How close to Pi are we?
PiSharp tracks compatibility separately from source updates. The historical assessment below retains its published-release baseline; the current 1.6.0 release and earlier 1.5.2 release are shown separately.
The historical assessment below uses the Pi v1.5.0 baseline, from PiSharp's own test suites and its compatibility inventories. Assessed on 5 November 2026 for release 1.5.0. "Ported" means it works and PiSharp's tests cover it. Some suites compare against output captured from Pi 1.1.0 itself, such as session files; the rest are authored tests. Released 1.5.0.1 coverage is listed separately below, preserving the original assessment and evidence pins.
PiSharp 1.6.0.1: Pi 1.6.0
The source target is faac5858. The exact-tag release workflow validates source, package contents and the required hosted gates before publishing all 29 packages. Results retain explicit suite and platform limitations and do not establish complete parity.
Review the complete source applicability map and release notes. See the publication evidence. Earlier assessment counts, captures and qualification records are preserved below.
Earlier release: PiSharp 1.5.2 (Pi 1.5.2)
The source of 1.5.2 is b4afdddf. The exact-tag release workflow validated source, package contents and the required hosted gates before publishing all 29 packages. Results retain explicit suite and platform limitations and do not establish complete parity.
Review the complete source applicability map and release notes. See the publication evidence.
Released 1.5.0.1: coverage and qualification
The tables below preserve the 1.5.0 assessment and its historical capture pins. Version 1.5.0.1 adds Chord v2 and legacy runtimes, native hosting, Durable.Store, Env and evaluation tooling, and closes reviewed provider, tool and lifecycle gaps. The four required hosted gates passed for immutable source 8144e3ea; release qualification also includes macOS checks, the three-platform WebAgent suite, validation of all 29 archives and a fresh external consumer of the five new libraries.
Read the release updates, the current source/test mapping and the publication evidence. Results retain explicit skips and tested-environment limits. Windows PTY remains unsupported; live providers, real SSH hosts, physical macOS keys, browser/Cloudflare exclusions and native runtime policy differences remain separate.
Does PiSharp do what Pi does? Same prompts, tools, ordering and results for the same inputs.
| Area | Status | Notes |
|---|---|---|
| Agent loop, steering and follow-ups | Ported | Steering and follow-up queues with both drain modes, parallel tool batches, abort and automatic retry. turn_end drafts and message_end replacements apply inside the running loop, as in Pi. Evidence |
| Built-in tools: read, write, edit, bash, grep, find, ls | Ported | Pi's declarations, arguments and errors. read returns images, decoded and resized with SkiaSharp. bash finds its shell as Pi does, with shellCommandPrefix and user_bash interception; without a shell it stays registered and each command fails with Pi's message, and a shell that can't start reports Node's spawn error. grep and find use rg and fd, downloaded on first use. Evidence |
| Providers and model selection | Ported | All 10 of Pi's chat APIs, including Bedrock, Codex and Copilot, all 42 provider catalogs and the llama.cpp router provider, each with a live route and /login. OpenAI Codex tries a WebSocket first and compresses server-sent-event requests with zstd, as Pi does. --model patterns, --models, --list-models (with extension providers), models.json and the startup catalog refresh work; with an OpenRouter key, the openrouter catalog lists only that key's models, with its limits and prices. models.json, keybindings and themes are validated with Pi's published schemas and TypeBox's messages. Azure resource names are taken as Pi takes them (decision 14). Difference: the websocketConnectTimeoutMs setting isn't read (the WebSocket gets 15 seconds). Evidence |
| Classifiers and image generation | Ported | OpenAI decisions (with image input), TypeSafe and Cloudflare system-one, llama.cpp decision models and log-probability classification, and OpenRouter images. Reachable from codemode, native extensions and TypeScript extensions, both of which can also register their own classifier and image providers. Evidence |
| CLI flags and print/JSON modes | Ported | Plain pisharp takes every flag in Pi's args.ts, with -p, --mode json|rpc, @file arguments and the install, remove, update, list, config, auth and mcp commands. -e loads packages with their skills, prompts and themes, and -e builtin:<name> a built-in extension; pisharp config switches the built-ins. Print mode recovers from a context overflow through auto-compaction and exits 0, as Pi does. pisharp update can't update PiSharp itself. Evidence |
| Sessions and branching | Ported | Sessions in ~/.pi/agent/sessions, --continue, --resume, --session, --session-id, --fork, --session-dir and --no-session, /name, /session, /fork, /clone, /tree, /resume, HTML export and /share. Session files are compared with files Pi 1.1.0 wrote for the same scripts, with Pi 1.2.0's text changes applied. Evidence |
| Compaction | Ported | Manual and automatic compaction and branch summaries, with Pi's summary retries, events and error texts. Automatic compaction is on by default in every mode and reads the compaction settings, including per-model overrides. Evidence |
| Slash commands | Ported | All 24 of Pi's built-in commands, with the same names, descriptions and arguments, plus /mcp and /llama from the built-in extensions. /bug builds Pi's local report and opens a prefilled PiSharp GitHub issue instead of uploading to Pi's developers. Evidence |
| Skills, prompt templates and context files | Ported | AGENTS.md and CLAUDE.md from the agent folder and every parent folder, SYSTEM.md and APPEND_SYSTEM.md, and skills, prompts and themes discovered from Pi's folders, settings, packages and -e, behind project trust. Evidence |
| Terminal UI, themes and keybindings | Ported | Pi's interactive mode on Windows, Linux and macOS: fullscreen and regular modes, every /settings item, the system, dark and light themes and custom theme files, keybindings.json, inline images, Mermaid and highlight.js highlighting. The footer's cost, tokens and context follow the session after every turn. On X11, pasting reads the clipboard through libxcb when xclip and xsel are missing, as Pi's helper does. Evidence |
| MCP | Ported | Stdio and HTTP servers, ~/.pi/agent/mcp.json and the trusted project .pi/mcp.json, OAuth with refresh locks, all exposure modes, resource tools, the 10-second wait for direct servers, a wait before each tool call for the servers it may reach, the mcp_servers prompt section, /mcp in every mode and pisharp mcp. MCP is a built-in extension that can be turned off. Difference: /reload keeps the servers connected and doesn't re-read mcp.json unless the mcp, codemode or tool-search built-ins changed; Pi reconnects on every reload. Evidence |
| tool_search | Ported | Pi's BM25 search, always registered and switched off as in Pi. It waits for background servers, and its prompt snippet is rendered. Evidence |
| Codemode | Ported | Pi's prelude, script API, store, models bridge and limits, on the Jint engine. Declarations show input constraints, and the row shows elapsed and total time. Codemode MCP servers connect. Intentional: each script runs in its own worker process (about 100 to 300 ms to start), its deadline starts when the script starts, and memory and recursion overruns end the script instead of throwing. Evidence |
Can PiSharp read and write the same files and speak the same protocol, so tools built for Pi keep working?
| Area | Status | Notes |
|---|---|---|
| Session file format: read | Ported | Reads JSONL v3 session trees and keeps unknown entries and fields. Lone surrogates are kept as JSON.parse keeps them. Records may nest 1,000 levels; V8 itself stops writing at about 1,700. Evidence |
| Session file format: write | Ported | Every line is the bytes JSON.stringify writes, in Pi's key order. Compared entry by entry with session files captured from Pi 1.1.0, with Pi 1.2.0's text changes applied. Evidence |
| Legacy session import | Ported | Pi's own v1 and v2 migration on open, and session copy and session migrate, which leave the original file unchanged. Evidence |
| JSON event stream | Ported | Every event Pi sends, including entry_appended, thinking_level_changed, extension_error, auto_retry_* and summarization_retry_*. agent_end carries willRetry, and agent_settled arrives before the response to the command that started the run. Evidence |
| RPC commands | Ported | All 33 Pi v1.5.0 RPC commands. A failed command answers with the error's message, thinking levels are clamped to the model, and the setters save the global settings.json, as in Pi. Under pisharp --mode rpc, bash runs in your shell with no extra options. Difference: get_session_stats fails on non-finite usage, where Pi reports null. Evidence |
| RPC extension UI | Ported | select, confirm, input, editor, notify, setStatus, setWidget, setTitle and set_editor_text requests, and their responses. Evidence |
| RPC framing and shutdown | Ported | Each line is read and written as rpc-mode.ts does, with lone surrogates kept and lines up to JavaScript's string limit. A line nested deeper than 1,000 levels is answered as a parse failure and the stream goes on. SIGTERM and SIGHUP shut down as in Pi. Evidence |
| Shared config files | Ported | settings.json, auth.json, models.json, mcp.json, mcp-auth.json, keybindings.json and trust.json in ~/.pi/agent (or PI_CODING_AGENT_DIR), and the project .pi folder. !command values run, as in Pi. Evidence |
Do Pi's TypeScript extensions and packages run unchanged? PiSharp runs them in Node with Pi's own npm packages, installed and verified on first use. Native C# extensions load from the same folders. The extension suite runs in the release pipeline with Node 22.
| Area | Status | Notes |
|---|---|---|
| Loading your own extensions | Ported | Discovered from ~/.pi/agent/extensions, .pi/extensions (after project trust), settings, packages and -e, as in Pi. Pi's built-in extensions (mcp, llama.cpp, codemode, tool-search) can be turned off or replaced. Needs Node.js 22.13 or later; Pi asks for 22.19. Evidence |
| Pi's npm packages | Ported | pi-coding-agent, pi-ai, pi-tui and pi-agent-core 1.2.0 are installed with your npm, checked against the registry's integrity, and loaded through Pi's jiti. Intentional: 1.5.0 keeps them on Pi 1.2.0 (see Extension Node runtime). Offline, or without npm, extensions fall back to built-in copies with a warning. Evidence |
| ExtensionAPI | Ported | Every member: tools, commands, shortcuts, flags, providers (chat, classifier and image), virtual models, MCP servers, ctx.ui.setTheme and the event bus. Evidence |
| Event hooks | Ported | Every v1.5.0 extension event reaches TypeScript handlers, including before_agent_start for runs a custom message starts. sendMessage with triggerTurn starts its turn at once, inside a command or from a timer, as in Pi. Evidence |
| Custom TUI components and renderers | Ported | ctx.ui dialogs, widgets and custom components, registerMessageRenderer and registerToolRenderer, in the terminal UI and over RPC. Evidence |
| Packages | Ported | pisharp install, remove, update, list and config for npm, git and local sources, global or project (-l), with Pi's trust rules. Evidence |
| Native C# extensions | Ported | A folder with a pisharp-extension.json loads from the same places as Pi extensions, without Node, and shares the session and command list with TypeScript extensions. All 41 v1.5.0 events reach native handlers, native extensions can register classifier and image providers, and a C# extension that registers codemode, tool_search or /mcp replaces the built-in extension with the same warning as a TypeScript extension. Evidence |
Published 1.5.0 differences
This historical list describes release 1.5.0. Resolutions in 1.5.0.1 are summarized above and in the current mapping; retained entries are not claims that all these gaps remain in the current release.
Intentional
Differences kept on purpose.
- No telemetry. PiSharp doesn't report installs to Pi's servers. PI_TELEMETRY and enableInstallTelemetry are accepted and ignored. PiSharp.Telemetry, Pi's telemetry contract from 1.5.0, records spans only for a host that passes one and has no exporter.
- Startup header. The header says PiSharp with PiSharp's own version (for example v1.1.0.3), where Pi shows its package version.
- User agents. Chat requests send Pi's detailed user agent for the Pi version PiSharp tracks, pi/1.5.0 (<platform>; dotnet/<version>; <arch>), naming .NET where Pi names Node. Bedrock sends pi/1.5.0 alone, media requests send PiSharp, and the NuGet update check sends pisharp/<version>.
- No attribution. Pi attributes OpenRouter, NVIDIA NIM and OpenCode requests to pi (https://pi.dev) while install telemetry is on, and pi-agent-core does by default. PiSharp sends no attribution headers, whatever enableInstallTelemetry says (owner decision, 2026-11-05). OpenCode requests with a session carry x-opencode-client: pisharp.
- MCP client registration. oauth.clientRegistration defaults to auto, as in Pi 1.5.0. PiSharp's auto always registers a client dynamically, as Pi's does in a rebranded build, so it never presents Pi's Client ID Metadata Document on pi.dev. An explicit cimd still presents it, as in Pi.
- Extension Node runtime. TypeScript extensions run against Pi 1.2.0's npm packages, with undici overridden to 8.12.3 as Pi 1.5.0 pins it, because Pi 1.5.0's pi-agent-core attributes agent requests to Pi by default. Installed extensions therefore see Pi 1.2.0's pi-ai.
- Codemode worker. Each script runs in its own worker process, so one script can't take PiSharp down. That costs about 100 to 300 ms per script. The deadline starts when the script starts running, not when the worker launches.
- Jint limits. Codemode runs on Jint, not QuickJS. Memory and recursion overruns end the script instead of throwing a catchable error, and the engine's own error messages differ.
- /bug opens a GitHub issue. /bug builds Pi's report and zip but never uploads them to Pi's developers. It opens a prefilled issue at github.com/jkelly/PiSharp for you to attach the zip to.
- Version check on NuGet. The update check looks up the latest PiSharp.Cli on NuGet and suggests dotnet tool update -g PiSharp.Cli. It never asks pi.dev.
- Self-update. pisharp update updates packages and catalogs. It updates PiSharp itself only through your own command (PI_SELF_UPDATE_COMMAND or selfUpdateCommand, as in Pi 1.5.0), which it runs when NuGet has a newer PiSharp.Cli, or with --force. Without one, update with dotnet tool update -g PiSharp.Cli.
- pisharp durable. An experimental, PiSharp-only command (decision 0005), listed in pisharp --help with pisharp session. Pi v1.1.0 ran its durable agent from source and Pi v1.2.0 removed it, so Pi's help has neither line. From 1.2.0.2 it also has --help, questions, plan mode and the media tools, and pisharp durable serve, token and the device commands (decision 0008), which pisharp durable help lists and pisharp --help doesn't.
- Service tiers. --tier (alias --service-tier), /tier, the tier in the footer and the serviceTier setting are PiSharp's, experimental from 1.2.0.2 (decision 0007). Pi has no service tiers. Without a tier, requests and the footer are as in Pi.
Still open
Differences that remain to be fixed or decided.
- /reload and MCP. /reload keeps MCP servers connected, and doesn't re-read mcp.json, unless the mcp, codemode or tool-search built-ins changed. Pi reconnects every server on every reload.
- JSON depth 1,000. Session records, RPC input and other JSON values hold 1,000 levels of nesting. Pi's JSON.parse has no limit, though V8's JSON.stringify gives up at about 1,700 levels, so Pi can't store deeper values either.
- Explicit session verbs. The pisharp session … and rpc verbs keep their byte bounds (64 MiB session lines and files, 32 MiB RPC records, 8 MiB tool results) and refuse lone surrogates. The Pi command line has neither limit. Provider request bodies stay limited to 64 MiB, and single request entries to 16 MiB, everywhere.
- write size. One write call's arguments hold up to 8 MiB of JSON, so a call writes a little under 8 MiB of plain text. Pi has no limit. Write a larger file in parts. PiSharp 1.2.0.1 and earlier stop at 64 KiB.
- Non-finite usage. get_session_stats fails when a session holds non-finite usage numbers, where Pi reports null.
- TypeScript tool reach. A TypeScript tool that declares reachesTools reaches every tool, so its calls wait for every MCP server. Pi asks the tool which servers a call may reach.
- Codemode row clock. The plain codemode row that native renderer hosts get shows the total time once a script finished, but no live elapsed time. The interactive mode shows both.
- WebSocket connect timeout. The websocketConnectTimeoutMs setting isn't read. The Codex WebSocket always gets 15 seconds to open, Pi's default.
- Azure resource names. Any resource name is taken as Pi takes it (decision 14). A name that leaves credentials, a fragment or a query in the URL, or a host .NET can't hold (such as one with $ or an empty label), is refused when the session starts; Pi fails only when it sends the request.
- Models-level identity. Identity travels on each request. Pi 1.5.0's Models-level default identity (createModels({ identity })) isn't ported.
- Responses tool changes. Responses, Codex and Azure additional_tools and tool search, which Pi 1.5.0 can send, aren't implemented. Azure refuses those flags.
- Classifier settings. The CLI's classifier registry reads only the built-in catalogs, so a models.json baseUrl or compat doesn't reach classifier calls, as it does in Pi 1.5.0.
- Streaming copies. Mistral still writes a full message snapshot per frame, pi-messages capture still copies its partials, and Anthropic and Completions rebuild their failure-path partials, where Pi 1.5.0 streams them incrementally.
- pi.exec() capture. Native pi.exec() captures at most 1 MiB per pipe, whatever maxBuffer says. The Node bridge honours maxBuffer in full.
- Session write failures. After a write that may have reached the file, a native session faults and accepts no more writes. Pi 1.5.0 rolls the entry back and keeps writing. Whether PiSharp follows is open.
- Overlay handles. An overlay's onHandle and overlayOptions.visible aren't forwarded from Node extensions.
- Shift+Enter on macOS. Pi 1.5.0 treats ESC+CR with Shift held as Shift+Enter. PiSharp does on Windows, but can't read the Shift state on macOS, so it isn't detected there.
- tool_search word splitting. Text without spaces is split into words by the system's ICU, which can differ from V8's. Without ICU it stays one word.
Roadmap
Full plans on GitHub- Phase 1Freeze the compatibility targetPartial
Pinned to Pi v1.5.0, with the command, RPC and event inventories refreshed. Release profiles (P1-04) are still open.
- Phase 2Provider layerPorted
All 10 of Pi's chat APIs, 42 provider catalogs, the llama.cpp router, logins, classifiers and images, and the Codex WebSocket transport with zstd.
- Phase 3Agent loop and toolsPorted
Loop, all built-in tools with images, codemode and tool_search.
- Phase 4SessionsPorted
Pi's session folder and format, byte for byte, with branching, compaction, export and sharing.
- Phase 5Headless RPC, then terminal UIPorted
Pi's command line, print, JSON and RPC modes, and the interactive UI with every slash command.
- Phase 6Native extension SDKPorted
C# extensions load from Pi's extension folders. All 41 events reach native handlers, and native extensions register classifier and image providers.
- Phase 7Optional Node bridgePorted
Runs any Pi extension and package on Pi's own npm packages.
- Phase 8Hardening and packagingPartial
The release pipeline runs 22 offline suites on Linux, including the extension suite with Node, the two durable suites, the custom agents suite, and the schema and telemetry suites. Platform and security qualification are open.
- Phase 91.1.0.x gap releasesPartial
tool_search shipped in 1.1.0.1 and the rest of Pi v1.1.0 in 1.1.0.2. 1.1.0.3 fixes issue #5 and closes most of the differences 1.1.0.2 left open; 1.1.0.5 names PiSharp in the startup header and fixes lone surrogates in compaction estimates; 1.1.0.6 is tested on macOS arm64 and fixes what that found; 1.1.0.7 fixes stdin commands hanging on Apple Silicon and makes the settings and trust locks exclusive.
- Phase 10Pi 1.2.0 syncPartial
Every Pi 1.2.0 change in scope is ported with tests (sync-1.2.0-applicability.json), except per-input reach for TypeScript tools and the live clock of the plain codemode row. 1.2.0.1 adds the experimental durable port, and 1.2.0.2 PiSharp-only experimental media, service tiers, custom agents and the durable device server on the same baseline.
- Phase 11Pi 1.5.0 syncPartial
1.5.0 ships phases 0 to 4 of the sync and its close-out: every row they need is ported, ported with a deferral, already in PiSharp or a no-op (sync-1.5.0-applicability.json). 19 rows keep a deferral; the ones outside durable and Chord are listed under Still open. pi-env, the rest of Chord and pi-evals follow as experimental 1.5.0.x patches.
- Phase 12Experimental durable portPartial
1.2.0.1 ships pisharp durable and the PiSharp.Durable, PiSharp.Durable.Tools and PiSharp.Durable.Sqlite packages as experimental: a port of pi-durable v1.2.0 whose every upstream file is ported or recorded as excluded (decision 0005, durable-port-map.json). Open: JSONL storage keeps its records in memory, and code mode scripts interrupted under Pi or PiSharp don't resume in the other. 1.2.0.2 adds PiSharp-only questions, plan mode, media tools and a device server (decisions 0005, 0007 and 0008), which pi-durable doesn't have. 1.5.0 moves the libraries to pi-durable v1.5.0 (decision 0013): 1.2.0.x can't open what 1.5.0 writes, no session written by pi-durable v1.5.0 has been compared yet, and Chord v2's host and durable on its store wait for 1.5.0.x.
- Phase 131.5.0.1 gap releasePorted
Released on the unchanged Pi 1.5.0 baseline: Chord v2 and legacy, native hosting, Durable.Store, Env/daemon, Anthropic threads and evaluations. Published inventory: 28 libraries plus the CLI. Exact-source Core/Durable/gap/native gates, macOS and three-platform WebAgent qualification, validation of all 29 archives and a fresh external consumer of the five new libraries passed at 8144e3ea. Experimental APIs, explicit skips and environment limits remain. This does not claim complete upstream parity. Evidence: AI_DOCS/release-1.5.0.1-publication-results.md.