soegaard2
2022-1-31 10:16:31

What exactly is the difference between Wordle and Mastermind?

https://boardgamegeek.com/image/1316787/word-mastermind


soegaard2
2022-1-31 10:17:12

The white and black pins indicate correct letter / correct letter and placement.


laurent.orseau
2022-1-31 10:21:33

Hm…. wait, I think there are some licensing issues: The original game in JS has no license AFAICT, so I’m not sure we are allowed to use that particular list of words. We could provide our own list of words and merely say where to find the original list. There’s an open source clone with the list of words: https://github.com/hannahcode/wordle/tree/main/src/constants but probably they are the same words and so the same issues apply?


spdegabrielle
2022-1-31 10:22:57

No. We just accept entries as a GitHub link - we are not publishing


spdegabrielle
2022-1-31 10:24:11

We are not the first - many others have published solvers


laurent.orseau
2022-1-31 10:25:01

If we want participants, I believe we should ease the effort required to enter. > We are not the first - many others have published solvers That’s not a good reason to do things wrong :slightly_smiling_face:


spdegabrielle
2022-1-31 10:26:32

An app to play a game is distinct from an app to implement a game


laurent.orseau
2022-1-31 10:26:58

I don’t think that counts. As long as you reuse parts of a source code, that’s copying


laurent.orseau
2022-1-31 10:28:00

It’s pretty similar. There are more letters than colours, but there are more constraints on possible words than possible Mastermind codes


laurent.orseau
2022-1-31 10:28:25

Also in hard mode, it’s like you can only play consistent guesses


soegaard2
2022-1-31 10:33:17

Mastermind came in several versions. I am thinking of the letter version on the picture. (I think, you are describing the color version) But I think you are right that Mastermind didn’t require the hidden code to be a word.


spdegabrielle
2022-1-31 10:33:53

Ok. Only entries that work without the wordle dictionary?


laurent.orseau
2022-1-31 10:38:18

That doesn’t help, it makes the entrance bar a little too high. We should try to provide our own list or point to a free-to-use list


laurent.orseau
2022-1-31 10:38:34

Unless lists of words cannot be licensed? (that’d be surprising)


spdegabrielle
2022-1-31 10:40:11

OED would like to speak with you:rolling_on_the_floor_laughing:


spdegabrielle
2022-1-31 10:41:14

The nature of the problem is you can’t write a solver without a word list.


laurent.orseau
2022-1-31 10:43:05

sure, but does that entail that you can use the list of words freely? Problably not I’d guess


spdegabrielle
2022-1-31 10:44:05

I think the risk is low but I have more important things to worry about.


laurent.orseau
2022-1-31 10:52:33

I wonder what others think


laurent.orseau
2022-1-31 10:53:09

Ah, I didn’t know about this version!


soegaard2
2022-1-31 10:53:50

If Wordle never makes a physical game, you know why :wink:


laurent.orseau
2022-1-31 10:54:21

heh


laurent.orseau
2022-1-31 11:09:33

So, @spdegabrielle and I are thinking of proposing a Wordle Hackarty (hacking party), but I’m a little worried about licensing issue for the list of words. Stephen thinks it should be fine, or that we can ask participants to not use the original list (in which case I think it sets the bar too high to enter, as one would have to come up with their own list). Ideally we would provide a list ourselves maybe?


mark.piffer
2022-1-31 11:13:21

@mark.piffer has joined the channel


laurent.orseau
2022-1-31 11:14:18

I was thinking of using the list of 5-letter words from the Racket source code (after removing non-alpha characters), but it may be a little too hard: "bytes" "close" "error" "start" "quote" "table" "block" "bfodd" "blame" "given" "owner" "rxplt" "local" "shape" "scale" "listc" "sound" "event" "curve" "frame" "topic" "debug" "ufset" ...


laurent.orseau
2022-1-31 11:14:36

Although…. I mean it’s a solver, right, so it should be fine?


soegaard2
2022-1-31 11:15:05

@laurent.orseau Write Josh Wardle (Wardle!) and ask. I think there are good chances you can use the actual word list. https://www.powerlanguage.co.uk/


