Attach guardian rollouts to feedback uploads

Add guardian review_thread_id plumbing so feedback can resolve the hidden guardian session rollout and attach it alongside the parent rollout in both app-server and local /feedback flows.

Co-authored-by: Codex <noreply@openai.com>
This commit is contained in:
Charles Cunningham
2026-03-18 12:28:55 -07:00
parent 42e932d7bf
commit 56b7efcb98
23 changed files with 597 additions and 103 deletions

View File

@@ -1,6 +1,7 @@
use std::collections::HashMap;
use std::path::PathBuf;
use crate::ThreadId;
use crate::mcp::RequestId;
use crate::models::MacOsSeatbeltProfileExtensions;
use crate::models::PermissionProfile;
@@ -122,6 +123,10 @@ pub struct GuardianAssessmentEvent {
/// Uses `#[serde(default)]` for backwards compatibility.
#[serde(default)]
pub turn_id: String,
/// Hidden guardian review thread that evaluated this request, when known.
#[serde(default, skip_serializing_if = "Option::is_none")]
#[ts(optional)]
pub review_thread_id: Option<ThreadId>,
pub status: GuardianAssessmentStatus,
/// Numeric risk score from 0-100. Omitted while the assessment is in progress.
#[serde(default, skip_serializing_if = "Option::is_none")]