Sample
int-ed93027bb5bd-I03
Replace method, parameter, and local names with length-matched, meaningful but unrelated names
Scores
| Method | Score | Scale |
|---|---|---|
| Posnett | 0.99 | 0–1; higher is more readable |
| Scalabrino | 0.943 | 0–1; higher is more readable |
| Dorn | 0.819 | 0–1; higher is more readable |
| Mi | 0.686 | 0–1; higher is more readable |
| LLOC | 27 | Logical lines; fewer is more readable |
| DeepSeek V4 Pro | 10 | 0–20; mean of three runs |
| GPT-6.1 Sol | 12.67 | 0–20; mean of three runs |
| BTTF | 0.629 | 0–1; higher is more readable |
Views
Loading feature diagnosis…
Source regions
Feature contributions
Feature contributions
| Feature | Value | Contribution (log-odds) |
|---|---|---|
| Source linesThe number of non-empty source lines. | 128 | +51.2 |
| Halstead volumeHow much symbolic information the code contains. It combines the total number of operators and values with the number of distinct ones. | 1459.002 | −48.147 |
| 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.886 | −7.329 |
Intercept 8.87 + feature contributions = 4.594 (log-odds).
Score = sigmoid(4.594) = 0.99.
| Score | 0.943 |
|---|
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. | 123 | −3.319 |
| Indentation frequencyHow rapidly indentation changes from line to line. | 74 | +1.822 |
| Identifier layout (vertical)How rapidly the visual pattern of identifier characters changes from top to bottom. | 127.911 | +1.378 |
| Operator visual areaThe share of the code’s visual area occupied by operators such as +, =, and *. | 0.032 | +0.633 |
| Comment layout (horizontal)How rapidly the visual pattern of comment characters changes from left to right. | 88.953 | +0.631 |
| Number layout frequencyHow rapidly the number of numeric values per line changes through the code. | 1 | +0.398 |
| 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. | 88.969 | −0.103 |
Intercept 0.07 + feature contributions = 1.51 (log-odds).
Score = sigmoid(1.51) = 0.819.
| Score | 0.686 |
|---|
| Score | 27 |
|---|
Run 1
The code structure is superficially organized but marred by severe naming mismatches. Class documentation and field names reference BeanDefinition defaults, but method names (buildRecord, validateMessage, refreshAccount) are unrelated, making intent ambiguous. Nesting and action granularity are acceptable; each method is short and flat. However, reading flow is disorganized due to irrelevant comments that don't match the methods they describe, causing confusion. Code length is moderate but contains misleading comments that should be removed or corrected. Overall readability is low because the disconnect between documented purpose and actual method names obscures logic.
Run 2
The code is structurally disjointed. While the class has a clear purpose as a defaults holder, method names like buildRecord, checkBatch, validateMessage, and validateAccount are semantically unrelated to their documented functions (lazy init, autowire mode, dependency check), making intent confusing and misleading. The reading flow is disrupted because getters and setters are not paired logically and their names provide no indication of the property they access. Nesting is low and structure is flat, which is good, but clarity of intent is severely undermined. Code length is moderate but comment-to-code mismatch adds noise. Action granularity is fine, with one operation per method. Overall, the code is syntactically simple but semantically opaque, requiring significant cognitive effort to map method names to documented behavior, reducing readability despite good formatting and low nesting.
Run 3
The code has a clear class structure with logical field organization and good documentation, but suffers from a critical readability problem: method names do not match their functionality. Methods like 'buildRecord', 'checkBatch', 'validateMessage', and 'refreshAccount' suggest validation or data processing operations, yet they simply get/set bean definition properties (lazyInit, autowireMode, dependencyCheck, initMethodName, destroyMethodName). This creates significant confusion about intent. The code is flat with no deep nesting, maintains one action per line, and has reasonable length. However, the disconnect between method names and actual behavior severely impacts readability and maintainability, making the code misleading despite its otherwise clean structure and good documentation comments.
Run 1
Code Structure: Fields and related accessor pairs are logically organized in a simple holder class. Nesting: Methods are flat, with only straightforward boolean and ternary expressions. Clarity of intent: Descriptive fields and documentation explain the purpose, but unrelated method and parameter names such as validateAccount and pendingBalance obscure actual behavior. Some @param tags reference nonexistent parameter names, further undermining clarity. Code length: Implementations are concise; extensive documentation adds length but mostly provides useful context. Action granularity: Each statement performs one clear assignment or return. Reading flow: Consistent formatting and accessor grouping support easy scanning, but misleading names force readers to consult method bodies and comments repeatedly.
Run 2
Code Structure: Well-organized holder class with fields followed by paired setters and getters. Nesting: Flat methods with no nested control flow; simple conditional expressions are easy to follow. Clarity of intent: Descriptive fields and helpful documentation explain behavior, but misleading method names such as validateAccount and refreshAccount obscure basic accessor operations. Unrelated parameter names further confuse intent, and some @param tags do not match actual parameters. Code length: Implementations are concise, though extensive documentation makes a simple holder relatively lengthy. Action granularity: Each implementation line performs one clear assignment or return. Reading flow: Consistent formatting and accessor grouping support sequential reading, but readers must repeatedly consult comments and fields to understand inaccurately named methods.
Run 3
Code Structure: Fields and related setter/getter pairs are logically organized in a simple holder class. Nesting: Methods are flat, with only straightforward boolean and ternary expressions. Clarity of intent: Descriptive fields and Javadoc explain the behavior, but misleading method names such as validateAccount and buildRecord obscure basic accessor operations. Unrelated parameter names further confuse intent, and some Javadoc @param names do not match the signatures. Code length: Implementations are concise, although extensive documentation and whitespace make a simple class longer to scan. Action granularity: Each statement performs a single clear assignment or return. Reading flow: Consistent formatting and grouping support natural reading, but the mismatch between documentation, names, and behavior repeatedly forces readers to inspect implementations.