altimate-code
altimate-code copied to clipboard
Adaptive routing memory: learn task-class priors from outcomes
Parent: #1134
Learn from mistakes — adaptive routing memory:
- Persist per-task-class outcomes locally (class → primary attempts, gate passes, escalations). Task class = coarse heuristic (e.g. task-type keywords, project size bucket), not prompt text.
- Routing consult: classes whose primary success rate is below a threshold (default e.g. <20% over ≥5 samples) skip the primary and go straight to escalation; surfaced in the session UX ("skipping primary: this task class escalated 9/10 recent runs").
- User control: view (
route reportincludes the memory), reset, and disable (route.adaptive: false). - Keep it transparent and simple: counts and thresholds, no opaque scoring in v1.
- Tests: threshold behavior, decay/window, reset, disable.
Closing: after evaluating verifier-gated and cascade routing, we decided not to build an inferred per-request router. The direction is a strong default model with explicit, user-chosen modes. Reopen if routing is revisited.