Sample
Scalabrio21
Human rating uses the original dataset scale.
Scores
| Method | Score | Scale | Dataset rank (0–100) |
|---|---|---|---|
| Posnett | 0 | 0–1; higher is more readable | 66.8Δ 6.5 |
| Scalabrino | 0.484 | 0–1; higher is more readable | 47.2Δ 26.1 |
| Dorn | 0.454 | 0–1; higher is more readable | 51.3Δ 22.1 |
| Mi | 0.157 | 0–1; higher is more readable | 41.7Δ 31.7 |
| LLOC | 7 | Logical lines; fewer is more readable | 81.7Δ 8.3 |
| DeepSeek V4 Pro | 15 | 0–20; mean of three runs | 61.6Δ 11.8 |
| GPT-6.1 Sol | 18.67 | 0–20; mean of three runs | 94.7Δ 21.4 |
| BTTF | 0.541 | 0–1; higher is more readable | 52.3Δ 21.1 |
| Human | 4 | 1–5; original rating | 73.4 |
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. | 485.798 | −16.031 |
| 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.181 | −7.772 |
| Source linesThe number of non-empty source lines. | 13 | +5.2 |
Intercept 8.87 + feature contributions = -9.733 (log-odds).
Score = sigmoid(-9.733) = 0.
| Score | 0.484 |
|---|
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. | 120.923 | −1.457 |
| Comment layout (horizontal)How rapidly the visual pattern of comment characters changes from left to right. | 121 | +1.148 |
| Indentation frequencyHow rapidly indentation changes from line to line. | 1 | −0.703 |
| Comment layout frequencyHow frequently the layout switches between lines containing only comments or whitespace and lines containing code. | 13 | +0.576 |
| Operator visual areaThe share of the code’s visual area occupied by operators such as +, =, and *. | 0.071 | +0.254 |
| Identifier layout (vertical)How rapidly the visual pattern of identifier characters changes from top to bottom. | 11.91 | −0.243 |
| Number layout frequencyHow rapidly the number of numeric values per line changes through the code. | 11 | +0.168 |
Intercept 0.07 + feature contributions = -0.186 (log-odds).
Score = sigmoid(-0.186) = 0.454.
| Score | 0.157 |
|---|
| Score | 7 |
|---|
Run 1
The code is highly readable with clear logical organization. It uses a flat structure with no nesting, making it easy to follow. Each function registration is on a single line, maintaining good action granularity. The intent is obvious—registering SQL functions with their return types and SQL syntax. The method is concise with no unnecessary code. Minor readability improvements could include vertical spacing between registrations to enhance visual separation, but this is negligible. The Javadoc comment is minimal but sufficient for a constructor.
Run 2
The code is fairly readable due to its consistent structure: each line performs one action (registering a function) and follows a predictable pattern. The method name and comment clearly indicate purpose. However, the code is overly verbose for what it does—six similar registration calls could be extracted into a helper method or data-driven structure to reduce repetition. The long lines slightly hinder readability but remain within typical Java conventions. Nesting is minimal and structure is logical, though the repetitive pattern signals an opportunity for abstraction. Overall, it's clear but not optimized for conciseness or maintainability.
Run 3
The code is generally readable and well-structured. Each registration is on a single line, which improves action granularity and scanability. The method is flat with no nesting, and the intent is clear: registering SQL functions for a Sybase dialect. However, readability is reduced by inconsistent formatting—the Javadoc comment indentation is misaligned and uses tabs inconsistently. The function names are repetitive but necessary; there's some verbosity from repeated 'StandardBasicTypes' and 'SQLFunctionTemplate' calls, though this is typical of such registration code. Overall, it is concise relative to its purpose and has a natural reading flow, but minor formatting issues and repetition prevent a higher score.
Run 1
Code Structure: The constructor logically groups related SQL function registrations after superclass initialization. Nesting: Flat, with no nested control flow. Clarity of intent: Explicit function names, return types, and SQL templates clearly communicate each registration; the constructor comment adds little information. Code length: Concise, though registration syntax is repetitive and lines are somewhat long. Action granularity: Each line performs one registration, making individual actions easy to distinguish. Reading flow: Consistent formatting and a straightforward top-to-bottom sequence make the code easy to scan.
Run 2
Code Structure: The constructor is logically organized, calling the superclass before registering SQL functions. Nesting: The body is flat, with no conditional or loop nesting. Clarity of intent: Descriptive function names, explicit return types, and SQL templates clearly communicate the configuration purpose; the constructor comment adds little beyond its name. Code length: The implementation is concise, although registration boilerplate is repetitive and lines are long. Action granularity: Each line performs one registration; nested object construction directly supports that action. Reading flow: Consistent formatting and a uniform registration pattern make the code easy to scan from top to bottom.
Run 3
Code Structure: The constructor logically groups SQL function registrations after superclass initialization. Nesting: Flat, with no nested control flow. Clarity of intent: Descriptive function names, explicit return types, and SQL templates clearly convey dialect initialization, though the constructor comment adds little information. Code length: Concise for six registrations; repetition is appropriate and easy to scan. Action granularity: Each line performs one registration, although nested object construction makes lines somewhat dense. Reading flow: Consistent formatting and a straightforward sequence support natural reading; long lines slightly reduce readability.