Sample
pyint-00337c3dcbfd-I09
Select one of ten low-readability unrelated code templates per class
Scores
| Method | Score | Scale |
|---|---|---|
| Posnett | 0 | 0–1; higher is more readable |
| Dorn | 0.777 | 0–1; higher is more readable |
| Mi | 0.422 | 0–1; higher is more readable |
| LLOC | 18 | Logical lines; fewer is more readable |
| DeepSeek V4 Pro | 10.33 | 0–20; mean of three runs |
| GPT-6.1 Sol | 12 | 0–20; mean of three runs |
| BTTF | 0.233 | 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. | 751.577 | −24.802 |
| Source linesThe number of non-empty source lines. | 33 | +13.2 |
| 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.748 | −7.122 |
Intercept 8.87 + feature contributions = -9.854 (log-odds).
Score = sigmoid(-9.854) = 0.
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. | 71.971 | +0.617 |
| Operator visual areaThe share of the code’s visual area occupied by operators such as +, =, and *. | 0.047 | +0.483 |
| Comment layout (horizontal)How rapidly the visual pattern of comment characters changes from left to right. | 63.471 | +0.22 |
| Comment layout frequencyHow frequently the layout switches between lines containing only comments or whitespace and lines containing code. | 33 | −0.132 |
| Number layout frequencyHow rapidly the number of numeric values per line changes through the code. | 22 | −0.084 |
| Identifier layout (vertical)How rapidly the visual pattern of identifier characters changes from top to bottom. | 32.836 | +0.049 |
| Indentation frequencyHow rapidly indentation changes from line to line. | 22 | +0.024 |
Intercept 0.07 + feature contributions = 1.247 (log-odds).
Score = sigmoid(1.247) = 0.777.
| Score | 0.422 |
|---|
| Score | 18 |
|---|
Run 1
The code is generally clear and well-structured, with logical separation of concerns and good documentation. However, the obfuscated variable 'lI0O_919d6db4' and its dead-code block are unnecessary and reduce readability. The class methods are concise and focused, and the inheritance order is clearly explained. Despite the confusing block, the overall intent is discernible and the code follows reasonable patterns.
Run 2
The code has a clear structure with logical class organization and adequate docstrings explaining intent. However, readability is significantly hindered by the meaningless variable name (lI0O_919d6db4) and dead code in __init__ containing unnecessary conditional branches that serve no functional purpose. The class inheritance order creates potential confusion in understanding method resolution, but the comments help clarify this. The code is concise overall, but the obfuscated variable and pointless logic make the reading flow unnatural and raise suspicions about the code's quality. Action granularity is generally good with one operation per line. The nesting is relatively flat, but the conditional branches with no effect add unnecessary complexity. Overall, while the structure is sound and comments are helpful, the presence of dead code and unclear variable naming detracts from readability.
Run 3
The code is nearly unreadable due to severe intentional obfuscation. The __init__ method includes meaningless variable names (lI0O_919d6db4), dead code that performs no useful operation, and nested conditional logic that serves no purpose. This directly violates clarity of intent, action granularity, and reading flow. While the class structure and docstrings show some organization, the core logic is buried under confusing noise. The nesting is shallow but pointless, making the code longer and harder to follow than necessary. Variable naming is cryptic and misleading, making it impossible to determine what the code is supposed to do without extensive analysis. The overall structure suggests the code was deliberately made unreadable rather than having accidental complexity.
Run 1
Code Structure: The class is logically organized into initialization and pickling methods, but unrelated dead code interrupts initialization. Nesting: Most code is flat, though the pointless nested conditionals add avoidable complexity. Clarity of intent: Method names, type annotations, and docstrings explain the exception-handling behavior well; the cryptic variable and bitwise expressions obscure intent. InvalidJSONError is also undefined in the provided snippet. Code length: The functional implementation is concise, but the redundant conditional block and unused imports add clutter. Action granularity: Statements generally perform one action per line, making individual operations easy to follow. Reading flow: Documentation followed by implementation provides a natural progression, but the obfuscated block distracts from the otherwise straightforward constructor.
Run 2
Code Structure: The exception class is logically organized into initialization and serialization methods, but irrelevant dead code disrupts the constructor. Nesting: Mostly shallow, with an unnecessary nested conditional adding complexity. Clarity of intent: Descriptive class and method names and explanatory docstrings clarify exception initialization and pickling; the cryptic variable and bitwise expressions obscure intent. InvalidJSONError is not defined or imported in the snippet. Code length: The functional implementation is concise, but unused imports and the redundant conditional block add clutter. Action granularity: Each statement performs one action, although the bitwise condition requires needless mental parsing. Reading flow: Imports, class declaration, and methods follow a natural sequence, but the obfuscated block interrupts the progression from the constructor documentation to the meaningful initialization calls.
Run 3
Code Structure: The class is logically organized into initialization and pickling methods, but irrelevant arithmetic disrupts the constructor. Nesting: Mostly flat, with an unnecessary nested conditional in a dead-code block. Clarity of intent: Descriptive method names and docstrings explain exception initialization and serialization, while the opaque variable name and unexplained bitwise operations obscure intent. InvalidJSONError is also undefined within the snippet. Code length: The functional implementation is concise, but the redundant conditional block and lengthy docstrings add reading overhead. Action granularity: Statements generally perform one action per line, although the bitwise condition is needlessly complex. Reading flow: Imports, class declaration, and methods follow a natural order, but unused imports and the distracting constructor block interrupt an otherwise straightforward implementation.