Sample
int-9f8148e8fcb7-I07
Insert deterministic runtime-dead branches into callable bodies
Scores
| Method | Score | Scale |
|---|---|---|
| Posnett | 0 | 0–1; higher is more readable |
| Scalabrino | 0.399 | 0–1; higher is more readable |
| Dorn | 0.011 | 0–1; higher is more readable |
| Mi | 0.041 | 0–1; higher is more readable |
| LLOC | 10 | Logical lines; fewer is more readable |
| DeepSeek V4 Pro | 8 | 0–20; mean of three runs |
| GPT-6.1 Sol | 14 | 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. | 1342.988 | −44.319 |
| Source linesThe number of non-empty source lines. | 23 | +9.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.954 | −7.43 |
Intercept 8.87 + feature contributions = -33.679 (log-odds).
Score = sigmoid(-33.679) = 0.
| Score | 0.399 |
|---|
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. | 174 | −3.705 |
| Comment layout (horizontal)How rapidly the visual pattern of comment characters changes from left to right. | 0 | −0.804 |
| Comment layout frequencyHow frequently the layout switches between lines containing only comments or whitespace and lines containing code. | 23 | +0.222 |
| Operator visual areaThe share of the code’s visual area occupied by operators such as +, =, and *. | 0.113 | −0.161 |
| Number layout frequencyHow rapidly the number of numeric values per line changes through the code. | 23 | −0.107 |
| Identifier layout (vertical)How rapidly the visual pattern of identifier characters changes from top to bottom. | 22.851 | −0.09 |
| Indentation frequencyHow rapidly indentation changes from line to line. | 23 | +0.058 |
Intercept 0.07 + feature contributions = -4.517 (log-odds).
Score = sigmoid(-4.517) = 0.011.
| Score | 0.041 |
|---|
| Score | 10 |
|---|
Run 1
The code contains dead code (unreachable assertion checks that always evaluate to false) which severely hurts readability and clarity of intent. The structure is minimal but functional; however, the class has very little logical organization beyond simple static methods. Nesting is flat, which is good, and the code length is concise. Action granularity is mostly one action per line, and reading flow is natural when ignoring the dead code. But the presence of nonsensical conditional blocks makes the code ambiguous and confusing: a reader must waste time checking whether those conditions can ever be true. Additionally, the hardcoded 'role' string in createAuthorizer makes intent unclear. Overall, while the structure is simple and concise, the dead code and lack of meaningful explanation significantly reduce readability.
Run 2
The code is well-structured with logical method separation and clear purpose: creating an Authorizer plugin and checking a cluster resource name. Nesting is minimal, and action granularity is mostly one action per line. However, readability is reduced by dead code in the form of obfuscated assertions, such as `if (((0x4D09 ^ 0x4D09) != 0)) { throw new AssertionError(); }`, which serve no purpose and break the natural reading flow. The import order and spacing are slightly unconventional but not harmful. Method names and parameters are clear, but the meaningless checks and minor formatting issues prevent a higher score.
Run 3
The code is short, but readability suffers from unnecessary dead code and misleading patterns. Each method contains an impossible assertion check (XOR of identical values always equals 0, so the condition is always false) that adds noise, confuses intent, and has no purpose. The action granularity is poor: method calls are chained on single lines, and the createAuthorizer signature is cramped. Import formatting is inconsistent with no separation between packages. The class name and method names are generally clear, and the logic itself is simple, but the unnatural assertions disrupt reading flow and mislead any reader. Code structure is acceptable at the class level, but the dead code and lack of environmental clarity (why metrics, key, role?) reduce clarity of intent. Overall, the code requires unnecessary mental effort to parse and discount irrelevant lines, making it significantly less readable than its underlying logic suggests.
Run 1
Code Structure: Two small, logically separated utility methods, but irrelevant assertion guards disrupt the organization. Nesting: Minimal nesting; each guard introduces only one level. Clarity of intent: Method names and core operations are clear, while hexadecimal XOR conditions obscure intent despite always evaluating to false. Code length: Concise overall, though the dead guards add unnecessary code and the factory signature is long. Action granularity: Core operations use one action per line, but each guard compresses its condition, block, and throw onto one line. Reading flow: Instantiation, configuration, and wrapping follow a natural sequence; unindented guards and tightly packed imports reduce visual consistency.
Run 2
Code Structure: Two small, logically separated utility methods provide clear organization, but unrelated assertion guards add noise. Nesting: Almost entirely flat, with only shallow conditional blocks. Clarity of intent: Descriptive method names and straightforward API calls communicate the main purpose; hexadecimal XOR conditions obscure intent despite always evaluating to false. Code length: Concise overall, although the dead guards are unnecessary and the createAuthorizer signature is overly long. Action granularity: Main operations occupy separate lines, but each guard compresses a condition and throw into one line. Reading flow: Authorizer creation, configuration, and wrapping follow a natural sequence; inconsistent indentation, cramped imports, and unexplained guards interrupt that flow.
Run 3
Code Structure: Two focused utility methods provide logical organization, but unindented dead-code assertions disrupt consistency. Nesting: The code is mostly flat, with only shallow conditional blocks. Clarity of intent: Method names and core operations clearly communicate their purposes; hexadecimal XOR conditions that are always false introduce needless ambiguity. Code length: The implementation is short, although the assertions add unnecessary code and the long method signature could be wrapped. Action granularity: Core operations use one action per line, but each assertion compresses a condition, block, and throw onto one line. Reading flow: Authorizer creation, configuration, and wrapping follow a natural sequence; inconsistent indentation, dense assertions, and missing spacing between package and imports interrupt the flow.