CLI tool
Dicklesworthstone/pi_agent_rust avatar
Dicklesworthstone/pi_agent_rust

pi_agent_rust: a Rust coding agent CLI where the licence badge and the repository metadata disagree

High-performance AI coding agent CLI written in Rust with zero unsafe code

1,741 stars205 forksRustNOASSERTION

At a glance

What is it?
pi_agent_rust is a from-scratch Rust port of Mario Zechner's Pi Agent, built on two purpose-built libraries and shipped as a single binary called pi. The README describes a capability-gated extension model and a benchmark policy that refuses to publish numbers until evidence artifacts pass a gate, but it also states the project is no longer a drop-in replacement for legacy Pi, and the repository carries a NOASSERTION licence despite a badge reading MIT + Rider.
Who is it for?
Adopt pi_agent_rust if you want a single-binary coding agent with an explicit extension trust lifecycle and you are willing to build it through DSR rather than Cargo. Do not adopt it if you need a stable drop-in replacement for legacy TypeScript Pi, or if a NOASSERTION licence blocks your legal review.
Can I use it commercially?
Check first. The repository uses a licence we do not classify automatically, so read its LICENSE file before any commercial use.
Is it still maintained?
Yes. The repository received new commits within the last day.
What is it written in?
Mainly Rust, according to GitHub's language statistics.

Answers come from the project's GitHub data, last synced on September 15, 2026, and from our analysis. They are not legal advice.

DEEP OPEN-SOURCE ANALYSIS

The problem pi_agent_rust claims to solve, and who the README is written for

The README opens with a four-item complaint about existing terminal coding assistants: slow startup, resource-heavy runtimes, unreliable streaming and session state, and extension systems that are closed or complicated. pi_agent_rust positions itself against all four. The stated answer is a native single binary named pi, a from-scratch Rust port of Pi Agent by Mario Zechner, made, in the README's words, with his blessing. The intended audience is narrow and stated plainly: people who already use Pi Agent, especially through OpenClaw. The TL;DR section is addressed to them by name. That matters for evaluation, because the project is not pitched at someone shopping for a first coding agent. It is pitched at someone with an existing Pi or OpenClaw workflow who wants the same workflow on a different engine. The README then undercuts that framing in a section titled Current product direction, which says the project is no longer trying to be a strict drop-in replacement for the legacy TypeScript Pi and that legacy Pi is not the compatibility authority. So the migration pitch and the product direction pull in opposite directions, and a reader deciding whether to switch should treat the second statement as the binding one.

Two purpose-built libraries sit under the CLI

The port is not a line-by-line translation. The README says it builds on asupersync, described as a structured concurrency async runtime with built-in HTTP, TLS, and SQLite, and rich_rust, a Rust port of Will McGugan's Rich that provides terminal output with markup syntax. Those two choices explain most of the architecture visible in the material. asupersync supplies the runtime, the network stack and the storage layer, which is why the project can claim a single binary without a managed runtime. The README ties structured concurrency to more predictable cancellation and lifecycle behaviour, which is the part that matters for long sessions: cancellation semantics are a runtime property, not something the agent layer bolts on. rich_rust handles rendering. The README mentions an illustration file in the repository root and a badge row, and rich_rust's markup syntax is the likely path for the terminal output, though the README does not document the rendering pipeline in detail. What is absent from the material is any description of how the agent loop itself is structured, how model responses are parsed into tool calls, or how the 36 built-in tools are dispatched. The README gives the counts and the dispatcher name (xdev) and stops there. That is a real gap for anyone evaluating the agent core rather than the runtime.

Extension execution: capability gates, command mediation, and a kill switch

The most concrete design material in the README is the extension security model, and it is specific enough to reason about. Hostcalls are capability-gated across tool, exec, http, session, ui and events. Extension exec goes through two stages: a capability policy check first, then command mediation that the README says blocks critical shell classes by default, naming recursive delete, disk and device writes, and reverse shell. Under a strict or safe policy, mediation can tighten further to block high-tier classes. The README also mentions DCG and heredoc AST signals, which suggests the guard inspects shell structure rather than matching strings, and specifically that it is meant to catch destructive payloads hidden in multiline wrappers. Separately, each extension moves through a trust lifecycle of pending, acknowledged, trusted and killed, with kill-switch audit logs and operator provenance, so a quarantine records who pulled the switch and why. There are also hostcall lane kill switches, named in the README as forced_compat_global_kill_switch and forced_compat_extension_kill_switch, which force compatibility-lane execution globally or for one extension. That is a containment control, not a disable switch. A hostcall reactor mesh with shard affinity, bounded SPSC lanes, backpressure telemetry and optional NUMA slab tracking is described for runtime predictability. Cold owner-isolated JS realms and a persistent transpile cache are mentioned, with the note that each reload gets a fresh realm while versioned disk-cached transpilation avoids treating mutable JavaScript state as durable. The README's own table is the clearest statement of intent here, and it is unusually candid about failure modes: fast-path regressions are the scenario the lane kill switches exist for.

Installation, commands, and the DSR-only build rule

