@carbon-ni/pi-schedule

Session-scoped scheduled follow-ups for Pi

Packages

Package details

extension

Install @carbon-ni/pi-schedule from npm and Pi will load the resources declared by the package manifest.

$ pi install npm:@carbon-ni/pi-schedule
Package
@carbon-ni/pi-schedule
Version
0.1.0
Published
Nov 9, 2026
Downloads
345/mo · 32/wk
Author
cristianoliveira
License
unknown
Types
extension
Size
74.2 KB
Dependencies
0 dependencies · 2 peers
Pi manifest JSON
{
  "extensions": [
    "./src/index.ts"
  ]
}

Security note

Pi packages can execute code and influence agent behavior. Review the source before installing third-party packages.

README

pi-schedule

Schedule one-off follow-ups in your Pi conversation. Ask Pi to check CI later, or set a deadline yourself. Results appear in the same chat.

Keep the Pi session open and the computer awake. There is no background service, recurring schedule, or automatic retry.

Install

Requires Pi 1.5.x, Node.js 22.18+, and a persistent TUI or RPC session. Storage relies on Unix file permissions and filesystem behavior; use macOS or Linux. Pi extensions run with your user permissions, not in a sandbox.

git clone https://github.com/carbon-ni/pi-schedule.git
cd pi-schedule
npm ci
pi install "$PWD"

Start Pi, or run /reload in an existing session. If the repository is already at ~/.pi/agent/extensions/pi-schedule, Pi discovers it without pi install.

After the first npm release, install without cloning:

pi install npm:@carbon-ni/pi-schedule

Schedule a follow-up

Ask Pi with an exact target and a clear scope:

In 30 minutes, check CI for owner/repo#123 and report failures. Do not modify code.

Pi confirms the task ID, due time with timezone, target, and cancellation command. It can schedule further checks needed for the current request, with a reason for each check. A status check does not authorize code changes, pushes, or merges.

To schedule without a model call, use /schedule:

/schedule in 30m Check CI for owner/repo#123 and report failures; do not modify code
/schedule at 2026-11-09T14:30:00+01:00 Check deployment status for owner/repo
/schedule list

Use an explicit timezone offset for at. Replace S-<id> below with the ID from the confirmation or task list:

/schedule show S-<id>
/schedule cancel S-<id>
/schedule help

Tasks wait while Pi is busy, messages are queued, or extension UI is blocking. They remain cancellable until dispatch starts. Dispatched means Pi started the turn, not that the check succeeded. Read the conversation for findings or blockers.

Recover missed work

Closing Pi stops execution. Reloading or resuming keeps future tasks, but missed tasks become overdue. Sleep or forward-clock gaps over two minutes also require review; missed work does not run automatically.

Inspect the saved request, then explicitly run overdue work when Pi is idle:

/schedule show S-<id>
/schedule run S-<id>

If dispatch is uncertain, inspect the conversation and any external effects first. Then acknowledge it without replay:

/schedule dismiss S-<id>

Create a fresh task only if another check is needed. For storage or lock errors, follow security and recovery before using /reload.

Each confirmation includes pi --session-id <id> to resume from the same project. Use it if a task was scheduled before the first chat message: Pi creates session files lazily, so the session may not appear in the picker yet.

Control follow-up limits

Agent-created checks share a default budget of three checks within two hours. Follow-ups cannot reset that budget or silently recreate a cancelled chain. A new explicit user request starts a new authorization scope.

Only you can change a chain's total run limit and expiry from now:

/schedule budget S-<id> 5 3h

An expired chain needs a budget extension before it can run. Maximum explicit budget: 20 checks within 24 hours. Each session allows 20 pending or overdue tasks, 8 KiB per saved instruction, and 1,000 history records.

For agent integrations, schedule_task supports create, list, show, and cancel. Creation requires an instruction, exact target, reason, and either delay_seconds or timezone-qualified run_at.

Local state

Tasks stay in ~/.pi/agent/schedule/, or <PI_CODING_AGENT_DIR>/schedule/ when Pi's agent directory is overridden. There is no separate scheduler configuration.

State files use mode 600; directories and locks use mode 700. Each session has one exclusive owner. Forked sessions get separate stores. Rewinding history does not restore cancelled or dispatched tasks. Corrupt state is retained for recovery; a write failure stops scheduling until reload.

Development

See development for setup, isolated loading, and checks; releasing for npm setup and publishing; architecture for implementation boundaries; security and recovery for permissions and failure handling; and design baseline for the original requirements.