Commit Graph

7 Commits

Author SHA1 Message Date
Ahmet Guzererler 0b4260a4e2 feat: add agentic memory scaffold and migrate tracking files to docs/agent/
Migrate DECISIONS.md, MISTAKES.md, PROGRESS.md, agents/, plans/, and
tradingagents/llm_clients/TODO.md into a structured docs/agent/ scaffold
with ADR-style decisions, plans, templates, and a live state tracker.

This gives agent workflows a standard memory structure for decisions,
plans, logs, and session continuity via CURRENT_STATE.md.

Agent-Ref: docs/agent/plans/global-macro-scanner.md
State-Updated: Yes

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-17 17:14:11 +01:00
copilot-swe-agent[bot] 373a03d744 docs: update PROGRESS, DECISIONS, MISTAKES, CLAUDE with env override implementation
- PROGRESS.md: added env override milestone, updated test count (38 total),
  marked Mistake #9 as resolved, added all new/modified files from PR #9
- DECISIONS.md: added Decision 008 (env var config overrides),
  Decision 009 (thread-safe rate limiter), Decision 010 (broader
  vendor fallback exceptions), updated Decision 007 status to superseded
- MISTAKES.md: updated Mistake #9 status to RESOLVED, added Mistake #10
  (rate limiter held lock during sleep)
- CLAUDE.md: added env var override convention docs, updated critical
  patterns with rate limiter and config fallback key lessons, updated
  mistake count to 10

Co-authored-by: aguzererler <6199053+aguzererler@users.noreply.github.com>
2026-03-17 14:37:41 +00:00
copilot-swe-agent[bot] 2193ff3fa1 fix: allow .env variables to override DEFAULT_CONFIG values
Merged origin/main and resolved all 8 conflicting files:
- CLAUDE.md: merged MISTAKES.md ref + Project Tracking section + env override docs
- cli/main.py: kept top-level json import, kept try/except in run_pipeline
- tool_runner.py: kept descriptive comments for MAX_TOOL_ROUNDS
- alpha_vantage_common.py: kept thread-safe rate limiter, robust error handling
- interface.py: kept broader exception catch (AlphaVantageError + ConnectionError + TimeoutError)
- default_config.py: kept _env()/_env_int() env var overrides with load_dotenv() at module level
- scanner_graph.py: kept debug mode fix (stream for debug, invoke for result)
- macro_bridge.py: kept get_running_loop() over deprecated get_event_loop()

Co-authored-by: aguzererler <6199053+aguzererler@users.noreply.github.com>
2026-03-17 14:25:10 +00:00
Ahmet Guzererler 61668fed6b feat: Complete 3-phase LLM scanner pipeline with inline tool execution
The scanner pipeline now runs end-to-end: Phase 1 (geopolitical, market
movers, sector scanners in parallel via Ollama), Phase 2 (industry deep
dive), Phase 3 (macro synthesis via OpenRouter/DeepSeek R1).

Key changes:
- Add tool_runner.py with run_tool_loop() for inline tool execution in
  scanner agents (scanner graph has no ToolNode, unlike trading graph)
- Fix vendor fallback: catch AlphaVantageError base class, raise on
  total failure instead of embedding errors in return values
- Rewrite yfinance sector perf to use SPDR ETF proxies (Sector.overview
  has no performance data)
- Fix Ollama remote host support in openai_client.py
- Add LangGraph state reducers for parallel fan-out writes
- Add --date CLI flag for non-interactive scanner invocation
- Fix .env loading to find keys from both CWD and project root
- Add hybrid LLM config (per-tier provider/backend_url)
- Add project tracking: DECISIONS.md, PROGRESS.md, MISTAKES.md
- Add 9 new test files covering exceptions, fallback, and routing

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-17 08:41:40 +01:00
copilot-swe-agent[bot] 44d13b6924 Implement all review feedback for Global Macro Scanner: fix exception handling, index fetching efficiency, conditional logic, CLI DRY, error prefixes, remove artifacts
Co-authored-by: aguzererler <6199053+aguzererler@users.noreply.github.com>
2026-03-15 10:43:26 +00:00
Ahmet Guzererler 6242af3b99 feat: Add Global Macro Scanner feature
- Added market-wide analysis capabilities (movers, indices, sectors, industries, topic news)
- Implemented yfinance and Alpha Vantage data fetching modules
- Added LangChain tools for scanner functions
- Created scanner state definitions and graph components
- Integrated scan command into CLI
- Added configuration for scanner_data vendor routing
- Included test files for scanner components

This implements a new feature for global macro scanning to identify market-wide trends and opportunities.
2026-03-14 22:22:13 +01:00
Ahmet Guzererler 405f969bd6 agents and plan 2026-03-14 12:18:13 +01:00