Spaces:
Running
Running
Board: thinking and non-thinking colours for our rows, base-to-trained arrows with the pass@1 gain
Browse files- index.html +29 -6
- index.src.html +29 -6
index.html
CHANGED
|
@@ -388,6 +388,9 @@ function legend(id,items){const el=$(id);el.textContent='';
|
|
| 388 |
w.className='sw';if(it.dash){w.style.borderTop='3px dotted '+it.color;w.style.height='0';}else w.style.background=it.color;
|
| 389 |
s.append(w,document.createTextNode(it.name));el.append(s);});}
|
| 390 |
|
|
|
|
|
|
|
|
|
|
| 391 |
function boardChart(host,rows,opt){
|
| 392 |
// Each bar is 100% of a model's attempts: solved | declined (safety) | never submitted | submitted and wrong.
|
| 393 |
opt=opt||{};host.textContent='';const W=host.clientWidth||700,stack=W<560,rh=stack?36:25,H=rows.length*rh+14;
|
|
@@ -396,14 +399,15 @@ function boardChart(host,rows,opt){
|
|
| 396 |
[['hd','var(--bad)','var(--badwash)'],['hn','#b07a4c','#f3e8dc']].forEach(([id,fg,bg])=>{
|
| 397 |
const pt=sv('pattern',{id:host.id+id,width:6,height:6,patternUnits:'userSpaceOnUse',patternTransform:'rotate(45)'},defs);
|
| 398 |
sv('rect',{width:6,height:6,style:`fill:${bg}`},pt);sv('line',{x1:0,y1:0,x2:0,y2:6,style:`stroke:${fg};stroke-width:2.2`},pt);});
|
| 399 |
-
const pr=sv('text',{x:-999,y:-999,style:'font:12px var(--sans)'},svg);let lw=0;
|
| 400 |
const name=r=>r.model+(r.partial?' (still running)':'');
|
| 401 |
rows.forEach(r=>{pr.textContent=name(r);lw=Math.max(lw,pr.getComputedTextLength());});svg.removeChild(pr);
|
| 402 |
-
const
|
|
|
|
| 403 |
const X=v=>L+Math.max(0,Math.min(1,v))*(W-L-R);
|
| 404 |
const fmt=opt.fmt||(r=>f3(r.pass1)+(r.pass4!=null?' / '+f3(r.pass4):''));
|
| 405 |
rows.forEach((r,i)=>{const y=(stack?18:7)+i*rh,h=stack?13:rh-9,mid=y+h/2;
|
| 406 |
-
sv('text',stack?{x:
|
| 407 |
svg.lastChild.textContent=name(r);
|
| 408 |
const tip=`${r.model} · pass@1 ${f3(r.pass1)}`+(r.lo!=null?` [${f2(r.lo)}, ${f2(r.hi)}]`:'')+(r.pass4!=null?` · pass@4 ${f3(r.pass4)}`:'')
|
| 409 |
+(r.unsplit?'':` · declined ${Math.round(100*(r.refused||0))}% · never submitted ${Math.round(100*(r.no_submit||0))}%`)+(r.note?` · ${r.note}`:'');
|
|
@@ -411,22 +415,41 @@ function boardChart(host,rows,opt){
|
|
| 411 |
sv('rect',{x:L,y,width:X(1)-L,height:h,rx:2,style:'fill:#e8ecea'},g);
|
| 412 |
let at=0;
|
| 413 |
const seg=(v,fill)=>{if(!(v>0))return;const x0=X(at),x1=X(at+v);sv('rect',{x:x0,y,width:Math.max(.8,x1-x0),height:h,style:`fill:${fill}`},g);at+=v;};
|
| 414 |
-
seg(r.pass1||0,r.ours?
|
| 415 |
if(!r.unsplit){seg(r.refused||0,`url(#${host.id}hd)`);seg(r.no_submit||0,`url(#${host.id}hn)`);}
|
| 416 |
if(r.lo!=null&&r.hi!=null){
|
| 417 |
sv('line',{x1:X(r.lo),x2:X(r.hi),y1:mid,y2:mid,style:'stroke:var(--fg);opacity:.55'},g);
|
| 418 |
[r.lo,r.hi].forEach(v=>sv('line',{x1:X(v),x2:X(v),y1:mid-3.5,y2:mid+3.5,style:'stroke:var(--fg);opacity:.55'},g));}
|
| 419 |
if(r.pass4!=null) sv('line',{x1:X(r.pass4),x2:X(r.pass4),y1:y-2,y2:y+h+2,style:'stroke:var(--ink);stroke-width:2'},g);
|
| 420 |
sv('text',{x:X(1)+6,y:mid+4,style:'font:11.5px var(--mono);fill:var(--fg-mid)'},svg).textContent=fmt(r);});
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 421 |
}
|
| 422 |
function boardLegend(id){const el=$(id);if(!el)return;
|
| 423 |
const sw=(st,label)=>`<span><i class="sw" style="height:10px;${st}"></i>${label}</span>`;
|
| 424 |
-
el.innerHTML=sw('background:var(--accent)','
|
| 425 |
+sw('background:repeating-linear-gradient(45deg,var(--bad) 0 2px,var(--badwash) 2px 5px)','declined on safety grounds')
|
| 426 |
+sw('background:repeating-linear-gradient(45deg,#b07a4c 0 2px,#f3e8dc 2px 5px)','never submitted (out of turns or tokens)')
|
| 427 |
+sw('background:#e8ecea;outline:1px solid var(--line2)','submitted and wrong')
|
| 428 |
+sw('width:2px;height:13px;border-radius:0;background:var(--ink)','pass@4')
|
| 429 |
-
+sw('width:14px;height:0;border-radius:0;border-top:1px solid var(--fg)','95% interval on pass@1')
|
|
|
|
| 430 |
|
| 431 |
/* ---------------- molecules: 2D depiction and the 3D viewer ------------- */
|
| 432 |
let MOL={}, viewer=null, spinning=true, style3d='stick', current3d=null;
|
|
|
|
| 388 |
w.className='sw';if(it.dash){w.style.borderTop='3px dotted '+it.color;w.style.height='0';}else w.style.background=it.color;
|
| 389 |
s.append(w,document.createTextNode(it.name));el.append(s);});}
|
| 390 |
|
| 391 |
+
const OURS_T=['Qwen3.8-27B base','Qwen3.8-27B + RL 525'], OURS_N=['Qwen3.8-27B base, non-thinking','Qwen3.8-27B + RL 300, non-thinking'];
|
| 392 |
+
const COL_T='var(--accent)', COL_N='#7a5aa6';
|
| 393 |
+
const oursCol=r=>OURS_N.includes(r.model)?COL_N:COL_T;
|
| 394 |
function boardChart(host,rows,opt){
|
| 395 |
// Each bar is 100% of a model's attempts: solved | declined (safety) | never submitted | submitted and wrong.
|
| 396 |
opt=opt||{};host.textContent='';const W=host.clientWidth||700,stack=W<560,rh=stack?36:25,H=rows.length*rh+14;
|
|
|
|
| 399 |
[['hd','var(--bad)','var(--badwash)'],['hn','#b07a4c','#f3e8dc']].forEach(([id,fg,bg])=>{
|
| 400 |
const pt=sv('pattern',{id:host.id+id,width:6,height:6,patternUnits:'userSpaceOnUse',patternTransform:'rotate(45)'},defs);
|
| 401 |
sv('rect',{width:6,height:6,style:`fill:${bg}`},pt);sv('line',{x1:0,y1:0,x2:0,y2:6,style:`stroke:${fg};stroke-width:2.2`},pt);});
|
| 402 |
+
const pr=sv('text',{x:-999,y:-999,style:'font:600 12px var(--sans)'},svg);let lw=0; // bold: our rows are drawn bold
|
| 403 |
const name=r=>r.model+(r.partial?' (still running)':'');
|
| 404 |
rows.forEach(r=>{pr.textContent=name(r);lw=Math.max(lw,pr.getComputedTextLength());});svg.removeChild(pr);
|
| 405 |
+
const G=rows.some(r=>r.ours)?100:0; // left gutter: base -> trained arrows
|
| 406 |
+
const L=stack?G:G+8+Math.min(Math.max(90,lw+12),Math.max(100,(W-G)*0.42)),R=stack?84:100;
|
| 407 |
const X=v=>L+Math.max(0,Math.min(1,v))*(W-L-R);
|
| 408 |
const fmt=opt.fmt||(r=>f3(r.pass1)+(r.pass4!=null?' / '+f3(r.pass4):''));
|
| 409 |
rows.forEach((r,i)=>{const y=(stack?18:7)+i*rh,h=stack?13:rh-9,mid=y+h/2;
|
| 410 |
+
sv('text',stack?{x:G,y:y-4}:{x:L-9,y:mid+4,'text-anchor':'end'},svg).setAttribute('style',`font:12px var(--sans);fill:${r.ours?'var(--fg)':'var(--fg-mid)'};font-weight:${r.ours?600:400}`);
|
| 411 |
svg.lastChild.textContent=name(r);
|
| 412 |
const tip=`${r.model} · pass@1 ${f3(r.pass1)}`+(r.lo!=null?` [${f2(r.lo)}, ${f2(r.hi)}]`:'')+(r.pass4!=null?` · pass@4 ${f3(r.pass4)}`:'')
|
| 413 |
+(r.unsplit?'':` · declined ${Math.round(100*(r.refused||0))}% · never submitted ${Math.round(100*(r.no_submit||0))}%`)+(r.note?` · ${r.note}`:'');
|
|
|
|
| 415 |
sv('rect',{x:L,y,width:X(1)-L,height:h,rx:2,style:'fill:#e8ecea'},g);
|
| 416 |
let at=0;
|
| 417 |
const seg=(v,fill)=>{if(!(v>0))return;const x0=X(at),x1=X(at+v);sv('rect',{x:x0,y,width:Math.max(.8,x1-x0),height:h,style:`fill:${fill}`},g);at+=v;};
|
| 418 |
+
seg(r.pass1||0,r.ours?oursCol(r):'#7f8d88');
|
| 419 |
if(!r.unsplit){seg(r.refused||0,`url(#${host.id}hd)`);seg(r.no_submit||0,`url(#${host.id}hn)`);}
|
| 420 |
if(r.lo!=null&&r.hi!=null){
|
| 421 |
sv('line',{x1:X(r.lo),x2:X(r.hi),y1:mid,y2:mid,style:'stroke:var(--fg);opacity:.55'},g);
|
| 422 |
[r.lo,r.hi].forEach(v=>sv('line',{x1:X(v),x2:X(v),y1:mid-3.5,y2:mid+3.5,style:'stroke:var(--fg);opacity:.55'},g));}
|
| 423 |
if(r.pass4!=null) sv('line',{x1:X(r.pass4),x2:X(r.pass4),y1:y-2,y2:y+h+2,style:'stroke:var(--ink);stroke-width:2'},g);
|
| 424 |
sv('text',{x:X(1)+6,y:mid+4,style:'font:11.5px var(--mono);fill:var(--fg-mid)'},svg).textContent=fmt(r);});
|
| 425 |
+
// Curved arrow from each base row to its trained row, labelled with the pass@1 gain. Each pair has
|
| 426 |
+
// its own column in the gutter (thinking outer, non-thinking inner), so the two never lie on each other.
|
| 427 |
+
const rowMid=name=>{const i=rows.findIndex(r=>r.model===name);if(i<0)return null;
|
| 428 |
+
const y=(stack?18:7)+i*rh,h=stack?13:rh-9;return y+h/2;};
|
| 429 |
+
const defs2=svg.querySelector('defs');
|
| 430 |
+
[[OURS_T,COL_T,G-46,14,'t'],[OURS_N,COL_N,G-14,10,'n']].forEach(([[base,tuned],col,xc,bow,k])=>{
|
| 431 |
+
const yb=rowMid(base),yt=rowMid(tuned);if(yb==null||yt==null)return;
|
| 432 |
+
const rb=rows.find(r=>r.model===base),rt=rows.find(r=>r.model===tuned);
|
| 433 |
+
const mk=sv('marker',{id:host.id+'ar'+k,viewBox:'0 0 8 8',refX:7,refY:4,markerWidth:7,markerHeight:7,orient:'auto'},defs2);
|
| 434 |
+
sv('path',{d:'M0,0 L8,4 L0,8 z',style:`fill:${col}`},mk);
|
| 435 |
+
const end=G-3,xl=xc-bow;
|
| 436 |
+
const d=`M ${end} ${yb} L ${xc} ${yb} C ${xl} ${yb}, ${xl} ${yt}, ${xc} ${yt} L ${end} ${yt}`;
|
| 437 |
+
const path=sv('path',{d,'marker-end':`url(#${host.id}ar${k})`,style:`fill:none;stroke:${col};stroke-width:1.6`},svg);
|
| 438 |
+
sv('title',{},path).textContent=`${base} → ${tuned}: pass@1 ${f3(rb.pass1)} → ${f3(rt.pass1)}`;
|
| 439 |
+
const gain=(rt.pass1||0)-(rb.pass1||0);
|
| 440 |
+
sv('text',{x:xl-4,y:(yb+yt)/2+4,'text-anchor':'end',style:`font:600 10.5px var(--mono);fill:${col};paint-order:stroke;stroke:var(--bg);stroke-width:3px`},svg)
|
| 441 |
+
.textContent=(gain>=0?'+':'')+gain.toFixed(2);
|
| 442 |
+
});
|
| 443 |
}
|
| 444 |
function boardLegend(id){const el=$(id);if(!el)return;
|
| 445 |
const sw=(st,label)=>`<span><i class="sw" style="height:10px;${st}"></i>${label}</span>`;
|
| 446 |
+
el.innerHTML=sw('background:var(--accent)','ours, thinking')+sw('background:#7a5aa6','ours, non-thinking')+sw('background:#7f8d88','other models')
|
| 447 |
+sw('background:repeating-linear-gradient(45deg,var(--bad) 0 2px,var(--badwash) 2px 5px)','declined on safety grounds')
|
| 448 |
+sw('background:repeating-linear-gradient(45deg,#b07a4c 0 2px,#f3e8dc 2px 5px)','never submitted (out of turns or tokens)')
|
| 449 |
+sw('background:#e8ecea;outline:1px solid var(--line2)','submitted and wrong')
|
| 450 |
+sw('width:2px;height:13px;border-radius:0;background:var(--ink)','pass@4')
|
| 451 |
+
+sw('width:14px;height:0;border-radius:0;border-top:1px solid var(--fg)','95% interval on pass@1')
|
| 452 |
+
+sw('width:14px;height:0;border-radius:0;border-top:2px solid var(--accent)','base → after RL, pass@1 gain');}
|
| 453 |
|
| 454 |
/* ---------------- molecules: 2D depiction and the 3D viewer ------------- */
|
| 455 |
let MOL={}, viewer=null, spinning=true, style3d='stick', current3d=null;
|
index.src.html
CHANGED
|
@@ -386,6 +386,9 @@ function legend(id,items){const el=$(id);el.textContent='';
|
|
| 386 |
w.className='sw';if(it.dash){w.style.borderTop='3px dotted '+it.color;w.style.height='0';}else w.style.background=it.color;
|
| 387 |
s.append(w,document.createTextNode(it.name));el.append(s);});}
|
| 388 |
|
|
|
|
|
|
|
|
|
|
| 389 |
function boardChart(host,rows,opt){
|
| 390 |
// Each bar is 100% of a model's attempts: solved | declined (safety) | never submitted | submitted and wrong.
|
| 391 |
opt=opt||{};host.textContent='';const W=host.clientWidth||700,stack=W<560,rh=stack?36:25,H=rows.length*rh+14;
|
|
@@ -394,14 +397,15 @@ function boardChart(host,rows,opt){
|
|
| 394 |
[['hd','var(--bad)','var(--badwash)'],['hn','#b07a4c','#f3e8dc']].forEach(([id,fg,bg])=>{
|
| 395 |
const pt=sv('pattern',{id:host.id+id,width:6,height:6,patternUnits:'userSpaceOnUse',patternTransform:'rotate(45)'},defs);
|
| 396 |
sv('rect',{width:6,height:6,style:`fill:${bg}`},pt);sv('line',{x1:0,y1:0,x2:0,y2:6,style:`stroke:${fg};stroke-width:2.2`},pt);});
|
| 397 |
-
const pr=sv('text',{x:-999,y:-999,style:'font:12px var(--sans)'},svg);let lw=0;
|
| 398 |
const name=r=>r.model+(r.partial?' (still running)':'');
|
| 399 |
rows.forEach(r=>{pr.textContent=name(r);lw=Math.max(lw,pr.getComputedTextLength());});svg.removeChild(pr);
|
| 400 |
-
const
|
|
|
|
| 401 |
const X=v=>L+Math.max(0,Math.min(1,v))*(W-L-R);
|
| 402 |
const fmt=opt.fmt||(r=>f3(r.pass1)+(r.pass4!=null?' / '+f3(r.pass4):''));
|
| 403 |
rows.forEach((r,i)=>{const y=(stack?18:7)+i*rh,h=stack?13:rh-9,mid=y+h/2;
|
| 404 |
-
sv('text',stack?{x:
|
| 405 |
svg.lastChild.textContent=name(r);
|
| 406 |
const tip=`${r.model} · pass@1 ${f3(r.pass1)}`+(r.lo!=null?` [${f2(r.lo)}, ${f2(r.hi)}]`:'')+(r.pass4!=null?` · pass@4 ${f3(r.pass4)}`:'')
|
| 407 |
+(r.unsplit?'':` · declined ${Math.round(100*(r.refused||0))}% · never submitted ${Math.round(100*(r.no_submit||0))}%`)+(r.note?` · ${r.note}`:'');
|
|
@@ -409,22 +413,41 @@ function boardChart(host,rows,opt){
|
|
| 409 |
sv('rect',{x:L,y,width:X(1)-L,height:h,rx:2,style:'fill:#e8ecea'},g);
|
| 410 |
let at=0;
|
| 411 |
const seg=(v,fill)=>{if(!(v>0))return;const x0=X(at),x1=X(at+v);sv('rect',{x:x0,y,width:Math.max(.8,x1-x0),height:h,style:`fill:${fill}`},g);at+=v;};
|
| 412 |
-
seg(r.pass1||0,r.ours?
|
| 413 |
if(!r.unsplit){seg(r.refused||0,`url(#${host.id}hd)`);seg(r.no_submit||0,`url(#${host.id}hn)`);}
|
| 414 |
if(r.lo!=null&&r.hi!=null){
|
| 415 |
sv('line',{x1:X(r.lo),x2:X(r.hi),y1:mid,y2:mid,style:'stroke:var(--fg);opacity:.55'},g);
|
| 416 |
[r.lo,r.hi].forEach(v=>sv('line',{x1:X(v),x2:X(v),y1:mid-3.5,y2:mid+3.5,style:'stroke:var(--fg);opacity:.55'},g));}
|
| 417 |
if(r.pass4!=null) sv('line',{x1:X(r.pass4),x2:X(r.pass4),y1:y-2,y2:y+h+2,style:'stroke:var(--ink);stroke-width:2'},g);
|
| 418 |
sv('text',{x:X(1)+6,y:mid+4,style:'font:11.5px var(--mono);fill:var(--fg-mid)'},svg).textContent=fmt(r);});
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 419 |
}
|
| 420 |
function boardLegend(id){const el=$(id);if(!el)return;
|
| 421 |
const sw=(st,label)=>`<span><i class="sw" style="height:10px;${st}"></i>${label}</span>`;
|
| 422 |
-
el.innerHTML=sw('background:var(--accent)','
|
| 423 |
+sw('background:repeating-linear-gradient(45deg,var(--bad) 0 2px,var(--badwash) 2px 5px)','declined on safety grounds')
|
| 424 |
+sw('background:repeating-linear-gradient(45deg,#b07a4c 0 2px,#f3e8dc 2px 5px)','never submitted (out of turns or tokens)')
|
| 425 |
+sw('background:#e8ecea;outline:1px solid var(--line2)','submitted and wrong')
|
| 426 |
+sw('width:2px;height:13px;border-radius:0;background:var(--ink)','pass@4')
|
| 427 |
-
+sw('width:14px;height:0;border-radius:0;border-top:1px solid var(--fg)','95% interval on pass@1')
|
|
|
|
| 428 |
|
| 429 |
/* ---------------- molecules: 2D depiction and the 3D viewer ------------- */
|
| 430 |
let MOL={}, viewer=null, spinning=true, style3d='stick', current3d=null;
|
|
|
|
| 386 |
w.className='sw';if(it.dash){w.style.borderTop='3px dotted '+it.color;w.style.height='0';}else w.style.background=it.color;
|
| 387 |
s.append(w,document.createTextNode(it.name));el.append(s);});}
|
| 388 |
|
| 389 |
+
const OURS_T=['Qwen3.8-27B base','Qwen3.8-27B + RL 525'], OURS_N=['Qwen3.8-27B base, non-thinking','Qwen3.8-27B + RL 300, non-thinking'];
|
| 390 |
+
const COL_T='var(--accent)', COL_N='#7a5aa6';
|
| 391 |
+
const oursCol=r=>OURS_N.includes(r.model)?COL_N:COL_T;
|
| 392 |
function boardChart(host,rows,opt){
|
| 393 |
// Each bar is 100% of a model's attempts: solved | declined (safety) | never submitted | submitted and wrong.
|
| 394 |
opt=opt||{};host.textContent='';const W=host.clientWidth||700,stack=W<560,rh=stack?36:25,H=rows.length*rh+14;
|
|
|
|
| 397 |
[['hd','var(--bad)','var(--badwash)'],['hn','#b07a4c','#f3e8dc']].forEach(([id,fg,bg])=>{
|
| 398 |
const pt=sv('pattern',{id:host.id+id,width:6,height:6,patternUnits:'userSpaceOnUse',patternTransform:'rotate(45)'},defs);
|
| 399 |
sv('rect',{width:6,height:6,style:`fill:${bg}`},pt);sv('line',{x1:0,y1:0,x2:0,y2:6,style:`stroke:${fg};stroke-width:2.2`},pt);});
|
| 400 |
+
const pr=sv('text',{x:-999,y:-999,style:'font:600 12px var(--sans)'},svg);let lw=0; // bold: our rows are drawn bold
|
| 401 |
const name=r=>r.model+(r.partial?' (still running)':'');
|
| 402 |
rows.forEach(r=>{pr.textContent=name(r);lw=Math.max(lw,pr.getComputedTextLength());});svg.removeChild(pr);
|
| 403 |
+
const G=rows.some(r=>r.ours)?100:0; // left gutter: base -> trained arrows
|
| 404 |
+
const L=stack?G:G+8+Math.min(Math.max(90,lw+12),Math.max(100,(W-G)*0.42)),R=stack?84:100;
|
| 405 |
const X=v=>L+Math.max(0,Math.min(1,v))*(W-L-R);
|
| 406 |
const fmt=opt.fmt||(r=>f3(r.pass1)+(r.pass4!=null?' / '+f3(r.pass4):''));
|
| 407 |
rows.forEach((r,i)=>{const y=(stack?18:7)+i*rh,h=stack?13:rh-9,mid=y+h/2;
|
| 408 |
+
sv('text',stack?{x:G,y:y-4}:{x:L-9,y:mid+4,'text-anchor':'end'},svg).setAttribute('style',`font:12px var(--sans);fill:${r.ours?'var(--fg)':'var(--fg-mid)'};font-weight:${r.ours?600:400}`);
|
| 409 |
svg.lastChild.textContent=name(r);
|
| 410 |
const tip=`${r.model} · pass@1 ${f3(r.pass1)}`+(r.lo!=null?` [${f2(r.lo)}, ${f2(r.hi)}]`:'')+(r.pass4!=null?` · pass@4 ${f3(r.pass4)}`:'')
|
| 411 |
+(r.unsplit?'':` · declined ${Math.round(100*(r.refused||0))}% · never submitted ${Math.round(100*(r.no_submit||0))}%`)+(r.note?` · ${r.note}`:'');
|
|
|
|
| 413 |
sv('rect',{x:L,y,width:X(1)-L,height:h,rx:2,style:'fill:#e8ecea'},g);
|
| 414 |
let at=0;
|
| 415 |
const seg=(v,fill)=>{if(!(v>0))return;const x0=X(at),x1=X(at+v);sv('rect',{x:x0,y,width:Math.max(.8,x1-x0),height:h,style:`fill:${fill}`},g);at+=v;};
|
| 416 |
+
seg(r.pass1||0,r.ours?oursCol(r):'#7f8d88');
|
| 417 |
if(!r.unsplit){seg(r.refused||0,`url(#${host.id}hd)`);seg(r.no_submit||0,`url(#${host.id}hn)`);}
|
| 418 |
if(r.lo!=null&&r.hi!=null){
|
| 419 |
sv('line',{x1:X(r.lo),x2:X(r.hi),y1:mid,y2:mid,style:'stroke:var(--fg);opacity:.55'},g);
|
| 420 |
[r.lo,r.hi].forEach(v=>sv('line',{x1:X(v),x2:X(v),y1:mid-3.5,y2:mid+3.5,style:'stroke:var(--fg);opacity:.55'},g));}
|
| 421 |
if(r.pass4!=null) sv('line',{x1:X(r.pass4),x2:X(r.pass4),y1:y-2,y2:y+h+2,style:'stroke:var(--ink);stroke-width:2'},g);
|
| 422 |
sv('text',{x:X(1)+6,y:mid+4,style:'font:11.5px var(--mono);fill:var(--fg-mid)'},svg).textContent=fmt(r);});
|
| 423 |
+
// Curved arrow from each base row to its trained row, labelled with the pass@1 gain. Each pair has
|
| 424 |
+
// its own column in the gutter (thinking outer, non-thinking inner), so the two never lie on each other.
|
| 425 |
+
const rowMid=name=>{const i=rows.findIndex(r=>r.model===name);if(i<0)return null;
|
| 426 |
+
const y=(stack?18:7)+i*rh,h=stack?13:rh-9;return y+h/2;};
|
| 427 |
+
const defs2=svg.querySelector('defs');
|
| 428 |
+
[[OURS_T,COL_T,G-46,14,'t'],[OURS_N,COL_N,G-14,10,'n']].forEach(([[base,tuned],col,xc,bow,k])=>{
|
| 429 |
+
const yb=rowMid(base),yt=rowMid(tuned);if(yb==null||yt==null)return;
|
| 430 |
+
const rb=rows.find(r=>r.model===base),rt=rows.find(r=>r.model===tuned);
|
| 431 |
+
const mk=sv('marker',{id:host.id+'ar'+k,viewBox:'0 0 8 8',refX:7,refY:4,markerWidth:7,markerHeight:7,orient:'auto'},defs2);
|
| 432 |
+
sv('path',{d:'M0,0 L8,4 L0,8 z',style:`fill:${col}`},mk);
|
| 433 |
+
const end=G-3,xl=xc-bow;
|
| 434 |
+
const d=`M ${end} ${yb} L ${xc} ${yb} C ${xl} ${yb}, ${xl} ${yt}, ${xc} ${yt} L ${end} ${yt}`;
|
| 435 |
+
const path=sv('path',{d,'marker-end':`url(#${host.id}ar${k})`,style:`fill:none;stroke:${col};stroke-width:1.6`},svg);
|
| 436 |
+
sv('title',{},path).textContent=`${base} → ${tuned}: pass@1 ${f3(rb.pass1)} → ${f3(rt.pass1)}`;
|
| 437 |
+
const gain=(rt.pass1||0)-(rb.pass1||0);
|
| 438 |
+
sv('text',{x:xl-4,y:(yb+yt)/2+4,'text-anchor':'end',style:`font:600 10.5px var(--mono);fill:${col};paint-order:stroke;stroke:var(--bg);stroke-width:3px`},svg)
|
| 439 |
+
.textContent=(gain>=0?'+':'')+gain.toFixed(2);
|
| 440 |
+
});
|
| 441 |
}
|
| 442 |
function boardLegend(id){const el=$(id);if(!el)return;
|
| 443 |
const sw=(st,label)=>`<span><i class="sw" style="height:10px;${st}"></i>${label}</span>`;
|
| 444 |
+
el.innerHTML=sw('background:var(--accent)','ours, thinking')+sw('background:#7a5aa6','ours, non-thinking')+sw('background:#7f8d88','other models')
|
| 445 |
+sw('background:repeating-linear-gradient(45deg,var(--bad) 0 2px,var(--badwash) 2px 5px)','declined on safety grounds')
|
| 446 |
+sw('background:repeating-linear-gradient(45deg,#b07a4c 0 2px,#f3e8dc 2px 5px)','never submitted (out of turns or tokens)')
|
| 447 |
+sw('background:#e8ecea;outline:1px solid var(--line2)','submitted and wrong')
|
| 448 |
+sw('width:2px;height:13px;border-radius:0;background:var(--ink)','pass@4')
|
| 449 |
+
+sw('width:14px;height:0;border-radius:0;border-top:1px solid var(--fg)','95% interval on pass@1')
|
| 450 |
+
+sw('width:14px;height:0;border-radius:0;border-top:2px solid var(--accent)','base → after RL, pass@1 gain');}
|
| 451 |
|
| 452 |
/* ---------------- molecules: 2D depiction and the 3D viewer ------------- */
|
| 453 |
let MOL={}, viewer=null, spinning=true, style3d='stick', current3d=null;
|