core practice · coding problem

Route by cost and difficulty

Classify queries: "2+2" → small model; "design payment system" → large model. Write a 2-rule router on length and keyword "design".

The mechanism

Not every request needs the frontier model. A router classifies difficulty and dispatches: small/cheap model for easy calls, large model for hard ones — with cost and latency tracked per route.

Study Model Routing

Expected evidence

Rule-based router with fallback to large on low confidence.

Try this drill in the practice workspace →

Hints when you need them
  • Cheap path for easy queries.
  • Escalate on failure.

Watch for these mistakes

  • Routing without evals, so quality silently drops
  • No fallback when the cheap model fails

Check the sources

Browse all practice briefs