Skip to content

feat: streaming chat and after-seal check for the Inspector - #20

Merged
lmarkmann merged 3 commits into
mainfrom
feat/inspector-api
Oct 17, 2026
Merged

lmarkmann merged 3 commits into
mainfrom
feat/inspector-api

Conversation

@lmarkmann

Copy link
Copy Markdown
Owner

The API side of the Inspector panel.

  • POST /chat streams answers over the AI SDK UI Message Stream protocol v1: tool steps (getOrder, watchPack, searchArchive) as tool-* parts, cited moments as data-evidence parts, the answer as text deltas from W&B Inference, and the Weave trace URL in the finish metadata. Errors reach the client as a generic message; details stay in the log.
  • /ask and the streaming route share one agent loop (converse, the traced Weave op).
  • After a seal, the agent compares the clip with the order and stores a verdict in proofbox.checks; GET /packs/{id}/check serves it and answers 404 until it exists.
  • Tool errors sent to the model are our own messages, so raw httpx errors with VM or GPU addresses no longer reach it.
  • kill -USR1 <pid> dumps every thread's stack to the log. The inspector test instance froze once without a reproducible cause, and ptrace is locked on the VM.

Tested with 25 api tests (fake W&B server streaming split text and tool-call chunks), and live on a separate instance on the VM: full streams, three concurrent chats, and clients disconnecting mid-answer.

Known: searchArchive searches the shared VSS collection, so it can cite other teams' clips with no pack id.

@lmarkmann
lmarkmann merged commit f52ff54 into main Oct 17, 2026
2 checks passed
@lmarkmann
lmarkmann deleted the feat/inspector-api branch October 17, 2026 14:42
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant