Sample
int-38833eaf64c7-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.192 | 0–1; higher is more readable |
| Dorn | 0.121 | 0–1; higher is more readable |
| Mi | 0.001 | 0–1; higher is more readable |
| LLOC | 25 | Logical lines; fewer is more readable |
| DeepSeek V4 Pro | 7 | 0–20; mean of three runs |
| GPT-6.1 Sol | 9.33 | 0–20; mean of three runs |
| BTTF | 0.274 | 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. | 2825.028 | −93.226 |
| Source linesThe number of non-empty source lines. | 49 | +19.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. | 4.646 | −6.969 |
Intercept 8.87 + feature contributions = -71.725 (log-odds).
Score = sigmoid(-71.725) = 0.
| Score | 0.192 |
|---|
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. | 215 | −5.441 |
| Comment layout (horizontal)How rapidly the visual pattern of comment characters changes from left to right. | 215 | +2.664 |
| Comment layout frequencyHow frequently the layout switches between lines containing only comments or whitespace and lines containing code. | 50 | −0.734 |
| Indentation frequencyHow rapidly indentation changes from line to line. | 42 | +0.716 |
| Number layout frequencyHow rapidly the number of numeric values per line changes through the code. | 1 | +0.398 |
| Identifier layout (vertical)How rapidly the visual pattern of identifier characters changes from top to bottom. | 48.819 | +0.273 |
| Operator visual areaThe share of the code’s visual area occupied by operators such as +, =, and *. | 0.09 | +0.068 |
Intercept 0.07 + feature contributions = -1.987 (log-odds).
Score = sigmoid(-1.987) = 0.121.
| Score | 0.001 |
|---|
| Score | 25 |
|---|
Run 1
The code has some readability issues. The class structure is simple with two methods, but the implementation is tightly packed, with multiple statements on single lines and braces placed on the same line in some places, hurting readability. The lambda in `all()` is deeply nested with chained streams and conditionals, making it harder to follow. There is some redundancy in error message construction. The intent of the code (a Kafka admin result wrapper) is mostly clear from the Javadoc, but the formatting and dense code reduce clarity. Action granularity is inconsistent—some lines contain multiple actions, while others are split over many lines. The overall reading flow is unnatural due to inconsistent indentation, line breaks, and brace placement.
Run 2
The code suffers from poor readability due to multiple issues. The imports are all crammed on single lines at the top, making it difficult to scan dependencies. The main structural problem is the heavy compaction - closing braces and method declarations share lines, eliminating visual separation between methods. This makes the class structure extremely hard to parse mentally. The `all()` method contains deeply nested streams, conditionals, and string concatenation logic all compressed into a single lambda expression, creating multiple levels of nesting with no natural reading flow. The `partitionResult()` method also has a deeply nested conditional chain with multiple `if-else` branches that would benefit from early returns. Action granularity is violated - multiple operations occur on single physical lines. The code appears to have been automatically minified or aggressively compacted, destroying the logical organization that would make the intent clear. While variable names are descriptive, the formatting choices make even simple logic difficult to follow.
Run 3
The code has significant readability issues. The imports are jammed onto single lines, and methods/fields are compressed with multiple statements per line, violating action granularity. The lambda body contains deep nesting and conditional blocks collapsed inline, making the control flow hard to follow. The `partitionResult` method mixes exception handling and business logic in a cramped multi-branch structure. While the class purpose is documented, the actual code obscures intent through poor formatting, excessive inline braces, and tangled stream operations in `all()`. The `all()` method also has inconsistent indentation and unclear error-message construction. Overall, the structure is disorganized, with multiple logical steps sharing lines, poor visual separation, and unnatural reading flow that forces the reader to mentally reformat the code.
Run 1
Code Structure: The class logically separates per-partition results from aggregate results, but compressed formatting obscures method boundaries. Nesting: Callback conditionals and the loop in all() create moderate nesting that is harder to follow because braces and statements share lines. Clarity of intent: Descriptive class and method names, types, and Javadocs explain the purpose; asynchronous error handling requires closer inspection. Code length: The implementation is reasonably compact, although repeated exception construction adds verbosity. Action granularity: Multiple imports, declarations, conditionals, and actions appear on single lines, substantially reducing readability. Reading flow: Inconsistent indentation, inline Javadocs after closing braces, and crowded stream operations interrupt otherwise logical execution flow.
Run 2
Code Structure: The class is logically organized around a shared future and two result methods, but compressed formatting obscures boundaries. Nesting: Callbacks, conditionals, and a loop introduce moderate nesting, made harder to track by inconsistent brace placement. Clarity of intent: Descriptive names, documentation, and explicit error messages make the purpose reasonably clear. Code length: Overall length is appropriate, though duplicated exception construction adds avoidable verbosity. Action granularity: Multiple imports, assignments, conditionals, and returns share lines, reducing scanability. Reading flow: Inline method bodies, comments attached to closing braces, and irregular stream-chain formatting repeatedly interrupt otherwise logical control flow.
Run 3
Code Structure: The class has a logical organization, with a shared future and separate methods for partition-level and aggregate results. Nesting: Callback conditionals and a loop with nested error checks add moderate complexity. Clarity of intent: Descriptive method names, types, Javadoc, and error messages make the purpose understandable. Code length: Reasonably short, though aggregate error-message construction repeats logic. Action granularity: Multiple imports, statements, and control-flow operations share lines, making individual actions difficult to scan. Reading flow: Inconsistent whitespace, compressed stream operations, and comments attached to closing braces disrupt natural reading. The underlying design is understandable, but poor formatting substantially reduces readability.