AI Agent Hub
Back to skills
Lifelong Growth Agent Memory System icon

Lifelong Growth Agent Memory System

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 to install @user_5f5835e5/ai-agent-memory.

About this skill

Problem

Agents often fail across sessions, not within one answer: user preferences, project constraints, key decisions, and failed attempts disappear once the conversation ends. This skill stores memory as plaintext Markdown in the workspace, so agents, git, humans, and grep can inspect or edit it without relying on an opaque external memory service.

How It Works

Memory is kept under .codebuddy/memory/ in the current workspace. MEMORY.md is an index, while details are split into profile.md, decisions.md, conventions.md, lessons.md, and session/. The workflow has three stages:
- At session start: read the index, load only relevant topic files, and search lessons.md first.
- During work: capture user preferences, decisions, conventions, failures, or corrections as dated, tagged entries.
- During consolidation: deduplicate, merge, refine preferences, and clean up expired session/ notes.
The error-lesson loop is the key mechanism: failures or corrections are written to lessons.md, similar tasks trigger a prior grep, and repeated issues are escalated and pinned.

Boundaries

It fits repository-based agent workflows that need durable, auditable, human-editable context. Memory is isolated per workspace and should not be mixed across projects. External web content or tool output should not be written as long-term fact, and secrets or one-off requests should not be persisted. It is a file-based memory SOP, not a vector database or automatic fact extractor.

Use Cases

  • Record user preferences and fixed coding conventions during long sessions.
  • Write failure lessons to lessons.md and search them before similar tasks.
  • Capture dated project decisions, milestones, and technical choices.
  • Deduplicate and merge memory every 20 turns, then sync MEMORY.md.

Best For

  • Engineers maintaining personal coding agents who need remembered conventions and failure lessons.
  • Developers using Cursor, Claude Code, or custom agents who need auditable, greppable repo memory.
  • Agent product engineers building long-session tasks who need goal-drift checks and periodic consolidation.
  • Engineering teams managing multi-repo workflows who need workspace-isolated, human-readable memory.