Skip to main content

assemble_context

Function assemble_context 

Source
pub fn assemble_context(
    db: &Database,
    brain_dir: &Path,
    prompt: &str,
    opts: &ContextOptions,
) -> Result<ContextBundle>
Expand description

Assemble a graph-aware context bundle for an agent prompt.

brain_dir is the .brain directory (for loading graph.mmap). When the mmap file is missing or the mmap feature is disabled, expansion is skipped and only ranked seeds are packed.

ยงErrors

Propagates FTS / database errors from the seed query.