Sample
int-587abfcac0ef-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.658 | 0–1; higher is more readable |
| Dorn | 0.439 | 0–1; higher is more readable |
| Mi | 0.154 | 0–1; higher is more readable |
| LLOC | 14 | Logical lines; fewer is more readable |
| DeepSeek V4 Pro | 14.67 | 0–20; mean of three runs |
| GPT-6.1 Sol | 12.67 | 0–20; mean of three runs |
| BTTF | 0.204 | 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. | 1283.344 | −42.35 |
| Source linesThe number of non-empty source lines. | 50 | +20 |
| 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.109 | −7.663 |
Intercept 8.87 + feature contributions = -21.144 (log-odds).
Score = sigmoid(-21.144) = 0.
| Score | 0.658 |
|---|
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. | 113.941 | −1.161 |
| Comment layout (horizontal)How rapidly the visual pattern of comment characters changes from left to right. | 114 | +1.035 |
| Comment layout frequencyHow frequently the layout switches between lines containing only comments or whitespace and lines containing code. | 51 | −0.769 |
| Indentation frequencyHow rapidly indentation changes from line to line. | 32 | +0.37 |
| Number layout frequencyHow rapidly the number of numeric values per line changes through the code. | 32 | −0.313 |
| Identifier layout (vertical)How rapidly the visual pattern of identifier characters changes from top to bottom. | 49.73 | +0.285 |
| Operator visual areaThe share of the code’s visual area occupied by operators such as +, =, and *. | 0.072 | +0.238 |
Intercept 0.07 + feature contributions = -0.246 (log-odds).
Score = sigmoid(-0.246) = 0.439.
| Score | 0.154 |
|---|
| Score | 14 |
|---|
Run 1
The code is well-structured with clear separation of concerns and logical organization. Nesting is minimal with only a single conditional level in generateKey. Intent is clearly communicated through descriptive method names and Javadoc. Code length is concise without unnecessary verbosity. However, the presence of an obfuscated switch statement with XOR operations and meaningless variable names significantly hurts readability - this appears to be injected or generated code that serves no purpose and makes the flow harder to follow. Without this artifact, the code would be exemplary.
Run 2
The code is generally readable for its small size, but several factors reduce its clarity. The class structure and method purpose are clear, with a straightforward single-method implementation. However, the presence of obfuscated-looking code in the generateKey method (an irrelevant switch statement with a bitwise operation) significantly harms readability and intent. Nesting is low, which is good, and the action granularity is mostly one action per line. The use of varargs with @Nullable is idiomatic for this Spring context. The conditional expression in the main generate method is acceptable but slightly dense. The length of the method is concise, but the unnecessary switch statement adds confusion. Overall, the code would be highly readable if that artifact were removed, as it violates the principle of clear intent and introduces a non-standard construct that gives the impression of obfuscation.
Run 3
The code is generally readable with clear intent and logical structure. Class-level documentation is thorough, method names are descriptive, and the single public interface method is concise. However, readability is hurt by the odd obfuscated line that appears to do nothing, likely an anti-tampering or bytecode artifact. The nested conditional in generateKey is moderately deep but acceptable. There is an unaesthetic opening brace placement in generateKey, and the ternary in generate() slightly reduces clarity. Overall, the core logic is readable, but the unnecessary noise brings the score down.
Run 1
1. Code Structure: The class and two methods are logically organized, but an unrelated no-op block disrupts the key-generation logic. 2. Nesting: The meaningful logic uses shallow nesting and early returns; the injected switch adds unnecessary complexity. 3. Clarity of intent: Documentation and descriptive method names explain key generation well, but the cryptic variable, hexadecimal XOR, and redundant assignments obscure the injected block's purpose. 4. Code length: Most code is concise, although the no-op block adds entirely unnecessary content. 5. Action granularity: Normal statements are clearly separated, but the injected block compresses declaration, switch cases, assignments, and breaks onto one line. 6. Reading flow: The main logic progresses naturally from zero parameters to one parameter to a composite key; the unindented, obfuscated block abruptly interrupts that flow.
Run 2
Code Structure: The class is logically divided into delegation and key-generation methods, but an unrelated obfuscated block disrupts that organization. Nesting: The meaningful logic is shallow, with straightforward conditionals; the injected block adds unnecessary scope and switch nesting. Clarity of intent: Documentation and descriptive method names explain key generation clearly, while the cryptic variable, hexadecimal XOR, and ineffective bitwise operations obscure intent. Code length: The functional implementation is concise, but the no-op block adds unnecessary code. Action granularity: Most statements occupy separate lines, whereas the entire injected block compresses declaration, branching, assignments, and breaks onto one line. Reading flow: Early returns make the main logic easy to follow, and the Kotlin-specific ternary is reasonably readable, but the poorly formatted block abruptly interrupts the flow.
Run 3
Code Structure: The class is logically organized into delegation and key-generation methods, but an unrelated obfuscated block disrupts that structure. Nesting: Most logic is shallow with early returns; the single-parameter check adds modest nesting, while the inserted switch adds unnecessary complexity. Clarity of intent: Documentation, method names, and straightforward conditions clearly explain key generation, but the cryptic variable, hexadecimal XOR, and no-op assignments obscure intent. Code length: The functional implementation is concise, although the redundant switch block adds needless code. Action granularity: Normal statements perform one action per line; the obfuscated block compresses declarations, branching, assignments, and breaks onto one line. Reading flow: The main algorithm progresses naturally from empty parameters to a single usable parameter to a composite key, but the unformatted block abruptly interrupts that flow. The Kotlin-specific ternary is compact and reasonably understandable.