model-routing
Route tasks to appropriate model size based on confidence estimation. Use small model by default, escalate to large model only on low confidence. Achieves 87% faster learning and 10-30x cost reduction while maintaining accuracy. Triggers on "optimize cost", "model routing", "confidence threshold", "small model first", "escalate on uncertainty".
npx skills add majiayu000/claude-skill-registry --skill skill-model-routing-alchimie-di-circe-extractor-desktop-ap --agent claude-code
Same command for any agent — swap --agent for codex, cursor, copilot.
Weekly change comes from our own snapshots, not the repository page — it measures attention, not adoption.
# Model Routing ## Purpose Route tasks to small models by default, escalate to large models only on low confidence detection. Optimizes cost without sacrificing accuracy. **Benefits:** - **87% faster learning** - **10-30x cost reduction** - **Maintained accuracy** (95%) ## When to Use - Cost optimization for routine tasks - High-volume processing - Mixed-complexity workloads - Budget-conscious operations - Resource-efficient workflows **When NOT to use:** - Always complex tasks (use large model directly) - Critical tasks requiring maximum accuracy - Low latency requirements (routing adds overhead) ## Core Routing Pattern ### Basic Implementation ```python def route_with_confidence(task, confidence_threshold=0.7): """ Route to appropriate model based on confidence """ # Step 1: Try small model first result, confidence = small_model.execute(task) # Step 2: Check confidence if confidence >= confidence_threshold: # High confidence: use small model result return { 'result': result, 'model': 'small', 'confidence': confidence, 'cost': 0.001 } else: # Low confidence: escalate to large model result = large_model.execute(task) return { 'result': result, 'model': 'large', 'confidence': 1.0, '
- Purpose
- When to Use
- Core Routing Pattern
- Basic Implementation
- Confidence Estimation
- Confidence Signals
- Adaptive Router with Learning
- Performance Characteristics
- Cost Breakdown
- Threshold Tuning
- Conservative (High Accuracy Priority)
- Balanced (Default)
- Aggressive (Maximum Cost Savings)
- Example Workflows
What does the model-routing skill do?
Route tasks to appropriate model size based on confidence estimation. Use small model by default, escalate to large model only on low confidence. Achieves 87% faster learning and 10-30x cost reduction while maintaining accuracy. Triggers on "optimize cost", "model routing", "confidence threshold", "small model first", "escalate on uncertainty".
How do I install it?
Run `npx skills add majiayu000/claude-skill-registry --skill skill-model-routing-alchimie-di-circe-extractor-desktop-ap --agent claude-code` — it drops the skill into your project so the agent can pick it up. Swap the --agent value for codex, cursor or copilot if you use one of those.
Where does this skill come from?
From majiayu000/claude-skill-registry, a repository with 534 stars. We read it straight from the repository tree rather than a submitted listing, so what you see here is what is actually published.
Is a popular skill a good skill?
Not necessarily. Stars measure attention, not adoption — a repository can trend for a week and be abandoned. That is why we show the weekly change from our own snapshots next to the total, instead of a single flattering number.
