Spaces:
Sleeping
Sleeping
Commit History
-
fix: retrospective agent evaluated wrong month and crashed; persist its analysis to Reports tab
Bibhu Mishra +1: Claude Sonnet 5The retrospective always evaluated (current month - 1), so when trading went live mid-June it kept evaluating an empty May instead of June where the real trades were, silently skipping strategy tuning. Now falls back to the current in-progress month when trading started after the naive previous month. Also fixes a MultipleResultsFound crash once a month has more than one portfolio snapshot, and a "^SPY" ticker typo (the caret prefix is for indices, not the SPY ETF) that made get_spy_monthly_return always return None. Also adds a retrospective_reports table + /retrospective-reports API + a "Monthly Retrospective" tab on the Reports page, so the pattern analysis, tuning rationale, and PDF that the agent already produces are persisted and visible in the UI instead of living only inside the PDF and the raw run log. Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>a381fc9
-
fix: PDF proxy, 0-qty positions, portfolio chart dedup, SQLite UTC dates
Bibhu Mishra +1: Claude Sonnet 4.6- PDF: remove partial select in getPdfPath (TypeORM select:{} quirk returned null even when row exists); fall back to GH_TOKEN env var in addition to GITHUB_TOKEN so HuggingFace secret naming doesn't matter - Positions: filter quantity > 0 in portfolio service so 0-qty open positions are hidden from dashboard and the open-positions table - Portfolio chart: deduplicate snapshots to one per calendar day (last value wins) to avoid repeated X labels and a cluttered line; rotate labels when many days; proper $ formatter on Y axis - SQLite dates: add SqliteDateSubscriber that undoes the local-timezone shift Node applies when parsing bare "YYYY-MM-DD HH:MM:SS" strings, so local dev times match the PostgreSQL pg-type-parser fix in production Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>73e0e3c
-
Add GitHub Actions CI/CD, HF Space deployment, market hours guard, and static serving
Bibhu Mishra +1: Claude Sonnet 4.6- Dockerfile (multi-stage Node build, port 7860 for HuggingFace) - .github/workflows/deploy-hf.yml — force-push to HF Space on every main push - .github/workflows/market_analyst.yml — cron 9:30 AM CST Mon–Fri + workflow_dispatch - .github/workflows/paper_trader.yml — crons 10 AM / 12 PM / 2:45 PM CST Mon–Fri - .github/workflows/retrospective.yml — cron Mon 5 AM UTC (Sun 11 PM CST), no market gate - agents/core/market_hours.py — check_or_exit() exits cleanly when market is closed; FORCE_RUN=true bypasses (set automatically on workflow_dispatch from admin) - Market Analyst and Paper Trader call check_or_exit() at startup - api/src/app.module.ts — ServeStaticModule serves ui/dist when present (production) - api/src/main.ts — add HuggingFace Space origin to CORS - api/src/agent-runs/agent-runs.service.ts — trigger() now dispatches GitHub Actions workflow_dispatch with force=true instead of spawning local shell scripts - ui/src/views/AdminView.vue — live market-hours banner + market tag…abc493d