Respect transcript logging for malformed tool-call warnings #837
All Vouch review confidence checks passed
Residual risk 0.07 = Change Risk (0.23) × (1 − Review Confidence (0.68)).
Review depth and reviewer attention state are adequate.
Model 1 · Change Risk (XGBoost)
Score: 0.23 · 20 lines diff across 2 files
Model 2 · Review Depth (DistilBERT)
Depth Score: 0.35 · 1 substantive comment(s)
Model 3 · Review Timing & Attention
Session adequacy: 100% · 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.182
Real PR Conversation Timeline
2 items
Approved
Good catch! Thank you!
<img src="https://static.klipy.com/ii/35ccce3d852f7995dd2da910f2abd795/c3/5f/yjEzVqYx.gif"/>
andimarafioti
gorkadabo1
What does this PR do?
Fixes #836. Malformed native tool-call JSON currently logs raw tool arguments at WARNING level, even when transcript logging is disabled. This can expose private information in application logs. This PR passes the existing 200-character prefix through
transcript_for_log(), preserving the WARNING level, malformed-JSON rejection, diagnostic length limit, and explicit opt-in visibility when transcript logging is enabled.It also adds one regression test covering disabled and enabled transcript logging, as well as malformed-JSON rejection.
Validation
git diff --check: passed.The patch applies cleanly to the related files at #806 head
1707d332, but full integration with that PR was not tested. I did not run the full test suite or validate on GPU, hosted providers, or end-to-end pipelines.