From a2d964bee6e8780ce0381cc73293e5da641db785 Mon Sep 17 00:00:00 2001 From: "zhangkun9038@dingtalk.com" Date: Tue, 23 Dec 2025 20:33:19 +0800 Subject: [PATCH] =?UTF-8?q?=E8=B0=83=E6=95=B4=E9=98=88=E5=80=BC=E5=88=A4?= =?UTF-8?q?=E6=96=AD=E9=80=BB=E8=BE=91=EF=BC=8C=E4=BB=8E=200.6/0.4=20?= =?UTF-8?q?=E6=94=B9=E4=B8=BA=200.5/0.3?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- freqtrade/templates/freqaiprimer.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/freqtrade/templates/freqaiprimer.py b/freqtrade/templates/freqaiprimer.py index 7fd2837c..704aca92 100644 --- a/freqtrade/templates/freqaiprimer.py +++ b/freqtrade/templates/freqaiprimer.py @@ -894,8 +894,8 @@ class FreqaiPrimer(IStrategy): if current_profit <= 0.02: dynamic_threshold *= 0.8 - # 新逻辑:如果 AI 预测需要长期持有(hold_duration_signal=1),且持仓时间还很短,则提高阈值 - if hold_duration_signal is not None and hold_duration_signal > 0.6: # AI 预测需要长期持有 + # 新逻辑:如果 AI 预测需要长期持有(hold_duration_signal > 0.5),且持仓时间还很短,则提高阈值 + if hold_duration_signal is not None and hold_duration_signal > 0.5: # AI 预测需要长期持有(从0.6降至0.5) # 如果持仓时间 < 30分钟,阈值提高 50%,更难出场 if trade_age_minutes < 30: dynamic_threshold *= 1.5 @@ -905,7 +905,7 @@ class FreqaiPrimer(IStrategy): # 如果持仓时间 30-60分钟,阈值提高 20% elif trade_age_minutes < 60: dynamic_threshold *= 1.2 - elif hold_duration_signal is not None and hold_duration_signal < 0.4: # AI 预测短期快速出场 + elif hold_duration_signal is not None and hold_duration_signal < 0.3: # AI 预测短期快速出场(从0.4降至0.3) # 阈值降低 20%,更容易出场 dynamic_threshold *= 0.8 logger.info(