Principle:20000419 Fauxnix Atomic Batch Execution
| Knowledge Sources | |
|---|---|
| Domains | Batch_Execution, MCP, Atomicity |
| Last Updated | 2026-10-26 00:00 GMT |
Overview
A batch execution technique that compiles all steps up front (parse + translate in pure mode), then runs them serially in a single session turn with shared timeout and output budgets, so no run/reset/dispose can interleave between steps.
Description
Atomic Batch Execution lets an agent submit a preplanned multi-step workflow in one MCP round trip. All steps are compiled (parsed and translated in PURE_TRANSLATION mode) before any step runs — a compile error in step N stops the whole batch before step 1 begins. Execution then proceeds serially in the same persistent session: later steps see cwd, env, and files from earlier steps. The timeout and output budgets apply to the complete batch, not per step. By default the batch stops after the first nonzero exit (stopOnError=true), but this can be disabled for workflows where later steps should run regardless. The result reports each step separately with a status (completed/failed/timed_out/cancelled/infrastructure_error) and a batch-level stopReason.
Usage
Use this principle when two or more commands or verification steps are already known and do not require model interpretation of intermediate output. It reduces MCP round trips and latency. Use separate single calls only when the next command depends on reading the previous output.
Theoretical Basis
[compile phase] for each step: plans[i] = translate(parse(step.cmd), PURE)
[execute phase] for each plans[i]: result[i] = runPlans(plans[i], session, remainingBudgets)
if stopOnError and result.exitCode != 0: stopReason = 'command_failed'; break
subtract stdout/stderr bytes from remaining budgets
[return] { results: ExecResult[], stopReason }
The lifecycle lock ensures no run/reset/dispose interleaves between steps.