"minimal_roi": {
"0": 0.03
}, // Take_profit exit value used with force_actions
- "stoploss": -0.03, // Stop_loss exit value used with force_actions
+ "stoploss": -0.02, // Stop_loss exit value used with force_actions
"unfilledtimeout": {
"entry": 10,
"exit": 10,
"freqaimodel": "ReforceXY",
"strategy": "RLAgentStrategy",
"minimal_roi": {"0": 0.03}, // Take_profit exit value used with force_actions
- "stoploss": -0.03, // Stop_loss exit value used with force_actions
+ "stoploss": -0.02, // Stop_loss exit value used with force_actions
...
"freqai": {
...
minimal_roi = {"0": 0.03}
process_only_new_candles = True
- stoploss = -0.03
+
+ stoploss = -0.02
+ # Trailing stop:
+ trailing_stop = True
+ trailing_stop_positive = 0.0099
+ trailing_stop_positive_offset = 0.01
+ trailing_only_offset_is_reached = True
+
use_exit_signal = True
+
startup_candle_count: int = 300
+ # @property
+ # def protections(self):
+ # fit_live_predictions_candles = self.freqai_info.get(
+ # "fit_live_predictions_candles", 100
+ # )
+ # return [
+ # {"method": "CooldownPeriod", "stop_duration_candles": 4},
+ # {
+ # "method": "MaxDrawdown",
+ # "lookback_period_candles": 48,
+ # "trade_limit": 20,
+ # "stop_duration_candles": 4,
+ # "max_allowed_drawdown": 0.2,
+ # },
+ # {
+ # "method": "StoplossGuard",
+ # "lookback_period_candles": int(fit_live_predictions_candles / 2),
+ # "trade_limit": 1,
+ # "stop_duration_candles": int(fit_live_predictions_candles / 2),
+ # "only_per_pair": True,
+ # },
+ # ]
+
@property
def can_short(self):
return self.is_short_allowed()
study_name = f"{identifier}-{study_namespace}-{pair}"
storage = self.optuna_storage(pair)
pruner = optuna.pruners.HyperbandPruner()
- self.optuna_study_delete(study_name, storage)
+ if self.__optuna_config.get("continuous", True):
+ self.optuna_study_delete(study_name, storage)
study = optuna.create_study(
study_name=study_name,
sampler=optuna.samplers.TPESampler(
direction=optuna.study.StudyDirection.MINIMIZE,
storage=storage,
)
- self.optuna_hp_enqueue_previous_best_trial(pair, study)
+ if self.__optuna_config.get("warm_start", True):
+ self.optuna_hp_enqueue_previous_best_trial(pair, study)
logger.info(f"Optuna {study_namespace} hyperopt started")
start = time.time()
try:
study_name = f"{identifier}-{study_namespace}-{pair}"
storage = self.optuna_storage(pair)
pruner = optuna.pruners.HyperbandPruner()
- self.optuna_study_delete(study_name, storage)
+ if self.__optuna_config.get("continuous", True):
+ self.optuna_study_delete(study_name, storage)
study = optuna.create_study(
study_name=study_name,
sampler=optuna.samplers.TPESampler(
direction=optuna.study.StudyDirection.MINIMIZE,
storage=storage,
)
- self.optuna_period_enqueue_previous_best_trial(pair, study)
+ if self.__optuna_config.get("warm_start", True):
+ self.optuna_period_enqueue_previous_best_trial(pair, study)
logger.info(f"Optuna {study_namespace} hyperopt started")
start = time.time()
try:
study_name = f"{identifier}-{study_namespace}-{pair}"
storage = self.optuna_storage(pair)
pruner = optuna.pruners.HyperbandPruner()
- self.optuna_study_delete(study_name, storage)
+ if self.__optuna_config.get("continuous", True):
+ self.optuna_study_delete(study_name, storage)
study = optuna.create_study(
study_name=study_name,
sampler=optuna.samplers.TPESampler(
direction=optuna.study.StudyDirection.MINIMIZE,
storage=storage,
)
- self.optuna_hp_enqueue_previous_best_trial(pair, study)
+ if self.__optuna_config.get("warm_start", True):
+ self.optuna_hp_enqueue_previous_best_trial(pair, study)
logger.info(f"Optuna {study_namespace} hyperopt started")
start = time.time()
try:
study_name = f"{identifier}-{study_namespace}-{pair}"
storage = self.optuna_storage(pair)
pruner = optuna.pruners.HyperbandPruner()
- self.optuna_study_delete(study_name, storage)
+ if self.__optuna_config.get("continuous", True):
+ self.optuna_study_delete(study_name, storage)
study = optuna.create_study(
study_name=study_name,
sampler=optuna.samplers.TPESampler(
direction=optuna.study.StudyDirection.MINIMIZE,
storage=storage,
)
- self.optuna_period_enqueue_previous_best_trial(pair, study)
+ if self.__optuna_config.get("warm_start", True):
+ self.optuna_period_enqueue_previous_best_trial(pair, study)
logger.info(f"Optuna {study_namespace} hyperopt started")
start = time.time()
try: