Wire catalyst score into the live watcher and arming rank
Completes the Phase 2 loop: the catalyst score now actually reaches the runtime decision, not just the pure functions. Gated behind its own flag so enabling the Phase 1 advisory/dashboard never silently changes trade scoring. - OllamaConfig.catalyst_score_enabled (NEWS_CATALYST_SCORE_ENABLED, default off). - Watcher accepts an optional catalyst_score_provider (symbol -> 0..1 | None) and passes it into evaluate_setup; a None provider reproduces today's behavior. The provider is injected so runtime/ stays free of research/ imports. - run_live_paper: one TTL-cached catalyst provider shared by the watcher and the execution service; the watcher gets the score provider only when the blend is enabled. step_arm gains a gated graded ranking multiplier (bullish catalyst boosts by 1+gain*score; a confirmed dilutive offering is sunk below the armed cut), falling back to the existing binary news boost when off. - Add the enrich task to the run_pass pipeline order so a single --once pass also runs enrichment (previously only the continuous loop did). - .env.example documents the new flags; watcher tests cover the blend + the no-op None-provider case. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01M5HTMkaadGDnAPtXe2hWwg
This commit is contained in:
5 files changed
+138
-24
No files matched your search
@@ -166,6 +166,9 @@ class OllamaConfig(BaseModel):
|
||||
# Phase 2 dilution veto (ships OFF).
|
||||
dilution_veto_enabled: bool = False
|
||||
dilution_veto_min_conviction: float = 0.6
|
||||
# Phase 2 score blend (ships OFF; separate from enrichment so turning on the
|
||||
# advisory/dashboard does NOT silently change trade scoring).
|
||||
catalyst_score_enabled: bool = False
|
||||
|
||||
@classmethod
|
||||
def from_env(cls, env: dict[str, str] | None = None) -> "OllamaConfig":
|
||||
@@ -205,6 +208,7 @@ class OllamaConfig(BaseModel):
|
||||
enrichment_batch_limit=i("NEWS_ENRICH_BATCH_LIMIT", 50),
|
||||
dilution_veto_enabled=b("NEWS_DILUTION_VETO_ENABLED", False),
|
||||
dilution_veto_min_conviction=f("NEWS_DILUTION_VETO_CONVICTION", 0.6),
|
||||
catalyst_score_enabled=b("NEWS_CATALYST_SCORE_ENABLED", False),
|
||||
)
|
||||
|
||||
|
||||
|
||||
Reference in new issue
Block a user