Why build your own agent factory
The case for running coding agents on your own machines: your real toolchain, data that stays put, fixed cost, no VM spin-up, and the honest trade-offs.
Picnic · · 8 min read
Most cloud coding agents work the same way. You describe a task, the vendor boots a fresh virtual machine, clones your repository into it, installs what it can, and an agent works there until it opens a pull request. It's a good model. It's also not the only one.
The other model is to run the agents on machines you already own: the Mac mini under the desk, the Mac Studio at the office, the laptop that's idle every night. You keep a board of jobs, pick which machine runs each one, and the agent works on that machine under its own login, against the checkout that's already there. That's what we mean by building your own agent factory, and it's what Picnic is built for.
This essay makes the case for it, and then makes the case against it, because there are plenty of times a hosted agent is the better choice.
Your toolchain is already set up
The hardest part of a hosted agent isn't the agent. It's the environment. Every hosted product has a setup step: a setup script, a snapshot, an environment file, a "machine" you configure once. It works well for a Node or Python service that builds on stock Linux. It gets harder the further your project drifts from that.
Think about what a real project needs to build and test:
- Platform tools. Xcode, the iOS Simulator, code signing identities and provisioning profiles. None of these run in a Linux container.
- Private dependencies. An internal package registry, a private Swift package, a licensed SDK, a database snapshot.
- Logins.
ghsigned in as you, a cloud CLI with the right profile, the staging environment's VPN. - The odd bits. A specific version of a tool pinned years ago, a local service the tests expect on a port, a fixture file that never made it into git.
On your own machine, all of that is already there, because it's where you work. The agent doesn't need a setup script to discover your environment; it inherits it. For Apple platform work this is decisive: an agent that can build and run the app in the Simulator, take screenshots and record a video can show you the change working, not just claim it compiles.
Note: "Inherits your environment" cuts both ways. The agent can reach whatever that machine's user can reach. See the trade-offs below.
No spin-up, no cold start
A hosted VM starts from a snapshot every time. Depending on the product, that means cloning, restoring caches, installing dependencies and running the setup script before the agent does any real work. Vendors work hard to make this fast, and some cache aggressively, but a large monorepo with a heavy build still takes time to come up.
A machine you own has the repository checked out, the dependencies installed and the build cache warm. Picnic gives each job its own git worktree and branch from your existing checkout, so a job starts without a fresh clone or a cold install, and builds can reuse what's already on the machine. Over dozens of jobs a week, that adds up.
Your code and data stay where they are
With a hosted agent, your source code is cloned into someone else's infrastructure for the length of the task, along with whatever secrets the environment needs. Vendors take this seriously, with isolated VMs, credential proxies and network allowlists, and for most teams it's fine.
Some teams can't, or would rather not. Client work under a contract, regulated data, or a company policy that code stays on company machines. Running the agent on your own machine keeps the checkout, build artifacts and secrets on hardware you control.
Two honest caveats. First, the model provider still sees the conversation: prompts, the code the agent reads and the tool results go to Anthropic or OpenAI under your account's terms, wherever the agent runs. Anthropic's own docs say this plainly about its self-hosted runners: checkouts stay on your machines, but "Session content still goes to api.anthropic.com" (Claude Code docs). Second, whatever tool you use to coordinate the agents may carry some content. In Picnic, the relay passes the board and chat between your machines; a machine in metadata-only privacy mode keeps task content (prompts, chat and results) on the machine and sends only state and titles. Loops are the one exception: a loop keeps its prompt on the relay so it can start the job on time. The security page has the detail.
Cost you can predict
Hosted agents meter something: credits, tokens, compute minutes, task counts or seats with quotas. That's fair, because the vendor is paying for the VM. It also means a busy week costs more than a quiet one, and a long-running job costs more than a short one.
If you run the official CLIs on your own machines, the agent work comes out of the subscription you already pay for. Claude Code runs under a Claude plan login, and the Codex CLI signs in with a ChatGPT plan (Codex on GitHub). Picnic never calls a model API itself and never touches those credentials; it starts the official claude or codex binary on the machine, the same as if you typed the command yourself. You still live within your plan's usage limits, so heavy use may push you to a bigger plan, but the bill is a known number.
The hardware is a cost too. If you already own a spare Mac, its marginal cost is electricity. If you'd be buying one, compare it against what you'd spend on hosted minutes over a year or two.
Long jobs are fine
Hosted sessions often have limits: a maximum run time, an idle timeout that reclaims the VM, a cap on concurrent tasks. They exist for good reasons, but they shape what you can hand off.
On your own machine, the only limit is the one you set. In Picnic a job runs until it reports. It waits on CI for as long as CI takes, and a job waiting on your answer neither times out nor holds a slot. A big migration, a full test suite on a slow simulator, or a refactor that takes a few CI rounds is all fine.
It's still a fleet, not a single laptop
Running agents locally used to mean a terminal per task on one machine. The point of an agent factory is that the machines act like one system:
- One board. Every job on every machine in four columns: Backlog, Running, Needs you, Done. Needs you is your inbox.
- Any machine, from anywhere. Machines connect out to Picnic's relay, so they reach each other from any network with no ports to open and no VPN. Your iPhone shows and steers everything, and runs nothing.
- A defined finish. Each job has a mode: Plan brings back an answer or a plan and changes nothing, Plan and build a draft PR and a demo, Ship a PR merged when required CI is green. See modes.
- Schedules. Loops start jobs hourly, daily, on weekdays or weekly, and a machine that's offline picks its job up when it's back.
- Two engines. Claude Code or Codex per job, under your own logins. See Codex and Claude Code side by side.
- Every account. A machine can hold several Claude and Codex accounts and each job picks one, so your company's Claude account, your own plan and a client's all feed one board, on one Mac or several. See several accounts.
- Yours alone. Your machines answer only to your own account, from your apps, your API keys and the AI apps you connect over MCP.
The trade-offs
Now the case against. These are real, and they're why hosted agents exist.
You run the machines
Your machines need to be on, awake and online for jobs to run. A machine that sleeps, loses Wi-Fi or reboots for an update stops working until it's back. Picnic holds jobs for an offline machine and starts them when it returns, but it can't make the machine come back. If you want an always-on worker, plan for it: power settings, auto-login, a wired connection. Our guide to an always-on machine covers the setup.
No fresh sandbox
A hosted VM is thrown away after each task. Your machine isn't. Picnic gives each job its own worktree and branch, and a policy layer refuses force-pushes and self-approval and asks before sudo, CI or secrets changes and writes outside the worktree. That's a set of guard rails, not a sandbox. An agent on your machine runs as your user, and anyone who can start jobs on a machine can reach everything that machine can: its files, its logins and anything it can reach on your network. Share machines only with people you'd trust at the keyboard (team access).
Capacity is what you own
Hosted products can run many tasks in parallel on demand. Your fleet runs as many jobs as your machines can handle at once. For most solo developers that's plenty, but you can't burst to fifty parallel tasks for an afternoon.
Setup is on you
Installing Claude Code or Codex, logging in, signing in to GitHub, keeping things updated: that's your job, on each machine. Picnic's setup checks show what's missing and offer fixes, but it's still more work than signing in to a website.
Mac and Linux, for now
Picnic's machines are Macs on macOS 26 or later and Linux computers. If you're on Windows, this isn't for you yet.
When a hosted agent is the better choice
Pick a hosted agent if:
- You don't have, or don't want, a machine that stays on.
- Your project builds cleanly on Linux with a short setup script.
- You want a fresh, disposable sandbox for every task, and the isolation that comes with it.
- You need to burst to many parallel tasks.
- You need mature enterprise controls such as SSO, SCIM and audit logs today.
- You'd rather pay per use than maintain anything.
Claude Code on the web, Codex cloud, Cursor's cloud agents, Devin, Jules and GitHub's Copilot agent are all good at this, and several of them now offer ways to run on your own runners too. Our roundup of the best cloud coding agents in 2026 compares them.
When your own agent factory wins
Run your own if:
- Your work needs macOS, Xcode, simulators or anything a stock Linux VM doesn't have.
- You already have Macs or Linux machines that sit idle overnight.
- You already pay for Claude or ChatGPT and want agent work to come out of that.
- Your work is split across accounts: a day job, side projects, a few clients.
- Your code should stay on machines you control.
- You want long jobs, scheduled jobs and a defined finish line, all on one board you can steer from your phone.
Try it
The cheapest way to find out is to try it on a Mac you already own. Picnic is free for up to 3 machines. Download Picnic, add a machine, and send it a job tonight. For more machines, see pricing.
