ZZust

Design

A controllable runtime layer for AI-written code

Zust keeps the parts of Rust that give generated code structure, then removes the friction that makes scripts hard to generate, review, and hot-swap.

Zust Mandelbrot rendering

Easier for AI to get right

Generated code needs a shape that humans and tools can inspect. Zust keeps blocks, functions, structs, impls, generics, and modules while making mutation and dynamic values straightforward.

pub fn agent_task(ctx) {
    let plan = ctx.goal;
    let tools = root::get("local/tools");

    for step in plan.steps {
        let result = tools[step.tool](step.input);
        ctx.memory.push(result);
    }

    ctx.memory
}

Dynamic at the boundary

`Dynamic` is the shared value model for host systems, JSON, MessagePack, tool results, maps, lists, bytes, and typed vectors. Scripts can start flexible and become typed where performance or ABI clarity matters.

From scripts to native functions

The VM imports Zust source, compiles it, and exposes function pointers to the Rust host. A generated workflow can be reviewed, hot-swapped, and then moved into the execution path.