laurent.orseau
2022-1-31 11:15:14

(There’s only 500 words or so though)


laurent.orseau
2022-1-31 11:20:55

email sent. Thanks for pointing it out!


spdegabrielle
2022-1-31 11:21:25

Use bfodd in a sentence


spdegabrielle
2022-1-31 11:21:52

I just bfodd the cat


spdegabrielle
2022-1-31 11:22:23

laurent.orseau
2022-1-31 11:22:36

“Blue Fcreen of D-Death”?


laurent.orseau
2022-1-31 11:22:56

hm, looks like the cat bfodd you, rather


laurent.orseau
2022-1-31 11:23:22

but you can rxplt it anyway


spdegabrielle
2022-1-31 11:23:51

Lol. There are good chances he never got rights for the list he is using but just scraped it from various webpages


laurent.orseau
2022-1-31 11:25:17

Maybe, but we can’t track the source higher than Wordle, so it’s the best we can do I think.


spdegabrielle
2022-1-31 11:29:07

Next time a Common Lisper complains about the Racket repl I’m going to say racket doesn’t have a repl it has a rxplt


massung
2022-1-31 14:01:02

IIRC, in Mastermind you don’t know which positions are correct. You just get 1 piece of information back: how many pegs are correct. So, often times your follow-ups are nothing but an attempt to lock down what’s actually in the correct position and what isn’t.

Put another way, Wordle’s “hard mode” isn’t possible in Mastermind, because you have no idea what’s correct.


laurent.orseau
2022-1-31 14:53:02

True


badkins
2022-1-31 14:53:02

What are you guys talking about? No one has exclusive rights to a list of words.


laurent.orseau
2022-1-31 14:53:50

As much as I would like to trust you, I’d rather have a legitimate source that says so :slightly_smiling_face:


badkins
2022-1-31 14:53:54

In other words, there is no issue with using the same list of words that Wordle uses.


massung
2022-1-31 14:54:41

Words are “natural” - like PI or DNA - and cannot be copyrighted, etc.


badkins
2022-1-31 14:54:45

I’m sorry, but some of those words in your last sentence are in the Wordle list, so please remove them from your message. ;)


soegaard2
2022-1-31 14:55:51

Tell that to J.K.Rowling…


badkins
2022-1-31 14:57:16

No problem, I sorted my word lists, so they’re in a different order than Wordle :)


laurent.orseau
2022-1-31 14:58:27

Hasbro begs to differ: > The definition-free _OWL_ and a words-only version of the _OSPD_ might be said to resemble the phone book. The facts in them—the individual words themselves—wouldn’t be considered “original” and likely couldn’t be copyrighted. But the lists might represent “an original selection or arrangement of facts,” as Justice Sandra Day O’Connor wrote in _Feist_. “These choices as to selection and arrangement, so long as they are made independently by the compiler and entail a minimal degree of creativity,” she wrote, “are sufficiently original that Congress may protect such compilations through the copyright laws.” Source: https://slate.com/human-interest/2014/09/scrabble-copyright-dispute-hasbro-says-it-owns-the-scrabble-dictionary-players-beg-to-differ.html


massung
2022-1-31 15:00:59

A company attempting to grab hold of anything that could possibly make them money and extend their influence, and stomp on people w/o enough resources to fight back (easily). Shocking. That hardly makes it legal. Although I can sympathize w/ not wanting to “poke the bear” so-to-speak.


laurent.orseau
2022-1-31 15:01:58

> Although I can sympathize w/ not wanting to “poke the bear” so-to-speak. That’s the idea.


badkins
2022-1-31 15:03:48

“entail a minimal degree of creativity” ’nuff said


massung
2022-1-31 15:06:16

Didn’t read the scrabble thing in detail, but I think that - if the “dictionary” in question contains tile values + maximum possible scorings, etc. WRT copyrighted rules of Scrabble and board tiles/setup, then Hasbro may have something (in court, I personally think the idea is silly, tho).


badkins
2022-1-31 15:06:20

