pam ▸ docs/generated/ralph_loop_2026-03-16_search_replay_parity.md
updated 2026-03-28
Ralph Loop Note: Search/Replay Parity
Date: 2026-03-16 Focus: replay evaluation quality
Bottleneck
Pam’s bounded search path in research/search.py had its own decision logic copy.
That makes search scores vulnerable to drifting away from the actual replay path in
research/strategy.py as sleeves evolve.
Change
- Added
resolve_params()toresearch/strategy.pyso replay and search can share the same parameter merge behavior. - Changed
research/search.pyto delegate candidate decisions toresearch.strategy.decide(..., params=...)instead of maintaining a separate rule copy. - Added focused tests to lock search/strategy parity, including the
test_tradepath. - Documented the rule in
research/README.md.
Validation
Command:
PYTHONPATH=. pytest -q tests/test_research_search.py
Result:
4 passed in 0.01s
Additional smoke check confirmed identical actions from search and replay strategy for the same observation and params override.
Why This Matters
This does not create more trades by itself. It improves the trustworthiness of replay search results so future sleeve work is evaluated on the exact same decision surface used by the replay gate.