Governed Incident Response - Generative UI Global Hackathon: Agentic Interfaces
AI Tinkerers - Boston
Hackathon Showcase

Governed Incident Response

1 member

Governed Incident Response is an agentic interface for workplace safety incidents in regulated industries. The agent handles emergency procedure lookup, severity-1 notifications, and procedure update drafting. Every action runs through a governance layer before it executes: role-based access control, retrieval scoring, evidence gating, hallucination detection (HHEM), and an immutable audit chain.

The interface is two columns of generative UI. The left column is a CopilotKit chat where the agent calls tools that render live procedure cards (cited, scoped, color-coded by outcome). The right column is a real-time governance instrument panel that streams every controller decision as the agent executes: RBAC checks, retrieval scores, ACL filters, evidence thresholds, HHEM scoring with pulsing PENDING-to-PASS animation, ALERT and BLOCKED events, and CHAINED audit entries.

This is not a chatbot with a side panel. The card the user sees and the governance cascade beside it are both generated at runtime in response to agent tool calls. The chat thread is the input surface. The cards and the governance panel are the output surfaces. Both update reactively.

Demo: three queries, four governance outcomes

SERVE — Operator asks about atmospheric testing for confined space entry. RBAC passes, retrieval finds the procedure, ACL clears it, evidence gate passes, HHEM passes, audit chains. Cited card rendered.

SERVE + BLOCK + ROUTE — Operator queries a confined space collapse at a petroleum facility. Two procedures retrieved and served as cards. The agent attempts a severity-1 notification. Operator role is not authorized. BLOCKED. The notification is ROUTED to the supervisor approval queue. Three governance outcomes in one query, all visible.

REFUSE — Operator asks about TIER greenhouse gas reporting. Evidence gate scores 0.41 against a 0.70 threshold. The system refuses rather than hallucinate. Amber fail-closed card renders.

A replay fallback plays the same governance cascades from hardcoded event sequences for venue WiFi failures. No LLM calls, identical visuals.

Stack

CopilotKit 1.56.5 (react-core, react-ui, runtime) for the agentic layer and tool-driven generative UI. Three governed tools registered via useCopilotAction with custom render callbacks. Next.js 16 with App Router. TypeScript. Tailwind. Zustand for the governance event store with HHEM PENDING-to-PASS update pattern. OpenAI GPT-4o through the CopilotKit OpenAI adapter.

The pattern is general. The same governance layer is being applied to clinical care in a separate project (Provana AcuteCare) co-built with another hackathon participant.

Solo build by Arnaldo Sepulveda.

The governance pattern (RBAC, evidence gating, HHEM scoring, audit chain) was developed pre-hackathon as part of my Keystone project (governed RAG over OHS safety documents, P@1 0.75 / MRR 0.79 baseline at github.com/getkeystone/keystone-gov).

What was BUILT DURING THE HACKATHON:

  • The CopilotKit + Next.js scaffold for this project (governed-incident-agent repo)
  • All three useCopilotAction tools and their render callbacks
  • The two-column generative UI layout
  • The ControlFeedback instrument panel component
  • The Zustand event store and HHEM PENDING-to-PASS update pattern
  • The replay fallback mode for offline demo
  • The text-after-card suppression via marker-string handler returns
  • All three demo queries and their event sequences

The pre-existing Keystone repo is referenced but not copied into this project. This hackathon entry is its own codebase, built around the agentic interface + governance pattern.

AI Tinkerers CopilotKit OpenAI