Sample

Dorn/python/60

Human rating uses the original dataset scale.

DatasetDorn
Human3.87
Lines30

Scores

MethodScoreScaleDataset rank
(0–100)
Posnett0.9780–1; higher is more readable
92.8Δ 6.4
Dorn0.860–1; higher is more readable
88.0Δ 1.7
Mi0.7210–1; higher is more readable
87.7Δ 1.4
LLOC11Logical lines; fewer is more readable
57.0Δ 29.4
DeepSeek V4 Pro16.670–20; mean of three runs
91.4Δ 5.0
GPT-6.1 Sol180–20; mean of three runs
93.5Δ 7.1
BTTF0.6430–1; higher is more readable
84.1Δ 2.2
Human3.871–5; original rating
86.4

Views

Download official ZIP ↗

Select the downloaded ZIP or its extracted folder. Files stay in your browser.

Loading feature diagnosis…

Source regions

Feature contributions

Feature contributions

FeatureValueContribution
(log-odds)
Source linesThe number of non-empty source lines.30+12
Halstead volumeHow much symbolic information the code contains. It combines the total number of operators and values with the number of distinct ones.312.886−10.325
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.502−6.752

Intercept 8.87 + feature contributions = 3.792 (log-odds).
Score = sigmoid(3.792) = 0.978.

Feature contributions

FeatureValueContribution
(log-odds)
Operator visual areaThe share of the code’s visual area occupied by operators such as +, =, and *.0.027+0.676
Number layout frequencyHow rapidly the number of numeric values per line changes through the code.1+0.398
Comment layout (horizontal)How rapidly the visual pattern of comment characters changes from left to right.73.129+0.375
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.77.968+0.363
Comment layout frequencyHow frequently the layout switches between lines containing only comments or whitespace and lines containing code.31−0.061
Indentation frequencyHow rapidly indentation changes from line to line.21−0.011
Identifier layout (vertical)How rapidly the visual pattern of identifier characters changes from top to bottom.29.797+0.007

Intercept 0.07 + feature contributions = 1.817 (log-odds).
Score = sigmoid(1.817) = 0.86.

Score0.721
Score11
Run 1

The code is well-structured and highly readable. It defines a clear abstract base class with concise documentation and logical organization. The nesting is minimal, with only one method body containing a flat list extension. Intent is clear through docstrings and attribute comments. The code is concise without being overly terse. Action granularity is appropriate, with one meaningful operation per line in the method. Reading flow is natural, moving from imports to class definition, docstring, configuration attributes, method, and instance attributes with explanatory comments. Minor stylistic improvements could include breaking the return list into multiple lines for slightly better readability and consistency, but the overall clarity remains excellent.

Run 2

The code is mostly readable with clear intent and logical structure. It defines a Writer component with descriptive docstrings and straightforward methods. However, there are minor issues: the closing bracket style is inconsistent, and the class attributes are placed after methods rather than at the top, which slightly disrupts the natural reading flow. Nesting is flat, and action granularity is acceptable.

Run 3

The code is highly readable due to its clear structure and purpose. It defines an abstract Writer class with a clean class-level organization: metadata, a simple overridden method, and documented attributes. Nesting is minimal. Intent is explicit through descriptive names and docstrings. Code length is concise. The get_transforms method is flat and logical, with one action per line. The only minor issue is the trailing comma in a list that includes a slightly awkward formatting break, but this doesn't significantly impact readability. Overall, it follows a natural reading flow and is easy for a developer to understand at a glance.

Run 1

Code Structure: The class is logically organized, with documentation, configuration attributes, a method, and documented state attributes, though grouping all attributes before methods would improve consistency. Nesting: Minimal nesting makes the code easy to scan. Clarity of intent: The class docstring and attribute descriptions clearly explain the writer's role; Component is not imported in the shown snippet, leaving some context implicit. Code length: Concise, with useful documentation rather than unnecessary implementation. Action granularity: Each assignment performs one action, and the transform list places each item on its own line. Reading flow: Mostly natural, but placing the list's closing bracket on the final item line and interleaving methods with attributes slightly disrupts readability.

Run 2

Code Structure: The class is logically organized, with configuration, a transform method, and documented state attributes, though grouping attributes before methods would improve consistency. Nesting: Minimal nesting makes the code easy to scan. Clarity of intent: Descriptive names and clear docstrings explain the writer's role and attributes; Component is not imported in the snippet, and write() and translate() are referenced but not shown. Code length: Concise, with useful documentation rather than unnecessary implementation. Action granularity: Each assignment or list item represents a distinct action or value. Reading flow: Generally natural and readable, with minor formatting distractions from the blank line before the class docstring and the closing bracket placed beside the final transform.

Run 3

Code Structure: The class is logically organized with a descriptive docstring, configuration attributes, and a small method, though grouping all attributes before methods would improve consistency. Nesting: Minimal nesting makes the code easy to scan. Clarity of intent: Names and documentation clearly explain the writer's role, transforms, and state; the undefined Component reference requires external context. Code length: Concise, with documentation that adds useful context rather than unnecessary verbosity. Action granularity: Statements have focused purposes, and transform entries are separated by line. Reading flow: Generally natural, but the attributes following the method and the closing bracket attached to the last list entry slightly interrupt the flow.