Skip to main content

Item

Enum Item 

Source
pub enum Item {
Show 54 variants Start { session: Option<String>, }, Session { session: String, }, Text { text: String, parent: Option<String>, id: Option<String>, }, Thinking { text: String, parent: Option<String>, id: Option<String>, }, Delta { id: String, text: String, thinking: bool, parent: Option<String>, }, Subagent { call: String, model: String, }, Tool { id: String, name: String, input: Value, parent: Option<String>, unplanned: bool, }, ToolInput { id: String, name: Option<String>, input: Value, }, ToolDone { id: String, output: String, error: bool, result: Value, }, Touched { path: String, }, Permission { request: String, call: String, tool: Option<String>, input: Option<Value>, description: Option<String>, reason: Option<String>, diff: Option<Diff>, can_always: bool, parent: Option<String>, hunks: Option<Value>, always_by_harness: bool, ends_stream: bool, }, Question { request: String, call: String, questions: Value, parent: Option<String>, }, Answered { request: String, decision: Option<String>, answers: Option<Value>, }, User { id: String, text: String, }, Model { model: String, }, Context { tokens: Option<u64>, window: Option<u64>, }, Todos { todos: Value, }, Mode { mode: String, }, Turn { interrupted: bool, limited: Option<Option<i64>>, usage: TurnUsage, error: Option<String>, entry: Option<String>, }, Notice { text: String, level: String, }, Write { line: String, }, PermissionCard { request: String, call: String, tool: String, input: Value, description: Option<String>, reason: Option<String>, hunks: Value, can_always: bool, always_scope: Option<String>, parent: Option<String>, }, QuestionCard { request: String, call: String, questions: Value, form: Value, parent: Option<String>, }, Quota { meters: Value, }, Usage { usage: Value, }, LimitRest, Ready { models: Value, }, Compacted { error: Option<String>, }, Stop { reason: String, }, Entry { entry: Option<String>, }, Activity { tool: Option<String>, input: Value, block: Option<String>, }, Took { ms: i64, }, Relaunch { launch: Box<Launch>, }, Pause, File { path: String, text: String, }, Closed, Conversation { session: String, notice: String, }, Message { id: String, model: String, usage: Value, main: bool, }, MessageOutput { id: String, output: u64, }, Tasks { frame: Value, }, Event { id: Option<String>, source: String, text: String, from: Option<String>, }, Output { id: Option<String>, level: String, text: String, }, Call { id: String, name: String, input: Value, parent: Option<String>, }, ToolResult { id: String, output: String, error: bool, result: Value, }, Replayed { id: Option<String>, text: String, origin: Option<String>, from: Option<String>, synthetic: bool, images: u32, files: Vec<String>, }, Ask { request: String, call: String, tool: String, input: Value, title: Option<String>, description: Option<String>, reason: Option<String>, suggestions: Value, no_always: bool, default_no: bool, task: Option<String>, }, Result {
Show 13 fields id: Option<String>, failed: bool, error: Option<String>, failure: String, reply: String, limited: bool, resets: Option<i64>, sign_in: bool, duration: Value, window: Option<u64>, cost: f64, tokens: u64, models: Vec<ModelTurn>,
}, Limit { scoped: bool, }, Overage { on: bool, }, Remote { state: Option<String>, }, Told { commands: Value, models: Value, }, Answer { ask: String, answer: Value, error: Option<String>, }, Said { line: String, }, Unknown,
}
Expand description

A normalized item or an effect, which the core applies to the agent: the same as the conversation’s (user, text, thinking, tool, question, permission, turn, notice) and the effects (Effects of agent.rs).

Variants§

§

Start

A turn begins, in the session session (the agent’s from now on).

Fields

§session: Option<String>
§

Session

The agent’s session, opened (new, resumed or copied) before any turn: the agent’s from now on, its status left as it is (INT-10.6: a copy of Mistral Vibe’s has its own session as soon as its process starts).

Fields

§session: String
§

Text

Its text; a subagent’s under parent. With id, the whole of the text streamed under that id (Delta).

Fields

§text: String
§parent: Option<String>
§

Thinking

Fields

§text: String
§parent: Option<String>
§

Delta

A piece of a text (or a reasoning) as it is written, under id: the first one makes its item, the others add to it; Text (Thinking) of the same id ends it.

Fields

§text: String
§thinking: bool
§parent: Option<String>
§

Subagent

The model a subagent runs on, under its call.

Fields

§call: String
§model: String
§

Tool

A tool called, named as Escouade names them (Claude Code’s names: Bash, Edit, Task…).

Fields

