feat: 初始化 llm iwiki

This commit is contained in:
richarjiang
2026-04-15 11:13:08 +08:00
parent 67b2f7f2ac
commit fc54e0dba8
8 changed files with 402 additions and 0 deletions

3
.obsidian/app.json vendored Normal file
View File

@@ -0,0 +1,3 @@
{
"attachmentFolderPath": "assets"
}

1
.obsidian/appearance.json vendored Normal file
View File

@@ -0,0 +1 @@
{}

33
.obsidian/core-plugins.json vendored Normal file
View File

@@ -0,0 +1,33 @@
{
"file-explorer": true,
"global-search": true,
"switcher": true,
"graph": true,
"backlink": true,
"canvas": true,
"outgoing-link": true,
"tag-pane": true,
"footnotes": false,
"properties": true,
"page-preview": true,
"daily-notes": true,
"templates": true,
"note-composer": true,
"command-palette": true,
"slash-command": false,
"editor-status": true,
"bookmarks": true,
"markdown-importer": false,
"zk-prefixer": false,
"random-note": false,
"outline": true,
"word-count": true,
"slides": false,
"audio-recorder": false,
"workspaces": false,
"file-recovery": true,
"publish": false,
"sync": true,
"bases": true,
"webviewer": false
}

22
.obsidian/graph.json vendored Normal file
View File

@@ -0,0 +1,22 @@
{
"collapse-filter": true,
"search": "",
"showTags": false,
"showAttachments": false,
"hideUnresolved": false,
"showOrphans": true,
"collapse-color-groups": true,
"colorGroups": [],
"collapse-display": true,
"showArrow": false,
"textFadeMultiplier": 0,
"nodeSizeMultiplier": 1,
"lineSizeMultiplier": 1,
"collapse-forces": true,
"centerStrength": 0.518713248970312,
"repelStrength": 10,
"linkStrength": 1,
"linkDistance": 250,
"scale": 1.992301859915002,
"close": false
}

192
.obsidian/workspace.json vendored Normal file
View File

@@ -0,0 +1,192 @@
{
"main": {
"id": "c904bff9f1809506",
"type": "split",
"children": [
{
"id": "37b384f6703532f4",
"type": "tabs",
"children": [
{
"id": "07a6f5425ad166a7",
"type": "leaf",
"state": {
"type": "graph",
"state": {},
"icon": "lucide-git-fork",
"title": "关系图谱"
}
}
]
}
],
"direction": "vertical"
},
"left": {
"id": "b747ed72b5949dd0",
"type": "split",
"children": [
{
"id": "6d5749264494a85f",
"type": "tabs",
"children": [
{
"id": "7cfc0b6455181a1d",
"type": "leaf",
"state": {
"type": "file-explorer",
"state": {
"sortOrder": "alphabetical",
"autoReveal": false
},
"icon": "lucide-folder-closed",
"title": "文件列表"
}
},
{
"id": "67ffba76b779e2aa",
"type": "leaf",
"state": {
"type": "search",
"state": {
"query": "",
"matchingCase": false,
"explainSearch": false,
"collapseAll": false,
"extraContext": false,
"sortOrder": "alphabetical"
},
"icon": "lucide-search",
"title": "搜索"
}
},
{
"id": "138fba9bc595392e",
"type": "leaf",
"state": {
"type": "bookmarks",
"state": {},
"icon": "lucide-bookmark",
"title": "书签"
}
}
]
}
],
"direction": "horizontal",
"width": 300
},
"right": {
"id": "8c6b8d4eadac9db0",
"type": "split",
"children": [
{
"id": "8e37d49ebfe902b5",
"type": "tabs",
"children": [
{
"id": "1a380483b92619ed",
"type": "leaf",
"state": {
"type": "backlink",
"state": {
"collapseAll": false,
"extraContext": false,
"sortOrder": "alphabetical",
"showSearch": false,
"searchQuery": "",
"backlinkCollapsed": false,
"unlinkedCollapsed": true
},
"icon": "links-coming-in",
"title": "反向链接"
}
},
{
"id": "9dc96dc60b63adf6",
"type": "leaf",
"state": {
"type": "outgoing-link",
"state": {
"linksCollapsed": false,
"unlinkedCollapsed": true
},
"icon": "links-going-out",
"title": "出链"
}
},
{
"id": "5de1b101fe3c9474",
"type": "leaf",
"state": {
"type": "tag",
"state": {
"sortOrder": "frequency",
"useHierarchy": true,
"showSearch": false,
"searchQuery": ""
},
"icon": "lucide-tags",
"title": "标签"
}
},
{
"id": "dacd8aa8ef5549d6",
"type": "leaf",
"state": {
"type": "all-properties",
"state": {
"sortOrder": "frequency",
"showSearch": false,
"searchQuery": ""
},
"icon": "lucide-archive",
"title": "添加笔记属性"
}
},
{
"id": "aa1135bf92837366",
"type": "leaf",
"state": {
"type": "outline",
"state": {
"followCursor": false,
"showSearch": false,
"searchQuery": ""
},
"icon": "lucide-list",
"title": "大纲"
}
}
]
}
],
"direction": "horizontal",
"width": 300,
"collapsed": true
},
"left-ribbon": {
"hiddenItems": {
"switcher:打开快速切换": false,
"graph:查看关系图谱": false,
"canvas:新建白板": false,
"daily-notes:打开/创建今天的日记": false,
"templates:插入模板": false,
"command-palette:打开命令面板": false,
"bases:新建数据库": false
}
},
"active": "07a6f5425ad166a7",
"lastOpenFiles": [
"CLAUDE.md",
"wiki/log.md",
"wiki/index.md",
"assets",
"wiki/topics",
"wiki/sources",
"wiki/meta",
"wiki/ideas",
"wiki/entities",
"wiki"
]
}

