Skip to content

Dependencies & Runtime Composition

How a reusable capability block states what it needs, where those bytes come from, and how two blocks with incompatible requirements run in one workflow.

Three places declare dependencies. The foundation is the base image a project's cells run on, and it exports a signed system baseline. runtime.xratu changes the project's shared set without rebuilding that image. @xratu declares every Python requirement a block imports. The resolver turns all three into one resolved runtime closure per block, and the kernel runs each closure in its own cell.

flowchart TB
  F["Foundation<br/>base image and exported baseline"] --> R
  P["runtime.xratu<br/>project-wide apt, prepared Python"] --> R
  B["@xratu<br/>this block's requirements"] --> R
  R["Resolution<br/>one binding per requirement"] --> C["Resolved runtime closure<br/>admitted by the control plane"]
  C --> M["Materialization<br/>data plane fetches and verifies"]
  M --> V["Verified closure view<br/>kernel opens the artifacts itself"]
  V --> Cell["Cell<br/>its own filesystem, import and loader views"]

In this section

How dependencies are declared

The runtime foundation

Project-wide declaration

Resolution

The resolved closure

Isolation in the cell

What the rest of the documentation assumes

A block declares every Python import. Presence in the foundation or in a prepared component makes bytes available to select; the block's own @xratu declaration grants the import.

The foundation is the shared base image. Large shared dependencies live there, and runtime.xratu changes the shared set without rebuilding it.

Everything is resolved before the cell starts. A closure names every selected component, and every package a cell imports was built and verified before the cell started.

A closure is immutable. A change produces a new closure digest and new cells, and running cells keep their closure until they are drained.