AI Agent Hub
Back to skills
AI Agent Long-Term Memory icon

AI Agent Long-Term Memory

AI Agent Updated 2026.08.30

Paste the following prompt into your AI chat to install this skill:

Please follow https://skillhub.cn/install/skillhub.md and install @user_4005c3e1/memory-skill.

About this skill

The Problem

AI agent context usually only covers the current session: user preferences, project decisions, correction lessons, and research findings can disappear after switching windows. Stuffing history into the prompt creates noise, omissions, and poor traceability.

How It Works

This skill stores long-term memory as workspace files instead of a black-box vector store. Memory lives under .workbuddy/memory/, with viking:// directories separating Daily/, Memory/, resources/, user/, and Feedback/. Each file must include complete YAML front matter with name, description, tags, importance, created, updated, and source, making it easier to parse, rank, and load on demand.

Key flow:
- Write triggers: conversation summaries go to Daily/, user preferences go to user/preferences.md, topic conclusions go to Memory/, research material goes to resources/, and corrections go to Feedback/.
- Confirm first: ask the user before writing so temporary discussion is not turned into durable preference.
- Priority retrieval: read user preferences, feedback, topic memory, daily notes, and external references first, and pass --path when calling search.py or read.py.

Boundaries and Notes

It fits personal or single-project workspace memory, not a shared knowledge base or database. Keep one file per topic, stay concise, and avoid loading all memories at once. If DEFAULT_MEMORY_PATH or RERANK_MODEL is missing in .env, pause and ask the user.

Use Cases

  • When building a support agent, write user corrections into Feedback/ and read it first to avoid repeating mistakes.
  • When creating a project assistant, write technical decisions into Memory/ and rank loading order by YAML importance.
  • When organizing research, write report summaries into resources/ so later retrieval does not depend on chat history.
  • At session end, create a Daily/ summary and read user/preferences.md to preserve user preference continuity.

Best For

  • Application engineers building conversational agents who need cross-session project preferences and corrections.
  • Automation engineers building personal work assistants who want task conclusions saved as retrievable files.
  • Platform developers maintaining AI workspaces who need a uniform directory and YAML front matter for agent memory.
  • Retrieval engineers who need priority access to feedback, preferences, topic memory, and research notes.