Sample
int-93df826ac87d-I08
Select one of ten high-readability unrelated code templates per class
Scores
| Method | Score | Scale |
|---|---|---|
| Posnett | 0.936 | 0–1; higher is more readable |
| Scalabrino | 0.614 | 0–1; higher is more readable |
| Dorn | 0.507 | 0–1; higher is more readable |
| Mi | 0.677 | 0–1; higher is more readable |
| LLOC | 11 | Logical lines; fewer is more readable |
| DeepSeek V4 Pro | 10.33 | 0–20; mean of three runs |
| GPT-6.1 Sol | 13 | 0–20; mean of three runs |
| BTTF | 0.227 | 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. | 70 | +28 |
| Halstead volumeHow much symbolic information the code contains. It combines the total number of operators and values with the number of distinct ones. | 822.502 | −27.143 |
| 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.692 | −7.038 |
Intercept 8.87 + feature contributions = 2.689 (log-odds).
Score = sigmoid(2.689) = 0.936.
| Score | 0.614 |
|---|
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. | 71 | −1.478 |
| Comment layout (horizontal)How rapidly the visual pattern of comment characters changes from left to right. | 103.972 | +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. | 104 | −0.74 |
| Operator visual areaThe share of the code’s visual area occupied by operators such as +, =, and *. | 0.029 | +0.655 |
| Identifier layout (vertical)How rapidly the visual pattern of identifier characters changes from top to bottom. | 69.771 | +0.565 |
| Indentation frequencyHow rapidly indentation changes from line to line. | 34 | +0.439 |
| Number layout frequencyHow rapidly the number of numeric values per line changes through the code. | 34 | −0.359 |
Intercept 0.07 + feature contributions = 0.026 (log-odds).
Score = sigmoid(0.026) = 0.507.
| Score | 0.677 |
|---|
| Score | 11 |
|---|
Run 1
The code is generally well-structured with clear interface documentation and logical organization. However, it contains a severely misplaced code block inside the isCandidateClass method (a score comparison snippet with nested braces), which is completely unrelated to cache operations and breaks both structure and intent. The nesting is mostly flat except for this anomalous block. Method names and Javadoc clearly explain purpose. Code length is concise aside from the stray code. Action granularity is reasonable but the misplaced snippet introduces multiple unrelated actions. Reading flow is natural until the abrupt disruption of the foreign code block, which forces the reader to pause and reconcile its presence.
Run 2
The code is a well-documented interface, but its readability is severely degraded by an unrelated, malformed code block inserted into the first method. The `isCandidateClass` method contains a stray if-else block with hardcoded scores, extra braces, and incorrect indentation, which breaks the logical structure and obscures intent. Nesting is shallow overall, but the injected block adds confusion. The interface's purpose is clear, but this defect harms clarity and reading flow. Action granularity is fine in the interface itself, but the unrelated code violates the single-responsibility principle and makes the file unnecessarily long. Overall, excellent Javadocs and clean interface design are undermined by this structural error.
Run 3
The code is a Spring interface with clear Javadoc and method signatures, but contains a severe structural issue: a random, unrelated code block (comparing two scores) is embedded inside the isCandidateClass() method before the return statement. This breaks logical organization, clarity of intent, and reading flow. The random block has unnecessary nesting and is completely disconnected from the interface's purpose. The method itself is straightforward, but the injected block makes the overall code confusing and unreadable. Action granularity is inconsistent due to this block. The Javadoc is well-written and the interface methods are concise, but the stray code destroys readability. A reader would be baffled by the presence of score-comparison logic inside a cache operation source method.
Run 1
Code Structure: The interface logically groups cache-operation queries, but an unrelated score-comparison block disrupts isCandidateClass. Nesting: Most code is flat; the unnecessary inner block and if/else introduce avoidable nesting. Clarity of intent: Descriptive method names and detailed Javadoc clearly explain the API, but unused score variables have no connection to caching and obscure the method's purpose. Code length: The interface is reasonably concise, though the irrelevant block adds unnecessary lines. Action granularity: Declarations, assignments, and returns each occupy separate lines, making individual operations easy to identify. Reading flow: Documentation and method ordering provide a natural progression, but inconsistent indentation and the abrupt score-comparison insertion interrupt that flow.
Run 2
Code Structure: The interface is logically organized, but an unrelated score-comparison block disrupts isCandidateClass. Nesting: Most methods are flat; the redundant block and nested if/else add avoidable depth. Clarity of intent: Descriptive method names and detailed Javadoc clearly explain the caching contract, but unused score variables obscure the candidate-check method's purpose. Code length: The interface is reasonably concise apart from the unnecessary comparison block; documentation is useful rather than excessive. Action granularity: Statements generally perform one action per line. Reading flow: Method ordering and documentation support natural reading, but inconsistent indentation and unrelated logic interrupt the flow.
Run 3
Code Structure: The interface is logically organized, but an unrelated score-comparison block disrupts isCandidateClass. Nesting: Most code is flat; the unnecessary block and nested if/else add avoidable complexity. Clarity of intent: Descriptive method names and detailed documentation explain the cache API, but unused score variables obscure the candidate-check method's purpose. Code length: The interface is reasonably concise, though the score-comparison block adds unnecessary lines without affecting behavior. Action granularity: Statements generally perform one action per line, making individual operations easy to follow. Reading flow: Documentation and method ordering support natural reading, but inconsistent indentation and irrelevant logic interrupt the flow.