PyCantonese: Cantonese Linguistics and NLP in Python
Project description
Full Documentation: https://pycantonese.org
PyCantonese is a Python library for Cantonese linguistics and natural language processing (NLP). Currently implemented features (more to come!):
Accessing and searching corpus data
Parsing and conversion tools for Jyutping romanization
Stop words
Word segmentation
Part-of-speech tagging
Download and Install
To download and install the stable, most recent version:
$ pip install --upgrade pycantonese
Ready for more? Check out the Quickstart page.
Consulting
If your team would like professional assistance in using PyCantonese, technical consulting and training services are available. Please email Jackson L. Lee.
Support
If you have found PyCantonese useful and would like to offer support, buying me a coffee would go a long way!
Links
Source code: https://github.com/jacksonllee/pycantonese
Bug tracker: https://github.com/jacksonllee/pycantonese/issues
How to Cite
PyCantonese is authored and maintained by Jackson L. Lee.
A talk introducing PyCantonese:
Lee, Jackson L. 2015. PyCantonese: Cantonese linguistic research in the age of big data. Talk at the Childhood Bilingualism Research Centre, Chinese University of Hong Kong. September 15. 2015. Notes+slides
License
MIT License. Please see LICENSE.txt in the GitHub source code for details.
The HKCanCor dataset included in PyCantonese is substantially modified from its source in terms of format. The original dataset has a CC BY license. Please see pycantonese/data/hkcancor/README.md in the GitHub source code for details.
The rime-cantonese data (release 2020.09.09) is incorporated into PyCantonese for word segmentation and characters-to-Jyutping conversion. This data has a CC BY 4.0 license. Please see pycantonese/data/rime_cantonese/README.md in the GitHub source code for details.
Logo
The PyCantonese logo is the Chinese character 粵 meaning Cantonese, with artistic design by albino.snowman (Instagram handle).
Acknowledgments
Wonderful resources with a permissive license that have been incorporated into PyCantonese:
HKCanCor
rime-cantonese
Individuals who have contributed feedback, bug reports, etc. (in alphabetical order of last names):
@cathug
Litong Chen
Jenny Chim
@g-traveller
Rachel Han
Ryan Lai
Charles Lam
Chaak Ming Lau
Hill Ma
@richielo
@rylanchiu
Stephan Stiller
Tsz-Him Tsui
Robin Yuen
Changelog
Please see CHANGELOG.md.
Setting up a Development Environment
The latest code under development is available on Github at jacksonllee/pycantonese. You need to have Git LFS installed on your system. To obtain this version for experimental features or for development:
$ git clone https://github.com/jacksonllee/pycantonese.git
$ cd pycantonese
$ git lfs pull
$ pip install -r dev-requirements.txt
$ pip install -e .
To run tests and styling checks:
$ pytest -vv --doctest-modules --cov=pycantonese pycantonese docs/source
$ flake8 pycantonese
$ black --check pycantonese
To build the documentation website files:
$ python docs/source/build_docs.py
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
File details
Details for the file pycantonese-3.3.1.tar.gz
.
File metadata
- Download URL: pycantonese-3.3.1.tar.gz
- Upload date:
- Size: 3.8 MB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.2.0 pkginfo/1.7.0 requests/2.24.0 setuptools/54.1.2 requests-toolbelt/0.9.1 tqdm/4.59.0 CPython/3.9.2
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 848d13a479b8161d93ffc85261a615f98419187ee937c4aa92e45d21ec8226ce |
|
MD5 | fb1d40f3e5e7dfdedfe5eab0cc45646e |
|
BLAKE2b-256 | 6f9399f7828bcd1c11890edef89fd74bba40c290ea1064dcbe533822b09237ab |
File details
Details for the file pycantonese-3.3.1-py3-none-any.whl
.
File metadata
- Download URL: pycantonese-3.3.1-py3-none-any.whl
- Upload date:
- Size: 3.9 MB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.2.0 pkginfo/1.7.0 requests/2.24.0 setuptools/54.1.2 requests-toolbelt/0.9.1 tqdm/4.59.0 CPython/3.9.2
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 53ecbe01f4d1d6c679600b6afe3e0c4b711acacb7fd985ead6097e9ce4670c18 |
|
MD5 | ba64cb9796cfc18d2e9618793b5a264f |
|
BLAKE2b-256 | 050e097604bf67d39cff145767844bd45bba4fd56e874632a370daeb57e0ba64 |