自动校正,自动完成功能 [英] Auto correction , auto complete features
问题描述
我们在Ms-word,google等中键入单词时会看到建议,他们怎么做?
We see suggestions when we type a word in Ms-word , google etc... How do they do that ?
我想知道技术如何自动纠正,自动完成,拼写检查等。 HOw是实际存储的字...什么算法遵循...?
I would like to know how the techniqueslike auto correct , auto complete , spell checking etc.. are performed . HOw are the words actually stored... what algorithms are followed ... ???
欢迎任何建议可能的方式的链接
Any links that suggest a possible way are welcome,
推荐答案
这里有一些数据结构对于使用(和查找)字符串特别有用。
Here are some data structures that are especially useful for working with (and finding) strings.
- Tries
- Suffix trees
- Directed acyclic word graphs
- Suffix array
- Patricia trie
这些对自动完成特别有用。
These can be especially useful for auto-completion.
Here 'sa简单的拼写检查器用Python编写,有一些关于它如何工作的分歧。
Here's a simple spell checker written in Python with a bit of digression on how it works.
为了构建一个字典,你可以解析例如维基百科收集已知的单词。
In order to build a dictionary, you could "parse" e.g. wikipedia to collect known words.
这篇关于自动校正,自动完成功能的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!