Sample
int-502a3a6cb3e8-SRC
Unmodified source class
Scores
| Method | Score | Scale |
|---|---|---|
| Posnett | 0.997 | 0–1; higher is more readable |
| Scalabrino | 0.643 | 0–1; higher is more readable |
| Dorn | 0.69 | 0–1; higher is more readable |
| Mi | 0.628 | 0–1; higher is more readable |
| LLOC | 5 | Logical lines; fewer is more readable |
| DeepSeek V4 Pro | 18.33 | 0–20; mean of three runs |
| GPT-6.1 Sol | 19 | 0–20; mean of three runs |
| BTTF | 0.807 | 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. | 598.547 | −19.752 |
| 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.676 | −7.014 |
Intercept 8.87 + feature contributions = 5.704 (log-odds).
Score = sigmoid(5.704) = 0.997.
| Score | 0.643 |
|---|
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 |
| Comment layout (horizontal)How rapidly the visual pattern of comment characters changes from left to right. | 103.967 | +0.873 |
| 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. | 103.983 | −0.739 |
| Operator visual areaThe share of the code’s visual area occupied by operators such as +, =, and *. | 0.024 | +0.708 |
| Identifier layout (vertical)How rapidly the visual pattern of identifier characters changes from top to bottom. | 58.81 | +0.412 |
| Number layout frequencyHow rapidly the number of numeric values per line changes through the code. | 1 | +0.398 |
| Indentation frequencyHow rapidly indentation changes from line to line. | 23 | +0.058 |
Intercept 0.07 + feature contributions = 0.799 (log-odds).
Score = sigmoid(0.799) = 0.69.
| Score | 0.628 |
|---|
| Score | 5 |
|---|
Run 1
This is a very readable interface definition. The structure is logical, with clear method separation and well-organized Javadoc. Nesting is minimal. The intent of each method is immediately clear from names like isCandidateClass and getCacheOperations. Code length is appropriate—not unnecessarily verbose—and the Javadoc provides useful context without being excessive. Action granularity is clean, with simple return statements and no complex operations. Reading flow is natural, progressing from class-level candidate checks to method-level operation retrieval. The only minor deductions are for slightly dense Javadoc blocks on default methods, which could be slightly condensed, but overall this is exemplary code readability.
Run 2
The code demonstrates excellent readability through a clear interface contract, logical method ordering, and comprehensive Javadoc documentation. Structure is highly organized: one top-level interface with two default methods and one abstract method, each serving a distinct purpose. Nesting is completely flat, with no conditionals or loops. Intent is unambiguous—each method’s role (candidate check, presence check, retrieval) is well-defined and named descriptively. Code length is appropriate for an API contract; Javadoc adds necessary context without bloating logic. Action granularity is ideal, with single-purpose lines and simple return statements. Reading flow is natural: candidate detection, then presence check, then retrieval, mirroring a logical progression from broad to specific introspection. The only minor deduction is the slightly verbose Javadoc, but this is justified for a framework-level interface.
Run 3
This is a well-structured Spring interface. The code has a clear single responsibility: defining a contract for cache operation metadata. It uses flat nesting with only interface-level methods, each performing one logical action. The Javadoc is thorough and explains intent, preconditions, and return values clearly, including @since tags and nullability annotations. Method names are descriptive (e.g., isCandidateClass, hasCacheOperations). Default methods are concise and reusable. Reading flow is natural due to consistent ordering of documentation before each method and logical grouping of related operations. Minor deductions: the extensive Javadoc adds length, and the parameter name 'targetClass' repeats across methods, but this is standard for clarity. Overall, highly readable with no unnecessary complexity.
Run 1
Code Structure: A focused interface logically groups candidate detection, operation checking, and retrieval. Nesting: Flat method bodies contain no conditional or loop nesting. Clarity of intent: Descriptive names, explicit nullability annotations, and detailed Javadocs clearly explain the contract and default behavior. Code length: Executable code is concise; documentation is useful but somewhat verbose relative to the implementation. Action granularity: Each statement performs one clear action, with the composed emptiness check remaining easy to understand. Reading flow: Methods progress naturally from class-level screening to method-level checking and retrieval. Minor formatting limitations, such as missing spacing between package and import sections, slightly reduce visual readability.
Run 2
Code Structure: A focused interface with logically ordered candidate checking, operation checking, and operation retrieval. Nesting: Flat, with no nested control flow. Clarity of intent: Descriptive method names, explicit nullability annotations, and detailed Javadoc clearly communicate purpose and contracts. Code length: Implementation is minimal; documentation is somewhat verbose but provides useful API context. Action granularity: Each implementation contains a single return statement, with no unrelated actions combined. Reading flow: Consistent formatting and progression from broad class filtering to method-level retrieval make the code easy to follow. Minor readability drawbacks are the lack of spacing between import groups and the relatively long retrieval declaration.
Run 3
Code Structure: A well-organized interface groups three closely related cache-operation methods, with clear separation between declarations. Nesting: Default implementations are flat and contain no nested control flow. Clarity of intent: Descriptive method names, explicit nullability annotations, and thorough Javadoc clearly explain behavior and contracts. Code length: Executable code is minimal; documentation is somewhat lengthy but provides useful API context. Action granularity: Each implementation performs a single, focused action, with one return statement per line. Reading flow: The progression from class-level candidacy to method-level existence checks and operation retrieval is natural. Minor formatting improvements, such as separating the package declaration and import groups with blank lines, would improve scanning.