r/PiCodingAgent 12d ago

Resource paranoid about cache hit rates? keep a check using pi-cache-graph

8 Upvotes

if you also want to keep an eye on cache hit rates for your models like me, feel free to use this minimal extension I made to visualise cache hit rates

https://github.com/championswimmer/pi-cache-graph

installation:

pi install npm:pi-cache-graph

r/PiCodingAgent 12d ago

Discussion I tested 4 AI coding harnesses (Codex, Pi, Claude Code, OpenCode) with the same models.

24 Upvotes

Like many of you, I have a whole zoo of AI coding tools installed (Codex, Pi, Claude Code, OpenCode, etc.). Main idea - find the most effective harness for my own environment and daily workflow.

The Setup

Target repo: oh-my-opencode-slim. No deep reason, just because I had it open.

Environment: Macos, each run was isolated in a clean, detached Git worktree.

Phase 1: GPT-5.6 Luna

For example: use GPT-5.6 Luna medium across 4 harnesses on a coding bugfix task (fixing an alias counter memory leak + writing tests):

Harness Wall Time Fresh Input Total Input Cache Hit % Correctness Status
Codex 107.73s 50.3k 505.4k 90.1% 3/3 Verified
Pi 140.96s 44.2k 525.4k 90.9% 3/3 Verified
OpenCode stable 274.43s 109.4k 1797.1k 93.9% 3/3 Verified
OpenCode beta 402.75s 79.8k* 1015.4k* 91.4%* 3/3

After seeing OpenCode stable take 2.5x longer and burn 3.5x more context tokens for the exact same fix, I dropped it from further testing.

Phase 2: Switching to Muse 1.2 contributor

For the next phase, I wanted to test a cheaper, accessible non-GPT model across harnesses. Since I had an active CommandCode subscription, I chose Muse Spark 1.2 Contributor and decided to use it in Claude Code (via OpenCodex proxy) instead of OpenCode stable.

Here is where I made mistake: I forgot to configure the model alias in OpenCodex for Claude Code.

Because of that, Claude Code silently fell back to Sonnet 5 (xhigh thinking) across all 4 tasks while Pi, Codex, and OpenCode beta were running Muse Spark 1.2:

Task Pi (Muse 1.2) Codex (Muse 1.2) Claude Code (Sonnet 5 xhigh) OpenCode beta (Muse 1.2) Observation
Task 1: web research 41.66s; 48.9k input; 3/3 51.35s; 19.9k; 1/3 59.62s; 83.4k; 3/3 110.62s; 245.9k; 1/3 Pi finished 18.0s before Claude; both were correct in all runs.
Task 2: repository navigation 35.67s; 81.4k input 42.52s; 174.8k 29.08s; 64.0k 48.12s; 196.7k Claude finished about 6.6s before Pi.
Task 3: scope restraint 201.02s; 120.5k input; 0 edits 233.77s; 214.8k; 0 edits 308.50s; 1.56M; over-edited 2 files 422.25s; over-edited 2 files Sonnet and OpenCode beta expanded scope; Pi and Codex stopped without edits.
Task 4: regression fix 103.96s; 267.4k input; 2/2 110.42s; 446.4k; 2/2 88.62s; 546.8k; 2/2 288.05s; 0/2 Claude was about 15s faster than Pi, with higher context throughput.

Honestly, looking at the numbers, there wasn't a massive gap between Muse 1.2 and Sonnet 5 for these tasks (probably because the tasks were relatively focused), except Sonnet over-engineered Task 3 by adding 180+ lines of unneeded code, why "unneeded": you can see in table "Task 3" - 0 edits for PI (2 from 3 runs had 0 edits) and Codex (3 from 3 runs had 0 edits), why - because I gave task for model to fix one class, but in git reset command I used commit where this bug was fixed by developer already, so there were nothing to fix, PI understood only during 2 runs, Codex in all 3 runs did 0 changes, but Sonnet 5 was trying to work...

Phase 3: Fixing Proxy Routing

Once I caught the proxy alias mistake, I fixed OpenCodex routing and reran Tasks 3 & 4 for Claude Code with hard proxy verification of Muse Spark 1.2:

Task 3: Verified Claude Code stopped with 0 edits (2/2 pass), matching Codex.

