-
-
Why Wrong: see what students’ wrong answers may reveal.
-
Sort into groups: students with the same answer pattern line up, so the reteach groups are visible at a glance.
-
Click a student: each estimate with the answers that supported it, and one more question worth asking.
-
Reteach groups built from shared answer patterns, not scores, each with a plan and check questions.
-
Your questions: which ones told you something, and which were too easy, ambiguous or worth reviewing.
-
After the reteach: the same paper again, compared student by student, with a plain note on what could be chance.
Inspiration
A red X tells a student which answer was wrong. It doesn't say why. Every math and science teacher knows the classic mistakes (adding the tops and the bottoms of two fractions, losing a minus sign when distributing, thinking a trait an animal acquired gets passed to its offspring), but finding out which students hold which one means reading every paper by hand. Most teachers don't have that time, so the whole class gets the same reteach, and the students who already understood sit through it again.
Diagnostic assessment that answers "why" exists, but it usually lives inside paid platforms or needs a specialist. I wanted any teacher with a browser and a stack of paper tests to get it for free.
What it does
Why Wrong takes a class's answers to a multiple-choice test and estimates the misunderstanding behind each wrong answer.
- Class map: every student against every question, colored by the misunderstanding each wrong answer points to, sorted into bands of students with similar patterns.
- Reteach groups: students grouped by shared answer patterns, not by score, each with a suggested plan and check questions. Students who sit between two groups are flagged, with one question that would settle it.
- Evidence trail: click a student to see each estimate and the answers behind it: which supported it, which argued against it, and the letter the student chose, as printed on the paper.
- Question audit: which questions told you something, which were too easy or ambiguous, and when to check the answer key.
- After the reteach: give the same paper again and it compares the two sittings with an exact McNemar test, and says plainly when a change could be chance.
- Student slips and follow-up questions: each student gets a slip in plain language ("you may be adding the tops and the bottoms") with no percentages or group numbers. The teacher gets one page of follow-up questions for every estimate that needs one more answer.
It ships with Algebra 1 (12 misconceptions, 36 questions) and Evolution & Inheritance (8 misconceptions, 24 questions). A teacher can bring an existing test as a file, or have an AI model draft a question set for another topic.
Before and after (sample class)
Before: the gradebook shows which questions Milo got wrong, and nothing about why.
After: Why Wrong says Milo's answers suggest a sign-distribution misunderstanding (87%), shows the answers behind that estimate, and puts him in a reteach group with the other students showing the same pattern, with check questions to confirm it before the lesson.
All examples use simulated students. No real student data is in the project.
Who it's for, and the barrier it removes
Middle and high school teachers, especially at schools that can't pay for an assessment platform.
- Free, no account, no server. Student names and answers never leave the browser tab. A class is saved to a file on the teacher's own computer, because school computers are shared.
- Works on paper. Print the questions and a blank answer sheet, give the test, then paste the answers back: letters, numbers or the answer text, including a Google Forms export as it comes. A class given only part of the test is read correctly.
- Accessible. The class map works from the keyboard like a spreadsheet, a letters mode marks every cell for anyone who can't tell the colors apart, and every statistic has a plain-language "?" written for teachers, which opens from the keyboard and is read out by screen readers.
How I built it
Plain JavaScript with no build step, hosted on GitHub Pages. Four stages, and the language model is not in the part that judges students.
- Distractor mapping. Each wrong option is linked to a misconception, or left unlinked. Hand-written for the built-in subjects. For a new topic, Claude drafts the question set, and code validates it and feeds structural failures back for repair.
- Per-student inference (
js/infer.js, no LLM). Naive Bayes over the student's answers, with explaining away for questions that probe several beliefs, each student's own accuracy, and each question's tempting wrong answers estimated from the class. - Class structure (
js/cluster.js, no LLM). Cosine k-means over each student's misconception estimates, with the number of groups picked by silhouette. - What the test doesn't label (
js/discover.js, no LLM). Finds unlabelled wrong answers that the same students keep picking together, checked against 100 reshuffled copies of the class. A teacher can name a pattern it finds, and the analysis then tracks it.
Item analysis (js/itemstats.js) grades the test itself: difficulty, discrimination, dead options, and a check that keeps it from calling a good diagnostic question "bad" just because it doesn't line up with total score.
Does it work?
Simulated classes have hidden ground truth, so the pipeline can be scored. Over 40 seeds:
| Algebra 1 | Evolution & Inheritance | |
|---|---|---|
| Diagnosis precision | 92.2% | 94.6% |
| Diagnosis recall | 83.4% | 87.7% |
| Group recovery (ARI) | 0.699 | 0.647 |
| Right number of groups | 37/40 | 36/40 |
A stress benchmark runs ten kinds of class that break the model's assumptions (options that tempt everyone, weaker classes, 15% blanks, classes of 14 and 90). On it, false labels for the weakest quarter of an Algebra class with tempting options fell from 1.55 to 0.50 per student after the November work.
In October I ran a first classroom pilot with a physics class and a CS class. It went well, but the paper answer sheets were lost afterward, so I can't report numbers from it.
Earlier work and what's new
Why Wrong's first version (the analysis pipeline, two subjects and the interface) was built in August 2026. The newer work, from November 2026, added: finding misunderstandings the test doesn't label and letting a teacher name them; flagging students between two groups; reading classes given only part of a test; reading answers retyped by Forms, Docs or Word; printing follow-up questions; and the stress benchmark plus the inference changes it drove. On Nov 12, a testing pass fixed help that opened under a panel, pastes of a class given part of a test, and screen-reader labels on the color key.
Challenges
- One answer can't diagnose anyone. A student who holds a misconception still gets questions right, and anyone can slip. An estimate is reported only when two answers point to it. On the benchmark, single-answer estimates were right 42% of the time, two-answer ones 79%.
- Tempting options looked like misconceptions. A wrong answer that pulls in the whole class says little about any one student, so each question's slips are now estimated from the class.
- Standard statistics punish diagnostic questions. Discrimination assumes the test measures one trait. A question built to catch one subgroup's misconception can look "bad" and still be the most useful one on the page, so the audit checks agreement with the rest of the test before flagging it.
What I learned
The hard part wasn't the math. It was deciding what the tool must not say. Every estimate needed a way to be checked, a statement of how sure it is, and wording a teacher can act on without reading a statistics paper.
Limitations
- The benchmark classes are simulated, so the recovery numbers describe consistency with the simulation, not accuracy on a real classroom.
- Two hand-written subjects. An AI-drafted question set is a first draft for a teacher to review.
- At 28 students, per-question statistics are noisy, and the page says so under 20.
- Results are estimates to check against student work, not confirmed explanations of what a student thinks.
Try it
- Live: https://adrian-erlikhman.github.io/why-wrong/ opens on a sample class with a 45-second tour. No account or key needed.
- Locally:
npx http-server . -p 4173 -c-1. Tests:npm test(274 checks) andnode test/benchmark.mjs.
Credits
Plain JavaScript, HTML and CSS, with Node for tests. Optional AI features call Anthropic's API (Claude) with the teacher's own key. Only the topic or group-level misconception details are sent, never student names or answers. I used Claude Code as a coding assistant throughout and reviewed its work. Earlier work is listed under "Earlier work and what's new". MIT licensed.
Built With
- anthropic
- claude
- css3
- github
- html5
- javascript
- node.js