A MANAGED Python REPL: a persistent interpreter subprocess running a tiny
line-framed eval server — one JSON request per line in, one JSON response per
line out. Globals persist across evals (real REPL state). One process per dir;
the Process handle is cached so teardown is clean.
A MANAGED Python REPL: a persistent interpreter subprocess running a tiny line-framed eval server — one JSON request per line in, one JSON response per line out. Globals persist across evals (real REPL state). One process per dir; the `Process` handle is cached so teardown is clean.
(eval! dir code timeout-ms)Evaluate code in the REPL for dir. Returns
{"ok" "out" "err" "value" "data" "type" "exc"} — value is the
last expression's repr, data its JSON-safe STRUCTURED view (dicts/lists/
dataclasses/numpy/pandas/objects, so the model can read real fields), type
the class name.
Evaluate `code` in the REPL for `dir`. Returns
{"ok" "out" "err" "value" "data" "type" "exc"} — `value` is the
last expression's repr, `data` its JSON-safe STRUCTURED view (dicts/lists/
dataclasses/numpy/pandas/objects, so the model can read real fields), `type`
the class name.(start! dir _opts)Spawn (or replace) the managed Python REPL for dir. Returns a STRING-keyed
status map (crosses the strings-only boundary as a tool :result).
Spawn (or replace) the managed Python REPL for `dir`. Returns a STRING-keyed status map (crosses the strings-only boundary as a tool `:result`).
(status dir)STRING-keyed lifecycle view (crosses as a tool :result).
STRING-keyed lifecycle view (crosses as a tool `:result`).
cljdoc builds & hosts documentation for Clojure/Script libraries
| Ctrl+k | Jump to recent docs |
| ← | Move to previous article |
| → | Move to next article |
| Ctrl+/ | Jump to the search field |