We turned our broken MacBooks into an AI cluster

8 min read

Pim Vernooij

Written by

Pim Vernooij

Co-founder Lab Digital & Evolve

How one AI gateway gives every team local, sovereign and frontier models, with failover when one of them goes down or runs out of capacity.

Every office has one: a drawer of laptops nobody uses anymore. Ours holds MacBooks with cracked screens and dead keyboards. The Apple Silicon chips and the memory inside them still work perfectly.

During Lab Digital's internal AI hackathon, the brief was to build something that makes our own work better. We turned that idea into a local inference cluster, proved it on four MacBook Pros, and put it behind a single AI gateway. Next to it sit the frontier models we already use, and Crew, our platform for autonomous agents, talks to all of it through one endpoint.

This post covers why we built it, how the pieces fit together, and what we learned, including the parts that didn't go the way we hoped.

One AI gateway, three tiers of inference

Scaling AI-driven engineering

At Lab Digital, AI-driven engineering is no longer an experiment. Every project we run uses it, through methods like spec-driven development. The field moves fast, and the question has shifted from whether to how far we can scale it.

Scaling has two sides. One is organisational: how teams work, review and share what they learn. The other is infrastructure:

  • Autonomous agents that pick up work in the cloud, without a developer at the keyboard. That is what we built Crew for.
  • Tokens. Lots of them, from models we can rely on, at a cost that keeps making sense as usage grows.

The hackathon was about that second part.

Tokens are infrastructure now

Once agents work on every project, tokens behave like any other infrastructure. You need them to be available, affordable and under your control. Relying on a single provider puts each of these at risk.

  • Cost. Agent runs read a lot. One small Crew task in this post consumed 49,000 input tokens. Multiply that by every team and every day, and the monthly bill grows with it.
  • Data. With a single cloud provider, every prompt leaves the building, including client code and context.
  • Lock-in. When one provider's API is wired into your tools, switching becomes a project of its own.
  • Availability. Providers have outages and capacity limits. If your agents depend on one, so does your delivery.

We didn't want to pick one model. We wanted a setup where the gateway decides which model handles a request, so we can switch models without changing our tools.

One gateway, three tiers

The design fits on a whiteboard, which is where it started. Every consumer talks to one gateway. Behind it sit three tiers of inference, and the gateway decides where each request goes.

When one tier is down or out of capacity, the gateway fails over to the next. Consumers never notice which tier answered.

  • Local: our own hardware. Data stays in the building, and the cost per token is effectively zero once the machines exist.
  • Sovereign: dedicated GPUs at a European provider, for bigger open models without depending on a US cloud.
  • Frontier: the strongest commercial models, through their APIs, for the work that needs them.

Sign-in runs through Entra ID, so access follows the same accounts as everything else we use.

Building the local tier with exo

The local tier runs on exo, an open-source project that pools Macs into one inference cluster. Under the hood it uses Apple's MLX framework. exo finds the other machines on the network, splits a model across them in proportion to their memory, and serves it through an OpenAI-compatible API.

For the hackathon we used four MacBook Pros with 24, 18, 18 and 32 GB of memory: 92 GB in total, connected in an MLX ring. On that cluster we ran Qwen, GLM and Llama models, including:

  • GLM-4.7-Flash (4-bit), on a single MacBook.
  • Qwen3-30B-A3B (4-bit), split across two MacBooks. Our first test answered after 1.26 seconds and generated 33.4 tokens per second.

All the machines sit on our Tailscale network, which is why connecting them took minutes instead of a day of firewall work. The same network lets the gateway and Crew reach the cluster without opening a single port to the internet.

One thing to know if you try this: exo doesn't load models on demand. You start an instance of a model first, and only then does the API answer for it.

Wiring it into Crew

We connected Crew to LiteLLM, which in turn exposes the local cluster. That took a configuration change and no code.

The first real run was deliberately small: add a name to a repository's README. The agent ran on a local Qwen model in a Docker sandbox and finished in 1 minute 31 seconds. Along the way it:

  1. made the change and ran the existing tests (2 of 2 passed);
  2. pushed a branch and opened a pull request;
  3. waited for CI, which passed;
  4. skipped human review by rule, because only docs changed.

It used 49,000 input tokens and 739 output tokens. Crew's cost column for the run read $0.0000.

On hackathon day, the gateway handled 427,700 tokens in total. 185,700 of those, 43%, went to GLM-4.7-Flash on our own MacBooks. The rest went to a frontier model.

What we learned

  • Open standards. Everything connected easily because every piece speaks the same OpenAI-compatible API, and every machine sits on the same Tailscale network.
  • GPU capacity. We wanted dedicated GPUs as a sovereign tier, and found them more or less sold out at AWS and Scaleway. Paying for capacity doesn't guarantee you get it.
  • Cluster speed. Pooling memory lets you run models no single laptop could hold, but it doesn't make them faster: over Thunderbolt 4 and the network, the links between machines stay the slow part. Fast RDMA clustering needs Thunderbolt 5; our cluster ran without it.
  • Memory. The memory in each machine decides which models it can help run. Machines with 8 GB add little to a cluster. For older chips, reading long agent prompts hurts more than generating the answer.
  • Real cost. The run cost nothing per token, but hardware, power and our time are real. Local inference beats an API on price only when the machines are busy most of the day.
  • Maturity of exo. It works, but expect warnings and rough edges, like the "incompatible macOS versions" banner on our dashboard.

What's next

  • Dedicated hardware. Our first step is buying a dedicated machine, such as a Mac Studio, and measuring how much of our actual work it can take on. If the numbers hold up, the end state might be one machine per team, or even per client.
  • A sovereign tier. As soon as GPU capacity frees up, a dedicated GPU such as an H100 at Scaleway joins the gateway. Because it speaks the same API, that's a configuration change for Crew and every other consumer.
  • More people on the gateway. Beyond Crew, we want office chat and developer tools like OpenCode on the same endpoint, with sign-in through Entra ID.
  • The gateway itself. We picked LiteLLM because we needed a gateway for the test, and it does the job well. Before a wider rollout we need to look at its licensing: single sign-on is free for up to 5 users, and beyond that it needs an Enterprise license. Because everything behind it is OpenAI-compatible, the gateway is replaceable too.

Conclusion

Scaling AI-driven engineering means treating tokens as infrastructure. What we took away from building ours:

  1. Put one OpenAI-compatible gateway between your tools and your models. Every model, provider and consumer becomes swappable.
  2. Spread your inference over tiers: local, sovereign and frontier. Each one covers for the others when it's down, full or too expensive.
  3. Start with the hardware you have. Older Apple Silicon is good enough to learn on and to run real, smaller tasks.
  4. Get your network right first. A private network like Tailscale turns hardware in different places into one platform.
  5. Measure before you buy. The gateway shows which tier does the work, and that data should drive the next hardware decision.

We built it with laptops we already had, open standards and one hackathon day.

Tags used in this article:
Pim Vernooij

About the author

Pim Vernooij

Co-founder Lab Digital & Evolve

Pim Vernooij is co-founder of Lab Digital and Evolve. He likes talking and writing about how technology enables business.

Related articles