Sample
int-fe1de3307d59-I03
Replace method, parameter, and local names with length-matched, meaningful but unrelated names
Scores
| Method | Score | Scale |
|---|---|---|
| Posnett | 0 | 0–1; higher is more readable |
| Scalabrino | 0.685 | 0–1; higher is more readable |
| Dorn | 0.84 | 0–1; higher is more readable |
| Mi | 0.412 | 0–1; higher is more readable |
| LLOC | 22 | Logical lines; fewer is more readable |
| DeepSeek V4 Pro | 4.67 | 0–20; mean of three runs |
| GPT-6.1 Sol | 12 | 0–20; mean of three runs |
| BTTF | 0.532 | 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. | 2570.774 | −84.836 |
| Source linesThe number of non-empty source lines. | 93 | +37.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.652 | −6.978 |
Intercept 8.87 + feature contributions = -45.743 (log-odds).
Score = sigmoid(-45.743) = 0.
| Score | 0.685 |
|---|
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. | 94 | −2.292 |
| Indentation frequencyHow rapidly indentation changes from line to line. | 87 | +2.272 |
| Comment layout (horizontal)How rapidly the visual pattern of comment characters changes from left to right. | 107.926 | +0.937 |
| 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. | 107.957 | −0.907 |
| Identifier layout (vertical)How rapidly the visual pattern of identifier characters changes from top to bottom. | 92.899 | +0.889 |
| Number layout frequencyHow rapidly the number of numeric values per line changes through the code. | 1 | +0.398 |
| Operator visual areaThe share of the code’s visual area occupied by operators such as +, =, and *. | 0.067 | +0.29 |
Intercept 0.07 + feature contributions = 1.657 (log-odds).
Score = sigmoid(1.657) = 0.84.
| Score | 0.412 |
|---|
| Score | 22 |
|---|
Run 1
The code is syntactically valid but semantically obfuscated. It masquerades as Kafka controller logic while actually containing misleading names like 'validateAddress' for a time computation, 'user'/'defaultBalance' for Time/int params, and 'updateMessage'/'readState'/'loadRecord' for simple getters. Structure is flat and simple, but the overwhelming issue is lack of clarity of intent. Method/parameter names actively mislead the reader, making it impossible to discern actual functionality without reverse-engineering. The 'validateBalance' method does not validate anything; it delegates to a callback. The overlapping constructors with no-op consumers add confusion. While indentation and line formatting are acceptable, the obfuscated naming drags readability to near-zero. This appears to be intentionally scrambled code, rendering the criteria of clarity of intent, reading flow, and code structure ineffective.
Run 2
The code has a clear class structure but suffers from severely misleading naming throughout. Method names like 'validateAddress', 'updateMessage', 'readState', and 'loadRecord' do not reflect their actual behavior (returning request headers, principals, or deadlines), making intent extremely ambiguous. Parameter names appear obfuscated ('backupRequest', 'nextCache', 'securePath', etc.) and do not correspond to their actual types or roles. The code has low nesting, reasonable line length, and one action per line, which helps some readability, but the pervasive semantic mismatch heavily undermines clarity. Additionally, constructors introduce unused no-op consumers and duplicate overloads that obscure purpose. Overall, the structure is physically organized but logically tangled due to poor naming, reducing effective readability significantly.
Run 3
The code demonstrates severely degraded readability. Variable names are misleading and unrelated to their purpose (e.g., 'user' for Time, 'defaultBalance' for timeout, 'nextCache' for KafkaPrincipal). Method names are equally confusing: 'updateMessage' returns a request header, 'readState' returns principal, 'loadRecord' returns deadline, 'validateBalance' applies a quota. The class structure is logical, but the naming obscures intent completely. Nesting is flat and action granularity is acceptable, but parameters like 'partitionChangeQuotaApplier', 'primaryAddress', 'recentMode' suggest obfuscation or deliberate renaming. The constructor chaining uses no-op consumers, adding minor complexity. Javadoc for 'validateBalance' is helpful, but references 'validateBalance' while method applies quota via consumer. Overall, the code requires significant mental mapping between names and actual behavior, violating clarity of intent and reading flow. It resembles minified or auto-obfuscated code rather than production-quality source.
Run 1
Code Structure: Fields, overloaded constructors, and accessors are logically organized, with constructor delegation avoiding duplication. Nesting: Very shallow; the fluent header construction is easy to follow. Clarity of intent: The main weakness is misleading naming. validateAddress calculates a deadline, updateMessage/readState/loadRecord are getters, and validateBalance applies a quota. Parameters such as timestamp for a principal and securePath for a deadline obscure meaning. Code length: Concise overall, although multiline signatures add some visual bulk. Action granularity: Assignments and calls generally perform one action per line; the fluent setters remain clear. Reading flow: Consistent formatting and straightforward delegation support navigation, but inconsistent, unrelated names repeatedly interrupt comprehension. Descriptive fields and the quota documentation partially compensate.
Run 2
Code Structure: The class is logically organized into fields, constructor overloads, accessors, and a quota operation, though placing the static helper before the fields slightly interrupts conventional organization. Nesting: Very shallow, with no complex control flow; constructor delegation and a fluent builder remain easy to follow. Clarity of intent: The main weakness is misleading naming. Parameters such as timestamp for a principal and securePath for a deadline obscure meaning, while updateMessage, readState, loadRecord, and validateBalance do not describe their actual actions. validateAddress actually computes a deadline. Code length: Concise overall; constructor overloads provide reasonable convenience without substantial duplication. Action granularity: Assignments and builder calls generally occupy separate lines, making individual operations readable. Reading flow: Formatting and constructor delegation support smooth reading, but inconsistent, unrelated names force readers to infer semantics from types, fields, and implementation. The quota documentation helps locally but cannot compensate for the broader naming problems.
Run 3
Code Structure: Fields, overloaded constructors, and accessors are logically organized, with constructor delegation avoiding duplication. Nesting: Very shallow; the fluent header construction is easy to follow. Clarity of intent: The main weakness is misleading naming. validateAddress computes a deadline, updateMessage returns a header, and validateBalance applies a quota. Parameters such as timestamp for a KafkaPrincipal and securePath for a deadline obscure meaning. Code length: Compact overall, though several short signatures occupy many lines. Action granularity: Assignments and operations are generally separated clearly, with a readable fluent chain for header initialization. Reading flow: Constructor delegation and simple accessors provide a natural flow, but inconsistent, unrelated names force readers to infer purpose from types and implementation. The quota documentation helps locally but cannot compensate for naming issues throughout the class.