Skip to main content
π

Run Pi on any model

Open-source terminal coding agent with a first-class Antseed extension.

Coding agentsMulti-format~3 min

What Pi is. Pi (@earendil-works/pi-coding-agent, formerly @mariozechner/pi-coding-agent) is a minimal, hackable terminal coding agent by Mario Zechner - the same lineage as pi-mono. It ships with four default tools (read, write, edit, bash) and lets you extend everything else - commands, providers, themes, even the editor UI - through TypeScript extensions, skills, and prompt templates. No fork required.

What the Antseed extension does. pi-antseed registers your Antseed endpoint as a Pi provider named antseed. It reads GET /v1/models when Pi loads and adds one model per seller and service, as antseed/<service-id>@<peer-prefix>-<seller-name>, ordered by seller reputation. Pick one with Ctrl+L or /model.

Which endpoint. The recommended endpoint is a gateway: set ANTSEED_BASE_URL and ANTSEED_API_KEY, and Pi works from any machine with its own budget and usage log. Without them the extension uses the local buyer proxy on http://localhost:8377, which only works on the same computer as the buyer.

How requests are sent. Each request goes out in the protocol the chosen seller advertises (OpenAI Responses, Anthropic Messages or OpenAI Chat Completions), with an x-antseed-pin-peer header for that seller, so Pi handles streaming, retries and tool calls natively.

Run Antseed first

Every integration needs an Antseed endpoint: a gateway, best on a small server so every tool on every machine can reach it, or the local buyer proxy (same computer only). One-time setup, a few minutes.

Step 1

Install Pi

  • Install Pi itself (the coding agent CLI)
    npm install -g @earendil-works/pi-coding-agent

    The binary is pi. Verify with pi --version. Pi's standalone binary install works the same way. The old @mariozechner/pi-coding-agent package is deprecated, but the extension still works with it.

  • Install the Antseed extension into Pi
    pi install git:github.com/Antseed/pi-antseed

    Pi extensions install from a git URL or a local path. pi -e git:github.com/Antseed/pi-antseed runs the extension once without installing; pi install ./pi-antseed works from a local clone.

Step 2

Point Pi at Antseed

Recommended: a gateway

ANTSEED_BASE_URLhttps://gateway.example.com/v1
ANTSEED_API_KEYantseed_…
Show as shell exports
export ANTSEED_BASE_URL="https://gateway.example.com/v1" export ANTSEED_API_KEY="antseed_…"

Your gateway's base URL, ending in /v1, and an API key from the Keys page of its console. Recommended: a gateway on a server, which every machine can reach. A gateway on this computer is http://localhost:8379/v1; publish it with a tunnel (antseed tunnel start) for other machines. No gateway yet: see Run Antseed first above. Set both in the shell that launches pi; the extension reads them when Pi loads.

Same computer, no gateway: the local buyer proxy

Leave ANTSEED_BASE_URL and ANTSEED_API_KEY unset. The extension then uses http://localhost:8377, the local buyer proxy, which checks no key. It only listens on localhost: for Pi on another machine, use a gateway.

Optional: limit the model list

ANTSEED_MODELSdeepseek-v4.1-flash,glm-5.2
Show as shell exports
export ANTSEED_MODELS="deepseek-v4.1-flash,glm-5.2"

A comma-separated list of service ids, or full route ids such as deepseek-v4.1-flash@aaaaaaaaaaaa-acme. Without it, every text model on the network is registered.

Step 3

Pick a model

deepseek-v4.1-flashglm-5.3-flashglm-5.2kimi-k3

The extension discovers models when Pi loads; run /reload in Pi to refresh the list as the network changes. Each entry is one seller: antseed/<service-id>@<peer-prefix>-<seller-name>, with the seller's reputation in the display name.

The full list is every model on the network. Run GET /v1/models on your endpoint, antseed network browse, or open the live network page to see what's available right now.

Verify

Test it

  • Launch Pi
    pi

    Pi's startup header lists loaded extensions. Look for antseed (or pi-antseed); load errors and discovery warnings (for example a 401 when ANTSEED_API_KEY is missing) show there too.

  • Open the model picker and pick an Antseed model
    /model

    Or press Ctrl+L. The picker is fuzzy-searchable; type "antseed" to filter. You should see entries like antseed/deepseek-v4.1-flash@aaaaaaaaaaaa-acme, one per seller and service.

Wire format • multi-protocol

Pi can send any of Antseed's supported protocols - configure per call. Antseed will match each request to the peer's advertised service protocols (see providerServiceApiProtocols on a peer) and translate when they don't match.

  • /v1/messagesAnthropic Messagesservice protocols includes anthropic-messages
  • /v1/chat/completionsOpenAI Chat Completionsservice protocols includes openai-chat-completions
  • /v1/responsesOpenAI Responsesservice protocols includes openai-responses

If it goes wrong

Troubleshooting

  • pi: command not found after installYour global npm bin is not on PATH. Run npm prefix -g to find it, then add <that-path>/bin to PATH in your shell rc. Or use a Node version manager (nvm, fnm, volta) which handles this automatically.
  • Pi says "No models available. Use /login…", and Antseed is not in /loginExpected: the extension adds its models when Pi starts, not through /login. Pi shows this when the extension loaded no models: update it with pi update (versions before 0.2.0 could not read a gateway), set ANTSEED_API_KEY next to ANTSEED_BASE_URL, restart Pi, and read the [pi-antseed] line it prints at startup.
  • No antseed/... models in the pickerCheck the warning in Pi's startup header. 401: set ANTSEED_API_KEY to your gateway key. Connection refused: ANTSEED_BASE_URL is wrong, or, without it, no buyer proxy runs on this computer. Then run /reload. Test the endpoint with curl -s "$ANTSEED_BASE_URL/models" -H "Authorization: Bearer $ANTSEED_API_KEY".
  • Pi runs on another machine than the buyerThe local buyer proxy on port 8377 only listens on localhost, so a remote Pi cannot reach it. Point Pi at a gateway: a server gateway, a gateway on your network, or a tunnel (antseed tunnel start). Set ANTSEED_BASE_URL to its URL ending in /v1 and ANTSEED_API_KEY to a gateway key. Never expose port 8377 itself.
  • An error from the endpoint mid-conversationUsually the seller behind the chosen model went offline, or your routing policy no longer allows it. Run /reload and pick another seller of the same model.

Reference

Links

Same category

Related

Run Pi on the open market

Run a gateway, point this tool at it, and pay per request.

All integrationsGateway API