Sample
int-e90eb2d0372f-SRC
Unmodified source class
Scores
| Method | Score | Scale |
|---|---|---|
| Posnett | 0 | 0–1; higher is more readable |
| Scalabrino | 0.543 | 0–1; higher is more readable |
| Dorn | 0.35 | 0–1; higher is more readable |
| Mi | 0.381 | 0–1; higher is more readable |
| LLOC | 32 | Logical lines; fewer is more readable |
| DeepSeek V4 Pro | 17.67 | 0–20; mean of three runs |
| GPT-6.1 Sol | 18 | 0–20; mean of three runs |
| BTTF | 0.423 | 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. | 3200.27 | −105.609 |
| Source linesThe number of non-empty source lines. | 104 | +41.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.877 | −7.316 |
Intercept 8.87 + feature contributions = -62.454 (log-odds).
Score = sigmoid(-62.454) = 0.
| Score | 0.543 |
|---|
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. | 105 | −2.681 |
| Indentation frequencyHow rapidly indentation changes from line to line. | 94 | +2.514 |
| Number layout frequencyHow rapidly the number of numeric values per line changes through the code. | 94 | −1.736 |
| Identifier layout (vertical)How rapidly the visual pattern of identifier characters changes from top to bottom. | 103.84 | +1.042 |
| Comment layout (horizontal)How rapidly the visual pattern of comment characters changes from left to right. | 85 | +0.567 |
| 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. | 98.933 | −0.525 |
| Operator visual areaThe share of the code’s visual area occupied by operators such as +, =, and *. | 0.084 | +0.13 |
Intercept 0.07 + feature contributions = -0.62 (log-odds).
Score = sigmoid(-0.62) = 0.35.
| Score | 0.381 |
|---|
| Score | 32 |
|---|
Run 1
The code is well-structured and follows clean patterns. It uses inheritance and delegation effectively, with clear method names reflecting intent. Nesting is minimal, with only one simple conditional in descendingMultiset(). Action granularity is excellent—each line performs a single clear action. Reading flow is natural, organizing methods logically: construction, overridden infrastructure, view methods, then mutators that throw. The class-level Javadoc explains the split rationale. Minor readability challenges come from the heavy use of generic type parameters and annotations, which add visual noise. The lazy-initialization block in descendingMultiset(), while logically compact, packs several actions into a conditional branch, slightly reducing immediate clarity. Overall, this is maintainable, idiomatic Guava-style code that would be readable to developers familiar with Java collection frameworks.
Run 2
The code is highly readable. It has a clear, logical structure with a single class extending a base class and implementing a sorted multiset. Nesting is minimal, with only one conditional block in the descendingMultiset() method. Intent is clear: the class provides an unmodifiable wrapper for sorted multisets, with methods delegating to the underlying implementation and mutating methods throwing UnsupportedOperationException. Code length is concise, with methods being short and focused. Action granularity is appropriate, typically one action per line. Reading flow is natural, with methods organized logically: constructor, overridden accessors, element set methods, descending multiset handling, entry operations, and range-view methods. The only minor drawbacks are the slightly complex descendingMultiset() lazy initialization logic and the verbose TODO comment, but these are well-documented and justified.
Run 3
The code is highly readable with a clear logical structure: class declaration, constructor, delegate accessor, element set creation, view methods, and mutation-unsupported operations are grouped logically. Nesting is minimal—only a single if-block for lazy initialization. Intent is explicit through method names, Javadoc, and consistent delegation to the wrapped SortedMultiset. Code length is appropriate for an unmodifiable wrapper; each method is concise and delegates to a single action. Action granularity is strong, with one primary operation per line (e.g., delegate().firstEntry()). Reading flow is natural, following the SortedMultiset interface contract from comparator through views to serialization. The only slight readability deduction comes from the TODO comment and the transient field ordering, but these are minor and well-documented.
Run 1
Code Structure: Well-organized wrapper class with small, focused methods and clear delegation; placing the cached field among methods slightly weakens organization. Nesting: Almost entirely flat, with only one simple conditional in lazy initialization. Clarity of intent: Descriptive names, class documentation, and explicit exceptions clearly communicate an unmodifiable sorted multiset; annotations and casts add minor complexity. Code length: Concise implementation with necessary interface overrides and little unnecessary code. Action granularity: Most lines perform one action, though returning an assignment in descendingMultiset combines caching and returning. Reading flow: Consistent formatting and predictable method patterns make scanning easy; the detailed platform-specific TODO briefly interrupts the otherwise straightforward flow.
Run 2
Code Structure: A logically organized wrapper class with focused delegation methods and explicit rejection of mutating operations. Nesting: Nearly flat, with only one simple conditional in the lazy initialization method. Clarity of intent: Descriptive names, class documentation, and consistent unmodifiable wrapping make the purpose clear; casts and platform-specific annotations add minor complexity. Code length: Concise for the interface implemented, with little unnecessary logic; the lengthy TODO slightly interrupts the otherwise compact presentation. Action granularity: Most statements perform one action, although 'return descendingMultiset = result' combines assignment and return. Reading flow: Consistent formatting and predictable method patterns make scanning easy, but the cache field placed between methods and densely grouped annotations slightly disrupt the flow.
Run 3
Code Structure: A well-organized wrapper class with focused methods and consistent delegation; the cached field appearing between methods slightly interrupts organization. Nesting: Almost entirely flat, with only one simple conditional in descendingMultiset(). Clarity of intent: Descriptive names, class documentation, unmodifiable wrappers, and explicit exceptions clearly convey the purpose. Generic casts and platform-specific annotations require some background knowledge. Code length: Concise implementations with little unnecessary code; repetitive overrides are appropriate for the interface. Action granularity: Most lines perform one action, although return descendingMultiset = result combines assignment and return. Reading flow: Consistent formatting and predictable method patterns make scanning easy; the lengthy platform-specific TODO and densely annotated declarations introduce minor distractions.