Sample
int-e3da9e0dc666-I10
Remove about 40% of line-break groups while retaining structure
Scores
| Method | Score | Scale |
|---|---|---|
| Posnett | 0 | 0–1; higher is more readable |
| Scalabrino | 0.623 | 0–1; higher is more readable |
| Dorn | 0.061 | 0–1; higher is more readable |
| Mi | 0.03 | 0–1; higher is more readable |
| LLOC | 6 | Logical lines; fewer is more readable |
| DeepSeek V4 Pro | 10.33 | 0–20; mean of three runs |
| GPT-6.1 Sol | 14 | 0–20; mean of three runs |
| BTTF | 0.684 | 0–1; higher is more readable |
Views
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. | 1055.401 | −34.828 |
| Source linesThe number of non-empty source lines. | 49 | +19.6 |
| 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.148 | −7.722 |
Intercept 8.87 + feature contributions = -14.08 (log-odds).
Score = sigmoid(-14.08) = 0.
| Score | 0.623 |
|---|
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. | 217.94 | −5.566 |
| Comment layout (horizontal)How rapidly the visual pattern of comment characters changes from left to right. | 218 | +2.713 |
| Comment layout frequencyHow frequently the layout switches between lines containing only comments or whitespace and lines containing code. | 49 | −0.699 |
| Operator visual areaThe share of the code’s visual area occupied by operators such as +, =, and *. | 0.04 | +0.552 |
| Identifier layout (vertical)How rapidly the visual pattern of identifier characters changes from top to bottom. | 48.845 | +0.273 |
| Number layout frequencyHow rapidly the number of numeric values per line changes through the code. | 21 | −0.061 |
| Indentation frequencyHow rapidly indentation changes from line to line. | 21 | −0.011 |
Intercept 0.07 + feature contributions = -2.729 (log-odds).
Score = sigmoid(-2.729) = 0.061.
| Score | 0.03 |
|---|
| Score | 6 |
|---|
Run 1
The code has clear intent and is logically organized, but formatting severely hampers readability. Imports are correctly grouped, and the class has clear Javadoc. However, multiple statements are placed on single lines (e.g., class declaration with constructor, method declarations with logic), violating action granularity and natural flow. Braces are misaligned in several places, making structure harder to follow. Nesting is minimal, but code length is unnecessarily compacted. The deprecation annotations and Assert checks are clear, but the compressed formatting obscures the logical separation of concerns.
Run 2
The code lacks proper line breaks and consistent indentation, making it visually dense and hard to scan. Multiple statements share lines, class declarations merge with methods, and import statements are not cleanly separated. While the logic and intent are straightforward, the formatting hurts readability. Javadoc comments are well-written but poorly integrated into the code layout. Restructuring with proper line breaks, one action per line, and cleaner method separation would significantly improve readability.
Run 3
The code is moderately readable but suffers from formatting and structural issues. The class has a clear purpose and follows standard Spring converter patterns, with helpful Javadoc explaining usage. However, imports are crammed onto single lines, multiple methods and Javadoc blocks appear on the same line as declarations, and the constructor bodies lack proper line breaks. This creates dense, difficult-to-scan code. Nesting is acceptable (flat structure), and each method performs one logical action, but the reading flow is disrupted by poor vertical spacing and line organization. The overridden setObjectMapper method is straightforward but its opening brace placement harms readability. Overall, the code would be significantly improved with standard formatting: one import per line, separated Javadoc blocks, and proper line breaks between declarations and method bodies.
Run 1
Code Structure: The class is logically organized into constructors and an overridden setter, but compressed formatting obscures member boundaries. Nesting: Minimal nesting makes the logic easy to follow. Clarity of intent: Descriptive names, detailed documentation, and explicit CBORFactory validation clearly communicate purpose and requirements. Code length: The implementation is concise; documentation is longer than the logic but useful. Action granularity: Multiple imports and constructor statements share lines, while annotations, declarations, comments, and closing braces are inconsistently combined. Reading flow: The default-to-custom constructor delegation and setter validation follow a natural sequence, but missing spacing and irregular line breaks interrupt scanning. Overall, straightforward functionality and strong documentation are undermined by poor formatting.
Run 2
Code Structure: The class is logically organized into constructors and an overridden setter, but inconsistent formatting obscures member boundaries. Nesting: Minimal nesting makes the logic easy to follow. Clarity of intent: Descriptive names, detailed documentation, and explicit CBORFactory checks clearly communicate purpose and constraints. Code length: The implementation is concise; documentation is longer than the executable code but provides useful context. Action granularity: Multiple imports and constructor statements share lines, reducing scanability and violating one-action-per-line formatting. Reading flow: The order is natural, but comments attached to braces, annotations sharing declaration lines, and closing braces appended to statements interrupt smooth reading.
Run 3
Code Structure: Imports, documentation, constructors, and the override are logically organized, but compressed formatting obscures their boundaries. Nesting: Very shallow, with no conditional or loop nesting. Clarity of intent: Descriptive names and useful Javadoc clearly explain CBOR support and ObjectMapper validation. Code length: The implementation is concise without unnecessary logic; documentation is proportionate. Action granularity: Multiple imports and constructor statements share lines, making individual actions harder to scan. Reading flow: The conventional class layout helps, but comments attached to braces, annotations sharing method declaration lines, and inline closing braces interrupt natural reading. Consistent line breaks and spacing would substantially improve readability.