# How to Write a Spelling Corrector (in Python)

DevFeed: [How to Write a Spelling Corrector (in Python)](<https://devfeed.tech/articles/how-to-write-a-spelling-corrector-in-python-40587.md>)

Original publisher: [Read original article](<http://norvig.com/spell-correct.html>)

Published: 2007-04-10T00:00:00Z

Content type: tutorial

Language: en

Sources: [Peter Norvig](<https://devfeed.tech/sources/peter-norvig.md>)

Topics: [Python](<https://devfeed.tech/topics/python.md>), [Algorithms](<https://devfeed.tech/topics/algorithms.md>), [Algorithms, Complexity](<https://devfeed.tech/topics/algorithms-complexity.md>), [Code](<https://devfeed.tech/topics/code.md>)

Tags: [algorithms](<https://devfeed.tech/tags/algorithms.md>), [code](<https://devfeed.tech/tags/code.md>), [how-to](<https://devfeed.tech/tags/how-to.md>), [python](<https://devfeed.tech/tags/python.md>), [theory](<https://devfeed.tech/tags/theory.md>)

## AI overview

A tutorial on building a toy spelling corrector in Python. It explains how to choose likely corrections using probabilities, separates word likelihood from edit likelihood, and considers candidate words generated by one- and two-edit operations.

## Source excerpt

Theory and practice of spelling correction algorithms