From da1c6299ed49343ab7141158c6bd6d47fe905ea8 Mon Sep 17 00:00:00 2001 From: xxm Date: Mon, 17 Aug 2026 03:56:24 +0800 Subject: [PATCH] =?UTF-8?q?feat:=20=E7=BB=BC=E5=90=88=E5=88=86=E5=8A=A0?= =?UTF-8?q?=E4=BF=A1=E5=8F=B7/=E6=88=90=E4=BA=A4=E6=AF=94=E6=95=88?= =?UTF-8?q?=E7=8E=87=E6=83=A9=E7=BD=9A+=E6=B8=A9=E5=8C=BA=E8=A1=A8?= =?UTF-8?q?=E5=B7=B2=E6=BF=80=E6=B4=BB/=E5=8F=AF=E6=BF=80=E6=B4=BB?= =?UTF-8?q?=E5=BE=BD=E7=AB=A0=E5=8C=BA=E5=88=86?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- static/index.html | 15 ++++++++++++--- 1 file changed, 12 insertions(+), 3 deletions(-) diff --git a/static/index.html b/static/index.html index 9041dc0e..d13e942d 100644 --- a/static/index.html +++ b/static/index.html @@ -2443,8 +2443,13 @@ function renderStrategyTable(strategies) { const n = st.total_trades || 0; const months = (st.universality || {}).months || 0; const conf = Math.min(1, n / 40) * (months > 0 ? Math.min(1, months / 6) : 1); + // 2026-08-17 老莫:效率惩罚(信号/成交比过高=大量信号未成交) + const _posN = (st.portfolio || {}).positions_taken || 0; + const _sigN = n; + const _ratioN = _posN > 0 ? _sigN / _posN : 99; + const _effN = _ratioN <= 2 ? 1.0 : _ratioN <= 5 ? 0.9 : _ratioN <= 10 ? 0.75 : 0.5; s._confidence = conf; - s._composite = Math.round((ret + wr + sh + pfc + dd) * conf); + s._composite = Math.round((ret + wr + sh + pfc + dd) * conf * _effN); } // 保存数据用于列排序 window._strats = strategies; @@ -2638,7 +2643,11 @@ function renderStrategyTable(strategies) { const rn = tr || 0; const rm = rw.universality ? (rw.universality.months || 0) : 0; const rconf = Math.min(1, rn / 40) * (rm > 0 ? Math.min(1, rm / 6) : 1); - comp = Math.round((ret + w + sh + pfc + dd) * rconf); + // 2026-08-17 老莫:效率惩罚——信号/成交比过高(大量信号未成交=质量差)综合分打折 + const _sig = tr != null ? tr : 0, _pos = (rw && rw.positions_taken) || 0; + const _ratio = _pos > 0 ? _sig / _pos : 99; + const _eff = _ratio <= 2 ? 1.0 : _ratio <= 5 ? 0.9 : _ratio <= 10 ? 0.75 : 0.5; + comp = Math.round((ret + w + sh + pfc + dd) * rconf * _eff); } const cagr = rwPf ? rwPf.cagr_pct : null; const ddV = rwPf ? rwPf.portfolio_max_dd_pct : null; @@ -2653,7 +2662,7 @@ function renderStrategyTable(strategies) { const rManual = s.manual_available !== false; let rState, rStateCls, rStateBadge, rRowBg; if (!rManual) { rState = 'manual_off'; rStateCls = 'text-slate-500'; rStateBadge = '手动停用'; rRowBg = 'opacity-50'; } - else if (r3) { rState = 'ok3'; rStateCls = 'text-emerald-400'; rStateBadge = '可激活'; rRowBg = 'bg-emerald-900/10'; } + else if (r3) { rState = 'ok3'; rStateCls = 'text-emerald-400'; rStateBadge = (s.current === true) ? '已激活' : '可激活'; rRowBg = 'bg-emerald-900/10'; } else if (rNearOk) { rState = 'ok2'; rStateCls = 'text-blue-400'; rStateBadge = '可用'; rRowBg = ''; } else { rState = 'bad'; rStateCls = 'text-red-400/80'; rStateBadge = '不合格'; rRowBg = 'opacity-60'; } const isActive = rState === 'ok3';