4.8 KiB
LLM Memory System
Purpose
This vault maintains persistent knowledge that helps the LLM understand:
- Who you are — Your expertise, goals, working style
- How you want to collaborate — Feedback, preferences, constraints
- Project context — Ongoing work, decisions, deadlines
- External resources — Tools, links, references
Why This Matters
Without persistent memory, each conversation starts from scratch. This system allows the LLM to:
- Remember your preferences across sessions
- Build on previous decisions
- Avoid repeating mistakes
- Provide context-aware assistance
How It Works
File-Based Storage
All memories are stored as Markdown files with YAML frontmatter:
---
name: example_memory
description: Short description
type: feedback
created: 2026-05-15
---
Bi-directional Linking
Memories link to related notes using [[wikilinks]]:
See also: [[tier2-setup-retro]], [[bumakopania-research]]
Tagging System
Use tags for filtering and querying:
#type/user#type/feedback#type/project#type/reference
Memory Types
User Memories (memories/user/)
About you — your role, expertise, goals, preferences.
When to create:
- Learning about your background
- Understanding your goals
- Noting your expertise level
Example:
---
name: senior-kdb-developer
description: Senior developer working with KDB/time-series data
type: user
---
Feedback Memories (memories/feedback/)
Guidance on how the LLM should work with you.
When to create:
- After corrections ("no, not that")
- After confirmations ("yes, exactly")
- When establishing preferences
Structure:
- The Rule — What to do/avoid
- Why — Reason behind it
- How to Apply — When it matters
Example:
---
name: no-summary-responses
description: Keep responses terse, no trailing summaries
type: feedback
---
## The Rule
Don't summarize what you just did at the end of every response.
## Why
User can read the diff; summaries are redundant.
## How to Apply
After making code changes, just show the diff. No "I've updated X, Y, Z" summary.
Project Memories (memories/project/)
Ongoing work — decisions, context, deadlines.
When to create:
- Starting new initiatives
- Recording decisions
- Noting deadlines/constraints
Structure:
- Fact/Decision — What's happening
- Why — Motivation
- How to Apply — Impact on work
- Timeline — Dates, status
Example:
---
name: tier2-setup-2026-05-14
description: Setting up local knowledge database (kiwix-serve + zim-llm)
type: project
status: active
---
Reference Memories (memories/reference/)
External resources — tools, links, documentation.
When to create:
- Finding useful resources
- Recording tool configurations
- Noting where to find information
Example:
---
name: offline-docs-sources
description: Sources for offline documentation (Kiwix, LibGen, etc.)
type: reference
url: https://download.kiwix.org/
---
Workflow
Adding New Memories
- Identify type — user, feedback, project, or reference
- Create note — Use appropriate template
- Fill frontmatter — Name, description, type
- Add content — Rule/fact, why, how to apply
- Link related — Add
[[wikilinks]]to connected notes
Finding Memories
- Graph view — Visualize connections
- Search — Ctrl/Cmd + Shift + F
- Tag pane — Filter by type
- Backlinks — See what links here
- Smart Connections (plugin) — Semantic search
Maintaining Quality
- Be specific — Clear rules, concrete examples
- Include why — Context helps with edge cases
- Update regularly — Remove outdated info
- Link generously — Build knowledge graph
Integration with LLM
Automatic Loading
The LLM loads MEMORY.md and all .md files in this directory at the start of each session.
Manual Recall
Ask the LLM to:
- "Check memory for X"
- "What do you know about Y?"
- "Remember that Z"
LLM Plugins
For advanced features:
- Smart Connections — Vector search
- ObsidianLLM — AI-assisted writing
- Templater — Dynamic templates
Best Practices
- Save immediately — Don't wait to add feedback
- Be concise — One idea per note
- Use templates — Consistent structure
- Link everything — Build the knowledge graph
- Review regularly — Archive outdated memories
Migration from Previous System
This system builds on the existing file-based structure:
- Existing
.mdfiles remain in root - New memories go in
memories/{type}/ - Templates ensure consistency
- Obsidian adds linking, search, visualization