Does the word appear in (no line break): ~/Library/Group\ Containers/group.com.apple.AppleSpell/Library/Spelling/LocalDictionary ?
If not, you can try typing the word you want to remove into TextEdit.app, selecting it, clicking command-right-click, and choosing “Unlearn Spelling” from the pop-up menu that appears.
Interesting! I followed your path on my Mac and the LocalDictionary was modified just minutes ago when I was testing learning and unlearning spellings in TextEdit to form a reply.
In LocalDictionary, opened in TextEdit, I deleted one of the learned misspellings from paragraph 1 above, saved the file and typed it in a new TextEdit window and it was not marked as incorrect, so the change I made didn’t seem to have taken effect. (some blogs on this topic say a restart is needed).
My dynamic-text.dat was last modified 8 days ago and when I open it in TextEdit it’s one block of text about 9 lines long starting with DynamicDictionary then a string of letters, no spaces, containing numerous misspelled words (I don’t recall marking any of them as learned in the past). I deleted one, saved the file, typed the deleted word in a new TextEdit document and it was marked as incorrect.
One blog said on the Mac to “…Navigate to `Spelling` and then delete `UserDictionary.plist`…". No idea if that works but would probably delete even desired/correct entries. Maybe a .plist file can be opened and edited…
I had a Copilot prompt open, so I typed in a variation of @gingerbeardman’s question. I was very amused when Copilot told me that the source for an answer was…this TidBITS thread.
Anyway, I tried poking around using old school Unix fu. Maybe give the strings command a try to see if you can find the erroneously spelled word. For example:
strings -a ~/Library/Group\ Containers/group.com.apple.AppleSpell/Library/Spelling/dynamic-text.dat
If you have a large dictionary, you may wish to redirect the output to a file using >.