Context
dragon_strategy.py has already been converted into a compatibility-first facade with layered orchestration support, but weak-family execution predicates remain embedded in the monolith. We now isolate these families physically while keeping RC1 path stability.
Goals / Non-Goals
Goals
- Extract predictive bridge predicates into a dedicated module.
- Extract deep-oversold subtype and confirmation predicates into dedicated modules.
- Preserve RC1 behavior on golden core fields.
- Strengthen testability with module-focused regression tests.
Non-Goals
- Introduce new predictive or deep-oversold optimization thresholds in RC1.
- Change report schemas or remove legacy reason strings.
- Promote experiment-branch behavior into RC1.
Decisions
1. Predicate extraction first, orchestration rewrite later
Only predicate logic moves now. Action ordering remains controlled by existing strategy flow to avoid path drift.
2. Keep strategy context as source of truth
New modules consume primitive inputs and context-derived values; they do not own position state mutation.
3. Preserve compatibility API
dragon_strategy.py remains callable exactly as before (DragonRuleEngine.run(...) unchanged).
Risks / Trade-offs
- [Predicate mismatch after extraction] -> pin with no-silent-path test and golden hash.
- [Context contract drift] -> pass explicit arguments rather than sharing mutable objects directly.
- [Over-extraction complexity] -> limit this phase to predictive/deep-oversold families only.
Migration Plan
- Add predictive bridge module and deep-oversold modules.
- Replace inline predicates in
dragon_strategy.py with module calls.
- Add module-focused tests.
- Run golden baseline, full tests, and daily pipeline smoke.
Rollback Plan
If any regression gate fails, revert extraction commit and keep previous compatibility layout.