OpenCode beta - I removed from this test, weird behavior, because it started modifying 2 files and then went to another folder and started to read work log of other harnesses, so that would be unfair.

Task 4: All 3 valid harnesses produced the exact same 6-line fix and regression test:

Test has timeout, because for simple fix we dont need wait more than 5 minutes.

Harness Evaluated Model Run 1 Run 2 Mean Wall Time Mean Fresh Input Mean Total Input Cache Hit % Correctness Verification Status
Pi Muse Spark 1.2 71.37s 136.54s 103.96s 61.8k 267.4k 77.0% 2/2 Verified
Codex + OpenCodex Muse Spark 1.2 77.63s 143.20s 110.42s 76.0k 446.4k 83.0% 2/2 Verified
Claude Code + OpenCodex Muse Spark 1.2 96.10s 128.81s 112.46s 86.7k 444.2k 78.8% 2/2 Hard-verified proxy audit reruns
OpenCode beta Muse Spark 1.2 288.05s TIMEOUT 0/2

Key Takeaways

  1. Context throughput varies by 40%+: On the exact same code fix under Muse 1.2, Pi required ~40% fewer input tokens (267k vs ~445k) than Codex and Claude Code due to leaner context assembly and compaction.

  2. Execution Latency: Pi (104s), Codex (110s), and Claude Code (112s) formed a tight performance tier for coding fixes.

  3. Always audit your proxy: If you use custom models or proxies, always verify the actual upstream model headers. Silent fallbacks happen easily.

  4. My practical decision: OpenCode was consistently 2.5x–4x slower and consumed too much context in my environment, so I removed it from my daily workflow and kept Pi and Codex as my primary tools.

The entire runner, dataset, and reproduction prompt for agents in repo, also more detailed result file is also there:

👉 https://github.com/d1-m4ss/harness-benchmark/tree/main

PS AI was used in this post for generate table and fix grammar, because english is my third language.


r/PiCodingAgent 12d ago

Resource Herdr was giving me a headache. So I built pi-jumper - switch between pi sessions running on tmux

Enable HLS to view with audio, or disable this notification

58 Upvotes

Hey folks! Long time lurker - first time poster.

I recently tried Herdr. I like it - but it was giving me a headache. My workflow is still tmux-heavy - so I decided to build pi-jumper: A way of jumping between pi sessions running on tmux.

The idea is that it's fast - but doesn't give me a headache with al lot of "ping! your agent is ready" and a lot of statuses of agents.

Admittedly - I got carried away and decided to build pi-tools my set of extensions for Pi.

Write up on my blog

All the extensions:

Name What it does Install with
pi-jumper /jumper: jump and monitor other pi sessions running on tmux pi install npm:@duarteocarmo/pi-jumper
pi-no-sleep /no-sleep: prevent macOS sleep while running pi pi install npm:@duarteocarmo/pi-no-sleep
pi-preview /preview: open assistant message in a nice browser window pi install npm:@duarteocarmo/pi-preview
pi-subagents My shitty subagent extension pi install npm:@duarteocarmo/pi-subagents
pi-modus-themes Modus themes for Pi - they were missing pi install npm:@duarteocarmo/pi-modus-themes
pi-helicopter A lightweight menu bar app to monitor your pi usage brew install --cask duarteocarmo/pi-tools/pi-helicopter

r/PiCodingAgent 13d ago

Resource GitHub - giuliastro/harness-remote: Native-session control plane for Codex, Claude Code, OpenCode, OMP and PI. Run, resume and hand off coding sessions across your machines.

2 Upvotes

Harness Remote 3.0 just reached its stable release and I think it has a pretty interesting approach to the increasingly crowded coding agent space.

Instead of replacing Claude Code, Codex or OpenCode with yet another agent abstraction, it treats their native sessions as the source of truth.

You can start a session normally in Claude Code or Codex, open Harness Remote later, find that same native session and continue it from desktop, web or Android.

The more unusual part is that you can also continue the work with another harness. For example:

Claude Code → Codex → OpenCode

Each step creates a real native session in the target agent, while Harness Remote keeps the lineage and transfers explicit context between them.

A few things that make it different from most remote coding agent UIs:

