ruscorpora-tools
This package provides Python interface to a free corpus subset available at http://ruscorpora.ru.
Installation
pip install ruscorpora-tools
Usage
Corpus downloading
Download and unpack the archive with XML files from http://www.ruscorpora.ru/corpora-usage.html
Corpus reading
ruscorpora.parse_xml function parses single XML file and returns an iterator over sentences; each sentence is a list of ruscorpora.Token instances, annotated with a list of ruscorpora.Annotation instances.
ruscorpora.simplify simplifies a result of ruscorpora.parse_xml by removing ambiguous annotations, joining split tokens (+ joining their annotations) and removing accent information.
>>> import ruscorpora as rnc
>>> for sent in rnc.simplify(rnc.parse('fiction.xml')):
... print(sent)
Development
Development happens at github and bitbucket:
The issue tracker is at github: https://github.com/kmike/ruscorpora-tools/issues
Feel free to submit ideas, bugs, pull requests (git or hg) or regular patches.
Running tests
Make sure tox is installed and run
$ tox
from the source checkout. Tests should pass under python 2.6..3.3 and pypy > 1.8.
Metadata
Release files for ruscorpora-tools 0.3
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| ruscorpora-tools-0.3.tar.gz | 8.3 kB | Without provenance | Details for ruscorpora-tools-0.3.tar.gz |
Release files / ruscorpora-tools-0.3.tar.gz
| Download URL | ruscorpora-tools-0.3.tar.gz |
|---|---|
| Size | 8.3 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
50b6c5845e1b7fba7ca71a7ba85376a5b63b5c413ae231434ae2fb5ec8d11936
|
|
BLAKE2b-256 checksum How to use checksums |
3422560bfdc4947453075b72b6deeb81357ad6812f5c0e5818c2c10e928fd6f8
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
Security for ruscorpora-tools 0.3
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.