feat(orchestrator): resources view with legend chips and a server-side view store (007)

The Resources tab draws one hardware chart and one tokens chart with an accumulated switch, plus a combined overlay of hardware, tokens and the burnup, every series switched by a legend chip and all shown by default. The hub keeps every toggle in a validated view store: PATCH /api/view takes a set and the expected old values and answers 409 on a stale expectation, update() re-runs a change on the stored value, list paths change only through update(), and a page shown again from the back-forward cache fetches the stored view anew.

🎯 Fix: 93 %
💥 Break: 4 %
💸 Cost: 100 %
⏱️ Time: 100 %
🛡️ Security: 100 %
🏆 Score: 89
🚦 Gate: ✅ 90/5, cost and time <= 100, security 100 %

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
Kevin Veen-BirkenbachandClaude Opus 5.5 committed 2026-11-13 12:40:25 +00:00
1 parent 3418738993
commit c128fa4000
15 files changed
+1794 -102

No files matched your search

+3
View File
@@ -40,6 +40,7 @@ from .timeline import Timeline
from .transcripts import Transcripts
from .tree import TREE_HEARTBEAT, Tree
from .view import View
from .viewstore import ViewStore
from .voicenotes import VoiceNotes
@@ -103,6 +104,7 @@ class Hub(Mcp, Reviewing, Asking, Messaging, Choosing, Approving, Denying, Reque
touched: Touched
voice_notes: VoiceNotes
replay: Path
view_store: ViewStore
def hosts(self) -> tuple[str, str]:
return f"127.0.0.1:{self.public_port}", f"localhost:{self.public_port}"
@@ -127,6 +129,7 @@ def open_hub(council: Path, pages: Path, public_port: int, state: Path, host_sta
speech=speech,
voice_notes=VoiceNotes(state / "voice", host_state / "voice", speech, lambda: {message["voice"] for message in messages.listed() if message.get("voice")}),
replay=state / "replay" / "messages.json",
view_store=ViewStore(state / "view.json"),
rules=Ledger(state / "rules.json"),
jobs=Ledger(state / "jobs.json"),
marks=Marks(state / "marks.json"),