Pi is interesting when you want more say in how a coding assistant does its work. It runs in a terminal, uses a model you choose and can read files, search, run commands and edit code. You can then adapt it with saved prompts, task instructions and extensions. A recurring incident review shows why that might help: the same kinds of files arrive each time, and the next engineer needs a report they can check. The example below starts with those files, then explains where customization becomes worth the effort.
Ready guideDocumentation checked
In this guide 7 sections
01Fit
Is it for you?
When it helps
A recurring file-based review where consistent instructions and source references would save effort
Work that calls for a particular model provider or a capability you want to add to the assistant
When to choose something else
A job your existing assistant already handles well enough to make extra customization unnecessary
Untrusted or unattended tasks on a machine where Pi can reach sensitive files or credentials without suitable isolation
02Requirements
Before you start
A terminal and access to a supported model provider, or a configured local model
Node.js 22.19 or newer for the npm installation below. Native Windows has a separate setup guide
For the incident example, an isolated environment containing only the sanitized inputs and an approved model connection
Cost and access
Pi is MIT licensed; the model it uses has its own costs. A provider may charge for API usage or require a subscription, while a local model uses your computing resources. Check the provider’s current prices and data terms before sending private files or committing to repeated reviews.
The npm command below requires Node.js 22.19 or newer. If npm does not suit your setup, the quickstart also has a standalone installer for macOS and Linux. Native Windows has a separate guide. Install Pi in the environment where you intend to run the review.
Run pi --version in that environment. A version number gives you something concrete to compare if a command or setting behaves differently after an update.
Start pi, use /login to select an approved provider, then use /model to choose an available model. The login flow can store credentials, so use the credential-handling approach approved for that environment.
Pi runs with the permissions of the account that starts it and does not ask before every tool call. Choosing a working folder or a shorter list of tools does not restrict the whole process to those files. The security guide and full Pi article explain how to run this review in an isolated environment with read-only inputs.
The starter’s checkout log contains two timeouts after a rollout, but also a successful request on the new revision. There is no downstream telemetry. Use Pi to turn these deliberately sparse, synthetic files into a handoff that says what happened, what remains uncertain and which evidence would help next.
Included example files
A small support-service project
Synthetic code, logs, a deliberately stale runbook, and six support tickets. The JavaScript uses Node.js 22+ with no packages or network calls. Product accounts and model access are separate.
Open the starter’s four operations files yourself first. The rollout changes r17 to r18 at 09:10 UTC; the next two logged requests time out at 2000 ms, and the 09:14 request succeeds. The checked-in configuration says 2000 ms and zero automatic write retries, while the runbook says 5000 ms and two. These deliberate contradictions give you something specific to verify.
Run the whole Pi process in an isolated environment following the linked security guidance, with only these synthetic inputs exposed. Mount or expose them read-only if changes must be prevented. Pi’s working folder and a “do not edit” request do not enforce that boundary. Select an authorized provider/model, then send the request.
Read the report beside the files. Copy the useful, checked findings into handoff.md outside the read-only input location. Keep the model/version and any corrections in a short review note. The artifact should help the next person find evidence rather than merely make the incident sound coherent.
What to ask
Read only the four files in operations/. Draft a handoff with observations, possible explanations, missing evidence and next checks. Cite filenames and line numbers for factual claims. Account for the successful request after the rollout as well as the timeouts. Compare the runbook with config.json. Do not invent downstream evidence or claim a root cause. Return the report in the conversation; do not edit the input files.
The artifact you are working toward
handoff.md, with the unknowns still visible
A useful handoff connects events without treating timing as proof. The excerpt below is an authored illustration of the expected reasoning, not output from a Pi run.
Illustrative result to compare
Observed: r18 was rolled out at 09:10 UTC (rollouts.csv:3). Two subsequent requests time out at 2000 ms, but a later r18 request succeeds (checkout.log:2–4).
Documentation mismatch: config.json:1 sets 2000 ms and zero automatic write retries; runbook.md:3 says 5000 ms and two.
Unknown: whether the rollout caused the timeouts. No downstream telemetry is included. Compare revision-specific failures and downstream latency before choosing a cause.
What the example should show
Every stated time, revision and setting maps to the supplied files.
The successful r18 request is retained instead of being omitted to strengthen the rollout theory.
The next checks name missing data, such as downstream latency and errors, rather than inventing a result.
The report announces that r18 caused the incident+
The bundle establishes ordering, not causation. Ask for the evidence that rules out competing explanations; none is provided here.
The report trusts the runbook’s timeout+
Point Pi back to config.json and ask it to preserve the disagreement. Confirming the deployed value would require evidence beyond this static bundle.
What you can take from this example
A colleague should be able to resume the investigation from the handoff and check its claims quickly. If checking the prose takes longer than reading the four files, simplify the request or the output before adding more tools.
The included baseline tests and evaluation script were checked locally. The deliberately failing contract tests demonstrate the defects in the starter. No AI product was installed or run for these examples; model responses and reviews will vary.
05Next steps
Go deeper
How much customization does the job need?
If you are repeatedly typing the same request, a prompt template may be enough. A skill can add the instructions and supporting material a review needs. An extension becomes useful when you need code to do something new, such as retrieve an approved incident export. The full Pi guide follows these choices through a related three-file review so you can see what each one adds.
When a script starts a review, it needs to know when Pi has finished before it forwards the report. The full guide explains the differences between plain-text output, JSON event records and the RPC interface, which lets another program send commands and receive responses. It also covers MCP, the protocol Pi can use to call tools supplied by other services.
Another terminal assistant to consider when Claude access already fits the project
07Evidence and scope
Sources and review
Product behavior is based on the linked official documentation. This walkthrough uses an authored synthetic starter project. Its baseline tests and local checker were checked; no installation, model response or product performance was independently tested for this guide.