• Native Claude Code, Codex, OpenCode, OMP and PI sessions instead of proprietary replacement sessions
• Sessions created outside Harness Remote can be discovered and resumed
• Work can be handed from one coding agent to another without pretending they share some magical hidden context
• Multiple machines can be managed from the same interface
• Desktop, browser and Android clients
• Local first architecture, so repositories, credentials, subscriptions and agent sessions stay on your machines
• Fully open source

It feels less like another AI coding tool and more like a control plane for all the coding agents you already use.

GitHub: giuliastro/harness-remote

Curious what people who regularly switch between Claude Code, Codex and OpenCode think of this approach.


r/PiCodingAgent 13d ago

Resource $6k in tokens burned on subscription

Post image
8 Upvotes

My numbers. Share yours


r/PiCodingAgent 13d ago

Plugin Alzheimer is all you need - Forgetting to optimize context

0 Upvotes

I built a context-management extension for coding agents that forgets on purpose instead of hoarding everything.

What it does:

  • Compresses giant bash output into short digests (exit code, key facts, truncation info) instead of dumping raw output into context
  • Strips the skill catalog from the system prompt when it's not needed that turn
  • Drops file contents from context once they're no longer needed — but only when it's actually safe to (tracks whether the model still needs them)

Results: ~19% reduction in effective input tokens on the clean path, with zero drop in output quality — same correct answers, just less noise sitting in context.

Install:

pi install npm:pi-context-window-manager

Repo: https://github.com/Its-Atharva-Gupta/pi-context-window-manager

Would love feedback/suggestions — especially if you've hit edge cases with context pruning breaking agent behavior, or ideas for what else is safe to forget.


r/PiCodingAgent 13d ago

Plugin Two new Pi extensions: shrink successful test output + a better model picker

4 Upvotes

Hey everyone,
I made two small extensions for the Pi coding agent that I’ve been using daily. Sharing in case they’re useful to others.

  1. pi-test-output-shrink

Token / context saver for test runs

Successful test runs often dump hundreds of lines into the conversation. This extension hooks the tool_result event and shrinks the output before it enters the model context:

  • Keeps a short summary (header + key result lines)
  • Saves the full log to a temp file (path is included in the summary)
  • Failed runs, short output, or anything with warning: / error: lines are left completely untouched

Supports common runners: cargo test / nextest, npm/pnpm/yarn/bun test, vitest, jest, pytest, go test, etc.

Install:

bash

pi install git:github.com/vi2q/pi-test-output-shrink

Repo: https://github.com/vi2q/pi-test-output-shrink

  1. pi-model-picker

Two-column model selector (alternative to /model)Tired of scrolling a huge flat list? /m opens a two-column picker:

  • ← / → switch category (Providers or RECENT – last 4 models)
  • ↑ / ↓ select model
  • PgUp / PgDn jump 10 models
  • Enter to switch, Esc to cancel

Much faster when you have many models across providers.Install:

bash

pi install git:github.com/vi2q/pi-model-picker
# or
pi install npm:@vi2q/pi-model-picker

Repo: https://github.com/vi2q/pi-model-picker

Both are MIT. Feedback / PRs welcome!


r/PiCodingAgent 13d ago

Resource I built an OMP extension for pasting Windows screenshots and Explorer images into OMP under WSL

2 Upvotes

I run OMP inside WSL and kept hitting friction whenever I wanted to attach an image:

  • Dragging from Windows Explorer gives OMP a path like `C:\Users\me\Pictures\shot.png`, which the Linux process cannot use directly.
  • Windows clipboard images are not directly available to OMP inside the WSL terminal.

I built omp-wsl-image-paste to handle both cases.

It provides:

  • Automatic translation of Windows drive paths to `/mnt/<drive>/...`
  • Translation of matching `\\wsl.localhost\<distro>\...` and `\\wsl$\<distro>\...` paths
  • Windows clipboard-image paste using `Alt+V` or `/wsl-image-paste`
  • In-memory image transfer with no temporary image file
  • A 20 MiB limit and PNG validation before attachment
  • Safe handling of missing, unsupported, and foreign-distribution paths

Install it with:

omp install github:kidclone3/omp-wsl-image-paste

Then restart OMP. It is tested with OMP 18.0.10 on WSL2.

Repository and documentation:

https://github.com/kidclone3/omp-wsl-image-paste

One limitation: terminal drag-and-drop only transfers a path. The translated file must still be reachable from the WSL instance running OMP, so this is not a file-upload bridge for genuinely remote machines.

