Skip to main content

Tiny preprocessor for Russian text

Project description

RuMor: Russian Morphology project

Toxine: a tiny python NLP library for Russian text preprocessing

PyPI Version Python Version License: BSD-3

A part of RuMor project. It contains pipeline for preprocessing and tokenization texts in Russian. Also, it includes preliminary entity tagging. Highlights are:

  • Extracting emojis, emails, dates, phones, urls, html/xml fragments etc.
  • Tagging/removing tokens with unallowed symbols
  • Normalizing punctuation
  • Tokenization (via NLTK)
  • Russan Wikipedia tokenizer
  • brat annotations support

Installation

pip

Toxine supports Python 3.5 or later. To install it via pip, run:

$ pip install toxine

If you currently have a previous version of Toxine installed, use:

$ pip install toxine -U

From Source

Alternatively, you can also install Toxine from source of this git repository:

$ git clone https://github.com/fostroll/toxine.git
$ cd toxine
$ pip install -e .

This gives you access to examples that are not included to the PyPI package.

Setup

Toxine uses NLTK with punkt data downloaded. If you didn't do it yet, start Python interpreter and execute:

>>> import nltk
>>> nltk.download('punkt')

NB: If you plan to use methods for brat annotations renewal, you need to install the python-Levenshtein library. See more on the brat annotations support page.

Usage

Text Preprocessor

Wrapper for tokenized Wikipedia

brat annotations support

Examples

You can find them in the directory examples of our Toxine github repository.

License

Toxine is released under the BSD License. See the LICENSE file for more details.

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

toxine-1.0.52.tar.gz (29.5 kB view details)

Uploaded Source

Built Distribution

toxine-1.0.52-py3-none-any.whl (29.5 kB view details)

Uploaded Python 3

File details

Details for the file toxine-1.0.52.tar.gz.

File metadata

  • Download URL: toxine-1.0.52.tar.gz
  • Upload date:
  • Size: 29.5 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.2.0 pkginfo/1.5.0.1 requests/2.24.0 setuptools/47.1.0 requests-toolbelt/0.9.1 tqdm/4.49.0 CPython/3.8.5

File hashes

Hashes for toxine-1.0.52.tar.gz
Algorithm Hash digest
SHA256 279250ac63c4fe41dab749bbf4a9d9d288c1b40ad89f8a8ad24bfd5ae64fe47d
MD5 d928ceea9ed8c5418388ede0ef27e861
BLAKE2b-256 0b43bcdac13c164940689d6ef8965e249ed0bda4e0ed233dba8eafcbc45a1ef5

See more details on using hashes here.

File details

Details for the file toxine-1.0.52-py3-none-any.whl.

File metadata

  • Download URL: toxine-1.0.52-py3-none-any.whl
  • Upload date:
  • Size: 29.5 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.2.0 pkginfo/1.5.0.1 requests/2.24.0 setuptools/47.1.0 requests-toolbelt/0.9.1 tqdm/4.49.0 CPython/3.8.5

File hashes

Hashes for toxine-1.0.52-py3-none-any.whl
Algorithm Hash digest
SHA256 773de3753814dbc43d5c4ac8be956c9ae5844a497f345fe675afc890c14e77a3
MD5 52120115a4a3df17e64ce80d72a38600
BLAKE2b-256 49e1b4720450edca8c5fe352fa499160d1965c10d1885dc6716c1afdf02436bd

See more details on using hashes here.

Supported by

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