Skip to main content

Crate graphrt_core

Crate graphrt_core 

Source
Expand description

§graphrt-core

A small, executor-agnostic runtime for agentic AI workflow graphs.

  • dsl: portable workflow documents (JSON / YAML).
  • graph: compiled, validated, immutable graphs.
  • node: the node contract, registry and host services.
  • engine: the scheduler that runs a graph and streams event::Events.
  • nodes: built-in control-flow and data nodes.
  • variables: the shared map of node outputs and pool namespaces.

The core has no dependency on any async runtime, HTTP client or model provider; those live in separate crates and plug in through node::Services and node::Registry.

Re-exports§

pub use dsl::Workflow;
pub use engine::Engine;
pub use engine::RunHandle;
pub use engine::RunInput;
pub use engine::RunStream;
pub use event::Event;
pub use event::Usage;
pub use graph::Graph;
pub use node::Node;
pub use node::NodeContext;
pub use node::NodeError;
pub use node::NodeOutcome;
pub use node::NodeOutput;
pub use node::NodeRole;
pub use node::Registry;
pub use node::Services;
pub use pool::Selector;
pub use pool::VariablePool;
pub use snapshot::Snapshot;
pub use value::Value;
pub use value::ValueType;
pub use variables::VarName;
pub use variables::Variables;
pub use indexmap;
pub use serde_json;

Modules§

catalog
Node catalog: machine-readable descriptions of node kinds.
child_env
The host environment given to child processes: the minimal one for processes that do not inherit the whole environment (plugin processes, stdio MCP servers), and the computer’s own environment, without what an AppImage launcher added, for every process graphrt starts.
condition
Condition evaluation shared by if-else, loop break conditions and list-operator filters.
coordination
Versioned key-value objects for coordinating writers that share one store.
doc_schema
JSON Schema (draft 2020-12) of a whole v1 workflow document.
dsl
Workflow documents: the portable, serializable description of a workflow.
engine
The execution engine.
event
Events emitted by a run.
file
File access contract.
graph
Compiled, validated, immutable graph.
node
The node contract.
nodes
Built-in nodes.
pool
Selectors and the variable pool.
private_fs
Owner-only files and directories for hosts that write run data to disk.
redact
Scrubbing plaintext secrets out of free text.
response
Ordered response streaming.
snapshot
Persistable run state for pause / resume.
source_map
Source positions of the values in a workflow document.
store
Durable run records for hosts that serve many runs (an HTTP server, a job queue).
task
One tokio task type for many spawn sites.
template
Variable templates: Hello {{#start.name#}}, you said {{#sys.query#}}.
tool
Tool contract shared by the tool node, the agent node and tool providers (native Rust tools, MCP servers, HTTP tools…).
tool_node
The generic tool node and NativeTools, a ToolRuntime built from Rust closures.
urls
Small, allocation-light helpers for operator-configured URLs: showing them without credentials, and comparing where they point.
validate
Whole-document validation that collects every finding.
value
Runtime values.
value_path
Where in a serde_json::Value a deserialization error happened, found after the fact from the error message.
variables
Variables: the small ordered map of named values a node produces and a pool namespace holds.
yaml
The one YAML entry point of graphrt: YAML text to a serde_json::Value.

Structs§

IndexMap
Ordered map used throughout the public API. A hash table where the iteration order of the key-value pairs is independent of the hash values of the keys.

Enums§

Error
Top-level error type.