Sample
Dorn/java/172
Human rating uses the original dataset scale.
Scores
| Method | Score | Scale | Dataset rank (0–100) |
|---|---|---|---|
| Posnett | 0 | 0–1; higher is more readable | 39.6Δ 24.0 |
| Scalabrino | 0.753 | 0–1; higher is more readable | 83.3Δ 19.8 |
| Dorn | 0.699 | 0–1; higher is more readable | 66.0Δ 2.5 |
| Mi | 0.527 | 0–1; higher is more readable | 56.3Δ 7.2 |
| LLOC | 3 | Logical lines; fewer is more readable | 88.6Δ 25.1 |
| DeepSeek V4 Pro | 16.33 | 0–20; mean of three runs | 87.9Δ 24.4 |
| GPT-6.1 Sol | 17.33 | 0–20; mean of three runs | 86.5Δ 23.0 |
| BTTF | 0.501 | 0–1; higher is more readable | 45.1Δ 18.4 |
| Human | 3.49 | 1–5; original rating | 63.5 |
Views
Select the downloaded ZIP or its extracted folder. Files stay in your browser.
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. | 886.085 | −29.241 |
| Source linesThe number of non-empty source lines. | 30 | +12 |
| Byte entropyHow varied the bytes in the source text are. Repeated bytes give a lower value; a more even mixture gives a higher value. | 5.157 | −7.736 |
Intercept 8.87 + feature contributions = -16.107 (log-odds).
Score = sigmoid(-16.107) = 0.
| Score | 0.753 |
|---|
Feature contributions
| Feature | Value | Contribution (log-odds) |
|---|---|---|
| Comment layout (horizontal)How rapidly the visual pattern of comment characters changes from left to right. | 89 | +0.632 |
| Operator visual areaThe share of the code’s visual area occupied by operators such as +, =, and *. | 0.067 | +0.288 |
| Indentation frequencyHow rapidly indentation changes from line to line. | 28 | +0.231 |
| Number layout frequencyHow rapidly the number of numeric values per line changes through the code. | 28 | −0.222 |
| 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. | 88.968 | −0.103 |
| 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. | 29.922 | +0.008 |
Intercept 0.07 + feature contributions = 0.844 (log-odds).
Score = sigmoid(0.844) = 0.699.
| Score | 0.527 |
|---|
| Score | 3 |
|---|
Run 1
The code is highly readable with clear structure and consistent formatting. It follows a logical organization: imports, class declaration, constants, nested interface for i18n strings, and constructor. Nesting is minimal and flat. Intent is explicit—this is an action class for adding auto-increment functionality. The use of a nested interface for internationalized strings is a bit unconventional but clearly labeled and maintains separation of concerns. Code length is appropriate; no unnecessary verbosity. Each declaration and statement is on its own line, improving action granularity. Reading flow is natural: you encounter class metadata, then string resources, then constructor. The only minor drawback is the nested interface named `i18n` (lowercase), which may subtly confuse readers unfamiliar with this pattern, but the intent remains clear. Overall, the code is clean, concise, and easy to follow.
Run 2
The code structure is clear with logical grouping of imports, constants, and interface definitions. Nesting is minimal and flat, making it easy to follow. The intent is explicit with descriptive names like AddAutoIncrementAction and the use of string managers for internationalization suggests a deliberate pattern. Code length is concise for what it accomplishes. Action granularity is good, with each declaration and statement on separate lines, improving readability. Reading flow is natural, from imports to class definition, though the interface naming convention (lowercase 'i18n') might be slightly unconventional and could confuse some readers. Overall, it's clean and maintainable but lacks comments explaining the purpose of the action or why the interface is nested.
Run 3
The code is moderately readable. It is well-structured with clear separation of constants, internationalization strings, and constructor. However, the use of nested interfaces for i18n is unconventional and obscures intent slightly. The code is flat with minimal nesting, which is good, and the action granularity is mostly one action per line. The reading flow is natural, moving from imports to class definition to constants to constructor. The main readability drawback is the non-standard i18n pattern, which adds a layer of indirection not immediately obvious to readers unfamiliar with the codebase. Overall, the code is above average in readability but could be improved by using a more conventional approach to internationalization string management.
Run 1
Code Structure: Logically organized into serialization metadata, localization support, constants, and a constructor. Nesting: Shallow, with only a small nested interface. Clarity of intent: The class name and localization keys communicate purpose, though abbreviated names such as rsrc and the unconventional i18n interface reduce clarity slightly; the actual action behavior is not shown. Code length: Concise overall, with modest boilerplate and two apparently unused imports. Action granularity: Each declaration or operation is separate, and longer expressions are sensibly wrapped. Reading flow: Consistent formatting and grouping make the code easy to scan, although the incomplete class excerpt limits understanding of its overall behavior.
Run 2
Code Structure: Logically organized into imports, class metadata, internationalization constants, and a constructor. Nesting: Shallow, with only a small nested interface. Clarity of intent: Class and constant names clearly communicate purpose, though the abbreviated i18n interface name and external superclass leave some context implicit. Code length: Concise overall, with minor boilerplate and apparently unused ICommand and AddAutoIncrementCommand imports. Action granularity: Each declaration or statement performs a single action; wrapped assignments remain easy to follow. Reading flow: Natural top-to-bottom progression, consistent indentation, and whitespace aid scanning. The internationalization comment provides useful context.
Run 3
Code Structure: Imports, class fields, internationalized constants, and constructor are logically organized. Nesting: Shallow nesting keeps the code easy to scan. Clarity of intent: The class name and superclass clearly identify a refactoring action, and the comment explains the string manager; however, abbreviated parameter names and the unconventional lowercase i18n interface slightly reduce clarity. Code length: Concise overall, though unused imports and generous whitespace add minor clutter. Action granularity: Each declaration or operation is separate, with sensible wrapping for longer expressions. Reading flow: The progression from setup to constructor is natural. The snippet ends without a closing class brace, making it appear incomplete.