Deslop

作者 cursorccb5507cec15无许可证10K 个星标收录于 2026年10月8日更新于 2026年10月8日仓库今天更新

Remove AI-generated code slop and clean up code style

AI 生成的概览

检查分支相对 main 的差异,清除 AI 生成的代码冗余,同时保持行为不变。

功能
该技能检查当前分支与 main 之间的差异,并清理 AI 生成的代码冗余。它针对不必要或与本地风格不一致的注释、在可信代码路径中不正常的防御性检查与 try/catch、仅为绕过类型问题而使用的 any 强制转换,以及应改用提前返回的深层嵌套代码。修改以最小、聚焦为原则,除修复明确缺陷外保持行为不变,最后给出 1-3 句的简洁总结。
适用场景
适用于在分支上进行 AI 辅助编码之后,差异中出现冗余注释、多余防御性代码或绕过类型的强制转换时。适合在评审或合并前做最终清理,而非大范围重构。
运行要求
需要访问代码仓库及其 git 历史,以便检查分支相对 main 的差异。该技能不包含脚本,仅为指令。

Remove AI code slop

Check the diff against main and remove AI-generated slop introduced in the branch.

Focus Areas

  • Extra comments that are unnecessary or inconsistent with local style
  • Defensive checks or try/catch blocks that are abnormal for trusted code paths
  • Casts to any used only to bypass type issues
  • Deeply nested code that should be simplified with early returns
  • Other patterns inconsistent with the file and surrounding codebase

Guardrails

  • Keep behavior unchanged unless fixing a clear bug.
  • Prefer minimal, focused edits over broad rewrites.
  • Keep the final summary concise (1-3 sentences).

来源与署名

来源:cursor/plugins位于cursor-team-kit/skills/deslop提交ccb5507

许可证: 无许可证

内容归原作者所有。SourceWeft 从公开仓库中收录这些内容。

举报或申请下架