Sample
int-1f6ceb075c0a-I01
Remove line comments, block comments, and Javadoc
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 well-structured, using a simple class that clearly extends a base event type. Fields are final and properly validated with null checks, ensuring immutability. Nesting is minimal, and the methods are flat and concise. Intent is clear: the class represents a current lag event with partition and isolation level information. Code length is appropriate—no unnecessary boilerplate. Action granularity is good, with one logical action per line. Reading flow is natural, with a clear progression from package and imports to class definition, fields, constructor, accessors, and toString. Minor deductions: the class lacks a default no-argument constructor (though likely intentional), and the import order is slightly non-standard (non-alphabetical grouping). Overall, it is highly readable and maintainable.
Run 3
The code is highly readable due to its clear structure, minimal nesting, and concise implementation. It follows a logical organization: package declaration, imports, class definition, fields, constructor, accessor methods, and a toString override. The nesting is flat with no conditional blocks or deep indentation. Intent is immediately clear—modeling a current lag event with a partition and isolation level. The code length is minimal and appropriate for the functionality. Each line performs a single logical action, such as super constructor invocation, null checks, or field assignment. The reading flow is natural, moving from fields to constructor to getters to string representation. The only minor deduction is that the class lacks Javadoc comments describing the event's purpose or usage context, which would slightly improve clarity for external readers.
Run 1
Code Structure: Logically organized into immutable fields, constructor, accessors, and string representation. Nesting: Flat, with no nested control flow. Clarity of intent: Descriptive class, field, and method names clearly communicate an event for querying current lag; constructor null checks make requirements explicit. Code length: Concise, with minimal boilerplate and no unnecessary logic. Action granularity: Each statement performs one clear action; the string concatenation forms a single coherent representation. 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: Fields, constructor, accessors, and string representation are logically organized. Nesting: Entirely flat, with no nested control flow. Clarity of intent: Descriptive class, field, and method names clearly communicate the event's purpose; constructor null checks make required inputs explicit. 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 definition to initialization and accessors, followed by diagnostic output. Minor formatting issues, including tightly grouped package/import declarations and a long constructor signature, slightly reduce readability.
Run 3
Code Structure: Fields, constructor, accessors, and string representation are logically organized. Nesting: Methods are flat, with no nested control flow. Clarity of intent: Descriptive class, field, and method names clearly convey an event for obtaining current lag; constructor null checks make requirements explicit. Code length: The class is concise, with no unnecessary logic or duplication. Action granularity: Each statement performs a focused action; the string concatenation remains easy to follow. Reading flow: The progression from state definition to initialization, access, and representation is natural. Minor formatting issues, including the long constructor signature and lack of separation between package and imports, slightly reduce readability.