Skip to main content

AgentPromptPacket

Struct AgentPromptPacket 

Source
pub struct AgentPromptPacket<T> {
    pub workflow_name: Name,
    pub goal: Purpose,
    pub event: Event,
    pub input: T,
    pub policies: Vec<PolicyInstruction>,
    pub output_schema_name: OutputSchemaName,
}
Expand description

Safe prompt-and-evidence packet exchanged with an automation agent.

An agent prompt packet bundles the workflow identity, triggering source event, typed app input, policy instructions, and expected output schema sent to an agent runner. It is a draft/evidence boundary: agents can use it to prepare a briefing, follow-up draft, classification, or manager-review packet, but the packet itself is not permission to mutate live resort systems.

Fields§

§workflow_name: Name

Workflow identifier that ties the packet to a specific agent spec.

Examples include manager-daily-brief, booking-triage, and grooming-rebooking; the name lets audits connect a packet back to the workflow contract that defined its allowed tools and forbidden actions.

§goal: Purpose

Business goal the agent should pursue while preparing only draft output.

This describes the labor, customer-service, safety, or data-quality outcome for the workflow, such as summarizing labor risk or drafting a customer follow-up, without granting authority to perform the action.

§event: Event

Source workflow event that caused the packet to be built.

The event provides audit correlation for the triggering reservation, intake, document, review, incident, or scheduled briefing path so a human reviewer can trace why this packet exists.

§input: T

Typed app-layer input facts available to the agent for this run.

The payload should contain the workflow-specific request or evidence the app has already promoted from source systems; it is context for drafting, not authorization to repair or overwrite those source records.

§policies: Vec<PolicyInstruction>

Policy instructions the runner must include in the agent context.

These instructions state review gates, safety limits, escalation rules, and source-grounding requirements that constrain generated drafts and make policy compliance reviewable after the run.

§output_schema_name: OutputSchemaName

Name of the output schema expected from the agent.

The schema name tells the runner and validator which structured draft, classification, briefing, or evidence bundle shape to expect before any downstream workflow code accepts the output.

Implementations§

Source§

impl<T> AgentPromptPacket<T>

Source

pub fn builder() -> AgentPromptPacketBuilder<T>

Create an instance of AgentPromptPacket using the builder syntax

Trait Implementations§

Source§

impl<T: Clone> Clone for AgentPromptPacket<T>

Source§

fn clone(&self) -> AgentPromptPacket<T>

Returns a duplicate of the value. Read more
1.0.0 · Source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
Source§

impl<T: Debug> Debug for AgentPromptPacket<T>

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
Source§

impl<'de, T> Deserialize<'de> for AgentPromptPacket<T>
where T: Deserialize<'de>,

Source§

fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>
where __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
Source§

impl<T: PartialEq> PartialEq for AgentPromptPacket<T>

Source§

fn eq(&self, other: &AgentPromptPacket<T>) -> bool

Tests for self and other values to be equal, and is used by ==.
1.0.0 · Source§

fn ne(&self, other: &Rhs) -> bool

Tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
Source§

impl<T> Serialize for AgentPromptPacket<T>
where T: Serialize,

Source§

fn serialize<__S>(&self, __serializer: __S) -> Result<__S::Ok, __S::Error>
where __S: Serializer,

Serialize this value into the given Serde serializer. Read more
Source§

impl<T: Eq> Eq for AgentPromptPacket<T>

Source§

impl<T> StructuralPartialEq for AgentPromptPacket<T>

Auto Trait Implementations§

§

impl<T> Freeze for AgentPromptPacket<T>
where T: Freeze,

§

impl<T> RefUnwindSafe for AgentPromptPacket<T>
where T: RefUnwindSafe,

§

impl<T> Send for AgentPromptPacket<T>
where T: Send,

§

impl<T> Sync for AgentPromptPacket<T>
where T: Sync,

§

impl<T> Unpin for AgentPromptPacket<T>
where T: Unpin,

§

impl<T> UnsafeUnpin for AgentPromptPacket<T>
where T: UnsafeUnpin,

§

impl<T> UnwindSafe for AgentPromptPacket<T>
where T: UnwindSafe,

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> CloneToUninit for T
where T: Clone,

Source§

unsafe fn clone_to_uninit(&self, dest: *mut u8)

🔬This is a nightly-only experimental API. (clone_to_uninit)
Performs copy-assignment from self to dest. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T> ToOwned for T
where T: Clone,

Source§

type Owned = T

The resulting type after obtaining ownership.
Source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
Source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.
Source§

impl<T> DeserializeOwned for T
where T: for<'de> Deserialize<'de>,