Sample

Scalabrio176

Human rating uses the original dataset scale.

DatasetScalabrino
Human3.56
Lines27

Scores

MethodScoreScaleDataset rank
(0–100)
Posnett00–1; higher is more readable
30.2Δ 15.3
Scalabrino0.3090–1; higher is more readable
27.1Δ 18.3
Dorn0.5840–1; higher is more readable
66.3Δ 20.9
Mi0.1940–1; higher is more readable
47.2Δ 1.8
LLOC25Logical lines; fewer is more readable
11.8Δ 33.7
DeepSeek V4 Pro16.670–20; mean of three runs
85.7Δ 40.2
GPT-6.1 Sol180–20; mean of three runs
83.7Δ 38.2
BTTF0.5190–1; higher is more readable
44.7Δ 0.8
Human3.561–5; original rating
45.5

Views

Download official ZIP ↗

Select the downloaded ZIP or its extracted folder. Files stay in your browser.

Loading feature diagnosis…

Source regions

Feature contributions

Feature contributions

FeatureValueContribution
(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.1128.557−37.242
Source linesThe number of non-empty source lines.27+10.8
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.627−6.941

Intercept 8.87 + feature contributions = -24.513 (log-odds).
Score = sigmoid(-24.513) = 0.

Score0.309

Feature contributions

FeatureValueContribution
(log-odds)
Comment layout frequencyHow frequently the layout switches between lines containing only comments or whitespace and lines containing code.1+1.001
Comment layout (horizontal)How rapidly the visual pattern of comment characters changes from left to right.0−0.804
Indentation frequencyHow rapidly indentation changes from line to line.1−0.703
Number layout frequencyHow rapidly the number of numeric values per line changes through the code.1+0.398
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.78.889+0.324
Operator visual areaThe share of the code’s visual area occupied by operators such as +, =, and *.0.085+0.115
Identifier layout (vertical)How rapidly the visual pattern of identifier characters changes from top to bottom.25.012−0.06

Intercept 0.07 + feature contributions = 0.341 (log-odds).
Score = sigmoid(0.341) = 0.584.

Score0.194
Score25
Run 1

The code is highly readable with a clear, focused purpose: verifying that an ElementCollection annotation exists and no other related annotations are present. The structure is logical, starting with setup, then a series of flat, one-action-per-line assertions. There is no nesting, and the flow follows a natural progression from setup to assertions to specific property checks. The assertions are concise and self-documenting, making intent obvious. The only minor drawback is the repetitive assertAnnotationNotPresent calls, which could be refactored into a loop or helper method for brevity, but the current form is perfectly acceptable for test clarity. Overall, the method is an excellent example of clear, maintainable test code.

Run 2

The code is highly readable due to its flat structure and consistent one-action-per-line formatting. Each assertion clearly states its intent, making the test's purpose immediately understandable. The method name 'testNoChildren' and the setup line at the top provide clear context. The sequence of assertions follows a logical flow, grouping related annotations together. Minor deductions for slight repetition in the assertion method names and the lack of separating blank lines between logical groups, but overall this is excellent, self-documenting test code.

Run 3

The code is well-structured and highly readable. It follows a clear logical flow: setup, assertion of many absent annotations, and final specific checks. Nesting is flat, with no conditional blocks. The intent is unambiguous—verify that certain annotations are not present while ElementCollection is. Each line contains a single action, and the repetitive assertion calls are concise and maintainable despite their number. The reading flow is natural, from setup to general checks to specific value assertions. Minor deduction for the long repetitive list of assertions, which could be slightly harder to scan, but it remains clear and purposeful.

Run 1

Code Structure: Clearly organized into reader setup, annotation presence/absence checks, and default-value assertions. Nesting: Completely flat, with no branching or nested blocks. Clarity of intent: The test name and explicit assertions communicate that an element collection without child configuration should retain defaults, though relAnno and the XML filename provide limited context. Code length: Reasonably concise for exhaustive checks, but the long sequence of similar absence assertions is repetitive. Action granularity: Each line performs one clear operation. Reading flow: Natural setup-to-verification progression; grouping related absence checks with whitespace could improve scanning.

Run 2

Code Structure: Logically organized into reader setup, annotation presence checks, and default-value assertions. Nesting: Flat, with no nested control flow. Clarity of intent: The test name and explicit assertions make the purpose clear, though relAnno is a mildly abbreviated variable name. Code length: The repeated absence checks make the method lengthy but remain explicit and useful for a test; a helper could shorten them at some cost to visibility. Action granularity: Each statement performs one clear action. Reading flow: Execution proceeds naturally from setup to verification, although blank lines separating the phases would improve scanning.

Run 3

Code Structure: Clearly organized into reader setup, annotation presence checks, and default-value assertions. Nesting: Flat method body with no nested control flow. Clarity of intent: The test name and explicit assertions communicate the expected behavior, though relAnno is abbreviated and the XML fixture requires external context. Code length: Reasonably concise; the long sequence of absence checks is repetitive but makes coverage explicit. Action granularity: Each statement performs one operation on its own line. Reading flow: Natural progression from setup to verification, although blank lines between phases would improve scanning.