spell-checking - Metaphone 3 算法是什么?

标签 spell-checking phonetics metaphone

我想自己编写 Metaphone 3 算法。有说明吗?我知道源代码可以出售,但这不是我要找的。

最佳答案

@Bo 的链接现在是指(现在是 deucnt)项目的整个源代码。
因此这里是新的链接,直接链接到 Metaphone 3 的源代码
https://searchcode.com/codesearch/view/2366000/
劳伦斯·飞利浦

Metaphone 3 is designed to return an approximate phonetic key (and an alternate * approximate phonetic key when appropriate) that should be the same for English * words, and most names familiar in the United States, that are pronounced similarly. * The key value is not intended to be an exact phonetic, or even phonemic, * representation of the word. This is because a certain degree of 'fuzziness' has * proven to be useful in compensating for variations in pronunciation, as well as * misheard pronunciations. For example, although americans are not usually aware of it, * the letter 's' is normally pronounced 'z' at the end of words such as "sounds".

The 'approximate' aspect of the encoding is implemented according to the following rules:

* * (1) All vowels are encoded to the same value - 'A'. If the parameter encodeVowels * is set to false, only initial vowels will be encoded at all. If encodeVowels is set * to true, 'A' will be encoded at all places in the word that any vowels are normally * pronounced. 'W' as well as 'Y' are treated as vowels. Although there are differences in * the pronunciation of 'W' and 'Y' in different circumstances that lead to their being * classified as vowels under some circumstances and as consonants in others, for the purposes * of the 'fuzziness' component of the Soundex and Metaphone family of algorithms they will * be always be treated here as vowels.

* * (2) Voiced and un-voiced consonant pairs are mapped to the same encoded value. This means that:
* 'D' and 'T' -> 'T'
* 'B' and 'P' -> 'P'
* 'G' and 'K' -> 'K'
* 'Z' and 'S' -> 'S'
* 'V' and 'F' -> 'F'

* * - In addition to the above voiced/unvoiced rules, 'CH' and 'SH' -> 'X', where 'X' * represents the "-SH-" and "-CH-" sounds in Metaphone 3 encoding.

关于spell-checking - Metaphone 3 算法是什么?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/10442633/

相关文章:

PHP 变音位实现错误

java - Metaphone 3 用 java 实现

java - Lucene:使用 RAMDictionary 进行拼写检查似乎不起作用

html - 在 UIWebView 中的 div 或 pre 标签中禁用自动更正

algorithm - 如何着手将未经训练的语音转换为文本转换器?

.net - 如何使用.net比较两个音轨的波形?

python - Python 拼写检查器

eclipse - 在 Eclipse 中更改拼写错误的颜色

search - 搜索用户名的语音算法

mysql - 模糊自动完成