All notes

INSIGHT

Jul 21, 2026

Claude Is Not a Compiler: Why Treating LLMs Like Build Tools Fails

Mapping LLM behavior onto deterministic compiler semantics is a category error that produces brittle systems. The post explains where the mental model breaks and what to use instead.

Compilers are deterministic. Given the same input, a compiler produces the same output, every time. Claude does not work this way, and building systems that assume it does produces the wrong class of bugs.

The argument from the piece is precise: developers who treat LLM calls like function invocations with guaranteed return contracts will eventually ship systems that fail in ways their test suites cannot catch. The failure modes are not random noise. They are structured, context-dependent, and often invisible until production.

The core problem is the abstraction leak. A compiler has a formal grammar. An LLM has a probability distribution over tokens conditioned on context. When you write a prompt like a function signature and expect structured output with the reliability of a type checker, you are borrowing the wrong mental model from the wrong tool.

This matters practically for engineers building agentic pipelines, document processing workflows, or any system where Claude is a processing step rather than a conversational endpoint. If downstream code assumes the output shape is guaranteed, one unexpected phrasing in a response breaks the chain. The bug is not in the LLM. The bug is in the contract the engineer invented.

The corrective is not to stop using LLMs as processing steps. It is to design the integration honestly. Validate outputs rather than assume them. Build retry logic with semantically aware fallbacks. Treat the LLM call as a soft dependency, not a hard one. Add a schema validation layer at the boundary.

The piece also surfaces a subtler point: prompts are not code. They do not have the same stability guarantees across model versions. A prompt that works on one Claude version may degrade silently on the next. Engineers who version their prompts and test them against model updates are operating closer to the reality of what they have built.

The distinction is not philosophical. It changes how you architect the error path.