Sample

Schnappinger/jsweet/def.dom.GainNode

Human rating uses the original dataset scale.

Human2.62
Lines7

Scores

MethodScoreScaleDataset rank
(0–100)
Posnett0.7760–1; higher is more readable
84.9Δ 69.1
Scalabrino0.950–1; higher is more readable
98.3Δ 82.4
Dorn0.8550–1; higher is more readable
92.7Δ 76.9
Mi0.680–1; higher is more readable
78.9Δ 63.0
LLOC3Logical lines; fewer is more readable
91.1Δ 75.2
DeepSeek V4 Pro18.670–20; mean of three runs
98.3Δ 82.5
GPT-6.1 Sol180–20; mean of three runs
73.8Δ 57.9
BTTF0.6940–1; higher is more readable
79.9Δ 64.0
Human2.621–4; original rating
15.8

Views

Source code

package def.dom; public class GainNode extends AudioNode { public AudioParam gain; public static GainNode prototype; public GainNode(){} }

Loading feature diagnosis…

Source regions

Feature contributions

Feature contributions

FeatureValueContribution
(log-odds)
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.474−6.71
Halstead volumeHow much symbolic information the code contains. It combines the total number of operators and values with the number of distinct ones.112.588−3.715
Source linesThe number of non-empty source lines.7+2.8

Intercept 8.87 + feature contributions = 1.244 (log-odds).
Score = sigmoid(1.244) = 0.776.

Score0.95

Feature contributions

FeatureValueContribution
(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.41+1.929
Comment layout (horizontal)How rapidly the visual pattern of comment characters changes from left to right.0−0.804
Comment layout frequencyHow frequently the layout switches between lines containing only comments or whitespace and lines containing code.8+0.753
Indentation frequencyHow rapidly indentation changes from line to line.6−0.53
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.6.881−0.314
Operator visual areaThe share of the code’s visual area occupied by operators such as +, =, and *.0.069+0.272

Intercept 0.07 + feature contributions = 1.774 (log-odds).
Score = sigmoid(1.774) = 0.855.

Score0.68
Score3
Run 1

The code is a minimal, clearly structured class definition. It extends a parent class, declares two public fields with obvious purposes, and includes an empty default constructor. There is no nesting, no ambiguous logic, and each member is declared on its own line, making the reading flow straight-forward. The brevity and clarity fully satisfy all evaluation criteria.

Run 2

The code is highly readable. It is a concise class definition with a clear package declaration and inheritance. Structure is logical and flat, with no nesting. Intent is obvious: it defines a GainNode extending AudioNode with a public gain parameter and a static prototype field. Length is minimal and appropriate. Each field declaration occupies its own line, maintaining good action granularity. Reading flow is natural, following standard Java conventions. The only minor deduction is the empty constructor which is redundant, but this barely affects readability.

Run 3

The code is highly readable due to its minimal, flat structure. It follows a clear, conventional class declaration with a single inheritance level and no nested blocks. The purpose is straightforward: define a GainNode extending AudioNode with an AudioParam field and a static prototype. The code is very concise, containing only essential declarations and a default constructor. Each line represents a single logical entity, maintaining strong action granularity. The reading flow is natural — package, imports/namespace, class signature, properties, and constructor — reflecting standard Java/Scala-like conventions. Minor deductions: the empty constructor is slightly redundant and could be omitted; 'prototype' is a static field typically managed by the runtime, which might confuse some readers. Overall, the code is clean, unambiguous, and easy to parse.

Run 1

Code Structure: The package, class declaration, fields, and constructor are logically organized. Nesting: Only a single class level, making the code easy to scan. Clarity of intent: GainNode, AudioNode, and AudioParam clearly suggest an audio gain control, though the static prototype field's purpose is not explained. Code length: Very concise, with no unnecessarily long logic. Action granularity: Each declaration occupies its own line. Reading flow: Natural top-to-bottom order, but missing blank lines between sections and the tightly formatted empty constructor slightly reduce readability.

Run 2

Code Structure: A simple, logically organized class with fields followed by its constructor. Nesting: Minimal, with no nested control flow. Clarity of intent: Class, superclass, and field names clearly suggest an audio gain node, though the static prototype field's purpose is not explained. Code length: Concise, with no unnecessary statements. Action granularity: Each declaration occupies its own line. Reading flow: Natural and easy to follow, but a blank line after the package declaration and standard spacing in the empty constructor would improve presentation.

Run 3

Code Structure: Logically organized as a small class with fields followed by its constructor. Nesting: Minimal, with no nested control flow. Clarity of intent: The GainNode name, AudioNode inheritance, and AudioParam gain field clearly suggest an audio gain node, though the prototype field's role is not explained. Code length: Very concise, with no unnecessary logic. Action granularity: Each declaration occupies its own line. Reading flow: Straightforward from package declaration to class members, but missing blank lines and the tightly formatted empty constructor slightly reduce readability.