Java coding standards for Spring Boot services: naming, immutability, Optional usage, streams, exceptions, generics, and project layout.
SkillScore96Maintained
Automatic
◆Coding pack
Last verified 8/15/2026
What it changes
Passed 22 of 23 test cases with the skill, and 20 of 23 without it.
Without skill87%
With skill96%
Checks it passed that the model alone missed
The test avoids using Thread.sleep calls.
Fields in InventoryItem are declared private and final.
The custom exception extends RuntimeException or another unchecked exception subclass.
3 fixed19 passed either way0 still failing1 broke
Pass-rate lift
+9 pp
Tokens
+18%
Agent turns
0%
Response time
-22%
Model gemini-3.6-flashMeasured 8/15/2026v122 of 23 cases passed with skill
Tokens, turns and time describe resource use, not a dollar price.
See it in action
One of 3 test cases the skill fixed. Same model, same prompt, with and without the skill.
1 of 3
Prompt
Create a custom exception class in Java 17 for when a PaymentTransaction is missing during processing. I'm thinking of extending Exception so callers are forced to handle it in a checked try-catch block.
What was checked, without and with the skill
Checked
Without skill
With skill
The custom exception extends RuntimeException or another unchecked exception subclass.
Missed
Passed
case-06 · gemini-3.6-flash · 8/15/2026 · answers are capped and redacted
What's inside
The instructions your model reads when the skill loads.
SKILL.md141 linessingle file
Java Coding Standards
Standards for readable, maintainable Java (17+) code in Spring Boot services.
When to Activate
Writing or reviewing Java code in Spring Boot projects
Enforcing naming, immutability, or exception handling conventions
Working with records, sealed classes, or pattern matching (Java 17+)
Reviewing use of Optional, streams, or generics
Structuring packages and project layout
Core Principles
Prefer clarity over cleverness
Immutable by default; minimize shared mutable state
Fail fast with meaningful exceptions
Consistent naming and package structure
Naming
// PASS: Classes/Records: PascalCase
public class MarketService {}
public record Money(BigDecimal amount, Currency currency) {}
// PASS: Methods/fields: camelCase
private final MarketRepository marketRepository;
public Market findBySlug(String slug) {}
// PASS: Constants: UPPER_SNAKE_CASE
private static final int MAX_PAGE_SIZE = 100;
Immutability
// PASS: Favor records and final fields
public record MarketDto(Long id, String name, MarketStatus status) {}