Skip to content

feat(backtest): add selectable stock pool presets - #441

Merged
hljhs-max merged 3 commits into
mainfrom
feat/backtest-stock-pool-selection
Sep 3, 2026
Merged

feat(backtest): add selectable stock pool presets#441
hljhs-max merged 3 commits into
mainfrom
feat/backtest-stock-pool-selection

Conversation

@hljhs-max

Copy link
Copy Markdown
Collaborator

Adds configurable stock-universe selection to Run Backtest.

Users can now choose from three versioned 30-symbol universes:

  • 30 ordinary stocks across 11 sectors
  • 30 funds and ETFs across major asset classes
  • A mixed universe containing 15 stocks and 15 funds

as well as the original choices.

The selected universe is previewed in the UI and resolved by the backend before the run starts. Its exact symbols and provenance are frozen and passed through the API, worker, CLI, and backtesting engine, ensuring queued runs remain reproducible even if the source catalog changes.

This change also updates LLM prompts to support non-DJIA universes, batches larger Alpaca data requests, and preserves existing DJIA, Magnificent 7, custom-asset, and iFinD behavior.

Purpose

Different stock universes can favor different trading strategies. A strategy that performs well on individual stocks may behave differently when applied to funds, ETFs, or a mixed universe.

These selectable pools make it possible to test and reproduce an agent’s strategy under consistent market scopes, compare its behavior across different universes, and identify which types of assets the strategy is most effective for.

Validation

  • 147 related tests passed
  • Frontend submission and roster preview behavior verified
  • Backend selection, validation, persistence, and worker handoff verified
  • JavaScript and Python syntax checks passed

- add versioned 30-symbol stock, fund, and mixed rosters to Run Backtest
- resolve and freeze backend pool selections across API, worker, CLI, and engine boundaries
- persist universe provenance and batch larger Alpaca requests
- cover selection, validation, compatibility, and frontend submission behavior
@vercel

vercel Bot commented Sep 3, 2026

Copy link
Copy Markdown
Contributor

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated
agentic-trading-lab Ready Ready Preview Sep 3, 2026 8:25pm UTC

Comment thread dashboard/backend/api/routers/backtests.py Fixed
@hljhs-max
hljhs-max merged commit c572645 into main Sep 3, 2026
7 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants