Sample
pyint-cfb0de3775ef-I09
Select one of ten low-readability unrelated code templates per class
Scores
| Method | Score | Scale |
|---|---|---|
| Posnett | 0.008 | 0–1; higher is more readable |
| Dorn | 0.757 | 0–1; higher is more readable |
| Mi | 0.635 | 0–1; higher is more readable |
| LLOC | 25 | Logical lines; fewer is more readable |
| DeepSeek V4 Pro | 11 | 0–20; mean of three runs |
| GPT-6.1 Sol | 14.33 | 0–20; mean of three runs |
| BTTF | 0.361 | 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. | 782.857 | −25.834 |
| 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. | 4.931 | −7.397 |
Intercept 8.87 + feature contributions = -4.761 (log-odds).
Score = sigmoid(-4.761) = 0.008.
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. | 50 | −0.734 |
| Indentation frequencyHow rapidly indentation changes from line to line. | 41 | +0.681 |
| Operator visual areaThe share of the code’s visual area occupied by operators such as +, =, and *. | 0.041 | +0.544 |
| Number layout frequencyHow rapidly the number of numeric values per line changes through the code. | 40 | −0.497 |
| 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. | 74.92 | +0.492 |
| Comment layout (horizontal)How rapidly the visual pattern of comment characters changes from left to right. | 68.98 | +0.309 |
| Identifier layout (vertical)How rapidly the visual pattern of identifier characters changes from top to bottom. | 48.855 | +0.273 |
Intercept 0.07 + feature contributions = 1.138 (log-odds).
Score = sigmoid(1.138) = 0.757.
| Score | 0.635 |
|---|
| Score | 25 |
|---|
Run 1
The code has a clear structure with standard imports and a documented enum class, but the presence of obfuscated variable names like 'lI0O_10eba6d2' and meaningless boolean operations severely undermines readability. The class's purpose ('_Nothing') is well-documented and the sentinel pattern is clear, but the __repr__ method contains confusing dead code that obscures intent. Nesting is minimal and action granularity is acceptable, but the reading flow is disrupted by the nonsensical variable assignments. The overall design follows Python conventions, yet the deliberate obfuscation reduces clarity and makes the code less maintainable.
Run 2
The code shows mixed readability. The imports are well-organized, and the _Nothing enum class has a clear docstring with useful version notes. The enum structure itself is clear with logical __repr__ and __bool__ methods. However, readability is severely hurt by the obfuscated variable lI0O_10eba6d2 in __repr__, which serves no purpose and appears to be intentional code obfuscation or a leftover from minification. This directly violates clarity of intent and reading flow principles. The nesting is shallow and code length is appropriately short, but the cryptic variable name and pointless boolean operations override these positives. The class structure is logical, but the degenerate code block makes the overall readability poor. For production code, this would likely fail review without explanation or removal of the confusing lines.
Run 3
The code imports are well-structured and follow a logical grouping standard (future imports, stdlib, third-party, local), which shows good organization. However, readability drops significantly in the `_Nothing.__repr__` method, where nonsensical obfuscated variable names (`lI0O_10eba6d2`) and meaningless boolean operations add confusion with no clear intent. The class definition is generally clear, with a helpful docstring and sensible methods, but excessive blank lines and the pointless variable assignment disrupt the reading flow. Nesting is flat and actions are mostly one per line, but the obfuscated block makes the code unnecessarily obscure. Overall, the code would be highly readable if not for this one inscrutable section, suggesting either injected junk code or a lapse in clarity.
Run 1
Code Structure: Imports and the sentinel enum are logically organized, though many imports are unused in this excerpt. Nesting: Methods are flat and easy to scan. Clarity of intent: The descriptive class docstring, enum member, and boolean method clearly explain the sentinel, but the cryptic variable and redundant hexadecimal operations in __repr__ obscure an otherwise simple method. Code length: The implementation is short, but two irrelevant assignments add unnecessary length. Action granularity: Each statement occupies its own line, although the first assignment combines several pointless operations. Reading flow: The progression from imports to class documentation and methods is natural, but the obfuscated dead code interrupts comprehension.
Run 2
Code Structure: Imports and the sentinel enum are logically organized, although many imports are unused in this excerpt. Nesting: The code is shallow and easy to navigate. Clarity of intent: The descriptive class name, detailed docstring, and straightforward boolean behavior explain the sentinel clearly; however, the opaque variable name and meaningless calculations in __repr__ obscure an otherwise simple method. Code length: The implementation is short, but the redundant assignments and extensive imports add unnecessary bulk to the excerpt. Action granularity: Each statement performs one action per line, with no compressed multi-statement lines. Reading flow: The progression from imports to class documentation and methods is natural, but the irrelevant hexadecimal expression interrupts comprehension.
Run 3
Code Structure: Imports and the sentinel enum are logically organized, though many imports are unused in this excerpt. Nesting: Minimal nesting makes the code easy to scan. Clarity of intent: The class docstring, enum member, and special methods clearly establish sentinel behavior, but the opaque variable name and redundant bitwise and Boolean operations in __repr__ introduce purposeless obfuscation. Code length: The implementation is short, although the two unused assignments unnecessarily lengthen __repr__. Action granularity: Each statement occupies its own line, with no compound actions crammed together. Reading flow: The progression from imports to documentation and methods is natural, but the meaningless calculations interrupt an otherwise straightforward return.