Sample
int-0bf48bdbbfbe-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.281 | 0–1; higher is more readable |
| Dorn | 0.007 | 0–1; higher is more readable |
| Mi | 0 | 0–1; higher is more readable |
| LLOC | 84 | Logical lines; fewer is more readable |
| DeepSeek V4 Pro | 8 | 0–20; mean of three runs |
| GPT-6.1 Sol | 9.33 | 0–20; mean of three runs |
| BTTF | 0.174 | 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. | 5373.21 | −177.316 |
| Source linesThe number of non-empty source lines. | 85 | +34 |
| 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.835 | −7.253 |
Intercept 8.87 + feature contributions = -141.699 (log-odds).
Score = sigmoid(-141.699) = 0.
| Score | 0.281 |
|---|
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. | 274.965 | −7.981 |
| Comment layout (horizontal)How rapidly the visual pattern of comment characters changes from left to right. | 274.988 | +3.632 |
| Comment layout frequencyHow frequently the layout switches between lines containing only comments or whitespace and lines containing code. | 86 | −2.009 |
| Indentation frequencyHow rapidly indentation changes from line to line. | 73 | +1.788 |
| Number layout frequencyHow rapidly the number of numeric values per line changes through the code. | 73 | −1.254 |
| Identifier layout (vertical)How rapidly the visual pattern of identifier characters changes from top to bottom. | 84.935 | +0.777 |
| Operator visual areaThe share of the code’s visual area occupied by operators such as +, =, and *. | 0.096 | +0.012 |
Intercept 0.07 + feature contributions = -4.964 (log-odds).
Score = sigmoid(-4.964) = 0.007.
| Score | 0 |
|---|
| Score | 84 |
|---|
Run 1
The code is functionally sound but poorly formatted. Many lines contain multiple statements separated by semicolons (e.g., field declarations, constructor assignments, method calls), which violates the action granularity criterion and hurts readability. There is inconsistent indentation and spacing throughout. The structure mixes package/imports together at the top, and some methods have statements bunched on one line while others are spaced out. The logic itself—SipHash rounds—is clear in intent, but the presentation makes it hard to follow. The constructor in particular is very dense, with validation, byte order handling, and state initialization compressed into few lines. The switch statement on leftover bytes is reasonably structured but has inconsistent break/fall-through formatting. Overall, the code would be much more readable with one statement per line, consistent indentation, and blank lines separating logical blocks.
Run 2
The code suffers from severe formatting issues that significantly hurt readability. Multiple statements are crammed onto single lines (especially in the constructor and state initialization), violating action granularity principles. The switch statement fall-through logic, while intentional, is not documented and could be confusing. Indentation is inconsistent, and some closing braces are placed on the same line as code. The original Netty code was likely well-formatted, but this version appears to have been corrupted or poorly minified. While the algorithm itself (SipHash) is logically structured and the method names are clear, the physical layout makes it difficult to follow. The import statements on one line, mixed spacing, and compressed code blocks all contribute to poor readability. A properly formatted version with one statement per line, consistent indentation, and better spacing would score much higher.
Run 3
The code has reasonable logical structure with clear sections (initialization, processing loop, tail handling), but readability is severely compromised by formatting issues. Multiple statements are crammed onto single lines, breaking the 'one action per line' principle. Nesting is generally flat, which is good, but the switch statement's fall-through cases and compact spacing make the tail processing difficult to follow. The intent is clear from comments and variable names, but the initial state constants could use better documentation. The code is concise but at the expense of clarity - the compact formatting makes it feel longer and harder to parse. Reading flow is disrupted by inconsistent spacing and line breaks, making it feel disorganized despite the underlying logical structure being sound. The compression/finalization round loops are clear, but the overall presentation significantly reduces readability.
Run 1
Code Structure: Constants, initialization, hashing, and round operations are logically separated, but merged declarations and method boundaries obscure that organization. Nesting: Generally shallow, with only modest nesting of loops and conditionals. Clarity of intent: Descriptive configuration names, comments, and the SipHash reference clarify the purpose; cryptographic state variables and undocumented switch fall-through require specialist knowledge. Code length: Appropriately compact for the algorithm, though excessive line compression makes it harder to scan rather than meaningfully simpler. Action granularity: Frequently poor, with multiple assignments, declarations, control statements, and closing braces on single lines; most of sipround is clearer. Reading flow: The algorithm follows a natural initialization, compression, tail-processing, and finalization sequence, but inconsistent indentation and crowded statements repeatedly interrupt that flow.
Run 2
Code Structure: Constants, initialization, hashing, and round operations are logically separated, but compressed method boundaries and inconsistent indentation obscure that organization. Nesting: Mostly shallow, with straightforward loops and conditionals; the switch adds little depth. Clarity of intent: The SipHash reference, descriptive round parameters, and endian comments help, but terse state variables and unexplained switch fall-through require algorithm knowledge. Code length: Reasonably concise for the algorithm, although excessive line compression reduces readability rather than simplifying it. Action granularity: Many lines combine declarations, assignments, control flow, and closing braces, making individual actions difficult to scan. Reading flow: The round function is mostly sequential and clear, but crowded imports, constructor statements, switch cases, and method transitions repeatedly interrupt natural reading.
Run 3
Code Structure: Constants, initialization, hashing, and the round operation are logically separated, but compressed declarations and method boundaries obscure that organization. Nesting: Mostly shallow, with manageable loops and conditionals. Clarity of intent: Descriptive round-count names, algorithm references, and endian comments help, while terse state variables and undocumented switch fall-through require algorithm knowledge. Code length: Reasonably concise for the algorithm, but excessive line compression sacrifices readability rather than removing unnecessary logic. Action granularity: Frequently poor; multiple declarations, assignments, control statements, and closing braces share lines. Reading flow: Inconsistent indentation, crowded switch cases, and statements attached to closing braces interrupt scanning. The mostly well-formatted sipround method is substantially easier to follow than the constructor and macHash method.