CtrlK
BlogDocsLog inGet started
Tessl Logo
SkillPublic

refactor

Guides a refactor, cleanup, or restructure with the right decomposition. Use when the user asks to refactor, simplify, extract, or modernize code.

Quality

71%

Does it follow best practices?

Run evals on this skill

Adds up to 20 points to the overall score

View guide
SecuritybySnyk

Passed

No findings from the security scan

Fix and improve this skill with Tessl

tessl review fix ./plugins/omo/skills/refactor/SKILL.md
SKILL.md
Quality
Evals
Security

Quality

Content

62%Weight 40%Scale 1-5

Reviews the quality of instructions and guidance provided to agents. Good implementation is clear, handles edge cases, and produces reliable results.

The refactoring workflow itself is a model of clarity: six phases with mandatory validation checkpoints, failure recovery, baseline capture, and abort conditions. However, the skill is severely bloated by a repetitive harness-compatibility preamble and two full embedded documents inlined into a single file with no progressive disclosure, and the agent examples require nontrivial translation to be executable.

Suggestions

Move the Codex/OpenCode tool-compatibility table and the Team Mode Protocol into separate reference files (e.g., references/harness-compatibility.md, references/team-mode.md) linked from a short overview, cutting the main body to a lean phase guide.

Deduplicate the routing rules: state "If a code block below conflicts with this section, this section wins" once and consolidate the multi_agent_v1/v2 guidance into a single compact table instead of repeated prose paragraphs.

Rewrite the Phase 1/3/4 agent examples directly in the target harness's tool syntax (or a single canonical form) so they are executable without the reader mentally applying the translation table.

DimensionReasoningScore

Conciseness

The ~780-line body is noticeably verbose: "If a code block below conflicts with this section, this section wins" is repeated three times, the Codex routing paragraphs restate V1/V2 rules across multiple dense blocks, and the template ends with motivational padding ("Remember: Refactoring without tests is reckless..."). It avoids explaining basic concepts Claude already knows, so it sits at anchor 2 rather than 1.

2 / 5

Actionability

Concrete executable commands appear throughout: `python3 scripts/ast_grep_helper.py search 'function $NAME($$$) { $$$ }' src/ --lang ts`, `sg --pattern '[old_pattern]' --rewrite '[new_pattern]' --lang ts src/`, `tsc --noEmit`, LSP call signatures, and git commit templates. Minor gaps remain: agent examples use OpenCode-only tools that must be mentally translated per the preamble, and the ast-grep helper script lives in another skill's directory (honestly flagged as "this skill ships no scripts/"), matching anchor 4 rather than fully copy-paste-ready 5.

4 / 5

Workflow Clarity

Phases 0-6 are explicitly sequenced with per-phase todos and mandatory post-step verification ("1. lsp_diagnostics → zero new errors / 2. Run test command → all pass / 3. Type check → clean"), a failure-recovery protocol (STOP → REVERT → DIAGNOSE → OPTIONS), a coverage-based verification strategy table, pre-change baseline capture, abort conditions, and commit checkpoints. Explicit validation with feedback loops and checklists matches anchor 5; anchor 4's "most checkpoints" understates the completeness.

5 / 5

Progressive Disclosure

No bundle files exist (references/, scripts/, assets/ are all absent), so everything lives in one ~780-line SKILL.md, including two large embedded documents — the full REFACTOR_TEMPLATE and the REFACTOR_TEAM_MODE_ADDENDUM — that clearly belong in separate reference files. Internal section structure is good, matching anchor 3 ("content that should be separate is inline") rather than anchor 2's "minimal structure".

3 / 5

Total

14

/

20

Passed

Description

70%Weight 40%Scale 1-5

Based on the skill's description, can an agent find and select it at the right time? Clear, specific descriptions lead to better discovery.

The description is well-formed with an explicit and natural "Use when..." trigger clause covering multiple user phrasings, and it stays concise in third person. Its main weakness is specificity: the capability statement is abstract ("with the right decomposition") and never conveys what the skill concretely does, and a couple of trigger terms risk overlap with adjacent code-quality skills.

Suggestions

Replace "with the right decomposition" with 2-3 concrete capabilities, e.g., "Maps dependencies and test coverage, plans atomic refactoring steps, and verifies each step against the test suite."

Add natural trigger variations users commonly say, such as "clean up", "tidy", or "reduce complexity in" code, to broaden matching without adding length.

Consider dropping or qualifying the broadest trigger verbs ("simplify", "extract") or pairing them with "code" consistently to reduce collision with code-review and cleanup skills.

DimensionReasoningScore

Specificity

"Guides a refactor, cleanup, or restructure with the right decomposition" names the domain and lists task variants, but "guides... with the right decomposition" is abstract and no concrete capabilities (e.g., dependency mapping, test-coverage gating, staged verification) are stated. It matches anchor 3 (domain plus 1-2 actions) rather than 4, which requires several specific listed actions.

3 / 5

Completeness

Both parts are present: the what ("Guides a refactor, cleanup, or restructure with the right decomposition") and an explicit when ("Use when the user asks to refactor, simplify, extract, or modernize code"). The when clause is explicit with concrete triggers, but the what is thin on what the skill actually does, matching anchor 4 rather than 5.

4 / 5

Trigger Term Quality

Trigger terms "refactor, simplify, extract, or modernize code" plus "cleanup, or restructure" give good natural-keyword coverage users would actually say. Common variations like "clean up code", "tidy", "reduce complexity", or "DRY" are missing, so it matches anchor 4 rather than 5's comprehensive synonym coverage.

4 / 5

Distinctiveness Conflict Risk

"refactor", "restructure", and "modernize" establish a clear niche, but "simplify" and "extract" are generic coding verbs that could overlap with code-review or general cleanup skills. This is minor overlap with closely related skills (anchor 4) rather than the minimal-conflict clarity of anchor 5.

4 / 5

Total

15

/

20

Passed

Validation

81%

Checks the skill against the spec for correct structure and formatting. All validation checks must pass before discovery and implementation can be scored.

Validation — 13 / 16 Passed

Validation for skill structure

CriteriaDescriptionResult

skill_md_line_count

SKILL.md is long (780 lines); consider splitting into references/ and linking

Warning

frontmatter_unknown_keys

Unknown frontmatter key(s) found; consider removing or moving to metadata

Warning

referenced_paths_exist

Referenced path issues: 2 missing

Warning

Total

13

/

16

Passed

Repository

code-yeongyu/lazycodex

Path

plugins/omo/skills/refactor/SKILL.md

Reviewed

Table of Contents

Is this your skill?

If you maintain this skill, you can claim it as your own. Once claimed, you can manage eval scenarios, bundle related skills, attach documentation or rules, and ensure cross-agent compatibility.