Sample
Schnappinger/jsweet/def.dom.WebGLTexture
Human rating uses the original dataset scale.
Scores
| Method | Score | Scale | Dataset rank (0–100) |
|---|---|---|---|
| Posnett | 0.798 | 0–1; higher is more readable | 86.0Δ 27.9 |
| Scalabrino | 0.901 | 0–1; higher is more readable | 89.6Δ 31.5 |
| Dorn | 0.819 | 0–1; higher is more readable | 87.8Δ 29.7 |
| Mi | 0.687 | 0–1; higher is more readable | 80.2Δ 22.1 |
| LLOC | 2 | Logical lines; fewer is more readable | 94.6Δ 36.5 |
| DeepSeek V4 Pro | 17.67 | 0–20; mean of three runs | 83.0Δ 24.9 |
| GPT-6.1 Sol | 18 | 0–20; mean of three runs | 73.8Δ 15.7 |
| BTTF | 0.688 | 0–1; higher is more readable | 77.9Δ 19.8 |
| Human | 3.92 | 1–4; original rating | 58.1 |
Views
Loading feature diagnosis…
Source regions
Feature contributions
Feature contributions
| Feature | Value | Contribution (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.572 | −6.858 |
| Halstead volumeHow much symbolic information the code contains. It combines the total number of operators and values with the number of distinct ones. | 92 | −3.036 |
| Source linesThe number of non-empty source lines. | 6 | +2.4 |
Intercept 8.87 + feature contributions = 1.376 (log-odds).
Score = sigmoid(1.376) = 0.798.
| Score | 0.901 |
|---|
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. | 47 | +1.675 |
| 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. | 7 | +0.788 |
| Indentation frequencyHow rapidly indentation changes from line to line. | 5 | −0.564 |
| 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. | 5.792 | −0.329 |
| Operator visual areaThe share of the code’s visual area occupied by operators such as +, =, and *. | 0.068 | +0.279 |
Intercept 0.07 + feature contributions = 1.513 (log-odds).
Score = sigmoid(1.513) = 0.819.
| Score | 0.687 |
|---|
| Score | 2 |
|---|
Run 1
This code is highly readable. It has a clear, logical structure with a simple package declaration, a single public class extending WebGLObject, a static prototype field, and a trivial constructor. Nesting is minimal, and intent is unambiguous. The code is concise, with one action per line, and follows a natural reading flow. Minor deductions for lack of documentation and potential redundancy in the empty constructor, but overall it is very clean and maintainable.
Run 2
The code is highly readable due to its simple, logical structure. It defines a class extending WebGLObject with a static prototype field and an empty constructor. Nesting is virtually nonexistent, the intent is clear from the naming and minimal structure, and the length is concise without unnecessary code. Each statement is on its own line, maintaining clear action granularity. The reading flow is natural, beginning with the package declaration, followed by the class definition, field, and constructor. Minor deductions for the empty constructor, which could be omitted, and the lack of any Javadoc or comments for context.
Run 3
The code is highly readable due to its simplicity and clean structure. It follows standard Java conventions with a clear package declaration, a single public class extending a parent, and a minimal constructor. There is no deep nesting or complex logic, making the intent obvious. The code is concise and each action is on its own line. The only minor deductions are the lack of any documentation or comments explaining the purpose of the prototype field or the class itself, and the empty constructor could be omitted entirely. Overall, the code is almost trivial to understand, scoring well on all criteria except for a slight lack of explanatory context.
Run 1
Code Structure: The package declaration and small class are logically organized. Nesting: Only a single class level with an empty constructor, so nesting is minimal. Clarity of intent: The class name and inheritance clearly identify a WebGL texture type, though the purpose of the public static prototype field is not explained. Code length: Very concise, with no unnecessary logic. Action granularity: Each declaration is on its own line. Reading flow: Natural top-to-bottom flow, but a blank line after the package declaration and conventional spacing in the constructor would improve readability.
Run 2
Code Structure: The package declaration and small class are logically organized. Nesting: There is no unnecessary nesting. Clarity of intent: The class name and inheritance clearly identify a WebGL texture type, though the public static prototype field and empty constructor lack explanatory context. Code length: The code is concise, with no unnecessary implementation. Action granularity: Each declaration occupies its own line. Reading flow: The code reads naturally from package to class to members, but a blank line after the package declaration and conventional spacing in the constructor would improve presentation.
Run 3
Code Structure: Logically organized as a small class with a field and constructor. Nesting: Minimal, with no nested control flow. Clarity of intent: The class name and inheritance clearly identify a WebGL texture type, although the purpose of the public static prototype field is not explained. Code length: Concise, with no unnecessary code. Action granularity: Each declaration occupies its own line; the empty constructor contains no actions. Reading flow: Natural package-to-class-to-members progression, though missing blank lines and tight constructor brace spacing slightly reduce readability.