Hostname: page-component-74656f9884-2dmjx Total loading time: 0 Render date: 2026-11-06T21:01:54.737Z Has data issue: false hasContentIssue false

A novel string distance metric for ranking Persian respelling suggestions

Published online by Cambridge University Press:  24 July 2012

OMID KASHEFI
Affiliation:
School of Computer Engineering, Iran University of Science and Technology, Tehran, Iran e-mails: kashefi@ieee.org, kashefi@iust.ac.ir, b_minaei@iust.ac.ir
MOHSEN SHARIFI*
Affiliation:
School of Computer Engineering, Iran University of Science and Technology, Tehran, Iran e-mails: kashefi@ieee.org, kashefi@iust.ac.ir, b_minaei@iust.ac.ir
BEHROOZ MINAIE
Affiliation:
School of Computer Engineering, Iran University of Science and Technology, Tehran, Iran e-mails: kashefi@ieee.org, kashefi@iust.ac.ir, b_minaei@iust.ac.ir
*
*Corresponding author: Email msharifi@iust.ac.ir
Rights & Permissions [Opens in a new window]

Abstract

Spelling errors in digital documents are often caused by operational and cognitive mistakes, or by the lack of full knowledge about the language of the written documents. Computer-assisted solutions can help to detect and suggest replacements. In this paper, we present a new string distance metric for the Persian language to rank respelling suggestions of a misspelled Persian word by considering the effects of keyboard layout on typographical spelling errors as well as the homomorphic and homophonic aspects of words for orthographical misspellings. We also consider the misspellings caused by disregarded diacritics. Since the proposed string distance metric is custom-designed for the Persian language, we present the spelling aspects of the Persian language such as homomorphs, homophones, and diacritics. We then present our statistical analysis of a set of large Persian corpora to identify the causes and the types of Persian spelling errors. We show that the proposed string distance metric has a higher mean average precision and a higher mean reciprocal rank in ranking respelling candidates of Persian misspellings in comparison with other metrics such as the Hamming, Levenshtein, Damerau–Levenshtein, Wagner–Fischer, and Jaro–Winkler metrics.

Information

Type
Articles
Copyright
Copyright © Cambridge University Press 2012
Figure 0

Table 1. Different single-error types (n.b. there is no correspondence between English and Persian words)

Figure 1

Algorithm 1 Levenshtein Distance

Figure 2

Algorithm 2 Damerau–Levenshtein Distance

Figure 3

Algorithm 3 Wagner–Fischer Distance

Figure 4

Algorithm 4 Jaro Distance

Figure 5

Algorithm 5 Jaro–Winkler Distance

Figure 6

Algorithm 6 Hamming Distance

Figure 7

Table 2. Persian homophone letters

Figure 8

Table 3. Persian homomorph letters

Figure 9

Table 4. The pattern of Persian spelling errors

Figure 10

Table 5. The probability of occurrence and the distance of single-errors in Persian

Figure 11

Fig. 1. The English QWERTY keyboard layout.

Figure 12

Fig. 2. The Persian standard keyboard layout.

Figure 13

Table 6. Statistics of misspellings involving upper characters in Persian

Figure 14

Algorithm 7 Proposed Character Distance

Figure 15

Algorithm 8 Proposed Substitution Distance of Two Letters

Figure 16

Table 7. The probability of occurrence and the distance of homophones and homomorphs in Persian

Figure 17

Algorithm 9 Proposed Omission Distance of One Letters

Figure 18

Algorithm 10 Proposed String Distance Metric

Figure 19

Table 8. Comparative evaluation measures of the proposed metric

Figure 20

Fig. 3. Relative effectiveness of the proposed string distance metric compared to other metrics.

Figure 21

Table 9. Comparative evaluation measures of the proposed metric for different misspelling types