Skip to main content

Module executor

Module executor 

Source
Expand description

Sandbox executor — creates fresh V8 isolates and runs LLM-generated code.

Each execution gets a brand new runtime. No state leaks between calls.

V8 isolates are !Send, so all JsRuntime operations run on a dedicated thread with its own single-threaded tokio runtime. The public API is fully async and Send-safe.

Structs§

SandboxConfig
Configuration for the sandbox executor.
SandboxExecutor
The sandbox executor. Creates fresh V8 isolates for each execution.

Enums§

ExecutionMode
How the sandbox executes code.

Functions§

run_execute
Run an execute operation on the current thread.
run_execute_with_known_servers
Run an execute operation with an optional set of known server names for SR-R6 validation and known tools for structured error fuzzy matching.
run_search
Run a search operation on the current thread (must be called from a dedicated thread, not the main tokio runtime).