Intent routing with Jev
Not every request deserves the same handler. TypeSafe’s intent-routing pattern puts Jev in front as a fast classifier:
- Some intents are a database lookup (order status).
- Some need a specialist LLM (product question, returns).
- Some need a human (unclear intent, or a complaint that scores too complex).
This unofficial page restates that pattern and links the glossary. Official mermaid + Python: docs.typesafe.ai/patterns/intent-routing. We do not sell keys.
Two questions, one call
Their customer-service sketch:
- Choice
intent— order_status, product_question, return_exchange, complaint, … - Score
complexity— used when the intent is a complaint.
Then code (their thresholds are examples):
- If intent confidence < 0.5 → human
order_status→ deterministic handler- product / returns → different LLM system prompts
complaint→ human ifcomplexity.score > 1or complexity confidence is low; else a complaint LLM
The expensive model runs only when the cheap decision says it must.
Compare to rules and queues. Pair with confidence-gated routing when the same intent has different risk levels. Sort probabilities for a ranked route only after the floor passes.
FAQ
Is intent a reserved API field? No. You name the key. See glossary: intent.
Should every company use 0.5? No. Fit on your labels (offline eval).
Hub: Use cases. Official: docs.typesafe.ai.
Sources
Public TypeSafe or adjacent documentation only. No private claims.