cd /news/developer-tools/show-hn-pi-extension-to-maximize-ai-… Β· home β€Ί topics β€Ί developer-tools β€Ί article
[ARTICLE Β· art-32824] src=github.com β†— pub= topic=developer-tools verified=true sentiment=↑ positive

Show HN: Pi Extension to Maximize AI Credits Across Cursor, Codex, ClaudeCode

Developer Sathish316 released open-source extensions that allow Pi, a host coding agent, to route tasks to other AI coding agents like Cursor, Codex, and Claude Code via the Agent Client Protocol (ACP), effectively pooling AI credits across services. The extensions, available on GitHub, enable Pi to treat external agents as models in its picker, executing turns through child processes. This tool aims to maximize usage of AI credits across multiple platforms.

read2 min views1 publishedJun 18, 2026

All four files do the same job: they let Pi (the host coding agent) drive another coding agent's CLI as if it were just another model in Pi's /model

picker. It uses ACP (https://agentclientprotocol.com/) to communicate with any coding agent. You pick "Cursor Sonnet" or "GPT-5 [codex-app-server]" or "Opus [claude-code-acp]" in Pi, and your turn is secretly executed by that external agent running in your workspace.

They all follow this shape:

β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”
β”‚ Pi host process                                                    β”‚
β”‚                                                                    β”‚
β”‚   /model picker ──► pi.registerProvider(...)                       β”‚
β”‚        β”‚                                                           β”‚
β”‚        β”‚ streamSimple(model, context)                              β”‚
β”‚        β–Ό                                                           β”‚
β”‚   β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”   builds prompt    β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”      β”‚
β”‚   β”‚  Provider   β”‚ ─────────────────► β”‚   Bridge (singleton) β”‚      β”‚
β”‚   β”‚  stream fn  β”‚ ◄───────────────── β”‚  serializes turns,   β”‚      β”‚
β”‚   β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜   stream events    β”‚  owns 1 session      β”‚      β”‚
β”‚        β–²                             β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”¬β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜      β”‚
β”‚        β”‚ AssistantMessageEventStream            β”‚ spawn            β”‚
β”‚        β”‚ (text/thinking deltas)                 β–Ό                  β”‚
β””β”€β”€β”€β”€β”€β”€β”€β”€β”Όβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”Όβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜
         β”‚                                        β”‚
         β”‚                                        β–Ό
         β”‚                              β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”¬β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”
         └──── JSON-RPC over stdio ───► β”‚ Child process (CLI)  β”‚
                                        β”‚ cursor-agent / rovo  β”‚
                                        β”‚ codex / claude-acp   β”‚
                                        β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜

The bundled extensions:

cursor-acp.ts

β€” Cursor Agent over ACPcodex-app-server.ts

β€” OpenAI Codex over app-serverclaude-code-acp.ts

β€” Claude Code over ACP (uses the official ACP SDK)rovo-acp.ts

β€” Atlassian Rovo Dev over ACP

Pi auto-discovers *.ts

files in ~/.pi/agent/extensions

, but external npm dependencies are not bundled into those files.

Clone this repo:

git clone https://github.com/sathish316/pi-omniagent-extensions.git
cd pi-omniagent-extensions

Copy the extension files into your Pi extensions directory:

mkdir -p ~/.pi/agent/extensions
cp cursor-acp.ts rovo-acp.ts codex-app-server.ts claude-code-acp.ts \
   package.json ~/.pi/agent/extensions/

Install the extension dependencies:

cd ~/.pi/agent/extensions
npm install
npm run check:claude-code-acp-deps

Make sure the underlying agent CLIs are installed and on your

PATH

for the extensions you want to use:cursor-agent

(cursor-acp),rovo

(rovo-acp),codex

(codex-app-server).claude-code-acp

pulls its runtime from npm. - Restart Pi. The bridged models appear in the

/model

picker tagged with their provider, e.g.[codex-app-server]

or[claude-code-acp]

.

The claude-code-acp.ts

extension needs:

@agentclientprotocol/sdk

@agentclientprotocol/claude-agent-acp

The Pi API packages imported by the extensions are provided by the running Pi installation.

── more in #developer-tools 4 stories Β· sorted by recency
── more on @pi 3 stories trending now
sponsored brought to you by zahid.host 4,200+ EU-deployed projects
reading about agents? ship yours in a single git push.

Run your AI side-project on zahid.host

EU-based hosting, git-push deploys, automatic HTTPS, no cold starts. Free tier with a custom domain β€” perfect for shipping the agent you just read about.

$git push zahid main
β†’ Live at https://your-agent.zahid.host βœ“
Get free account β†’ Pricing
from €0/mo Β· no card required
LIVE [news/show-hn-pi-extension…] indexed:0 read:2min 2026-06-18 Β· β€”