Hub
The hub links your boxes, cleans their disks, and keeps your pack secrets. Turn on recovery, and threads go on after a usage limit.

Watch it work
How it works
- A thread hits a usage limit
- The hub asks the provider
- The provider answers
- The thread continues
Workflows
Disk watch
On with the packThe hub cleans a devbox whose disk runs low with hedge prune and each tool's own cache cleaner, and names the largest folders only when that cannot free enough.
Read before you turn it on
The sweep deletes only this. Through hedge prune: worktrees idle for 6 hours, or 24 when no T3 thread or agent owns them, whose commits are on the default branch or in a merged pull request, whose T3 thread is closed, or whose agent has been idle for a day. Their commits stay on their branch, but their lockfile and tool output changes are dropped. Also worktree folders that Git no longer tracks and no open T3 thread uses. Itself: the oldest part of a T3 boot log over 100 MB. Through pnpm store prune, uv cache prune and go clean -cache: caches those tools fill again. It never runs Nix garbage collection and never removes Cargo build output, the uv cache folder, old T3 versions, Docker data or Bun's cache, which projects can link into. It deletes no other file. For the rest, you decide.
Hub links
On with the packThe hub keeps SSH tunnels and T3 links to every devbox open, so each one can start threads on the others.
Own-account balancing
Off until you turn it onThe hub holds your own Claude or Codex subscriptions in a local proxy, and Claude Code and Codex on the hub, your devboxes, and boxes go through it, spending the Claude subscription whose weekly quota resets first.
Read before you turn it on
On the Claude and both plans, the hub keeps your Claude sign-ins in CLIProxyAPI, and every machine in the workflow sends Claude Code through it. On the Codex and both plans, it keeps your ChatGPT sign-ins there, and every machine sends Codex through it. The balancer ranks only Claude subscriptions by reset date. Read Anthropic's terms first, and OpenAI's terms for your plan too. As read on 2026-11-05: the Anthropic Usage Policy, effective Nov 12, 2026, section "Do Not Abuse Our Platform" (https://www.anthropic.com/legal/aup), lists: "Resell, proxy, or otherwise provide access to Claude through unauthorized means, including services that route requests through consumer subscriptions or misrepresent the product or client being used". The Anthropic Consumer Terms, effective Oct 8, 2025, section 2 (https://www.anthropic.com/legal/consumer-terms), say: "You may not share your Account login information, Anthropic API key, or Account credentials with anyone else. You also may not make your Account available to anyone else." Section 3, item 7 of the same terms lists: "Except when you are accessing our Services via an Anthropic API Key or where we otherwise explicitly permit it, to access the Services through automated or non-human means, whether through a bot, script, or otherwise." Balancing is only for your own subscriptions, never for someone else's.
Proxy panel
Off until you turn it onThe hub's proxy serves its management panel on loopback, with quota history, drain forecasts, and buttons that spend a subscription's banked weekly or Fable reset.
Read before you turn it on
The panel can change the proxy's settings and subscriptions, and spend banked resets, which do not come back. It also turns on CLIProxyAPI's plugins, so anyone with the management key can install and run other plugins from CLIProxyAPI's plugin store on the hub; hedge cli-proxy doctor fails on any plugin besides Hedge's pinned quota-ledger, and hedge apply then keeps Claude Code and Codex on the hub off the proxy. It listens only on the hub's loopback port 8317, which the SSH tunnels also carry to your devboxes and boxes, and it asks for the management key, which stays on the hub. Every tunnelled client reaches the proxy as 127.0.0.1, so 5 wrong sign-ins from any machine ban 127.0.0.1 from the management API for 30 minutes. That also stops the hub's balancer and hedge cli-proxy doctor until the ban ends. Hedge does not route it through the hub's HTTPS.
Provider recovery
Off until you turn it onThreads that stop on a usage limit or a provider outage continue by themselves once the provider answers again.
Read before you turn it on
Sends continue messages to stopped threads without you in the room, and starts an alert thread in the hub's thread folder.
What it costs
You need one devbox that stays on, and some setup on it. Every other machine keeps working when the hub is down.
Know before you turn it on
The hub holds sign-ins for your MCP servers and reaches every devbox over SSH. Keep it as private as your laptop.
Settings8 settings that your agent asks about
hub.aliasWhat is the SSH name of your hub, the always-on devbox that manages the others, such as my-hub?hub.diskSweepGigabytesBelow how many free gigabytes does the hub clean a devbox's disk?Default:15hub.diskAlertGigabytesBelow how many free gigabytes after a cleanup does the hub tell you?Default:10hub.httpsHostWhich private host name does a browser on your own computer use to open the hub's sign-in pages over HTTPS, such as hub.internal.example.com? Devboxes always reach the hub through their SSH tunnels. Leave it empty to skip HTTPS.hub.relayPortWhich port on the hub do the SSH tunnels from your devboxes use?Default:60001hub.threadFolderWhich folder do the hub's threads start in, such as ~/notes? The hub starts its disk alerts there. Hedge adds it as a T3 Code project when T3 does not know it yet.Default:~hub.proxyAccountsHow many of your own subscriptions should the hub's proxy hold? Below that, hedge doctor shows a To do line, and nothing fails. They are Claude subscriptions, or Codex ones on the Codex plan.Default:2hub.proxyHistoryDaysFor how many days does the proxy panel keep the quota history behind its charts and drain forecasts?Default:35
Add Hub to your Hedge
Paste this prompt into a T3 Code thread on a machine that runs Hedge.
Your install prompt
Add this Hedge pack to my setup with me: Hub. Hedge runs on my hub and my nodes in the cloud, not on my Mac. Run each command of this prompt on the hub, over SSH with the `PATH` line of https://raw.githubusercontent.com/PostHog/hedge/main/SETUP.md when you run elsewhere. Install nothing from Hedge here. Ask me each choice with your question tool, and run every command yourself. 1. Find my hub. List my cloud boxes as step 1 of https://raw.githubusercontent.com/PostHog/hedge/main/SETUP.md does, and run `hedge hub status` over SSH on each one that runs, until one names the hub. Do not ask a `hedge` on this Mac: an earlier setup can leave one here. The name after "The hub:" is the SSH name of the hub. In each SSH command of a note, put that whole name in place of the host that holds `<hub>`. When every box prints "The hub: not named", or no box runs Hedge, I have no hub yet. Tell me, and offer to set one up first with steps 5, 7, and 9 of https://raw.githubusercontent.com/PostHog/hedge/main/SETUP.md. To make a box that already runs Hedge the hub, skip step 5 for it. 2. Run `hedge update` on the hub, so it has the newest engine and packs. Then run `hedge packs` there, and leave out each pack that is already on. 3. Read the setup note of each pack. Ask me what it asks, and collect the flags that it names. Where a note names "the setup command" or "the command in item 2 of step 9", use the `hedge packs` command of this prompt. Do not run a step that a note puts after that command yet. - Hub: ~/.local/share/hedge/engine/packs/hub/SETUP.md 4. Turn the packs on with one command on the hub, and add the flags that the notes name: hedge packs --add hub 5. Do the steps that each note puts after the command. 6. Run `hedge doctor` on the hub, and explain each line. Do each `To do:` line with me, and say what a sign-in is for before it opens. 7. My nodes take the change at their next `hedge update`. To give it to one now, run `hedge update` there.