Yeda AI Tips · #205

Español

Plan Expensive, Build Cheap, Review Sharp

The people getting the most out of AI coding agents have stopped asking "which model is best?" and started asking "which model for which part of the task?" A single coding task isn't one job — it's three: planning, execution, and review. Each one has a completely different shape, and paying frontier prices for all three is how you burn money on the parts that don't need it.

One task, three roles

Route a single task across three passes:

  1. Plan with your strongest, priciest model. The hard part of coding is the high-level thinking: read the whole codebase, understand the request, design the approach, see around corners. Give this to the best model you have — a frontier model from OpenAI or Anthropic — because a bad plan poisons everything downstream.
  2. Execute with a cheap, fast model. Once a solid plan exists, writing the code is the easy part. You don't need a frontier model to type out functions against a spec. A cheaper model — something like Grok's coding tier or Cursor's Composer — does this well at a fraction of the price.
  3. Review with a second frontier model. Hand the finished code to a different strong model and ask it to check the work against the plan. A model reviewing another model's code catches more bugs than one reviewing its own — self-review has blind spots.

Why execution is where you save

The counterintuitive part: execution is the most expensive stage, not planning. It comes down to the split between input and output tokens, and output tokens cost far more (roughly $5 per million input vs. $30 per million output on a typical frontier model).

StageInput tokensOutput tokensCost driver
PlanHigh — reads the whole codebaseLow — just a planCheap input
ExecuteLow — reads the planHigh — writes all the codeExpensive output
ReviewHigh — reads the codeLow — a verdictCheap input

Execution reads little and writes a lot, so it burns the most expensive tokens. That's exactly the stage a non-frontier model handles fine — which means you're swapping the priciest model out of the priciest stage.

The cost math

Run the same task three ways and the numbers are stark:

Same output, roughly a third of the cost. And often faster, because the cheap execution model is also the fast one, and the biggest frontier models tend to be the slowest.

Why cross-model review works

The review pass isn't just about cost — it's a quality upgrade. Different models write and reason differently: they cluster their mistakes in different places. One model tends to drop required behavior; another misreads semantic intent. When a second model reviews the first model's pull request, it isn't fighting the same blind spots that produced the bug, so it catches more of them. Reviewing your own code — human or model — is where errors hide.

Making it practical

You need access to several models behind one workflow. A router like OpenRouter exposes many providers' models through a single OpenAI-compatible API, so you can point your plan step at one model and your execute step at another without wiring up three vendor SDKs. Set up three prompts — a planner, an executor that's fed the plan, and a reviewer that's fed the code plus the plan — and route each to the right model.

Takeaway

Stop paying frontier prices for the easy part. Plan expensive, build cheap, review sharp: your best model designs, a cheap fast model implements, and a second frontier model checks the work. Same result, about a third of the cost, and usually quicker — because not every token in a task deserves the same model.

Resources

Building an AI feature? Yeda AI designs, audits, and ships production LLM systems.

Talk to us · Read the blog