112
CLAUDE.md Normal file
View File

@@ -0,0 +1,112 @@
# 知识库 Schema — 内容创作者 Wiki
本知识库用于沉淀小红书、微信公众号等平台的内容素材,提炼主题,积累创作灵感。
LLM 负责 wiki 层的全部写作和维护,人负责素材投喂、方向引导和最终创作。
---
## 三层架构
| 层 | 位置 | 所有者 | 说明 |
|---|---|---|---|
| Raw | 根目录(`*.md`、子文件夹均可) | 人 | 原始素材,不可变。文章剪藏、笔记截图、灵感草稿等 |
| Wiki | `wiki/` | LLM | 生成的结构化页面,人只读 |
| Schema | 本文件 (`CLAUDE.md`) | 人 + LLM | 约定与规则,需要调整时先改此文件 |
### Raw 素材存放约定
- 根目录下直接放 markdown 文件或按来源建子目录(如 `小红书/``公众号/``播客/`
- 图片统一放 `assets/`Obsidian 附件路径已配置指向此处
- 文件名格式:`来源-标题.md` 或自由命名,无强制要求
### Wiki 目录结构
```
wiki/
├── index.md # 内容目录LLM 每次 ingest 后更新
├── log.md # 操作日志append-only
├── sources/ # 每篇素材的摘要页(一对一)
├── topics/ # 主题/选题方向(多素材归纳)
├── entities/ # 实体页:人物、品牌、产品、账号
├── ideas/ # 创作灵感、选题构思、内容框架
└── meta/ # 方法论、风格指南等元知识
```
---
## 页面规范
### Frontmatter所有 wiki 页面必须包含)
```yaml
---
type: source | topic | entity | idea | meta
created: YYYY-MM-DD
updated: YYYY-MM-DD
tags: [] # 自由标签,小写,用短横线连接
sources: [] # 关联的 raw 文件路径source 页必填)
---
```
### Source 页(`wiki/sources/`
- 文件名:`{来源缩写}-{关键词}.md`,如 `xhs-护肤成分科普.md`
- 内容:原文核心观点摘要、关键数据/金句、可复用的内容角度
- 必须标注原始素材路径
### Topic 页(`wiki/topics/`
- 围绕一个选题方向,综合多个 source
- 包含:主题概述、关键论点、素材引用、潜在创作角度
- 当 3+ 个 source 涉及同一主题时应创建 topic 页
### Entity 页(`wiki/entities/`
- 人物、品牌、产品、账号等
- 包含:基本信息、相关内容汇总、值得关注的点
### Idea 页(`wiki/ideas/`
- 创作灵感和选题构思
- 包含:核心 hook、目标受众、参考素材链接、初步大纲
- 状态标记:`draft` / `ready` / `published` / `abandoned`
---
## 操作流程
### Ingest投喂素材
1. 读取 raw 素材全文
2. 与用户讨论关键要点(除非用户要求批量处理)
3.`wiki/sources/` 创建摘要页
4. 检查是否需要:创建/更新 topic 页、创建/更新 entity 页、生成 idea 页
5. 更新 `wiki/index.md`
6. 追加 `wiki/log.md` 条目:`## [YYYY-MM-DD] ingest | {标题}`
### Query查询
1. 先读 `wiki/index.md` 定位相关页面
2. 读取相关 wiki 页面,综合回答
3. 有价值的分析结果应存为新 wiki 页面idea 或 topic
4. 追加 log 条目:`## [YYYY-MM-DD] query | {问题摘要}`
### Lint健康检查
定期执行,检查:
- 孤立页面(无入链)
- 过时内容source 更新但 topic 未同步)
- 缺失的交叉引用
- 有素材积累但未创建的 topic
- idea 页面状态是否需要更新
- 追加 log 条目:`## [YYYY-MM-DD] lint | 检查结果摘要`
---
## 链接与引用
- Wiki 页之间用 Obsidian 双链:`[[wiki/topics/护肤成分]]`
- 引用 raw 素材用相对路径:`[[小红书/某篇笔记.md]]`
- 页面内引用具体段落时用 blockquote + 来源标注
---
## Obsidian 配置备忘
- 附件目录:`assets/`
- 推荐插件Dataviewfrontmatter 查询、Graph View关系可视化、Marp幻灯片

28
wiki/index.md Normal file
View File

@@ -0,0 +1,28 @@
---
type: meta
updated: 2026-04-15
---
# Wiki Index
知识库内容目录。LLM 每次 ingest 后更新此文件。
## Sources
<!-- 每条素材的摘要页 -->
_暂无内容_
## Topics
<!-- 主题/选题方向 -->
_暂无内容_
## Entities
<!-- 人物、品牌、产品、账号等实体 -->
_暂无内容_
## Ideas
<!-- 创作灵感、选题构思、内容框架 -->
_暂无内容_

11
wiki/log.md Normal file
View File

@@ -0,0 +1,11 @@
---
type: meta
---
# Wiki Log
操作日志,按时间倒序。每条以 `## [日期] 动作 | 标题` 格式记录。
## [2026-04-15] init | 知识库初始化
创建三层架构raw根目录→ wiki → schemaCLAUDE.md