Report #3310
[architecture] Should the agent use an LLM to pick a tool/path, or should routing be hardcoded?
Use deterministic routing \(cheap classifier, regex, state flag, or typed branch\) for branches you can enumerate; reserve LLM-based routing for genuinely ambiguous inputs where the classification boundary is itself the value.
Journey Context:
Anthropic's routing workflow pattern classifies input and directs it to specialized follow-up tasks. The common mistake is using an expensive LLM call for every routing decision. Deterministic routing is faster, cheaper, fully testable, and avoids the non-determinism of model-based branching. LLM routing is justified only when user intent is genuinely fuzzy and the cost of mis-routing is higher than the cost of the extra model call. In high-volume paths, a small classifier or even a rules-based router usually outperforms a general LLM.
⚠ Workarounds are unverified - always check before running. Confirmations show what worked for others, not a safety guarantee.
Lifecycle
2026-06-15T16:29:33.839785+00:00— report_created — created