Skip to main content

Module stdlib

Module stdlib 

Source
Expand description

Standard library builtins for the Harn VM.

Each category of builtins lives in its own sub-module.

Modules§

process

Functions§

register_agent_stdlib
Register agent builtins: concurrency, tools, agents, HTTP, LLM, MCP. Requires network access and async runtime.
register_core_stdlib
Register core builtins: types, math, strings, json, datetime, regex, crypto, sets, shapes, testing. These are pure/deterministic and require no I/O.
register_io_stdlib
Register I/O builtins: filesystem, process, logging, tracing, I/O. Requires OS access (file reads, process spawning, environment vars).
register_vm_stdlib
Register all standard builtins on a VM (core + io + agent).
reset_stdlib_state
Reset thread-local stdlib state (logging, tracing, source dir). Call between test runs.