Memory Recall: Ranking and Relevance
Memory & Context
90-120 minutes0/4 steps0%
Step 1 of 4
Build the lexical layer
Exact matches are the floor of trustworthy recall.
First time here? Paste the Context Pack first so the AI understands your project - open it from the header above.
Prompt Capsule
Implement lexical search over memory entries. Requirements: tokenize entries and queries (lowercase, split identifiers on common separators so auth_handler matches 'auth handler'); score with BM25 (use SQLite FTS5 or a small library - do not hand-roll unless trivial); support quoted exact-phrase matching for error strings; return top-K with matched terms highlighted per result. Test with queries that MUST work lexically: an exact file name, an exact error message substring, and a specific command flag - all should hit their entries at rank 1.
Paste into EmergentFull Build: complete implementation prompt with explicit requirements
Quick is short. Full Build is recommended for most steps. Strict forces real logic when the AI keeps faking output.
Actual change check
Expected after this step
BM25 lexical search passing the exact-match tests.
Should NOT happen
- An existing feature broke
- A button only logs to console
- Data disappears after refresh
- Errors fail silently with no visible state
This is what should exist before you continue. If reality does not match, do not move on.
Track what changed, failed, or needs follow-up. Notes export with the flow.
Pass the Verify Gate to complete this step