Sample
Scalabrio138
Human rating uses the original dataset scale.
Scores
| Method | Score | Scale | Dataset rank (0–100) |
|---|---|---|---|
| Posnett | 0 | 0–1; higher is more readable | 12.1Δ 47.0 |
| Scalabrino | 0.541 | 0–1; higher is more readable | 53.3Δ 5.8 |
| Dorn | 0.259 | 0–1; higher is more readable | 34.7Δ 24.4 |
| Mi | 0.019 | 0–1; higher is more readable | 10.1Δ 49.0 |
| LLOC | 25 | Logical lines; fewer is more readable | 11.8Δ 47.2 |
| DeepSeek V4 Pro | 8.33 | 0–20; mean of three runs | 11.1Δ 48.0 |
| GPT-6.1 Sol | 16 | 0–20; mean of three runs | 34.7Δ 24.4 |
| BTTF | 0.461 | 0–1; higher is more readable | 28.1Δ 30.9 |
| Human | 3.78 | 1–5; original rating | 59.0 |
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. | 1609.878 | −53.126 |
| Source linesThe number of non-empty source lines. | 38 | +15.2 |
| 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.9 | −7.349 |
Intercept 8.87 + feature contributions = -36.405 (log-odds).
Score = sigmoid(-36.405) = 0.
| Score | 0.541 |
|---|
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. | 129.947 | −1.839 |
| Comment layout (horizontal)How rapidly the visual pattern of comment characters changes from left to right. | 130 | +1.293 |
| Number layout frequencyHow rapidly the number of numeric values per line changes through the code. | 36 | −0.405 |
| Comment layout frequencyHow frequently the layout switches between lines containing only comments or whitespace and lines containing code. | 38 | −0.309 |
| Indentation frequencyHow rapidly indentation changes from line to line. | 26 | +0.162 |
| Operator visual areaThe share of the code’s visual area occupied by operators such as +, =, and *. | 0.11 | −0.127 |
| Identifier layout (vertical)How rapidly the visual pattern of identifier characters changes from top to bottom. | 36.847 | +0.105 |
Intercept 0.07 + feature contributions = -1.05 (log-odds).
Score = sigmoid(-1.05) = 0.259.
| Score | 0.019 |
|---|
| Score | 25 |
|---|
Run 1
The code is partially readable but has several issues. The structure is disrupted by the lengthy @SkipForDialects annotation, which dominates the method signature and hurts clarity. Indentation is inconsistent throughout, especially around the annotation and method body. While the logic itself (persisting products, flushing, clearing, and asserting) is straightforward, the multiple assertions are packed together without spacing or comments explaining intent. Variable names like 'productIdnf' are cryptic. The use of System.out.println for debugging is unnecessary and reduces clarity. Some actions are grouped per line (e.g., multiple assertions), though the setup portion does maintain one action per line. Overall, the code would benefit from reformatting, grouped assertions with comments, and removal of debug output.
Run 2
The code has a logical purpose but suffers from readability issues. The annotations are verbose and make the method signature hard to follow. There is inconsistent indentation—some lines use spaces, others tabs—which disrupts reading flow. Nesting in annotations is somewhat deep. The test body does generally have one action per line, which is good, but several assertions are chained conceptually without blank lines or comments separating setup, action, and verification. Magic numbers like '1' and '2' and literal strings appear without named constants. Overall the intent is clear enough, but formatting, annotation complexity, and lack of separation reduce readability.
Run 3
The code has mixed indentation (tabs vs spaces), inconsistent spacing, and overly long annotations that obscure the method signature. The @SkipForDialects block dominates the top, making the test method hard to locate. The body mixes setup, assertions, and output (System.out.println) in a linear sequence, but the setup uses manual field assignments rather than helpers or builders, reducing intent clarity. There are multiple actions per line in several assertion blocks, and the deep annotation nesting (arrays containing annotations with arrays) creates visual clutter. Method intent is somewhat clear (testing JoinFormula), but the annotation noise buries it. Reading flow is broken by indentation shifts and trailing sloppy formatting. It is not unreadable, but it needs consistent formatting, extraction of repetitive setup, and removal of debug output.
Run 1
Code Structure: Logically organized into session setup, product creation, reload, assertions, and cleanup, with blank lines separating phases. Nesting: The method is flat; only the dialect annotations introduce visual complexity. Clarity of intent: The descriptive test name, annotation comments, and assertions communicate the relationship being tested, though 's', 'tx', and 'productIdnf' are less immediately clear. Code length: Reasonably concise, with some repetitive fixture initialization and an unnecessary debug print. Action granularity: Each statement performs one action, making individual steps easy to follow. Reading flow: The setup-to-verification sequence is natural, but inconsistent indentation and long annotation lines disrupt scanning. Printing kitkat.description before assertNotNull(kitkat) also weakens the verification flow.
Run 2
Code Structure: The test follows a logical setup, persist, reload, assert, and cleanup sequence, though phases are not explicitly labeled. Nesting: The method is flat and easy to scan; only the dialect annotations add visual complexity. Clarity of intent: The descriptive test name, annotation comments, and assertions explain the relationship being tested, but abbreviated names such as s, tx, and productIdnf reduce clarity. Code length: Reasonably concise, with some repetitive product setup and verbose annotations. Action granularity: Each statement performs a single action, making execution straightforward to follow. Reading flow: Blank lines separate meaningful phases, but inconsistent indentation, long annotation lines, and a debug print interrupt readability. Accessing kitkat.description before asserting kitkat is non-null also weakens the natural validation order.
Run 3
Code Structure: The test is logically organized into setup, persistence, reload, assertions, and cleanup. Nesting: The method is flat and easy to follow; only the dialect annotations add visual complexity. Clarity of intent: The descriptive test name, domain objects, and assertions communicate the relationship being tested, although 's', 'tx', and 'productIdnf' are less clear. Code length: The method is reasonably concise, with some repetitive object initialization and a distracting debug print. Action granularity: Each statement performs one action, making individual operations easy to inspect. Reading flow: Execution proceeds naturally, but inconsistent indentation and densely formatted annotations interrupt scanning. Dereferencing 'kitkat' before asserting it is non-null also makes the verification sequence less intuitive.