Blog
Writing
Life, tech, and everything in-between.
Evaluator-Optimizer: Iterative Refinement with a Separate Critic LLM
Some tasks improve on a second pass, but only when the critic is a separate LLM with its own mandate. Asking a generator to grade its own work produces confident praise for mediocre output.
Orchestrator-Workers: Dynamic Task Decomposition for LLM Agents
Routing picks from a fixed list. Parallelization runs a fixed fan-out. The orchestrator-workers pattern lets a planning LLM decide, at runtime, what the subtasks are and how many workers to spawn.
Parallelizing LLM Calls: Sectioning and Voting
Parallelizing LLM calls is not a single pattern. Sectioning runs different subtasks on the same input; voting runs the same task several times and aggregates. Choosing the wrong shape produces the wrong kind of improvement.
Routing: Classify and Dispatch LLM Requests to Specialists
A prompt tuned to handle billing refunds well is almost never the same prompt that handles technical outages well. Route the input instead, and give each category a prompt, a toolset, and sometimes a model of its own.
Prompt Chaining: Sequential LLM Pipelines with Validation Gates
A single unscoped prompt that tries to plan, draft, validate, and polish in one pass is a coin toss. Chain narrow calls instead, and put programmatic gates between them.
Context Engineering for Agents
The question is not which prompt to write. It is which tokens deserve a place in the context window on this turn. Context engineering is the discipline that answers that question.
Structured Output from LLMs
A free-text response that sometimes parses and sometimes does not is the single largest source of flakiness in agentic systems. Structured output makes the model behave like an ordinary function.
The Augmented LLM: Retrieval, Tools, and Memory
A bare language model is a closed system. It cannot look up a fresh fact, cannot act in the world, cannot remember the last conversation. Every non-trivial agent is an attempt to lift one or more of those three constraints.
Workflows Versus Agents in LLM Systems
The term agent has become overloaded, and the overloading is expensive. A system in which the language model controls its own flow costs more to run and more to debug. The default should be a workflow.