From 3c3eeaf7429561e07300401632846ce6a10e7074 Mon Sep 17 00:00:00 2001 From: "zhangkun9038@dingtalk.com" Date: Tue, 23 Dec 2025 00:36:14 +0800 Subject: [PATCH] =?UTF-8?q?=E6=97=A5=E5=BF=97?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- freqtrade/templates/freqaiprimer.py | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/freqtrade/templates/freqaiprimer.py b/freqtrade/templates/freqaiprimer.py index 64d51f6b..77cf218a 100644 --- a/freqtrade/templates/freqaiprimer.py +++ b/freqtrade/templates/freqaiprimer.py @@ -763,6 +763,13 @@ class FreqaiPrimer(IStrategy): #logger.info(f"[{pair}] 动态止盈: 持仓时间={trade_age_minutes:.1f}分钟, 当前利润={current_profit:.2%}, " # f"动态ROI阈值={dynamic_roi_threshold:.4f}, 利润比值={profit_ratio:.2f}, " # f"市场状态={current_state}, entry_tag={entry_tag}, 退出比例={exit_ratio:.0%}") + + # 当决定退出时,输出出场价格信息 + if exit_ratio > 0: + # 计算出场价格上浮比例(1.25%) + price_markup_percent = 1.25 + adjusted_exit_price = current_rate * 1.0125 + logger.info(f"[{pair}] 准备出场 - 市场价: {current_rate:.8f}, 调整后出场价: {adjusted_exit_price:.8f}, 上浮: {price_markup_percent}%, 退出比例: {exit_ratio:.0%}") return exit_ratio