{
"info": {
"author": "Ra\u00fal Escamilla",
"author_email": "raul.escamilla@asesoriait.com",
"bugtrack_url": null,
"classifiers": [],
"description": "spacyemoticon: emoticon for spaCy\n**************************\n\nThis extension was inpired in `spacymoji `_.\n\n`spaCy v2.0 `_ extension and pipeline component\nfor adding text emoticon meta data to ``Doc`` objects. Detects text emoticons\nconsisting in one or more characters or symbols into one token. The extension \nsets the custom ``Doc``, ``Token`` and ``Span`` attributes ``._.is_emoticon``,\nand ``._.emoticon``. You can read more about custom pipeline\ncomponents and extension attributes\n`here `_.\n\nEmoticon are matched using spaCy's ``PhraseMatcher``, and looked up in the data\ntable provided by the `\"emoticons.py\"`_.\n\n\n\u23f3 Installation\n===============\n\n``spacyemoticon`` requires ``spacy`` v2.0.0 or higher.\n\n.. code:: bash\n\n pip install spacyemoticon\n\n\u261d\ufe0f Usage\n========\n\nImport the component and initialise it with the shared ``nlp`` object (i.e. an\ninstance of ``Language``), which is used to initialise the ``PhraseMatcher``\nwith the shared vocab, and create the match patterns. Then add the component\nanywhere in your pipeline.\n\n.. code:: python\n\n import spacy\n from spacyemoticon import Emoticon\n\n nlp = spacy.load('en')\n emoticon = Emoticon(nlp)\n nlp.add_pipe(emoticon, first=True)\n\n doc = nlp(u\"This is a test :) <\\3\")\n assert doc[0]._.is_emoticon == False\n assert doc[4]._.is_emoticon == True\n assert len(doc._.emoticon) == 2\n\n``spacyemoticon`` only cares about the token text, so you can use it on a blank\n``Language`` instance (it should work for all\n`available languages `_!), or in\na pipeline with a loaded model. If you're loading a model and your pipeline\nincludes a tagger, parser and entity recognizer, make sure to add the emoticon\ncomponent as ``first=True``, so the spans are merged right after tokenization,\nand *before* the document is parsed. If your text contains a lot of emoticon, this\nmight even give you a nice boost in parser accuracy.\n\nAvailable attributes\n--------------------\n\nThe extension sets attributes on the ``Doc``, ``Span`` and ``Token``. You can\nchange the attribute names on initialisation of the extension. For more details\non custom components and attributes, see the\n`processing pipelines documentation `_.\n\n====================== ======= ===\n``Token._.is_emoticon`` bool Whether the token is an emoticon.\n``Doc._.emoticon`` list ``(emoticon, index, description)`` tuples of the document's emoticon.\n``Span._.emoticon`` list ``(emoticon, index, description)`` tuples of the span's emoticon.\n====================== ======= ===\n\nSettings\n--------\n\nOn initialisation of ``Emoticon``, you can define the following settings:\n\n=============== ============ ===\n``nlp`` ``Language`` The shared ``nlp`` object. Used to initialise the matcher with the shared ``Vocab``, and create ``Doc`` match patterns.\n``attrs`` tuple Attributes to set on the ._ property. Defaults to ``('is_emoticon', 'emoticon')``.\n``pattern_id`` unicode ID of match pattern, defaults to ``'EMOTICON'``. Can be changed to avoid ID conflicts.\n``merge_spans`` bool Merge spans containing multi-character emoticon, defaults to ``True``. Will only merge combined emoticon resulting in one icon, not sequences.\n``lookup`` dict Optional lookup table that maps emoticon text strings to custom descriptions, e.g. translations or other annotations.\n=============== ============ ===\n\n.. code:: python\n\n emoticon = Emoticon(nlp, attrs=('has_e', 'e'), lookup={u':S'})\n nlp.add_pipe(emoticon)\n doc = nlp(u\"We can be :S heroes\")\n assert doc[3]._.is_e\n\n\n",
"description_content_type": "",
"docs_url": null,
"download_url": "",
"downloads": {
"last_day": -1,
"last_month": -1,
"last_week": -1
},
"home_page": "https://spacy.io",
"keywords": "",
"license": "MIT",
"maintainer": "",
"maintainer_email": "",
"name": "spacyemoticon",
"package_url": "https://pypi.org/project/spacyemoticon/",
"platform": "",
"project_url": "https://pypi.org/project/spacyemoticon/",
"project_urls": {
"Homepage": "https://spacy.io"
},
"release_url": "https://pypi.org/project/spacyemoticon/1.0.2/",
"requires_dist": [
"spacy (<3.0.0,>=2.0.0)"
],
"requires_python": "",
"summary": "spaCy pipeline component for adding emoticon meta data to Doc, Token and Span objects that are text emoticons.",
"version": "1.0.2"
},
"last_serial": 3893801,
"releases": {
"1.0.0": [
{
"comment_text": "",
"digests": {
"md5": "98f7d7b42974f6c5121855eae0440db7",
"sha256": "42dfdc0c46e3ba0b2589830968d62f4478a5ffa7ff9dd605a8985f25d86655bc"
},
"downloads": -1,
"filename": "spacyemoticon-1.0.0-py2.py3-none-any.whl",
"has_sig": false,
"md5_digest": "98f7d7b42974f6c5121855eae0440db7",
"packagetype": "bdist_wheel",
"python_version": "py2.py3",
"requires_python": null,
"size": 3666,
"upload_time": "2018-05-24T04:07:28",
"url": "https://files.pythonhosted.org/packages/b8/9a/3c6cd741db55d261c3644e467129f3268b8cc7cd66eadfe95d98e1db5aac/spacyemoticon-1.0.0-py2.py3-none-any.whl"
},
{
"comment_text": "",
"digests": {
"md5": "1374c6e0495a3acc4864192a2b8f283f",
"sha256": "58dba96bd5483945f32d17950510a3061b3f932bd94fac4d9f1c41cd5c57fdfc"
},
"downloads": -1,
"filename": "spacyemoticon-1.0.0-py3-none-any.whl",
"has_sig": false,
"md5_digest": "1374c6e0495a3acc4864192a2b8f283f",
"packagetype": "bdist_wheel",
"python_version": "py3",
"requires_python": null,
"size": 3662,
"upload_time": "2018-05-24T04:07:29",
"url": "https://files.pythonhosted.org/packages/e3/cc/492541b898c7eb9b09e6382ad4b4b01c6132de05bc143fc8d91e1fdb09c0/spacyemoticon-1.0.0-py3-none-any.whl"
},
{
"comment_text": "",
"digests": {
"md5": "d69232036aed0faf607a4ce5ec5ed8ab",
"sha256": "cf68f7b63917fb5b344b5fe4c2c9154ddbc9c0a2ab02cae3977bb52eca7ec7f2"
},
"downloads": -1,
"filename": "spacyemoticon-1.0.0.tar.gz",
"has_sig": false,
"md5_digest": "d69232036aed0faf607a4ce5ec5ed8ab",
"packagetype": "sdist",
"python_version": "source",
"requires_python": null,
"size": 3104,
"upload_time": "2018-05-24T04:07:30",
"url": "https://files.pythonhosted.org/packages/e1/f9/a76b10565af120cb4e208460ebc99cd43e7d6b2c3374ba962c2c125c6dce/spacyemoticon-1.0.0.tar.gz"
}
],
"1.0.2": [
{
"comment_text": "",
"digests": {
"md5": "b8b8b3c2e0344ff45d0394f5c35a42e0",
"sha256": "63845cfae72ca8055990097717f0015aa58335ea2c440e3c837592a97314d952"
},
"downloads": -1,
"filename": "spacyemoticon-1.0.2-py2.py3-none-any.whl",
"has_sig": false,
"md5_digest": "b8b8b3c2e0344ff45d0394f5c35a42e0",
"packagetype": "bdist_wheel",
"python_version": "py2.py3",
"requires_python": null,
"size": 5091,
"upload_time": "2018-05-24T05:14:38",
"url": "https://files.pythonhosted.org/packages/09/95/d885234eb9a23cb25e37e9e8abf3d9cd0eed11340d13aace4d29dd39d0e4/spacyemoticon-1.0.2-py2.py3-none-any.whl"
},
{
"comment_text": "",
"digests": {
"md5": "50282b267f8211215d94fce9cebb18e8",
"sha256": "ba9d4c9ae87299d356d1379b7293a08cf1cb628dcbe21db70b0caa13467af88c"
},
"downloads": -1,
"filename": "spacyemoticon-1.0.2-py3-none-any.whl",
"has_sig": false,
"md5_digest": "50282b267f8211215d94fce9cebb18e8",
"packagetype": "bdist_wheel",
"python_version": "py3",
"requires_python": null,
"size": 5083,
"upload_time": "2018-05-24T05:14:40",
"url": "https://files.pythonhosted.org/packages/1e/7d/8b2051633a2357d2d4981398a000e4a3c88ac5ceaa845f01ded0b76181ea/spacyemoticon-1.0.2-py3-none-any.whl"
}
]
},
"urls": [
{
"comment_text": "",
"digests": {
"md5": "b8b8b3c2e0344ff45d0394f5c35a42e0",
"sha256": "63845cfae72ca8055990097717f0015aa58335ea2c440e3c837592a97314d952"
},
"downloads": -1,
"filename": "spacyemoticon-1.0.2-py2.py3-none-any.whl",
"has_sig": false,
"md5_digest": "b8b8b3c2e0344ff45d0394f5c35a42e0",
"packagetype": "bdist_wheel",
"python_version": "py2.py3",
"requires_python": null,
"size": 5091,
"upload_time": "2018-05-24T05:14:38",
"url": "https://files.pythonhosted.org/packages/09/95/d885234eb9a23cb25e37e9e8abf3d9cd0eed11340d13aace4d29dd39d0e4/spacyemoticon-1.0.2-py2.py3-none-any.whl"
},
{
"comment_text": "",
"digests": {
"md5": "50282b267f8211215d94fce9cebb18e8",
"sha256": "ba9d4c9ae87299d356d1379b7293a08cf1cb628dcbe21db70b0caa13467af88c"
},
"downloads": -1,
"filename": "spacyemoticon-1.0.2-py3-none-any.whl",
"has_sig": false,
"md5_digest": "50282b267f8211215d94fce9cebb18e8",
"packagetype": "bdist_wheel",
"python_version": "py3",
"requires_python": null,
"size": 5083,
"upload_time": "2018-05-24T05:14:40",
"url": "https://files.pythonhosted.org/packages/1e/7d/8b2051633a2357d2d4981398a000e4a3c88ac5ceaa845f01ded0b76181ea/spacyemoticon-1.0.2-py3-none-any.whl"
}
]
}