Clarify model API source and simplify probability hints

This commit is contained in:
2569718930@qq.com
2026-04-17 01:11:04 +08:00
parent 5f0677447e
commit cdaea8a1f0
3 changed files with 38 additions and 109 deletions
@@ -1001,87 +1001,36 @@
border: 1px solid rgba(251, 113, 133, 0.26); border: 1px solid rgba(251, 113, 133, 0.26);
} }
.root :global(.prob-model-vote) { .root :global(.prob-model-hint) {
display: flex;
flex-direction: column;
gap: 8px;
margin-bottom: 8px;
padding: 10px;
border: 1px solid rgba(148, 163, 184, 0.14);
border-radius: 8px;
background: rgba(15, 23, 42, 0.34);
}
.root :global(.prob-model-vote-head) {
display: flex; display: flex;
align-items: center; align-items: center;
justify-content: space-between; flex-wrap: wrap;
gap: 10px; gap: 6px;
margin-bottom: 10px;
padding: 7px 9px;
border: 1px solid rgba(148, 163, 184, 0.14);
border-radius: 8px;
background: rgba(15, 23, 42, 0.22);
} }
.root :global(.prob-model-vote-head span) { .root :global(.prob-model-hint span) {
color: var(--text-primary); color: var(--cyan);
font-size: 12px; font-size: 11px;
font-weight: 800; font-weight: 800;
} }
.root :global(.prob-model-vote-head em) { .root :global(.prob-model-hint strong) {
color: var(--text-secondary);
font-size: 11px;
font-weight: 800;
}
.root :global(.prob-model-hint em) {
color: var(--text-muted); color: var(--text-muted);
font-size: 11px; font-size: 11px;
font-style: normal; font-style: normal;
} }
.root :global(.prob-model-vote-grid) {
display: grid;
gap: 6px;
}
.root :global(.prob-model-vote-row) {
display: grid;
grid-template-columns: 64px minmax(0, 1fr);
align-items: center;
gap: 8px;
}
.root :global(.prob-model-vote-row > span) {
color: var(--text-primary);
font-size: 12px;
font-weight: 800;
text-align: right;
}
.root :global(.prob-model-vote-track) {
position: relative;
height: 18px;
overflow: hidden;
border-radius: 6px;
background: rgba(148, 163, 184, 0.1);
}
.root :global(.prob-model-vote-fill) {
height: 100%;
border-radius: 6px;
background: linear-gradient(90deg, rgba(20, 184, 166, 0.62), rgba(34, 211, 238, 0.88));
}
.root :global(.prob-model-vote-track strong) {
position: absolute;
top: 50%;
right: 8px;
transform: translateY(-50%);
color: var(--text-primary);
font-size: 11px;
line-height: 1;
text-shadow: 0 1px 2px rgba(2, 6, 23, 0.85);
}
.root :global(.prob-model-vote p) {
margin: 0;
color: var(--text-muted);
font-size: 11px;
line-height: 1.45;
}
/* ── Model Bars ── */ /* ── Model Bars ── */
.root :global(.model-bars) { .root :global(.model-bars) {
display: flex; display: flex;
+18 -38
View File
@@ -584,6 +584,13 @@ export function ProbabilityDistribution({
() => getRoundedModelVoteDistribution(detail, targetDate), () => getRoundedModelVoteDistribution(detail, targetDate),
[detail, targetDate], [detail, targetDate],
); );
const modelVoteHint = modelVoteView.rows
.slice(0, 2)
.map(
(row) =>
`${row.value}${detail.temp_symbol} ${row.count}/${modelVoteView.total}`,
)
.join(" · ");
const marketTopBuckets = isToday ? getMarketTopBuckets(marketScan) : []; const marketTopBuckets = isToday ? getMarketTopBuckets(marketScan) : [];
const sortedMarketTopBuckets = useMemo(() => { const sortedMarketTopBuckets = useMemo(() => {
const sorted = [...marketTopBuckets].sort( const sorted = [...marketTopBuckets].sort(
@@ -639,44 +646,17 @@ export function ProbabilityDistribution({
: `市场概率(该温度桶): ${marketYesText}`} : `市场概率(该温度桶): ${marketYesText}`}
</div> </div>
)} )}
{modelVoteView.rows.length > 0 && ( {modelVoteHint && (
<div className="prob-model-vote"> <div className="prob-model-hint">
<div className="prob-model-vote-head"> <span>
<span> {locale === "en-US" ? "Model vote reference" : "模型投票参考"}
{locale === "en-US" </span>
? "Rounded model-vote baseline" <strong>{modelVoteHint}</strong>
: "模型四舍五入票数基线"} <em>
</span>
<em>
{locale === "en-US"
? `${modelVoteView.total} sources after family dedup`
: `家族去重后 ${modelVoteView.total} 个来源`}
</em>
</div>
<div className="prob-model-vote-grid">
{modelVoteView.rows.slice(0, 4).map((row) => (
<div key={row.value} className="prob-model-vote-row">
<span>
{row.value}
{detail.temp_symbol}
</span>
<div className="prob-model-vote-track">
<div
className="prob-model-vote-fill"
style={{ width: `${Math.max(row.percent * 100, 8)}%` }}
/>
<strong>
{row.count}/{modelVoteView.total}
</strong>
</div>
</div>
))}
</div>
<p>
{locale === "en-US" {locale === "en-US"
? "This is a transparent model-count baseline, not the calibrated settlement probability." ? "shown for explanation only"
: "这是透明模型票数基线,不等同于经过实测下限与历史 MAE 校准后的结算概率"} : "仅用于解释,不作为结算概率"}
</p> </em>
</div> </div>
)} )}
{useMarketTopBuckets ? ( {useMarketTopBuckets ? (
@@ -909,7 +889,7 @@ export function ModelForecast({
</span> </span>
{metadataSource && ( {metadataSource && (
<span> <span>
{locale === "en-US" ? "Source" : "来源"} ·{" "} {locale === "en-US" ? "API" : "接口"} ·{" "}
<strong>{metadataSource}</strong> <strong>{metadataSource}</strong>
</span> </span>
)} )}
+2 -2
View File
@@ -198,7 +198,7 @@ export const DOCS_PAGES: DocsPage[] = [
id: "display", id: "display",
title: "网页上如何展示", title: "网页上如何展示",
blocks: [ blocks: [
{ type: "paragraph", text: "网页的“模型区间与分歧”会按全球基准、AIFS 模型、欧洲高分辨率、北美高分辨率分组显示,并展示可用模型数量、模型分歧、来源、模型名称、分辨率和预报时效。没有覆盖的区域模型不会显示。" }, { type: "paragraph", text: "网页的“模型区间与分歧”会按全球基准、AIFS 模型、欧洲高分辨率、北美高分辨率分组显示,并展示可用模型数量、模型分歧、模型机构、接入接口、模型名称、分辨率和预报时效。没有覆盖的区域模型不会显示。" },
], ],
}, },
], ],
@@ -236,7 +236,7 @@ export const DOCS_PAGES: DocsPage[] = [
id: "display", id: "display",
title: "How the site displays this", title: "How the site displays this",
blocks: [ blocks: [
{ type: "paragraph", text: "The Model Range & Spread panel groups the model stack into Global Baseline, AIFS Model, Europe High-resolution, and North America High-resolution. It shows available model count, spread, source, model name, resolution, and forecast horizon. Regional models outside their domain are simply not shown." }, { type: "paragraph", text: "The Model Range & Spread panel groups the model stack into Global Baseline, AIFS Model, Europe High-resolution, and North America High-resolution. It shows available model count, spread, model agency, API, model name, resolution, and forecast horizon. Regional models outside their domain are simply not shown." },
], ],
}, },
], ],