Deleting Three Agents for 40 Lines of Python Cut Latency 9s to 800ms and Cost 75%

Prestigious_Style267 · reddit · 2026-09-23

A developer refactored a multi-agent customer support triage system that a client paid an agency $40K to build. The original architecture—a master router agent, sentiment classifier, context extractor, and tool selector orchestrated in a large graph—burned 12,000 tokens and 9 seconds of latency per query, and the router hallucinated twice a day, sending simple refund tickets to tier-3 engineering when customers used the word "broken."

The fix: delete three middle agents and replace routing with a fast regex pass, an embedding cosine-similarity check, and forty lines of plain Python conditionals. Results:

The author argues the agent space has "caught a disease" of solving deterministic problems with nondeterministic LLM loops: if a router can be a switch statement or pydantic validator, agentifying it just burns compute to look sophisticated. He asks where the line should be drawn between genuine agentic behavior and procedural code that never needed an LLM.

Original post →

More from coding & agent

coding & agent channel →