Skip to main content

Syscall

Enum Syscall 

Source
pub enum Syscall {
    Invoke(ToolCall),
    Spawn(IsolationManifest),
    PageIn(PageInRequest),
    WriteMemory(MemoryWriteRequest),
    QueryMemory(MemoryQuery),
    SubmitNodes {
        count: usize,
    },
    LoadWorkflow {
        node_count: usize,
    },
}
Expand description

An effectful request from the SDK that the kernel must adjudicate.

Every side-effecting service request becomes a Syscall variant; the opcode is data, so adding a service does not add a new ABI shape (unlike the per-feature Load*Policy events today).

Variants§

§

Invoke(ToolCall)

Model-proposed tool call (today: the only thing through the governance gate).

§

Spawn(IsolationManifest)

Spawn a sub-agent (today: bypasses the gate).

§

PageIn(PageInRequest)

Page long-term memory into working context (today: bypasses the gate).

§

WriteMemory(MemoryWriteRequest)

Persist a long-term memory entry.

§

QueryMemory(MemoryQuery)

Retrieve long-term memory entries.

§

SubmitNodes

R3-1: append count nodes to the in-flight workflow DAG at runtime. Gating DAG growth through the trap lets a ResourceQuota backstop a runaway loop-until-done (denied past max_workflow_nodes); per-node spawns are still gated separately by Spawn.

Fields

§count: usize
§

LoadWorkflow

M5/G1: an agent authors a whole workflow spec (node_count nodes). Bootstraps the DAG when none is active, else flattens onto it — either way it is gated by the same max_workflow_nodes quota as SubmitNodes (a spec is just a node batch with a bootstrap fast-path), so an agent-authored harness cannot overgrow the DAG past the run’s budget.

Fields

§node_count: usize

Implementations§

Source§

impl Syscall

Source

pub fn opcode(&self) -> &'static str

Stable opcode label for audit/event-log categorization.

Trait Implementations§

Source§

impl Clone for Syscall

Source§

fn clone(&self) -> Syscall

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 Syscall

Source§

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

Formats the value using the given formatter. Read more

Auto Trait Implementations§

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.