Codex Plans, DeepSeek Executes: A Practical Guide to Multi-Model Collaboration for Saving Tokens

A multi-model workflow where Codex plans and DeepSeek executes to slash AI programming Token costs.
Facing soaring AI programming Token costs, creator Wu Xiu built the open-source project Hand of Labor: Codex handles planning while DeepSeek executes. Through three principles—role isolation, evidence-first, and local observability—it dramatically cuts AI coding costs while improving code quality and quantity.
The Real Pain Point of AI Programming: Not Whether It Can Write, But Whether You Can Afford It
In his latest video, Bilibili creator Wu Xiu raised an anxiety shared by AI programming users today: AI has long been able to write code—the real bottleneck is that Tokens get consumed too fast. This point strikes at the heart of what heavy users struggle with.
Background|The Underlying Logic of Tokens and Cost A Token is the basic unit of measurement that large language models use to process text. Typically, one English word equals about 1-2 Tokens, and each Chinese character is roughly 1-2 Tokens. In AI programming scenarios, Token consumption is staggering. This is because each conversation not only sends the user's question but also carries the full context (code files, conversation history, system prompts, etc.)—known as the "context window." As a project grows in size, a single request can carry tens of thousands or even hundreds of thousands of Tokens, and the model's reply is billed too. This explains why the author consumed 5% of his monthly quota with just one command to "package the entire project"—the system needs to read all relevant files and fully understand the project structure, which incurs enormous input Token overhead.
He shared his real usage data: to access Zhipu's well-regarded GLM programming plan—which is highly rated for quality—he found the quota basically impossible to grab at 10 AM domestically, so he had to pay a premium to buy the MAX version overseas ($144/month, 20x usage). Even so, he consumed about 1.5 billion Tokens in the past 7 days, and 2.24 billion over the past 30 days. By comparison, Zhipu's team premium plan offers at most 800 million Tokens per week—the usage gap is obvious.
To supplement his compute, he also subscribed to Volcano Engine's Token plan (about ¥200/month). But in practice, just one command—"package this project completely"—consumed 5% of the quota, even though the project itself was only 10 files, 95K in size. A slightly more complex second command to evaluate open-source code burned through 10% directly. At this rate, over every 5 hours you can only have about 10 exchanges with the AI, and complex tasks can eat up 20%~50% with a single sentence.
He emphasized that the problem isn't that Volcano Engine is expensive—it's that the overall cost of high-quality AI programming model plans remains persistently high.
The Core Idea: Let the Expensive Model Plan, the Cheap Model Do the Work
Facing high Token costs, Wu Xiu proposed a clever multi-model division-of-labor scheme:
Codex's monthly fee is expensive but the usage is acceptable, while DeepSeek is relatively cheap. Given this, why not have the two models work together?
His core idea is: Codex handles planning (Planner), and DeepSeek handles execution (Worker). Since he couldn't afford the GPT API fees, he used the Codex client directly and integrated an excellent open-source client to run DeepSeek.
Background|Multi-Agent Collaboration Architecture Multi-Agent Systems are a classic research direction in AI. The core idea is to break down complex tasks and assign them to multiple specialized agents working together, rather than relying on a single all-purpose agent. In the LLM era, this concept has been reactivated. Companies like OpenAI and Anthropic have released frameworks for Agent collaboration. The Planner-Worker-Reviewer three-tier architecture adopted by Hand of Labor closely mirrors the "requirements-development-testing" workflow in software engineering—essentially mapping the collaboration paradigm of a human engineering team onto AI model division of labor. The key advantage of this architecture is that different roles can use models with different capabilities and costs, avoiding using expensive models for repetitive grunt work, thereby achieving an optimal balance between quality and cost.

The initial approach was very primitive: state requirements in Codex, manually copy-paste them to the execution end, and after the execution end produces output, copy it back to Codex for review. After a full day, even though he hadn't written a single line of code, his "finger joints were cramping." This gave rise to the idea of building an intermediary program to automatically hand off messages.
Interestingly, his first demo had two Agents talking to each other, and the result had quite a meme-like flavor—the two AIs bantered about the relationship between hardware configuration and marriage using metaphors of "RAM sticks, gold bars, and dowries," verifying the feasibility of automated handoff between dual Agents.

Hand of Labor: From Chat Tool to "Local Handoff Laboratory"
During iteration, the author realized that simply doing message passing would fall into the trap of "gilding the lily"—features like history records, context management, permissions, and directory browsing were already provided by both Codex and the execution end's CLI. So he turned to a more fundamental question:
How can AI programming tools hand off tasks, submit evidence, and complete acceptance testing just like an engineering team?
This gave birth to the open-source project Hand of Labor. Its core idea can be summarized in four words:
Planner · Worker · Evidence · Acceptance
- Planner: Understands requirements, breaks down tasks, and sets acceptance criteria (handled by Codex)
- Worker: Modifies code, runs commands, submits test logs (handled by DeepSeek)
- System: Saves task status and evidence paths
- Reviewer: Decides whether to pass or continue revising based on evidence

The entire framework's operating logic is clear: the user submits a task → Codex breaks it into a structured task package → Hand of Labor Server manages the local state machine and event flow → the Worker actually modifies code, runs tests, and generates evidence → the Reviewer does QA based on the evidence.
You may not have noticed, but its front-end interface is not a chat window, but a "process viewer"—it shows what step the current task has reached, what the Worker did, where the test logs are, where the evidence files are, and whether acceptance passed. Complete logs are saved in a local directory, and the page only displays summaries and evidence paths to avoid information overload.
Installation and Hands-On Demo
The author also demonstrated the complete installation process, and thoughtfully provided a cloud drive backup link for domestic users:

