microsoft/continual-learning
Guide for implementing continual learning in AI coding agents — hooks, memory scoping, reflection patterns. Use when setting up learning infrastructure for agents.
npx skills add https://github.com/microsoft/skills --skill continual-learning
Your agent forgets everything between sessions. Continual learning fixes that.
Experience → Capture → Reflect → Persist → Apply
↑ │
└───────────────────────────────────────┘
Install the hook (one step):
cp -r hooks/continual-learning .github/hooks/
Auto-initializes on first session. No config needed.
Global (~/.copilot/learnings.db) — follows you across all projects:
Local (.copilot-memory/learnings.db) — stays with this repo:
The hook observes tool outcomes and detects failure patterns:
Session 1: bash tool fails 4 times → learning stored: "bash frequently fails"
Session 2: hook surfaces that learning at start → agent adjusts approach
The agent can write learnings directly:
INSERT INTO learnings (scope, category, content, source)
VALUES ('local', 'convention', 'This project uses Result<T> not exceptions', 'user_correction');
Categories: pattern, mistake, preference, tool_insight
For human-readable, version-controlled knowledge:
# .copilot-memory/conventions.md
- Use DefaultAzureCredential for all Azure auth
- Parameter is semantic_configuration_name=, not semantic_configuration=
Learnings decay over time:
This prevents unbounded growth while preserving what matters.
cp -r, it won't get adopted"Use semantic_configuration_name=" beats "use the right parameter"Take microsoft/continual-learning from the repository into ~/.claude/skills for personal
use, or into .claude/skills inside a project.
The agent identifies a skill by the name field in its header. Two skills with the
same name cannot sit side by side — one of them will be ignored.