Oh wow, have you guys done today’s Wordle with your solvers?!?!?! It’s one of the “trap” words!


badkins
2022-1-31 15:06:45

I was lucky and got it in 6 :)


badkins
2022-1-31 15:07:04

Wordle 226 6/6

:white_large_square::white_large_square::white_large_square::white_large_square::white_large_square: :white_large_square::white_large_square::white_large_square::large_yellow_square::white_large_square: :white_large_square::large_green_square::large_green_square::large_green_square::large_green_square: :white_large_square::large_green_square::large_green_square::large_green_square::large_green_square: :white_large_square::large_green_square::large_green_square::large_green_square::large_green_square: :large_green_square::large_green_square::large_green_square::large_green_square::large_green_square:


badkins
2022-1-31 15:07:41

I was too lazy to code up a defensive measure for that one.


rokitna
2022-1-31 15:08:17

I wonder how much the words count as Wordle’s API surface in the sense of Google vs Oracle. Probably depends on how a judge feels about the transformativeness of Wordle solver programs.


laurent.orseau
2022-1-31 15:08:30

Got it in 5 (that’s my second game) after using a non-hard mode word


badkins
2022-1-31 15:09:11

Manually, or with a program?


laurent.orseau
2022-1-31 15:09:25

manually


laurent.orseau
2022-1-31 15:09:34

I haven’t written the solver yet, will do! :slightly_smiling_face:


badkins
2022-1-31 15:09:54

Ah, yeah, I don’t think it’s too hard manually, but a problem for my program which only does hard mode.


laurent.orseau
2022-1-31 15:10:09

I think non-hard mode is actually more interesting


badkins
2022-1-31 15:10:34

I agree 100% - not sure if I’m motivated to code it up though :)


badkins
2022-1-31 15:11:49

I think I’m de-motivated by the fact that the type of feedback used seems very different than what you’d have in a typical AI program, so the solver is too niche for me to get super excited by it.


badkins
2022-1-31 15:12:07

I mean, chess is niche also, but I think it warrants more effort.


laurent.orseau
2022-1-31 15:13:11

You can basically use the same tools, deep down, since it’s a planning problem with a clear objective function


soegaard2
2022-1-31 15:13:21

Manually: Wordle 226 4/6

:black_large_square::black_large_square::black_large_square::large_yellow_square::black_large_square: :large_yellow_square::black_large_square::black_large_square::black_large_square::black_large_square: :black_large_square::large_yellow_square::black_large_square::large_yellow_square::black_large_square: :large_green_square::large_green_square::large_green_square::large_green_square::large_green_square:


laurent.orseau
2022-1-31 15:13:51

were you lucky on the last one or was it the only solution?


massung
2022-1-31 15:14:52

i got mine in 4, but happened to have picked the 1st letter in an earlier try.

Wordle 226 4/6

:white_large_square::white_large_square::white_large_square::white_large_square::white_large_square: :white_large_square::large_yellow_square::large_yellow_square::white_large_square::large_yellow_square: :white_large_square::large_green_square::large_yellow_square::large_yellow_square::white_large_square: :large_green_square::large_green_square::large_green_square::large_green_square::large_green_square:


soegaard2
2022-1-31 15:15:16

I can see from the unused letters that there were at least two other possible words.


massung
2022-1-31 15:16:10

if you had all but the 1st letter there were a good 5–15 possible words it could be based on what you had eliminated previously.


rokitna
2022-1-31 15:17:36

I seem to remember hearing professional Scrabble players pay lots of attention to word list updates for strategy purposes. It’s potentially a game balance issue, and the words that are admitted are probably contested among players, not just for enabling uncompetitive strategies but for changing how accessible the game is to people who don’t memorize dictionaries. I’m not a fan of copyright in general, but I would consider that selection process to easily involve more than a minimal degree of creativity.


badkins
2022-1-31 15:19:04

@massung when you said your solver got it in 3 guesses usually except for one time taking 4, are you saying that your solver’s 3rd guess is right? If so, that seems really good.


massung
2022-1-31 15:19:25

My solver this time around failed to get it in 6 (got it in 7).


