From c6b7202a0c3309978ebec4432c9afefa030559e7 Mon Sep 17 00:00:00 2001 From: cardosofede Date: Tue, 3 Oct 2023 16:34:24 -0300 Subject: [PATCH] (feat) simplify file templates --- utils/file_templates.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/utils/file_templates.py b/utils/file_templates.py index bee0ac16..ad288294 100644 --- a/utils/file_templates.py +++ b/utils/file_templates.py @@ -66,7 +66,7 @@ def get_optuna_suggest_str(field_name: str, properties: Dict): if field_name == "candles_config": return f"""{field_name}=[ CandlesConfig(connector=exchange, trading_pair=trading_pair, - interval="3m", max_records=1000000) # Max number of candles for the real-time bot, + interval="1h", max_records=1000000) ]""" if field_name == "strategy_name": return f"{field_name}='{properties.get('default', '_')}'" @@ -111,8 +111,8 @@ def strategy_optimization_template(strategy_info: dict): def objective(trial): try: # General configuration for the backtesting - exchange = trial.suggest_categorical('exchange', ['binance_perpetual', ]) - trading_pair = trial.suggest_categorical('trading_pair', ['BTC-USDT', ]) + exchange = "binance_perpetual" + trading_pair = "BTC-USDT" start = "2023-01-01" end = "2023-08-01" initial_portfolio_usd = 1000.0