TradingAgents/tradingagents/agents/scanners
Copilot 3b6e399563
Resolve merge conflicts after PR #18 merge into main (#19)
* feat: add extract_json() utility for robust LLM JSON parsing

Handles DeepSeek R1 <think> blocks, markdown code fences, and
preamble/postamble text that LLMs wrap around JSON output.
Applied to macro_synthesis, macro_bridge, and CLI scan output.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>

* feat: opt-in vendor fallback — fail-fast by default (ADR 011)

Silent cross-vendor fallback corrupts signal quality when data contracts
differ (e.g., AV news has sentiment scores yfinance lacks). Only methods
with fungible data contracts (OHLCV, indices, sector/industry perf,
market movers) now get fallback. All others raise immediately.

- Add FALLBACK_ALLOWED whitelist to interface.py
- Rewrite route_to_vendor() with fail-fast/fallback branching
- Improve error messages with method name, vendors tried, and exception chaining
- Add 11 new tests in test_vendor_failfast.py
- Update ADRs 002 (superseded), 008, 010; create ADR 011

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>

* Initial plan

* fix: address PR #18 review findings - type safety, import ordering, EOF newline

Co-authored-by: aguzererler <6199053+aguzererler@users.noreply.github.com>

* fix: add inline comments explaining combined ValueError catch in json_utils.py

Co-authored-by: aguzererler <6199053+aguzererler@users.noreply.github.com>

---------

Co-authored-by: Ahmet Guzererler <guzererler@gmail.com>
Co-authored-by: Claude Opus 4.6 <noreply@anthropic.com>
Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>
Co-authored-by: aguzererler <6199053+aguzererler@users.noreply.github.com>
2026-03-18 14:38:48 +01:00
..
__init__.py feat: Complete 3-phase LLM scanner pipeline with inline tool execution 2026-03-17 08:41:40 +01:00
geopolitical_scanner.py feat: Complete 3-phase LLM scanner pipeline with inline tool execution 2026-03-17 08:41:40 +01:00
industry_deep_dive.py feat: improve Industry Deep Dive report quality with enriched data, sector routing, and tool-call nudge 2026-03-17 20:10:45 +01:00
macro_synthesis.py Resolve merge conflicts after PR #18 merge into main (#19) 2026-03-18 14:38:48 +01:00
market_movers_scanner.py feat: Complete 3-phase LLM scanner pipeline with inline tool execution 2026-03-17 08:41:40 +01:00
sector_scanner.py feat: Complete 3-phase LLM scanner pipeline with inline tool execution 2026-03-17 08:41:40 +01:00