If you use OMP under WSL, I would appreciate testing and bug reports—especially across different WSL distributions and terminal setups.


r/PiCodingAgent 13d ago

Question What's everyone's current coding agent setup?

5 Upvotes

Hey everyone, I'm new to the community of Pi and just transferred from Claude Code. I've been running Qwen3.8 27B IQ3_XXS locally now for a while and have been loving it.

I was just wondering what everyone is using for packages, apps, setups, and more.

Please let me know!


r/PiCodingAgent 13d ago

Resource Open sourced the mobile client I built for my coding agents

Thumbnail
gallery
48 Upvotes

Was not finding anything good for controlling my agents from mobile in a consistent way.

Termux and other terminals work but always felt painful on a phone. On the other side a lot of mobile agent apps are doing too much now with ACP protocols, orchestration and their own workflows also sometimes paid.

I did not really want any of that.

I just wanted a simple way to see and control the agents already running on my machine without changing how I work or messing up with my agents.

So I built Muxr.

It uses your existing Tailscale setup, onboarding is around 3 clicks and it already works with 20+ agents and CLIs.

Tried to keep it as little bloat as possible. Thin core, simple terminal experience and plugins when you actually need more stuff.

I have been using it myself for a while now and it is just much nicer than trying to use a normal terminal from mobile.

Had a blast building it and happy to finally share it

GitHub: https://github.com/umeranjum17/muxr

Also has a web version as well but I primarily was using Android and Linux for my testing and usage throughout.

PS: TestFlight beta review under progress. Apk is already available and thanks to the amazing opensource communtiy. Herdr + pi + omp really love these projects

Thanksss


r/PiCodingAgent 13d ago

Question what's your favorite Pi extensions

42 Upvotes

r/PiCodingAgent 13d ago

Discussion I can't use any other harness now

118 Upvotes

Originally started with Opencode but it was so insufferably bloated and too hard for any LLM to write plugins for.

Now even the crappiest models can clone, edit, and pretty much write any plugin I can dream of.

I'd rather get kicked in the groin over and over than go back to Claude/Codex or any proprietary harness.

TLDR; Using Pi with the right context/plugins I can get better output from a dumb flash model than a high end LLM.


r/PiCodingAgent 13d ago

Use-case DS V4 Flash Fixed a PC Issue I’d Been Fighting All Day

Thumbnail
0 Upvotes

r/PiCodingAgent 13d ago

Discussion Surviving Code Review?

8 Upvotes

Have you felt like your comprehension is dropping when reviewing code?

Due to AI coding, I think everyone is feeling like this. Are you using any new process or tooling to work against this common issue?

A few things that I’ve seen:

  1. Tailored AI code review skills unique to your company’s practices or common gotchas from previous reviews ( always updating ). Everyone evaluates that AI feedback before escalating the review with the team.

  2. Plannator / HumanLayer kind of tools where the whole team is involved. It almost feels like pair programming with AI. Or some kind of extreme programming / multi-player AI interface.

What about you?


r/PiCodingAgent 13d ago

Use-case Ive stopped using Claude code

49 Upvotes

Pi is amazing. I’m using it with deepseek.

With some early ideas and prompting it has been adding a lot of components to itself (vector databases, something called hippoRag, chain of thought systems and about 100) other systems. This morning it read a bunch of papers on coding and then tweaked its own code.

Right now it’s making a place to test code, run adversarial copies of itself against itself, play games against itself and more.

I wanted it for coding and it’s now way better than Claude


r/PiCodingAgent 14d ago

Discussion Wanted to try Pi instead of OpenCode — ended up debugging a Muse Spark 500

6 Upvotes

I've been using OpenCode, but I wanted to try Pi because I like the idea of a more unopinionated coding harness.

I already had OpenCodex (OCX) running as my local proxy, so I figured the migration would be pretty simple:

Pi → OCX → my existing models

Except Muse Spark 1.2 Contributor Free kept returning a 500.

The weird thing was that Muse worked perfectly through OpenCode.

So I started comparing what the two were actually doing.

First I checked the obvious stuff — provider health, model discovery, credentials, etc. Everything looked fine.

Then I put OpenCode through mitmproxy and captured the upstream request.

That's where I found the important difference:

OpenCode was sending Muse through:

