The smaller conveniences, each its own extension.
- Project trust (
extensions/internal/project-approval.ts): prompts before loading project config (MCP servers, hooks, agents, rules, output styles, commands, skills) that pi would otherwise trust silently. - Plan mode (
extensions/plan-mode/):plan_mode_completetool, tool snapshot/restore that survives/reload./plan [description]enters plan mode and sends the description as the first prompt; it never leaves plan mode.pi --planstarts a session in plan mode, as Claude's--permission-mode plandoes. Leave by choosing "Execute the plan" afterplan_mode_complete, or withCtrl+Alt+P, which toggles plan mode; Claude'sShift+Tabmode cycle has no equivalent, since pi bindsShift+Tabto cycling the thinking level. - Todo list (
extensions/todo.ts): compaction-safe task tracking with the full list above the editor, as Claude Code shows its task list whenever a task is created or updated./todos-widget off|compact|fullhides the widget, shows counts and the active task on one line, or restores the full panel; it needs the terminal UI, since RPC mode draws no widgets. Empty lists stay hidden in every mode;/todosalways opens the complete list. Display mode stays in effect across tree navigation and compaction;/reload, a new session, resume and fork reset it tofull. Divergence: Claude Code collapses the list withCtrl+Tand saves that choice across sessions, and its collapsed form is the active task in the spinner line with the next one below it;/todos-widgetand its one-line form are pi-code's own. - Checkpoints / rewind (
extensions/git-checkpoint.ts): shadow-repo snapshots scoped to the files the session's edit tools touched, so checkpoint size tracks the edits rather than the size of the working directory; ignored files stay out even when edited. Restore overwrites checkpointed files, puts back a file the session first edited after the checkpoint as it was before that edit, and keeps files created later; 100 per session, repos pruned after 30 days.CLAUDE_CODE_DISABLE_FILE_CHECKPOINTINGskips the pre-run snapshot entirely. - AskUserQuestion (
extensions/question.ts): 1-4 questions per call, each withheaderand 2-4 options, single- ormultiSelect, plus free-text. Multiple questions share a TUI form: Left/Right or Tab/Shift+Tab move between the questions and a final Submit review, stopping at either end as in Claude Code. Navigation preserves answers, checkbox selections and text drafts; it does not select a highlighted option. Entering a question, answered or not, focuses its first row, as in Claude Code. A confirmed single-select answer shows a ✔ in the success colour: after the option's label, which also turns that colour, even with the focus on it, or after the text in the free-text row, as in Claude Code. The free-text row keeps its ✔ while its text is edited or deleted without Enter, deleted text showing the placeholder with the ✔, as Claude Code does, although the confirmed text stays the answer in the review and the result. Text typed in the free-text row stays there when an option is confirmed instead, and is not sent, as in Claude Code; a remote responder's option answer keeps it too. Checkboxes read[✔]in the success colour when checked and[ ]when not, as in Claude Code. Divergence: Claude Code draws every row number in grey; pi-code gives the number the colour of its label, and the success colour on a confirmed free-text row. The free-text option is an inline field: moving the highlight onto it starts typing, Left/Right move the cursor, Up/Down leave the row and keep the draft, and no key switches questions until typing stops. Enter confirms an answer and advances. AmultiSelectquestion uses Space to toggle and Enter to confirm. Divergence: Claude Code toggles with Enter or Space and confirms on a separate Next/Submit row below the options. On the TUI overlay it also has the inline free-text row, whose checkbox is checked exactly while it has text; Space types there and never toggles it, and the typed text is sent after the checked labels as a separateUser wrote:line. Enter with nothing checked and no text leaves it unanswered, as in Claude Code, clearing any earlier answer, and on a lone question it does nothing. The tab bar marks each question answered (☒) or not (☐). The Submit review lists the answered questions, warns when any are unanswered, and offers Submit answers or Cancel (Up/Down, Enter); Cancel is the same whole-call cancel as Esc. Once amultiSelectquestion is confirmed, every toggle and every edit of its text updates its answer, as in Claude Code, so what is shown is what is submitted. A confirmed single-select text answer changes only when Enter confirms the edited text, as in Claude Code. A confirmed single-select answer wins over a text draft left on the same question. Submitting marks unanswered questions explicitly as skipped while preserving confirmed answers and, for an unconfirmedmultiSelectquestion, its checked options and typed text. Single-select text that Enter did not confirm is not an answer, as in Claude Code. Claude Code keeps the given answers on a partial submit too. Divergence: it leaves the unanswered questions out of the result, and reports that the user did not answer only when nothing was answered; pi-code names each unanswered question as skipped. The keys match Claude Code's tab keybindings. Enter on a blank single-select field cancels the whole call, as Esc does, as in Claude Code. Esc cancels the whole call, from the field too, and discards every answer; the model gets a single cancellation. On the TUI overlay, Chat about this, below the options on every question, ends the call and sends the model Claude Code's clarify text with each question and the answer Submit would send: amultiSelectquestion's checks and text count as they stand, a single-select question's text only once Enter confirms it. Divergence: Claude Code returns that text as a rejected tool call, behind its rejection preamble "…To tell you how to proceed, the user said:", which credits its own template to the user; pi-code sends the clarify text alone. The RPC fallback has no Chat row, asks questions in sequence, and a cancel there also cancels the whole call. HonorsaskUserQuestionTimeout(60s/5m/10m, scope "User or managed"; a project's own settings.json cannot set it), read from managed settings then~/.claude/settings.json. On the TUI overlay only: a visible countdown for the last 20 seconds, any keypress restarting the timer, and on firing, confirmed answers are reported as on a normal submit, each unconfirmed question submits only its checked options, including a filled-inmultiSelecttext row, which the model gets apart from the checked labels (an unconfirmed highlight or single-select text draft is not sent), and the model is told once per call that the user may be away, even when every question was answered, so it proceeds on its own judgment rather than reading it as a cancel. Not implemented: restarting the timer on terminal focus-in, since pi's TUI input stream is not confirmed to carry that escape sequence; and the timeout on the RPC dialog-primitive fallback (no terminal, so no keypress or countdown to drive it); there amultiSelectquestion takes one option, since the dialog's select returns a single choice. Remote responders (a chat bridge, for example): on the TUI each question is first emitted onpi.eventsaspi-code:question:v1, typed asRemoteQuestionOfferin the same file. A listener that callsclaim()synchronously during emission receives the only settle handle. The overlay opens either way and the first answer, local or remote, wins. Answers are 1-based option indices, free text only whenallowFreeText, orcancel;passor an invalid reply withdraws the remote side and leaves the overlay open.touch()restarts the overlay idle timer, and the offer'ssignalaborts once the question is settled, after which replies are rejected. A call with several questions differs from a single one. Every question is offered when the form opens, so up to four offers are live at once; each carriesbatch(idshared by the call's offers, 1-basedindex,total), which a single question's offer omits. An offer stays live while its question is unanswered, whichever question has focus; a remote answer to another question saves there without moving focus. The settle handle returningtruemeans the answer was accepted, not that it is final: the local user can still change it until the form is submitted. A remotecancelon any offer cancels the whole call. Every open offer aborts when the form closes. A remote answer that leaves every question answered submits the form without a terminal review, whether the other answers were local or remote; while the highlight is on another question's field holding text that Enter has not confirmed, the form stays open instead. A remote answer to the question being typed in answers it, and the typed text is not sent. - Notifications (
extensions/notify.ts): terminal notification when a turn ends (OSC 777 / Kitty OSC 99 / Windows toast); honorspreferredNotifChannel(terminal_bell,notifications_disabled,iterm2_with_bell, else desktop) from user settings or the--settingsflag; fires only when you appear to be away, approximated by turn duration since pi exposes no terminal-focus signal. - Think keyword (
extensions/thinking.ts):ultrathinkraises reasoning to the max for one turn, matched on a word boundary, only ever raising, restored once the turn settles. It is the only keyword, as in Claude:think,think hard,think moreand similar phrases pass through as ordinary prompt text. Divergence: Claude adds an in-context instruction and leaves the API effort level unchanged; pi has no separate in-context channel for this and its thinking level is how deeper reasoning is requested, so the keyword moves the level and restores it after. - Session title (
extensions/session-title.ts): names a new session from its first message with a single model call; never overwrites an existing name, best-effort, at most once per session.CLAUDE_CODE_DISABLE_TERMINAL_TITLEskips it, which also leaves the terminal/tab title untouched sincesetSessionNameis the only sink for both. /context(extensions/context-usage.ts): reports used/window/free/percent of the model's context window, reading pi's live usage so it reflects a compaction./init(extensions/init.ts): generates a project context file; detects an existingAGENTS.md/CLAUDE.md(proposes improvements) or createsAGENTS.md, ingesting.cursor/rules,.cursorrules, and.github/copilot-instructions.mdwhen present; drives the main agent with full tools so it analyzes the codebase and writes the file itself.