Skip to content

Latest commit

 

History

History
47 lines (37 loc) · 1.45 KB

README.md

File metadata and controls

47 lines (37 loc) · 1.45 KB

Spelling Corrector

Spelling Corrector using the frequence of use of words in a dataset of books.

Four languages are currently supported:

  • French (default)
  • English
  • Spanish
  • German

It's also possible to use the corrector with custom sources and alphabets for other languages.

Data used

  • fr :
    • CARPENTIER Nicolas-Joseph, Dictionnaire du bon language - link
    • Voltaire, Candide - link
  • en :
    • SHAKESPEARE William, All's Well That Ends Well - link
    • SHAKESPEARE William, Hamlet - link
  • es :
    • DE CERVANTES Miguel, Don Quijote - link
    • BAROJA Pío, Los Contrastes de la Vida - link
  • de :
    • KANT Immanuel, Kritik der reinen Vernunft - link
    • NIETZSCHE Friedrich, Ecce homo, Wie man wird, was man ist - link

Examples of use

# French correction
c = Corrector()
c.correct('orthografe')
>> orthographe

# English correction
c = Corrector(lang='en')
c.correct('mroinng')
>> morning

References

Spelling corrector based on that of Peter Norvig