【问题标题】:Dictionary File Structure of Open Spell-Checkers开放拼写检查器的字典文件结构
【发布时间】:2011-12-14 11:31:01
【问题描述】:
是否有任何关于 FreeDict、Aspell、Hunspell/OpenOffice 词典的文件结构的解释文档或教程,特别是关于每个 .dic 文件中每行末尾的开关?我的猜测是这些开关描述了这个词的语义解释,无论它是一个
或以上任意组合。但我不知道如何将这些与开关字符匹配。
我也很好奇 .aff 文件描述的内容。
【问题讨论】:
标签:
dictionary
spell-checking
openoffice.org
libreoffice
hunspell
【解决方案3】:
在 Hunspell 中,您选择的标签是任意的,除了您分配给它们的含义之外,它们没有任何意义。您可以选择使用字母、数字 (1-65535) 等。
词缀文件描述了很多东西,但主要关注单词的屈折变化。
例如:
$ test.dic
4
apple/a
banana/a
green/b
small/b
$ test.aff
SFX a Y 2 # Allow the following 2 suffixes to words with the "a" flag.
SFX a 0 s . # An "s" at the end for words ending in any letter (signified by the dot). "Apples" and "bananas".
SFX a 0 s' . # "Apples'" and "bananas'".
SFX b Y 2
SFX b 0 er . # "Greener" and "smaller".
SFX b 0 est . # "Greenest" and "smallest".
The manual 详细解释了大部分内容。也有可以查看的测试文件。