Keyboard shortcuts

Press or to navigate between chapters

Press S or / to search in the book

Press ? to show this help

Press Esc to hide this help

LayerFS

Filesystem Storage for Parallel Agents

01 · LayerStack storage model

Core storage mechanisms

CAS, CDC, and COW solve three different forms of reuse: object identity, byte locality, and structural locality.

01 · Identity

Content-addressed storage

Names immutable objects from their canonical bytes, verifies reads, and reuses exact duplicates across files, layer stacks, and agents.

02 · Byte locality

Content-defined chunking

Keeps chunk boundaries stable around localized edits, so changing a small region does not require storing an entirely new large file.

03 · Structural locality

Copy-on-write

Publishes a change in a new layer by rebuilding only the changed file and directory path while preserving every unchanged subtree from its parent.

Check out an ephemeral filesystem from any layer

A LayerStack records a sequence of filesystem states. Agent A can check out an ephemeral filesystem from L1 while Agent B independently checks out another from L3, giving each agent a separate place to work from the state it selected.

A LayerStack containing layers L0 through L4. Agent A checks out an ephemeral filesystem from L1, while Agent B checks out a separate ephemeral filesystem from L3.
One LayerStack, two checkout points, and two ephemeral filesystems in which agents can work independently.

02 · System boundaries

LayerFS components

The storage engine is implemented today. The SDK and filesystem projection are the planned interfaces around it.

Implemented core

Storage

Owns identities, canonical objects, CDC, file manifests, structural COW, packs, immutable CAS admission, lifecycle coordination, and verified reads.

Planned boundary

SDK

Will expose stable filesystem, workspace, layer-stack, and publication operations without leaking private CAS handles or storage formats.

Planned boundary

Filesystem projection

Will expose a workspace to an agent and capture bounded filesystem effects. It delegates identity, CDC, COW, and admission to storage.

03 · Reading path

Build it from first principles

The book follows the same dependency order as the storage model: establish immutable content identity, localize file edits, optimize the combined representation, and only then add filesystem-level copy-on-write.

Chapter 1 CAS + CDC Vanilla CAS → CDC → chunks and file manifests
Chapter 2 · planned Optimizing CAS and CDC Typed objects, verified admission, identities, packs, and efficient reads
Chapter 3 · planned Adding Copy-on-Write Immutable trees, changed-path rebuilding, workspaces, checkpoints, forks, and rollback

04 · Ecosystem

Collaborating projects

LayerFS supplies storage mechanics. The surrounding projects own execution environments and version-control workflows.

Powered by Ephemeral AI Lab