Sample
Buse/95
Human rating uses the original dataset scale.
Scores
| Method | Score | Scale | Dataset rank (0–100) |
|---|---|---|---|
| Posnett | 0.649 | 0–1; higher is more readable | 69.7Δ 28.3 |
| Dorn | 0.41 | 0–1; higher is more readable | 27.3Δ 14.1 |
| Mi | 0.69 | 0–1; higher is more readable | 79.8Δ 38.4 |
| LLOC | 3 | Logical lines; fewer is more readable | 88.9Δ 47.5 |
| DeepSeek V4 Pro | 12 | 0–20; mean of three runs | 27.8Δ 13.6 |
| GPT-6.1 Sol | 19.33 | 0–20; mean of three runs | 99.0Δ 57.6 |
| BTTF | 0.296 | 0–1; higher is more readable | 8.1Δ 33.3 |
| Human | 3.19 | 1–5; original rating | 41.4 |
Views
Select the downloaded ZIP or its extracted folder. Files stay in your browser.
Loading feature diagnosis…
Source regions
Feature contributions
Feature contributions
| Feature | Value | Contribution (log-odds) |
|---|---|---|
| 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.308 | −6.463 |
| Halstead volumeHow much symbolic information the code contains. It combines the total number of operators and values with the number of distinct ones. | 102.799 | −3.392 |
| Source linesThe number of non-empty source lines. | 4 | +1.6 |
Intercept 8.87 + feature contributions = 0.615 (log-odds).
Score = sigmoid(0.615) = 0.649.
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. | 4 | +0.895 |
| Comment layout (horizontal)How rapidly the visual pattern of comment characters changes from left to right. | 0 | −0.804 |
| Indentation frequencyHow rapidly indentation changes from line to line. | 1 | −0.703 |
| Number layout frequencyHow rapidly the number of numeric values per line changes through the code. | 1 | +0.398 |
| Identifier layout (vertical)How rapidly the visual pattern of identifier characters changes from top to bottom. | 3.747 | −0.357 |
| Operator visual areaThe share of the code’s visual area occupied by operators such as +, =, and *. | 0.086 | +0.106 |
| 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. | 85.8 | +0.031 |
Intercept 0.07 + feature contributions = -0.365 (log-odds).
Score = sigmoid(-0.365) = 0.41.
| Score | 0.69 |
|---|
| Score | 3 |
|---|
Run 1
The code shows minimal structure but is tangled and unclear. It retrieves an input handler, sets it as the message handler, and updates a GUI flag. The intent is ambiguous without surrounding context—why is the input handler being set as the message handler? The variable name is long but does not clarify the flow. Nesting is flat, which is good, but action granularity is mixed: one line does one action, yet the logic spans three lines with no comments or grouping. The reading flow is disjointed because the reader must infer the relationship between the GUI state and the message handler. Overall, the code is short but lacks clarity and cohesive purpose, making it hard to understand at a glance.
Run 2
The code is highly readable. It uses a clear, logical structure with flat nesting and one action per line. The intent is straightforward: retrieve the input handler, set it as the message handler, and update the GUI state. Variable names are descriptive, and the sequence follows a natural flow. Minor improvement could involve adding a comment or context, but overall it is concise and unambiguous.
Run 3
The code is relatively straightforward, with each line representing a single, distinct action, which contributes to clear action granularity. However, the overall readability is limited by a lack of surrounding context. The snippet does not reveal the purpose of the sequence or the relationship between `InGameInputHandler`, `freeColClient`, and `gui`, making the intent ambiguous. The variable name `inGameInputHandler` is descriptive, but the code reads as a low-level setup routine rather than a cohesive, self-documenting block. Structurally, the snippet is linear and flat (no nesting), and its length is concise. The reading flow is natural but interrupted by the deeply-qualified access chain (`freeColClient.getClient().setMessageHandler(...)`). Without comments or a meaningful method name, the reader must infer the high-level goal, which reduces clarity of intent.
Run 1
Code Structure: Logically organized into retrieving the handler, registering it, and updating the GUI state. Nesting: Completely flat, with no nested control flow. Clarity of intent: Descriptive names make the purpose of each statement clear. Code length: Concise, with no unnecessary code. Action granularity: Each statement performs one primary action. Reading flow: The sequence is natural, and the blank line separates handler retrieval from state changes.
Run 2
Code Structure: logically ordered setup steps with appropriate spacing. Nesting: entirely flat. Clarity of intent: descriptive names make retrieving and registering the in-game input handler and updating GUI state clear, though setInGame(true) uses a boolean flag. Code length: concise with no unnecessary operations. Action granularity: each statement performs one main action. Reading flow: naturally progresses from obtaining the handler to registering it and marking the GUI as in-game.
Run 3
Code Structure: logically organized setup steps with clear separation between obtaining the handler and configuring game state. Nesting: entirely flat, with no nested control flow. Clarity of intent: descriptive names make handler registration and entering in-game mode clear, though their relationship depends slightly on surrounding context. Code length: concise, with no unnecessary statements. Action granularity: each statement performs one primary action. Reading flow: natural progression from retrieving the handler to registering it and enabling in-game mode.