v5.3.0 — Context Throttler, Partition Planner, Coverage Gate, Route Classifier
Four new Phase 12 orchestration modules — all dependency-free, fully pluggable, and wired into runTeam().
What's new in v5.3.0
Four new Phase 12 orchestration modules — all dependency-free, fully pluggable, and wired into runTeam().
Context Throttler (lib/context-throttler.ts)
Prune blackboard keys before LLM calls based on per-agent scope metadata tags. Prevents context pollution when agents only need a subset of shared state.
filterState()pure function +ContextThrottlerclass- Wildcard
["*"]pass-through,exactMatch,maxKeysoptions registerScope/deregisterScope/filterAll
Partition Planner (lib/partition-planner.ts)
Assign non-overlapping focus areas to agents before DAG execution. Eliminates redundant research across parallel agents.
- Pluggable
PartitionPlannerFunction+ built-increateLexicalOverlapChecker()(zero cost) parsePartitionJSON()with markdown-fence strippingPartitionPlanner.injectConstraint()injects_partitionConstraintinto task paramsstrictOverlapmode throws on detected overlap
Coverage Gate (lib/coverage-gate.ts)
Recursive refinement loop — evaluates completeness and re-runs GoalDecomposer for gaps until coverage score >= threshold.
CoverageGateclass: configurablethreshold(default 90) andmaxRefinements(default 3)- Built-in
createKeywordEvaluator()+createLLMEvaluator()for LLM-backed scoring - Fail-open when max refinements reached; full
history+gapsRequeuedtracking
Route Classifier (lib/route-classifier.ts)
Short-circuit routing — classify goals before DAG planning and bypass the blackboard entirely for FACTUAL_LOOKUP goals.
RouteClassifierclass with pluggableClassifierFunction- Built-in
createHeuristicClassifier()(keyword + length heuristic, zero cost) createLLMClassifier()for LLM-backed classificationroute()short-circuits to a lookup agent and surfaces executor errors
FSM: WORKFLOW_STATES.EVALUATING
New state in JourneyFSM for the Coverage Gate refinement loop — orchestrator is re-evaluating completeness.
runTeam() — 4-phase execution
All four modules integrate into runTeam() via new optional RunTeamOptions fields:
- Route classification → short-circuit if
FACTUAL_LOOKUP - Partition schema + context throttler → filtered per-agent context +
_partitionConstraintinjected into task params - Normal DAG execution
- Coverage gate → recursive gap decomposition until threshold met
Fully backward-compatible — all new fields are optional.
Stats
- 28 test suites, 2,899 passing assertions (up from 27 / 2,834)
test-phase12.ts— 65 new deterministic tests (no LLM/network/I/O)
Full changelog: CHANGELOG.md