en-wl / wordlist

SCOWL (and friends).
http://wordlist.aspell.net
Other
394 stars 79 forks source link

Oxford dictionary for hunspell? #342

Closed allefeld closed 3 months ago

allefeld commented 2 years ago

I would like to use Oxford spelling for spell check with hunspell, but I find it hard to figure out how to do so.

I first looked in my distribution (Debian), but there is only the standard British dictionary hunspell-en-gb. I then googled, and found the hunspell_dictionaries directory in Google's chromium/deps repository, which contains the files: en-GB-oxendict-9-0.bdic, en_GB_oxendict.aff, en_GB_oxendict.dic, en_GB_oxendict.dic_delta.

The corresponding README_en_GB_oxendict.txt doesn't say much, but led me to this repository and http://wordlist.aspell.net/other-dicts/. That page mentions "en_GB-oed" (not "en_GB_oxendict"), but doesn't explain how to use it. The listed link http://en-gb.pyxidium.co.uk/index.php is broken. Simply trying to use it, hunspell -d en_GB-oed unsurprisingly didn't work.

Next I downloaded this repository and followed the build instructions. That led to a lot of files being generated, including under scowl/speller/hunspell/ the files

hunspell-en_GB-ise.zip
hunspell-en_GB-ize.zip
hunspell-en_GB-large.zip

However, there is nothing for "en_GB-oed" or "en_GB-oxendict", plus there are no installation instructions. I assume I would have to copy the dic and aff file into /usr/share/hunspell – but from which zip-file?

ianhellstrom commented 2 years ago

I second that!

Tex2002ans commented 2 years ago

I would like to use Oxford spelling for spell check with hunspell, but I find it hard to figure out how to do so.

On SCOWL's "English Spell Checker Dictionaries" page, there's a link to this tool:

You'll want to select:

After you select whatever other options you want, press the button for:

This will give you a ZIP file with 3 files:

However, there is nothing for "en_GB-oed" or "en_GB-oxendict" [...]

oed was the old language code for the "Oxford English Dictionary". In 2015, it was deprecated and changed to oxendict.

For more info on the latest language codes, see IANA.org: "Language Subtag Directory".

[...] plus there are no installation instructions. I assume I would have to copy the dic and aff file into /usr/share/hunspell

Yes.

You can then rename the .aff + .dic files inside the ZIP to:

Then place it where it's needed.

The listed link http://en-gb.pyxidium.co.uk/index.php is broken.

And for your future knowledge, Archive.org is absolutely fantastic for recovering/reading dead websites:

It looks like the website died around 2014, but the files are still recoverable. :)

getsnoopy commented 1 year ago

Indeed. The en_GB-ize is the Oxford dictionary spelling, so just rename that to whatever you want.

I've already added this dictionary into Chrome as its own locale, so if you want to use it for spellchecking purposes on the web, you can just change your browser locale to English (UK, Oxford English Dictionary spelling) in the Settings > Languages menu of Chrome (and set it to Basic spell check).

kevina commented 3 months ago

@allefeld the file you want is hunspell-en_GB-ize.zip. The main difference between the two British spellings is the -ise vs -ize ending, hence the name, however -ize also follows the Oxford spelling in other ways.

kevina commented 3 months ago

I will consider changing -ize to -oxendict, see #401 Closing this issue as completed.