Lingose
Lingose is an offline English lexicon for Python. Look up pronunciations, word structure and English–Chinese meanings, browse vocabulary lists, or add pronunciation marks to English text.
Requires Python 3.11+. Queries work offline with no third-party runtime dependencies.
The IPSM Approach
The IPSM Approach (Integrated Pronunciation, Spelling and Meaning Approach) connects a word's pronunciation, spelling and meaning to support vocabulary learning. It brings together IPS, which marks pronunciation on the spelling; ISM, which divides a word into morphemes to show its structure; and IPM, which explores links between sound and meaning through listening and speaking. Lingose provides IPA, IPS, ISM, IPSM derived from IPS and ISM, meanings and vocabulary categories for use with the approach.
Install
Install version 0.4.0 from PyPI:
python -m pip install --upgrade lingose==0.4.0
Version 0.4.0 includes reviewed IPS updates for 12,007 words and regenerated IPSM data. The public API and offline runtime format are unchanged from 0.3.0.
Look up a word
Lingose offers four ways to represent a word: IPA for phonetic transcription, IPS for pronunciation marks on its spelling, ISM for morpheme divisions, and IPSM for pronunciation marks combined with those divisions.
import lingose
print(lingose.ipa("apple")) # ['æpəl']
print(lingose.ips("running")) # ['rûnning']
print(lingose.ism("running")) # runn-ing
print(lingose.ipsm("running")) # ['rûnn-ing']
print(lingose.root_lemma("running")) # run
print(lingose.meaning("apple", lang="zh"))
The uppercase names IPA(), IPS(), ISM() and IPSM() remain available; the lowercase names are aliases with identical behavior.
Use lang="en" for English meanings. Unavailable pronunciations return []; unavailable meanings and ISM return None.
lookup(word) returns nine fixed keys: word, ipa, ips, ism, ipsm, root_lemma, rank, meaning and labels. Pronunciation fields are single strings or None; meaning always has en and zh. Unknown words keep the input word; other scalars and both meanings are None, with labels=[].
result = lingose.lookup("Apple")
print(result["word"]) # Apple
print(result["ipa"]) # æpəl
print(result["meaning"]["en"])
Annotate text
print(lingose.annotate_ips("Abandon the book."))
# Åbando̊n ṫhe̊ book.
print(lingose.annotate_ips("Abandon the book.", skip_top=1000))
# Åbando̊n the book.
Text keeps its capitalization, spacing and punctuation. Increase skip_top to leave more common words and their inflections unchanged; the default is 0. Words that cannot be converted appear in brackets, such as [unknownword].
Vocabulary lists
print(lingose.kind("apple", "CET4")) # True
print(lingose.kind_list("CET4")[:10]) # First ten words in the list
print(lingose.labels()) # All available categories
Categories include CET4, CET6, IELTS, TOEFL and Oxford vocabulary lists.
License and credits
CC BY 4.0. Original Lingose data and notation by ZHAN Xianjue, lingose.com.
Data sources and third-party credits are documented in SOURCES.md.
Metadata
Release files for lingose 0.4.0
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 |
|---|---|---|---|---|
| lingose-0.4.0.tar.gz | 6.7 MB | Without provenance | Details for lingose-0.4.0.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| lingose-0.4.0-py3-none-any.whl | Python 3 | none | any | Details for lingose-0.4.0-py3-none-any.whl |
Total release size: 13.5 MB
Release files / lingose-0.4.0.tar.gz
| Download URL | lingose-0.4.0.tar.gz |
|---|---|
| Size | 6.7 MB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
1340a4adb18bf7e5a3b801350a88469ea848ed08c1f63f7fb2d967f3769e150f
|
|
BLAKE2b-256 checksum How to use checksums |
9e4abce016f9018a348d6191e5c630de56ee898dd141082b634c6894cdbd5e05
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/7.0.0 CPython/3.12.4
|
Release files / lingose-0.4.0-py3-none-any.whl
| Download URL | lingose-0.4.0-py3-none-any.whl |
|---|---|
| Size | 6.7 MB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
b3c44a8a46c96ff1423bc09367291be4170bca3b2969ddc21e4dd7b0046cde9a
|
|
BLAKE2b-256 checksum How to use checksums |
dbe1ec4280c395a5ffab13426777acc77ab54b29f59d44b4705e24fb129108f6
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/7.0.0 CPython/3.12.4
|
Security for lingose 0.4.0
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.