Initial commit: company-kb framework

- 完整的知识库框架(P0-P5 路线图)
- 12篇治理文档
- 工具脚本(kb-init.sh, kb-lint-fm.py, feishu-sync.py, kb-bot)
- 7个 Claude 命令
- 示例项目和测试项目(wanniu-l1)
- 契约文件(meta/kb-contract.yaml)

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
This commit is contained in:
yangqianqian
2026-07-16 18:24:39 +08:00
commit 84f7950589
60 changed files with 4410 additions and 0 deletions

17
.claude/commands/kb-save.md Executable file
View File

@@ -0,0 +1,17 @@
---
description: 把当前对话的洞察回写为 questions/ 知识页
argument-hint: [可选:一句话点题]
---
把当前对话中有价值的问答/洞察沉淀成一页知识。`$ARGUMENTS` 是可选点题。
前置:`question` 是预留 type`meta/kb-contract.yaml``active: false`)。若尚未激活:
1. 提示用户"首次回写需激活 question type",征得同意后把契约里 `question` 改成 `active: true``mkdir -p questions/`
执行:
1.`meta/kb-contract.yaml` 确认 question 字段要求。
2. 提炼本轮对话的问题 + 结论,写到 `questions/<slug>.md`
- frontmatter`type: question``title``status`(草稿→seed)、`created`/`ingested`=今天、`related: [[...]]` 连到依据页。
- 正文:问题 / 结论 / 依据(挂 source_link
3.`python3 tools/kb-lint-fm.py questions/` 确认 exit 0。
4. 简报路径。绝不把无据推测写成知识——只沉淀有出处的结论。