danmaps / spooner

programmatic spoonerisms
MIT License
5 stars 2 forks source link

sort results by popularity of words #2

Open danmaps opened 4 years ago

danmaps commented 4 years ago

https://github.com/first20hours/google-10000-english

danmaps commented 4 years ago

actually try this https://norvig.com/ngrams/count_1w.txt

danmaps commented 4 years ago

instead of:

>>> sp.sentence("let's eat trail snacks")
["let's treat ail snacks", "let's treat ale snacks", "let's eat snail tracks", "let's eat snail trax"]

return:

["let's eat snail tracks", "let's treat ail snacks", "let's treat ale snacks", "let's eat snail trax"]
danmaps commented 4 years ago

Idea: Instead of word popularity, try sorting by putting the "more perfect" (that work both on spelling and pronounciation) matches first.

danmaps commented 2 years ago

potential resource: https://github.com/3b1b/videos/tree/master/_2022/wordle_data

... https://youtu.be/v68zYyaEmEA?t=1101...

danmaps commented 1 year ago

another inspiring youtube video. Josh Wardle used the google ngram thing to rank words by popularity.

https://www.youtube.com/watch?v=0sZv3EPgt9Y