技能 编程开发 清理 AI 生成代码

清理 AI 生成代码

v20261107
deslop
此技能帮助开发者清理 AI 生成的代码,移除不必要的注释、过度的防御性检查和类型转换。它通过检查与主分支的差异来识别风格不一致之处并确保代码质量。在使用 AI 辅助创建分支时,使用此技能以维护代码库的一致性和可读性。
获取技能
148 次下载
概览

Remove AI Code Slop

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

What to Remove

  • Extra comments that a human wouldn't add or are inconsistent with the rest of the file
  • Extra defensive checks or try/catch blocks that are abnormal for that area of the codebase (especially if called by trusted/validated codepaths)
  • Casts to any to get around type issues
  • Inline imports in Python (move to top of file with other imports)
  • Any other style that is inconsistent with the file

Process

  1. Get the diff against main: git diff main...HEAD
  2. Review each changed file for slop patterns
  3. Remove identified slop while preserving legitimate changes
  4. Report a 1-3 sentence summary of what was changed
信息
分类 编程开发
名称 deslop
版本 v20261107
大小 1000B
更新时间 2026-11-08
语言