{"id":14959580,"url":"https://github.com/gagan3012/streamlit-tags","last_synced_at":"2025-04-13T00:43:54.109Z","repository":{"id":40594724,"uuid":"346667458","full_name":"gagan3012/streamlit-tags","owner":"gagan3012","description":"Custom Tag component for streamlit","archived":false,"fork":false,"pushed_at":"2022-09-02T23:07:20.000Z","size":968,"stargazers_count":322,"open_issues_count":24,"forks_count":23,"subscribers_count":3,"default_branch":"master","last_synced_at":"2025-04-13T00:43:51.744Z","etag":null,"topics":["machine-learning","st-tags","streamlit","streamlit-tags"],"latest_commit_sha":null,"homepage":"https://streamlit-tags.readthedocs.io/en/latest/","language":"TypeScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/gagan3012.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":"CONTRIBUTING.md","funding":".github/FUNDING.yml","license":"LICENSE.txt","code_of_conduct":"CODE_OF_CONDUCT.md","threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null},"funding":{"github":"gagan3012","patreon":null,"open_collective":null,"ko_fi":null,"tidelift":null,"community_bridge":null,"liberapay":null,"issuehunt":null,"otechie":null,"custom":null}},"created_at":"2021-03-11T10:43:03.000Z","updated_at":"2025-04-06T15:46:08.000Z","dependencies_parsed_at":"2022-07-16T10:16:37.733Z","dependency_job_id":null,"html_url":"https://github.com/gagan3012/streamlit-tags","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/gagan3012%2Fstreamlit-tags","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/gagan3012%2Fstreamlit-tags/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/gagan3012%2Fstreamlit-tags/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/gagan3012%2Fstreamlit-tags/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/gagan3012","download_url":"https://codeload.github.com/gagan3012/streamlit-tags/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248650419,"owners_count":21139672,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["machine-learning","st-tags","streamlit","streamlit-tags"],"created_at":"2024-09-24T13:20:03.859Z","updated_at":"2025-04-13T00:43:54.079Z","avatar_url":"https://github.com/gagan3012.png","language":"TypeScript","funding_links":["https://github.com/sponsors/gagan3012"],"categories":[],"sub_categories":[],"readme":"# Streamlit-tags\n[![pypi Version](https://img.shields.io/pypi/v/streamlit-tags.svg?style=flat-square\u0026logo=pypi\u0026logoColor=white)](https://pypi.org/project/streamlit-tags/)\n[![conda Version](https://img.shields.io/conda/vn/conda-forge/streamlit_tags.svg?style=flat-square\u0026logo=conda-forge\u0026logoColor=white)](https://anaconda.org/conda-forge/streamlit_tags)\n[![Downloads](https://static.pepy.tech/personalized-badge/streamlit-tags?period=total\u0026units=none\u0026left_color=grey\u0026right_color=orange\u0026left_text=Pip%20Downloads)](https://pepy.tech/project/streamlit-tags)\n[![Conda downloads](https://img.shields.io/conda/dn/conda-forge/streamlit_tags?label=conda%20downloads)](https://anaconda.org/gagan3012/streamlit-tags)\n[![Streamlit App](https://static.streamlit.io/badges/streamlit_badge_black_white.svg)](https://share.streamlit.io/gagan3012/streamlit-tags/examples/app.py)\n[![Documentation Status](https://readthedocs.org/projects/streamlit-tags/badge/?version=latest)](https://streamlit-tags.readthedocs.io/en/latest/)\n\n\n![streamlit-tags](https://socialify.git.ci/gagan3012/streamlit-tags/image?descriptionEditable=Tags%20in%20Streamlit\u0026language=1\u0026logo=https%3A%2F%2Fpbs.twimg.com%2Fprofile_images%2F1366779897423810562%2Fkn7ucNPv.png\u0026owner=1\u0026stargazers=1\u0026theme=Light)\n\nA custom component to add Tags in Streamlit.\n\n[![gif](https://user-images.githubusercontent.com/49101362/114277814-83cb1200-9a35-11eb-8761-9d8bb81ffadc.gif)](https://share.streamlit.io/gagan3012/streamlit-tags/examples/app.py)\n\n# Please Upgrade to 1.2.7 version\n\n### 📢 Favour:\nIt would be highly motivating, if you can STAR⭐ this repo if you find it helpful.\n\n\nTry out a demo here: [![Streamlit App](https://static.streamlit.io/badges/streamlit_badge_black_white.svg)](https://share.streamlit.io/gagan3012/streamlit-tags/examples/app.py)\n\nCheck out docs here: https://streamlit-tags.readthedocs.io/en/latest/\n## Install\n### PyPi\n```\npip install streamlit-tags\n```\nThe installation can also be found on [**PyPi**](https://pypi.org/project/streamlit-tags/) \n### Anaconda\n```\nconda install -c conda-forge streamlit_tags\n```\nThe installation can also be found on [**Anaconda**](https://anaconda.org/conda-forge/streamlit_tags) \n## Usage\nThis library has two main functions to display and use tags:\n- `st_tags` to display the tags feature\n- `st_tags_sidebar` to display the tags in the sidebar\nCheck the [`examples/`](https://github.com/gagan3012/streamlit-tags/tree/master/examples) folder of the project a quick start.\nCheck out demo here: https://share.streamlit.io/gagan3012/streamlit-tags/examples/app.py\n## Definition\n```python\ndef st_tags(value: list,\n            suggestions: list,\n            label: str,\n            text: str,\n            maxtags: int,\n            key=None) -\u003e list:\n    '''\n    :param maxtags: Maximum number of tags allowed maxtags = -1 for unlimited entries\n    :param suggestions: (List) List of possible suggestions (optional)\n    :param label: (Str) Label of the Function\n    :param text: (Str) Instructions for entry\n    :param value: (List) Initial Value (optional)\n    :param key: (Str)\n        An optional string to use as the unique key for the widget.\n        Assign a key so the component is not remount every time the script is rerun.\n    :return: (List) Tags\n        \n    Note: usage also supports keywords = st_tags()\n    '''\n```\nNote: the suggestion and value fields are optional\n#### Note:\n- The suggestion and value fields are optional\n- Usage also supports `keywords = st_tags()`\n- Upgrade to 1.1.9 for being able to control number of tags \n\n### We also have a function now to embed the tags function to the sidebar:\n\n```python \ndef st_tags_sidebar(value: list,\n                    suggestions: list,\n                    label: str,\n                    text: str,\n                    maxtags: int,\n                    key=None) -\u003e list:\n    '''\n    :param maxtags: Maximum number of tags allowed maxtags = -1 for unlimited entries\n    :param suggestions: (List) List of possible suggestions (optional)\n    :param label: (Str) Label of the Function\n    :param text: (Str) Instructions for entry\n    :param value: (List) Initial Value (optional)\n    :param key: (Str)\n        An optional string to use as the unique key for the widget.\n        Assign a key so the component is not remount every time the script is rerun.\n    :return: Tags\n    '''\n```\n#### Note:\n- The suggestion and value fields are optional\n- Usage also supports `keywords = st_tags_sidebar()`\n- Upgrade to 1.1.9 for being able to control number of tags \n\n## Example Usage\n```python \nkeywords = st_tags(\n    label='# Enter Keywords:',\n    text='Press enter to add more',\n    value=['Zero', 'One', 'Two'],\n    suggestions=['five', 'six', 'seven', \n                 'eight', 'nine', 'three', \n                 'eleven', 'ten', 'four'],\n    maxtags = 4,\n    key='1')\n                   \nkeyword = st_tags_sidebar(\n    label='# Enter Keywords:',\n    text='Press enter to add more',\n    value=['Zero', 'One', 'Two'],\n    suggestions=['five', 'six', 'seven', \n                 'eight', 'nine', 'three', \n                 'eleven', 'ten', 'four'],\n    maxtags = 4,\n    key='2')\n```\n## Sample Images of the UI:\n[![UI](https://user-images.githubusercontent.com/49101362/113942909-59494100-980a-11eb-8f4c-662f5c18d967.png)](https://share.streamlit.io/gagan3012/streamlit-tags/examples/app.py)\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fgagan3012%2Fstreamlit-tags","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fgagan3012%2Fstreamlit-tags","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fgagan3012%2Fstreamlit-tags/lists"}