Skip to main content

Module mm

Module mm 

Source
Expand description

Memory-management paging decisions (Phase 4) and long-term memory management (Phase 7).

The kernel decides when to page working context out/in; SDKs perform how (durable store, embedding search, idle pipeline). No I/O in this module.

Phase 7 extends this module with memory classification and validation rules.

Re-exports§

pub use handle::plan_eviction;
pub use handle::plan_spool;
pub use handle::EvictionOp;
pub use handle::EvictionPlan;
pub use handle::Handle;
pub use handle::HandleId;
pub use handle::HandleKind;
pub use handle::HandleTable;
pub use handle::Residency;
pub use handle::SpoolDecision;

Modules§

handle
Primitive P3: the resource handle table + paging (context as address space).
memory
Long-term memory management (Phase 7).

Structs§

PageInEntry
One knowledge entry supplied by the SDK after a long-term fetch (page-in).
PageInRequest
Parsed arguments for a page-in meta-tool call.

Enums§

MemoryTierHint
Long-term tier hint for a page-out event (SDK maps to durable vs semantic store).

Functions§

is_page_in_tool
Whether a tool name triggers an explicit page-in request (memory / knowledge meta-tools).
page_in_requests_from_calls
Extract page-in requests from proposed tool calls (pure parse, no I/O).
tier_hint_for_compress
Map a pressure-driven compression action to the recommended long-term tier.