SoduWork Carries Pi, Qwen Code, and Google Harness² Through One Conversation: Rules Survive, Billing Does Not
A single conversation switches among Pi, Qwen Code, and Google Harness² — a SoduWork multi-harness relay, cost records, and source-code debugging run
When working with multiple agents to write code and run data, one specific question matters: after switching tools, do the rules established earlier and the files already produced keep working?
Opening a new conversation in another tool usually means re-explaining business rules, field definitions, and directory paths. Choosing different harnesses step by step might reduce needless re-derivation, but the handoff itself also costs time, and whether the bill gets lower needs a separate calculation.
The open-source enterprise-grade AI-native engine SoduWork puts multiple AI harnesses into one interface and supports switching harnesses within the same conversation after the current round ends and the switch conditions are met.
I connected Pi 1.4.0, Qwen Code 0.21.8, and Google Harness² 0.2.0 on a MacBook Pro and ran a "single-session three-leg relay" over 120 cloud gateway fault tickets, then inspected the underlying conversation .jsonl and the SQLite usage tables to verify the handoff results and the costs.
The relay kept using the same conversation (01a1d12b-7ee4-71b4-9ea5-3e5667a1c7c4): Pi cleaned first and left R1–R4, Qwen Code continued with regional scorecards, and Google Harness² finally attempted to produce a containment brief. Queueing and failed retries along the way are also recorded below.
Verification scope: these are the results of this short conversation and cannot yet represent that long-history handoffs retain every detail.
Experiment setup | three harnesses, one shared model
SoduWork positions itself as an open-source enterprise-grade AI-native engine: a unified desktop entry sits in the frontend, and behind it strings together the enterprise's existing work with different model and skill harnesses, so that suitable AI can join in step by step:
Figure 1 | SoduWork product overview: desktop unified work entry and multi-model, skill stepwise invocation diagram
All tests ran in a local self-hosted environment. The three harnesses all used DeepSeek's official API deepseek-chat. A unified model removes one variable, but the three legs take on different tasks, so this mainly observes relay capability and per-step costs. No harness performance ranking or cross-model-vendor failover testing was done.
- Device and system: MacBook Pro (M1 Max 10-core / 64 GB RAM) · macOS 27.2.1
- Source version:
https://github.com/mdiri-ai/SoduWork· Commit25bae6a64e69a6262344f7f500cfcd0f6483b2e0 - Enabled models: DeepSeek official API:
deepseek-chat(daily/fast) +deepseek-reasoner(deep reasoning) - Tested harness 1:
Pi 1.4.0(desktop-native harness withtool-hookpermission control) - Tested harness 2:
Qwen Code 0.21.8(coding harness connected locally through the Runner via the ACP protocol, executing in the selected directory and permission mode) - Tested harness 3:
Google Harness² 0.2.0(heavy harness that first runs Google Research's seven-stage text reasoning, then calls an independent executor)
The running copy had temporary modifications: when the first switch hit queue blockage, I added a zero-concurrency release judgment to
claim_nextand restarted the Runner. The laterQwen CodeandGoogle Harness²relay results come from this temporarily patched copy and cannot be treated as results of running the Commit as-is. The queue trigger conditions and the temporary patch process are documented in the first switch's record.
Clicking a batch probe on the desktop's "Agent Management" page lit up all three harnesses with green "test passed" badges. The right-side drawer directly shows CLI paths, version numbers, and probe receipts (9 mainstream harnesses can be managed in total):
Figure 2 | Desktop probe passes Google Harness², Pi, and Qwen Code
Input file and a deliberately arranged data distribution
To probe whether switching harnesses loses previously fixed rules, I generated in the working directory exp-c-ops-triage a cloud_incident_tickets_q4.csv with 120 cross-region cloud gateway alarm records and a change-over schedule change_freeze_windows.json.
I deliberately planted a counter-intuitive distribution: the North China region (cn-north) has the most tickets (52) but all are marginal jitters; the South China region (cn-south) has only 24 tickets, yet all are severe connection-pool exhaustion and Redis brain-split cases, with a cumulative impact score of 2016.61.
01|Pi: filtering 120 tickets down to 96
For the first round I chose the Pi harness to start the conversation. I had it do the initial CSV cleaning and write stage1_filtered.json, and in the first instruction I laid out the 4 rules to hold for the rest of the run, without re-pasting formulas and thresholds later:
- R1 (change-freeze window exemption): tickets whose
hour_utc8falls inside the region's[start_hour, end_hour)half-open change window are markedPLANNED_MAINTand removed; - R2 (impact score formula):
impact_score = round(affected_tenants * 2.5 + p99_latency_sec * 1.2 + error_rate_pct * 3.0, 2); - R3 (dual-measure leaderboard tie): when reporting the top region, both "first by valid ticket count" and "first by cumulative impact_score" must be listed together, not a single measure;
- R4 (three-level listing threshold): cumulative score
>= 450getsRED_FREEZE,[250, 450)getsAMBER_WATCH,< 250getsGREEN_NORMAL.
Pi took 8.59s to write the filtering script and finish the review: 24 change-window tickets removed (14 East China, 10 Singapore), leaving 96 valid tickets written to stage1_filtered.json, with score_mismatch=0.
02|First switch, and a queue stall first
On the first in-conversation switch from Pi to Qwen Code, Pi had finished in 10 seconds but Qwen Code stayed stuck at queued · 1 item ahead. A ps check showed no agent child process running at all.
I traced from runner-adapter.js to the scheduler runner_admission.py (full path hub-backend/app/services/runner_admission.py) and found two pieces of logic colliding:
On macOS there is no /proc/stat, so load is converted into a CPU percentage (line 157)
_ProcSampler computes actual CPU utilization on Linux through /proc/stat. On macOS (Darwin) that file does not exist, so it falls back to os.getloadavg()[0] * 100.0 / cpu_count as an estimate. The converted value cannot be treated as a measured CPU utilization.
On my 10-core M1 Max, with the IDE and browser open, loadavg read 20.59. Although observed CPU usage was low, the converted value still hit the cap of cpuPercent = 100.0% >= 95.0%, which flipped can_start to False at line 212.
No zero-concurrency fallback and a sequence starting at 1 (lines 337 & 366)
claim_next() at line 366 judges if not can_start or int(active or 0) >= limit: return None — even with active == 0 and nothing running, a false can_start still blocks. Meanwhile line 337's enumerate(..., 1) returns queue-head index 1, so the frontend shows "1 item ahead", making it look like a ghost task is stuck.
Temporary patch and later verification
In the local run copy I added a zero-concurrency release judgment to claim_next (if (not can_start and int(active or 0) > 0) ...), restarted the Runner, and only then finished the last two legs. Their execution times appear in the cost table. This was a temporary change made to continue the experiment; the effect of forcing a release under resource pressure was not verified. A proper fix still needs regression testing combined with a resource-protection strategy; on Darwin, host_processor_info or top -l 1 could supply CPU sampling data instead.
03|Qwen Code: continuing from the previous leg
The instruction to Qwen Code was short and did not re-paste formulas or thresholds:
Step 2: directly read stage1_filtered.json just generated in the working directory, strictly follow the 4 rules we agreed on in the previous round (R1~R4), summarize and generate regional scorecards regional_scorecard.json, and give in the reply the dual-measure leaderboard top regions and each region's listing level.
After the queue problem was handled, this leg finished in 16.85s. I opened regional_scorecard.json to verify the data:
{
"summary": {
"valid_total": 96,
"excluded_planned_maint": 24,
"impact_score_grand_total": 3195.12,
"score_mismatch": 0,
"grade_counts": { "RED_FREEZE": 2, "AMBER_WATCH": 1, "GREEN_NORMAL": 1 }
},
"dual_leaderboard": {
"by_valid_ticket_count": { "value": 52, "leaders": ["cn-north"] },
"by_impact_score_total": { "value": 2016.61, "leaders": ["cn-south"] },
"same_region": false
}
}
This output matched 4/4 rules: total 3195.12, listing distribution 2 RED / 1 AMBER / 1 GREEN, and the reply listed both the ticket-count leader cn-north (52) and the cumulative impact-score leader cn-south (2016.61) per R3. South China's 24 tickets average about 84.03 points each.
What 4/4 means: R1's filtering and R2's scoring results were already written into the first leg's JSON. That supports "existing rules and artifacts carry over after handoff", but is not enough alone to prove a fresh harness re-understood and re-executed all four rules.
The desktop reply and the dual-measure comparison table:
Figure 3 | Same conversation switched to Qwen Code outputs the dual-measure scorecard without restating formulas
Why did it connect this time? What the handoff code does
Pi is a built-in JS conversation, while Qwen Code and Google Harness² run as independent processes on the Runner. How does clicking a switch button mid-conversation keep the chat going?
I read client/main/agent-runtime/switchable-conversation.js (lines 119–204, the selectAgent implementation). The switch works through Segmented Conversation:
- Save the previous harness's context: before switching,
raw.snapshotAsync()grabs the old harness's message stream, tool-call details (tools), and usage receipts (usageReceipts). These are saved torecord.prefix, and each harness's conversation description goes intorecord.segments. - Tool-call ID namespace collision prevention: different harnesses may each number tool calls from
1internally. Line 174 prefixesold.sessionId + ':' + t.idso tool cards from different harnesses in the same chat window stay distinct. - In-place inheritance of working directory and automatic handoff-summary injection: when the new harness starts, SoduWork forces the same physical working directory (
cwd: raw.cwd), the same task bindings (raw.taskBindings), and the same activated plugins (activePluginIds), and callssegments.brief(before)to generate a structured summary of prior progress injected intocontextPrompts.
In this switch I did not move intermediate files or hand-write a handoff summary. But saving full history is not the same as sending full history to the new harness.
Handoff summary length limits
client/main/conversation/runtime-segments.js lines 145–155, brief limits:
- Message text: at most 6,000 characters per message; after concatenation, the trailing 28,000 characters are kept
- Tool records: the most recent 12, at most 1,000 characters per argument; after concatenation, the trailing 6,000 characters are kept
Earlier details may be cut off. The source code's handoff prompt also states this.
04|Harness²: plan blocked, so I changed the delivery requirement
The third step needed a root-cause comparison for the two RED_FREEZE severe regions and an executive avalanche-prevention decision brief. I switched in the same conversation to Google Harness², which favors "seven-stage text reasoning".
The first attempt asked Harness² to analyze the files and write the new brief into the working directory. It got blocked by the path guardrail during the "propose task method improvement" reasoning stage:
Figure 4 | Google Harness² seven-stage reasoning triggers the path-safety guardrail
The interface showed clearly: Google Harness² reasoning execution failed (propose task method improvement): the improvement plan contains a disallowed file or path; this round did not enter final execution. Before calling its independent executor, Harness² runs a strict path-whitelist check on the generated plan; if the model's reasoning draft references an out-of-bounds path, it trips early.
I followed up in the same conversation with: "do not reference external paths, directly output an architecture decision brief of at most 200 characters in the body, based on the two RED_FREEZE conclusions above". This time Harness² took 27s to finish seven-stage reasoning and returned a 190-character brief.
This changed the delivery requirement: what succeeded was the in-body output; the originally requested brief file was not written to disk in this round.
Figure 5 | Same conversation spans PI, QW, H2 harnesses and completes the final architecture decision brief
In the left conversation list of the screenshot, next to "we are now starting to handle…", the PI, QW, H2 harness badges appear, and the bottom workspace is still exp-c-ops-triage. The brief's conclusion: "south fixes capacity and consistency, north fixes entry resilience, both RED regions pause routine changes."
05|After the relay, itemizing the bill
After the relay finished, I checked the admin backend's "Usage and Cost" panel, then exported ai_usage_event records from the local soduwork.db and cross-checked them against the Pi conversation .jsonl, the Runner's events.jsonl, and raw.log:
Figure 6 | Admin usage and cost panel shows Pi 899k and harness2 119k
Below are the underlying receipts for this relay conversation (01a1d12b-7ee4-71b4-9ea5-3e5667a1c7c4). All three harnesses use deepseek-chat; fees follow the RMB rates estimated in the test records:
- Cache-hit input:
¥0.2 / million tokens; - Cache-miss input:
¥2.0 / million tokens; - Output:
¥3.0 / million tokens.
This article does not attach the rate page's collection date or supplier settlement bills; these numbers are estimated costs under that measure only.
Leave Qwen's billable amount blank first
Two data measures in the screenshot and soduwork.db need separate treatment:
Qwen Code (ACP protocol) context occupancy is not billable usage
The event in 06206968-.../raw.log is:
{"type": "step_finish", "contextOnly": true, "part": {"contextWindow": 131072, "tokens": {"input": 53016, "output": 0}}}
Here 53,016 means context used, 131072 means window capacity, and output: 0 cannot be read as "no output this round". hub-backend/app/services/acp_bridge.py turns context-usage updates into this event; hub-backend/app/services/runtime_messages.py explicitly excludes contextOnly so window occupancy is not counted as cumulative consumption.
This time meta.json's usage is 0; the backend only shows the two combinations Pi (899k) and harness2 (119k).
Unknown billable amount is not zero consumption: the existing records are not enough to account for Qwen's leg, and a billing bug cannot be inferred from this event alone. The UI should distinguish "no billable usage obtained" from "confirmed zero usage", and the gap should be filled from actual model-request receipts or supplier bills.
Usage records
| Execution phase and harness | Model requests | Input tokens (incl. cache hits) | Output tokens | Total tokens |
|---|---|---|---|---|
Leg 1: Pi 1.4.0 (relay rough filter) |
4 |
69,354 (cache 52,992, 76.4%) |
1,689 |
71,043 |
Baseline: Pi 1.4.0 (standalone rough filter) |
5 |
84,410 (cache 68,480, 81.1%) |
1,666 |
86,076 |
Leg 2: Qwen Code 0.21.8 |
not split | only context occupancy 53,016 (contextOnly: true), not billable input |
ledger says 0, actual unknown |
context occupancy 53,016, not cumulative consumption |
Leg 3 round 1: Google Harness² (guardrail blocked) |
3 |
55,515 (cache 0, 0%) |
1,849 |
57,364 |
Leg 3 retry: Google Harness² (7-stage brief) |
8 |
58,474 (cache 6,912, only 11.8%) |
3,474 |
61,948 |
Leg 3 both rounds: Google Harness² |
11 |
113,989 (cache 6,912, 6.1%) |
5,323 |
119,312 |
Time and estimated costs
| Execution phase and harness | Underlying log / event source | Measured time | Converted per-step cost |
|---|---|---|---|
Leg 1: Pi 1.4.0 (relay rough filter) |
conversation .jsonl receipts |
8.59s |
approx. ¥0.048 |
Baseline: Pi 1.4.0 (standalone rough filter) |
soduwork.db (01a1d120) |
— | approx. ¥0.051 |
Leg 2: Qwen Code 0.21.8 |
Runner raw.log step_finish |
16.85s |
cannot be estimated (billing boundary in this section) |
Leg 3 round 1: Google Harness² (guardrail blocked) |
Runner events.jsonl Round 1 |
13s trip |
approx. ¥0.117 |
Leg 3 retry: Google Harness² (7-stage brief) |
Runner events.jsonl Round 2 |
27s |
approx. ¥0.115 |
Leg 3 both rounds: Google Harness² |
events.jsonl Round 1+2 |
40s |
approx. ¥0.232 |
Session cumulative totals and per-harness breakdown need to be separated
In the underlying ai_usage_event table, aggregating by conversation_id puts the known usage (Pi's 71,043 + Harness²'s 119,312 = 190,355 tokens) on the last-used harness2 row; the upper-level overview API shows Pi 899k and harness2 119k.
The latter is overview-scope backend data, not the relay conversation's per-item bill; neither can be credited entirely to H2. Both places lack an accountable Qwen usage figure.
Also, "known model cost" shows "pending reconciliation". If preset reference rates are provided, the currency, applicable model, and update time should be marked so admins can verify.
These records give two reminders:
Short outputs can still contain multiple reasoning passes' overhead.Google Harness² round 2 directly summarized the above without calling a file-write tool, yet still sent 8 model requests. That round's input cache-hit rate was 11.8%, lower than Pi rough filter's 76.4%; round 1 planning was 0%.
Stage prompts and prefix changes may be one cause, but cache hot/cold state was not controlled and prefixes were not compared request-by-request, so the cause of the difference cannot be confirmed. At the table's rates, the successful brief round costs about 2.4x the Pi rough filter, and about 4.8x when counting the failed round; these are only cost ratios between different tasks.
Whether money is saved still lacks a full comparison: no single harness ran all three steps alone, and Qwen Code's billable usage is missing, so a total cost or savings ratio for the mixed relay cannot be given. The standalone Pi rough filter in the table works as a first-step reference, not a substitute for a full-process comparison.
Appendix: official public comparison case (five-round dialogue relay)
The official public comparison case also provides a "logistics network shutdown decision" five-round evaluation. Per the case description, the tasks come from the public JobBench management-analyst set, MIT licensed, translated into Chinese, with a fictional company.
Data source: quoted from the official public comparison case; I did not reproduce this experiment, and this article attaches no independently reviewable scoring record, so it is treated as a supplementary case, not merged into this experiment's conclusions.
The task was to find 3–5 shutdown or merger candidates among 19 factories and write a board brief. The first 4 rounds ran on Pi + GLM-5.3-Flash, each round fixing one hard rule (five scoring weights; 12 zero-business-volume factories out of 19 not directly judged for shutdown; the largest factory carrying 92.7% of orders listed side by side with both COO and board perspectives; a fixed customer-churn risk rule). Round 5 switched within the same dialogue to Qwen Code, OpenCode, and Codex Harness (model DeepSeek-V4.1-Flash), and round 5's instruction did not repeat any earlier rule.
The official case records:
- All three harnesses retained all 4 rules (
4/4) in round 5 without restating them; the evaluation rated final-draft quality on par with not switching harnesses at all. - A control group opening a new conversation used a 336-character manual handoff summary and also kept
4/4. The test group summarized the benefit: "the biggest advantage of switching harnesses mid-way is not needing to hand-write that handoff summary, not making the model magically smarter."
What comparisons to add next time
Verifying whether segmented relay is cost-effective needs each scheme to process the same input and delivery requirements, verify against consistent quality standards, and count failures, retries, and all model requests.
Developers who regularly use multiple CLI agents: the same workspace and the automatic handoff summary reduce manual organizing at switch time. Here all three harnesses connected to the same model API, so this verifies harness switching; whether migration works smoothly under vendor rate limits or outages needs separate testing.
R&D and tech leads: the tool can manage multiple harnesses and inspect the usage receipts obtained. But the ACP path lacks billable usage, and the backend summary and conversation breakdown need alignment; no complete budget conclusion can be drawn yet. SoduWork is currently in public testing; evaluate with your own chain before production use.
People doing only lightweight Q&A with a single model: the benefits of multi-harness management, relay, and reconciliation may be limited; the added deployment and maintenance may not be worth it.
I plan to organize the macOS queue-starvation trigger conditions into a reproduction note and submit it to the repo. If you also want to try switching harnesses in one conversation, start from the source and the integration docs:
- GitHub repo: mdiri-ai/SoduWork
- Docs directory in the repo: https://github.com/mdiri-ai/SoduWork/tree/main/docs
For harness adaptation or accounting issues, attach version, reproduction steps, and desensitized logs in an Issue or PR for easier diagnosis.