Factor out common functions in notebooks + Perf Improvements + max-splits heuristic #6
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
performance.ipynb
andwordle_solver.ipynb
into a single utils file. This will make code reviews in the future simpler, since diffs of.jl
files display better than those for.ipynb
files.performance.ipynb
by using a 2d-array to store the precomputed scores rather than a dictionary, and by making the score aUInt8
, which takes up less space.get_group_sizes
,find_move
,trim_pool
,apply_strategy
andget_num_turns
make use of type polymorphism to handle either anInt
(corresponding to the index of the word in the list of all words) or aString
(the word itself).UInt8
, we treat the scores as ternary (e.g. 22222 in base 3 is 242 in base 10).NOTE: You'll see that there's some differences in our histograms. I haven't been able to dig in to exactly what the issues are, but I suspect it has to do with the change to tiebreaks (from lexical order on strings to the position of the words in the guessing list).