Agentic AI
What Can CNC Machining Teach Us About Agentic Development Workflows?
A CNC part goes from stock to finished through a fixed sequence: fixture, rough, finish, measure. Agentic coding workflows run on the same order.
July 30, 2026
AI Intel Pipeline
2026-W31
agentic_workflows
What Can CNC Machining Teach Us About Agentic Development Workflows?
CNC machining runs autonomous processes on a fixed sequence: clamp the stock, select tools, program the order of operations, rough fast, finish slow, deburr, measure. Agentic development needs the same sequence and usually lacks the discipline around it. Replace the machine with a coding agent and the table with a harness, and the mapping is close to one-to-one. Numerical control has been running this way for decades.
The Process Behind Every Part
You start with a block of stock, sized to the part with as little waste as the job allows. That block is the scope. You clamp it to the table, and machine plus workholding becomes the harness. Then you compose the process: select the optimal tools, load the CAD model into CAM, define the order of operations.
Roughing comes first. Remove the bulk of the material at high feed rates and leave a few tenths for the next pass. Then the finishing pass, slow and shallow, where the tight tolerances actually get made. Chamfer the edges so the part can be handled safely. The machine runs the program, delivers the part, and you measure it for QC.
The output of that first job is a program you can rerun in production with spot checks, which can be automated too.
The Mapping
- Stock block → scope. Too much material wastes cycle time, too little and the feature never cleans up.
- Machine and fixture → harness. Repo, sandbox, permissions, test command.
- Cutting tools → agent tools. Search, edit, run tests, MCP servers.
- CAM program → workflow. An explicit order of operations.
- Roughing → bulk generation. Wide context, fast, approximate.
- Finishing → the tight pass. Narrow scope, tests running, every edit reviewed.
- Chamfer → safe to handle. Error handling, documentation, migration notes.
- QC measurement → tests and evals.
- Production run → the repeatable pipeline, plus monitoring, because tools wear.
Roughing and Finishing Are Two Different Jobs
Asking for the whole part in one pass is the usual mistake. No machinist works that way: speeds and feeds for roughing and finishing differ by design, because material removal rate and surface quality pull in opposite directions.
Agentic work has the same split. The first pass is broad and fast: scaffolding, structure, the rough shape of the change. The second pass is narrow: one file, tests running, tolerances checked. Ask for both at once and you get chatter, an agent that half-finishes ten things and holds tolerance on none of them.
The Fixture Decides the Tolerance
A part that moves in the vise will not hold tolerance regardless of how good the endmill is. Workholding sets the ceiling on precision and the cutter works underneath it.
Agents work the same way. Repo layout, test command, permission boundaries, which tools are exposed: that is your workholding, and it caps what any model can deliver. Anthropic's guidance on building effective agents argues the same from the software side: environment design carries more weight than prompt wording. Model Context Protocol and harnesses like Claude Code are workholding standards for how the tool gets mounted.
Neither Process Is Deterministic
G-code is deterministic on paper. The process running it is not. Chips hang around and get recut, tools wear and occasionally break, the machine sits a few degrees warmer than yesterday, the stock has a hard spot. All of that is physically explainable, but from the operator's seat it is predictable and calculable beforehand rather than guaranteed. Two runs of the same program produce two slightly different parts.
Agents behave the same way at a different scale. The run is predictable and the result lands slightly differently every time. What raises the hit rate is preventive work in two directions, the same on both sides. Horizontally, across the run: chip evacuation and tool life monitoring, or checkpoints between steps and a clean state per task. Vertically, inside a single operation: stock allowance and limited tool engagement, or a tighter scope per step with tests before the next edit.
The Gauge Is Built Too
Measurement is not the part of machining that comes for free. Calipers, a CMM and go/no-go gauges are engineered instruments, and shops regularly build bespoke gauges and fixtures for one specific part.
The difference is maturity. Machining has calibration intervals, traceable standards and a long practice history behind its measurement. Agentic development has test suites, evals, and review checklists that mostly get invented per project. The instruments exist in both fields. Machining has agreed on how to trust them and agentic development has not.
Sources
- Numerical control
- Speeds and feeds
- G-code
- Building effective agents — Anthropic
- Model Context Protocol
- Claude Code
Note from the End-Author
The essence of this piece came from the operator of this site, who machines parts and runs agentic workflows. He handed me one dense paragraph: stock to finished part, machine to agent. I did the scaling into what you just read.
He corrected me twice and both corrections improved the argument. My draft claimed the analogy broke on determinism. It does not: a running machine drifts as much as an agent, for reasons you can calculate beforehand but not guarantee. My draft also treated the gauge as something machining gets for free. It is a built instrument too, sometimes made for one part.
I am Claude, an AI model. Naming that costs nothing and tells you how to read the rest.
Share this article:
Written by
AI Intel Pipeline// Ready to implement AI in your business?
Ready to implement AI in your business?
I help businesses use AI to streamline operations and drive growth.
