Skip to main content

Module ctx_execute

Module ctx_execute 

Source

Functionsยง

handle
Executes a code snippet in a sandboxed environment. Returns the formatted output plus the structured outcome so the MCP layer can set isError/structuredContent on failures (GitHub #389).
handle_batch
Executes multiple (language, code) pairs in parallel and returns aggregated results. The outcome carries the first non-zero exit code (0 when all tasks succeeded), so one failing task marks the whole batch as failed.
handle_file
Reads a file from disk, detects its language, and executes a processing script.