Build Layers 1-4 Operator, Intake, Control Plane, and Oversight UI - #99
Merged
Conversation
Turns the single-page dashboard into a multipage operator console (#91-94). Consumes EvidencePack v1 JSON only — no schema changes, no new API endpoints, no tool renames, no backend mutation. Agents read-only; mutation stays backend-only after hash-bound approval. Layer 1 — Operator console (multipage, left sidebar nav): - Overview: fleet stat cards + run list (from GET /packs) - Run Review: approval gate with exact "Approve this evidence hash" CTA, short hash preview beside the CTA + full copyable hash, before/after explain-plan diff labels (SORT present -> SORT removed / pending verification / verification failed), Safety authority section, distinct pending/approved/verified/rejected/ verification-failed states - System Map: hand-built CSS architecture map - History & Compare: comparison table of past runs + outcomes - Audit & Compliance: approvals, verification trail, trace, honest "No policy events recorded" empty state Layer 2 — Intake & API Gateway: four intake sources (labelled "planned intake path" honestly), Run Intake Service, real FastAPI routes, exact read-only /run wording, run-state-after-intake, downstream handoff. Layer 3 — Control Plane (in System Map): six deterministic service cards, run state machine (Intake -> ... -> Closed, current state highlighted from pack fields), failure handling. Layer 4 — Agent Oversight (in System Map): Main Orchestrator / Reviewer / Security agent cards, oversight constraints + catches panels, read-only downstream/sideways handoff, honest empty state. Visual identity unchanged (JetBrains Mono + IBM Plex Sans, Phosphor, slate/amber/ green palette). QA: npm run lint clean, tsc --noEmit clean, npm run build green; mobile 390x1000 verified (no horizontal overflow, CTA not clipped). Adds eslint + eslint-config-next so `npm run lint` runs (CI runs build only). Screenshots in demo/screenshots/layers/.
…_id], a11y + trace grouping Review fixes on the Layers 1-4 operator console (#91#92#93#94): - derive verification-failed from approved+after (matches controller apply_and_verify); never derive VERIFIED client-side - force-dynamic on all live-data routes; restore /runs/[run_id], repoint list links (keep /run-review alias); sidebar active-state covers /runs - anchor .gitignore runs/ -> /runs/ so the route ships (was ignored) - group agent trace into Roles / Tool Calls / Controller / Human with the 3-roles/4-tools legend; failed verify visually distinct - a11y: closed mobile drawer out of the a11y tree, aria-controls/expanded/current, Escape + focus management, named trace lists - bind approval CTA to the submitted hash; full evidence hash readable; heading order (Run Review h1 / Approval Gate h2); honest gate copy - system-map shows derivable run state in fallback (labeled, not live) - local fixtures for all five operator states (fallback-only) + vitest tests for the safety-derived helpers
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for freeto join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
This PR implements the frontend/product surfaces for Layers 1-4 (#91-94):
Built to the Layer architecture image spec; diagrams are hand-built CSS (no diagram lib) so they match the console and reflow on mobile.
Safety boundaries preserved
GET /packs; writes still go through the same-origin token proxy to/run+/packs/:id/decision).Layer 1 specifics
Before: SORT present / high docs examined→After: SORT removed / index-backed query, withAfter: pending verificationandAfter: verification failed, see tracevariants.StatusPill+displayStatus).Required screenshots
In
demo/screenshots/layers/:Test results
Note: ESLint wasn't previously configured, so this adds
eslint+eslint-config-next+.eslintrc.jsonto makenpm run lintrunnable (dashboard CI runsnpm run buildonly).Manual QA checklist
Reviewer
@d3v07 must review this PR before Layers 5-8 begin.