You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Native chat for third-party agents: pi (pi-coding-agent) adapter / public session-host contract #21558
Request native chat (structured session) support for third-party coding agents — concretely pi — or, more generally, a documented adapter contract for the session host that native chat already uses for Claude and Codex.
Why
Native chat has become the best surface in Orca for agent work: structured turns, tool rows, diff cards, session history, rewind, slash commands, mobile. Today it is closed to two first-party agent kinds (Claude via the Claude Agent SDK, Codex).
The session-host abstraction is already agent-agnostic in shape — Claude and Codex render through the same UI, there is one / picker for every agent, and orchestration can drive "native-born structured chat sessions". A documented adapter contract would let the ecosystem plug agents in instead of forking the TUI path.
pi is a strong first candidate because it ships an embedding SDK built for exactly this:
@earendil-works/pi-coding-agent → createAgentSession() with subscribable event streams (message_update / assistantMessageEvent.type: "text_delta"), programmatic session.prompt(), file-backed or in-memory session managers.
First-class resources: extensions, skills, prompt templates, themes, context files; multi-provider model registry via ModelRuntime.create().
Durable JSONL session transcripts that map naturally onto Agent Session History / resume.
Fully headless when driven via the SDK — no PTY/TUI required, matching the structured-session delivery path Orca already implements for Claude/Codex.
Ask
Document the session-host / structured-agent contract (launcher, turn events, tool progress, question/ask flow, session persistence) so third-party agents can target it.
Ideally, ship a pi adapter natively. Happy to help test on headless Linux (server runtime) plus Windows and macOS clients.
Following up on our own issue: we'd like to attempt this PR — adding pi to native chat's transcript-backed agents, alongside omp.
We've mapped the surface: native-chat-agent-support.ts (union + list + resolver), session-file-resolver.ts (pi's sessions root is ~/.pi/agent/sessions/<mangled-workspace>/), transcript-reader.ts/tail reader record mapping, and nativeChatRequiresLocalTranscript. We run pi heavily on headless Linux + desktop clients, so we can derive real-transcript fixtures and test e2e.
Two questions before we sink the time:
Is there in-flight work on pi native-chat support we'd collide with (omp landed recently — is pi queued behind it)?
Any design constraints we should honor for transcript-backed agents (e.g. how the composer send path is expected to work for them), or pointers to the right reviewer?
Happy to start with a small "resolver + reader + fixtures" PR if that's easier to review incrementally.
Pi now has structured native chat through its RPC mode as of #25851, thanks for pushing on this! If anything is missing or broken with it on a current build, feel free to reopen or file a follow-up.
Activity
havertonpropertygroup commentedon Sep 19, 2026
Following up on our own issue: we'd like to attempt this PR — adding
pito native chat's transcript-backed agents, alongsideomp.We've mapped the surface:
native-chat-agent-support.ts(union + list + resolver),session-file-resolver.ts(pi's sessions root is~/.pi/agent/sessions/<mangled-workspace>/),transcript-reader.ts/tail reader record mapping, andnativeChatRequiresLocalTranscript. We run pi heavily on headless Linux + desktop clients, so we can derive real-transcript fixtures and test e2e.Two questions before we sink the time:
pinative-chat support we'd collide with (omp landed recently — is pi queued behind it)?Happy to start with a small "resolver + reader + fixtures" PR if that's easier to review incrementally.
nwparker commentedon Sep 25, 2026
oh I see there's a PR I will have @brennanb2025 help out here
OrcaWin commentedon Oct 9, 2026
Pi now has structured native chat through its RPC mode as of #25851, thanks for pushing on this! If anything is missing or broken with it on a current build, feel free to reopen or file a follow-up.