Use eb1 with Pi
Pi is an efficiency-first, customizable coding-agent harness. Use Keiro through Pi's custom model configuration when lower context overhead, local control, and a minimal terminal workflow matter.
On this page 1 of 7
Before you configure#
A dedicated key lets you inspect and revoke Pi traffic independently from production application traffic.
- Open API keys.
- Create a dedicated key for this Pi installation.
- Keep the newly revealed secret available in your password manager until setup is complete.
Install and configure#
Install Pi with the @earendil-works/pi-coding-agent package, or run it through npx:
npm install --global --ignore-scripts @earendil-works/pi-coding-agent@latest
# or
npx --yes @earendil-works/pi-coding-agent@latest --help
Pi reads custom model definitions from ~/.pi/agent/models.json. Add a Keiro provider entry that uses the OpenAI-compatible completions API:
{
"providers": {
"keiro": {
"baseUrl": "https://api.keirolabs.ai/v1",
"api": "openai-completions",
"apiKey": "keiro_sk_...",
"compat": {
"supportsStore": false,
"supportsDeveloperRole": false,
"supportsReasoningEffort": false
},
"models": [
{ "id": "eb1-preview", "contextWindow": 400000, "maxTokens": 32000 },
{ "id": "eb1-frontier-preview", "contextWindow": 400000, "maxTokens": 32000 },
{ "id": "eb1-fast-preview", "contextWindow": 240000, "maxTokens": 32000 },
{ "id": "eb1-efficient-preview", "contextWindow": 400000, "maxTokens": 32000 }
]
}
}
}
Replace keiro_sk_... with the key secret you created, then select the model as keiro/eb1-preview or pass it on the command line:
pi --provider keiro --model eb1-preview
contextWindow mirrors each model's published context_window in /v1/models. maxTokens is the generation cap Pi requests per turn; adjust it to match your plan's output-token budget.
Keep ~/.pi/agent/models.json owner-readable because it contains the key. Do not place raw secret bytes in shared project files.
Models#
Start with eb1-preview. Switch models when the task has a clear quality, latency, or cost requirement:
See Models for what each model is for.
eb1-previeweb1-frontier-previeweb1-fast-previeweb1-efficient-preview
Efficiency positioning#
External benchmark evidence makes Pi a strong efficiency-oriented harness choice, especially when context volume and cost are first-order constraints. That does not make it the universal quality leader: outcome quality still depends on the selected model, task type, repository shape, and tool configuration.
Authentication#
The key is sent as Authorization: Bearer, the same credential form as every other public endpoint. See API auth. A 401 means the configured key is missing, invalid, or revoked.
Requests from Pi appear in Keiro Usage and Logs like other API traffic.
Rotate the Pi key#
- Create a replacement dedicated key in the console.
- Update the key in Pi's local configuration or secret store.
- Verify a harmless request.
- Delete the old key in the console.