Sample
int-9de467873d89-SRC
Unmodified source class
Scores
| Method | Score | Scale |
|---|---|---|
| Posnett | 0.046 | 0–1; higher is more readable |
| Scalabrino | 0.853 | 0–1; higher is more readable |
| Dorn | 0.766 | 0–1; higher is more readable |
| Mi | 0.382 | 0–1; higher is more readable |
| LLOC | 15 | Logical lines; fewer is more readable |
| DeepSeek V4 Pro | 18 | 0–20; mean of three runs |
| GPT-6.1 Sol | 19 | 0–20; mean of three runs |
| BTTF | 0.687 | 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. | 1135.35 | −37.467 |
| Source linesThe number of non-empty source lines. | 82 | +32.8 |
| 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.828 | −7.241 |
Intercept 8.87 + feature contributions = -3.038 (log-odds).
Score = sigmoid(-3.038) = 0.046.
| Score | 0.853 |
|---|
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. | 83 | −1.902 |
| Indentation frequencyHow rapidly indentation changes from line to line. | 57 | +1.234 |
| Comment layout (horizontal)How rapidly the visual pattern of comment characters changes from left to right. | 98.699 | +0.788 |
| Identifier layout (vertical)How rapidly the visual pattern of identifier characters changes from top to bottom. | 81.832 | +0.734 |
| 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.88 | −0.565 |
| Operator visual areaThe share of the code’s visual area occupied by operators such as +, =, and *. | 0.053 | +0.431 |
| Number layout frequencyHow rapidly the number of numeric values per line changes through the code. | 1 | +0.398 |
Intercept 0.07 + feature contributions = 1.188 (log-odds).
Score = sigmoid(1.188) = 0.766.
| Score | 0.382 |
|---|
| Score | 15 |
|---|
Run 1
The code is highly readable. It clearly documents the interface's purpose, its deviation from the DataInput contract, and the rationale for @CanIgnoreReturnValue annotations on each method. The structure is logical: imports, Javadoc, interface declaration, then method overrides grouped with consistent comments. Nesting is minimal—only package and interface-level. Clarity of intent is strong, especially with the warning about IllegalStateException and the guidance on skipBytes. Code length is appropriate; the repetitive annotations are concise and informative. Each method declaration is on a single line, maintaining one-action-per-line granularity. Reading flow is natural and consistent, making it easy to scan method signatures and understand each one's purpose. Minor deductions: some readers might find the repeated inline comments slightly verbose, but they serve an explicit purpose here.
Run 2
The code is highly readable due to its clear structure and purpose. It is well-organized with a logical grouping of imports, a descriptive Javadoc explaining the contract deviation, and a flat, consistent method list. Each method is concise, with one action per line, and the repeated @CanIgnoreReturnValue annotations with comments clarify intent for skipping data. Nesting is minimal, and the reading flow is natural. Minor deductions include verbosity from repeated annotations and slight comment redundancy, but overall it is excellent.
Run 3
The code is highly readable. Structure is clear and logical for an interface extending DataInput, with well-organized imports and Javadoc. Nesting is non-existent (flat). Intent is explicitly documented, including the important deviation from the contract regarding exceptions. Code length is minimal and appropriate, avoiding unnecessary implementation details. Action granularity is one declaration per line, aided by repeated @CanIgnoreReturnValue annotations with concise comments explaining the rationale for skipping return values. Reading flow is natural, grouping related overrides together. Minor deductions: the interface is somewhat verbose due to repeated annotations and comments, and the lack of blank lines between method groups could slightly improve visual separation, but overall readability is excellent.
Run 1
Code Structure: A logically organized interface with consistent method declarations and annotations. Nesting: Flat, with no nested control flow. Clarity of intent: The Javadoc clearly explains the interface's purpose, exception behavior, and caller responsibilities; standard DataInput method names are recognizable. Code length: Appropriate for the interface, although repeated annotations and skip comments add minor visual repetition. Action granularity: Each method declaration occupies its own line, with annotations clearly associated with it. Reading flow: Consistent spacing and ordering make scanning natural. Minor drawbacks include abbreviated parameter names and the lack of separation between the package declaration and imports.
Run 2
Code Structure: A well-organized interface with consistently formatted method declarations and related operations grouped naturally. Nesting: Flat, with no nested control flow. Clarity of intent: The interface name, familiar DataInput methods, and documentation clearly explain its purpose and exception behavior; abbreviated parameters such as b and off are minor weaknesses. Code length: Concise for the API it defines; repeated annotations and comments add some visual repetition but communicate useful contracts. Action granularity: Each declaration occupies its own line, with annotations clearly associated with individual methods. Reading flow: Proceeds naturally from the interface contract through bulk reads, skipping, primitive reads, and string reads. Minor spacing omissions around the package and imports slightly reduce visual separation.
Run 3
Code Structure: A well-organized interface with related read methods grouped logically and consistent annotation placement. Nesting: Completely flat apart from the interface scope, making scanning easy. Clarity of intent: The documentation clearly explains the purpose, exception behavior, and caller responsibilities; standard method names communicate operations well, though abbreviated parameter names are less descriptive. Code length: Concise for the API it defines; repeated annotations and comments add some visual bulk but convey useful contracts. Action granularity: Each method declaration occupies its own line, with no combined operations. Reading flow: Natural progression from bulk reads and skipping to primitive reads and strings, supported by consistent spacing. Minor formatting issues, such as the lack of separation between the package and imports, slightly reduce polish.