Small enough for one GPU, with approvals small enough for a phone.
A Python/FastAPI service and mobile web UI for running local and hosted AI agents from one place, with Docker sandboxes, scoped API access, and approval workflows I can answer from my phone.
Python
FastAPI
Docker sandboxes
Local inference
Who it’s for
Me first: someone who wants to start coding agents from a phone and watch every session in one place. The agents run on a home GPU server, either against a local open-weight model (Qwen3.6-35B-A3B on llama.cpp) or through a Claude Code, Codex or Cursor subscription.
It is a public repo with installers and docs, so anyone with similar hardware can run their own.
The problem
I built it because the big labs’ agent apps have an uneven mobile experience and remote sessions kept breaking. I wanted one place to track every session, with a fallback when a provider’s usage pool runs low.
While I tuned it for local models, I found that a smaller system prompt and a tighter context budget made it faster than popular open-source harnesses.
Constraints
One consumer GPU. A single 16 GB card has to serve agent sessions, external API requests and image generation. The benchmark ran on an RTX 4070 Ti Super with a 32K context.
Slow prompt processing. The default model decodes at about 70 tokens a second regardless of context, but a cold 29K-token prompt costs about 33 seconds, so wasted context is expensive.
Phone-first approvals. Anything risky has to be approvable from the lock screen, without logging in to anything.
Sandboxed sessions. Every tool call runs in a sandbox, and each session’s work arrives as a git branch to review and merge.
Subscription-agnostic. The local model and the unmodified vendor CLIs have to look the same to the clients.
Decisions and tradeoffs What was chosen, what was passed on, and what it costs
Approvals answered from a phone
Chose
A push notification with Approve and Deny buttons. Each button carries a random per-approval secret, so the notification app needs no login to the daemon. A decided notification is replaced in place, using the approval id as its sequence id.
Passed on
Making the phone sign in to the web app before it can decide anything.
Cost
The token is a bearer secret. It only decides that one approval and is never returned by the API or written to transcripts, but whoever holds it can answer. A session also stops until someone answers, though it gives up the GPU while it waits.
The sandbox is the boundary, the policy is a usability gate
Chose
One long-lived container per session on an internal network with no route out. Only an approved network: true command temporarily attaches an egress network, and git work that needs credentials runs on the host, where the agent can’t reach it.
Passed on
Relying on the approval policy alone to keep a command from doing damage.
Cost
Every session pays for a container, and network access needs an approval. The Phase 1 notes also record that while the egress network is attached, the host and local network are reachable too.
Our own agent loop, with a smaller prompt and a tighter context budget
Chose
Build the loop instead of wrapping an existing harness. On the same task, the native system prompt was 1,109 characters for Agent Harness against 9,530 for OpenCode and 35,610 for OpenHands. At 32K context the loop masks old tool output at 55%, resets the round at 60% and summarizes at 65%. It compacts only before a model call, so a final answer is never summarized away.
Passed on
Wrapping OpenCode as a building block. It matched the baseline’s accuracy, but it was about 1.7 times slower with Qwen and failed one task when compaction replaced a correct answer.
Cost
I own the loop, its compaction and its crash recovery. The sessions, clients and approvals around it had to be designed anyway, but the loop is more code to maintain.
A session holds the GPU for its whole run
Chose
One model slot per session, released only while it waits on a human or an app. One lock arbitrates agent turns, external /v1 requests and image jobs.
Passed on
Interleaving sessions per generation, which would evict the model server’s prompt cache.
Cost
Sessions queue behind each other, and an image batch swaps the language model out for its duration.
How it was built
server · one daemon, many front ends
Clients installable PWA, CLI, Python SDK and third-party apps
Versioned REST APIs app, owner and an OpenAI- and Anthropic-compatible inference endpoint
Agent loop crash-resumable; every step is saved to SQLite before the next
Approval policy allow, ask the owner, or deny
Docker sandbox one per session, no route out unless approved
one GPU · the loop asks the scheduler for the model
GPU scheduler one gate for agent turns, API requests and image jobs
Local model or image models the language model sleeps after 30 idle minutes and is swapped out for an image batch
life of a tool call
Model proposes
Saved
Policy classifies
Phone approves, if asked
Runs in sandbox
Output saved
Result to model
The server’s layers top to bottom, how it shares the GPU, and the steps of one tool call. Redrawn from the README’s architecture, life-of-a-tool-call and GPU-sharing diagrams. Hosted agents run the unmodified vendor CLIs in isolated containers behind the same event stream.
From pull request to production
Every pull request gets the full test suite, a SonarCloud coverage gate and an automated review by Codex, Claude or Cursor. After a merge, CI runs again on the exact commit and immutable images are published. The deploy then builds a new environment side by side, swaps to it and checks health, so a rollback is a pointer swap.
A real run on my tower, recorded at phone size: a task in a throwaway scratch folder asks to pip install pytest, I approve it, and all 7 tests pass. Slow stretches are sped up and labelled.
Where AI agents did the work, and what I decided
AI coding agents implemented most of the work: 685 of the repo’s 1,003 non-merge commits carry a co-author trailer naming Claude, Cursor or GPT, and the repo has 232 merged pull requests (counted on 8 October 2026).
The build is split into phases, each with a written results doc. The docs record the decisions I made: whether to build our own loop after the bake-off (“D1 decided (user, 2026-09-14): build our own agent loop”), a self-hosted notification server, and how a tap or long-press on a notification behaves.
The bake-off was set up to catch bad grading. Every failure was checked by hand, and two checkers were fixed after that review: a hidden test that demanded something the prompt never asked for, and a check that was too strict about merge commits. Both were regraded.
Every pull request goes through the same gates whoever wrote it: CI, the coverage gate and an automated review.
The benchmark
My own benchmark: 10 hard coding tasks, each run twice, graded mostly by hidden tests. Same model everywhere (Qwen3.6-35B-A3B, 32k context, one RTX 4070 Ti SUPER). The pass counts are within one run of each other, so only the speed gap is a finding.
Harness
Passed
Per task
Agent Harness
19/20
47 s
OpenCode 1.18.30
18/20
81 s
OpenHands CLI 1.16.0
18/20
126 s
How it was run
Tasks. The hard suite has 10 tasks, each run twice, with a limit of 50 turns and 30 minutes per run. Most are graded by hidden tests. Each run gets one Docker sandbox.
Checkers. Each task ships with a reference solution, and a self-test proves its checker passes correct work and fails no work. Saved runs can be regraded after a checker fix without calling a model again.
Reference harnesses. OpenHands and OpenCode ran the same tasks with the same model profile on an internal Docker network whose only route out is a proxy to the local model.
Failures. Every failure was checked by hand. In the first hard-suite run, three of the four misses were one task, a report query, and every harness got it wrong in the same ways: counting an order once per refund, and a date range that dropped the last day of June. Those misses came from the model.
What’s proven so far
Results
On the hard suite the loop passed 19 of 20 at 47 s a task, against 18 of 20 at 81 s (OpenCode) and 18 of 20 at 126 s (OpenHands).
The same suites picked the model: Qwen3.6-35B-A3B passed 26 of 26 on the 13-task core suite and 19 of 20 on the hard suite, ahead of gpt-oss-20b at 23 of 26 and 16 of 20.
The walkthrough above is a real run of a phone approval.
Limits
20 runs per harness on one machine. The pass counts are within a run of each other, so only the speed gap is a finding.
Some early OpenHands runs happened while the machine was paging, so part of its gap may be memory pressure, and the OpenCode runs had as little as 239 MiB of RAM free.
The model reached the ceiling of the first suite and is close to it on the hard one.
The results are from 14 September 2026, on the versions named in the table.
Next
A wider bake-off against newer, pinned releases of more harnesses, with failures classified as model, harness, adapter or infrastructure. The repo’s adapter record is a draft, with no scored run in it yet.
A hosted-subscription lane in the same study.
Source and docs
agent-harness: source, installers and the README with its architecture diagrams and benchmark
Phase 0 results: the model and harness bake-off, with every table and failure