(()=>{ const HF='https://huggingface.co/datasets/HuggingFriends/PixelWorld/resolve/main/analyses/flash/'; let cohort=new URLSearchParams(location.search).get('cohort')||'confirmation_native24',report,exampleCase='0047',liveOrigin,originChecked=0; const $=id=>document.getElementById(id),esc=x=>String(x??'').replace(/[&<>"']/g,c=>({'&':'&','<':'<','>':'>','"':'"',"'":'''}[c])); const fmt=(x,n=2)=>typeof x==='number'?x.toFixed(n):'—',tok=x=>typeof x==='number'?(x/1000).toFixed(1)+'k':'—'; async function load(){const path=cohort+'.json';if(Date.now()-originChecked>300000){originChecked=Date.now();liveOrigin=null;try{const r=await fetch('https://huggingface.co/datasets/HuggingFriends/PixelWorld/resolve/main/live/catalogue.json?t='+Date.now(),{cache:'no-store',signal:AbortSignal.timeout(6000)});const c=await r.json();if(c.live_origin&&new URL(c.live_origin).protocol==='https:')liveOrigin=c.live_origin}catch(e){}}let urls=[HF+path];if(liveOrigin)urls.unshift(new URL('flash_'+path,liveOrigin).href);if(!document.body.dataset.liveBase)urls.unshift('flash_'+path);let error;for(const url of urls){try{let r=await fetch(url+'?t='+Date.now(),{cache:'no-store',signal:AbortSignal.timeout(12000)});if(!r.ok)throw Error('HTTP '+r.status);return await r.json()}catch(e){error=e}}throw error} function chart(arms){const pts=arms.filter(a=>a.expected_cases>=20&&a.scored_cases===a.expected_cases&&typeof a.mean_cost_normalized70==='number'&&typeof a.mean_v1==='number');if(!pts.length){$('chart').innerHTML='

等待完整匹配评分。这里不展示占位分数。

';return}const W=850,H=340,L=70,T=25,R=30,B=55,xmax=Math.max(...pts.map(a=>a.mean_cost_normalized70))*1.15,ymax=Math.max(.3,...pts.map(a=>a.mean_v1))*1.2;let s='';for(let i=0;i<=4;i++){let y=H-B-(H-B-T)*i/4;s+=''+fmt(ymax*i/4)+'';let x=L+(W-R-L)*i/4;s+='$'+fmt(xmax*i/4)+''}const colors=['#2563eb','#16803b','#7c3aed','#a8650a','#c43e30'];pts.forEach((a,i)=>{let x=L+a.mean_cost_normalized70/xmax*(W-L-R),y=H-B-a.mean_v1/ymax*(H-T-B);const anchor=x>W*.7?'end':'start',labelX=x+(anchor==='end'?-12:12),labelY=y+(a.key==='baseline'?24:a.key==='receipt'?-32:-12),short={baseline:'Baseline',api:'Save API',receipt:'API + receipt',strict:'Four-call guidance'}[a.key]||a.label;s+=''+esc(a.label)+' · '+a.scored_cases+' cases · $'+fmt(a.mean_cost_normalized70)+' · IoU '+fmt(a.mean_v1,4)+''+esc(short)+''});s+='Cost / fully measured attempt · 70% cache scenarioSubset weighted spatial IoU v1 ↑';$('chart').innerHTML=s} function render(){const arms=report.arms||[];$('scope').textContent=report.scope;$('sync').textContent='更新:'+new Date(report.updated_utc).toLocaleString();$('condition').textContent='质量采样:'+(report.quality_scoring_fps||4)+' FPS / '+(report.quality_scoring_frames||20)+' 帧 · '+(cohort!=='legacy'?'工作中的视觉工具 · 20 个独立场景 · 正式 Flash 版本待确认':'旧开发条件:附带首帧,但输出图片工具因 helper 校验失败而不可用。此处数据不作为完整 Vision 主评测。');$('rows').innerHTML=arms.map(a=>{let c=a.counts||{},q=a.paired?.v1,e=a.paired_economics;return''+esc(a.label)+''+a.valid_rgb+'/'+a.expected_cases+' RGB · '+a.original_protocol_pass+' 协议通过
'+(a.excluded_from_acceptance?'已停止 · 不用于版本选择':(c.running||0)+' 运行 · '+a.pending+' 待生成 · '+(c.failed||0)+' 真实失败 · '+(c.stale||0)+' infra 待恢复')+''+tok(a.mean_input)+' / '+tok(a.mean_output)+'
'+a.usage_measured_cases+' 次完整 usage'+(a.unknown_prior_usage_cases?.length?'
历史消耗不完整:'+a.unknown_prior_usage_cases.length+' case':'')+''+ (typeof a.mean_cost_normalized70==='number'?'$'+fmt(a.mean_cost_normalized70):'—')+(typeof a.cost_per_protocol_delivery_normalized70==='number'?'
$'+fmt(a.cost_per_protocol_delivery_normalized70)+' / 有效交付':'')+(typeof e?.cost_per_delivery_normalized70_relative_delta==='number'?'
配对成本 '+fmt(e.cost_per_delivery_normalized70_relative_delta*100,1)+'% · '+e.paired_closed_cases+' cases':'')+'
实测缓存:$'+fmt(a.mean_cost_measured_cache)+''+a.scored_cases+'/'+a.expected_cases+'
'+fmt(a.mean_v1,4)+' / '+fmt(a.mean_v2,4)+''+(q?fmt(q.relative_mean_delta*100,1)+'%
'+(Array.isArray(q.ci95)?'Δ CI ['+fmt(q.ci95[0],4)+', '+fmt(q.ci95[1],4)+']':'样本不足以估计区间')+'':'—')+''}).join('');$('trace').innerHTML=arms.map(a=>{let t=a.trace||{};return''+esc(a.label)+''+fmt(t.mean_exec_calls,1)+''+fmt(t.mean_patch_calls,1)+''+fmt(t.mean_image_calls,1)+''+fmt(t.mean_returned_image_messages,1)+''+fmt(t.mean_image_helper_failures,1)+''+(t.source_reads?.['artifact_io.py']??'—')+''+(t.source_reads?.['player_template.html']??'—')+''}).join('');chart(arms)} function renderRefinement(){const r=report.refinement;if(!r){$('refinement').innerHTML='

首个候选对照只在匹配的原生 24 FPS 评分中展示。

';return}let s='

'+r.matched_cases+' 个配对案例 · '+r.changed_tensor_cases+' 个保存的 tensor 文件发生变化

';for(const key of ['v1','v2']){const q=r.paired?.[key];s+=''}s+='
指标首个有效候选最终候选变化的 95% 区间改善 / 降低 / 持平
IoU '+key+''+fmt(r.first_mean?.[key],4)+''+fmt(r.final_mean?.[key],4)+''+(q?.ci95?'['+fmt(q.ci95[0],4)+', '+fmt(q.ci95[1],4)+']':'—')+''+(q?q.wins+' / '+q.losses+' / '+(r.matched_cases-q.wins-q.losses):'—')+'
';const u=r.post_submission_usage;if(u?.measured_cases)s+='

'+u.measured_cases+' 个案例的逐请求 usage 与最终记录一致。首个有效候选保存后,报告了总 input 的 '+fmt(u.input_fraction_reported_after*100,1)+'%、总 output 的 '+fmt(u.output_fraction_reported_after*100,1)+'%;此后平均运行 '+fmt(u.mean_seconds_after/60,1)+' 分钟。

';s+='

这是已有轨迹的描述性比较。保存后的消耗包含检查、修订和验证,不能全部算作浪费,也不证明提前停止会保持质量。

';$('refinement').innerHTML=s} async function showExamples(){if(cohort==='legacy'){$('examples').textContent='旧开发条件单独保留,不与当前示例混排。';return}const playing=$('examples').querySelector('video');if(playing&&!playing.paused)return;try{const response=await fetch(HF+(cohort.startsWith('prompt_')?'prompt_examples.json':cohort.startsWith('boundary_')?'boundary_examples.json':cohort.startsWith('submission_')?'submission_examples.json':'examples.json')+'?t='+Date.now(),{cache:'no-store',signal:AbortSignal.timeout(12000)});if(!response.ok)throw Error('HTTP '+response.status);const data=await response.json(),rows=data.examples||[],ids=[...new Set(rows.map(x=>x.case))].sort();if(!ids.length)return;if(!ids.includes(exampleCase))exampleCase=ids[0];const labels=Object.fromEntries((report.arms||[]).map(a=>[a.key,a.label]));$('examples').innerHTML='
'+rows.filter(x=>x.case===exampleCase).map(x=>{const candidate=(x.candidates||[]).at(-1);return'
'+esc(labels[x.arm]||x.arm)+' · Attempt '+esc(x.attempt||x.detail?.match(/attempt_(\d+)\.json/)?.[1]||1)+'

'+(x.protocol_pass?'交付协议通过':'交付协议未通过 · 保留生成结果供检查')+'

'+(candidate?.preview_mp4?'':'

尚无可播放候选

')+'

完整详情'+(x.trace?' · 完整脱敏 Trace':'')+'

'}).join('')+'
';$('example-case').onchange=e=>{exampleCase=e.target.value;showExamples()}}catch(e){$('examples').textContent='已完成视频和完整 Trace 正在自动发布;汇总数据继续刷新。'}} async function showSubmissionProbe(){let urls=[HF+'submission_probe.json'];if(liveOrigin)urls.unshift(new URL('flash_submission_probe.json',liveOrigin).href);for(const url of urls){try{const r=await fetch(url+'?t='+Date.now(),{cache:'no-store',signal:AbortSignal.timeout(6000)});if(!r.ok)continue;const d=await r.json();$('submission-probe').innerHTML='

'+esc(d.model||'GPT-5.6-Luna')+' · '+esc(d.case)+' · Attempt '+esc(d.attempt||1)+' · '+esc(d.status)+(d.active?' · 进程已核验运行中':'')+'

'+(d.valid_delivery?'1 / 1 有效交付':'0 / 1 有效交付')+' · '+esc(d.submission_tool_calls||0)+' 次提交工具调用 · '+esc(d.attempt_records||0)+' 次原始记录

Input '+tok(d.input_tokens)+' · Output '+tok(d.output_tokens)+(d.scored?' · Native24 IoU '+fmt(d.score.v1,4)+' / '+fmt(d.score.v2,4):' · 原生评分待完成')+'

单例机制 smoke,不能证明省 token 或质量保持。

';return}catch(e){}}$('submission-probe').textContent='正在等待实际 smoke 记录。'} async function poll(){try{report=await load();render();renderRefinement();showExamples();showSubmissionProbe()}catch(e){$('sync').textContent='报告同步等待:'+e.message}}document.querySelectorAll('[data-cohort]').forEach(b=>b.onclick=()=>{cohort=b.dataset.cohort;poll()});poll();setInterval(poll,30000) })();