§name: String
§input: Value
§parent: Option<String>
§unplanned: bool

Not a row of the plan: its task list comes by Todos.

§

ToolInput

What is known later of a call: its input (an edit’s file), or the name it turns out to have (Write for a file added).

Fields

§input: Value
§

ToolDone

Its result; result the structured one Claude Code gives ({ filePath, structuredPatch } of an edit, { stdout, stderr } of a command), which shows its diff.

Fields

§output: String
§error: bool
§result: Value
§

Touched

A file it changed (the effect files_changed).

Fields

§path: String
§

Permission

The approval of the call call, asked as the request request: the call’s tool and input unless tool says another (ExitPlanMode and its plan), what the card says of it (description, reason), the write it would make (diff, shown on the card), and whether « Pour cet agent » is offered.

Fields

§request: String
§call: String
§input: Option<Value>
§description: Option<String>
§reason: Option<String>
§diff: Option<Diff>
§can_always: bool
§parent: Option<String>

The call of the subagent that asks it.

§hunks: Option<Value>

The hunks of a patch the harness gave as they are, in place of diff (hunks_of).

§always_by_harness: bool

« Always » is the harness’s, for its session: not worded as « Pour cet agent ».

§ends_stream: bool

The turn stays open on this card, what was streaming closed (a plan to approve at the end of a turn).

§

Question

Questions to the user (each {question, header, multiSelect, options: [{label, description}]}).

Fields

§request: String
§call: String
§questions: Value
§parent: Option<String>

The call of the subagent that asks them.

§

Answered

A request answered in the harness’s own interface: its card says so and goes. decision of a permission (allow, always, deny), answers of questions (for each in its order, the labels chosen), else cancelled.

Fields

§request: String
§decision: Option<String>
§answers: Option<Value>
§

User

The user’s message typed in the harness’s own interface: shown as they typed it.

Fields

§text: String
§

Model

The model the harness took in place of the agent’s (one its account does not offer).

Fields

§model: String
§

Context

What the agent’s context holds (tokens), and the window of its model.

Fields

§tokens: Option<u64>
§window: Option<u64>
§

Todos

The task list of the agent, as Claude Code’s TodoWrite gives it ([{ content, status, activeForm }]), for its plan.

Fields

§todos: Value
§

Mode

The harness changed its mode by itself (out of its mode Plan): Escouade’s mode it is in now.

Fields

§mode: String
§

Turn

The turn is over.

Fields

§interrupted: bool
§limited: Option<Option<i64>>

Stopped by the usage limit, which resets then (ms), if told: null for a limit whose reset is not told, left out for none.

§error: Option<String>

It ended in error, and why (a model refused, a key refused).

§entry: Option<String>

The last entry of its session: where a copy forks it.

§

Notice

A line of the conversation from Escouade or the harness, not the model (info, warning, error).

Fields

§text: String
§level: String
§

Write

A line for the harness’s input, written by the core in the order of the items.

Fields

§line: String
§

PermissionCard

The approval of a call, its card written whole: the tool asked, what it says of it, the hunks of the write it would make (Claude Code’s structuredPatch), how far « Toujours » goes (alwaysScope, left out for a plan).

Fields

§request: String
§call: String
§tool: String
§input: Value
§description: Option<String>
§reason: Option<String>
§hunks: Value
§can_always: bool
§always_scope: Option<String>
§parent: Option<String>
§

QuestionCard

Questions asked by a subagent (parent), or a form (form: what it is for, { message, source }).

Fields

§request: String
§call: String
§questions: Value
§form: Value
§parent: Option<String>
§

Quota

The account’s quota as a call told it: its meters (usage::parse_windows’s).

Fields

§meters: Value
§

Usage

What agent/readUsage asked of the harness (UsageAsked), as Usage::usage.

Fields

§usage: Value
§

LimitRest

The turn ending next stopped at a limit it waits for: told in its turn, the agent at rest and not in error.

§

Ready

A harness that declares opens: its session is open and its first message may go; models are the account’s (ToldModels), for the menu.

Fields

§models: Value
§

Compacted

The end of what agent/compact asked, and why it failed.

Fields

§

Stop

The harness is of no use: the core stops it, and reason is what its end says (its protocol, no sign-in).

Fields

§reason: String
§

Entry

The last entry of its session a copy may start after, when no Turn tells it (a plan to approve).

Fields

§

Activity

What the agent is doing, shown on its row, when the item that follows does not tell it: a command that only reads a file is a Read (tool, input), a reasoning begun says so before it has a word (block: thinking).

Fields

§input: Value
§

Took

How long the turn that ends took, as its harness counted it (ms), told just before its Turn; left out, the core counts it.

