Expand description
Runlet’s executable semantic model.
The runtime keeps deterministic values and ordered results while allowing
bounded loop subgraphs to execute concurrently. Durable journals and remote
production executors remain later phases described in DESIGN.md.
§Quick start
use runlet::{CanonicalValue, Runtime};
let runtime = Runtime::builder().with_prelude().build()?;
let program = runtime.compile(r#"return text.upper("runlet")"#)
.expect("valid Runlet source");
let execution = runtime.run(&program)?;
assert_eq!(execution.value, CanonicalValue::from("RUNLET"));Structs§
- Block
- Lexically scoped sequence of statements ending in a result expression.
- Call
Schema - Ordered parameter schema for a tool call.
- Compiled
Program - A parsed and schema-checked program ready for execution.
- Diagnostic
- Structured parse, analysis, planning, or execution feedback.
- Edge
- Directed relationship in an execution graph.
- Execution
- Final value and execution graph from a successful run.
- Expr
- Source expression and its location.
- External
Input - A named value supplied by the host and available to a Runlet program.
- Fix
- A source edit that may resolve a diagnostic.
- Graph
- Snapshot of nodes and edges produced by one execution.
- Graph
Event - An ordered, incremental change to a running execution graph.
- Healed
- Source produced by a successful mechanical repair pass.
- Node
- A unit of work or value in an execution graph.
- Program
- Parsed Runlet compilation unit.
- Property
- Schema and host metadata for an object property.
- Runtime
- Immutable compiler and in-process executor configured by
RuntimeBuilder. - Runtime
Builder - Builder for a
Runtimeand its complete host capability surface. - Span
- Half-open byte range in the original UTF-8 source.
- Stmt
- Source statement and its location.
- Tool
Context - Metadata supplied to a host tool handler for one dispatch attempt.
- Tool
Descriptor - Host-facing declaration of a callable tool.
- Tool
Error - Structured failure returned by a tool handler or the runtime.
- Tool
Registry - Deterministically ordered collection of tool descriptors.
Enums§
- Binary
Op - Infix binary operator.
- Canonical
Value - Deterministic runtime value representation used throughout Runlet.
- Edge
Kind - Relationship between two execution graph nodes.
- Execution
Policy - Effect and retry semantics declared by a host tool.
- Expr
Kind - Kind-specific expression data.
- Graph
Change - Mutation emitted while an execution graph is built.
- Node
Kind - Semantic role of a node in an execution graph.
- Node
State - Lifecycle state of an execution graph node.
- Object
Key - An object-literal property key: written literally (
name:/"name":) or computed at runtime ([expr]:). Computed keys evaluate to a string; scalar values (integers, numbers, booleans) convert to their canonical text form. When keys collide, the last entry wins. - Phase
- Pipeline phase that produced a diagnostic.
- Schema
- Runtime value schema used to validate inputs and analyze programs.
- Severity
- Diagnostic importance.
- Stmt
Kind - Kind-specific statement data.
- UnaryOp
- Prefix unary operator.
- Value
Error - Failure while constructing or serializing a canonical value.
Constants§
- LANGUAGE_
VERSION - Language semantic version implemented by this crate.
- VALUE_
ENCODING_ VERSION - Canonical value encoding version implemented by this crate.