Installation Steps in Brief
- Clone the Hand of Labor project locally
- Enter the directory, use
python -m venvto create a virtual environment and install dependencies - Install the Skill: copy files from the
Hand of Labor Skillsdirectory to Codex's Skills directory - Run
python server.py, which opens port 51514 by default (customizable) - Access the interface in a browser and configure DeepSeek's API Key (Codex needs no configuration—it automatically reads the local config)
Background|Skill Mechanism and Tool Use The "Skill" mentioned here is the plugin/extension mechanism of the Codex client—essentially a set of predefined instructions or tool-call templates. In modern LLM frameworks, Tool Use (Function Calling) is the core mechanism that lets models interact with external systems, formally standardized by OpenAI in 2023 and widely adopted. The key value of Skills lies in "behavioral constraints": it tells the Planner model not to write code itself, but to structure tasks into standardized task packages (including goals, constraints, acceptance criteria, and required evidence), then hand them to the Worker for execution. This constraint prevents the Planner from overstepping its authority and maintains the architectural purity of role isolation—it's the foundation that allows the entire multi-model collaboration system to run stably.
The author mentioned that a vision model can optionally be configured—when the AI needs to judge the quality of output (such as PPT layout, or whether front-end page colors and layouts are correct), a vision model comes in handy; for pure back-end development, it can be skipped.
Live Test: Snake Game
The demo task was "add a Snake game to the page." You can see Codex on the left furiously outputting plans, while DeepSeek on the right furiously writes code, hands it to Codex for review, Codex feeds back to have DeepSeek continue improving, and finally acceptance passes and the game runs normally.
The key role of the Skill is: it keeps Codex from writing code itself, and instead organizes tasks into structured task packages, clearly specifying "what to change, what not to change, how to accept, and what evidence is needed," then hands them to the Worker for implementation.
Design Philosophy: Three Core Principles
The author summarized the three design principles that Hand of Labor currently values most—also its essence:
1. Role Isolation
The Planner is the Planner, the Worker is the Worker, the Reviewer is the Reviewer. The author put it sharply: "If everyone in a team is in meetings and no one writes code, that's not agent collaboration—that's a year-end summary meeting."
2. Evidence First
The Reviewer doesn't listen to the model's self-declarations—it only looks at Test Logs, Build Reports, and real file changes.
Background|AI Hallucination and the Evidence Mechanism AI hallucination refers to the phenomenon where large language models generate content that seems plausible but is actually wrong or fabricated—especially dangerous in code generation scenarios, where a model might claim a function call succeeded or tests passed, when in fact the code doesn't run at all. This kind of "confident error" is harder to detect than obvious errors, because it bypasses developers' intuitive vigilance. Academics call this phenomenon "Overconfident Calibration." Hand of Labor's "evidence-first" principle is precisely the engineering solution to this pain point: the Reviewer doesn't accept the model's self-declarations, only recognizing Test Logs, Build Reports, and real file diffs. This aligns with the "verifiability" principle in software engineering—code correctness must be proven by objective test results, not by the implementer's self-assessment.
The author described the scariest thing about AI programming: not that it can't write, but that "it writes so confidently that you're embarrassed to doubt it"—the evidence mechanism exists precisely to counter this "confident hallucination."
3. Local Observability
Hand of Labor runs on the local machine by default, with runtime status and evidence saved in local directories, and the QA Reviewer only displays key processes. Check the page for a summary, dig into local files for details—the data is completely under your own control.
Background|Local-First and Data Sovereignty Hand of Labor runs locally by default (localhost:51514), a design choice made for multiple reasons. First is data security: the code of enterprises or individual developers often involves trade secrets, and uploading to third-party clouds carries leakage risks, especially where subject to strict compliance regulations in certain countries and regions. Second is latency and cost: a local state machine requires no network round-trips, so task scheduling responds faster. Third is auditability: all task states, evidence files, and execution logs are saved in local directories, allowing developers to trace back to any historical node at any time. This aligns closely with the "Local-First" software philosophy that has emerged in recent years—data should be under the user's own control, with the cloud serving only as an optional sync layer rather than a mandatory central node.
Conclusion: Each Model Plays Its Part, Humans Make the Final Call
The author candidly admitted that he didn't build this project to prove which model is stronger, but to convey an idea:
Each model has its strengths—the key is putting them in the right place: the right planning, the right execution, the right acceptance. And humans are best suited to making the final call, and to pulling the plug in time when the AI goes off the rails.
From a cost-benefit perspective, the results are quite obvious: previously Codex would burn through 5 hours' worth of usage in half an hour; now most Tokens within a 5-hour period are consumed by the cheaper DeepSeek, so the most basic plan is enough—while the quality and quantity of code output are even higher than before.
For developers equally anxious about AI programming Token usage, this "plan-execute-evidence-accept" multi-model collaboration workflow offers a cost-reduction approach worth diving into. The project is open-source, with the repository named Hand of Labor.
Key Takeaways
Related articles

Godot Engine VR Development Log: Lessons and Pitfalls from Porting to PSVR2
An in-depth analysis of an indie developer's experience using Godot to develop VR games and port to PSVR2, covering OpenXR integration, performance optimization, and console certification challenges.

What Are AI Model Weights, Really? The Deep Learning Truth Revealed by a Meme
Starting from a viral Reddit meme, we dive deep into AI neural network weights — what they are, why they can't be read visually, and how open weights drive technological democratization.

PDF Document Auto-Classification in Practice: Why Embedding Models Fall Short and Better Alternatives
Analysis of why embedding models (like bge-m3) fail at PDF document classification, covering label sensitivity and semantic dilution issues, with three better approaches: LLM classification, supervised classifiers, and multimodal feature fusion.