Sample
int-f0f69897bdf8-I05
Rewrite eligible decimal integer literals in hexadecimal notation
Scores
| Method | Score | Scale |
|---|---|---|
| Posnett | 0 | 0–1; higher is more readable |
| Scalabrino | 0.752 | 0–1; higher is more readable |
| Dorn | 0.221 | 0–1; higher is more readable |
| Mi | 0.108 | 0–1; higher is more readable |
| LLOC | 11 | Logical lines; fewer is more readable |
| DeepSeek V4 Pro | 17.67 | 0–20; mean of three runs |
| GPT-6.1 Sol | 19 | 0–20; mean of three runs |
| BTTF | 0.609 | 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. | 909.583 | −30.016 |
| Source linesThe number of non-empty source lines. | 31 | +12.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.68 | −7.02 |
Intercept 8.87 + feature contributions = -15.767 (log-odds).
Score = sigmoid(-15.767) = 0.
| Score | 0.752 |
|---|
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. | 119.969 | −1.416 |
| Comment layout (horizontal)How rapidly the visual pattern of comment characters changes from left to right. | 0 | −0.804 |
| Number layout frequencyHow rapidly the number of numeric values per line changes through the code. | 1 | +0.398 |
| Indentation frequencyHow rapidly indentation changes from line to line. | 31 | +0.335 |
| Operator visual areaThe share of the code’s visual area occupied by operators such as +, =, and *. | 0.077 | +0.197 |
| Comment layout frequencyHow frequently the layout switches between lines containing only comments or whitespace and lines containing code. | 31 | −0.061 |
| Identifier layout (vertical)How rapidly the visual pattern of identifier characters changes from top to bottom. | 30.769 | +0.02 |
Intercept 0.07 + feature contributions = -1.261 (log-odds).
Score = sigmoid(-1.261) = 0.221.
| Score | 0.108 |
|---|
| Score | 11 |
|---|
Run 1
The code is well-structured with clear separation of concerns: imports, field declarations, constructor, accessors, and toString override. It is flat with no nested logic. Purpose is unambiguous: a completion event carrying partition and isolation level data. The length is concise with no unnecessary code. Each action (assignment, null check, return) is on its own line. Reading flow is natural, progressing from fields to construction to access. Minor deduction for the long class declaration line and the chained `Objects.requireNonNull` calls reducing slightly the one-action-per-line granularity.
Run 2
The code is highly readable. It follows a logical structure with clear class purpose, minimal nesting, and flat organization. The constructor uses Objects.requireNonNull for explicit validation, improving clarity. Method names like partition() and isolationLevel() clearly indicate intent. Each action is on its own line, aiding readability. The toStringBase method extends the parent method naturally, maintaining a clean reading flow. The class is concise without unnecessary length. Minor deductions could be for slightly more verbose constructor but overall it is exceptional.
Run 3
The code is highly readable with a clear, logical structure. The class has a single responsibility, flat nesting, and minimal length. Each method performs one action, and the flow is natural: fields, constructor, accessors, toString. Naming is explicit and consistent with Java/Kafka conventions. Null validation with Objects.requireNonNull improves clarity of intent. The only minor deductions are for the absence of Javadoc and slightly verbose toStringBase, but overall readability is excellent.
Run 1
1. Code Structure: Logically organized into immutable fields, constructor, accessors, and string representation. 2. Nesting: Flat methods with no nested control flow. 3. Clarity of intent: Descriptive class, field, and method names clearly communicate the event's purpose; constructor null checks make requirements explicit. 4. Code length: Concise, with minimal boilerplate and no unnecessary logic. 5. Action granularity: Each statement performs one clear action; the string concatenation remains straightforward. 6. Reading flow: Natural progression from state initialization to access and representation. Minor formatting improvements, such as separating the package declaration from imports and wrapping the long constructor signature, would improve scanning.
Run 2
Code Structure: The class is logically organized into fields, constructor, accessors, and a string-representation override. Nesting: No nested control flow; methods are flat and easy to follow. Clarity of intent: Descriptive class, field, and method names clearly convey a current-lag event carrying partition and isolation information. Code length: Concise, with no unnecessary logic or duplication. Action granularity: Each statement performs a single clear action, including field initialization and null validation. Reading flow: Natural top-to-bottom progression, slightly weakened by the lack of spacing between the package declaration and import groups and the long constructor signature.
Run 3
Code Structure: Fields, constructor, accessors, and string representation are logically organized. Nesting: Flat methods with no nested control flow make scanning easy. Clarity of intent: Descriptive class, field, and method names clearly convey a current-lag event; explicit null checks establish required inputs. Code length: Concise, with no unnecessary logic or repetition. Action granularity: Each statement performs one clear action; the string concatenation remains straightforward. Reading flow: Natural progression from state to initialization to accessors and representation. Minor formatting improvements, such as separating the package declaration from imports and wrapping the long constructor signature, would improve readability.