pi-extensionsA pi package that bundles pi extensions
Semantic code search, quota recovery, and cross-device config sync for the pi coding agent.
Semantic code search, quota recovery, and cross-device config sync for the pi coding agent.
Install from the git repository into user settings (default):
pi install https://github.com/SeriousJul/pi-extensionsOr into project settings, shared with the team:
pi install -l https://github.com/SeriousJul/pi-extensionspi clones the repository and runs npm install for you, which also applies the codegraph postinstall patch. Update with pi update --extensions. Remove with pi remove https://github.com/SeriousJul/pi-extensions, list with pi list.
| Extension | What it does |
|---|---|
| codegraph | Semantic code index for the agent: four tools plus /codegraph, one index per git worktree, dependency sources via projectRoot. |
| tools | The /tools command to enable and disable tools per session. |
| context-cap | --context-window <tokens> caps the session's context window so compaction fires early. |
| initial-context | /ctx shows the token breakdown of the agent's initial context, with per-tool usage. |
| model-router | Recovers a session from a provider usage-limit halt (switch to a fallback or wait for the reset, then resume). |
| llama-refresh | Self-heals the context window of a session that resolved a local llama.cpp model while it was asleep. |
| output-starvation | Judges each request's output budget against the Effective window: refuses a budget that collapsed to pi's floor, and fits one the window cannot pay for. |
| quota | Monitors the OpenAI ChatGPT plan quota: a footer line with the used windows, and a /quota detail view. |
| sync | Cross-device pi config sync: /sync plus the pi-sync CLI, three-way merge, v1 backend a secret GitHub Gist. |
| usage | The pi-usage CLI and the usage report: token and cost usage across all pi sessions. |
| compress | Replaces finished turns in outgoing requests with one short standing-in message; the session file stays intact. |
| edit-assist | Corrects and diagnoses built-in edit calls: leading-whitespace drift corrected before execution, a Nearest region diff on no-match, occurrence lines on ambiguous matches, one targeted hint on malformed calls; the stock error text is always kept. |
| bash-no-match | Returns a no-match search (rg/grep exit 1 with an empty stream) to the agent as a normal result with a "(no matches)" note, instead of an error. |
| background-jobs | bash_bg, job_wait, job_status: run long commands in the background and wait on them once, instead of sleep-and-tail loops. |
| safe-branch-summary | Writes the /tree branch summary against a safe budget (Effective window over the Inflation factor) so code-heavy branches no longer die with exceed_context_size_error. |
| skill-command | Normalizes a newline-separated /skill: command to the single-space form pi expands, so injected skill commands are recognized. |