Expand description
Pre-prompt memory context builder.
Assembles a ranked block of relevant memories to inject into the system prompt before each LLM call, constrained by the model’s token budget.
Structs§
- Context
Build Result - Result of a context build — includes the formatted prompt block and the raw memory hits that were included (for streaming to the client).
- Memory
Context Provenance - No memory body, owner credential or storage endpoint belongs in this receipt.
Enums§
- Memory
Context Status - Host-observed selection status, independent of memory-tool recall.
Functions§
- build_
context - Assembles a formatted memory context block for injection into a system prompt.
- build_
context_ with_ hits - Assembles a formatted memory context block for injection into a system prompt, returning both the block and the raw memory hits.