A rule-based morphological analyzer for the Uzbek language based on CSE (Complete Set of Endings) and annotated morphological tags
Project description
uzmorph - Uzbek Rule-based Morphological Analyzer using CSE (Complete Set of Endings)
uzmorph is a professional morphological analyzer for the Uzbek language based on CSE (Complete Set of Endings) rules and comprehensive morphological tagging. It provides deep linguistic analysis by identifying stems, lemmas, and a wide array of annotated morphological features.
Key Features
- CSE-Based Analysis: Employs advanced suffix stripping rules (Complete Set of Endings) for precise morphological segmentation.
- Rich Morphological Tagging: Extracts detailed features including part-of-speech (POS), tense, person, possession, case, and voice.
- Flat JSON Output: Returns analysis results in a developer-friendly, flattened JSON-compatible format.
Installation
pip install uzmorph
Quick Start
from uzmorph import UzMorph
# Initialize the analyzer
analyzer = UzMorph()
# Analyze a word
results = analyzer.analyze("maktabimda")
# Formatted console print
analyzer.print_result(results)
JSON Result Sample
Each analysis result is a dictionary containing the following structure:
[
{
"word": "maktabimda",
"stem": "maktab",
"lemma": "maktab",
"cse": "imda",
"cse_formula": "(i)mda",
"pos": "NOUN",
"possession": "1",
"cases": "Locative",
"singular": "1",
"syntactical_affixes": "(i)m da",
"note": null,
"ball": 108
}
]
API Reference
UzMorph Class
analyze(word, pos_filter=None): Performs morphological analysis and returns a list of results.print_result(results): Prints formatted output to the console.get_pos_list(): Returns a formatted string of all available POS tags.get_features_list(): Returns a list of all possible property keys in the result.
License
MIT
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
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file uzmorph-1.1.2.tar.gz.
File metadata
- Download URL: uzmorph-1.1.2.tar.gz
- Upload date:
- Size: 32.6 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.12.0
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
af1933c6f219b61d03965169331f0f2a36555de2537e477e0caa2f3b22e35d8e
|
|
| MD5 |
c6f0829e7e6bc806bd2f1a248cc18534
|
|
| BLAKE2b-256 |
600893394647faf67895221e435df4a80976c6cdf839d8945b404e45cb5912e2
|
File details
Details for the file uzmorph-1.1.2-py3-none-any.whl.
File metadata
- Download URL: uzmorph-1.1.2-py3-none-any.whl
- Upload date:
- Size: 32.5 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.12.0
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
cc4e6396d8e709ec9a31ccb434e02d1202d207a3c8d1a15e5a6aeacba7c4fe5b
|
|
| MD5 |
33e09fd94e5ace83a762d27a588e522d
|
|
| BLAKE2b-256 |
9853f3d3c2f3d066289ff3a0bee18d51ee40b37a1daa18fb8c26b1f85274ef11
|