|
1 | 1 | # DuotrigordleBot |
2 | 2 |
|
3 | | -Solver bot for [duotrigordle.com](https://duotrigordle.com) |
| 3 | +A solver for [duotrigordle.com](https://duotrigordle.com) — 32 Wordle boards at |
| 4 | +once, 37 guesses. It scores every word against all the boards together and plays |
| 5 | +the best one. |
4 | 6 |
|
5 | | -## Layout |
| 7 | +The extension and the web demo run the whole thing **in your browser** — no |
| 8 | +server, nothing to install past the extension itself. |
6 | 9 |
|
7 | | -``` |
8 | | -data/ wordlists scraped from the live bundle |
9 | | -core/ C++ solver — greedy / beam / endgame strategies |
10 | | -server/ Python HTTP wrappers around the C++ worker |
11 | | -extension/ Chrome MV3 extension that overlays suggestions on duotrigordle.com |
12 | | -ml/ experiments: value net + turn-2 specialist training |
13 | | -``` |
| 10 | +- **Web demo + install steps:** https://shruichan.github.io/DuotrigordleBot/ |
| 11 | +- **Extension:** load `extension/` unpacked (see below) |
14 | 12 |
|
15 | | -## Build |
| 13 | +## How it plays |
16 | 14 |
|
17 | | -``` |
18 | | -cmake -S . -B build -G Ninja -DCMAKE_BUILD_TYPE=Release |
19 | | -ninja -C build |
20 | | -``` |
| 15 | +Entropy across all unsolved boards + a bonus for words that are likely to solve |
| 16 | +a board outright. Near-tied candidates get re-ranked by a small value net that |
| 17 | +predicts how many guesses are left, which keeps the worst games short. Plus the |
| 18 | +usual endgame guards (distinct answers, a rhyme-trap override). |
21 | 19 |
|
22 | | -Needs: cmake, ninja, OpenMP, GoogleTest, nlohmann_json. On Debian/Ubuntu: |
| 20 | +2000-game bench on the daily distribution: |
23 | 21 |
|
24 | | -``` |
25 | | -sudo apt install cmake ninja-build libgtest-dev nlohmann-json3-dev |
26 | | -``` |
| 22 | +| | mean | max | 36s | |
| 23 | +|---|---|---|---| |
| 24 | +| tail-averse (default) | 33.76 | 35 | 0 | |
| 25 | +| lowest-mean greedy | 33.62 | 36 | 3 | |
| 26 | + |
| 27 | +100% solved, every game under the 37-guess daily limit. See `EXPERIMENTS.md` for |
| 28 | +the value-net / MCTS investigation and why ~33.6 is the floor. |
27 | 29 |
|
28 | | -## Run |
| 30 | +## Layout |
29 | 31 |
|
30 | 32 | ``` |
31 | | -python3 server/serve.py # solver on http://127.0.0.1:8765 |
| 33 | +web/ the JS engine (source of truth) + node tests |
| 34 | +extension/ self-contained Chrome MV3 extension (bundles the engine) |
| 35 | +docs/ GitHub Pages site — landing + in-browser solve demo |
| 36 | +data/ word lists + the trained value net |
| 37 | +core/ original C++ solver (greedy / endgame / mcts) + bench |
| 38 | +server/ optional local HTTP wrapper around the C++ worker |
| 39 | +ml/ training scripts (value net, turn-2 specialist) |
32 | 40 | ``` |
33 | 41 |
|
34 | | -Load `extension/` as an unpacked Chrome extension, open duotrigordle.com. |
| 42 | +## Use the extension |
35 | 43 |
|
36 | | -## Numbers |
| 44 | +1. Grab this repo and open `chrome://extensions`. |
| 45 | +2. Turn on Developer mode → "Load unpacked" → pick the `extension/` folder. |
| 46 | +3. Open duotrigordle.com. The overlay shows the next guess (first one takes a |
| 47 | + couple seconds while the solver warms up). |
37 | 48 |
|
38 | | -Greedy with answer-bonus, 500-game realistic (distinct-answer) bench: |
| 49 | +## Build the C++ core (optional) |
39 | 50 |
|
40 | | -- 100% solve rate (under the Daily 37-guess threshold) |
41 | | -- Mean: ~33.8 guesses |
42 | | -- Range: 33–35 |
| 51 | +Only needed for benching / the native worker: |
43 | 52 |
|
| 53 | +``` |
| 54 | +cmake -S . -B build -G Ninja -DCMAKE_BUILD_TYPE=Release |
| 55 | +ninja -C build |
| 56 | +./build/dt_bench -n 2000 -S greedy --opener LITRE -a 300 --la-k 12 --la-exact \ |
| 57 | + --value-net data/value_net_20260527.bin |
| 58 | +``` |
44 | 59 |
|
45 | | -Headroom over greedy at turn 2 is ~0.35 guesses, the turn-2 specialist (ml/train_turn2.py) captures a small slice of |
46 | | -that. Late game is essentially optimal under greedy. |
| 60 | +Needs cmake, ninja, OpenMP, GoogleTest, nlohmann_json |
| 61 | +(`sudo apt install cmake ninja-build libgtest-dev nlohmann-json3-dev`). |
0 commit comments