A Manifest V3 Chrome DevTools extension for capturing, decoding, and debugging AG-UI 1.0 protocol streams in real time.
Instead of squinting at raw text/event-stream chunks in Chrome's Network tab, AG-UI Inspector reconstructs agent runs into a collapsible execution tree, lets you scrub through state patches step by step, and exports real agent traffic into deterministic Playwright and MSW test mocks.
Zero-Config Stream Capture: Passively intercepts HTTP + Server-Sent Events (SSE) andEventSource traffic via Chrome DevTools Protocol (chrome.debugger ), including nested iframes—no SDK changes required. #
Flat & Execution Tree Views: Switch between a chronological wire log and a nested execution tree (RUN_STARTED →STEP_STARTED →TOOL_CALL_* →TEXT_MESSAGE_* ) with roll-up span durations and automatic token-chunk collapsing. #
State Time-Travel: Reconstructs agent state at any event in the timeline by starting fromSTATE_SNAPSHOT and immutably replaying RFC 6902STATE_DELTA JSON Patches. #
1-Click Test Codegen: Export any captured run directly into a copy-pasteablePlaywright page.route() mock orMSW ( http.post) streaming handler. #
Protocol Diagnostics: Validates AG-UI 1.0 lifecycle rules, flags truncated streams or malformed frames, and inspects redactedRunAgentInput payloads. #
Built-In Redaction: Automatically scrubs sensitive headers, query parameters, and secret/token/password keys before storing or exporting traces. #
1-Click Sample Run: Includes a built-in sample agent run so you can test the timeline, state time-travel, and mock generators without a live backend.
You can load the prebuilt extension directly into Chrome or Edge in ~30 seconds:
Download the latest ag-ui-inspector-v*.zip from theReleases page.
2.
Unzip the archive to a local folder (verify manifest.json is directly inside the extracted folder).
3.
Open chrome://extensions in your browser.
4.
Toggle Developer mode ON in the top-right corner.
5.
Click Load unpacked and select the extracted folder.
Open any application running AG-UI (or test immediately on the AG-UI Dojo ).
2.
Open Chrome DevTools ( F12 orCmd+Option+I /Ctrl+Shift+I ) and select theAG-UI panel tab.
3.
Click Attach to begin capturing live streams (or clickLoad Sample Run from the empty state to explore offline).
4.
Use the Flat | Tree toggle andCollapse chunks checkbox to inspect tool calls, scrubSTATE_DELTA patches in theState tab, or clickCopy as Playwright Mock /Copy as MSW Handler .
Node.js 20+ #
npm
npm install
npm test
npm run typecheck
npm run build
After running npm run build, load the generated dist/ directory via chrome://extensions → Load unpacked.
Inspected Tab
└─▶ chrome.debugger (CDP Network events)
└─▶ CdpCapture (src/background/cdp-capture.ts)
└─▶ SseStreamDecoder (src/lib/sse.ts)
└─▶ InspectorStore (src/background/store.ts)
└─▶ chrome.runtime.Port (throttled deltas)
└─▶ React DevTools Panel (src/panel/)
| Path | Responsibility |
|---|---|
src/assets/manifest.json |
Manifest V3 configuration and permissions ( debugger ,storage ) |
src/devtools/ |
Registers the AG-UI tab inside Chrome DevTools |
src/background/sw.ts |
MV3 service worker managing panel ports and throttled state updates |
src/background/cdp-capture.ts |
CDP network attachment, iframe auto-attach, and stream chunk decoding |
src/background/store.ts |
Run grouping ( runId ), truncation detection, andchrome.storage.session persistence |
src/lib/sse.ts |
Incremental SSE frame parser |
src/lib/agui.ts |
AG-UI 1.0 event family mapping and structural diagnostics |
src/lib/eventTree.ts |
Hierarchical event tree projection and roll-up duration calculator |
src/lib/codegen.ts |
Playwright and MSW mock generator |
src/shared/redaction.ts |
Header, query string, and secret key redaction |
src/panel/ |
React UI, virtualized event list, and RFC 6902 state inspector |
WebSocket and custom transport decoding #
Protobuf wire format support #
Full AG-UI JSON Schema validation #
IndexedDB retention for cross-session trace history
All captured traffic stays strictly local within your browser's memory and chrome.storage.session. Sensitive authorization headers, tokens, and secret-matching keys are redacted before storage or export.
MIT