pub struct InteractionRequest {
pub interaction_id: Uuid,
pub kind: InteractionKind,
pub context: Value,
pub urgency: Urgency,
pub metadata: HashMap<String, String>,
pub created_at: DateTime<Utc>,
pub goal_id: Option<Uuid>,
}Expand description
A request from TA to the human, delivered via a ReviewChannel.
Fields§
§interaction_id: UuidUnique identifier for this interaction (for correlation with response).
kind: InteractionKindWhat kind of interaction this is.
context: ValueStructured payload — contents depend on kind.
For DraftReview: { “draft_id”: “…”, “summary”: “…”, “artifact_count”: N }
For PlanNegotiation: { “phase”: “…”, “proposed_status”: “…” }
urgency: UrgencyHow urgent is this interaction?
metadata: HashMap<String, String>Arbitrary key-value pairs for channel-specific rendering hints. e.g., { “color”: “yellow”, “thread_id”: “…” }
created_at: DateTime<Utc>When the request was created.
goal_id: Option<Uuid>Optional goal ID for context.
Implementations§
Source§impl InteractionRequest
impl InteractionRequest
Sourcepub fn new(kind: InteractionKind, context: Value, urgency: Urgency) -> Self
pub fn new(kind: InteractionKind, context: Value, urgency: Urgency) -> Self
Create a new interaction request.
Sourcepub fn with_goal_id(self, goal_id: Uuid) -> Self
pub fn with_goal_id(self, goal_id: Uuid) -> Self
Set the goal ID for this interaction.
Sourcepub fn with_metadata(
self,
key: impl Into<String>,
value: impl Into<String>,
) -> Self
pub fn with_metadata( self, key: impl Into<String>, value: impl Into<String>, ) -> Self
Add a metadata key-value pair.
Sourcepub fn draft_review(
draft_id: Uuid,
summary: &str,
artifact_count: usize,
) -> Self
pub fn draft_review( draft_id: Uuid, summary: &str, artifact_count: usize, ) -> Self
Create a DraftReview interaction request.
Sourcepub fn plan_negotiation(phase: &str, proposed_status: &str) -> Self
pub fn plan_negotiation(phase: &str, proposed_status: &str) -> Self
Create a PlanNegotiation interaction request.
Sourcepub fn escalation(reason: &str, details: Value) -> Self
pub fn escalation(reason: &str, details: Value) -> Self
Create an Escalation interaction request.
Trait Implementations§
Source§impl Clone for InteractionRequest
impl Clone for InteractionRequest
Source§fn clone(&self) -> InteractionRequest
fn clone(&self) -> InteractionRequest
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for InteractionRequest
impl Debug for InteractionRequest
Source§impl<'de> Deserialize<'de> for InteractionRequest
impl<'de> Deserialize<'de> for InteractionRequest
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Source§impl Display for InteractionRequest
impl Display for InteractionRequest
Auto Trait Implementations§
impl Freeze for InteractionRequest
impl RefUnwindSafe for InteractionRequest
impl Send for InteractionRequest
impl Sync for InteractionRequest
impl Unpin for InteractionRequest
impl UnsafeUnpin for InteractionRequest
impl UnwindSafe for InteractionRequest
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> PolicyExt for Twhere
T: ?Sized,
impl<T> PolicyExt for Twhere
T: ?Sized,
Source§impl<T> ToStringFallible for Twhere
T: Display,
impl<T> ToStringFallible for Twhere
T: Display,
Source§fn try_to_string(&self) -> Result<String, TryReserveError>
fn try_to_string(&self) -> Result<String, TryReserveError>
ToString::to_string, but without panic on OOM.