What the kernel is¶
A project's agents and workflows run untrusted code: reusable capability blocks, the third-party libraries they import and the native extensions those libraries load. The kernel, XCK, is the operating system that code runs on: a Rust user-space kernel over Linux process cells, one per project runtime. It executes the project's sealed work, holds all runtime authority as grants and handles, enforces policy at the point of action and writes evidence of each step. This page covers the kernel's parts, what each one owns, and what crosses between the kernel and the other two planes.
The kernel among the planes¶
flowchart TB
subgraph CP["CONTROL PLANE"]
direction TB
REL[("Releases, policy, assignments")]
EVI[("Evidence metadata")]
end
subgraph NODE["DATA PLANE NODE"]
direction TB
XD["xratud<br/>reconcile, materialise, supervise"]
end
subgraph XCK["KERNEL: ONE PER PROJECT RUNTIME"]
direction TB
subgraph KP["KERNEL PROCESS, TRUSTED"]
direction TB
OPL["Operator lane endpoint"]
SYS["Kernel Application ABI ingress"]
HOST["Nucleus host<br/>timers, processes, effects"]
CORE{{"Nucleus core<br/>authority state machine"}}
RLN[("Return lane<br/>continuity store")]
end
subgraph CELLS["CELLS"]
direction TB
APP["Application cell<br/>kernel-local caller"]
MON["Cell monitor<br/>trusted, one per cell"]
PROV["Runtime provider<br/>untrusted, runs block code"]
end
end
REL -->|"1. assignments pulled"| XD
XD -->|"2. sealed handoff, runtime.* commands"| OPL
OPL --> HOST
HOST -->|"commands"| CORE
CORE -->|"effects"| HOST
HOST -->|"starts, supervises"| MON
MON -->|"provider protocol"| PROV
APP -->|"3. Run requests, through its monitor"| SYS
SYS --> CORE
CORE -->|"4. evidence"| RLN
RLN -->|"5. evidence, lifecycle"| XD
XD -->|"6. metadata and object references"| EVI
Releases, policy, assignments on the control plane decide what runs. The
node pulls an assignment, materialises it and hands it to Operator lane
endpoint sealed. From then on the run stays inside KERNEL: a kernel-local
caller in Application cell starts Runs through Kernel Application ABI
ingress, Nucleus core admits every call, and the Runtime provider cells do
the work. What leaves is evidence and lifecycle on Return lane, which the
node relays to the control plane as metadata.
The parts and what each owns¶
| Part | Trust | Owns |
|---|---|---|
| Nucleus core | Trusted, deterministic | Grants, local handles, cells and epochs, channels, tasks, scheduling decisions, resources, streams, buffers, leases, revocation, fault and evidence effects |
| Nucleus host | Trusted | Timers, process events, control channels, scheduler wake-ups, effect execution and receipts, the evidence sink |
| Cell monitor | Trusted, one per cell | Frame validation, handle import and export, guest supervision, deadline and cancellation forwarding, cell evidence |
| Runtime provider | Untrusted, one per cell | The language runtime, the block's code, third-party libraries, native extensions and every live object they create |
The nucleus core and the nucleus host run in the kernel process. Each cell is a monitor process and a provider process under one containment boundary. The chain is one root: the nucleus host starts each monitor, and each monitor starts its provider.
What the kernel does with a call¶
The caller's monitor checks the frame, the nucleus core admits it against an installed grant, the target's monitor validates it again, and the provider runs it. The nucleus core records the outcome as typed evidence. Policy is evaluated at six defined points of that path, so a call that policy refuses is never issued. Enforcement, native telemetry and scoring are functions of the kernel itself; see Three first-class features.
Across the plane boundary¶
The kernel exchanges three things with the other planes:
- Assignments in. The node delivers one control-plane assignment into the kernel as a sealed handoff that carries the admitted runtime closure, the sealed policy and trust inputs and the ownership lease with its fence.
- Lifecycle and supervision. The node drives the kernel over the operator
lane with ten
runtime.*commands. See The operator lane. - Evidence out. The kernel pushes status, events, logs, evidence and faults on the return lane. See The return lane.
Run traffic and application results stay with the kernel-local caller. A run's result reaches the control plane only as evidence.
When the kernel process ends¶
If the kernel process dies, every monitor and provider is terminated, the kernel epoch advances, and every local handle becomes stale. The node then reconciles its assignments into a clean kernel epoch. See Restart, epochs, and stale handles.
Related¶
- The core invariant for the rule every part enforces.
- Cells, containment, and placement for what a cell is.
- The Application Run Boundary for how kernel-local callers start and control Runs.