Spaces:
Running
Running
Label SmolLM baselines above their lines without legend scores
Browse files- site/progress.js +7 -2
site/progress.js
CHANGED
|
@@ -14,14 +14,14 @@ async function drawProgress() {
|
|
| 14 |
hovertemplate: "PyBot 路 revision %{x:,}<br>Win rate: %{y:.2f}%<br>Commit %{customdata}<extra></extra>"
|
| 15 |
}, ...data.baselines.map((baseline, index) => ({
|
| 16 |
type: "scatter", mode: "lines",
|
| 17 |
-
name:
|
| 18 |
x: extent, y: [baseline.score, baseline.score],
|
| 19 |
line: {color: ["#999999", "#555555", "#000000"][index], width: 1.5,
|
| 20 |
dash: ["dot", "dash", "dashdot"][index]},
|
| 21 |
hovertemplate: `${baseline.name}<br>Win rate: %{y:.2f}%<extra></extra>`
|
| 22 |
}))];
|
| 23 |
await Plotly.newPlot("progress-chart", traces, {
|
| 24 |
-
margin: {l: 60, r: 12, t:
|
| 25 |
paper_bgcolor: "#ffffff", plot_bgcolor: "#ffffff",
|
| 26 |
font: {family: "'Letter Gothic', monospace", size: 12, color: "#000000"},
|
| 27 |
xaxis: {title: {text: "Evaluated revisions", standoff: 12},
|
|
@@ -29,6 +29,11 @@ async function drawProgress() {
|
|
| 29 |
yaxis: {title: {text: "Win rate (%)", standoff: 10}, rangemode: "tozero",
|
| 30 |
gridcolor: "#eeeeee", zerolinecolor: "#dddddd", automargin: true},
|
| 31 |
legend: {orientation: "h", x: 0, y: -0.25, yanchor: "top", font: {size: 11}},
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 32 |
hoverlabel: {bgcolor: "#ffffff", bordercolor: "#000000"}
|
| 33 |
}, {responsive: true, displayModeBar: false, displaylogo: false});
|
| 34 |
status.hidden = true;
|
|
|
|
| 14 |
hovertemplate: "PyBot 路 revision %{x:,}<br>Win rate: %{y:.2f}%<br>Commit %{customdata}<extra></extra>"
|
| 15 |
}, ...data.baselines.map((baseline, index) => ({
|
| 16 |
type: "scatter", mode: "lines",
|
| 17 |
+
name: baseline.name,
|
| 18 |
x: extent, y: [baseline.score, baseline.score],
|
| 19 |
line: {color: ["#999999", "#555555", "#000000"][index], width: 1.5,
|
| 20 |
dash: ["dot", "dash", "dashdot"][index]},
|
| 21 |
hovertemplate: `${baseline.name}<br>Win rate: %{y:.2f}%<extra></extra>`
|
| 22 |
}))];
|
| 23 |
await Plotly.newPlot("progress-chart", traces, {
|
| 24 |
+
margin: {l: 60, r: 12, t: 30, b: 130},
|
| 25 |
paper_bgcolor: "#ffffff", plot_bgcolor: "#ffffff",
|
| 26 |
font: {family: "'Letter Gothic', monospace", size: 12, color: "#000000"},
|
| 27 |
xaxis: {title: {text: "Evaluated revisions", standoff: 12},
|
|
|
|
| 29 |
yaxis: {title: {text: "Win rate (%)", standoff: 10}, rangemode: "tozero",
|
| 30 |
gridcolor: "#eeeeee", zerolinecolor: "#dddddd", automargin: true},
|
| 31 |
legend: {orientation: "h", x: 0, y: -0.25, yanchor: "top", font: {size: 11}},
|
| 32 |
+
annotations: data.baselines.map(baseline => ({
|
| 33 |
+
text: baseline.name, x: 1, xref: "paper", y: baseline.score, yref: "y",
|
| 34 |
+
xanchor: "right", yanchor: "bottom", yshift: 4, showarrow: false,
|
| 35 |
+
font: {size: 11, color: "#000000"}, bgcolor: "#ffffff", borderpad: 2
|
| 36 |
+
})),
|
| 37 |
hoverlabel: {bgcolor: "#ffffff", bordercolor: "#000000"}
|
| 38 |
}, {responsive: true, displayModeBar: false, displaylogo: false});
|
| 39 |
status.hidden = true;
|