16 ejentum

code Skill

在生成、重构、审查或调试代码之前使用。触发短语包括“为X写一个函数/脚本/类”、“审查这段代码/diff/PR”、“重构一下”、“调试这个错误”、“这个实现正确吗”、“这段代码有什么问题”、“改进这段代码”、“从X转换到Y”,或任何包含你要求其处理的代码块的提示。也适用于规划架构变更、选择算法或数据结构、评估依赖升级。调用 code MCP 工具获取工程脚手架(失败模式、流程、正确示例等)。

安装方式:把技能目录放入 ~/.claude/skills/(Claude Code)或在 claude.ai 设置中启用;也可复制右侧安装命令一键添加。

查看源码

技能指令原文(SKILL.md)

Code Harness

When this skill triggers, call the code tool from the ejentum MCP server. Pass a 1-2 sentence framing of WHAT you are coding or reviewing as the query argument. Include the failure risk to avoid where possible.

Good query: review a Python refactor that converts raise UserNotFound to silent default return; tests still pass
Bad query: look at this code

The tool returns a structured scaffold containing:

  • [CODE FAILURE]: engineering failure pattern to avoid
  • [ENGINEERING PROCEDURE]: steps to follow
  • [REASONING TOPOLOGY]: decision flow
  • [CORRECT PATTERN]: shape correct code should take
  • [VERIFICATION]: self-check
  • Amplify: and Suppress: signals

Absorb internally. Do NOT echo bracket labels in the user-facing reply. Apply the scaffold's failure-pattern check against your draft before responding; if your code exhibits the named failure, rewrite.

If the API is unreachable, proceed with native engineering. The scaffold enhances; it is not a hard dependency.

Latency cost: ~1 second. Benefit: catches the kinds of behavioral changes and silent contract violations that look plausible but break under real conditions.

配合站内内容