Sample
int-e593168e938e-I08
Select one of ten high-readability unrelated code templates per class
Scores
| Method | Score | Scale |
|---|---|---|
| Posnett | 0 | 0–1; higher is more readable |
| Scalabrino | 0.725 | 0–1; higher is more readable |
| Dorn | 0.575 | 0–1; higher is more readable |
| Mi | 0.505 | 0–1; higher is more readable |
| LLOC | 18 | Logical lines; fewer is more readable |
| DeepSeek V4 Pro | 6 | 0–20; mean of three runs |
| GPT-6.1 Sol | 12.33 | 0–20; mean of three runs |
| BTTF | 0.315 | 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. | 2122.888 | −70.055 |
| Source linesThe number of non-empty source lines. | 61 | +24.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.607 | −6.911 |
Intercept 8.87 + feature contributions = -43.696 (log-odds).
Score = sigmoid(-43.696) = 0.
| Score | 0.725 |
|---|
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. | 62 | −1.159 |
| Indentation frequencyHow rapidly indentation changes from line to line. | 54 | +1.131 |
| Number layout frequencyHow rapidly the number of numeric values per line changes through the code. | 54 | −0.818 |
| Comment layout (horizontal)How rapidly the visual pattern of comment characters changes from left to right. | 90 | +0.648 |
| Identifier layout (vertical)How rapidly the visual pattern of identifier characters changes from top to bottom. | 60.945 | +0.442 |
| 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. | 89.919 | −0.143 |
| Operator visual areaThe share of the code’s visual area occupied by operators such as +, =, and *. | 0.083 | +0.133 |
Intercept 0.07 + feature contributions = 0.303 (log-odds).
Score = sigmoid(0.303) = 0.575.
| Score | 0.505 |
|---|
| Score | 18 |
|---|
Run 1
The code is structured as a typical Netty server bootstrap but contains a severe flaw: an unrelated block of code (comparing two integer scores) is randomly inserted inside the `initChannel` method before the actual pipeline setup. This completely breaks the logical organization and clarity of intent, making the code extremely confusing. Nesting is otherwise reasonable, but the erroneous block adds unnecessary nesting and ambiguity. Code length is acceptable for a Netty example, but the stray code makes it seem unnecessarily long. Action granularity is mostly one action per line, which is good. Reading flow is natural at the top (imports, Javadoc, constants) but is abruptly disrupted by the unrelated score-comparison logic, destroying the overall readability.
Run 2
The code generally follows good structure with clear comments and method chaining, but contains a serious readability flaw: an unrelated block of code (comparing firstScore and secondScore) is inexplicably inserted inside the initChannel method. This breaks the reading flow and confuses the intent. The nested anonymous inner class and if-else add unnecessary depth. Action granularity is mostly one action per line, and imports/logging are reasonable. However, the distracting dead code and misplacement significantly reduce clarity. Without that block, the score would be higher (around 16-17).
Run 3
The code is highly unreadable due to a glaring structural defect: a random, unrelated block of code (`int firstScore = 72; ...`) has been inserted inside the `initChannel` method, completely breaking the logical flow and purpose of the SCTP server example. This destroys code structure, clarity of intent, and reading flow. While the Netty boilerplate itself is reasonably concise and flat, the foreign block introduces unnecessary complexity and redundant logic. Action granularity is mostly one action per line, but the nested anonymous class plus the inserted block creates confusing nesting. Overall, the file appears corrupted or tampered with, making it impossible to follow the intended echo server implementation. Without the inserted block, the code would be moderately readable, but as presented it fails almost every criterion for readability.
Run 1
Code Structure: The server follows a logical setup, bind, wait, and cleanup sequence, but an unrelated score-comparison block interrupts channel initialization. Nesting: Mostly moderate, although the anonymous initializer, extra block, and if/else add unnecessary depth. Clarity of intent: The class documentation and lifecycle comments clearly explain the echo server; the unused higherScore calculation has no apparent purpose, and names like b and f are vague. Code length: Generally concise, but the irrelevant calculation and commented-out logging statement add clutter. Action granularity: Statements mostly perform one action per line, and the fluent configuration chain is easy to scan. Reading flow: The lifecycle reads naturally, but inconsistent indentation and the abruptly inserted comparison block significantly disrupt it.
Run 2
Code Structure: Server setup, startup, waiting, and cleanup are logically organized, but an unrelated score-comparison block interrupts channel initialization. Nesting: The try/finally, anonymous initializer, extra block, and conditional create moderately deep nesting. Clarity of intent: The echo-server purpose and lifecycle are clear, but unused score variables and generic names such as b and f weaken clarity. Code length: The server configuration is compact, but the irrelevant comparison and commented-out logging add unnecessary content. Action granularity: Statements generally perform one action per line, and the fluent configuration is split into readable steps. Reading flow: Lifecycle comments and consistent configuration ordering help, but the abruptly inserted, poorly indented comparison block substantially disrupts the flow.
Run 3
Code Structure: Server configuration, startup, waiting, and cleanup are logically organized, but an unrelated score-comparison block disrupts the channel initializer. Nesting: The try/finally, anonymous initializer, extra block, and conditional create moderately deep nesting. Clarity of intent: The echo-server purpose and lifecycle are clear, while unused score variables and the commented-out logging handler introduce distractions. Code length: Most setup is concise, but the irrelevant comparison adds unnecessary lines. Action granularity: Statements generally perform one action per line, and the fluent configuration chain is reasonably formatted. Reading flow: The lifecycle reads naturally overall, but the abruptly inserted, inconsistently indented block interrupts it; abbreviated names such as b, f, and ch also slightly reduce clarity.