fakoli-claw: A Local-First, Tier-Routed Multi-Agent Coding Crew
Impact Summary
I built a multi-agent coding crew that runs high-volume specialist work on a local GPU while routing planning and review to a frontier model. It treats agent coordination as a team-management problem — file ownership, parallel waves, and evidence-based review gates — backed by a durable SQLite-over-MCP state layer.
Role
Creator & Maintainer
Timeline
2026-Present
Scale
- 9-agent crew, two tiers
- 22-tool MCP state server
- Local-first execution
- Production-validated stack
Links
Problem
A 35-billion-parameter model running on the GPU in my office will confidently hand you a function that does not compile. I watched it happen repeatedly until I stopped asking it to behave like a frontier model. The problem with a lone local model is not that it is dumb — it is that it is unsupervised. Give a small model a vague goal and the whole codebase, and it wanders.
The real problem is coordination, not intelligence. And we already know how to coordinate work on shared codebases, because we have been coordinating humans on them for decades. Existing multi-agent frameworks — CrewAI, LangGraph, AutoGen — orchestrate agents competently, but none make local-first, tier-routed execution the default, and most treat “the critic agent said it’s fine” as a sufficient review gate. I wanted implementation to be free and parallel on hardware I already own, with frontier spend reserved for where it sets the quality ceiling.
Approach
I ported the practices of running a real engineering team onto the OpenClaw runtime. File ownership becomes code ownership, wave execution becomes sprint sequencing, and a code-review gate stays a code-review gate.
The crew is nine specialists — an orchestrator plus guido (architecture), scout (research), smith and welder (engineering and integration), herald (docs), keeper (infra), critic, and sentinel. The wave engine reads each task’s Depends on: declarations and computes waves via topological sort: independent work runs in parallel, each agent receiving only its own packet of intent, scope, and verify command.
Tier routing is the most important decision and is pure config: high-volume builders run locally on SGLang through an OpenAI-compatible endpoint, while quality-critical roles route to GPT-5.5. Durable state lives in the fakoli-state FastMCP server — 22 tools over SQLite — with leased claims and typed evidence events rather than schema-less status files.
Key Design Elements
- Four invariants: intent over recipe, specialist over generalist, evidence over claim, durability over chat.
- Evidence gates: the critic re-runs verify commands and the sentinel cites fresh command output for every PASS — caught broken code mid-build that text-matching would have waved through.
- Config-only tiering: swap local or cloud models via environment variables without touching any prompt.
- Compaction fix: lowering
reserveTokensto 8192 resolved a turn-1 deadlock that otherwise blocked the entire local tier.
Outcomes
- Small local models become genuinely useful when work is scoped into tight, evidence-checked packets — the design is an honest admission of the small-model ceiling, not a denial of it.
- Implementation runs effectively free and parallel on a GPU that is already paid for, with frontier cost spent only where it sets quality.
- Runs are reproducible: a plan, a wave, an evidence scorecard, and durable state mean a stranger can run the same wave from the README.
Key Contributions
- Designed a nine-agent specialist crew installed as OpenClaw
agents.list[]entries. - Built the wave engine that derives dependencies via topological sort and dispatches specialists in parallel through
sessions_spawn/sessions_yield. - Implemented the critic and sentinel gates that prove work by re-running verify commands rather than trusting claims.
- Developed the
fakoli-stateFastMCP server exposing the PRD → plan → review → claim → apply lifecycle over SQLite. - Architected tier routing that splits local-GPU and frontier execution as re-tunable configuration.
- Diagnosed the small-context compaction deadlock and shipped the global config fix the local-first thesis depended on.
Key Takeaways
- ● Made small local models reliable by scoping work into evidence-checked packets
- ● Enabled effectively free, parallel implementation on already-owned GPU hardware
- ● Produced reproducible runs: plan, wave, scorecard, and durable state from the README
Co-authored with AI, based on the author's working sessions, dictations, and notes.
Explore the source
fakoli/fakoli-claw
Star it, fork it, or open an issue — contributions and feedback welcome.
Related Projects
AWS Security Group Mapper: Visual Analysis Tool for Cloud Security
A Python tool for visualizing AWS security group relationships and generating interactive graphs to help understand complex security architectures.
Fighters Paradise: Modern Game Engine Reimplementation in Rust
A modern Rust reimplementation of the MUGEN 2D fighting game engine with full backward compatibility for existing community content.
Agent-Eval: CI Evaluation Harness for Multi-Agent Development
Behavioral regression testing framework for detecting drift in AI agent instruction files across multi-agent development environments.