Sample
int-c573c67d6dcd-I10
Remove about 40% of line-break groups while retaining structure
Scores
| Method | Score | Scale |
|---|---|---|
| Posnett | 0 | 0–1; higher is more readable |
| Scalabrino | 0.476 | 0–1; higher is more readable |
| Dorn | 0.029 | 0–1; higher is more readable |
| Mi | 0.007 | 0–1; higher is more readable |
| LLOC | 56 | Logical lines; fewer is more readable |
| DeepSeek V4 Pro | 4.67 | 0–20; mean of three runs |
| GPT-6.1 Sol | 11 | 0–20; mean of three runs |
| BTTF | 0.297 | 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. | 5431.521 | −179.24 |
| Source linesThe number of non-empty source lines. | 109 | +43.6 |
| Byte entropyHow varied the bytes in the source text are. Repeated bytes give a lower value; a more even mixture gives a higher value. | 5.1 | −7.65 |
Intercept 8.87 + feature contributions = -134.42 (log-odds).
Score = sigmoid(-134.42) = 0.
| Score | 0.476 |
|---|
Feature contributions
| Feature | Value | Contribution (log-odds) |
|---|---|---|
| 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. | 206.964 | −5.101 |
| Comment layout frequencyHow frequently the layout switches between lines containing only comments or whitespace and lines containing code. | 110 | −2.858 |
| Indentation frequencyHow rapidly indentation changes from line to line. | 97 | +2.618 |
| Comment layout (horizontal)How rapidly the visual pattern of comment characters changes from left to right. | 207 | +2.535 |
| Number layout frequencyHow rapidly the number of numeric values per line changes through the code. | 98 | −1.828 |
| Identifier layout (vertical)How rapidly the visual pattern of identifier characters changes from top to bottom. | 108.745 | +1.11 |
| Operator visual areaThe share of the code’s visual area occupied by operators such as +, =, and *. | 0.102 | −0.05 |
Intercept 0.07 + feature contributions = -3.504 (log-odds).
Score = sigmoid(-3.504) = 0.029.
| Score | 0.007 |
|---|
| Score | 56 |
|---|
Run 1
The code suffers from severe readability issues. The package and imports are compressed onto single lines, making them difficult to scan. Multiple method declarations are crammed together on the same lines, violating the 'one action per line' principle and disrupting reading flow. Nesting is inconsistent, with some methods using proper if-else blocks and others using inline conditionals. The class structure is logical (caching, unmodifiable wrappers), but the inconsistent formatting obscures intent. While the individual methods are relatively simple, the erratic line breaks and compressed declarations make the code feel tangled and unprofessional. The code length is acceptable, but the formatting choices dramatically reduce clarity.
Run 2
The code is a simple read-only wrapper over HttpHeaders, but readability suffers significantly from inconsistent formatting and compressed statements. Many method signatures and bodies are crammed onto single lines, making the code visually chaotic and harder to scan. Nesting is mostly flat, which is good, but the flow is broken by irregular line breaks and inconsistent brace placement. The intent is generally clear—most methods throw UnsupportedOperationException—but the presentation obscures it. Action granularity is poor in several places, with multiple statements or branched logic packed into one line (e.g., get(), forEach()). Imports are also compressed onto one line, further reducing clarity. The class itself is straightforward, but the lack of consistent formatting and occasional multi-action lines make it harder to read than necessary.
Run 3
This code is extremely difficult to read due to severe formatting issues. The imports are on a single line, multiple fields are declared on one line, and method signatures are run together with multiple overrides per line. There's no consistent indentation or spacing. The code violates almost every readability principle: it has multiple actions per line, no visual separation between methods, inconsistent brace placement, and no breathing room around operators. While the logic itself is straightforward (read-only wrapper for HTTP headers), the presentation makes it nearly unreadable. A developer would need to reformat the entire file to understand its structure. The class has a clear purpose and relatively simple logic, but the formatting completely obscures this. Even basic navigation is challenging as methods blur together, making it hard to identify where one method ends and another begins.
Run 1
Code Structure: The class logically groups cached getters, read-only views, and rejected mutations, but compressed method boundaries obscure that organization. Nesting: Mostly shallow, with simple conditionals and one loop; the collector expression adds modest complexity. Clarity of intent: The class name, documentation, descriptive identifiers, and repeated UnsupportedOperationException calls clearly communicate read-only behavior. Code length: Reasonably concise for the required overrides, although repetitive mutation methods add scanning overhead. Action granularity: Multiple imports, declarations, annotations, statements, and even methods share lines, substantially reducing readability. Reading flow: Inconsistent spacing, brace placement, and abrupt transitions between methods disrupt an otherwise straightforward implementation.
Run 2
Code Structure: The class logically groups read-only header behavior, caching, and prohibited mutations, but compressed method boundaries obscure organization. Nesting: Mostly shallow, with simple conditionals and one loop; the collector expression adds modest complexity. Clarity of intent: Descriptive names, documentation, unmodifiable wrappers, and consistent exceptions clearly communicate purpose. Code length: Methods are concise, and repetitive overrides are appropriate to the interface, though unnecessary else blocks add minor verbosity. Action granularity: Multiple imports, declarations, annotations, statements, and even methods share lines, making individual actions difficult to distinguish. Reading flow: Inconsistent spacing, abrupt transitions, and closing braces joined to subsequent declarations significantly disrupt scanning. Overall, understandable logic is undermined by poor formatting.
Run 3
Code Structure: The class logically groups read-only header behavior, caching, and rejected mutations, but compressed method boundaries obscure organization. Nesting: Generally shallow, with simple conditionals and one loop; the collector expression is moderately complex. Clarity of intent: Descriptive names, overrides, and class documentation clearly communicate the purpose and caching limitation. Code length: Methods are short and mostly necessary; repeated exception-throwing overrides add justified boilerplate. Action granularity: Multiple imports, declarations, statements, annotations, and even methods share lines, making individual actions harder to distinguish. Reading flow: Inconsistent spacing, crowded braces, and annotations attached to preceding methods repeatedly interrupt scanning. Overall, straightforward logic and meaningful naming preserve readability, but poor formatting substantially reduces it.