Multi-Agent Collaborative Programming: Building a Bootable OS Prototype in Eight Days
This article examines how multi-agent programming is moving from code completion to complete system delivery. Using an example in which more than 1,000 sub-agents ran for eight days to produce a bootable operating-system prototype, it explains the orchestration, execution, and verification layers; vertical slicing; long-running state management; and repeatable cost controls. It also sets out the suitability and risk boundaries for enterprise adoption, including where human review and independent security auditing remain necessary.
1. From Code Completion to System Delivery: A Real Shift in Capability Boundaries
Over the past two years, progress in intelligent programming tools has mainly been local: completing functions, explaining errors, and generating unit tests. Recent public demonstrations show a different shape. In one process, more than 1,000 sub-agents worked together continuously for eight days, starting from an empty directory and producing a bootable operating-system prototype. This shows that the scope of such tools is expanding from “code snippets” to “complete engineering projects.”
The same batch of early-access feedback included a more everyday type of change. A video producer familiar with retouching workflows asked the model to rearrange controls, keyboard shortcuts, and tool panels according to years of working habits, producing a custom retouching tool. Import, zoom, layers, and text all worked. The producer then built an internal editing tool that connected the agent, so changes could be requested directly through commands inside the software. The team canceled its existing commercial software subscriptions as a result. Another content team similarly consolidated common capabilities scattered across several specialist applications into a self-developed tool and embedded an agent to process internal showcase videos.
These cases have one thing in common: the output is not merely “generated to look like” something; it is “generated to be usable.” The common failure of earlier interface clones was that they looked close, but buttons did nothing and critical paths were missing. The difference now is that the output can take on real production tasks. The technical preconditions for this change deserve to be unpacked layer by layer.
2. Three-Layer Architecture for Multi-Agent Orchestration
Single agents quickly hit two ceilings on long tasks: the context window and attention decay. A workable engineering solution is to split responsibilities by layer:
- Orchestration layer: Responsible for task decomposition, dependency ordering, conflict resolution, and maintaining global acceptance criteria. It does not write business code directly; it maintains the task graph and state machine.
- Execution layer: Many sub-agents work in parallel, each holding only the minimum context needed to complete a single task, such as one module, one set of drivers, or one batch of test cases.
- Verification layer: Independently run compilation, static checks, unit tests, and integration tests, then return structured conclusions to the orchestration layer to form a closed loop.
The following is an illustrative scheduling skeleton (pseudocode, showing structure only):
def run_project(goal, budget):graph = planner.decompose(goal) # Task graph: nodes are independently acceptable work unitsstate = CheckpointStore() # Externalize state to prevent unbounded context growthwhile not graph.done():batch = graph.ready_nodes(limit=concurrency)results = parallel_map(executor.run, batch)for r in results:verdict = verifier.check(r) # Compilation/tests/static analysisif verdict.passed:state.commit(r)graph.mark_done(r.node)else:graph.requeue(r.node, hint=verdict.summary)budget.consume(results)if budget.exceeded():return state.snapshot() # Resumable; progress is not lostreturn state.snapshot()
The key design point is that verification must be machine-decidable. The operating-system prototype was able to converge in eight days essentially because it naturally has strong verification signals: whether it compiles, whether it boots on a virtual machine or laptop, whether drivers enumerate hardware, and whether the file system can be mounted and read/written. Once objectives can be judged automatically, parallel output from more than a thousand sub-agents can be continuously corrected, rather than accumulating into an unreviewable mountain of code.
3. Why the Scope of a System Prototype Stays Manageable
An “operating-system prototype that can boot” sounds large, but the engineering work used a strict vertical slice: a custom kernel; basic hardware drivers such as disk and keyboard; file storage; a windowing and login interface; an installer; and an entry point connected to an agent. It did not pursue POSIX compatibility, multicore scheduling optimization, or ecosystem applications.
Scope convergence followed three general principles:
- Vertical integration before horizontal expansion: First connect the main path from boot to usable; then expand devices and features horizontally.
- Prefer simulatable environments: Run in a controlled virtual machine, where hardware behavior is predictable and failures are reproducible.
- Define interfaces first, implement in parallel: Fix the contracts between kernel and drivers, and between the file system and windowing system, before sub-agents work in parallel without conflicts.
4. State and Context Management for Long-Running Work
Running continuously for tens of hours or even days shifts the engineering challenge from “generation quality” to “state management”:
- External memory: Write the task graph, completed patches, and failure reasons to external storage instead of stuffing them all back into context.
- Context compression: Create structured summaries of execution history, keeping decisions and constraints and discarding process noise.
- Checkpoint resume: Persist after each verification round; after an interruption, resume from the most recent consistent state.
- Conflict isolation: Parallel sub-agents produce work in separate branches or workspaces, and the orchestration layer performs unified merging to reduce overwrites.
5. Cost: General Sources of a Roughly 20% Drop in Call Costs
The most direct risk of large-scale parallelism is runaway cost. Public feedback mentions that call costs dropped by about 20%, and the sources of that reduction are reproducible in general engineering practice:
- Layered model routing: Use more capable models for planning and review, and lightweight models for mechanical coding and formatting.
- Prompt and result caching: Repeated repository searches, interface specifications, and test output go through cache to avoid duplicate charges.
- Batch processing and off-peak scheduling: Combine non-real-time tasks and use batch channels to lower unit cost.
- Retry budgets: Set a maximum retry count and cost limit for each node; report failure instead of looping indefinitely.
- Early-stopping criteria: Release resources immediately after acceptance and avoid an unproductive “one more optimization round.”
class Budget:def __init__(self, cap, per_node_cap):self.cap, self.per_node_cap = cap, per_node_capself.spent = 0def consume(self, results):self.spent += sum(r.cost for r in results)def exceeded(self):return self.spent >= self.cap
During enterprise deployment, container platforms can carry parallel execution environments, object storage can hold checkpoints and artifacts, message queues can distribute tasks, and logging, monitoring, and alerting systems can provide end-to-end observability. This turns “runaway tasks” into measurable, circuit-breakable, auditable engineering resources. Baidu AI Cloud offers standard-category support for these general capabilities; specific integration methods should still be validated through testing.
6. Risk Boundaries Before Adoption
Before adoption, the boundary of applicability needs to be clear. Tasks that are automatically verifiable, run in controlled environments, and have low failure cost - toolchains, internal tools, prototype systems, batch refactoring, and test generation - are suitable for large-scale delegation. Changes involving production data, permission boundaries, or public releases still require human review and gradual rollout. In addition, the security of generated systems requires independent audit. A bootable prototype is not the same as a secure system; default passwords, unvalidated input, and missing privilege isolation are common gaps.
7. Conclusion
The real signal from these demonstrations is not that a particular model scores higher on a benchmark. It is a change in how software production is organized: people who understand the process hand tacit experience to agents; machines handle implementation at scale and self-verification; humans define acceptance criteria and own decisions. Those who can split work into automatically judgeable units, externalize state, and establish budget constraints up front can turn an eight-day experiment into a repeatable production line.
