Skip to main content

Python Custom Spell Rectifier

Project description

This package helps in rectifying the spelling of the word with the custom collection of words.

Python Custom Spell Rectify

This package helps in rectifying the spelling of the word with the custom collection of words. This uses numpy and difflib module.

Installation

You can install directly after cloning:

use the Python package:

.. code-block:: bash

$ pip install --user py_custom_spellrectify

Command line tool

After installation, you should have py_custom_spellrectify in your $PATH:

Usage

Initailize the handler and load the custom list and auto correct:

.. code-block:: python

>>> from py_custom_spellrectify import WordCorrection
>>> word_handler= WordCorrection()
>>> word_handler.load(input_words=['Commercially', 'available', 'development', 'Discontinued', 'Production', 'Ready', 'Samples', 'Prototype'])
>>> result= word_handler.correct(input='develop', threshold=0.75)
>>> print(result)
>>> ('development', 0.78)

For words whose macthing percentage is lesser than threshold:

.. code-block:: python

>>> result= word_handler.correct(input='devel', threshold=0.75)
>>> print(result)
>>> devel
>>> # the above will return the same input word if the word if the mataching percentage is lesser than the threshold.

License

MIT License

.. code:: rst

|MIT license|

.. image:: https://img.shields.io/badge/License-MIT-blue.svg

Contact

Please submit an issue if you encounter a bug and please email any questions or requests to
1. vimald8959@gmail.com ( https://github.com/vimal-dharmalingam )
2. catchmaurya@gmail.com ( https://github.com/catchmaurya )

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

py_custom_spellrectify-1.0.0.tar.gz (2.7 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

py_custom_spellrectify-1.0.0-py3-none-any.whl (5.7 kB view details)

Uploaded Python 3

File details

Details for the file py_custom_spellrectify-1.0.0.tar.gz.

File metadata

  • Download URL: py_custom_spellrectify-1.0.0.tar.gz
  • Upload date:
  • Size: 2.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.1.1 pkginfo/1.5.0.1 requests/2.20.1 setuptools/41.4.0 requests-toolbelt/0.9.1 tqdm/4.36.1 CPython/3.7.3

File hashes

Hashes for py_custom_spellrectify-1.0.0.tar.gz
Algorithm Hash digest
SHA256 1c942a97b428b17158fa3f2ab081480522113b13c8d2c2886041bbdd7f31cbcf
MD5 60f335aede51ed032a707a911171f4b7
BLAKE2b-256 5246e311b254accbe5c0a9a91c6faf6094cb85cbc7455ed013fa3b925f2845b3

See more details on using hashes here.

File details

Details for the file py_custom_spellrectify-1.0.0-py3-none-any.whl.

File metadata

  • Download URL: py_custom_spellrectify-1.0.0-py3-none-any.whl
  • Upload date:
  • Size: 5.7 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.1.1 pkginfo/1.5.0.1 requests/2.20.1 setuptools/41.4.0 requests-toolbelt/0.9.1 tqdm/4.36.1 CPython/3.7.3

File hashes

Hashes for py_custom_spellrectify-1.0.0-py3-none-any.whl
Algorithm Hash digest
SHA256 739b40bea6fe47f49a3434b946c587eaedea627ffe462c321711d0343d223987
MD5 432ff3952422fafc55192e7ea145dae1
BLAKE2b-256 614bbe8721f44d30c7eb5740378cd794e064b33262a4f6cd1e10de73e4158baf

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page