Sample
int-18ec5bbec5aa-I09
Select one of ten low-readability unrelated code templates per class
Scores
| Method | Score | Scale |
|---|---|---|
| Posnett | 0 | 0–1; higher is more readable |
| Scalabrino | 0.482 | 0–1; higher is more readable |
| Dorn | 0.305 | 0–1; higher is more readable |
| Mi | 0.467 | 0–1; higher is more readable |
| LLOC | 40 | Logical lines; fewer is more readable |
| DeepSeek V4 Pro | 13 | 0–20; mean of three runs |
| GPT-6.1 Sol | 15.33 | 0–20; mean of three runs |
| BTTF | 0.216 | 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. | 4095.522 | −135.152 |
| Source linesThe number of non-empty source lines. | 109 | +43.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.012 | −7.518 |
Intercept 8.87 + feature contributions = -90.2 (log-odds).
Score = sigmoid(-90.2) = 0.
| Score | 0.482 |
|---|
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. | 110 | −2.858 |
| Indentation frequencyHow rapidly indentation changes from line to line. | 93 | +2.48 |
| Number layout frequencyHow rapidly the number of numeric values per line changes through the code. | 93 | −1.713 |
| Identifier layout (vertical)How rapidly the visual pattern of identifier characters changes from top to bottom. | 108.841 | +1.112 |
| 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. | 111.955 | −1.077 |
| Comment layout (horizontal)How rapidly the visual pattern of comment characters changes from left to right. | 111.855 | +1 |
| Operator visual areaThe share of the code’s visual area occupied by operators such as +, =, and *. | 0.08 | +0.162 |
Intercept 0.07 + feature contributions = -0.824 (log-odds).
Score = sigmoid(-0.824) = 0.305.
| Score | 0.467 |
|---|
| Score | 40 |
|---|
Run 1
The code has reasonable structure and naming, but a critical bug in the getTarget() method contains an obfuscated, meaningless line with a randomly generated variable name and a no-op conditional loop. This severely damages readability, violating clarity of intent and reading flow. Additionally, the class-level Javadoc contains grammatical errors ('or wrap' should be 'or wraps'), and the generate method performs multiple operations per line (type cast, method call, exception throwing) reducing action granularity. The createCacheKeyInvocationContext method is concise but the unchecked cast adds noise. The generic type usage is complex but acceptable. Overall, while the core logic is understandable, the obfuscated dead code and compression of actions make it difficult to read and maintain.
Run 2
The code is generally structured and follows Spring conventions, but has a notable readability issue: an unexplained artifact line in getTarget() containing obfuscated logic (`{int lI0O...}`). This breaks the reading flow and clarity of intent. Otherwise, the class uses clear naming, flat structure, minimal nesting, and concise methods with reasonable action granularity. Constructors and null checks are straightforward, and the main generate() method is easy to follow. The varargs handling in doGenerate() is slightly dense but acceptable. Overall, it’s readable except for the stray obfuscated line.
Run 3
The code is generally well-structured with clear class and method organization. It has reasonable nesting depth (mostly 1-2 levels), and intent is mostly clear through descriptive method names and Javadoc. However, there's a significant readability issue: an injected obfuscated line in getTarget() that appears to be dead code and breaks flow. The varargs handling logic in doGenerate is slightly complex with conditional collection handling. Constructor overloading is clear, and null-check assertions improve clarity. Overall readable but the obfuscated line and minor complexity in parameter handling prevent a higher score.
Run 1
Code Structure: Well-organized adapter with distinct constructors and focused helper methods, except for an unrelated block in getTarget(). Nesting: Generally shallow; the parameter loop contains manageable conditional nesting, but the injected block uses unnecessarily nested ternaries. Clarity of intent: Descriptive names, documentation, and assertions clarify key-generation behavior; the cryptic variable and meaningless bitwise expressions obscure intent locally. Code length: Mostly concise, with minor constructor duplication and an unnecessary computation block. Action granularity: Normally one action per line, but the injected block compresses declaration, assignment, and conditional expressions onto one line. Reading flow: Methods follow a logical progression and use consistent formatting, interrupted sharply by the unindented, obfuscated block. Overall, the main implementation is readable, but the conspicuous dead computation reduces clarity and consistency.
Run 2
Code Structure: Constructors and focused helper methods organize the adapter logically, but getTarget contains an unrelated obfuscated block. Nesting: Most methods are shallow; the parameter loop has manageable conditional nesting, while the injected nested ternary adds needless complexity. Clarity of intent: Descriptive names, documentation, and assertions explain delegation and parameter handling well; the cryptic variable and redundant bitwise expressions obscure intent locally. Code length: Mostly concise, with some repeated initialization checks and unnecessary dead computation. Action granularity: Normal code uses one action per line, but the obfuscated block compresses declaration, assignment, and nested expressions into one line. Reading flow: Delegation and helper extraction provide a natural progression, interrupted sharply by the unindented, irrelevant block.
Run 3
Code Structure: The adapter is logically divided into constructors, delegation methods, parameter handling, and context creation, but an unrelated block disrupts getTarget(). Nesting: Most methods are shallow; the parameter loop has manageable nesting, while the injected nested ternary is unnecessarily complex. Clarity of intent: Descriptive names, documentation, and assertions explain the adapter's purpose, but the cryptic variable and meaningless bitwise expressions obscure intent locally. Code length: The functional implementation is reasonably concise, although the unrelated block adds needless code. Action granularity: Most statements perform one action per line; the injected block compresses declaration, assignment, and conditional expressions onto one line. Reading flow: Method organization and consistent formatting generally support natural reading, but the unindented, dense block sharply interrupts that flow.