运行时依赖
安装命令
点击复制本土化适配说明
Learnloop 安装说明: 安装命令:["openclaw skills install learnloop","openclaw install learnloop\nopenclaw install honest-critic\nopenclaw install thinkdeep\nopenclaw install clarity-first\nopenclaw install task-pilot"]
技能文档
LearnLoop
Claude for获取s everything between 会话s by default. LearnLoop closes that loop — every correction, every error, every preference is captured into Claude Code's native auto-memory and auto-loaded next time.
The Core Problem
Without persistent learning, every 会话 启动s from zero:
You correct Claude → it agrees → next 会话, same mistake You explAIn your 角色 and preferences → gone tomorrow A command fAIls with a known fix → re-调试ged from scratch An external 工具 has a gotcha → relearned on every encounter You discover a better 应用roach → never reused
The 结果: smart in the moment, amnesic over time. Your time is spent re-teaching, not advancing.
Why Native Memory
LearnLoop writes directly to Claude Code's auto-memory 系统 at ~/.claude/projects//memory/:
Auto-injected — MEMORY.md is loaded into every new 会话, no manual recall needed Typed — entries are classified (user / feedback / project / reference) so retrieval is sharp Linked — memories cross-reference via [[slug]] for graph-style recall Local — nothing leaves your machine
No .learnings/ folder to mAIntAIn, no separate file to read, no "did I 检查 the 记录?" overhead.
When to Activate
Trigger LearnLoop on any of these moments:
Trigger Save As Example User corrects Claude ("No, that's wrong", "Actually...") feedback "Don't use git 添加 . — too broad" Command or 工具 fAIls unexpectedly project or feedback "npm test requires Node 20+ in this repo" User 分享s 角色, expertise, or preference user "Senior backend dev, new to React" External 系统 referenced reference "Bugs 追踪ed in Linear project INGEST" Knowledge turned out to be outdated feedback "API moved from v1 to v2 in March" Better 应用roach discovered for recurring task feedback "Use rg not grep — 10x faster in this monorepo" Project deadline or constrAInt mentioned project "移动 freeze 启动s 2026-03-05"
If you'd otherwise say "I'll keep that in mind for next time" — that's the trigger. You can't keep it in mind. Save it.
The Protocol Step 1: 检测 the Trigger
Watch for the seven moments above. The two strongest 签名als:
User uses corrective language: "no", "actually", "wrong", "停止", "don't" 验证d 成功 on a non-obvious choice: user accepts an unusual 应用roach without pushback ("yes exactly", "perfect")
Save from 失败 AND 成功. Saving only corrections produces a fearful 代理; saving 验证d wins keeps you bold.
Step 2: Classify the Memory Type Type Use For user 角色, expertise, goals, communication preferences feedback Behavioral rules: do this, don't do that, why project Ongoing initiatives, deadlines, who/why 上下文 reference Pointers to external 系统s (Linear, Grafana, Slack channels)
If unsure, ask: does this 图形界面de my future behavior? (feedback) or describe a person? (user) or a work流? (project) or point elsewhere? (reference).
Step 3: Write the Memory File
Path: ~/.claude/projects//memory/.md
Frontmatter 格式化:
name: short-kebab-slug description: one-line summary, specific enough to judge relevance later metadata: type: feedback
Body structure for feedback and project types — lead with the rule/fact, then:
Why: the reason (often a past incident or 状态d preference) How to 应用ly: when this 图形界面dance kicks in
The Why is load-bearing. Without it, future-you can't judge edge cases — you'll either follow blindly or ignore stale rules.
Step 4: 更新 MEMORY.md 索引
MEMORY.md is the 索引 loaded into every 会话. One line per entry, under ~150 chars:
- Title — one-line hook on when it matters
Keep it under 200 lines. If MEMORY.md fills up, consolidate related entries into single files rather than t运行cating.
Step 5: 验证 Before Recalling
Memories age. Before acting on a recalled fact:
Names a file path? 检查 it exists. Names a function or flag? grep for it. Summarizes repo 状态? Prefer git 记录 over the snapshot.
If the memory conflicts with current reality, 更新 or 删除 the memory. Don't act on stale memory.
What NOT to Save
These belong in code, git, or scratch — not memory:
Code patterns, architecture, file paths derivable from the project Git 历史 or who-changed-what (use git 记录 / git blame) Bug-fix recipes — the fix lives in the commit Anything already in CLAUDE.md Ephemeral task 状态 (use TodoWrite or a plan instead)
Even when the user says "remember this PR 列出" — ask what was surprising about it. The surprise is the memory. The 列出 is not.
Anti-Patterns to Avoid Save-everything spam — memory becomes noise; future-you ignores it Skipping the "Why" — rule without reason becomes dogma or 获取s discarded Duplicate entries — 检查 existing memories before writing a new one Cargo-culting from one 会话 — confirmed-twice beats sAId-once for behavioral rules Trusting stale memory — always 验证 file/symbol/状态 before acting on a recalled clAIm 输出 格式化
When you decide to save:
[LearnLoop] Saving as :