Sample
int-9143dbc94835-I03
Replace method, parameter, and local names with length-matched, meaningful but unrelated names
Scores
| Method | Score | Scale |
|---|---|---|
| Posnett | 0 | 0–1; higher is more readable |
| Scalabrino | 0.819 | 0–1; higher is more readable |
| Dorn | 0.527 | 0–1; higher is more readable |
| Mi | 0.217 | 0–1; higher is more readable |
| LLOC | 6 | Logical lines; fewer is more readable |
| DeepSeek V4 Pro | 17 | 0–20; mean of three runs |
| GPT-6.1 Sol | 16 | 0–20; mean of three runs |
| BTTF | 0.71 | 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. | 1065.982 | −35.177 |
| Source linesThe number of non-empty source lines. | 61 | +24.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. | 5.172 | −7.758 |
Intercept 8.87 + feature contributions = -9.665 (log-odds).
Score = sigmoid(-9.665) = 0.
| Score | 0.819 |
|---|
Feature contributions
| Feature | Value | Contribution (log-odds) |
|---|---|---|
| Comment layout frequencyHow frequently the layout switches between lines containing only comments or whitespace and lines containing code. | 62 | −1.159 |
| Comment layout (horizontal)How rapidly the visual pattern of comment characters changes from left to right. | 103.968 | +0.873 |
| 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. | 103.968 | −0.738 |
| 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. | 60.905 | +0.441 |
| Indentation frequencyHow rapidly indentation changes from line to line. | 33 | +0.404 |
| Number layout frequencyHow rapidly the number of numeric values per line changes through the code. | 33 | −0.336 |
Intercept 0.07 + feature contributions = 0.107 (log-odds).
Score = sigmoid(0.107) = 0.527.
| Score | 0.217 |
|---|
| Score | 6 |
|---|
Run 1
The code is well-structured and readable, with clear package/import organization and Javadoc documentation that explains the class purpose and constructors. The class follows Spring conventions and the logic is flat—no deep nesting or complex control flow. Each constructor is concise and performs a single delegation, making intent clear. The use of Assert.isInstanceOf improves readability by validating preconditions explicitly. One minor issue is the unnecessarily verbose naming of parameters like 'recentConfig' and 'primaryEvent', which are ambiguous despite referring to ObjectMapper. Overall, the code is maintainable and easy to follow.
Run 2
The code is highly readable with a clear class-level Javadoc explaining purpose, usage, and deprecation. Structure is logical: imports, class declaration, constructors, and overridden method are well-organized. Nesting is minimal—no conditional blocks or deep indentation. Intent is explicit through descriptive naming and documentation. Code length is concise; each method performs a single action or delegates clearly. Action granularity is mostly one action per line, especially in constructors and validation. Reading flow is natural: constructors are grouped, and validation logic is isolated. Minor readability improvement could be renaming parameters like 'recentConfig' and 'primaryEvent' to more conventional names (e.g., 'objectMapper'), but this does not significantly detract. Overall, it follows clean code principles and Spring framework conventions.
Run 3
The code is well-structured and readable. It clearly separates concerns with a compact class definition, two constructors, and a single overridden method. Nesting is minimal, and intent is explicit through descriptive names and Javadoc. However, the parameter names in the second constructor and overridden method are misleading: 'recentConfig' and 'primaryEvent' suggest unrelated purposes, contrary to their actual role as ObjectMapper instances. This ambiguity reduces clarity of intent and could confuse maintainers. Additionally, the method name 'validateSession' does not align with its actual responsibility of validating the ObjectMapper's factory and setting it. Overall, the code is concise and well-organized but would benefit from more accurate naming to enhance readability.
Run 1
Code Structure: Well-organized class with constructors followed by an overridden method; documentation clearly separates responsibilities. Nesting: Flat method bodies with no conditional or loop nesting. Clarity of intent: CBOR configuration and validation are explicit, but misleading names such as recentConfig, primaryEvent, and validateSession obscure their ObjectMapper-related purpose. The mismatch between validateSession and its call to super.setObjectMapper also makes the override confusing. Code length: Implementation is concise; documentation is substantial but mostly useful. Action granularity: Each statement performs one primary action, with straightforward constructor delegation and validation. Reading flow: Generally natural, progressing from default construction to custom configuration and mapper validation. Missing spacing after the package declaration and an extra blank line slightly reduce formatting consistency.
Run 2
Code Structure: Imports, class documentation, constructors, and the override are logically organized. Nesting: Methods are flat, with no nested control flow. Clarity of intent: Documentation and CBOR validation clearly establish the converter's purpose, but recentConfig and primaryEvent obscure that parameters are ObjectMapper instances. The name validateSession is especially misleading because the method validates and sets an object mapper rather than handling a session. Code length: Implementation is concise; documentation is somewhat lengthy but useful. Action granularity: Each statement occupies its own line, and constructor delegation keeps initialization simple. Reading flow: The progression from default construction to custom configuration is natural, though the inconsistent override name interrupts comprehension.
Run 3
Code Structure: Imports, class documentation, constructors, and the override are logically organized. Nesting: Flat methods with no branching or loops make the code easy to scan. Clarity of intent: Documentation clearly explains CBOR conversion and factory requirements, but recentConfig and primaryEvent obscure their ObjectMapper role. The name validateSession conflicts with its mapper-setting behavior and the superclass method it calls, making the override questionable. Code length: Implementation is concise; documentation is somewhat lengthy but useful. Action granularity: Each statement performs a distinct action, with straightforward constructor delegation and validation. Reading flow: The progression from default construction to custom configuration is natural, though the misleading final method name disrupts understanding.