Installation is a single shell command from the README: curl -fsSL "https://raw.githubusercontent.com/Dicklesworthstone/pi_agent_rust/main/install.sh?$(date +%s)" | bash. The cache-busting query string is deliberate. Official release archives install the single end-user binary pi. Three commands appear in the README: pi "Help me refactor this function to use async/await" starts a session, pi --continue resumes a previous one, and pi -p "What does this error mean?" < error.log runs single-shot with no session and reads stdin. The README also shows a --tools flag with a default list and states that 36 tools are built in, 19 in the default --tools list, 14 always present in the model's schema, and the remainder reachable through the xdev dispatcher or enabled in settings. Those three numbers do not obviously reconcile, and the README does not explain the overlap, so treat the counts as approximate until you check the schema yourself. The build path is the part most likely to surprise a Rust developer. The README states that all repository quality checks, builds and releases run through Doodlestein Self-Releaser, that contributors must not invoke Cargo or RCH directly, and that GitHub Actions is never an execution or evidence authority for the project. The registered quality recipe is dsr quality --tool pi_agent_rust, and build and release commands are documented in docs/releasing.md. If your workflow assumes cargo build, this project tells you not to use it.

The benchmark policy is a gate, not a number

The README has a section on benchmark methodology and claim integrity, and the honest reading is that it publishes no performance numbers at all. Release-facing performance figures are published only when checked-in evidence artifacts are current, carry matching run provenance, and show data and a passing result for every declared budget with no data-contract failures. Historical snapshots exist in planning and evidence artifacts but are explicitly not treated as current README claims until the gate is regenerated cleanly. So the README asserts that a native single-binary design is intended to minimize startup and runtime overhead, and simultaneously declines to quantify it. Both halves of that are worth taking seriously. The refusal to publish stale numbers is a better signal than a stale number would be. But it also means a reader has no performance evidence in the material at all, and any claim about how pi compares to a managed-runtime agent on startup time is unverified. If startup latency is your reason for considering this project, you would need to build it and measure, which brings you back to the DSR requirement.

Where pi_agent_rust is the wrong tool

The clearest limitation is stated by the project itself: it is not a drop-in replacement for legacy TypeScript Pi, and legacy Pi is not its compatibility authority. The README says the closer reference for where the product is going is OMP, for feature surface, agent workflows, look and feel, and UI/UX, while the implementation still chooses Rust-native architecture and may intentionally differ from both. For an OpenClaw user whose extensions depend on legacy Pi behaviour, that is a migration risk the README does not resolve. Historical drop-in and parity artifacts remain in the repository as records but do not gate releases or user-facing claims, which means parity is not a promise you can hold the project to. The second limitation is the build policy. A project that forbids direct Cargo invocation and treats GitHub Actions as not an execution authority is a poor fit for a team that needs to build from source inside its own CI with standard Rust tooling. The third is licence. The repository metadata reports NOASSERTION while the README badge reads MIT + Rider. Rider is not a licence identifier this material explains, and the discrepancy is unresolved. The fourth is documentation depth: the agent loop, tool dispatch and model integration are not described, so anyone whose questions are about the agent rather than the runtime will not find answers here.

The alternative: legacy Pi, and why the difference is architectural

The README names the alternative directly. Legacy Pi is the TypeScript implementation by Mario Zechner that this project ports, and it remains useful historical context. The difference in approach is not feature parity but the engine underneath. Legacy Pi runs on a managed JavaScript runtime; pi_agent_rust runs on asupersync, a Rust async runtime with HTTP, TLS and SQLite built in, and renders through rich_rust rather than a JavaScript terminal library. That changes what the extension model can enforce. The capability-gated hostcalls, the two-stage exec guard with command mediation, the pending to acknowledged to trusted to killed trust lifecycle, and the lane kill switches are all described as properties of the Rust runtime, and they are the kind of control that is harder to guarantee when extension code shares a runtime with the host. The trade is compatibility. You get enforcement and a single binary; you give up the guarantee that existing Pi extensions and workflows behave identically. The README's own framing, that OMP is the closer reference for where the product is going, tells you the project is steering toward a different target rather than converging on the one it started from.

Maintenance, release cadence, and the licence question to settle first

The release history in the repository metadata shows v0.1.22 in July 2026, v0.1.23 later that month, and v0.3.0 in August 2026, with the last push in September 2026. The jump from 0.1.x to 0.3.0 within roughly a month, alongside the README's statement that drop-in parity no longer gates releases, is consistent with a project still moving its own target. The version number is a minor-version series, so expect interface churn. Maintenance cost is dominated by the DSR requirement rather than by Rust dependencies: quality checks, builds and releases all route through Doodlestein Self-Releaser, and the canonical commands live in docs/releasing.md. A team that wants to vendor, patch or rebuild this project inherits that toolchain. On licensing, the material is contradictory and this is not legal advice: the repository metadata reports NOASSERTION, the README badge reports MIT + Rider, and the README's own badge markup is the only place Rider appears. Before adopting, confirm which licence actually applies to the code you would ship, and note that the install script is fetched from the main branch with a timestamp query string, so what you install is whatever main holds at that moment rather than a pinned release artifact.

Editorial conclusion

Adopt pi_agent_rust if you want a single-binary coding agent with an explicit extension trust lifecycle and you are willing to build it through DSR rather than Cargo. Do not adopt it if you need a stable drop-in replacement for legacy TypeScript Pi, or if a NOASSERTION licence blocks your legal review. Before anything else, run dsr quality --tool pi_agent_rust and resolve the licence question, because the README badge and the repository metadata do not agree.

Official sources

  1. Dicklesworthstone/pi_agent_rust on GitHub
  2. Issues
  3. README
  4. Releases
Community notes

Community notes