Fields

§ms: i64
§

Relaunch

A harness that relaunches: its program stopped, and another started from this description, checked as the first one was; the lines written after it go to the new one.

Fields

§launch: Box<Launch>
§

Pause

A harness that relaunches: its program stopped, the agent kept; Relaunch starts the next one.

§

File

A file written now, in the agent’s own folder alone, checked as those of a launch: rules read while it runs.

Fields

§path: String
§text: String
§

Closed

Asked to stop gently (method::CLOSE), its turn is over: the agent has left its shared process.

§

Conversation

The conversation it runs (a harness that says so at each start): another than the agent’s starts anew, its plan forgotten; notice is what the agent’s conversation says when that happens to a process that had one.

Fields

§session: String
§notice: String
§

Message

A message of the model begins, under id: what it reads (usage, as the API tells it) counts in the running turn until Item::Result; main: of the agent itself, not of a subagent.

Fields

§model: String
§usage: Value
§main: bool
§

MessageOutput

What the message id wrote so far, in tokens.

Fields

§output: u64
§

Tasks

What the harness says of its background tasks, for the plan (task_started, task_progress…).

Fields

§frame: Value
§

Event

A line of the conversation that comes from neither the user nor the model (a task that ended, a message of another agent): source says which.

Fields

§source: String
§text: String
§

Output

What a local command printed (output, error).

Fields

§level: String
§text: String
§

Call

The whole call of a tool, once its message is whole: Tool began it if it was streamed, its row is then told its input; the plan hears of it either way.

Fields

§name: String
§input: Value
§parent: Option<String>
§

ToolResult

Its result, whatever the row says by now (ToolDone leaves a row that ended as it is).

Fields

§output: String
§error: bool
§result: Value
§

Replayed

A user’s message the harness says back: the echo of one sent by the core, or one sent another way. origin is who it comes from when no person wrote it (task-notification, peer…), from the agent that sent it.

Fields

§text: String
§origin: Option<String>
§synthetic: bool
§images: u32
§files: Vec<String>
§

Ask

The harness asks leave for a call, or asks the user (tool AskUserQuestion): suggestions are the rules « Toujours » would keep, given back in AnswerPermission::rules; task the subagent that asks. The core answers by itself a read of a file the user joined.

Fields

§request: String
§call: String
§tool: String
§input: Value
§description: Option<String>
§reason: Option<String>
§suggestions: Value
§no_always: bool
§default_no: bool
§

Result

The end of a turn the harness counts itself: what each model cost, the context window of the one that ran, whether it failed and why. limited: stopped by the usage limit, which resets at resets (ms) if told; sign_in: by a sign-in of its account that could not be refreshed; failure is what a failure says, reply what a good end says when the model wrote nothing.

Fields

§failed: bool
§failure: String
§reply: String
§limited: bool
§resets: Option<i64>
§sign_in: bool
§duration: Value
§window: Option<u64>
§cost: f64
§tokens: u64
§models: Vec<ModelTurn>
§

Limit

A usage limit was met: scoped to the model it runs on, not to its account.

Fields

§scoped: bool
§

Overage

Whether its account answers as extra usage.

Fields

§on: bool
§

Remote

The state of its link to its vendor’s site (ready, connected…).

Fields

§

Told

What its harness said when it started: its commands and its models (as it tells them), which Ready follows.

Fields

§commands: Value
§models: Value
§

Answer

What the harness said of the call ask (Asked): its answer, or why it refused.

Fields

§answer: Value
§

Said

What the harness wrote that is none of its protocol, kept for what its end says.

Fields

§line: String
§

Unknown

An item of a later version of the contract: left aside.

Trait Implementations§

Source§

impl Clone for Item

Source§

fn clone(&self) -> Self

Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§

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

Performs copy-assignment from source. Read more
Source§

impl Debug for Item

Source§

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

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

impl<'de> Deserialize<'de> for Item

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 PartialEq for Item

Source§

fn eq(&self, other: &Self) -> bool

Equality operator ==. Read more
1.0.0 (const: unstable) · Source§

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

Inequality operator !=. Read more
Source§

impl Serialize for Item

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 StructuralPartialEq for Item

Auto Trait Implementations§

§

impl Freeze for Item

§

impl RefUnwindSafe for Item

§

impl Send for Item

§

impl Sync for Item

§

impl Unpin for Item

§

impl UnsafeUnpin for Item

§

impl UnwindSafe for Item

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> DeserializeOwned for T
where T: for<'de> Deserialize<'de>,

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 = !

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

fn try_from(value: U) -> Result<T, !>

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.