feat: inspect raw LLM request/response payloads in session events - #14
Merged
Conversation
Store and stream the raw JSON sent to the provider (model_request) and the raw SSE chunks returned (model_response) alongside the existing parsed fields, so you can debug exact LLM inputs/outputs. - provider.py: assemble_response now returns raw_request and raw_response - agent_loop.py: model_request event includes raw_payload; model_response event includes raw_response - EventTimeline.tsx: collapsible "Raw request payload" and "Raw response (N chunks)" sections for model_request/model_response events - tests: 4 new tests covering raw payload shape, tool_choice, params, and raw response chunks Co-Authored-By: Flash <flash@hermes>
vivganes
force-pushed
the
feat/raw-llm-io
branch
from
June 28, 2026 04:53
a5b1266 to
3424650
Compare
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 free
to 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
Stores and streams the raw JSON sent to the LLM provider and the raw SSE chunks returned, alongside the existing parsed fields in session events. This enables debugging exact LLM inputs/outputs without needing to intercept network traffic.
Changes
Backend
provider.py—assemble_response()now returnsraw_request(full JSON payload sent to provider) andraw_response(list of raw SSE JSON chunks)agent_loop.py—model_requestevent includesraw_payload;model_responseevent includesraw_responseFrontend
EventTimeline.tsx— Collapsible "Raw request payload" section onmodel_requestevents, and "Raw response (N chunks)" section onmodel_responseeventsTests
Test Plan
ruff checkpasses clean🤖 Generated with Hermes Agent