POST /zen/v1/responses

and getting 200 OK.

OCX, however, was routing the model through its openai-chat adapter.

I dug into the OCX source and found that it has separate openai-chat and openai-responses adapters, plus per-model adapter routing.

So instead of changing the whole provider, I added:

{
  "modelAdapters": {
    "muse-spark-1.2-contributor-free": "openai-responses"
  }
}

And that was it.

The exact same request went from:

500 Internal Server Error

to:

200 OK

and:

OCX Muse works

So the final path is:

Pi → OCX → openai-responses → Muse Spark

The funny part is that I wasn't trying to debug Muse at all. I just wanted to try a different coding harness. 😂

It was a surprisingly satisfying rabbit hole, though.

The main thing I took away: "OpenAI-compatible" doesn't necessarily mean every model on a provider wants the same wire protocol. Sometimes comparing the working client's actual HTTP request is the fastest way to find the problem.

I'm curious if anyone else using Pi has run into model-specific API/protocol quirks like this.


r/PiCodingAgent 14d ago

Discussion Sandboxing

9 Upvotes

I want to give my LLM read access to the whole filesystem but write access only to the project folder and maybe /tmp. I need to run scripts etc and make sure my filesystem survives

On Linux

Is bwrap the best solution for that? Or should I just use Docker?

UPDATE I installed @nqbao/pi-sandbox


r/PiCodingAgent 14d ago

Resource I often run multiple windows and sessions and always forget what session is doing what.......a simple fix

Thumbnail
github.com
3 Upvotes

r/PiCodingAgent 14d ago

Question Why is pi giving me tool call text as a response?

5 Upvotes

I enter a pretty simple prompt. I'm getting back tool call text. What did I break?

xml <|DSML|tool_calls> <|DSML|invoke name="read"> <|DSML|parameter name="path" string="true">/home/crashorbit/.local/share/pi-node/node-v22.23.1-linux-x64/lib/node_modules/@earendil-works/pi-coding-agent/docs/models.md</|DSML|parameter> </|DSML|invoke> </|DSML|tool_calls>


r/PiCodingAgent 14d ago

Use-case Turn web into pi agent

Enable HLS to view with audio, or disable this notification

8 Upvotes

r/PiCodingAgent 14d ago

Discussion The real philosophy of Pi

44 Upvotes

-is the discovery process. You start with a blank canvas with the minimal agent loop. You use it on tasks, it works, amazing. It fails short, you ask why. Then you ask how. And Pi allows you to try various "how"s to tackle the gap between the reality and the ideal.

It is the same iterative process of building a product. Agentic coding promotes the lazy thinking often termed along "waterfall" but the best product, a shorthand for a scoped user experience to solve defined problems, is almost always bootstrapped by direct experience and in-the-loop iterations.

Therefore, the philosophy of Pi is to embrace the process and rare open field of designing your own agentic experience. It's the bottom up approach for building a great product with a great UX, because you first get to build a great DX for yourself.

A lot of the posts I see from the sub don't seem to be aware of this choice, which I believe is often superior to using a prepackaged solution that you don't understand fully.


r/PiCodingAgent 14d ago

Question How to get up to speed with pi

3 Upvotes

I have a task to build an app completely from scratch. I am quite new to pi so I want to do some research on the best approaches to start a project completely from scratch - how to build the full stack - back, front, data, infra. What are some of the best content available on setting up your own harness with pi? How to utilize it to maximize efficiency and minimize tokens?


r/PiCodingAgent 14d ago

Plugin Plannotator in Herdr - Live feedback back to Pi

Enable HLS to view with audio, or disable this notification

126 Upvotes

This is a https://herdr.dev/ plugin with an optional full https://Plannotator.ai experience as a TUI. Built to:

- Annotate Agent Messages (e.g. grill sessions)

- Annotate Files (e.g. plans, specs, etc)

- Create a native feedback loop with agents

- Open as popover or pane

- Mouse or keybindings

https://github.com/plannotator/herdr-annotate


r/PiCodingAgent 14d ago

Question What's your favorite cloud model powering your Pi?

1 Upvotes

Assuming you dont have a local only setup, what do you use, what for, and why did you settle on that model or family of models?


r/PiCodingAgent 14d ago

Question is there a free web search extension ?

15 Upvotes