Skip to main content

Crate metalcraft_flows

Crate metalcraft_flows 

Source
Expand description

§metalcraft-flows

Reference types and helpers for the Flow specification — a serializable, human-authored DAG format for AI agent workflows.

See SPEC.md for the formal wire-format specification.

§Modules

  • model — core types: FlowDefinition, FlowNode, FlowEdge, SavedFlow, FlowNodeType, CoreNodeType.
  • nodes — typed views over each node type’s data payload.
  • requires — declared integration-pack / tool dependencies and their validation and satisfaction checks.
  • walk — graph traversal: BFS reachability and handle-aware stepping.
  • eval — deterministic predicate evaluation for conditional nodes.
  • template{{path}} interpolation for string fields.
  • state — the running variables bag and dotted-path helpers.
  • validate — spec conformance checks.
  • store — directory-backed CRUD (enabled by the default fs feature).
  • log — flow execution log entries (enabled by the log feature).

Re-exports§

pub use eval::evaluate;
pub use eval::Operator;
pub use model::CoreNodeType;
pub use model::FlowDefinition;
pub use model::FlowEdge;
pub use model::FlowNode;
pub use model::FlowNodeType;
pub use model::FlowScheduleSpec;
pub use model::FlowSummary;
pub use model::SavedFlow;
pub use model::ScheduleTrigger;
pub use model::SPEC_VERSION;
pub use model::SUPPORTED_SPEC_VERSIONS;
pub use nodes::BRANCH_ERROR_HANDLE;
pub use requires::check_requirements;
pub use requires::check_tools;
pub use requires::derive_requires;
pub use requires::AvailablePack;
pub use requires::PackRequirement;
pub use requires::Requires;
pub use requires::Unmet;
pub use state::Variables;
pub use template::resolve as resolve_template;
pub use validate::validate;
pub use validate::ValidationError;
pub use walk::next_by_handle;
pub use walk::walk_bfs;
pub use store::delete_flow;fs
pub use store::list_flows;fs
pub use store::load_flow;fs
pub use store::save_flow;fs
pub use log::append_flow_log;log
pub use log::load_flow_logs;log
pub use log::FlowLogEntry;log

Modules§

eval
Deterministic predicate evaluation for conditional nodes.
loglog
Flow execution log entries.
model
Core data model for the Flow specification.
nodes
Typed views over each core node type’s data payload.
requires
Declared dependencies of a flow: the integration packs and tool surface it needs in order to run.
state
The running variables state threaded through a flow, plus dotted-path helpers shared with crate::template.
storefs
Directory-backed CRUD for SavedFlow documents.
template
{{path}} interpolation for string fields in a flow.
validate
Spec-conformance validation for a SavedFlow or FlowDefinition.
walk
Generic graph traversal over a FlowDefinition.