massung
2022-1-31 15:19:39

Working on a new solver tho, which I hope to chat about later today. :slightly_smiling_face:


massung
2022-1-31 15:19:46

(something more “fun”)


badkins
2022-1-31 15:20:27

Without special purpose code for today’s trap, it just depends on the order of words tried, so mine was just lucky.


badkins
2022-1-31 15:21:11

I’m debating on whether to make an easy mode solver.


massung
2022-1-31 15:21:40

Today’s “trap” could have been avoided with earlier guesses. The first letter is quite common, so should have been chosen by an algorithm in an earlier guess. This is one where “hard mode” likely screwed many people, though.


badkins
2022-1-31 15:21:42

Also, it doesn’t seem fair to know the target list, and use it for testing :)


soegaard2
2022-1-31 15:23:45

Luckily most of the first possible letters were eliminated.


massung
2022-1-31 15:23:58

I’m using this wordlist (500 of the most common 5-letter words) for testing and another purpose ATM.


soegaard2
2022-1-31 15:24:15

@badkins What did you mean by trap?


laurent.orseau
2022-1-31 15:24:58

*ight


badkins
2022-1-31 15:26:10

@soegaard2 my program (unintentionally) works in hard mode, so on the 3rd guess it tried “dight” and got the last 4 letters right. That means, the next guesses have to use those same last 4 letters which means I don’t get much new info since I can only vary the 1st letter.


soegaard2
2022-1-31 15:26:48

I see. Then luck is needed.


badkins
2022-1-31 15:27:08

Well, you can add code to circumvent the problem I think.


badkins
2022-1-31 15:28:20

I’m curious how many instances of N words differing by only 1 letter in the same spot there are, where N > 3, or so.


badkins
2022-1-31 15:28:38

is the *ight family the worst?


laurent.orseau
2022-1-31 15:28:39

About the rules: Say the target word is “happy”, and you write “mamas”, will the two “a” be in orange, or only the first one?


massung
2022-1-31 15:28:44

ixnay on the luck part. Given that “L” appears far more frequently in words (esp. in the first position) than “G”, “W”, “M”, …, it should have been the guess made over “dight”, because - if wrong - it would reveal far more information (by eliminating words) than any of the other guesses possible.


massung
2022-1-31 15:28:57

That said, my solver failed to do that as well. :stuck_out_tongue:


massung
2022-1-31 15:29:39

It will be green. You won’t be given information saying that there’s another.


massung
2022-1-31 15:29:56

Err… I misread, flipped it thinking you meant “mamas” was the solution


massung
2022-1-31 15:30:09

If you wrote “mamas” then you’d get green and yellow


laurent.orseau
2022-1-31 15:30:22

oops, yeah it should be green. But say the target is “arrow” instead


badkins
2022-1-31 15:30:33

@massung I switched from a global letter frequency to a per position letter frequency, and surprisingly, at first, it made it worse! Anyway, I’m currently using a per slot frequency, so apparently D is more common in position 1 than L (or I have a bug).


laurent.orseau
2022-1-31 15:30:37

I guess there’ll be only one orange “a” in “mamas”?


massung
2022-1-31 15:30:37

Then two yellow


badkins
2022-1-31 15:30:55

Oh, that is, it’s more common in the remaining list of words that match the criteria (i.e. hard mode).


massung
2022-1-31 15:31:01

If the solution was “arrow” and you typed “mamas”, you’d get a yellow box for each “a”


laurent.orseau
2022-1-31 15:31:26

hm, that’s weird


badkins
2022-1-31 15:31:27

So mine guessed: CARES PONTY DIGHT WIGHT MIGHT LIGHT


laurent.orseau
2022-1-31 15:31:30

thanks


massung
2022-1-31 15:32:17

> I switched from a global letter frequency to a per position letter frequency, and surprisingly, at first, it made it worse It needs to be (IMO) the frequency of all positions where it could possibly be still.


badkins
2022-1-31 15:33:21

It is. I have a vector of 5 vectors where the latter is a 26 element vector of frequencies per letter. So I score a guess word based on the frequency of a letter in the spot I’m checking.


