docs: init
This commit is contained in:
4
.gitignore
vendored
Normal file
4
.gitignore
vendored
Normal file
@@ -0,0 +1,4 @@
|
|||||||
|
.obsidian/
|
||||||
|
.claude/
|
||||||
|
.claudian/
|
||||||
|
hzh/Daily/
|
||||||
19
CLAUDE.md
Normal file
19
CLAUDE.md
Normal file
@@ -0,0 +1,19 @@
|
|||||||
|
# Claude Code 配置 - Obsidian 知识库
|
||||||
|
|
||||||
|
此知识库级别的配置为 Claude 操作提供额外的指导说明。
|
||||||
|
在行动前,先列计划(工具调用)。
|
||||||
|
|
||||||
|
## 新增和完善文件
|
||||||
|
|
||||||
|
在初始化和完成文件时,必须**完整**读取参照 `./config/agent/DOCUMENT_OPERATION.md`
|
||||||
|
了解结构、规范和惯例。
|
||||||
|
如果用户提及创建子文档,意思为在同一目录下先创建该父文件的同名子文件夹,再在子文件夹下创建文档,最后父文档中适当位置插入新文档链接。
|
||||||
|
在初次完善后,读取文件并二次检查是否符合文档的每一条内容规范——
|
||||||
|
- **教学者模式** 提问设计
|
||||||
|
- **代码示例** 合理注释
|
||||||
|
- **图表** Mermaid 格式正确性
|
||||||
|
## 行为规范
|
||||||
|
|
||||||
|
- 不要读取多余的无关文件,以减少 Token 消耗,这非常重要。
|
||||||
|
- 当你不确定某个文件应该放在什么地方时,应当优先询问用户,而不是自己探索。
|
||||||
|
|
||||||
52
config/agent/DOCUMENT_OPERATION.md
Normal file
52
config/agent/DOCUMENT_OPERATION.md
Normal file
@@ -0,0 +1,52 @@
|
|||||||
|
|
||||||
|
# 文件创建/修改规范
|
||||||
|
|
||||||
|
## 格式
|
||||||
|
|
||||||
|
```yaml
|
||||||
|
---
|
||||||
|
tags: []
|
||||||
|
create time: YYYY-MM-DD HH:mm
|
||||||
|
---
|
||||||
|
|
||||||
|
# <标题>
|
||||||
|
|
||||||
|
## 概述
|
||||||
|
[简短描述]
|
||||||
|
|
||||||
|
## 正文
|
||||||
|
[按照内容规范生成的内容]
|
||||||
|
|
||||||
|
## 关联笔记
|
||||||
|
- [[相关笔记-可不填-无需链接README]]
|
||||||
|
```
|
||||||
|
|
||||||
|
## 必填项
|
||||||
|
|
||||||
|
| 字段 | 格式 | 说明 |
|
||||||
|
|------|------|------|
|
||||||
|
| `tags` | 数组 | 必须存在 `[]`,智能填充相关标签 |
|
||||||
|
| `create time` | `YYYY-MM-DD HH:mm` | 当前系统时间 |
|
||||||
|
|
||||||
|
## 文档结构
|
||||||
|
|
||||||
|
1. **## 概述**: 简短描述文档内容,不要保留占位文本
|
||||||
|
2. **## 正文**: 主要内容,详略得当,注重拓展进阶
|
||||||
|
3. **## 关联笔记**: 相关笔记 Wiki-links,若无可移除
|
||||||
|
|
||||||
|
## 内容规范【IMPORTANT】
|
||||||
|
|
||||||
|
- **教学者模式**: 假设你是教学者,你需要先规划如何记录这个知识点,让读者能够容易理解。你也可以穿插问题在文档中,启发学生的思考。(建议使用 Obsidian **原生** `> [!type]` 语法)
|
||||||
|
- **代码示例**: 优先 Go (后端) + React/TS (前端),代码示例点到为止,不要过于冗长。可以适当通过注释省略一部分代码增强可读性,体现核心逻辑即可。当你给出代码时,一定要给出对应的文本解释。
|
||||||
|
- **图表**: 遇到关键概念、流程,仅仅靠文字不容易清晰说明,此时应该使用 Mermaid。避免使用纯文本 ASCII 图表。
|
||||||
|
- **风格**: 详略得当,注重实用性。文风严谨但是不失“活人感”,循序渐进,深入浅出。
|
||||||
|
|
||||||
|
## 附录 Mermaid 规范
|
||||||
|
|
||||||
|
"All content in the Mermaid code, especially Chinese content, MUST be enclosed exclusively in English double quotes "". Never use Chinese double quotes “” to enclose any content. "
|
||||||
|
"Inside English double quotes, no punctuation or special characters are allowed, except for the English comma ,. "
|
||||||
|
"Do not use \n for line breaks. "
|
||||||
|
"Node IDs MUST be in English. If Chinese text is required for display, it should be placed within double quotes. For example, use A["中文显示文本"] instead of 中文节点["文本"]. "
|
||||||
|
"When defining nodes with explanatory information using [], all information inside [] MUST be enclosed in double quotes, like A["Interface MethodSet"]. "
|
||||||
|
"For quadrant charts, do not use [label] for points, as this syntax format is incompatible. Points should be defined as A: [x, y]. "
|
||||||
|
"When generating requirement diagrams, replace fulfills with SATISFIES (满足) and calls with TRACES (追踪) to meet the required syntax. "
|
||||||
Reference in New Issue
Block a user