fable-agent/PHASES/phase-08-adaptive-router.md

810 B
Raw Blame History

Phase 8: Adaptive Router

Purpose: Route execution paths based on accumulated state and historical performance. TS Module: src/tier2-primitives/workflows/adaptive-router.ts

What It Does

At workflow branch points, chooses the path most likely to succeed. Uses epsilon-greedy: 90% exploit best path, 10% explore alternatives.

Path Selection

  1. Check historical path records (quality × success rate × frequency)
  2. If no history: use accumulator state for first-guess routing
  3. Record outcome after each branch execution
  4. Update path scores: weighted average of quality + success + frequency bonus

Key Rules

  • Exploration (epsilon) prevents overfitting to early successes
  • Path history resets on session boundary
  • For new tasks, routes based on semantic similarity to past paths