Build an Agentic OS
Connect knowledge, adaptive research, jointly authorized computation, and tested repair in one executable mission.
On this page
Agents can retrieve knowledge, research it, compute jointly, and ship a tested repair, each step under authority you control. These applications run on Chio’s kernel: workers with explicit authority, shared resources that keep their accounting, independent services that check one another, and work whose outcome you can inspect.
Run the missionOne mission runs four chapter applications end to end
An operating system for a research-to-repair mission
Retrieve an operating procedure, assign research, obtain joint compute approval, repair the analysis program, and publish only its reviewed candidate.
Run the composed mission, or choose one of the ten chapter applications. The mission retrieves a versioned recovery runbook, investigates its numerical evidence, requests joint authorization for a computation, and produces a tested repair whose publication the release owner controls. Each stage keeps the output contract it has in its own chapter.
Four relationships compose around one kernel
Delegation, shared resources, coordination, and federation are the relationships the chapters exercise. Each lens names the chapter that runs it.
A worker gets a job and the authority for it
A mission host narrows the tools, operations, lifetime, and limits a worker can exercise. The kernel checks each request against that signed authority before dispatch and signs the decision. Build a mission host.
The suite calls each chapter’s own implementation
The suite invokes the public Application implementation for each stage and creates a separate retained child run. Child output becomes the next stage’s input where the workflow depends on it, so knowledge retrieval, research, computation, and repair each have one implementation and keep their distinct authority boundaries.
async fn stage(app: &dyn Application, input: Value, parent: &Run) -> Result<(Value, Run)> {
let child = Run::create(&parent.directory()?.join("stages"), app.name(), &input)?;
let result = app.execute(input, child.clone()).await;
child.finish(&result)?;
parent.emit("suite.stage", app.name(), app.title(), child.snapshot()?)?;
Ok((result?, child))
}In the verified run, events 01 to 05 record the knowledge, research, cooperative, and two factory stages in order.
Retrieved evidence enters the research corpus verbatim
The mission retrieves permitted runbook passages and adds their text to the research corpus, then schedules bounded research against those sources. A source version and byte range can be followed from the knowledge result into the investigation.
let (knowledge, _) = stage(
&Knowledge,
json!({
"question":question,
"caller":"engineer",
"mode":if mode=="model"{
"model"
}else{
"retrieve"
},
"exercise_denials":true
}),
&run,
)
.await?;
let mut research_input = Research.sample();
research_input["question"] = json!(question);
research_input["allowance"] = json!(9);
let passages = knowledge["evidence"]
.as_array()
.context("Knowledge returned no evidence list")?;
let reference = passages
.iter()
.filter_map(|p| p["text"].as_str())
.collect::<Vec<_>>()
.join("\n");
if !reference.is_empty() {
research_input["sources"].as_array_mut().context("Research has no corpus")?.push(json!({"id":"retrieved-procedure","title":"Retrieved operating procedure","text":reference}));
}
let (research, _) = stage(&Research, research_input, &run).await?;The members authorize the computation and the release owner authorizes publication
Numerical samples from the selected research source become the cooperative’s requested computation. Member-local policy can refuse it, and a refused computation stops the composition before the factory stage. These signatures authorize the computation; publication has its own release-owner decision over the tested candidate.
// Compute over the actual measurements supplied to the research application.
let samples = research["sources"]
.as_array()
.context("No research sources")?
.iter()
.filter_map(|s| s["text"].as_str())
.flat_map(|t| t.lines())
.filter_map(|line| line.strip_prefix("samples:"))
.flat_map(|values| values.split(','))
.map(|v| v.trim().parse::<f64>())
.collect::<std::result::Result<Vec<_>, _>>()?;
anyhow::ensure!(
!samples.is_empty(),
"The research did not supply a numerical workload"
);
let joint_input = json!({"values":samples,"member_budget":input["member_budget"],"member_accepts":true,"exercise_denials":true});
let joint_run = Run::create(
&run.directory()?.join("stages"),
"cooperative",
&joint_input,
)?;
let joint =
chio_cooperative::execute_bilateral(joint_input, joint_run.clone(), executable).await;
joint_run.finish(&joint)?;
run.emit(
"suite.stage",
"cooperative",
"Jointly authorize computation over the investigated samples",
joint_run.snapshot()?,
)?;
let joint = joint?;
if joint["status"] != "completed" {
return Ok(json!({
"status":"awaiting_joint_authority",
"knowledge":knowledge,
"research":research,
"cooperative":joint,
"published":false
}));
}The release owner publishes the exact tested result
The factory generates or supplies a patch, tests and reviews one candidate, and creates a publication proposal. When the release owner selects approval, the suite calls the factory’s candidate-bound decision path. The final result retains every stage output and the publication receipt.
let (factory, factory_run) = stage(
&Factory,
json!({"issue":issue,"mode":mode,"exercise_denials":true}),
&run,
)
.await?;
let approval = &factory["approval"];
let decision = json!({
"action":"decide",
"source_run":factory_run.id()?,
"candidate_sha256":approval["candidate_sha256"],
"proposal_sha256":approval["proposal_sha256"],
"decision":if input["approve_publication"]==true{
"approve"
}else{
"reject"
}
});
let (publication, _) = stage(&Factory, decision, &run).await?;A low member budget, a failing test, or a withheld approval stops the mission
Each stage is a retained child run, so the suite’s own record is the list of stages that completed:
./run --run input.json01 suite.stage knowledge-network
Answers with an evidence trail
02 suite.stage research-swarm
Research that follows the evidence
03 suite.stage cooperative
Jointly authorize computation over the investigated samples
04 suite.stage software-factory
From issue to a tested candidate
05 suite.stage software-factory
From issue to a tested candidate- Reduce the cooperative member budget below the requested work: the composition stops before repair generation.
- Let tests or review fail: no factory completion or release is inferred.
- Withhold publication approval: the tested candidate stays available and the suite reports it as unpublished.
The downloadable tests assert each effect or its absence: run cargo test --locked -p chio-suite from the extracted project.
Ten chapters with one responsibility each
Each chapter runs one application on its own, with its own download and verified run.
- Build a mission host Run two scoped workers over one document, join their results by digest, and let a model answer through the same governed tools.
- Build a shared worker fleet Run competing workers against one durable authority, account for every report, and recover a lost acknowledgement without producing a report twice.
- Build an institutional knowledge network Retrieve permitted source versions, produce a cited answer, and show the caller when revocation or a stale citation stops a request.
- Build a research swarm Turn signed observations into retained assignments, run bounded investigations, and compare adaptive with fixed scheduling on the same workload.
- Build a software factory Turn an issue into a patch, test and review one exact candidate, and publish only the candidate the release owner approves.
- Build a personal agent network Connect a coordinator, a private knowledge node, and a compute node with independent identities, explicit membership, and governed remote tools.
- Build federated incident response Investigate a service failure across three independently governed organizations, approve one bounded repair, and confirm health after the change.
- Build an agent cooperative Let independent operators authorize shared computation, including a registered 2-of-3 threshold settlement with retained local-credit accounting.
- Build a cognition marketplace Generate a repair, have a venue replay it, purchase verified work within a bid, and apply the patch to a separate customer project.
- Operate an Agentic OS Kill processes, cancel work, expire authority, and recover only the outcomes the effect owner can prove.
Run the suite on your machine
Keep the run directory to follow the retrieved evidence, research assignments, joint computation, and candidate publication across the child stages.
cd chio-suite
./runThe archive holds the application, the shared host code, tests, sample input, pinned dependencies, and a README. The launcher builds and runs the Rust source included in this archive. Install Rust 1.94.1 and the README’s native prerequisites; filesystem isolation and operator workloads require the listed Linux host profile. Cargo resolves immutable public dependencies, so a sibling checkout is unnecessary.
For model workers, set OPENROUTER_API_KEY on the local host and select model mode; credentials stay on that host and never enter the docs form. The qualified model is openai/gpt-4.1-mini. Analysis, retrieval, and deterministic worker modes run without a model key. Ctrl-C stops the local web process and its active child work and keeps the run directory.
Download identity and source revision
Download complete project · View public source
46de3681ac093bf899ef637b4f61a575eae88d3a91279420e519ca9ae4f17065Replace one stage with your own service
Build your own operating system by replacing one stage with a useful service, keeping its inputs, authority, effect record, and completion condition explicit. A different research scheduler, private model worker, organizational tool host, or settlement adapter fits the same architecture with its responsibilities in view.