fix: record VS Code Copilot tool output and slim the raw audit event #48
All Vouch review confidence checks passed
Residual risk 0.30 = Change Risk (0.48) × (1 − Review Confidence (0.38)).
Review depth and reviewer attention state are adequate.
Model 1 · Change Risk (XGBoost)
Score: 0.48 · 356 lines diff across 4 files
Model 2 · Review Depth (DistilBERT)
Depth Score: 0.02 · 1 substantive comment(s)
Model 3 · Review Timing & Attention
Session adequacy: 64% · Reviewer familiarity: 35%
Bedrock Claude 3 · Risk Narration
(disconnected)
Groq Risk Narration
AWS Bedrock is currently disconnected. Generate high-confidence PR triage narration on-demand using Groq.
Model 1 · Change Risk Attribution
SHAP Weights
Diff Size
diff_size
0.352
Shallow Review Depth
shallow_review_depth
0.344
Ai Authored
ai_authored
0.050
Real PR Conversation Timeline
1 comments
"Review active on #48"
general
weight: 0.35
claude[bot]
Problem
Two problems in the local-agent audit hook, found while investigating obot-platform/obot#8420:
tool_result: {result_type, text_result_for_llm}and sends notool_response. The parser only readtool_response, so these events were submitted withresponse.body: null. The output survived only insiderawEvent.tool_inputand the tool output in their own fields, and then again insiderawEvent, which is the hook's whole stdin. For Claude Code those two values are about 88% of the payload.Change
tool_resultas the output whentool_responseis absent or null.tool_inputand the output key the entry was built from with a marker, for example"tool_response": {"obot_sentry_omitted": "details.response.body"}. Every other field is kept as the agent sent it.Compatibility
rawEventto be non-empty JSON.Reviewer notes
tool_resultobject rather than justtext_result_for_llm. That keeps the extraction lossless, at the cost of the body being an object where the Local harness gives a string. Say if you'd prefer the text alone.Testing
go test ./...andgo vet ./...pass.golangci-lintwas not run locally.audit submit --dry-run --print-normalizedbefore and after: all six Copilot post-tool events now have a non-null response body, and the submitted size for an 11-event Claude Code session drops from about 140 KB to 84 KB.Addresses obot-platform/obot#8420
🤖 Generated with Claude Code