Skip to content
Agentmart
Submit a tool

neat-freak

End-of-session knowledge cleanup with OCD-level rigor — reconciles project docs (CLAUDE.md, README.md, docs/) and agent memory against the code so nothing rots.

Skill by UynajGI

IndexedMIT
Write a review

Install

Works with Claude Code, Claude apps, Codex, Cursor, Gemini CLI, GitHub Copilot, VS Code, OpenCode, Goose, Windsurf. Read the repository before you give any tool access to your data.

npx agentmarket install skill/uynajgi-neat-freak

Asks which of your tools to add it to (Claude Code, Codex, Cursor, VS Code, Windsurf, Gemini CLI, Claude Desktop) and shows the change first. See https://agentmart.dev/cli.

Get the weekly diff

The weekly diff: one email a week with new agent tools, notable updates and grade changes, plus security alerts for tools you follow. Double opt-in, one-click unsubscribe.

We use your email only for this newsletter. Privacy

About

End-of-session knowledge cleanup with OCD-level rigor — reconciles project docs (CLAUDE.md, README.md, docs/) and agent memory against the code so nothing rots. 会话结束后对项目文档和记忆进行洁癖级审查与同步。MUST trigger when the user says: "sync up", "tidy up docs", "update memory", "clean up docs", "/sync", "/neat", "同步一下", "整理文档", "整理一下", "更新记忆", "梳理一下", "收尾", "这个阶段做完了", "新人能直接上手", or any phrase suggesting a dev milestone where knowledge needs reconciliation. Also trigger when the user reports stale docs, conflicting memories, or wants a clean handoff to teammates or other agents. Bare "整理" / "tidy" with prior dev context counts — do not under-trigger. Cross-platform: works on Claude Code, OpenAI Codex, OpenCode, and OpenClaw.

Use cases: agent-building

No reviews yet. Installed it? Reviews come from verified installers only. How reviews work

Permissions

What this skill can do and what it asks for, from its SKILL.md. Checked Oct 25, 2026.

Tools
No tools found
Secrets
None asked for
Install scripts
None found

Network hosts it talks to 1

  • codeload.github.com · found in install command

Files it touches

  • ~/.claude/skills/neat-freak

What's inside

Skill name
neat-freak
Description
End-of-session knowledge cleanup with OCD-level rigor — reconciles project docs (CLAUDE.md, README.md, docs/) and agent memory against the code so nothing rots. 会话结束后对项目文档和记忆进行洁癖级审查与同步。MUST trigger when the user says: "sync up", "tidy up docs", "update memory", "clean up docs", "/sync", "/neat", "同步一下", "整理文档", "整理一下", "更新记忆", "梳理一下", "收尾", "这个阶段做完了", "新人能直接上手", or any phrase suggesting a dev milestone where knowledge needs reconciliation. Also trigger when the user reports stale docs, conflicting memories, or wants a clean handoff to teammates or other agents. Bare "整理" / "tidy" with prior dev context counts — do not under-trigger. Cross-platform: works on Claude Code, OpenAI Codex, OpenCode, and OpenClaw.
License
MIT
Instructions
147 lines in SKILL.md · view on GitHub

Before installing

  • Instructions call the network

Files (3)

  • SKILL.md
  • agent-paths.md · references/
  • sync-matrix.md · references/

SKILL.md (first lines)

# 洁癖 — Knowledge Base Neat-Freak

> **Cross-platform Agent Skill** — Claude Code · OpenAI Codex · OpenCode · OpenClaw 通用。
> 跨平台 SKILL.md,遵循开放 Agent Skill 规范。

你是一个**知识库编辑**,不是记录员。记录员只会往后追加,编辑会审查全局、合并重复、修正过期、删除废弃。你的工作是让整个项目的知识体系始终保持**干净、准确、对新人友好**的状态——像有洁癖一样。

## 为什么这件事重要

在 AI 协作开发中,代码可以随时重写,但**文档和记忆是跨会话、跨 Agent 的唯一桥梁**。如果记忆里有过期信息,下一个 Agent(无论它是 Claude、Codex 还是别的)会基于错误前提做决策。如果 docs/ 混乱或缺失,接手者(尤其是下游项目的同事)会浪费大量时间搞清楚这套系统怎么用。

