Sample
Dorn/java/211
Human rating uses the original dataset scale.
Scores
| Method | Score | Scale | Dataset rank (0–100) |
|---|---|---|---|
| Posnett | 0 | 0–1; higher is more readable | 16.2Δ 52.6 |
| Scalabrino | 0.499 | 0–1; higher is more readable | 41.5Δ 27.3 |
| Dorn | 0.697 | 0–1; higher is more readable | 65.2Δ 3.6 |
| Mi | 0.323 | 0–1; higher is more readable | 30.9Δ 37.9 |
| LLOC | 24 | Logical lines; fewer is more readable | 23.7Δ 45.1 |
| DeepSeek V4 Pro | 12.67 | 0–20; mean of three runs | 57.5Δ 11.3 |
| GPT-6.1 Sol | 15.33 | 0–20; mean of three runs | 58.6Δ 10.2 |
| BTTF | 0.422 | 0–1; higher is more readable | 27.3Δ 41.5 |
| Human | 3.57 | 1–5; original rating | 68.8 |
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. | 1823.635 | −60.18 |
| Source linesThe number of non-empty source lines. | 50 | +20 |
| 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.192 | −7.787 |
Intercept 8.87 + feature contributions = -39.097 (log-odds).
Score = sigmoid(-39.097) = 0.
| Score | 0.499 |
|---|
Feature contributions
| Feature | Value | Contribution (log-odds) |
|---|---|---|
| Indentation frequencyHow rapidly indentation changes from line to line. | 48 | +0.923 |
| Comment layout (horizontal)How rapidly the visual pattern of comment characters changes from left to right. | 0 | −0.804 |
| 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. | 70.647 | +0.673 |
| Comment layout frequencyHow frequently the layout switches between lines containing only comments or whitespace and lines containing code. | 44 | −0.522 |
| 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. | 49.589 | +0.283 |
| Operator visual areaThe share of the code’s visual area occupied by operators such as +, =, and *. | 0.117 | −0.19 |
Intercept 0.07 + feature contributions = 0.831 (log-odds).
Score = sigmoid(0.831) = 0.697.
| Score | 0.323 |
|---|
| Score | 24 |
|---|
Run 1
The code demonstrates generally readable structure with logical organization and mostly flat nesting. The class uses clear naming conventions like _proccessAttributes and _isValidAttribute, making method purposes understandable. Action granularity is acceptable with one operation per line, and the reading flow is natural. However, there are notable issues: the method name contains a typo (_proccessAttributes), there's inconsistent indentation and spacing in method declarations and map initializations, and several methods are incomplete (the _proccessAttributes method cuts off abruptly). The use of underscores in method names deviates from Java conventions and isn't consistent within the codebase shown. The _isValidAttribute method could be more concise by combining its conditional logic. The code relies on class-level constants and utilities (StringPool, ReservedAttributeUtil) that aren't visible, which can make it harder for readers to understand the full context. The method _proccessAttributes appears to be doing substantial work but the implementation is truncated, making it hard to fully evaluate.
Run 2
The code is moderately readable but has several issues. Structure is logical with clear method separation, though the class and method names use inconsistent naming prefixes (`_proccessAttributes` with typo, `_isEventAttribute`, `_isValidAttribute`). Nesting is mostly flat which is positive. Intent is somewhat clear but method bodies are incomplete (truncated loop) and naming inconsistencies create ambiguity. Code length is reasonable but methods like `_isValidAttribute` could be more concise. Action granularity is good - one operation per line. Reading flow is natural but disrupted by odd formatting (misaligned tabs in map declarations) and the typo. Missing context about field declarations and incomplete method affects overall comprehension. The code would benefit from consistent naming without underscores, fixing the typo, and completing the implementation logic.
Run 3
The code has moderate readability but contains several issues. Structure is somewhat organized into logical methods, but the incomplete method at the end leaves the flow unclear. Nesting is relatively flat, which is good. Intent is mostly clear through method names like '_isValidAttribute' and '_isEventAttribute', but '_proccessAttributes' has a typo and unclear purpose from the snippet. The code length is reasonable, though some parts are unnecessarily verbose (e.g., repeatedly calling getExcludeAttributes()). Action granularity is mixed: some lines combine multiple operations while others are concise. Reading flow is disrupted by the incomplete method, inconsistent formatting (extra spaces before '=' and 'new'), and the use of raw types (HashMap without generics). The method naming with underscore prefix is inconsistent with typical Java conventions. Overall, the code is not terribly written but lacks polish and completeness, making it harder to follow than necessary.
Run 1
Code Structure: Responsibilities are separated into focused methods for setting attributes, detecting events, validating attributes, and processing options. Nesting: Shallow conditionals and an early continue keep the loop easy to follow. Clarity of intent: Most names explain their purpose, but the typo in _proccessAttributes and the vague newOptions parameter reduce clarity. Code length: The excerpt is reasonably concise, though repeated getExcludeAttributes() calls and extra temporary variables add some verbosity. Action granularity: Statements generally perform one action per line, with clear separation between steps. Reading flow: Method organization and whitespace support natural reading, but inconsistent wrapping and spacing interrupt it slightly. The processing method is truncated, so its full organization and overall flow cannot be assessed.
Run 2
Code Structure: Responsibilities are separated into attribute setup, event detection, validation, and processing helpers, though the processing method is incomplete. Nesting: Shallow nesting and an early continue keep control flow easy to follow. Clarity of intent: Most method and variable names communicate purpose, but the misspelled _proccessAttributes, vague newOptions name, and missing processing logic reduce clarity. Code length: Generally concise, although repeated getExcludeAttributes() calls and rebuilding the exclusion list for each validation introduce avoidable repetition. Action granularity: Statements typically perform one action per line; wrapped expressions remain understandable. Reading flow: Setup proceeds naturally through processing, superclass setup, and attribute assignment. Inconsistent whitespace and line wrapping slightly disrupt scanning, and the truncated ending prevents assessment of the complete processing flow.
Run 3
Code Structure: Methods separate attribute setup, validation, and event detection logically, though the processing method is incomplete. Nesting: Shallow conditionals and an early continue keep nesting manageable. Clarity of intent: Most names explain their roles, but the misspelled _proccessAttributes and vague newOptions reduce clarity; the relationship between options and optionsJSON is not fully evident. Code length: The visible code is reasonably concise, although repeated getExcludeAttributes() calls add redundancy. Action granularity: Statements generally perform one action per line, with sensible wrapping of longer expressions. Reading flow: Setup proceeds naturally from collecting options to processing and publishing them, but inconsistent whitespace and the abrupt truncation interrupt the flow.