{ "info": { "author": "Lokendra Singh, Arghya Bhatttacharya, Sushain K. Cherivirala, Andi Qu", "author_email": "sushain@skc.name", "bugtrack_url": null, "classifiers": [ "Development Status :: 3 - Alpha", "Intended Audience :: Developers", "Intended Audience :: Science/Research", "License :: OSI Approved :: GNU General Public License v3 or later (GPLv3+)", "Operating System :: Microsoft :: Windows", "Operating System :: POSIX", "Programming Language :: Python :: 3.5", "Programming Language :: Python :: 3.6", "Programming Language :: Python :: 3.7", "Programming Language :: Python :: 3 :: Only", "Topic :: Text Processing :: Linguistic" ], "description": "# Apertium + Python\n\n[![Travis Build Status](https://travis-ci.com/apertium/apertium-python.svg?branch=master)](https://travis-ci.com/apertium/apertium-python)\n[![Appveyor Build status](https://ci.appveyor.com/api/projects/status/sesdinoy4cw2p1tk/branch/master?svg=true)](https://ci.appveyor.com/project/apertium/apertium-python/branch/master)\n[![ReadTheDocs Docs Status](https://readthedocs.org/projects/apertium-python/badge)](https://readthedocs.org/projects/apertium-python)\n[![Coverage Status](https://coveralls.io/repos/github/apertium/apertium-python/badge.svg?branch=master)](https://coveralls.io/github/apertium/apertium-python?branch=master)\n[![PyPI - Python Version](https://img.shields.io/pypi/pyversions/apertium.svg)]((https://pypi.org/project/apertium/))\n\n## Introduction\n\n- The codebase is in development for the GSoC '19 project called **Apertium API in Python**\n- The Apertium core modules are written in C++.\n- This project makes the Apertium modules available in Python, which because of its simplicity is more appealing to users.\n\n## About the Exisiting Code Base\n\n- The existing codebase has `Subprocess` and [SWIG](http://www.swig.org/) wrapper implementations of the higher level functions of Apertium and CG modules.\n\n## Installation\n\n- Installation on Ubuntu and Windows is natively supported:\n\n ```\n pip install apertium\n ```\n\n- For developers, `pipenv` can be used to install the development dependencies and enter a shell with them:\n\n ```\n pip install pipenv\n pipenv install --dev\n pipenv shell\n ```\n\n- Apertium packages can be installed from Python interpreter as well.\n - Install `apertium-all-dev` by calling `apertium.installer.install_apertium()`\n - Install language packages with `apertium.installer.install_module(language_name)`. For example `apertium-eng` can be installed by executing `apertium.installer.install_module('eng')`\n\n## Usage\n\n- For multiple invocations `Method 1` is more performant, as the dictionary needs to be loaded only once.\n\n### Analysis\n\nPerforming Morphological Analysis\n\nMethod 1: Create an `Analyzer` object and call its `analyze` method.\n```python\nIn [1]: import apertium\nIn [2]: a = apertium.Analyzer('en')\nIn [3]: a.analyze('cats')\nOut[3]: [cats/cat, ./.]\n```\n\nMethod 2: Calling `analyze()` directly.\n```python\nIn [1]: import apertium\nIn [2]: apertium.analyze('en', 'cats')\nOut[2]: cats/cat\n```\n\n### Generation\n\nPerforming Morphological Generation\n\nMethod 1: Create a `Generator` object and call its `generate` method.\n```python\nIn [1]: import apertium\nIn [2]: g = apertium.Generator('en')\nIn [3]: g.generate('^cat$')\nOut[3]: 'cats'\n```\n\nMethod 2: Calling `generate()` directly.\n```python\nIn [1]: import apertium\nIn [2]: apertium.generate('en', '^cat$')\nOut[2]: 'cats'\n```\n\n### Tagger\n\nMethod 1: Create a `Tagger` object and call its `tag` method.\n```python\nIn [1]: import apertium\nIn [2]: tagger = apertium.Tagger('eng')\nIn [3]: tagger.tag('cats')\nOut[3]: [cats/cat]\n```\n\nMethod 2: Calling `tag()` directly.\n```python\nIn [1]: import apertium\nIn [2]: apertium.tag('en', 'cats')\nOut[2]: [cats/cat]\n```\n\n### Translation\n\nMethod 1: Create a `Translator` object and call its `translate` method.\n```python\nIn [1]: import apertium\nIn [2]: t = apertium.Translator('eng', 'spa')\nIn [3]: t.translate('cats')\nOut[3]: 'Gatos'\n```\n\nMethod 2: Calling `translate()` directly.\n```python\nIn [1]: import apertium\nIn [2]: apertium.translate('en', 'spa', 'cats')\nOut[2]: 'Gatos'\n```\n\n### Installing more modes from other language data\n\nOne can also install modes by providing the path to the `lang-data`:\n\n```python\nIn [1]: import apertium\nIn [2]: apertium.append_pair_path('..')\n```", "description_content_type": "text/markdown; charset=UTF-8", "docs_url": null, "download_url": "", "downloads": { "last_day": -1, "last_month": -1, "last_week": -1 }, "home_page": "https://github.com/apertium/apertium-python", "keywords": "apertium machine translation linguistics", "license": "GNU General Public License v3.0", "maintainer": "", "maintainer_email": "", "name": "apertium", "package_url": "https://pypi.org/project/apertium/", "platform": "Ubuntu", "project_url": "https://pypi.org/project/apertium/", "project_urls": { "Homepage": "https://github.com/apertium/apertium-python" }, "release_url": "https://pypi.org/project/apertium/0.2.2/", "requires_dist": null, "requires_python": ">=3.5", "summary": "Apertium core modules available in Python", "version": "0.2.2" }, "last_serial": 5828397, "releases": { "0.1.0": [ { "comment_text": "", "digests": { "md5": "1f73c80d0bda493d602dfeb3a2bcaf96", "sha256": "77437b2731ba4857ecd638b497a60ebe8456b88252d1eab282bff66539ab57a7" }, "downloads": -1, "filename": "apertium-0.1.0-py3-none-any.whl", "has_sig": true, "md5_digest": "1f73c80d0bda493d602dfeb3a2bcaf96", "packagetype": "bdist_wheel", "python_version": "py3", "requires_python": ">=3.5", "size": 26896, "upload_time": "2019-09-01T17:58:40", "url": "https://files.pythonhosted.org/packages/34/2c/a75cda570a9b372eb46702c79a8ee0041bfe797f4fa6e2a26b285cc9d385/apertium-0.1.0-py3-none-any.whl" }, { "comment_text": "", "digests": { "md5": "ada4768dbb111792ed657d8d38133b65", "sha256": "c96daf87b966b59b13d7b58d231041675fbbeb34b0617833657296a24447151e" }, "downloads": -1, "filename": "apertium-0.1.0.tar.gz", "has_sig": true, "md5_digest": "ada4768dbb111792ed657d8d38133b65", "packagetype": "sdist", "python_version": "source", "requires_python": ">=3.5", "size": 13311, "upload_time": "2019-09-01T17:58:42", "url": "https://files.pythonhosted.org/packages/81/da/457b276c15ddd54919ab8879d5b6451274049a6d0f0cfbe4d489b480008e/apertium-0.1.0.tar.gz" } ], "0.2.0": [ { "comment_text": "", "digests": { "md5": "818f3252fcb6f3b9bbc8dba8239ba009", "sha256": "26ca52c12096f0a11b898849f39e058ae59f2165e58909495d9ef077691cba27" }, "downloads": -1, "filename": "apertium-0.2.0-py3-none-any.whl", "has_sig": true, "md5_digest": "818f3252fcb6f3b9bbc8dba8239ba009", "packagetype": "bdist_wheel", "python_version": "py3", "requires_python": ">=3.5", "size": 27010, "upload_time": "2019-09-06T03:52:49", "url": "https://files.pythonhosted.org/packages/4d/bf/989a1a0d975bf2838bc2a1554afc068c0a66b394e7bae4398ed73ccf1bf8/apertium-0.2.0-py3-none-any.whl" }, { "comment_text": "", "digests": { "md5": "b869d8d7eb67ce23eea9de71467f9045", "sha256": "e3ae26d738765f17d828941fc5dc70791940a0c12d78dffd774632e58a79a4b3" }, "downloads": -1, "filename": "apertium-0.2.0.tar.gz", "has_sig": true, "md5_digest": "b869d8d7eb67ce23eea9de71467f9045", "packagetype": "sdist", "python_version": "source", "requires_python": ">=3.5", "size": 13446, "upload_time": "2019-09-06T03:52:53", "url": "https://files.pythonhosted.org/packages/0b/84/f34950cead942c85976cd8d31806b89db4124557c76d2dd4fefbbadb1688/apertium-0.2.0.tar.gz" } ], "0.2.1": [ { "comment_text": "", "digests": { "md5": "d3dbc9ce6d3a62f42d2255f782d50df3", "sha256": "f8d5a7d8237a8da4c5058462a0997f2c6987e7ceb48979f2231d859dee6f6706" }, "downloads": -1, "filename": "apertium-0.2.1-py3-none-any.whl", "has_sig": true, "md5_digest": "d3dbc9ce6d3a62f42d2255f782d50df3", "packagetype": "bdist_wheel", "python_version": "py3", "requires_python": ">=3.5", "size": 27010, "upload_time": "2019-09-12T04:02:56", "url": "https://files.pythonhosted.org/packages/2e/6d/7ca375afce1b34487f465b7a528fcfcb147f03b867ae1b1d80bf882147cf/apertium-0.2.1-py3-none-any.whl" }, { "comment_text": "", "digests": { "md5": "e02a3102e872ad7f3d0fec097fbeede0", "sha256": "1e71f01565ae4db6b6400ebdafcda9352e571708097d9f6ffe679018641358a6" }, "downloads": -1, "filename": "apertium-0.2.1.tar.gz", "has_sig": true, "md5_digest": "e02a3102e872ad7f3d0fec097fbeede0", "packagetype": "sdist", "python_version": "source", "requires_python": ">=3.5", "size": 13654, "upload_time": "2019-09-12T04:02:58", "url": "https://files.pythonhosted.org/packages/4a/5c/f96dbe711fd85d8e7c10fd804dc993ca7486c9ea984e169856ace7ac22a6/apertium-0.2.1.tar.gz" } ], "0.2.2": [ { "comment_text": "", "digests": { "md5": "c665376641da21502ef6195b74222e44", "sha256": "00e6cf29f5321498ae77c54eb00024ccf75fe2723ea0333b719ba1613903502c" }, "downloads": -1, "filename": "apertium-0.2.2.tar.gz", "has_sig": true, "md5_digest": "c665376641da21502ef6195b74222e44", "packagetype": "sdist", "python_version": "source", "requires_python": ">=3.5", "size": 13622, "upload_time": "2019-09-14T02:37:35", "url": "https://files.pythonhosted.org/packages/d5/5f/b75ed2e8548bb402676e83cdfc90161aceb39a58dd497dbce751814d4476/apertium-0.2.2.tar.gz" } ] }, "urls": [ { "comment_text": "", "digests": { "md5": "c665376641da21502ef6195b74222e44", "sha256": "00e6cf29f5321498ae77c54eb00024ccf75fe2723ea0333b719ba1613903502c" }, "downloads": -1, "filename": "apertium-0.2.2.tar.gz", "has_sig": true, "md5_digest": "c665376641da21502ef6195b74222e44", "packagetype": "sdist", "python_version": "source", "requires_python": ">=3.5", "size": 13622, "upload_time": "2019-09-14T02:37:35", "url": "https://files.pythonhosted.org/packages/d5/5f/b75ed2e8548bb402676e83cdfc90161aceb39a58dd497dbce751814d4476/apertium-0.2.2.tar.gz" } ] }