fix: support retrieval of stored Responses payloads #354
All Vouch review confidence checks passed
Residual risk 0.28 = Change Risk (0.65) × (1 − Review Confidence (0.57)).
Review depth and reviewer attention state are adequate.
Model 1 · Change Risk (XGBoost)
Score: 0.65 · 230 lines diff across 2 files
Model 2 · Review Depth (DistilBERT)
Depth Score: 0.17 · 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.326
Shallow Review Depth
shallow_review_depth
0.289
Sensitive Paths
sensitive_paths
0.065
Ai Authored
ai_authored
0.050
Real PR Conversation Timeline
1 comments
"Review active on #354"
general
weight: 0.35
franciscojavierarceo
Summary
A response created with
store: truecould be continued throughprevious_response_id, but retrieving it withGET /v1/responses/{response_id}returned 404. Add an authenticated retrieval route backed by a typed terminal response snapshot, persisted atomically with the response history. Retrieval preserves this turn's output, status, usage, and IDs without calling the upstream model.Keep snapshots out of continuation checkpoints and strip request-scoped MCP credentials before persistence. Unknown IDs return a JSON 404; legacy and history-only records return 409 because they lack the original response payload. Document the behavior and expose the endpoint in OpenAPI.
When OIDC is disabled and
OPENAI_API_KEYis nonempty, retrieval validates the supplied bearer token locally before reading storage. Missing or invalid credentials return 401; OIDC authentication takes precedence when enabled. Deployments without either authentication option retain unauthenticated access.Test Plan
cargo clippy --workspace --all-targets -- -D warningsand all pre-commit hooks.