Spaces:
Running
chore(sync): mirror front-door files to Space (hf-sync)
Browse filesAutomated front-door sync from szl-holdings/a11oy main via hf-sync.
Added/updated: cathedral.html, console/docs.html, console/index.html, console/pricing.html, console/throne-room.html, console/throne-room.js, pages/api-keys.html, pages/audit.html, pages/ayni.html, pages/brain-dual.html, pages/brain-jack.html, pages/brain.html, pages/chaski.html, pages/codex-kernel.html, pages/company.html, pages/compliance.html, pages/console.html, pages/counter-uas.html, pages/cued-engagement.html, pages/docs.html, pages/evidence.html, pages/gap-report.html, pages/harvest.html, pages/hatun-mcp.html, pages/hub.html, pages/integrations.html, pages/landing.html, pages/mesh.html, pages/observability.html, pages/operator_organ.html, pages/pricing.html, pages/run-all.html, pages/sdk.html, pages/security.html, pages/status.html, pages/substrate.html, pages/superpowers.html, pages/throne-room.html, pages/throne-room.js, pages/uds.html, pages/upgrades.html, pages/wallpa.html, pages/warhacker.html, pages/wasi-rikuq.html, pages/wires.html, static/a11oy_cathedral.js
Deleted (gone from GitHub main): (none)
Keeps the served front-door (pages/*.html, console/*.html) identical
to GitHub main so an HF factory rebuild never drops a GitHub edit or
keeps serving a page that was deleted on GitHub.
- pages/console.html +85 -25
- pages/harvest.html +10 -2
|
@@ -319,6 +319,17 @@ details.raw[open] summary{color:var(--muted);}
|
|
| 319 |
.tl-graphbox{height:clamp(280px,46vh,380px);background:#080808;border:1px solid var(--gold-line);border-radius:10px}
|
| 320 |
.ln-dagbox{height:clamp(300px,50vh,440px);background:#080808;border:1px solid var(--gold-line);border-radius:10px}
|
| 321 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 322 |
</style>
|
| 323 |
</head>
|
| 324 |
<body>
|
|
@@ -506,6 +517,39 @@ const RED='#b06a5a',AMBER='#c9a05f';
|
|
| 506 |
function fetchTimeout(url,ms,opts){const ctl=new AbortController();const t=setTimeout(()=>ctl.abort(),ms||12000);
|
| 507 |
return fetch(url,Object.assign({signal:ctl.signal},opts||{})).finally(()=>clearTimeout(t));}
|
| 508 |
async function getPublic(url,ms){const r=await fetchTimeout(url,ms);if(!r.ok)throw new Error('HTTP '+r.status);return r.json();}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 509 |
// ===== In-browser DSSE receipt verification (WebCrypto, ECDSA P-256 / SHA-256) =====
|
| 510 |
// Fetches a11oy's OWN in-image public key (/cosign.pub) and a signed receipt
|
| 511 |
// envelope (/api/a11oy/v1/receipt/export), rebuilds the signing pre-auth encoding, and verifies
|
|
@@ -637,25 +681,25 @@ const LAMBDA_FRONTIER_CARDS=`<div class="grid2"><div class="card" style="border-
|
|
| 637 |
const VIEWS={
|
| 638 |
command:{title:'Command Center',badge:'LIVE',sub:'One pane of glass over the whole governed-AI platform \u2014 live service health, the connected system map, trust posture, and a verifiable audit trail.',
|
| 639 |
render:async(c)=>{c.innerHTML=`<div class="kpis">
|
| 640 |
-
<div class="kpi"><div class="k">Services up</div><div class="v live" id="k-fleet">
|
| 641 |
-
<div class="kpi"><div class="k">Connections</div><div class="v teal" id="k-wires">
|
| 642 |
-
<div class="kpi"><div class="k">Trust score</div><div class="v teal" id="k-lam">
|
| 643 |
-
<div class="kpi"><div class="k">Decisions today</div><div class="v" id="k-dec">
|
| 644 |
<div class="kpi"><div class="k">Build security</div><div class="v teal">SLSA L1+L2</div><div class="d">attested · L3 roadmap</div></div></div>
|
| 645 |
<div class="grid2">
|
| 646 |
<div class="card"><div class="card-h"><span class="card-t">Trust posture</span><span class="card-ep">live</span></div><div class="chartbox"><canvas id="cmd-radar"></canvas></div></div>
|
| 647 |
<div class="card"><div class="card-h"><span class="card-t">Safety gate posture</span><span class="card-ep">live</span></div><div class="chartbox"><canvas id="cmd-gates"></canvas></div><div class="legend"><span><i style="background:#5fb3a3"></i>allow-capable</span><span><i style="background:#b06a5a"></i>deny-by-default</span></div></div>
|
| 648 |
</div>
|
| 649 |
-
<div class="card"><div class="card-h"><span class="card-t">Service health</span><span class="card-ep">live probe</span></div><div class="brain-note" style="margin:.1rem 0 .5rem"><b>How to read “Services up”.</b> This
|
| 650 |
-
<div class="card"><div class="card-h"><span class="card-t">Performance constants</span><span class="card-ep">real measured benchmarks</span></div><div class="kpis" id="cmd-perf"><
|
| 651 |
// instant: trust radar (this service)
|
| 652 |
try{const d=await getJSON(API+'/v1/lambda');const ax=d.axes||[];radar('cmd-radar',ax.map(a=>a.name),ax.map(a=>a.score||0));setTxt('k-lam',(d.lambda||0).toFixed?d.lambda.toFixed(3):d.lambda);}catch(e){}
|
| 653 |
// safety gates posture (policy, fast)
|
| 654 |
try{const g=await orgGet('core','/api/a11oy/v1/policy/gates');const gs=g.gates||[];const deny=gs.filter(x=>x.expectedDecision==='deny').length;doughnut('cmd-gates',['allow-capable','deny-by-default'],[gs.length-deny,deny],[TEAL,'#b06a5a']);}catch(e){}
|
| 655 |
// live service probe (slower) non-blocking
|
| 656 |
getJSON(API+'/v1/observability/summary').then(d=>{const mr=d.mesh_reach||{};const keys=Object.keys(mr);let ok=0;setHTML('cmd-fleet','');
|
| 657 |
-
keys.forEach(k=>{const p=mr[k];const up=(p.status||'ok')==='ok';if(up)ok++;addHTML('cmd-fleet',`<div class="row"><span class="badge ${up?'b-live':'b-
|
| 658 |
-
setTxt('k-fleet',keys.length?ok+'/'+keys.length:'\u2014');}).catch(()=>{
|
| 659 |
try{const m=await getJSON(API+'/v1/mesh/state');setTxt('k-wires',Object.keys(m.wires||{}).length);}catch(e){}
|
| 660 |
try{const f=await orgGet('core','/api/a11oy/v1/policy/decisions/feed?limit=50');setTxt('k-dec',f.total_buffered??(f.verdicts||[]).length);}catch(e){}
|
| 661 |
// performance constants from published knowledge bundle (measured benchmarks)
|
|
@@ -5642,7 +5686,9 @@ window.warboard_init=warboard_init; window.warboard_all=warboard_all;
|
|
| 5642 |
+'</div>'; };
|
| 5643 |
|
| 5644 |
/* small helper: KPI card */
|
| 5645 |
-
|
|
|
|
|
|
|
| 5646 |
function card(t,ep,inner){ return '<div class="card"><div class="card-h"><span class="card-t">'+t+'</span><span class="card-ep">'+(ep||'')+'</span></div>'+inner+'</div>'; }
|
| 5647 |
function box3d(id){ return '<div id="'+id+'" style="height:380px;position:relative"></div>'; }
|
| 5648 |
var HON=window.HONEST||'';
|
|
@@ -5665,31 +5711,32 @@ window.warboard_init=warboard_init; window.warboard_all=warboard_all;
|
|
| 5665 |
+card('Trust posture (13-axis Λ)','live '+window.a11oyPoweredBy(['F19','F1']),'<div class="chartbox"><canvas id="cc-radar"></canvas></div>')
|
| 5666 |
+card('Governed throughput by vertical','live · auto-poll','<div class="chartbox"><canvas id="cc-bars"></canvas></div>')
|
| 5667 |
+'</div>'
|
| 5668 |
-
+card('Service health','live probe · <span id="cc-stamp" class="mono dim" style="font-size:10px"></span>','<div class="brain-note" style="margin:.1rem 0 .5rem"><b>How to read “Services up”.</b> This
|
| 5669 |
-
+card('Rolling receipt stream — ALL verticals',''+liveDot()+'live · one tamper-evident chain','<div id="cc-stream"><
|
| 5670 |
+'<div class="card"><div class="card-h"><span class="card-t">Governance engine — powered by the proven formulas</span><span class="card-ep">honest maturity labels</span></div>'
|
| 5671 |
+'<div id="cc-formulas"></div></div>'
|
| 5672 |
+HON;
|
| 5673 |
// formulas instilled
|
| 5674 |
H('cc-formulas', window.a11oyFormula('F1')+window.a11oyFormula('F19')+window.a11oyFormula('F11')+window.a11oyFormula('F18')+window.a11oyFormula('F12'));
|
| 5675 |
-
// trust radar
|
| 5676 |
-
try{var
|
| 5677 |
-
|
|
|
|
| 5678 |
window.a11oyPoll(async function(){
|
| 5679 |
-
try{ var
|
| 5680 |
keys.forEach(function(k){var p=mr[k];var up=(p.status||'ok')==='ok';if(up)ok++;
|
| 5681 |
-
html+='<div class="row"><span class="badge '+(up?'b-live':'b-
|
| 5682 |
-
H('cc-fleet',html); T('cc-svc',keys.length?ok+'/'+keys.length:'—');
|
| 5683 |
T('cc-chain', s.dag_depth!=null?s.dag_depth:'—');
|
| 5684 |
-
}catch(e){}
|
| 5685 |
-
try{ var
|
| 5686 |
-
try{ var
|
| 5687 |
rs.forEach(function(r){ sh+=window.a11oyReceiptRow(r); });
|
| 5688 |
H('cc-stream', sh||'<div class="row mono dim">no receipts yet</div>');
|
| 5689 |
-
T('cc-chain', L.chain_depth);
|
| 5690 |
var counts=L.verticals_in_window||{}; var labs=Object.keys(counts); var vals=labs.map(function(k){return counts[k];});
|
| 5691 |
if(window.barH&&labs.length) window.barH('cc-bars',labs,vals,labs.map(function(){return TEAL;}));
|
| 5692 |
-
}catch(e){}
|
| 5693 |
}, 'cc-stamp');
|
| 5694 |
T('cc-slsa','SLSA L1+L2');
|
| 5695 |
}
|
|
@@ -8778,7 +8825,7 @@ window.warboard_init=warboard_init; window.warboard_all=warboard_all;
|
|
| 8778 |
'<div class="card"><div class="card-h"><span class="card-t">Node roster</span><span class="card-ep" id="udm-fresh">live</span></div><div id="udm-list"><div class="row mono dim">probing mesh\u2026</div></div>'+
|
| 8779 |
'<div class="brain-note" id="udm-note"></div></div></div>'+
|
| 8780 |
'<div class="card"><div class="card-h"><span class="card-t">In-image mesh vs external organs — honest reconciliation</span><span class="card-ep">read with Command Center</span></div>'+
|
| 8781 |
-
'<div class="brain-note">This 6/6 / 4-of-4 quorum is the <b>in-image capability mesh</b> a11oy actually runs on (probed live, same-origin, 0 CDN). It is <b>NOT</b> the same probe as Command Center’s “Services up
|
| 8782 |
'<div class="card"><div class="card-h"><span class="card-t">Deploy targets — same UDS bundle, cloud → edge → air-gap</span><span class="card-ep">honest · no secrets</span></div>'+
|
| 8783 |
'<div class="row"><span class="badge b-live">LIVE</span><span style="color:'+CR+'">Cloud — HF Space</span><span class="spacer mono dim">szlholdings-a11oy.hf.space · this demo deploy</span></div>'+
|
| 8784 |
'<div class="row"><span class="badge b-live">LIVE</span><span style="color:'+CR+'">Hetzner — a11oy.net</span><span class="spacer mono dim">167.233.50.75 · self-hosted</span></div>'+
|
|
@@ -13917,9 +13964,13 @@ window.warboard_init=warboard_init; window.warboard_all=warboard_all;
|
|
| 13917 |
return '<div class="card"><div style="display:flex;justify-content:space-between;align-items:center"><b>'+esc(title)+'</b>'+b+'</div><div class="dim" style="font-size:11px">'+esc(src)+'</div>'+body+'</div>';
|
| 13918 |
}
|
| 13919 |
window.energy_render=async function(c){
|
| 13920 |
-
|
|
|
|
|
|
|
|
|
|
| 13921 |
try{
|
| 13922 |
-
var
|
|
|
|
| 13923 |
if(!r.ok) throw new Error("HTTP "+r.status);
|
| 13924 |
var d=await r.json();
|
| 13925 |
var p=EH_POS[d.grid_price_posture]||EH_POS.unknown;
|
|
@@ -13948,6 +13999,15 @@ window.warboard_init=warboard_init; window.warboard_all=warboard_all;
|
|
| 13948 |
+'<div class="dim" style="font-size:11px">grid index: '+esc(d.uk_carbon_index||'—')+'</div>');
|
| 13949 |
h+='</div>';
|
| 13950 |
var when=d.ts?new Date(d.ts*1000).toLocaleTimeString():'now';
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 13951 |
h+='<div class="dim" style="font-size:11px;margin-top:.5rem">'+esc(d.feeds_live)+'/'+esc(d.feeds_total)+' feeds live · '+(d.cached?'cached':'fresh')+' · '+esc(when)
|
| 13952 |
+' · <a href="'+EH_API+'/harvest" target="_blank" rel="noopener">raw API</a> · <a href="https://a11oy.net/energy/" target="_blank" rel="noopener">standalone page ↗</a></div>';
|
| 13953 |
c.innerHTML=h;
|
|
|
|
| 319 |
.tl-graphbox{height:clamp(280px,46vh,380px);background:#080808;border:1px solid var(--gold-line);border-radius:10px}
|
| 320 |
.ln-dagbox{height:clamp(300px,50vh,440px);background:#080808;border:1px solid var(--gold-line);border-radius:10px}
|
| 321 |
|
| 322 |
+
/* investor-grade-polish (polish/console-investor-grade): honest animated loading
|
| 323 |
+
skeletons. Replaces blank "···"/"loading…"/"probing…" placeholders with a
|
| 324 |
+
shimmering block so a panel mid-fetch reads as LOADING, never BROKEN. Purely
|
| 325 |
+
cosmetic; resolves to a real value or an honest labeled state in <1-2s. */
|
| 326 |
+
@keyframes skelshimmer{0%{background-position:-200px 0}100%{background-position:calc(200px + 100%) 0}}
|
| 327 |
+
.skel{display:inline-block;border-radius:6px;background:linear-gradient(90deg,rgba(201,183,135,0.06) 25%,rgba(201,183,135,0.16) 37%,rgba(201,183,135,0.06) 63%);background-size:200px 100%;animation:skelshimmer 1.2s ease-in-out infinite;vertical-align:middle}
|
| 328 |
+
.skel-val{width:3.2em;height:1.05em}
|
| 329 |
+
.skel-row{height:.9em;margin:.32rem 0;border-radius:5px}
|
| 330 |
+
.skel-row.w90{width:90%}.skel-row.w70{width:70%}.skel-row.w55{width:55%}
|
| 331 |
+
.skel-caption{font-family:var(--mono);font-size:10px;color:var(--muted);letter-spacing:.04em;margin-top:.35rem;opacity:.8}
|
| 332 |
+
|
| 333 |
</style>
|
| 334 |
</head>
|
| 335 |
<body>
|
|
|
|
| 517 |
function fetchTimeout(url,ms,opts){const ctl=new AbortController();const t=setTimeout(()=>ctl.abort(),ms||12000);
|
| 518 |
return fetch(url,Object.assign({signal:ctl.signal},opts||{})).finally(()=>clearTimeout(t));}
|
| 519 |
async function getPublic(url,ms){const r=await fetchTimeout(url,ms);if(!r.ok)throw new Error('HTTP '+r.status);return r.json();}
|
| 520 |
+
/* ===== investor-grade-polish: FAIL-FAST KPI fetch + last-good cache ============
|
| 521 |
+
(polish/console-investor-grade) Investor watching live must never see an endless
|
| 522 |
+
"probing…". gjFast() wraps the JSON fetch with a SHORT abort timeout (default
|
| 523 |
+
1500ms) and a same-origin last-good in-memory cache. On timeout/error it does
|
| 524 |
+
NOT hang and does NOT fabricate: it resurfaces the last real value if we ever
|
| 525 |
+
had one, otherwise it throws so the caller can paint an HONEST labeled degraded
|
| 526 |
+
state ("not available right now") instead of a spinner. This composes with the
|
| 527 |
+
server-side circuit breaker (szl_resilience) + TTL cache (szl_backend_hardening)
|
| 528 |
+
already on main: the backend fails fast to a cached/honest value, and the
|
| 529 |
+
frontend refuses to wait on it. Doctrine v11: no fake values, degrade to a
|
| 530 |
+
labeled state. */
|
| 531 |
+
window.__gjLast=window.__gjLast||{};
|
| 532 |
+
async function gjFast(url,ms){
|
| 533 |
+
try{
|
| 534 |
+
const r=await fetchTimeout(url,ms||1500);
|
| 535 |
+
const ct=r.headers.get('content-type')||'';
|
| 536 |
+
if(!r.ok) throw new Error('HTTP '+r.status);
|
| 537 |
+
if(ct.indexOf('text/html')>=0) throw new Error('route not deployed here');
|
| 538 |
+
const j=await r.json();
|
| 539 |
+
window.__gjLast[url]={v:j,t:Date.now()};
|
| 540 |
+
return {data:j, degraded:false, cached:false};
|
| 541 |
+
}catch(e){
|
| 542 |
+
const c=window.__gjLast[url];
|
| 543 |
+
if(c){ return {data:c.v, degraded:true, cached:true, age:Date.now()-c.t, err:(e&&e.message)||String(e)}; }
|
| 544 |
+
const err=new Error((e&&e.message)||String(e)); err.__failFast=true; throw err;
|
| 545 |
+
}
|
| 546 |
+
}
|
| 547 |
+
/* honest degraded chip — shown when a KPI cannot be observed right now (never "down",
|
| 548 |
+
never fabricated). Reads as a labeled state, not a broken panel. */
|
| 549 |
+
function honestDegraded(label){ return '<span class="badge b-gold" title="This metric cannot be observed from this Space right now — shown honestly as not-available rather than faked.">'+(label||'not available right now')+'</span>'; }
|
| 550 |
+
function skelVal(){ return '<span class="skel skel-val"></span>'; }
|
| 551 |
+
function skelRows(n){ var w=['w90','w70','w55','w90','w70'],h=''; n=n||3; for(var i=0;i<n;i++){ h+='<div class="skel skel-row '+w[i%w.length]+'"></div>'; } return '<div class="skel-wrap">'+h+'<div class="skel-caption">loading live data…</div></div>'; }
|
| 552 |
+
window.gjFast=gjFast; window.honestDegraded=honestDegraded; window.skelVal=skelVal; window.skelRows=skelRows;
|
| 553 |
// ===== In-browser DSSE receipt verification (WebCrypto, ECDSA P-256 / SHA-256) =====
|
| 554 |
// Fetches a11oy's OWN in-image public key (/cosign.pub) and a signed receipt
|
| 555 |
// envelope (/api/a11oy/v1/receipt/export), rebuilds the signing pre-auth encoding, and verifies
|
|
|
|
| 681 |
const VIEWS={
|
| 682 |
command:{title:'Command Center',badge:'LIVE',sub:'One pane of glass over the whole governed-AI platform \u2014 live service health, the connected system map, trust posture, and a verifiable audit trail.',
|
| 683 |
render:async(c)=>{c.innerHTML=`<div class="kpis">
|
| 684 |
+
<div class="kpi"><div class="k">Services up</div><div class="v live" id="k-fleet"><span class="skel skel-val"></span></div><div class="d">live health probe</div></div>
|
| 685 |
+
<div class="kpi"><div class="k">Connections</div><div class="v teal" id="k-wires"><span class="skel skel-val"></span></div><div class="d">cross-service links</div></div>
|
| 686 |
+
<div class="kpi"><div class="k">Trust score</div><div class="v teal" id="k-lam"><span class="skel skel-val"></span></div><div class="d">vs floor 0.90</div></div>
|
| 687 |
+
<div class="kpi"><div class="k">Decisions today</div><div class="v" id="k-dec"><span class="skel skel-val"></span></div><div class="d">governed + logged</div></div>
|
| 688 |
<div class="kpi"><div class="k">Build security</div><div class="v teal">SLSA L1+L2</div><div class="d">attested · L3 roadmap</div></div></div>
|
| 689 |
<div class="grid2">
|
| 690 |
<div class="card"><div class="card-h"><span class="card-t">Trust posture</span><span class="card-ep">live</span></div><div class="chartbox"><canvas id="cmd-radar"></canvas></div></div>
|
| 691 |
<div class="card"><div class="card-h"><span class="card-t">Safety gate posture</span><span class="card-ep">live</span></div><div class="chartbox"><canvas id="cmd-gates"></canvas></div><div class="legend"><span><i style="background:#5fb3a3"></i>allow-capable</span><span><i style="background:#b06a5a"></i>deny-by-default</span></div></div>
|
| 692 |
</div>
|
| 693 |
+
<div class="card"><div class="card-h"><span class="card-t">Service health</span><span class="card-ep">live probe</span></div><div class="brain-note" style="margin:.1rem 0 .5rem"><b>How to read “Services up”.</b> This Space runs the <b>governed mesh</b> — the in-image capability mesh is <b>6/6 healthy</b> (Byzantine quorum 4/4 REACHED, see the <b>UDS 4/4 Quorum</b> tab). The heavy <b>organ backends (Reasoning/Policy/Operator/Receipts)</b> run on <b>dedicated infrastructure (roadmap)</b>, so on this demo Space they are shown honestly as <b>not-deployed-here</b> rather than faked “up”. Same truth, two probes: organ backends not deployed on this Space; the governed mesh a11oy actually runs on is fully healthy.</div><div id="cmd-fleet">${skelRows(4)}</div></div>
|
| 694 |
+
<div class="card"><div class="card-h"><span class="card-t">Performance constants</span><span class="card-ep">real measured benchmarks</span></div><div class="kpis" id="cmd-perf">${skelRows(3)}</div><div class="brain-note">Measured benchmarks from the published thesis brief (maturity: measured). Source: THESIS_BRIEF.md / Zenodo.</div></div>${HONEST}`;
|
| 695 |
// instant: trust radar (this service)
|
| 696 |
try{const d=await getJSON(API+'/v1/lambda');const ax=d.axes||[];radar('cmd-radar',ax.map(a=>a.name),ax.map(a=>a.score||0));setTxt('k-lam',(d.lambda||0).toFixed?d.lambda.toFixed(3):d.lambda);}catch(e){}
|
| 697 |
// safety gates posture (policy, fast)
|
| 698 |
try{const g=await orgGet('core','/api/a11oy/v1/policy/gates');const gs=g.gates||[];const deny=gs.filter(x=>x.expectedDecision==='deny').length;doughnut('cmd-gates',['allow-capable','deny-by-default'],[gs.length-deny,deny],[TEAL,'#b06a5a']);}catch(e){}
|
| 699 |
// live service probe (slower) non-blocking
|
| 700 |
getJSON(API+'/v1/observability/summary').then(d=>{const mr=d.mesh_reach||{};const keys=Object.keys(mr);let ok=0;setHTML('cmd-fleet','');
|
| 701 |
+
keys.forEach(k=>{const p=mr[k];const up=(p.status||'ok')==='ok';if(up)ok++;addHTML('cmd-fleet',`<div class="row"><span class="badge ${up?'b-live':'b-gold'}">${up?'UP':'NOT DEPLOYED HERE'}</span><span>${esc(p.name||k)}</span><span class="spacer mono dim">${p.latency_ms?Math.round(p.latency_ms)+'ms':(up?'':'dedicated infra (roadmap)')}</span></div>`);});
|
| 702 |
+
setTxt('k-fleet',keys.length?ok+'/'+keys.length:'\u2014');}).catch(()=>{/* investor-grade-polish: NEVER fabricate "up" on error — degrade to an honest labeled state (doctrine v11) */setHTML('cmd-fleet','<div class="row mono dim">service health not available right now — shown honestly, not faked.</div>');setHTML('k-fleet',honestDegraded('n/a'));});
|
| 703 |
try{const m=await getJSON(API+'/v1/mesh/state');setTxt('k-wires',Object.keys(m.wires||{}).length);}catch(e){}
|
| 704 |
try{const f=await orgGet('core','/api/a11oy/v1/policy/decisions/feed?limit=50');setTxt('k-dec',f.total_buffered??(f.verdicts||[]).length);}catch(e){}
|
| 705 |
// performance constants from published knowledge bundle (measured benchmarks)
|
|
|
|
| 5686 |
+'</div>'; };
|
| 5687 |
|
| 5688 |
/* small helper: KPI card */
|
| 5689 |
+
/* investor-grade-polish: KPI cards now seed with an animated skeleton value
|
| 5690 |
+
(not a bare "…") so a card mid-fetch reads as LOADING, never BROKEN. */
|
| 5691 |
+
function kpi(k,id,d,cls){ return '<div class="kpi"><div class="k">'+k+'</div><div class="v '+(cls||'')+'" id="'+id+'"><span class="skel skel-val"></span></div><div class="d">'+(d||'')+'</div></div>'; }
|
| 5692 |
function card(t,ep,inner){ return '<div class="card"><div class="card-h"><span class="card-t">'+t+'</span><span class="card-ep">'+(ep||'')+'</span></div>'+inner+'</div>'; }
|
| 5693 |
function box3d(id){ return '<div id="'+id+'" style="height:380px;position:relative"></div>'; }
|
| 5694 |
var HON=window.HONEST||'';
|
|
|
|
| 5711 |
+card('Trust posture (13-axis Λ)','live '+window.a11oyPoweredBy(['F19','F1']),'<div class="chartbox"><canvas id="cc-radar"></canvas></div>')
|
| 5712 |
+card('Governed throughput by vertical','live · auto-poll','<div class="chartbox"><canvas id="cc-bars"></canvas></div>')
|
| 5713 |
+'</div>'
|
| 5714 |
+
+card('Service health','live probe · <span id="cc-stamp" class="mono dim" style="font-size:10px"></span>','<div class="brain-note" style="margin:.1rem 0 .5rem"><b>How to read “Services up”.</b> This Space runs the <b>governed mesh</b> — the in-image capability mesh is <b>6/6 healthy</b> (Byzantine quorum 4/4 REACHED, see the <b>UDS 4/4 Quorum</b> tab). The heavy <b>organ backends (Reasoning / Policy / Operator / Receipts)</b> run on <b>dedicated infrastructure (roadmap)</b>, so on this demo Space they are shown honestly as <b>not-deployed-here</b> rather than faked “up”. Same truth, two probes: the governed mesh a11oy actually runs on is fully healthy; the organ backends are not deployed on this Space.</div><div id="cc-fleet">'+skelRows(4)+'</div>')
|
| 5715 |
+
+card('Rolling receipt stream — ALL verticals',''+liveDot()+'live · one tamper-evident chain','<div id="cc-stream">'+skelRows(3)+'</div>')
|
| 5716 |
+'<div class="card"><div class="card-h"><span class="card-t">Governance engine — powered by the proven formulas</span><span class="card-ep">honest maturity labels</span></div>'
|
| 5717 |
+'<div id="cc-formulas"></div></div>'
|
| 5718 |
+HON;
|
| 5719 |
// formulas instilled
|
| 5720 |
H('cc-formulas', window.a11oyFormula('F1')+window.a11oyFormula('F19')+window.a11oyFormula('F11')+window.a11oyFormula('F18')+window.a11oyFormula('F12'));
|
| 5721 |
+
// trust radar — FAIL-FAST: short timeout, last-good cache, honest degraded chip (never an endless spinner)
|
| 5722 |
+
try{var rL=await gjFast(API+'/v1/lambda');var d=rL.data;var ax=d.axes||[];if(window.radar)window.radar('cc-radar',ax.map(function(a){return a.name;}),ax.map(function(a){return a.score||0;}));T('cc-lam',(d.lambda||0).toFixed?d.lambda.toFixed(3):d.lambda);}
|
| 5723 |
+
catch(e){ H('cc-lam', honestDegraded('not available right now')); }
|
| 5724 |
+
// auto-poll: services + decisions + chain depth + ledger stream + throughput bars (all fail-fast)
|
| 5725 |
window.a11oyPoll(async function(){
|
| 5726 |
+
try{ var rS=await gjFast(API+'/v1/observability/summary'); var s=rS.data; var mr=s.mesh_reach||{};var keys=Object.keys(mr);var ok=0;var html='';
|
| 5727 |
keys.forEach(function(k){var p=mr[k];var up=(p.status||'ok')==='ok';if(up)ok++;
|
| 5728 |
+
html+='<div class="row"><span class="badge '+(up?'b-live':'b-gold')+'">'+(up?'UP':'NOT DEPLOYED HERE')+'</span><span>'+esc(p.name||k)+'</span><span class="spacer mono dim">'+(p.latency_ms?Math.round(p.latency_ms)+'ms':(up?'':'dedicated infra (roadmap)'))+'</span></div>';});
|
| 5729 |
+
H('cc-fleet',html||'<div class="row mono dim">no services reported</div>'); T('cc-svc',keys.length?ok+'/'+keys.length:'—');
|
| 5730 |
T('cc-chain', s.dag_depth!=null?s.dag_depth:'—');
|
| 5731 |
+
}catch(e){ if(el('cc-svc')&&el('cc-svc').querySelector('.skel')) H('cc-svc', honestDegraded('n/a')); if(el('cc-fleet')&&el('cc-fleet').querySelector('.skel')) H('cc-fleet','<div class="row mono dim">service health not available right now — shown honestly, not faked.</div>'); }
|
| 5732 |
+
try{ var rF=await gjFast(API+'/v1/policy/decisions/feed?limit=50'); var f=rF.data; T('cc-dec', f.total_buffered!=null?f.total_buffered:((f.verdicts||[]).length)); }catch(e){ if(el('cc-dec')&&el('cc-dec').querySelector('.skel')) H('cc-dec', honestDegraded('n/a')); }
|
| 5733 |
+
try{ var rLg=await gjFast(API+'/v1/wow/ledger?limit=12'); var L=rLg.data; var rs=L.receipts||[]; var sh='';
|
| 5734 |
rs.forEach(function(r){ sh+=window.a11oyReceiptRow(r); });
|
| 5735 |
H('cc-stream', sh||'<div class="row mono dim">no receipts yet</div>');
|
| 5736 |
+
if(L.chain_depth!=null) T('cc-chain', L.chain_depth);
|
| 5737 |
var counts=L.verticals_in_window||{}; var labs=Object.keys(counts); var vals=labs.map(function(k){return counts[k];});
|
| 5738 |
if(window.barH&&labs.length) window.barH('cc-bars',labs,vals,labs.map(function(){return TEAL;}));
|
| 5739 |
+
}catch(e){ if(el('cc-stream')&&el('cc-stream').querySelector('.skel')) H('cc-stream','<div class="row mono dim">receipt stream not available right now — shown honestly, not faked.</div>'); }
|
| 5740 |
}, 'cc-stamp');
|
| 5741 |
T('cc-slsa','SLSA L1+L2');
|
| 5742 |
}
|
|
|
|
| 8825 |
'<div class="card"><div class="card-h"><span class="card-t">Node roster</span><span class="card-ep" id="udm-fresh">live</span></div><div id="udm-list"><div class="row mono dim">probing mesh\u2026</div></div>'+
|
| 8826 |
'<div class="brain-note" id="udm-note"></div></div></div>'+
|
| 8827 |
'<div class="card"><div class="card-h"><span class="card-t">In-image mesh vs external organs — honest reconciliation</span><span class="card-ep">read with Command Center</span></div>'+
|
| 8828 |
+
'<div class="brain-note">This 6/6 / 4-of-4 quorum is the <b>in-image capability mesh</b> a11oy actually runs on (probed live, same-origin, 0 CDN). It is <b>NOT</b> the same probe as Command Center’s “Services up”, which reports the <b>organ backends (Reasoning/Policy/Operator/Receipts)</b> that run on <b>dedicated infrastructure (roadmap)</b> — on this demo Space they are shown honestly as <b>not-deployed-here</b> rather than faked “up”. Same honest story, two probes: governed mesh healthy; organ backends not deployed on this Space.</div></div>'+
|
| 8829 |
'<div class="card"><div class="card-h"><span class="card-t">Deploy targets — same UDS bundle, cloud → edge → air-gap</span><span class="card-ep">honest · no secrets</span></div>'+
|
| 8830 |
'<div class="row"><span class="badge b-live">LIVE</span><span style="color:'+CR+'">Cloud — HF Space</span><span class="spacer mono dim">szlholdings-a11oy.hf.space · this demo deploy</span></div>'+
|
| 8831 |
'<div class="row"><span class="badge b-live">LIVE</span><span style="color:'+CR+'">Hetzner — a11oy.net</span><span class="spacer mono dim">167.233.50.75 · self-hosted</span></div>'+
|
|
|
|
| 13964 |
return '<div class="card"><div style="display:flex;justify-content:space-between;align-items:center"><b>'+esc(title)+'</b>'+b+'</div><div class="dim" style="font-size:11px">'+esc(src)+'</div>'+body+'</div>';
|
| 13965 |
}
|
| 13966 |
window.energy_render=async function(c){
|
| 13967 |
+
/* investor-grade-polish: animated skeleton while the grid feeds resolve (never a
|
| 13968 |
+
blank "reading…"), plus a SHORT abort timeout so a slow public feed cannot hang
|
| 13969 |
+
the tab — it degrades to an honest "unavailable" state, never fabricated. */
|
| 13970 |
+
c.innerHTML='<div class="card">'+(window.skelRows?window.skelRows(4):'<div class="dim">reading live grid feeds…</div>')+'</div>';
|
| 13971 |
try{
|
| 13972 |
+
var _ctl=new AbortController(); var _t=setTimeout(function(){try{_ctl.abort();}catch(e){}},2000);
|
| 13973 |
+
var r=await fetch(EH_API+"/posture",{cache:"no-store",signal:_ctl.signal}).finally(function(){clearTimeout(_t);});
|
| 13974 |
if(!r.ok) throw new Error("HTTP "+r.status);
|
| 13975 |
var d=await r.json();
|
| 13976 |
var p=EH_POS[d.grid_price_posture]||EH_POS.unknown;
|
|
|
|
| 13999 |
+'<div class="dim" style="font-size:11px">grid index: '+esc(d.uk_carbon_index||'—')+'</div>');
|
| 14000 |
h+='</div>';
|
| 14001 |
var when=d.ts?new Date(d.ts*1000).toLocaleTimeString():'now';
|
| 14002 |
+
/* investor-grade-polish: make the measured-joule story explicit + investor-legible.
|
| 14003 |
+
Honest by construction (szl_joules_truth): the grid feed is a real wholesale-price
|
| 14004 |
+
signal, but reading energy off it is NOT a power measurement — joules stay SAMPLE
|
| 14005 |
+
until a fresh on-box NVML exporter sample exists on a sovereign GPU node. */
|
| 14006 |
+
var _jl=String(d.joules_label||'sample').toLowerCase();
|
| 14007 |
+
var _jmeasured=(_jl==='measured');
|
| 14008 |
+
h+='<div class="honesty" style="margin-top:.6rem;display:flex;align-items:center;gap:.5rem;flex-wrap:wrap">'
|
| 14009 |
+
+'<span class="badge" style="border:1px solid '+(_jmeasured?'#4fb37f':'#c9a05f')+';color:'+(_jmeasured?'#5fe39a':'#c9a05f')+'">JOULES '+(_jmeasured?'MEASURED':'SAMPLE')+'</span>'
|
| 14010 |
+
+'<span class="dim" style="font-size:11.5px">This is a real grid <b>price/carbon</b> signal, not a power meter. Per <code>szl_joules_truth</code> (doctrine v11), joules read <b>SAMPLE</b> until a fresh on-box NVML exporter sample is present on a sovereign GPU node — we never fabricate a “measured” number, and this feed never sets <code>sovereign:true</code>.</span></div>';
|
| 14011 |
h+='<div class="dim" style="font-size:11px;margin-top:.5rem">'+esc(d.feeds_live)+'/'+esc(d.feeds_total)+' feeds live · '+(d.cached?'cached':'fresh')+' · '+esc(when)
|
| 14012 |
+' · <a href="'+EH_API+'/harvest" target="_blank" rel="noopener">raw API</a> · <a href="https://a11oy.net/energy/" target="_blank" rel="noopener">standalone page ↗</a></div>';
|
| 14013 |
c.innerHTML=h;
|
|
@@ -426,8 +426,15 @@ const ENDPOINTS = {
|
|
| 426 |
/* ── helpers ──────────────────────────────────────────────────── */
|
| 427 |
function q(id){ return document.getElementById(id); }
|
| 428 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 429 |
function safeFetch(url, label){
|
| 430 |
-
|
|
|
|
|
|
|
| 431 |
.then(r => {
|
| 432 |
if(!r.ok) throw new Error(`${r.status} ${r.statusText}`);
|
| 433 |
return r.json();
|
|
@@ -435,7 +442,8 @@ function safeFetch(url, label){
|
|
| 435 |
.catch(e => {
|
| 436 |
console.warn(`[harvest] ${label} failed:`, e.message);
|
| 437 |
return null;
|
| 438 |
-
})
|
|
|
|
| 439 |
}
|
| 440 |
|
| 441 |
function fmtNum(v){
|
|
|
|
| 426 |
/* ── helpers ──────────────────────────────────────────────────── */
|
| 427 |
function q(id){ return document.getElementById(id); }
|
| 428 |
|
| 429 |
+
/* investor-grade-polish (polish/console-investor-grade): fail-fast fetch. A short
|
| 430 |
+
abort timeout (1.8s) means a slow/asleep backend can never leave a harvest panel
|
| 431 |
+
stuck on its skeleton — it resolves to a real value or an honest null/labeled
|
| 432 |
+
state quickly. On failure we return null (the renderers already paint an honest
|
| 433 |
+
"unreachable"/SAMPLE state) — never a fabricated value. */
|
| 434 |
function safeFetch(url, label){
|
| 435 |
+
const ctl = new AbortController();
|
| 436 |
+
const t = setTimeout(()=>{ try{ctl.abort();}catch(e){} }, 1800);
|
| 437 |
+
return fetch(url, {cache:"no-store", signal:ctl.signal})
|
| 438 |
.then(r => {
|
| 439 |
if(!r.ok) throw new Error(`${r.status} ${r.statusText}`);
|
| 440 |
return r.json();
|
|
|
|
| 442 |
.catch(e => {
|
| 443 |
console.warn(`[harvest] ${label} failed:`, e.message);
|
| 444 |
return null;
|
| 445 |
+
})
|
| 446 |
+
.finally(()=>clearTimeout(t));
|
| 447 |
}
|
| 448 |
|
| 449 |
function fmtNum(v){
|