anomalyco / anomalyco/opencode
[FEATURE] Per-folder notebook memory (notes_get/notes_commit) for the agent
Nobody has claimed this yet.
- Dominant language
- TypeScript
- Stars
- 209k
- Forks
- 27.5k
- PR merge metrics
- PR metrics pending
Description
Summary
Add per-folder notebook memory so the agent persists what it learns across tasks and reuses it instead of re-exploring code.
What
- Each folder can carry a
.note.yamlwith a folder summary, per-file entries, and cross-file relations, grounded inbased_onsource fingerprints with freshness badges (✓/⚠/✗). notes_getreads the ancestor-chain memory for a path or keyword-searches all notebooks.notes_commitwrites summaries/entries/relations with diff approval (write-notespermission), never auto-approved.- A concreteness gate rejects summaries that name no concrete symbols, so saved notes are usable mid-task.
NotebookAttachprepends the relevant per-file note toread/edit/write/apply_patchoutput on first touch (opt-out viaexperimental.notebook.attach = false).- The injected digest tells the model it only samples memory and to call
notes_getbefore answering general project questions. - Save-learnings nudge after exploring without saving.
Motivation
Agents re-read code they have already mapped; a lightweight, source-grounded per-folder memory with freshness badges avoids that and keeps the map trustworthy.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Locate the notes_get and notes_commit entry points and the NotebookAttach implementation first. Trace how folder memory, source freshness, write-notes approval, concreteness checks, and tool-output attachment are represented. Done means per-folder notes can be read and safely committed, relevant notes attach as specified, and the opt-out and save-learnings behavior work.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- typescript
- Domain
- ai, developer-experience
- Issue type
- Feature
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Quiet
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100