ce-explain
它能做什么
这项技能解释项目构建方式和一段工作期间所做改动背后的原因。适合需要理解现有代码或决定的人。
适用场景
- ✓当你想了解代码的某一部分为何这样构建的时候。
- ✓当你想获得项目在某个时间段内发生了什么的摘要的时候。
- ✓当你需要为没有参与工作的同事撰写解释的时候。
技能链接
https://github.com/EveryInc/compound-engineering-plugin/blob/main/skills/ce-explain/SKILL.md复制后粘贴给你的 AI(Claude、ChatGPT 或 Cursor),让它按照说明操作。
使用方法
最简单的方法:复制下面的消息,粘贴给你的 AI。它会读取这个技能并按说明操作。
可直接粘贴的消息
适用于 Claude Code、Codex 或 Cursor:在项目文件夹中运行,即可安装该技能。
下载 SKILL.md,放进智能体的技能文件夹。
可以这样问 AI
“请解释我们的登录系统为何使用两个独立的令牌服务。”
每周 5 个新技能,1 分钟读完。
工作原理
该技能读取相关的代码和历史记录,把有文档记录的原因与推断区分开来,然后写出解释。它会注明无法回答的未决问题。
技术内容(原始 SKILL.md)
作者在 GitHub 上的英文原文。
Explain How and Why
Produce an explanation that answers the scoped question and gives its consumer enough understanding for the intended use. The subject and purpose come from the request and available context, whether a person or another workflow supplied them. Ground project behavior in source evidence; distinguish documented rationale, inference, and unknowns.
Done: deliver the explanation with supporting evidence and material unanswered questions, or return the specific blocker. When an artifact is requested, deliver the artifact and its location. Publication is a separate action, not a condition of having explained the subject.
Consumer and interaction
Adapt depth and presentation to the intended readers and use. A person may need a working answer; a calling agent may need a teaching artifact for someone else. Do not infer the output from the caller's identity alone. When contributing to an ongoing workflow, deliver the requested result and leave continuation to its owner, the calling workflow. Do not add destination menus or follow-up offers to that return.
Resolve discoverable facts before asking. Ask only when missing information materially changes the answer and cannot be resolved from the request or evidence. If interaction is unavailable, return the unresolved question and its consequence rather than waiting or inventing an answer. A result may explain verified behavior while reporting that its historical rationale is unknown.
Read references/orchestration.md before grounding, the first blocking question, or subagent dispatch. It defines evidence gathering, tool use, model tiers, and their fallbacks.
Artifact Root
An explainer lands under <root>/explainers/ only when archived to the repo, and learnings may be read under <root>/solutions/. Resolve <root> only when you compose such a path; a scratch-only or external-concept run never composes one. Pass the resolved path to any subagent, not the config.
Resolve the CE artifact root <root> before composing any artifact path.
- Read
docs_rootfrom<repo-root>/.compound-engineering/config.yamlonly (<repo-root>=git rev-parse --show-toplevel). Do not read it fromconfig.local.yaml. Unset -><root>isdocs, exactly as before. - Validate a set value: a repo-relative directory whose real, symlink-resolved path stays inside the repo and is neither the repo root nor under
.git/. Otherwise stop with an error namingdocs_rootand the value -- never fall back todocs. - Use
<root>as the sole artifact location: create it if absent, compose each path as<root>/<subdir>with this skill's own subdirectory, and never also readdocs.
Execution Flow
Phase 1: Establish the question and use
Read references/intake.md now. It defines how the subject and time window are resolved, the input tokens, and how the delivery form is chosen. Explain only the requested subject. A bare invocation with no recoverable subject needs clarification under the interaction rule above, not an invented topic or default artifact.
Phase 2: Ground
Follow references/orchestration.md for the scoped evidence pass. Use existing evidence when it is adequate and current; check claims whose support is missing, disputed, or affected by source changes.
Create a run directory only when an artifact or an evidence dossier needs one. Use this block before writing either; it rejects a symlink or a scratch root owned by another user:
SCRATCH_ROOT="/tmp/compound-engineering-$(id -u)";
[ ! -L "$SCRATCH_ROOT" ] && (umask 077; mkdir -p "$SCRATCH_ROOT") 2>/dev/null && [ ! -L "$SCRATCH_ROOT" ] && [ -O "$SCRATCH_ROOT" ] && [ -w "$SCRATCH_ROOT" ] || SCRATCH_ROOT="${TMPDIR:-/tmp}/compound-engineering-$(id -u)";
if [ -L "$SCRATCH_ROOT" ]; then echo "unsafe scratch root symlink: $SCRATCH_ROOT" >&2; exit 1; fi;
(umask 077; mkdir -p "$SCRATCH_ROOT") || exit 1;
if [ -L "$SCRATCH_ROOT" ] || [ ! -O "$SCRATCH_ROOT" ]; then echo "scratch root is not owned by the current user: $SCRATCH_ROOT" >&2; exit 1; fi;
chmod 700 "$SCRATCH_ROOT" || exit 1;
RUN_DIR="$SCRATCH_ROOT/ce-explain/$(date +%Y%m%d)-$(openssl rand -hex 3)";
(umask 077; mkdir -p "$RUN_DIR") || exit 1; chmod 700 "$RUN_DIR" || exit 1;
echo "$RUN_DIR";
A behavior trace that splits across ownership boundaries writes scout dossiers. Create this run directory before dispatching those scouts.
- Diff mode. **Empty
常见问题
它会给出建议吗?
不会。如果需要判断或建议,其他技能更为适合。
它会总是区分事实与猜测吗?
会。该技能会区分有文档记录的理由、推断和未知之处。
我能把解释变成文档吗?
可以。如果你要求生成成果物,它会交付该成果物并说明保存位置。
详情
作者的原始描述
Explain how and why something has its current shape, or what happened over a window of work, grounded in evidence. Use when the user asks for an explanation. Use ce-pov for a judgment or recommendation.
热度
- GitHub 星标
- 26k
- 排名
- #10029
- 许可证
- MIT
- 更新时间
- 2026/11/2
评论
- …
同一仓库的更多技能
ce-babysit-pr
26k帮你的智能体通过处理评审意见、失败的检查和过时的分支,持续推动一个未合并的 GitHub 拉取请求走向合并。
ce-bakeoff
26k帮你的智能体为一个问题构建多个相互竞争的方案,进行比较,并把最强的部分组合成一个推荐方案。
ce-brainstorm
26k通过简短的引导式对话,帮你的智能体在任何工作开始前,把模糊的想法整理成清晰、规模合适的需求。
ce-code-review
26k帮你的智能体审查指定的代码改动或拉取请求,查找缺陷、回归、缺失的测试和规范问题,并报告清晰的发现。