mirror of
https://github.com/NicolasBohn/NexQuant.git
synced 2026-08-08 20:47:44 +00:00
fix(strategy): Fix template variables, APIBackend import, and JSON extraction
- Fix {{ ic_values }} template variable not being replaced in prompts
- Fix APIBackend abstract class import (use factory from llm_utils)
- Add robust JSON extraction with python code block fallback
- Add response_format json_object to LLM payload
- Add detailed debug logging for LLM responses
- Simplify prompt variable replacement for readability
Files:
rdagent/components/coder/strategy_orchestrator.py
rdagent/components/prompt_loader.py
rdagent/app/cli.py
prompts/strategy_generation_v4.yaml
This commit is contained in:
+1
-1
@@ -567,7 +567,7 @@ def rl_trading_cli(
|
||||
@app.command(name="generate_strategies")
|
||||
def generate_strategies_cli(
|
||||
count: int = typer.Option(10, "--count", "-n", help="Number of strategies to generate"),
|
||||
workers: int = typer.Option(4, "--workers", "-w", help="Parallel workers"),
|
||||
workers: int = typer.Option(2, "--workers", "-w", help="Parallel workers (default: 2 to avoid LLM overload)"),
|
||||
style: str = typer.Option("swing", "--style", "-s", help="Trading style: daytrading or swing"),
|
||||
optuna: bool = typer.Option(True, "--optuna/--no-optuna", help="Enable Optuna optimization"),
|
||||
optuna_trials: int = typer.Option(30, "--optuna-trials", help="Number of Optuna trials per strategy"),
|
||||
|
||||
Reference in New Issue
Block a user