lore
它能做什么
这是一种把软件项目的重要信息保存下来的方式,让人工智能(AI)能够记住这些信息。它会保存项目结构、已做出的决策,以及代码应当遵循的编写方式。
适用场景
- ✓开始一个新项目时,记录它的结构。
- ✓做出一项重要的项目决策之后。
- ✓当你希望 AI 记住特定的编码约定时。
技能链接
https://github.com/sickn33/agentic-awesome-skills/blob/main/plugins/agentic-awesome-skills-claude/skills/lore/SKILL.md复制后粘贴给你的 AI(Claude、ChatGPT 或 Cursor),让它按照说明操作。
使用方法
最简单的方法:复制下面的消息,粘贴给你的 AI。它会读取这个技能并按说明操作。
可直接粘贴的消息
适用于 Claude Code、Codex 或 Cursor:在项目文件夹中运行,即可安装该技能。
下载 SKILL.md,放进智能体的技能文件夹。
可以这样问 AI
“请记住这个关于项目架构的决定。”
每周 5 个新技能,1 分钟读完。
工作原理
信息会以纯文本文件(Markdown)的形式保存在名为 `.lore/` 的文件夹中。任何能够读取文件的 AI 都可以访问这些信息。
技术内容(原始 SKILL.md)
作者在 GitHub 上的英文原文。
lore — Framework-agnostic Memory Management
What this skill is
A long-term knowledge base for a software project, maintained by AI agents. It is not a dev journal or a changelog. It captures the kind of context that normally lives only in the original developer's head:
- What the project is, how it is shaped (architecture)
- Why specific choices were made over alternatives (decisions)
- How code should be written and what to avoid (conventions)
This knowledge is persisted as plain Markdown files in .lore/ at the project root. Any agent that can read files can consume them.
When to Use
The skill uses a two-tier trigger model.
Tier 1 — Loading the skill
Load this skill when the user explicitly invokes lore, names a subcommand, references .lore/, or asks to record, recall, audit, sync, or compress project memory about decisions, architecture, conventions, or monorepo scopes. Generic phrases like "init", "compress", "audit", or "query" alone are not enough — they may map to the agent's native commands or unrelated tasks (Claude Code's /init, /compact, security audits, SQL queries, etc.).
| User says (examples) | Command |
|---|---|
| "lore init" / "create lore memory bank" / "initialize lore" | init |
| "lore sync" / "sync this change to lore" / "record this decision in lore" | sync |
| "lore query" / "query lore" / "what's the project convention" | query |
| "lore audit" / "check lore" / "is memory still accurate" | audit |
| "lore compress" / "compress lore" / "summarize lore" | compress |
| "lore mirror" / "update CLAUDE.md" / "refresh mirror" | mirror |
| "lore history" / "show the git history of this entry" / "show me the commits behind this" | history |
Tier 2 — Internal proposals (after the skill is loaded)
Once the skill is loaded for this session, certain commands may proactively propose themselves based on internal thresholds. These proposals still require user acceptance — the skill never mutates files silently.
syncproposes when 50+ changed lines span 2+ directories, OR a new top-level module/directory/dependency was added or removed, OR a new convention was explicitly discussed in chat.compressappends a[COMPRESS NOTICE]to sync proposals when entries > 500,SUMMARY.mdis missing, or last compression > 30 days ago.syncemits[ALERT]markers when an active entry conflicts with current code or with a candidate change.mirrorregenerates automatically duringcompressifauto_mirror: trueis set in.lore/.config.json.
Other commands (init, query, history) are always explicit — they need user intent. See references/workflows.md for when each workflow is used.
Which command do I need?
| User goal | Command | When | Procedure |
|---|---|---|---|
| First-time setup, or start over | init |
One-time setup | references/workflows.md#init, then references/platform-mirrors.md + references/monorepo-detection.md |
| "Remember this change" after a feature / refactor / bug fix | sync |
After a non-trivial change | references/workflows.md#sync, then references/stale-new-markers.md |
| "What is the project convention / why was X chosen?" | query |
Answer from memory | references/workflows.md#query |
| "Is memory still accurate?" | audit |
Memory may have drifted from reality | references/workflows.md#audit, then references/audit-template.md |
| "Summarize the memory bank" | compress |
SUMMARY.md stale, or entries > 500 | references/workflows.md#compress, then references/summary-template.md |
| "Update CLAUDE.md / AGENTS.md / mirrors" | mirror |
Explicit publish of mirror changes | references/workflows.md#mirror, then references/platform-mirrors.md |
| "Why does this decision exist?" / "show the commits behind this" | history |
Git story behind an entry | references/workflows.md#history, then references/history-command.md |
…
常见问题
“lore”和开发日志有什么区别?
“lore”关注的是项目的长期信息(架构、决策、约定),而不是每日的活动记录。
我需要使用所有的 lore 命令吗?
不需要,按需使用即可:`init` 用于开始,`sync` 用于记录变更,`query` 用于提问,`audit` 用于检查,`compress` 用于总结,`mirror` 用于更新文档。
如果不使用 lore 会怎样?
AI 可能会遗忘重要的项目细节,从而导致前后不一致,或重复讨论已经做过的决定。
详情
作者的原始描述
Markdown project memory for AI agents. Use for decisions, architecture, conventions, monorepo scopes, `.lore/`, or `lore` commands; not native `/init`/`/compact` or generic init/compress/audit/query.
热度
- GitHub 星标
- 48k
- 排名
- #5118
- 许可证
- MIT
- 更新时间
- 2026/10/15
评论
- …
同一仓库的更多技能
00-andruia-consultant
48k帮你的智能体启动或改进 AI 项目。它可以分析代码、推荐工具,并用西班牙语制定行动计划。
007
48k让你的智能体执行安全审计和威胁建模。它有助于保护项目免受攻击和漏洞的威胁。
10-andruia-skill-smith
48k帮你的智能体创建或改进 AI 工具。它可以定义工具的工作方式、编写文档,并验证其结构。
20-andruia-niche-intelligence
48k让你的智能体创建某个特定行业的摘要。它有助于借助可靠的信息来源,了解项目的背景、规则、使用模式和风险。