这个 Skill 的价值就在于:**让知识体系的每一层都跟得上代码的变化。**

## 关键概念:三类知识,三种受众

**必须先理解这件事,否则你会只改 CLAUDE.md 就结束,把下游同事和其他 agent 晾在那儿。**

| 位置 | 受众 | 职责 | 不同步的代价 |
|------|------|------|--------------|
| **Agent 记忆系统**(若 agent 支持) | Agent 自己跨会话复用 | 个人偏好、非显而易见的项目事实、跨项目 reference | 下次会话 Agent 忘记历史决策 |
| 项目根 `CLAUDE.md` / `AGENTS.md` | 当前项目里的 AI(下次会话自己) | 项目约定、结构、红线、环境变量、路由清单 | 下次 AI 在这个项目里走弯路 |
| 项目 `docs/` + `README.md` | **其他人**(人类同事、下游开发者、未来接手的 AI) | 接入指南、架构图、运维手册、交接说明、API 参考 | **其他人或系统无法正确接入或运维** |

这三层**受众不同,职责不重叠**。CLAUDE.md 里写"新增了 device flow 五个路由" ≠ docs/integration-guide.md 里"下游怎么接这套 flow" —— 前者是提醒自己,后者是教别人。**两份都要写。**

> **Agent 记忆系统的具体位置因平台而异**(Claude Code 在 `~/.claude/projects/<...>/memory/`,Codex 用 `AGENTS.md`,OpenCode 用 `.opencode/`,OpenClaw 用 `~/.openclaw/`)。完整路径速查见 [references/agent-paths.md](references/agent-paths.md)。如果当前 agent 没有独立的记忆系统,直接跳过这一层,把功夫全花在 docs 和项目根 markdown 上。

## 执行流程

### 第一步:盘点现状(强制机械式枚举,不能跳过)

**先做 ls,再做判断。**

1. 列出 agent 的记忆文件(如有):
   - Claude Code:`ls ~/.claude/projects/<...>/memory/` 并读 `MEMORY.md` 及所有被引用的 `.md`
   - Codex / OpenCode / 其他:找该 agent 的等价位置(见 references/agent-paths.md)
2. 对本次对话涉及的**每一个项目**:
   - `ls <project-root>/` → 确认根目录结构
   - `ls <project-root>/docs/ 2>/dev/null` → **枚举所有 docs**(缺失也要确认)
   - `find <project-root> -maxdepth 2 -name "*.md" -not -path "*/node_modules/*" -not -path "*/.git/*"` → 兜底抓散落的 .md
   - 读 `README.md`、`CLAUDE.md` / `AGENTS.md`、每一个 `docs/*.md`
3. 读全局 agent 配置(若有,如 `~/.claude/CLAUDE.md`、`~/.codex/AGENTS.md`)
4. 回顾本次对话全部内容

**输出一张文件清单**(内部用,不用给用户看),对每个文件标:「评估过 / 要改 / 不用改」。**漏一个不行**——这是这个 skill 最容易翻车的地方。

### 第二步:识别变更——用"变更影响矩阵"思考

**不要只看对话增量有什么新事实,要看新事实会波及哪些文档层级。**

常见模式速览:
- 新增 API / 路由 → CLAUDE.md 路由清单 + integration-guide + architecture 的 Routes
- 新增 / 改名 环境变量 → CLAUDE.md 环境变量表 + runbook + 下游 integration-guide
- 新增数据库表 → CLAUDE.md + architecture 的 Data Model
- 新增大特性(跨多文件) → 以上全部 + architecture 新章节 + handoff 已完成清单
- 跨项目改动 → 上下游两边的 docs **都要对齐**(最常见的漏改场景)
- 记忆层面:相对时间→绝对日期、过期事实→改、重复→合并、已完成待办→删

完整映射表(覆盖更多变更类型与对应文档)见 **[references/sync-matrix.md](references/sync-matrix.md)**——遇到不确定的改动先查这张表。

