The Demon knows every word your opponent doesn't.
A pragmatic tool that searches 477k+ words in milliseconds, finds the hardest follow-up, and types it like a human.
The game's suffix-matching system rewards dead-end patterns more than vocabulary. Letter Demon exploits that weakness.
Pick a main strategy, then a backup for when things go sideways.
- Trap → Lead your opponent into a dead end.
- Long → To boost your ego by pretending you know obscure, ridiculously long words.
- Short → Minimal effort, maximum efficiency.
- Random → Let fate take the wheel.
Typing speed ranges from 10-250 ms per keystroke.
Turn up the humanizer and the typing stops feeling like a machine gun and starts feeling like an actual person. A little hesitation here, a weird pause there, enough imperfection to look natural.
At around 170 ms with 75%+ humanization in Trap mode, it starts looking suspiciously like a real player who somehow knows every obscure word in the dictionary.
The app suggests. You decide.
- Block words you never want to use.
- Create custom trap endings.
- Edit everything in an inline editor with search and undo.
- Keep a log of every word played.
You type "ca" at the start of a game. The engine:
- Searches all words starting with "ca" (cabinet, camera, capital, etc.)
- Scores each by matching trap endings (suffix priority list)
- Picks the highest-scoring word that's not in exceptions
- Types it like a human with realistic keystroke delays
Result: "cabinet" gets typed with delays that look natural.
Note
No dictionary is included. Bring your own word list and
trap_endings.txt, ideally from the game's 474k-477k-word dictionary.
Windows • Python 3.10+. Run:
git clone https://github.com/n6ufal/Letter-Demon.git
cd letter-demon
pip install -r requirements.txt
python main.pyw- Load a Dictionary - Advanced > Load Dictionary, pick a .json or .txt file. Indexing takes 5-30s depending on your system specs.
- Configure Typing - Set speed (default 170ms), jitter/humanizer intensity (default 75%), pre/post delays (default 500ms each).
- Pick Strategy - Trap Words (hardest), Long Words, Short Words, or Random. Choose a fallback.
- Play - Type starting letters, press Play or Ctrl+Enter.
Dictionary Format
JSON:
{
"words": ["apple", "banana", "cherry"]
}Text (one word per line):
apple
banana
cherry
Advanced Configuration
Trap endings are suffixes that are statistically hard to continue from. The engine scores each word by its longest matching suffix, prioritizing earlier entries in trap_endings.txt.
To load trap endings:
- Click Advanced > Load (Trap Endings section)
- Select
data/trap_endings.txt - Changes take effect immediately
Format: one suffix per line, ordered by difficulty. Lines starting with # are ignored.
Note: The
data/trap_endings.txtin this repository is a minimal dummy for testing. Provide your own full trap endings file for real use.
# comment lines are ignored
ocy
loh
sz
osa
Stop the engine from suggesting certain words:
- Click Advanced > Edit (Exceptions section)
- Add one word per line
- Useful for slurs, proper nouns, or anything you want blocked
Run all 104 tests:
python -m unittest discover -vSee TESTING.md for full details.
- "Game: off" indicator - Open the game window before hitting Play
- Dictionary won't load - Check the file exists and is valid JSON or TXT
- Typing fails - Run
python main.pyto see errors, or checklogs/letter_demon.log
- Full architecture and algorithms: ARCHITECTURE.md
- Test suite guide: TESTING.md
- Blog post: What Happens When You Take a Word Game Too Seriously
I built this as my personal Python learning project, for personal use only.
