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

Workspace illustration. CLI appearance depends on the version you install.

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.

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.

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.

Latest request Routing flow
Apps PHI Route group Provider · Model
Codexgpt-6.1-sol · 20:58:52
ClaudeIdle
Claude DesktopIdle
Grok BuildIdle
OpenCodeIdle
OpenClawIdle
Show 11 more apps
PHI 17 apps
+ New route group
Primary routeLeast used first · fail over automatically
Provider Aclaude-sonnet
Provider Bgpt-6.1-sol
Provider Cgemini-2.5-pro
Provider Dglm-5.3
  • Light gray dashes · configured topology
  • Solid · completed
  • Dashed · failed
  • Dotted · unconfirmed
  • Color · by app
Illustration: light gray is the configured topology; color is the path of the latest request. While a request is running, the line flows.

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.

Interface illustration. The terminal is rendered by Ghostty.

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.

  1. 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.

  2. 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.

  3. 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