badkins
2022-1-31 15:34:18

In this case, with the last 4 positions known, all that matters (to my program) is choosing the unused letter with the highest frequency in the 1st slot.


massung
2022-1-31 15:35:26

Sorry, maybe a lack of knowledge on my part.

Assuming you don’t already know that “ight” is correct (and is just part of your guess) - or at least part of it is still part of the “guess”, then even though you’re guessing a letter for the first position, it’s still possible that letter might be in one of the other positions. So you want to eliminate - when wrong - as many possible downstream words as you can.


badkins
2022-1-31 15:35:52

So, I think to avoid the trap, you’d want to know all the “families” of words that differ by 1 letter, and choose guesses to avoid getting into the *ight situation.


massung
2022-1-31 15:36:24

So, if you know that “ig” is correct, even tho you’re picking a first position letter, you want words where that letter might appear in slots: 0, 3, or 4 as well.


massung
2022-1-31 15:36:57

> the “families” of words that differ by 1 letter That’s an interesting idea, too.


badkins
2022-1-31 15:37:32

You may be right, and that may be why I saw a decrease when switching to per slot frequencies!! I then made a few other algorithmic improvements that beat my original performance, but maybe switching back to global freq with those other improvements would be even better. I was basically in stream of consciousness coding mode :)


badkins
2022-1-31 15:38:19

I’d be more interested in coding an easy mode solver though.


massung
2022-1-31 15:38:40

Been there, done that. Worst for me are things like AoC where I stick to my initial idea and only 2 hours later after making no headway do I stop and re-eval. :stuck_out_tongue_winking_eye:


badkins
2022-1-31 15:39:15

Yes - I did that a lot. Sometimes that kind of bulldog tenacity pays off, but if it’s in the wrong direction, it can be bad :)


badkins
2022-1-31 15:42:26

A “todo” list item I didn’t get to for my solver, was to make use of info indicating a letter occurred at least N times vs. my current knowledge of only whether it occurs, or not. I’m pretty sure that would provide a significant boost in effectiveness.


badkins
2022-1-31 15:45:20

Just deleted the comments on this because I reversed my opinion like 3 times in 30 seconds. I should think about this more…


laurent.orseau
2022-1-31 17:25:03

Averaging out the likely bugs, I’ve finished a first draft of my solver. It finds “light” in 4 guesses


laurent.orseau
2022-1-31 18:37:22

I just realized that when using “Rename variable”, we can actually use any string such as a function call (handy for turning variables into parameters) or even several identifiers (handy to change a single value to several?)


sorawee
2022-1-31 18:39:11

I don’t think that’s meant to work though. It renames both binding and bound occurrences. A general expression at bound occurrences makes sense. But that’s not the case for binding occurrences.


laurent.orseau
2022-1-31 18:41:37

Yes, that can fail indeed :slightly_smiling_face:


laurent.orseau
2022-1-31 18:41:52

I think it’s good enough though, and doesn’t need to be fixed


laurent.orseau
2022-1-31 20:04:50

On the 2315 target words, in ‘easy’ mode and using the additional list of allowed words, my solver finds all words in at most 5 moves except for 2 where it takes 6 moves: #guesses #words 1 1 2 52 3 982 4 1182 5 96 6 2 The two “hard” words are corer and mover .


jcoo092
2022-1-31 20:08:31

I’m moderately certain that while each word by itself is (essentially) in the public domain, the compilation of a list can be considered a copyrighted work. I can’t think of citations for that right now, though.


laurent.orseau
2022-1-31 20:11:12

In hard mode (still allowing additional words), it’s not so nice though: #guesses #words 1 1 2 93 3 908 4 1033 5 222 6 42 7 13 8 3


laurent.orseau
2022-1-31 20:16:28

and finally in hard mode without the additional list of words, there’s even a 9 steps guess :disappointed: #guesses #words 1 1 2 122 3 889 4 981 5 256 6 49 7 12 8 4 9 1


laurent.orseau
2022-1-31 20:19:49

I think the hard mode requires some plan ahead to reduce the worst cases. That may be pretty time consuming though.


