CtrlK
BlogDocsLog inGet started
Tessl Logo

141-java-refactoring-with-modern-features

Use when you need to refactor Java code to adopt modern Java features (Java 8+) — including migrating anonymous classes to lambdas, replacing Iterator loops with Stream API, adopting Optional for null safety, switching from legacy Date/Calendar to java.time, using collection factory methods, applying text blocks, var inference, or leveraging Java 25 features like flexible constructor bodies and module import declarations. This should trigger for requests such as Review Java code for modern Java development; Apply best practices for modern Java development in Java code; Modernize Java code with records pattern matching or switch expressions; Replace legacy idioms with modern Java features; Adopt Java 8+ language features safely. Part of Plinth Toolkit

72

Quality

88%

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

SKILL.md
Quality
Evals
Security

Quality

Content

85%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.

Well-structured body with a clear validation-gated workflow and clean one-level progressive disclosure. The main improvement would be folding the duplicated compile/verify commands so they appear once and optionally showing one inline refactoring example.

Suggestions

State the compile/verify commands once (e.g. only in the Workflow) and reference them from Constraints to remove the verbatim duplication.

Add one short inline good/bad example (e.g. anonymous class to lambda) so the skill is actionable without immediately opening the reference.

DimensionReasoningScore

Conciseness

The body is lean and assumes Claude's Java knowledge, but the compile/verify commands are stated in both the Constraints section and again verbatim in the Workflow steps, a minor redundancy that keeps it just below the leanest anchor.

4 / 5

Actionability

Provides concrete, executable commands ('./mvnw compile', 'mvn clean verify') and a specific reference path, but the actual refactoring techniques are delegated to the reference file with no inline code examples, leaving minor gaps.

4 / 5

Workflow Clarity

A clear four-step sequence with explicit validation checkpoints — compile before changes, stop immediately on failure, verify after — and a feedback loop ('If compilation fails, stop immediately'), satisfying the destructive/batch validation requirement.

5 / 5

Progressive Disclosure

SKILL.md is a concise overview that points to a single one-level-deep reference, signaled clearly both in the Workflow ('Read references/...') and a dedicated Reference section with a linked path; the reference file exists and is well-organized.

5 / 5

Total

18

/

20

Passed

Description

92%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.

A strong, specific description that enumerates concrete capabilities and provides explicit trigger guidance with natural user phrases. Minor room to add a few more synonyms for trigger terms.

DimensionReasoningScore

Specificity

Lists multiple concrete refactoring actions — 'migrating anonymous classes to lambdas', 'replacing Iterator loops with Stream API', 'adopting Optional for null safety', 'switching from legacy Date/Calendar to java.time', 'applying text blocks, var inference' — giving comprehensive coverage of the domain.

5 / 5

Completeness

Explicitly answers both 'what' (the enumerated refactoring actions) and 'when' via the 'Use when you need to refactor Java code...' clause plus the 'This should trigger for requests such as' list of concrete trigger phrases.

5 / 5

Trigger Term Quality

Includes natural user phrases like 'Review Java code for modern Java development', 'Modernize Java code with records pattern matching or switch expressions', and 'Replace legacy idioms with modern Java features'; good coverage but a few natural synonyms (e.g. 'upgrade', 'clean up') are missing, so it sits just below the comprehensive anchor.

4 / 5

Distinctiveness Conflict Risk

Occupies a clear niche — modern Java (Java 8+) refactoring with specific version markers (Java 25 FCB, module import declarations) — making it unlikely to trigger for unrelated skills.

5 / 5

Total

19

/

20

Passed

Validation

100%

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

Validation16 / 16 Passed

Validation for skill structure

No warnings or errors.

Repository
jabrena/plinth
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.