personal-knowledge-base
Skill0 starsChanged 3 months agoMITView on GitHub
用「四区流转」模型组织个人知识库——纯 Markdown + 原始文件 + Git,跨 AI 工具通用。涵盖建库、收件箱归位、证书/资料归档与索引、笔记规范、作业协作、版本管理与隐私分级。当用户要建立或整理个人知识库、清空"收件箱"、归档证书与资料、或基于知识库完成作业时使用。
- Commits and pushes
1 other project uses a version of this.
Adopted by
Most recently taken up by
- WaytoAIC/personal-knowledge-basetheir own version, first seen Sep 23, 2026
Other versions1 project uses a version of this.
Word for word · 0
None found.
Edited · 0
None found.
Wrote their own version · 1
- WaytoAIC/personal-knowledge-base★ 0same name
How matches are found. Word for word: the exact same text. Edited: shares passages with this file (“99% same” means 99% of its five-word phrases also appear here; 10% or more counts). Their own version: similar meaning, or, weakest, the same name. We can’t tell which project had it first. Projects are counted among the 200 most-starred candidates, and mentions are links to the repository we found, up to 50 per site, so both counts are a floor.
In this repository4 other files it gives its agents.
- AGENTS.mdAGENTS.md
- CLAUDE.mdCLAUDE.md
- .github/copilot-instructions.mdCopilot instructions
- .cursor/rules/personal-knowledge-base.mdcCursor rule
The file
Files
个人知识库 · 组织架构 Skill
把一个人的资料、证书、笔记、项目、作业组织成一个纯文本、可版本管理、任何 AI 工具都能读写的知识库。
核心理念三条:
- 纯文本优先——Markdown + 原始文件,零厂商锁定,几十年后仍可打开
- 流动而非堆积——内容按"临时 → 整理 → 长期"流动,避免"该放哪"阻碍记录
- 规范即接口——用
AGENTS.md等通用约定文件写清规则,任何 agent 都能自动加载并遵守
1. 目录模型(四区 + 作业 + 工具 + 模板)
| 目录 | 用途 | 生命周期 |
01-收件箱 | 临时剪藏、随手笔记、灵感 | 定期清空归位 |
02-资料库 | 原始材料:证书 / PDF / 扫描件 / 图片,按主题分子目录 | 原始文件只增不改 |
03-笔记 | 整理后的知识笔记,按主题分子目录 | 长期维护 |
04-项目 | 进行中的项目 / 课题 / 论文 | 完成后归档 |
05-作业 | AI 协助完成的作业,每个作业一个文件夹 | 保留为记录 |
06-Agent工具 | 本机工具脚本、用法说明、环境说明 | 工具文档 |
00-模板 | 笔记与作业模板 | 只读参考 |
流转模型:收件箱 → 资料库 / 笔记 / 项目。
2. 初始化一个新知识库
assets/template/ 是可直接复制的骨架(含各目录、规范文件、模板)。
- Windows:
pwsh scripts/init.ps1 -Path "D:\我的知识库" - macOS / Linux:
bash scripts/init.sh ~/my-kb
脚本会复制骨架并 git init。也可手工复制 assets/template/* 到目标目录。
3. 内容规范(所有笔记必须遵守)
3.1 Frontmatter(YAML 头部)
---
type: note # note | certificate | document | project | inbox | assignment | person
title: 笔记标题
tags: [学业, 证书] # 受控词表,新增须在 INDEX.md 登记
created: YYYY-MM-DD
updated: YYYY-MM-DD # 每次修改必须更新
status: 活跃 # 收件箱 | 整理中 | 活跃 | 已完成 | 归档
---3.2 命名
- 笔记:
YYYYMMDD-简短描述.md - 资料:
主题-描述.ext - 文件名避免空格、引号与
\/:*?"<>|
3.3 资料文件必须配索引笔记
每个入库的 PDF / 图片都要有一个同名或同组 .md 索引笔记,写明:是什么、时间、来源、用途、存储路径。
AI 优先读索引笔记,而不是直接解析二进制文件。
3.4 链接
内部链接优先用相对路径(对各类工具最通用):[标题](../03-笔记/学业研究/xxx.md)。
Obsidian 的 [[双链]] 兼容但不是权威形式。
3.5 索引
根目录 INDEX.md 是活索引:新增 / 移动 / 归档笔记时同步更新;标签词表新增词条也在此登记。
4. 工作流(AI 执行规则)
4.1 收件箱归位(最常用)
处理 01-收件箱:
- 原始材料 →
02-资料库对应子目录 + 写同名索引笔记 - 知识笔记 →
03-笔记按主题归类 - 项目内容 →
04-项目 - 归位后删除收件箱原文,并在
INDEX.md登记
4.2 新建笔记
用 00-模板/笔记模板.md 初始化 → 填 frontmatter → 更新 INDEX.md。
4.3 作业协作
每个作业一个文件夹 05-作业/YYYYMMDD-课程名-作业名/,内含
README.md(元信息)+ 题目/ + 解答.md + 过程/ + 附件/。
流程:读题 → 检索知识库 → 作答写入 解答.md(标注来源、不编造、保留推导)→ 更新 status → 可复用知识点回灌 03-笔记/ → 登记 INDEX.md。
详见 assets/template/05-作业/AGENTS.md。
4.4 每次修改后
- 更新 frontmatter 的
updated - 结构变化时同步
INDEX.md
5. Git 规则
- 约定式提交:
feat:fix:docs:chore:refactor: - 一个逻辑变更一个提交;提交前
git status确认无敏感文件 - 有远端时提交后
git push
6. 隐私分级(重要)
把内容分成两级管理:
- 可入库:一般笔记、公开可查的荣誉、模板
- 敏感:证件照、身份证、含他人姓名/学号/编号的材料、账号密钥
规则:
- 敏感内容不进公开仓库、不外发;确需版本管理时用私有仓库,或对对应目录加
.gitignore - 引用敏感信息一律用占位符
<已脱敏> - AI 输出敏感内容前必须提醒用户
7. 硬性约束(Do / Don't)
- ✅ 每个作业一个文件夹;每个原始文件配索引笔记;改完更新
updated与INDEX.md - ✅ 引用知识库内容时给出相对路径来源
- ❌ 不编造:不确定处写
> 待确认:… - ❌ 不在
01-收件箱长期堆放;不在区根目录直接堆文件 - ❌ 不覆盖原始文件(原始材料只增不改)
8. 跨 Agent 使用
本仓库是一个通用 skill bundle,安装方式见 references/cross-agent.md:
| 工具 | 放置位置 |
| DSH | .agents/skills/ 或 ~/.agents/skills/(也支持 .dsh/skills、~/.dsh/skills) |
| Claude Code | .claude/skills/ 或 ~/.claude/skills/ |
| Cursor / Copilot / Codex / Cline / Windsurf | 直接以本仓库为工作区,或复制 assets/template/ 到目标库(内含各自的入口文件) |
详细规范见 references/conventions.md。
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