badkins
2022-1-31 20:59:28

You’re probably right - I’m just being difficult. Regardless, I think we all know that using the same list of 5 letter words as Wordle uses will likely never land in any court :)


massung
2022-1-31 21:02:44

I have to stick it up on github, but my “fun” wordle solution…

I built a reinforcement/q-learning model that learned to play the game. Clocks in at 185 LOC. It uses a good amount of RAM and time to build the model, so I decided to - instead - grab a much smaller wordlist of 500 common, 5-letter words and use that as my setup. It’s possible to just swap out one wordlist for another and it’s fine, but I didn’t feel like training it for 13,000 words.

Example output of training: > (learn-common-words) Learning (1/500) "about"... Won 996 of 1000 games. Learning (2/500) "above"... Won 999 of 1000 games. Learning (3/500) "abuse"... Won 990 of 1000 games. Learning (4/500) "actor"... Won 995 of 1000 games. Learning (5/500) "acute"... Won 997 of 1000 games. Learning (6/500) "admit"... Won 1000 of 1000 games. Learning (7/500) "adopt"... Won 997 of 1000 games. Learning (8/500) "adult"... Won 997 of 1000 games. ... And playing: > (play "light") Turn 1. "leave" Turn 2. "light" #t > (play "light") Turn 1. "begun" Turn 2. "logic" Turn 3. "light" #t > (play "light") Turn 1. "these" Turn 2. "forum" Turn 3. "dying" Turn 4. "vital" Turn 5. "light" #t > --- > (play "house") Turn 1. "think" Turn 2. "clear" Turn 3. "mouse" Turn 4. "house" #t It learns using hard mode, but plays in easy mode.

The model takes ~1.5 GB of RAM to build and - when saved using s-exp->fasl - clocks in at ~225 MB. Zipped it’s only 15 MB, though. I’d love to chat about the solution if anyone is interested. Would love to play around with it more and see what other models for the state/reward people can come up with!


laurent.orseau
2022-1-31 21:10:33

As long as the lists remain on our personal laptops, there can hardly be any real problem. But the issue may arise if we create a public repo with the list of words and give it a license.



jcoo092
2022-1-31 22:39:11

I have a suspicion they’ll regret the price tag in a few months when the fad dies down. Good for Mr. Wardle, though.


massung
2022-1-31 22:53:36

Not just fad, but no one I know will subscribe to the times to play.


sschwarzer
2022-1-31 22:53:47

sorawee
2022-1-31 22:57:24

I’m not sure if I buy the criticism that Discord is not accessible, when one of the suggested alternatives is IRC.


sorawee
2022-1-31 22:58:10

I have positive experience with Zulip though.


samdphillips
2022-1-31 23:21:20

I wonder if the price for Wordle is more or less than the amount of money the NYT pays crossword puzzle makers annually.


spdegabrielle
2022-2-1 00:50:58

I dislike that discord is a walled garden, so I often push posters in #show-and-tell to post on Discourse.(which is FOSS & not a walled garden)


spdegabrielle
2022-2-1 00:52:13

I then link back to the discourse post from Reddit, Twitter & mastodon.


spdegabrielle
2022-2-1 00:56:12

I think if there is a platform where racket users congregate we should endeavour to reach out and build bridges. (In the human sense not automated message bridges that platform owners sabotage - I’m looking at you @Slack)


spdegabrielle
2022-2-1 00:57:47

I even try with facebook sometimes but it feels like a ghost town


spdegabrielle
2022-2-1 00:58:33

I’m waiting for racket TikTok :scream:


samdphillips
2022-2-1 01:00:21

We should leave that for the youths.


spdegabrielle
2022-2-1 01:02:21

The thing would be to (crowd?) source our own list of words so you know it doesn’t contain a ‘trap street’.


james275
2022-2-1 02:26:32

Also, it seems like not the hardest thing to implement, but not scale. How long until free to play, no ads wordle clones appear all over the place?


laurent.orseau
2022-2-1 07:39:35

I’m probably not going to get a reply anytime soon then :sweat_smile: