Skip to content

Slice 3.4 — Retrieval: sync stage, query stack, ranker, budgets, memory templates #380

Description

@failerko

Slice doc (canonical): 04-retrieval.md · milestone.md

Goal

Each turn's prompt gains a retrieved slice: the pre-retrieval sync
stage embeds dirty rows, three query vectors rank per-type
candidate pools through the pure ranker module (scoring, decay,
pinning, high-similarity bypass, MMR, greedy budget-fill), and the
selected bundle renders into the prompt through new memory pack
templates. js-tiktoken lands as the first budget-accounting
consumer; injected awareness rows get their retrieval_count
increment; lore.keywords drives the keyword pathway.

Dependencies

Depends on: #376 (Slice 3.1a). Develops against pnpm db:seed rows — no build gate on #379 (Slice 3.3); real-data validation is a milestone DoD item
Blocks: #381 (Slice 3.5)
Pairs with: #377 (Slice 3.1b) via C8 (swap-dialog route) — doc-contract, not a gate


The slice doc is the brief (scope, acceptance criteria, tests, contracts); this ticket tracks execution. Doc wins on conflict.


View on Discord

Metadata

Metadata

Assignees

Labels

1.0.0_MVPM3Milestone 3 — Memory floor slice work

Type

No type

Projects

Status
Ready

Relationships

None yet

Development

No branches or pull requests

Issue actions