Skip to content

Add code-simplifier skill with three-aspect review#211

Merged
xingyaoww merged 7 commits intomainfrom
add-code-simplifier-skill
Apr 25, 2026
Merged

Add code-simplifier skill with three-aspect review#211
xingyaoww merged 7 commits intomainfrom
add-code-simplifier-skill

Conversation

@xingyaoww
Copy link
Copy Markdown
Contributor

  • A human has tested these changes.

Why

The code-simplifier plugin from the Claude Plugins Official repository provides useful code simplification capabilities, but it is a single monolithic pass and references Claude-specific conventions (CLAUDE.md). This PR migrates and adapts it for OpenHands as a proper skill with progressive disclosure, split into three focused review dimensions.

Summary

  • Add new code-simplifier skill that analyzes recently modified code across three dimensions: code reuse, code quality, and efficiency
  • Each dimension has its own detailed reference document (references/code-reuse-review.md, references/code-quality-review.md, references/efficiency-review.md) for progressive disclosure
  • SKILL.md supports sub-agent delegation (parallel review) with fallback to sequential review
  • All CLAUDE.md references replaced with AGENTS.md for OpenHands compatibility
  • Registered in marketplaces/openhands-extensions.json and README catalog updated via sync script

How to Test

  1. Verify the skill structure: ls -R skills/code-simplifier/
  2. Verify sync passes: pip install pyyaml && python scripts/sync_extensions.py --check
  3. Verify marketplace registration: grep -A 8 'code-simplifier' marketplaces/openhands-extensions.json
  4. Review the SKILL.md for correct frontmatter, description, and references to AGENTS.md
  5. Confirm each reference doc has tagged output format ([REUSE], [QUALITY], [EFFICIENCY])

Notes

This PR was created by an AI agent (OpenHands) on behalf of the user.

@xingyaoww can click here to continue refining the PR

Migrated and adapted from the Claude Plugins Official code-simplifier
plugin. Split into three focused review dimensions (code reuse, code
quality, efficiency) with sub-agent delegation support and AGENTS.md
integration.

Co-authored-by: openhands <openhands@all-hands.dev>
…GENTS.md

Co-authored-by: openhands <openhands@all-hands.dev>
Replace three keyword triggers (simplify, refine, cleanup) with a
single /simplify slash command via the commands/ directory approach,
per repository conventions.

Co-authored-by: openhands <openhands@all-hands.dev>
Let sync_extensions.py auto-generate the commands/simplify.md file
from the trigger definition.

Co-authored-by: openhands <openhands@all-hands.dev>
Required by test_skill_plugin_loading.py for Codex compatibility.

Co-authored-by: openhands <openhands@all-hands.dev>
Generated by sync_extensions.py for Codex/Claude compatibility.

Co-authored-by: openhands <openhands@all-hands.dev>
@xingyaoww xingyaoww marked this pull request as ready for review April 24, 2026 19:15
Copy link
Copy Markdown
Contributor

@all-hands-bot all-hands-bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🟡 Acceptable - Well-designed skill with good progressive disclosure structure, but uses deprecated trigger convention.

[IMPROVEMENT OPPORTUNITIES]

  • Trigger format uses deprecated slash convention instead of keywords
  • Scope specification could be more explicit for user clarity

[RISK ASSESSMENT]

⚠️ Risk Assessment: 🟢 LOW

New skill addition with no changes to existing code. Well-structured progressive disclosure, properly registered in marketplace, follows repository conventions (except trigger format). Limited blast radius - only affects users who invoke this specific skill.

VERDICT: ✅ Worth merging after addressing trigger convention

KEY INSIGHT: The three-aspect split (reuse, quality, efficiency) with separate reference documents is a pragmatic improvement over monolithic review - each dimension has clear, actionable criteria without forcing special-case handling.

Comment thread skills/code-simplifier/SKILL.md
Comment thread skills/code-simplifier/SKILL.md Outdated
Co-authored-by: openhands <openhands@all-hands.dev>
Copy link
Copy Markdown
Contributor Author

Addressed feedback in 5d8be69. Ready for another look.

@xingyaoww xingyaoww requested a review from all-hands-bot April 24, 2026 19:22
Copy link
Copy Markdown
Contributor

@all-hands-bot all-hands-bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🟢 Good taste - Well-designed skill addition with clear structure, pragmatic philosophy, and proper progressive disclosure.

[RISK ASSESSMENT]

⚠️ Risk Assessment: 🟢 LOW

New skill addition with no changes to existing code. Well-structured progressive disclosure with three focused review dimensions (reuse, quality, efficiency), properly registered in marketplace, follows repository conventions including the new punctuation style. Previous review feedback has been addressed.

VERDICT:

Worth merging: Elegant solution that addresses a real need without over-engineering.

KEY INSIGHT:

The three-aspect breakdown with separate reference files demonstrates good taste in progressive disclosure - simple enough to understand quickly, detailed enough to be useful in practice.

@xingyaoww xingyaoww merged commit 3ef520c into main Apr 25, 2026
4 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants