Review fixes applied:
- format_signals_for_role accepts both list and JSON string
- Test imports aligned with actual function names
- Test assertions use actual StrategySignal keys
- Tax optimization: informative message when lot data unavailable
- Pairs trading: single batch yf.download replaces 10 sequential calls
Based on: Kakushadze & Serur, '151 Trading Strategies',
Palgrave Macmillan 2018. SSRN 3247865, DOI 10.1007/978-3-030-02792-6
InvestDebateState was missing bull_history, bear_history, judge_decision.
RiskDebateState was missing aggressive_history, conservative_history,
neutral_history, latest_speaker, judge_decision. This caused KeyError
in _log_state() and reflection, especially with edge-case config values.
- Add StatsCallbackHandler for tracking LLM calls, tool calls, and tokens
- Integrate callbacks into TradingAgentsGraph and all LLM clients
- Dynamic agent/report counts based on selected analysts
- Fix report completion counting (tied to agent completion)