# PyOmorfi
This is a pure-python implementation of Omorfi, a free and open source morphological analyzer for Finnish.
Most of the files have been copied from the [Omorfi repository](https://github.com/flammie/omorfi).
HFST has been replaced with KFST, a pure-python implementation of finite state transducers.
This package includes a pre-built transducer, so you don't need to build the transducer yourself.
For most part, this library should be a drop-in replacement for Omorfi.
## Installation
Pyomorfi is available on PyPI and can be installed with pip:
```sh
pip install pyomorfi
```
## Usage
PyOmorfi has the same API as Omorfi, so you can use it in the same way as Omorfi.
Please refer to the [Omorfi documentation](https://flammie.github.io/omorfi/) for more information.
Just import `pyomorfi.omorfi` instead of `omorfi`.
```py
from pyomorfi.omorfi import Omorfi
omorfi = Omorfi()
omorfi.load_analyser("omorfi.analyse.kfst")
analyses = omorfi.analyse("kissa")
```
There is also a function that loads the built-in transducers and returns an `Omorfi` object:
```py
from pyomorfi import load_omorfi
omorfi = load_omorfi()
analyses = omorfi.analyse("kissa")
```
## Development
This package is in very early stages of its development and there are probably many bugs.
Please report them if you find them!
If you want to contribute code, feel free to open pull requests.
## License
PyOmorfi is licensed under the GNU GPL version 3. See the LICENSE file for details.
Raw data
{
"_id": null,
"home_page": "https://github.com/fergusq/fst-python",
"name": "pyomorfi",
"maintainer": "",
"docs_url": null,
"requires_python": ">=3.8",
"maintainer_email": "",
"keywords": "finnish nlp morphology",
"author": "Iikka Hauhio",
"author_email": "iikka.hauhio@helsinki.fi",
"download_url": "https://files.pythonhosted.org/packages/57/8b/edac9d24de850ac6bb16d69feb963994fbd3c56117d5601b5c54b6f21923/pyomorfi-1.0.1.tar.gz",
"platform": null,
"description": "# PyOmorfi\n\nThis is a pure-python implementation of Omorfi, a free and open source morphological analyzer for Finnish.\n\nMost of the files have been copied from the [Omorfi repository](https://github.com/flammie/omorfi).\nHFST has been replaced with KFST, a pure-python implementation of finite state transducers.\n\nThis package includes a pre-built transducer, so you don't need to build the transducer yourself.\nFor most part, this library should be a drop-in replacement for Omorfi.\n\n## Installation\n\nPyomorfi is available on PyPI and can be installed with pip:\n\n```sh\npip install pyomorfi\n```\n\n## Usage\n\nPyOmorfi has the same API as Omorfi, so you can use it in the same way as Omorfi.\nPlease refer to the [Omorfi documentation](https://flammie.github.io/omorfi/) for more information.\nJust import `pyomorfi.omorfi` instead of `omorfi`.\n\n```py\nfrom pyomorfi.omorfi import Omorfi\n\nomorfi = Omorfi()\nomorfi.load_analyser(\"omorfi.analyse.kfst\")\n\nanalyses = omorfi.analyse(\"kissa\")\n```\n\nThere is also a function that loads the built-in transducers and returns an `Omorfi` object:\n\n```py\nfrom pyomorfi import load_omorfi\n\nomorfi = load_omorfi()\n\nanalyses = omorfi.analyse(\"kissa\")\n```\n\n## Development\n\nThis package is in very early stages of its development and there are probably many bugs.\nPlease report them if you find them!\n\nIf you want to contribute code, feel free to open pull requests.\n\n## License\n\nPyOmorfi is licensed under the GNU GPL version 3. See the LICENSE file for details.\n",
"bugtrack_url": null,
"license": "GNU GPLv3",
"summary": "A pure-python implementation of the Omorfi library that provides Finnish morphological analysis",
"version": "1.0.1",
"project_urls": {
"Bug Tracker": "https://github.com/fergusq/fst-python/issues",
"Homepage": "https://github.com/fergusq/fst-python"
},
"split_keywords": [
"finnish",
"nlp",
"morphology"
],
"urls": [
{
"comment_text": "",
"digests": {
"blake2b_256": "9aa66624961e0bfec931dd2991f9dd8c806b04ecde67873a932dbfbf89dd804e",
"md5": "25161ec5a8c190c63cee032940b2d08f",
"sha256": "792456b74fee6ee1fa32e7b7c4643114195595b959686e2f602a9df4abd06623"
},
"downloads": -1,
"filename": "pyomorfi-1.0.1-py3-none-any.whl",
"has_sig": false,
"md5_digest": "25161ec5a8c190c63cee032940b2d08f",
"packagetype": "bdist_wheel",
"python_version": "py3",
"requires_python": ">=3.8",
"size": 7704624,
"upload_time": "2023-07-07T10:42:13",
"upload_time_iso_8601": "2023-07-07T10:42:13.279264Z",
"url": "https://files.pythonhosted.org/packages/9a/a6/6624961e0bfec931dd2991f9dd8c806b04ecde67873a932dbfbf89dd804e/pyomorfi-1.0.1-py3-none-any.whl",
"yanked": false,
"yanked_reason": null
},
{
"comment_text": "",
"digests": {
"blake2b_256": "578bedac9d24de850ac6bb16d69feb963994fbd3c56117d5601b5c54b6f21923",
"md5": "9705ffbf5b153d97540fd7f8ecf10b11",
"sha256": "47fd5f96b1e72c762f1781189546fa3e698ceff855964a0b750304112f46cb7a"
},
"downloads": -1,
"filename": "pyomorfi-1.0.1.tar.gz",
"has_sig": false,
"md5_digest": "9705ffbf5b153d97540fd7f8ecf10b11",
"packagetype": "sdist",
"python_version": "source",
"requires_python": ">=3.8",
"size": 7675913,
"upload_time": "2023-07-07T10:42:18",
"upload_time_iso_8601": "2023-07-07T10:42:18.142355Z",
"url": "https://files.pythonhosted.org/packages/57/8b/edac9d24de850ac6bb16d69feb963994fbd3c56117d5601b5c54b6f21923/pyomorfi-1.0.1.tar.gz",
"yanked": false,
"yanked_reason": null
}
],
"upload_time": "2023-07-07 10:42:18",
"github": true,
"gitlab": false,
"bitbucket": false,
"codeberg": false,
"github_user": "fergusq",
"github_project": "fst-python",
"travis_ci": false,
"coveralls": false,
"github_actions": false,
"lcname": "pyomorfi"
}