Sample
int-a6f135310183-SRC
Unmodified source class
Scores
| Method | Score | Scale |
|---|---|---|
| Posnett | 0.996 | 0–1; higher is more readable |
| Scalabrino | 0.939 | 0–1; higher is more readable |
| Dorn | 0.795 | 0–1; higher is more readable |
| Mi | 0.687 | 0–1; higher is more readable |
| LLOC | 27 | 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.72 | 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. | 128 | +51.2 |
| Halstead volumeHow much symbolic information the code contains. It combines the total number of operators and values with the number of distinct ones. | 1427.996 | −47.124 |
| 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.888 | −7.331 |
Intercept 8.87 + feature contributions = 5.615 (log-odds).
Score = sigmoid(5.615) = 0.996.
| Score | 0.939 |
|---|
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. | 123 | −3.319 |
| Indentation frequencyHow rapidly indentation changes from line to line. | 74 | +1.822 |
| Identifier layout (vertical)How rapidly the visual pattern of identifier characters changes from top to bottom. | 127.781 | +1.376 |
| Comment layout (horizontal)How rapidly the visual pattern of comment characters changes from left to right. | 94.961 | +0.728 |
| Operator visual areaThe share of the code’s visual area occupied by operators such as +, =, and *. | 0.032 | +0.635 |
| 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. | 94.953 | −0.357 |
Intercept 0.07 + feature contributions = 1.354 (log-odds).
Score = sigmoid(1.354) = 0.795.
| Score | 0.687 |
|---|
| Score | 27 |
|---|
Run 1
The code is highly readable. It follows a clear, logical structure with a simple class definition and well-organized fields at the top. Nesting is minimal, with only simple getter/setter methods and no deep conditional blocks. Each method's intent is immediately obvious from its name and Javadoc. The code is concise but not overly dense, with each setter/getter performing a single, clear action. Reading flow is natural: fields first, then logical grouping of paired methods, each preceded by descriptive documentation. The only minor complexity is the null-handling ternary in some setters, but it is clear and appropriate. Overall, this is exemplary Java code.
Run 2
The code is highly readable with clear logical organization: fields, setters, and getters follow a consistent pattern. Nesting is minimal (only simple ternary expressions in two setters). Intent is unambiguous through descriptive names and thorough Javadoc comments explaining purpose and constraints. Code length is appropriate — each method is concise, though Javadocs add bulk, they improve maintainability. Action granularity is excellent: one action per line, with single return statements. Reading flow is natural, following standard JavaBean conventions from field declaration to accessor methods. Minor deductions: the ternary expressions slightly reduce readability compared to an if-statement, and the class lacks a toString/hashCode/equals implementation, but these don't significantly impact the score.
Run 3
The code is highly readable. It has a clear, logical structure with a single class containing private fields and straightforward getter/setter pairs. Nesting is minimal—only a single ternary expression per setter for init/destroy method names. Intent is unambiguous due to descriptive names and thorough Javadoc. Code length is appropriate, avoiding unnecessary repetition while maintaining clarity. Most lines perform a single action, enhancing readability. Reading flow is natural, grouping related fields and methods in a consistent order. Minor deductions: ternary conditions could be slightly clearer with a helper or explicit if statements, but this is a very minor style point.
Run 1
Code Structure: Fields precede logically paired setters and getters, producing a well-organized defaults holder. Nesting: Methods are flat, with only simple boolean and ternary expressions. Clarity of intent: Descriptive names, explicit default constants, nullable annotations, and informative Javadoc clearly explain behavior, including the distinction between unset and false lazy initialization. Code length: Implementation is concise; extensive documentation and repeated accessor boilerplate add some length but mostly support understanding. Action granularity: Each statement performs one clear assignment or return; string normalization remains compact and readable. Reading flow: Consistent formatting and predictable method ordering make navigation natural. Minor verbosity and redundant expression parentheses slightly reduce an otherwise excellent readability score.
Run 2
Code Structure: Fields are grouped first, followed by consistently paired setters and getters, providing clear organization. Nesting: Methods are flat, with no nested control flow. Clarity of intent: Descriptive names, explicit defaults, nullable annotations, and helpful Javadoc clearly explain the holder's purpose and property semantics, including the distinction between unset and false lazy initialization. Code length: Implementations are concise; extensive documentation and repetitive accessors add length but are largely justified. Action granularity: Each statement performs a single assignment or return; the simple conditional expressions remain easy to understand. Reading flow: Consistent formatting and predictable method ordering make scanning natural. Minor readability costs come from verbose documentation and integer-based modes whose meanings require consulting external constants.
Run 3
Code Structure: Fields are grouped first, followed by logically paired setters and getters. Nesting: Methods are flat, with no nested control flow. Clarity of intent: Descriptive names, explicit defaults, nullable annotations, and helpful Javadoc clearly communicate behavior, including unset versus false lazy initialization. Code length: Implementation is concise; extensive documentation and repetitive accessors add length but mostly support understanding. Action granularity: Each statement performs one assignment or return; the simple ternary expressions remain easy to read. Reading flow: Consistent formatting and predictable method ordering allow natural top-to-bottom reading. Minor drawbacks are documentation verbosity and integer-based modes that require consulting external constants.