**关键检查**:这次对话是不是**跨项目**的?如果改了项目 A 且项目 B 依赖它(通过 SDK、API、子域、环境变量),**项目 B 的 docs 也要改**。这是历次同步最常翻的车。

### 第三步:实际修改(用工具,不只是描述)

你必须**真的用 Edit 修改现有文件、用 Write 创建新文件、用删除命令清理废弃文件**。"我会怎么改"的描述不算完成。

**顺序建议**:先改 docs/(改错影响外部)→ 再改 CLAUDE.md/AGENTS.md → 最后理记忆。先动外部优先级最高的,即使中途被打断,读者看到的也是对齐的最新状态。

**编辑原则**:

- **合并优于追加**:新信息是对旧信息的更新,改旧条目,不要再加一条
- **删除优于保留**:完成的临时计划、推翻的决策、过期的上下文,删掉
- **精确优于冗长**:一条记忆说清楚一件事,别塞三件
- **绝对时间**:永远 `2026-04-29`,不写"今天"、"最近"
- **面向读者**:docs/ 的读者是"第一次接触这个项目的外部人",写的时候想象对方只有 5 分钟能看完
- **受众不混**:CLAUDE.md 里不抄 docs/ 的全文,docs/ 里不写"我记得上次……"——这是记忆的事

**全局配置极度克制**:`~/.claude/CLAUDE.md` / `~/.codex/AGENTS.md` 只有用户在对话中明确表达了**跨项目的核心原则**才动。日常项目细节绝不进全局。

**docs/ 编辑要点**——新增一个能力的文档变更通常要四处都补:
1. **integration-guide** 或对应"外部视角"文档:加**怎么用**(curl / SDK 示例 / 错误码表)
2. **architecture**:加**怎么工作**(数据流、状态机、设计取舍)
3. **runbook**:加**怎么运维**(冒烟命令、故障排查、环境变量)
4. **handoff** 或 CHANGELOG:加**已完成**

API 速查表、环境变量表、术语表是高频查询的结构化信息,**必须保持"所见即最新"**。

### 第四步:自检清单(必须逐项过一遍)

这一步防止"漏改 docs"。改完后逐条检查:

- [ ] 第一步列出的每个文件,都判断了"不用改"或"已改"
- [ ] 记忆索引(若有)里的每个链接指向存在的文件
- [ ] 每个记忆文件的 description 和内容对得上
- [ ] 记忆之间没有互相矛盾
- [ ] CLAUDE.md / AGENTS.md 里提到的路径 / 命令 / 工具 / 环境变量在代码中真实存在
- [ ] README 的安装 / 运行步骤跟代码一致
- [ ] 新增 API 路由:**在 integration-guide 和 architecture 都出现了**
- [ ] 新增环境变量:**在 runbook 和项目根 markdown 都出现了**
- [ ] 新增数据库表:**在 architecture 的 Data Model 和项目根 markdown 都出现了**
- [ ] 跨项目影响:下游项目的 docs 也跟着改了
- [ ] 没有相对时间遗留(`grep -E "今天|昨天|刚刚|最近|上周|today|yesterday|recently"` 清零)

哪条打不了勾,**回去补**。不要因为"差不多了"就跳过这一步——这是这个 skill 的灵魂。

### 第五步:变更摘要

在所有文件修改完之后(不是之前),给用户简洁摘要:

```
## 同步完成

### 记忆变更
- 更新:xxx(原因)
- 新增:xxx
- 删除:xxx(原因)

### 文档变更(按项目分组,每个项目列全改动的文件)
- <项目 A>/CLAUDE.md — xxx

From UynajGI/drbrain, MIT.

More from UynajGI/drbrain

Signals

Stars
0
Forks
0
Open issues
0
Last commit (this folder)
Sep 3, 2026 (1 month ago)

From GitHub (fetched Oct 24, 2026).

Details

License
MIT
First seen
Oct 24, 2026
Last checked
Oct 24, 2026

More from UynajGI

Cite this page

neat-freak skill. Agent Mart. https://agentmart.dev/skills/uynajgi-neat-freak (last updated 2026-10-24)