mirror of
https://github.com/Twigpine/icaptcha.git
synced 2026-11-10 05:01:46 -10:00
The grader accepts one answer, so a pool word that shares its letters with another real word fails a solver who thought of the other one. Against the live service, the letters of 'star' answered as 'rats' come back failed. 31 of the 70 words were affected, checked against hunspell en_US with affix rules expanded so inflections count. Short words collide most, so the easiest levels were the least reliable: cloud/could, garden/danger, bread/beard, door/odor, kitchen/thicken. Fixed in the pool rather than the grader. Teaching grade() to accept alternates widens what the gate says yes to, and since a scramble can equal an alternate, echoing the prompt letters back would pass 5.9% of level-1 challenges against 0% today (measured over 50k generated challenges). A gate should not get more permissive to fix a correctness bug. Replacements are verified by the same dictionary check, which ships as scripts/audit-anagram-pool.mjs to re-run when words are added. It reads a hunspell dictionary already on the machine and skips when there is none, so the runtime keeps its zero production dependencies.