Every execution is a Run
Stable identity and causal parent–child relationships make the entire execution tree reconstructable.
A typed, observable, cancellable, and budget-aware runtime for models, tools, agents, and workflows in Rust.
use runifold::ProviderModelExt;
use runifold_providers::openai::OpenAiClient;
#[tokio::main]
async fn main() -> Result<(), Box<dyn std::error::Error>> {
let runtime = OpenAiClient::from_api_key(
std::env::var("OPENAI_API_KEY")?
)?.runtime("gpt-5")?;
let answer = runtime
.agent("assistant")
.system("Answer precisely. Expose uncertainty.")
.prompt_text("Why is durable execution useful?")
.await?;
println!("{answer}");
Ok(())
}Start with one prompt. Add production constraints without replacing the abstraction that got you there.
Stable identity and causal parent–child relationships make the entire execution tree reconstructable.
Tools, retrievers, and child agents receive named capabilities. Nothing inherits ambient permission.
Cancellation, deadlines, budgets, effects, and ambiguous retries are runtime state—not application folklore.
Install the runtime plus one provider adapter, then keep vendor details at the edge.
Run the compile-checked Quickstart →cargo add runifold@0.9.0
cargo add runifold-providers@0.9.0 --features openai
cargo add tokio --features macros,rt-multi-threadIdentity, budgets, cancellation, capabilities, and journals.
↗02 / MODELS & PROVIDERSLossless content, canonical streams, routing, and provider runtimes.
↗03 / DURABLE WORKFLOWSCheckpoints, Workers, leases, signals, timers, and tenant budgets.
↗