Sample
int-ec4fc14423fb-I02
Shorten method, parameter, and local names without collisions
Scores
| Method | Score | Scale |
|---|---|---|
| Posnett | 0.995 | 0–1; higher is more readable |
| Scalabrino | 0.655 | 0–1; higher is more readable |
| Dorn | 0.789 | 0–1; higher is more readable |
| Mi | 0.61 | 0–1; higher is more readable |
| LLOC | 5 | Logical lines; fewer is more readable |
| DeepSeek V4 Pro | 16.67 | 0–20; mean of three runs |
| GPT-6.1 Sol | 14.67 | 0–20; mean of three runs |
| BTTF | 0.75 | 0–1; higher is more readable |
Views
Loading feature diagnosis…
Source regions
Feature contributions
Feature contributions
| Feature | Value | Contribution (log-odds) |
|---|---|---|
| Source linesThe number of non-empty source lines. | 59 | +23.6 |
| Halstead volumeHow much symbolic information the code contains. It combines the total number of operators and values with the number of distinct ones. | 609.596 | −20.117 |
| Byte entropyHow varied the bytes in the source text are. Repeated bytes give a lower value; a more even mixture gives a higher value. | 4.681 | −7.022 |
Intercept 8.87 + feature contributions = 5.331 (log-odds).
Score = sigmoid(5.331) = 0.995.
| Score | 0.655 |
|---|
Feature contributions
| Feature | Value | Contribution (log-odds) |
|---|---|---|
| Comment layout frequencyHow frequently the layout switches between lines containing only comments or whitespace and lines containing code. | 57 | −0.982 |
| Operator visual areaThe share of the code’s visual area occupied by operators such as +, =, and *. | 0.025 | +0.7 |
| Comment layout (horizontal)How rapidly the visual pattern of comment characters changes from left to right. | 81.567 | +0.512 |
| Identifier layout (vertical)How rapidly the visual pattern of identifier characters changes from top to bottom. | 58.893 | +0.413 |
| Number layout frequencyHow rapidly the number of numeric values per line changes through the code. | 1 | +0.398 |
| Identifier layout (horizontal)How rapidly the visual pattern of identifier characters changes from left to right. It measures spatial frequency, not the meaning of the names. | 82.967 | +0.151 |
| Indentation frequencyHow rapidly indentation changes from line to line. | 23 | +0.058 |
Intercept 0.07 + feature contributions = 1.321 (log-odds).
Score = sigmoid(1.321) = 0.789.
| Score | 0.61 |
|---|
| Score | 5 |
|---|
Run 1
The code is a well-structured Spring interface with clear Javadoc. It maintains a flat structure with no deep nesting, and each method serves a clear purpose: is(), has(), and get() for cache operation detection. The naming is mostly consistent, though the parameter names 'target', 'target2', 'target3', 'met', and 'met2' introduce slight ambiguity compared to the documented parameters 'targetClass' and 'method'. The default methods are concise, and action granularity is appropriate. Reading flow is natural, with documentation preceding each method. Minor readability deduction comes from the inconsistent parameter naming, which could confuse a reader attempting to trace the flow from documentation to implementation, and the somewhat terse method names like 'is' and 'has' which rely heavily on documentation to convey intent.
Run 2
The code is well-structured and readable as a Spring interface. It has clear separation of methods, good Javadoc documentation, and flat nesting with no complex logic. Intent is explicit through method names and documentation. However, parameter names like 'met', 'met2', 'target2', and 'target3' are unnecessarily abbreviated and inconsistent, which slightly reduces clarity. The method names 'is' and 'has' are also very generic without context. Default method bodies are appropriately concise. Overall, the code is maintainable and clear but could benefit from more descriptive parameter naming.
Run 3
The code is highly readable due to its clear logical structure as an interface with well-documented default methods. Nesting is minimal, with no deep blocks. Intent is explicit through descriptive method names and comprehensive Javadoc explaining purpose, parameters, and return values. Code length is concise, containing only necessary methods and defaults. Action granularity shows one action per line in method bodies. Reading flow is natural, progressing logically from class-level checks to method-level checks to retrieving operations. Minor deductions: parameter names like 'target2', 'target3', 'met', and 'met2' are slightly awkward and could be more descriptive, and the default method 'is' name is a bit terse. Overall, it adheres well to Spring's documentation standards and maintains excellent clarity.
Run 1
Code Structure: The interface is logically organized into three related operations, although imports lack visual separation. Nesting: Flat methods with no nested control flow are easy to follow. Clarity of intent: Documentation explains the caching contract, but vague method names (is, has, get) and inconsistent parameter names (met, met2, target2, target3) obscure meaning. Javadoc parameter names and method references do not match the declarations, creating confusion. Code length: Implementations are concise; extensive documentation is mostly useful but disproportionate to the small interface. Action granularity: Each method performs a single operation, with no crowded multi-action lines. Reading flow: The progression from class eligibility to operation existence to retrieval is natural, but naming inconsistencies and stale documentation interrupt comprehension.
Run 2
Code Structure: The interface is logically organized, with two default helpers followed by the core operation lookup declaration. Nesting: There is no nested control flow, making implementation easy to scan. Clarity of intent: Documentation explains the caching contract, but vague method names (is, has, get) and parameter names (met, met2, target2, target3) obscure meaning. Javadoc parameter names do not match actual signatures, and references to getCacheOperations and hasCacheOperations do not match declared methods. Code length: Implementations are concise; extensive documentation is mostly useful but disproportionate to the small interface. Action granularity: Each implementation contains a single, clearly separated return action. Reading flow: Declaration order is natural, but missing spacing around imports and inconsistencies between documentation and signatures interrupt an otherwise straightforward reading experience.
Run 3
Code Structure: The interface is logically organized into candidate detection, operation checking, and retrieval. Nesting: Methods are flat, with no nested control flow. Clarity of intent: Detailed documentation explains the caching contract, but generic names such as is, has, and get, and parameters met2 and target3 obscure meaning. Documentation references and @param names do not match the actual declarations, creating confusion. Code length: Implementation is concise; documentation is lengthy but mostly useful. Action granularity: Each method performs a single action, and statements are clearly separated. Reading flow: The method order is natural, but mismatched documentation and missing spacing between package and import sections weaken an otherwise straightforward presentation.