Refine and restructure existing notes into well-organized, deduplicated, and enriched documents in your personal Yuque knowledge base. For personal/individual use — reads and writes your own docs.
Help the user transform scattered, rough notes into well-structured, deduplicated, and enriched documents. Turn chaos into clarity.
All tools are from the yuque-mcp server:
yuque_search — Find the target notes to refineyuque_get_doc — Read the full content of notesyuque_list_repos — List personal reposyuque_list_docs — List documents in a repoyuque_create_doc — Create the refined documentyuque_update_doc — Update the original document in placeThe user may provide:
If the user says "整理我最近的笔记":
Tool: yuque_search
Parameters:
query: "每日捕获"
type: "doc"
Or for topic-specific notes:
Tool: yuque_search
Parameters:
query: "<topic keyword>"
type: "doc"
For each identified document:
Tool: yuque_get_doc
Parameters:
repo_id: "<namespace>"
doc_id: "<slug>"
Read up to 5-10 source documents. If there are more, prioritize by recency and relevance.
Before refining, analyze the raw content:
Present the analysis to the user:
## 📋 笔记分析
**来源**:X 篇文档,共约 XXXX 字
### 主题分布
- **[主题 1]**:X 条相关记录
- **[主题 2]**:X 条相关记录
- **[主题 3]**:X 条相关记录
### 发现
- 🔄 发现 X 处重复内容
- 🕳️ 发现 X 处信息缺口
- 📊 建议整理为 X 篇主题文档
要按这个方向整理吗?
Based on user confirmation, perform the refinement:
Restructure one document:
Merge multiple notes into themed documents:
Refined document template:
# [主题标题]
> 整理自 X 篇笔记,时间跨度:YYYY-MM-DD 至 YYYY-MM-DD
> 最后整理:YYYY-MM-DD
---
## 概述
[对这个主题的整体概述,2-3 句话]
---
## [分类 1]
### [子主题 1.1]
[整理后的内容]
### [子主题 1.2]
[整理后的内容]
---
## [分类 2]
### [子主题 2.1]
[整理后的内容]
---
## 待补充
- [ ] [识别出的信息缺口 1]
- [ ] [识别出的信息缺口 2]
---
## 原始来源
- [原文档 1 标题](链接) — YYYY-MM-DD
- [原文档 2 标题](链接) — YYYY-MM-DD
---
> 本文档由 AI 助手整理,原始笔记已保留。
Ask the user's preference:
For new document:
Tool: yuque_create_doc
Parameters:
repo_id: "<namespace>"
title: "[主题标题]"
body: "<refined content>"
format: "markdown"
For in-place update:
Tool: yuque_update_doc
Parameters:
repo_id: "<namespace>"
doc_id: "<slug>"
body: "<refined content>"
✅ 笔记整理完成!
📄 **[[主题标题]](文档链接)**
📚 已保存到:「知识库名称」
### 整理成果
- 📥 输入:X 篇原始笔记,约 XXXX 字
- 📤 输出:1 篇结构化文档,约 XXXX 字
- 🔄 去除重复:X 处
- 🕳️ 标记待补充:X 处
💡 原始笔记已保留,可随时对照。
| Situation | Action |
|---|---|
| Source notes are too few (<3 items) | Refine what's available; suggest capturing more first |
| Source notes are too many (>10 docs) | Focus on most recent or ask user to narrow the scope |
| Content is already well-structured | Tell user honestly; suggest minor improvements only |
yuque_update_doc fails | Fall back to creating a new document |
| Mixed languages in notes | Maintain the dominant language; don't force translation |