{"id":14959566,"url":"https://github.com/gagan3012/keytotext","last_synced_at":"2025-05-16T17:07:19.572Z","repository":{"id":42042653,"uuid":"340657225","full_name":"gagan3012/keytotext","owner":"gagan3012","description":"Keywords to Sentences ","archived":false,"fork":false,"pushed_at":"2023-08-15T22:12:17.000Z","size":4235,"stargazers_count":450,"open_issues_count":19,"forks_count":57,"subscribers_count":12,"default_branch":"master","last_synced_at":"2025-04-12T17:46:52.901Z","etag":null,"topics":["api","docker","huggingface-transformers","keytotext","keywords","nlp","sentences","streamlit","t5"],"latest_commit_sha":null,"homepage":"https://share.streamlit.io/gagan3012/keytotext/UI/app.py","language":"Jupyter Notebook","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":".github/CONTRIBUTING.md","funding":".github/FUNDING.yml","license":"LICENSE","code_of_conduct":".github/CODE_OF_CONDUCT.md","threat_model":null,"audit":null,"citation":"CITATION.cff","codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":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-02-20T13:08:44.000Z","updated_at":"2025-04-10T17:29:15.000Z","dependencies_parsed_at":"2024-06-18T22:42:56.211Z","dependency_job_id":"580ddaef-347e-4724-9388-473b7c48a765","html_url":"https://github.com/gagan3012/keytotext","commit_stats":{"total_commits":1579,"total_committers":6,"mean_commits":263.1666666666667,"dds":0.005699810006333128,"last_synced_commit":"3df9e446ab57e56f7cd422d9cf76e6f7ee617f97"},"previous_names":[],"tags_count":19,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/gagan3012%2Fkeytotext","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/gagan3012%2Fkeytotext/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/gagan3012%2Fkeytotext/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/gagan3012%2Fkeytotext/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/gagan3012","download_url":"https://codeload.github.com/gagan3012/keytotext/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":253805839,"owners_count":21967054,"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":["api","docker","huggingface-transformers","keytotext","keywords","nlp","sentences","streamlit","t5"],"created_at":"2024-09-24T13:20:01.291Z","updated_at":"2025-05-16T17:07:19.521Z","avatar_url":"https://github.com/gagan3012.png","language":"Jupyter Notebook","funding_links":["https://github.com/sponsors/gagan3012"],"categories":["Jupyter Notebook"],"sub_categories":[],"readme":"\u003ch1 align=\"center\"\u003ekeytotext\u003c/h1\u003e\n\n[![pypi Version](https://img.shields.io/pypi/v/keytotext.svg?logo=pypi\u0026logoColor=white)](https://pypi.org/project/keytotext/)\n[![Downloads](https://static.pepy.tech/personalized-badge/keytotext?period=total\u0026units=none\u0026left_color=grey\u0026right_color=orange\u0026left_text=Pip%20Downloads)](https://pepy.tech/project/keytotext)\n[![Open In Colab](https://colab.research.google.com/assets/colab-badge.svg)](https://colab.research.google.com/github/gagan3012/keytotext/blob/master/notebooks/K2T.ipynb)\n[![Streamlit App](https://static.streamlit.io/badges/streamlit_badge_black_white.svg)](https://share.streamlit.io/gagan3012/keytotext/UI/app.py)\n[![API Call](https://img.shields.io/badge/-FastAPI-red?logo=fastapi\u0026labelColor=white)](https://github.com/gagan3012/keytotext#api)\n[![Docker Call](https://img.shields.io/badge/-Docker%20Image-blue?logo=docker\u0026labelColor=white)](https://hub.docker.com/r/gagan30/keytotext)\n[![HuggingFace](https://img.shields.io/badge/%F0%9F%A4%97-Models%20on%20Hub-yellow)](https://huggingface.co/models?filter=keytotext)\n[![Documentation Status](https://readthedocs.org/projects/keytotext/badge/?version=latest)](https://keytotext.readthedocs.io/en/latest/?badge=latest)\n[![Code style: black](https://img.shields.io/badge/code%20style-black-000000.svg)](https://github.com/psf/black)\n[![CodeFactor](https://www.codefactor.io/repository/github/gagan3012/keytotext/badge)](https://www.codefactor.io/repository/github/gagan3012/keytotext)\n\n![keytotext](https://socialify.git.ci/gagan3012/keytotext/image?description=1\u0026forks=1\u0026language=1\u0026owner=1\u0026stargazers=1\u0026theme=Light)\n\n\n\n\n\nIdea is to build a model which will take keywords as inputs and generate sentences as outputs.\n\nPotential use case can include: \n- Marketing \n- Search Engine Optimization\n- Topic generation etc.\n- Fine tuning of topic modeling models \n\n## Model:\n\nKeytotext is based on the Amazing T5 Model: [![HuggingFace](https://img.shields.io/badge/%F0%9F%A4%97-Models%20on%20Hub-yellow)](https://huggingface.co/models?filter=keytotext)\n\n- `k2t`: [Model](https://huggingface.co/gagan3012/k2t)\n- `k2t-base`: [Model](https://huggingface.co/gagan3012/k2t-base)\n- `mrm8488/t5-base-finetuned-common_gen` (by Manuel Romero): [Model](https://huggingface.co/mrm8488/t5-base-finetuned-common_gen)\n\nTraining Notebooks can be found in the [`Training Notebooks`](https://github.com/gagan3012/keytotext/tree/master/notebooks) Folder\n\n**Note**: To add your own model to keytotext Please read [`Models Documentation`](https://github.com/gagan3012/keytotext/blob/master/docs/MODELS.md)\n\n## Usage:\n\nExample usage: [![Open In Colab](https://colab.research.google.com/assets/colab-badge.svg)](https://colab.research.google.com/github/gagan3012/keytotext/blob/master/notebooks/K2T.ipynb)\n\nExample Notebooks can be found in the [`Notebooks`](https://github.com/gagan3012/keytotext/tree/master/examples) Folder\n\n```shell script\npip install keytotext\n```\n\n![carbon (3)](https://user-images.githubusercontent.com/49101362/116220679-90e64180-a755-11eb-9246-82d93d924a6c.png)\n\n## Trainer:\n\nKeytotext now has a trainer class than be used to train and finetune any T5 based model on new data. Updated Trainer docs here: [`Docs`](https://github.com/gagan3012/keytotext/blob/master/docs/TRAINER.md)\n\nTrainer example here: [![Open In Colab](https://colab.research.google.com/assets/colab-badge.svg)](https://colab.research.google.com/github/gagan3012/keytotext/blob/master/notebooks/Trainer.ipynb)\n\n```python\nfrom keytotext import trainer\n```\n\n![carbon (6)](https://user-images.githubusercontent.com/49101362/125130656-5989fe80-e0cf-11eb-8c07-c659767911b4.png)\n\n## UI:\n\nUI: [![Streamlit App](https://static.streamlit.io/badges/streamlit_badge_black_white.svg)](https://share.streamlit.io/gagan3012/keytotext/UI/app.py)\n\n```shell script\npip install streamlit-tags\n```\nThis uses a custom streamlit component built by me: [GitHub](https://github.com/gagan3012/streamlit-tags)\n\n![image](https://user-images.githubusercontent.com/49101362/116162205-fc042980-a6fd-11eb-892e-8f6902f193f4.png)\n\n## API:\n\nAPI: [![API Call](https://img.shields.io/badge/-Open%20with%20FastAPI-red?logo=fastapi\u0026labelColor=white)](http://localhost:8000/api?data=[%22India%22,%22Capital%22,%22New%20Delhi%22])\n[![Docker Call](https://img.shields.io/badge/-Docker%20Image-blue?logo=docker\u0026labelColor=white)](https://hub.docker.com/r/gagan30/keytotext)\n\nThe API is hosted in the Docker container and it can be run quickly.\nFollow instructions below to get started\n\n```shell script\ndocker pull gagan30/keytotext\n\ndocker run -dp 8000:8000 gagan30/keytotext\n```\n\nThis will start the api at port 8000 visit the url below to get the results as below:\n```\nhttp://localhost:8000/api?data=[\"India\",\"Capital\",\"New Delhi\"]\n```\n\n![k2t_json](https://user-images.githubusercontent.com/49101362/117046515-c56e7600-acde-11eb-8a20-7e1ab5f0de02.png)\n\nNote: The Hosted API is only available on demand\n## BibTex:\n\nTo quote keytotext please use this citation\n\n```bibtex\n@misc{bhatia, \n      title={keytotext},\n      url={https://github.com/gagan3012/keytotext}, \n      journal={GitHub}, \n      author={Bhatia, Gagan}\n}\n```\n\n# References \n- https://github.com/Shivanandroy/simpleT5 (Shivanand Roy)\n- https://github.com/patil-suraj/question_generation (Suraj Patil)\n- https://github.com/MathewAlexander/T5_nlg (Mathew Alexander)\n\n\n## Articles about keytotext:\n\n- https://towardsdatascience.com/data-to-text-generation-with-t5-building-a-simple-yet-advanced-nlg-model-b5cce5a6df45 (Mathew Alexander)\n- Amazing Video by [1LittleCoder](https://twitter.com/1littlecoder) here: https://www.youtube.com/watch?v=I0iBzP-SxFY about keytotext\n- https://medium.com/mlearning-ai/generating-sentences-from-keywords-using-transformers-in-nlp-e89f4de5cf6b (Prakhar Mishra)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fgagan3012%2Fkeytotext","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fgagan3012%2Fkeytotext","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fgagan3012%2Fkeytotext/lists"}