feat: use enabled field from config to determine which models run

Changed the API to respect the 'enabled' field in model configurations,
rather than requiring models to be explicitly specified in API requests.

Changes:
- Make 'models' parameter optional in POST /simulate/trigger
- If models not provided, read config and use enabled models
- If models provided, use as explicit override (for testing)
- Raise error if no enabled models found and none specified
- Update response message to show model count

Behavior:
- Default: Only runs models with "enabled": true in config
- Override: Can still specify models in request for manual testing
- Safety: Prevents accidental execution of disabled/expensive models

Example before (required):
  POST /simulate/trigger
  {"config_path": "...", "date_range": [...], "models": ["gpt-4"]}

Example after (optional):
  POST /simulate/trigger
  {"config_path": "...", "date_range": [...]}
  # Uses models where enabled: true

This makes the config file the source of truth for which models
should run, while still allowing ad-hoc overrides for testing.
This commit is contained in:
2025-10-31 15:12:11 -04:00
parent 20506a379d
commit ec2a37e474
3 changed files with 38 additions and 589 deletions

View File

@@ -7,6 +7,13 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
## [Unreleased]
### Changed
- **Model Selection** - `enabled` field in config now controls which models run
- API `models` parameter is now optional
- If not provided, uses models where `enabled: true` in config
- If provided, explicitly overrides config (for manual testing)
- Prevents accidental execution of all models
### Removed
- **Web UI Port** - Removed unused web dashboard port configuration
- Removed port 8888 from docker-compose.yml (not implemented)