DEV Community

Abhishek Roy
Abhishek Roy

Posted on

Building Task Optimal mixture of experts

My name is Abhishek Roy, based in Kishanganj, Bihar. When building local AI agents, one major problem stands out: How do you route low-complexity prompts to fast, cheap models while preserving deep multi-pass reasoning for complex engineering prompts?

In this article, I’m walking through the design of TO-MoE, a local terminal-based Python prototype built on LangGraph.

Key Technical Sections:

Why Keyword Routing Fails (RFC Trap A vs Trap B)

Semantic Coordinate Routing with Cosine Similarity

Implementing Action Verb Dominance (AVD) & 1-Token Jury

State Protection: Silent Escalation & Quarantine Gates

Memory Architecture: ChromaDB Vector Store + Context-Assist Semantic Cache

Benchmark Results & Lessons Learned

Top comments (0)