Gateway · Routing · Terminal
One gateway.
Your AI stack, unified.
Claude Code, Codex and Gemini CLI each speak their own protocol. PHI translates in between, so a provider is set up once. Go direct or through a route group on rules you set, with the terminal in the same window.
macOS · Windows · Linux/Open source · MIT license
Let the middle layer handle protocols.
Claude Code speaks Anthropic Messages, Codex speaks OpenAI Responses, Gemini CLI speaks native Gemini; your provider may speak something else. PHI detects the protocol and passes it through or translates it, so each app doesn't need a separate connection per provider. The fifth is System One, a decision protocol built around questions and answers. It's on the way.
- Anthropic Messages
- OpenAI Responses
- OpenAI Chat
- Native Gemini
- System OneComing soon
Pass through or translate
Streaming output
- Anthropic Messages
- OpenAI Responses
- OpenAI Chat
- Native Gemini
- System OneComing soon
Same-protocol passthrough
When both sides speak the same protocol, requests pass through as they are; streaming, tool calls and usage fields are not rewritten.
Cross-protocol translation
Requests, responses and streaming events are translated to the target protocol; tool calls, reasoning content and token usage are preserved wherever possible.
Four chat protocols
OpenAI Chat Completions, OpenAI Responses, Anthropic Messages and native Gemini. Pick one for the entry point and one for the upstream; they don't have to match.
System One (coming soon)
A decision protocol: the request carries a state and a set of questions, and the reply is structured answers with probabilities. It keeps its own path through the gateway and is never rewritten into a chat request.
System One isn't available yet. Once it ships, it will appear in the provider protocol list. Before a cross-protocol setup, try a simple task to confirm tool calls and streaming. Gemini CLI currently accepts only a native Gemini upstream.
The apps you already use are in there.
Seventeen apps, one setup. Take over existing configuration or coexist with it; either way, one set of providers and routes.
Claude
Claude Desktop
Codex
Gemini
Grok Build
OpenCode
OpenClaw
HermesPi
MiniMax Code
Command Code
CrushDroid
Kimi Code
AtomCodeOmO
System One
System One is on the way; the other 16 apps work today.
Direct is simple. A route group carries more.
Each app can pin one provider, or put providers and models into a route group and let PHI pick by strategy. Members don't have to share a protocol or a model; the gateway translates as it forwards.
- Light gray dashes · configured topology
- Solid · completed
- Dashed · failed
- Dotted · unconfirmed
- Color · by app
-
One map, two layers
The light gray dashes are the configured topology, always there. The colored line is the latest request, and only the newest one stays. No jumping between a settings page and a log page.
-
Line style is the result
Color follows the app; line style shows the state: solid is completed, dashed is failed, dotted is unconfirmed. While a request is running, the line flows.
-
The map is the control panel
Click an app to set its route, click a group to change members and strategy, or create a group right here. Members are providers or models; groups stay one level deep.
The terminal opens right here.
Click “+” at the top right of an app page, or press ⌘T, pick a folder and go. PHI checks that the CLI is installed first. Nine apps open this way, including Claude Code, Codex and Gemini CLI, with your providers and route groups applied. Currently available on macOS 13+ only. If a CLI is missing, PHI shows installation guidance.
-
Settings and terminals, in tabs
Switch within the same app; change a provider, then run a command without opening another window.
-
Put sessions side by side
Two sessions of the same tool side by side: edit in one, check results in the other. Split top and bottom too.
-
Keep your preferred colors
Follow PHI's light or dark theme, or pick one of the built-in palettes.
-
Leave the tab. Keep it running.
Check usage or change settings on another page; the process keeps running.
-
A shell after your CLI exits
You come back to the same shell, with your working directory and output intact.
~/code/phi
$ claude
Launch a CLI in your project directory
> Look through the project, then help me add this feature
Switch tools. Your sessions stay put.
PHI already gathers the session records each tool keeps on this machine into one list: group by project, search, open the source, or copy a resume command. Next come cross-tool context and long-term memory: what you said in a project shouldn't need repeating from scratch.
Start in Claude Code, carry on in Codex.
Cross-tool context and long-term memory are still in planning; today's session browser only reads the records each tool keeps on this machine.
Settings, usage and data,
all in one place.
Manage providers, MCP, Skills and prompts in one place, then write them into configuration the way each tool expects. The gateway, route groups and CLIs in the terminal all read the same copy.
- Providers and keys
- Providers and models in one place, one click to switch. Subscription credentials go to the system keychain.
- MCP and Skills
- One list of servers and skills shows which apps they are installed in and whether they are enabled.
- Prompts
- Keep regular prompts in a library: copy them any time, or write them into project settings.
- Usage ledger
- Requests pass through the local gateway, and sessions, tokens, cost, cache hits and active time go into a local ledger. Follow daily trends, or use a weekday × hour heatmap to find your busiest hours.
- Local data
- PHI has no project-run cloud backend: configuration, session statistics and the usage ledger live on this machine in
~/.phi/. Subscription OAuth tokens go to the system keychain. Only when you use an online model does the CLI or local gateway connect to your chosen provider.
Start with an app you know.
You don't need to configure everything at once. Connect one app, then build out your workspace at your own pace.
Install PHI and your CLI
PHI manages and launches apps; install each CLI as its own docs say, or keep using the copy you already have.
Add a provider and choose a connection
Fill in a model service, then choose direct or a route group on the Routing page; pick a strategy for the group if you need one.
Open a project and get to work
Click “+” on an app page and pick a folder — on macOS 13+ the terminal opens right there — or open the project in your usual terminal.
A few things before you download.
Does PHI include models or free credits?
PHI is an open-source desktop tool and does not include model credits. Bring a provider API key or a subscription account your app supports; the provider bills for model usage.
What's the difference between direct and a route group?
Direct mode skips the gateway and keeps the app's existing connection to one provider. A route group puts several providers or models together, PHI picks one by strategy, and moves on when one fails. Members can use different protocols.
Where do my keys and requests go?
Main configuration and usage data stay on this machine; subscription OAuth tokens go to the system keychain. Through the local gateway, requests reach PHI first and are then forwarded to the provider you configured; in direct mode the app connects to the provider itself. Either way, request content and the credentials it needs go to the provider you chose.
Are unified sessions and long-term memory available now?
Session browsing works: records the tools keep on this machine land in one list, where you can view them by project or time, search, and copy a resume command. Continuous sessions across tools and long-term memory are still in planning.
Can I run CLIs inside PHI on Windows or Linux?
The built-in terminal currently requires macOS 13 or later. On Windows and Linux, use PHI to manage settings, connect models and track usage, and run CLIs in an external terminal.
How do I update or report a problem?
Choose “Check for updates” in the app, or visit GitHub Releases for the latest version. Report problems on GitHub Issues with your OS version, tool name and steps to reproduce. Remember to remove any keys.
Pick a platform and install.
Versions, architectures and downloadable files are listed on GitHub Releases.
All links above open the release page; downloads do not start automatically. You can also build from source