Sample
int-c3083380a1f1-I02
Shorten method, parameter, and local names without collisions
Scores
| Method | Score | Scale |
|---|---|---|
| Posnett | 0 | 0–1; higher is more readable |
| Scalabrino | 0.943 | 0–1; higher is more readable |
| Dorn | 0.558 | 0–1; higher is more readable |
| Mi | 0.248 | 0–1; higher is more readable |
| LLOC | 2 | Logical lines; fewer is more readable |
| DeepSeek V4 Pro | 16.67 | 0–20; mean of three runs |
| GPT-6.1 Sol | 15.33 | 0–20; mean of three runs |
| BTTF | 0.652 | 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. | 975.657 | −32.197 |
| Source linesThe number of non-empty source lines. | 45 | +18 |
| 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.991 | −7.486 |
Intercept 8.87 + feature contributions = -12.813 (log-odds).
Score = sigmoid(-12.813) = 0.
| Score | 0.943 |
|---|
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. | 113 | −1.121 |
| Comment layout (horizontal)How rapidly the visual pattern of comment characters changes from left to right. | 112.913 | +1.017 |
| Operator visual areaThe share of the code’s visual area occupied by operators such as +, =, and *. | 0.032 | +0.631 |
| Comment layout frequencyHow frequently the layout switches between lines containing only comments or whitespace and lines containing code. | 46 | −0.592 |
| Indentation frequencyHow rapidly indentation changes from line to line. | 28 | +0.231 |
| Number layout frequencyHow rapidly the number of numeric values per line changes through the code. | 28 | −0.222 |
| Identifier layout (vertical)How rapidly the visual pattern of identifier characters changes from top to bottom. | 44.912 | +0.218 |
Intercept 0.07 + feature contributions = 0.232 (log-odds).
Score = sigmoid(0.232) = 0.558.
| Score | 0.248 |
|---|
| Score | 2 |
|---|
Run 1
The code is highly readable. It is well-structured as a concise interface with clear separation of constants and method declarations. Nesting is minimal, which aligns with interface design. Naming of constants and methods is explicit, making the intent unambiguous. The code is appropriately concise for its purpose, with one action or declaration per line. Javadocs provide clear context for the methods and parameters, enhancing the reading flow. The only slight drawbacks are shortened parameter names (e.g., 'sig', 'dec', 'eng', 'inp') and minor Javadoc inconsistency (parameter named 'engine' vs 'eng'), which slightly reduce formal clarity.
Run 2
The code is well-structured and clear, with good documentation. The interface has a logical organization of constants and methods, flat structure, and clear intent. However, the method signatures use abbreviated parameter names that reduce readability, the methods themselves have somewhat generic names like 'sig' and 'dec', and the constants section is quite long without grouping, which could benefit from better organization.
Run 3
The code is generally readable and well-structured as an interface definition. It logically groups related constants and documents methods with Javadoc. However, readability is hindered by abbreviated method and parameter names (`sig`, `dec`, `eng`, `inp`), which are ambiguous despite Javadoc explanations. The long list of constants is flat and repetitive, though unavoidable for such mappings. The constant declarations are concise and reference native constants, but the repetition adds length. The interface is flat with no nesting, and each method declaration is on one line, aiding quick scanning. The Javadoc provides clear intent and parameter descriptions, improving understanding. Some inconsistency exists between parameter names in Javadoc (`engine`, `input`) and signatures (`eng`, `inp`), creating minor confusion. Overall, the structure and clarity are good, but naming choices and repetition reduce readability.
Run 1
Code Structure: Logically organized into imports, algorithm constants, and two documented methods; grouping constants by algorithm would improve scanning. Nesting: Flat interface with no nested control flow. Clarity of intent: Constants and documentation explain the purpose, but abbreviated method names (sig, dec) and parameters (eng, inp, eng2, inp2) obscure meaning. Javadoc parameter names do not match the declarations, reducing clarity and documentation reliability. Code length: Concise for the interface's scope; repetitive constants are justified. Action granularity: Each constant and method declaration occupies its own line. Reading flow: Natural top-to-bottom progression, slightly weakened by dense constant declarations, minimal spacing around imports, and inconsistent parameter naming.
Run 2
Code Structure: The interface is logically organized into constants and two documented operations, though spacing and constant grouping could improve scanning. Nesting: Flat declarations with no nested control flow make it easy to follow. Clarity of intent: Descriptive constants and documentation explain the purpose, but abbreviated method and parameter names (sig, dec, eng, inp, eng2, inp2) obscure meaning. Javadoc parameter names do not match the actual signatures, creating confusion. Code length: Appropriately concise for an interface; the repeated constant mappings are straightforward rather than unnecessary. Action granularity: Each declaration occupies its own line, with no bundled actions. Reading flow: Constants followed by signing and decryption methods provide a natural progression, weakened by inconsistent naming and mismatched documentation.
Run 3
Code Structure: Logically organized into imports, algorithm constants, and two documented interface methods, though spacing and constant grouping could improve scanning. Nesting: Flat, with no nested control flow. Clarity of intent: Constants and documentation explain the purpose, but abbreviated method names (sig, dec) and parameters (eng, inp, eng2, inp2) reduce clarity. Javadoc parameter names do not match the declarations, creating confusion. Code length: Appropriately concise; the repetitive constants provide useful API definitions rather than unnecessary logic. Action granularity: Each constant and method declaration occupies its own line. Reading flow: Generally natural, moving from supported algorithms to operations, but inconsistent naming and inaccurate parameter documentation interrupt comprehension.