@arhen/pi-core-todo

Minimalist pi todo extension: todo tool with 4-state machine and blockedBy dependencies, /todos command, persistent tree widget. Fork of @juicesharp/rpiv-todo, cut to the core.

Packages

Package details

extension

Install @arhen/pi-core-todo from npm and Pi will load the resources declared by the package manifest.

$ pi install npm:@arhen/pi-core-todo
Package
@arhen/pi-core-todo
Version
1.0.7
Published
Aug 22, 2026
Downloads
1,294/mo · 261/wk
Author
arhen
License
MIT
Types
extension
Size
41.4 KB
Dependencies
0 dependencies · 4 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

@arhen/pi-core-todo

npm version license pi extension

Install

Requires the pi coding agent — install it first: npm install -g @earendil-works/pi-coding-agent.

pi install npm:@arhen/pi-core-todo

Registers the todo tool — conflicts with other todo extensions (@juicesharp/rpiv-todo). Run one at a time.

Minimalist pi todo extension: todo tool with a 4-state machine and blockedBy dependencies, /todos command, persistent tree widget. Fork of @juicesharp/rpiv-todo, cut to the core — no i18n, no branch replay, no config, no lazy-loading machinery.

Widget

Todos widget

Above-editor tree: ● Todos (2/5) heading, strikethrough for completed, for in-progress with activeForm in parens, for pending.

What's kept

  • todo tool: create / update / list / get / delete / clear
  • 4-state machine: pending → in_progress → completed, deleted tombstone (legal-transition validation)
  • blockedBy dependencies: create with initial set, addBlockedBy / removeBlockedBy additive updates, self-block and cycle rejection
  • /todos command: grouped status listing
  • Tree widget above the editor: ● Todos (n/m) heading, ├─/└─ rows, status glyphs, #id + deps when present, completed rows hide one turn after completion
  • Per-session state isolation (detached/child sessions never clobber each other)
  • Sidecar persistence (~/.pi/agent/pi-todo-state.json, debounced) — survives restarts

What's cut (vs rpiv-todo)

  • i18n/locales — inline English
  • Branch/fork replay — replaced by sidecar persistence (no replay of history across forked sessions)
  • Config dialog, collapse shortcut, guidance validation — fixed behavior
  • Lazy overlay loader + stale-module detection — direct import, register-once widget

Tool contract

Same LLM-facing schema as rpiv-todo: action (required) + per-action fields (subject, status, id, blockedBy, addBlockedBy, removeBlockedBy, activeForm, description, owner, metadata, includeDeleted). Prompt guidelines preserved verbatim (never batch completions, one task in_progress at a time, keep it in_progress on failure).

Development

bun install
npx tsc --noEmit
bun test   # pure-logic: reducer, transitions, cycles, sanitize

License

MIT.

Notes

  • Sidecar persistence assumes a single pi process per agent dir; concurrent processes overwrite each other's todo state.