Sample
int-90578299712c-SRC
Unmodified source class
Scores
| Method | Score | Scale |
|---|---|---|
| Posnett | 0 | 0–1; higher is more readable |
| Scalabrino | 0.692 | 0–1; higher is more readable |
| Dorn | 0.752 | 0–1; higher is more readable |
| Mi | 0.705 | 0–1; higher is more readable |
| LLOC | 53 | Logical lines; fewer is more readable |
| DeepSeek V4 Pro | 17.67 | 0–20; mean of three runs |
| GPT-6.1 Sol | 19 | 0–20; mean of three runs |
| BTTF | 0.601 | 0–1; higher is more readable |
Views
Loading feature diagnosis…
Source regions
Feature contributions
Feature contributions
| Feature | Value | Contribution (log-odds) |
|---|---|---|
| Halstead volumeHow much symbolic information the code contains. It combines the total number of operators and values with the number of distinct ones. | 3874.457 | −127.857 |
| Source linesThe number of non-empty source lines. | 146 | +58.4 |
| 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.667 | −7.001 |
Intercept 8.87 + feature contributions = -67.588 (log-odds).
Score = sigmoid(-67.588) = 0.
| Score | 0.692 |
|---|
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. | 147 | −4.168 |
| Indentation frequencyHow rapidly indentation changes from line to line. | 113 | +3.171 |
| Identifier layout (vertical)How rapidly the visual pattern of identifier characters changes from top to bottom. | 145.554 | +1.625 |
| Comment layout (horizontal)How rapidly the visual pattern of comment characters changes from left to right. | 99.946 | +0.808 |
| 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. | 99.966 | −0.569 |
| Number layout frequencyHow rapidly the number of numeric values per line changes through the code. | 1 | +0.398 |
| Operator visual areaThe share of the code’s visual area occupied by operators such as +, =, and *. | 0.12 | −0.224 |
Intercept 0.07 + feature contributions = 1.111 (log-odds).
Score = sigmoid(1.111) = 0.752.
| Score | 0.705 |
|---|
| Score | 53 |
|---|
Run 1
The code is highly readable due to its consistent and logical structure. It follows a standard delegation pattern where each method is a single, clear delegation to the abstract delegate() method, making the intent immediately obvious. There is minimal nesting, no conditional complexity, and each line performs one action. The ordering of methods groups related functionality (nodes, edges, degree, edge connectivity), which aids the natural reading flow. The only minor drawback is code length—while repetitive, this is inherent to forwarding classes and not a sign of poor readability. Overall, it is very clear and maintainable.
Run 2
The code is highly readable. It follows a clear, consistent structure where each method simply delegates to an abstract delegate() method, making the intent unambiguous. The class is flat with no nesting, and each method performs exactly one action (delegation), adhering to good action granularity. Method ordering appears logical, grouping related functionality (nodes, edges, connectivity). Although the class is long, the length is justified by the interface implementation and does not introduce complexity. The reading flow is natural, with a clear pattern that is easy to scan. Minor deductions could be made for the repetitive boilerplate nature and the slightly unusual import of Optional/Nullable, but these do not significantly hinder readability.
Run 3
The code demonstrates excellent readability through its flat, consistent structure. Each method follows an identical one-line delegation pattern, making it highly predictable and easy to scan. The class has a clear single purpose: forwarding calls to a delegate object. Method grouping follows a logical progression (basic properties, node operations, edge operations, connectivity queries). No nesting exists beyond the class itself, and naming is explicit and self-documenting. The absence of additional logic keeps the code concise despite many methods. The abstract delegate() method clearly signals the extension point. Javadoc and annotations add useful context without clutter. Minor deductions only for slight repetition and lack of inner grouping comments.
Run 1
Code Structure: Well-organized forwarding class with related methods and overloads grouped together. Nesting: Flat method bodies with no conditional or loop nesting. Clarity of intent: Class documentation, descriptive method names, and consistent delegation make its purpose immediately clear. Code length: Long due to required forwarding boilerplate, but each method is minimal and contains no unnecessary logic. Action granularity: Each method performs one forwarding action in a single return statement. Reading flow: Consistent formatting and predictable method patterns make scanning easy, although the repetitive boilerplate slightly increases reading effort.
Run 2
Code Structure: Logically organized forwarding methods, with related operations and overloads grouped together. Nesting: Flat method bodies with no conditional or loop nesting. Clarity of intent: The class documentation, descriptive method names, and consistent delegate() calls clearly establish its forwarding purpose. Code length: The class is lengthy and repetitive, but each method is minimal; most repetition is necessary to implement the forwarding interface explicitly. Action granularity: Each method contains a single return statement performing one clear forwarding operation. Reading flow: Consistent formatting, annotations, and method patterns make the code easy to scan and predict. Minor drawbacks are boilerplate volume and the lack of spacing between the package declaration and imports.
Run 3
Code Structure: Well-organized forwarding class with related methods and overloads grouped together. Nesting: Flat method bodies with no conditional or loop nesting. Clarity of intent: The class documentation, descriptive method names, and consistent delegate calls make its purpose immediately clear. Code length: Long but largely justified by the interface's forwarding requirements; repetition adds scanning overhead without unnecessary complexity. Action granularity: Each method contains a single return statement performing one clear forwarding operation. Reading flow: Consistent formatting, annotations, and predictable method patterns make the code easy to follow. Minor drawbacks are repetitive boilerplate and the lack of spacing between the package declaration and imports.