Sample
int-e99c2288310b-I10
Remove about 40% of line-break groups while retaining structure
Scores
| Method | Score | Scale |
|---|---|---|
| Posnett | 0.999 | 0–1; higher is more readable |
| Scalabrino | 0.602 | 0–1; higher is more readable |
| Dorn | 0.165 | 0–1; higher is more readable |
| Mi | 0.012 | 0–1; higher is more readable |
| LLOC | 1 | Logical lines; fewer is more readable |
| DeepSeek V4 Pro | 17.67 | 0–20; mean of three runs |
| GPT-6.1 Sol | 18 | 0–20; mean of three runs |
| BTTF | 0.64 | 0–1; higher is more readable |
Views
Loading feature diagnosis…
Source regions
Feature contributions
Feature contributions
| Feature | Value | Contribution (log-odds) |
|---|---|---|
| Source linesThe number of non-empty source lines. | 21 | +8.4 |
| 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.747 | −7.12 |
| Halstead volumeHow much symbolic information the code contains. It combines the total number of operators and values with the number of distinct ones. | 106.198 | −3.505 |
Intercept 8.87 + feature contributions = 6.645 (log-odds).
Score = sigmoid(6.645) = 0.999.
| Score | 0.602 |
|---|
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. | 220 | −5.653 |
| Comment layout (horizontal)How rapidly the visual pattern of comment characters changes from left to right. | 220 | +2.745 |
| Operator visual areaThe share of the code’s visual area occupied by operators such as +, =, and *. | 0.013 | +0.817 |
| Comment layout frequencyHow frequently the layout switches between lines containing only comments or whitespace and lines containing code. | 12 | +0.611 |
| Indentation frequencyHow rapidly indentation changes from line to line. | 7 | −0.495 |
| 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. | 20.919 | −0.117 |
Intercept 0.07 + feature contributions = -1.624 (log-odds).
Score = sigmoid(-1.624) = 0.165.
| Score | 0.012 |
|---|
| Score | 1 |
|---|
Run 1
The code is highly readable. It demonstrates excellent structure with a clear package declaration, import section, and a well-organized interface definition. Nesting is minimal and appropriate for a simple interface. The Javadoc comments clearly explain the purpose, context, and provide useful references, making the intent unambiguous. Code length is concise, containing only the essential elements. Action granularity is ideal - each statement occupies its own line. Reading flow is natural: package, Javadoc, interface declaration, method signature, closing brace. The only minor issue is the unusual placement of the 'public interface' keyword on the same line as the Javadoc closing tag, which slightly disrupts conventional formatting. Overall, this is production-quality, maintainable code that would be easy for any developer to understand immediately.
Run 2
The code is exceptionally readable. It consists of a single, well-defined interface with clear intent: apply a transport-specific format to a SockJS frame. The Javadoc is concise and informative, explaining the purpose, potential format variations, and pointing to relevant implementations. The interface has a single method, `format`, with a clear parameter and return type. There is no unnecessary complexity, nesting, or verbosity. The code is flat, organized, and flows naturally. The only minor formatting issue is the Javadoc closing tag and `@since` tag appearing on the same line as the `public interface` declaration, which slightly disrupts conventional formatting but does not impact comprehension. Overall, this is exemplary code that is easy to understand and maintain.
Run 3
The code is highly readable due to its excellent structure and clear intent. It consists of a single, well-documented interface with one concise method, resulting in flat nesting and minimal length. The Javadoc provides thorough context, explaining the purpose and implementation details, which aids clarity. However, the code loses points for the unusual placement of the interface declaration on the same line as the closing Javadoc tag, which breaks conventional formatting. Additionally, the interface could benefit from a separating line between the class documentation and the declaration itself. Action granularity is perfect, and the reading flow is natural, though the formatting irregularity slightly disrupts it.
Run 1
Code Structure: A simple interface with a single method is logically organized. Nesting: No nested control flow or unnecessary structural depth. Clarity of intent: Descriptive type and method names, supported by detailed Javadoc, clearly communicate transport-specific frame formatting; method-level documentation could clarify the return value. Code length: The implementation is minimal, though the documentation is relatively lengthy and includes a cumbersome link. Action granularity: The method declaration occupies its own line, with no combined actions. Reading flow: Package, documentation, interface, and method follow a natural order. However, placing the interface declaration on the same line as the closing Javadoc delimiter disrupts conventional formatting and slightly reduces readability.
Run 2
Code Structure: A minimal, logically organized interface with a single formatting method. Nesting: No nested control flow or unnecessary complexity. Clarity of intent: The interface name, method signature, and explanatory Javadoc clearly communicate transport-specific SockJS frame formatting, though method-level documentation could clarify the return value. Code length: The implementation is appropriately concise; the documentation is useful but contains a lengthy cross-reference. Action granularity: The single method declaration occupies its own line, with no combined operations. Reading flow: Package, documentation, interface, and method follow a natural order. However, placing the interface declaration directly after the closing Javadoc marker and using an unusually long link line slightly reduce readability.
Run 3
Code Structure: A single, logically organized interface declares one formatting method. Nesting: No nested control flow or complex blocks. Clarity of intent: Descriptive interface and method names, supported by Javadoc explaining transport-specific formatting, make the purpose clear; method-level documentation could clarify the return value. Code length: The implementation is minimal, although the documentation is relatively lengthy for one method. Action granularity: One declaration per line keeps the code easy to scan. Reading flow: Package, documentation, interface, and method follow a natural order. Minor readability issues include placing the interface declaration on the same line as the closing Javadoc marker and an unusually long Javadoc link.