{"id":19816942,"url":"https://github.com/flyingfathead/discord-gpt2-bot","last_synced_at":"2026-05-02T08:34:02.625Z","repository":{"id":186382365,"uuid":"675065493","full_name":"FlyingFathead/Discord-GPT2-bot","owner":"FlyingFathead","description":"A simple Discord chatbot for local GPT-2 TensorFlow models","archived":false,"fork":false,"pushed_at":"2023-08-05T21:03:28.000Z","size":44,"stargazers_count":1,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-02-28T12:07:05.105Z","etag":null,"topics":["chatbot","chatbot-application","chatbot-framework","chatbots-framework","discord","discord-bot","discord-py","gpt-2","gpt-2-chatbot","gpt2","gpt2-bot","gpt2-chitchat","python","python311","tensorflow","tensorflow2"],"latest_commit_sha":null,"homepage":"","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/FlyingFathead.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null}},"created_at":"2023-08-05T16:51:18.000Z","updated_at":"2024-07-24T21:58:07.000Z","dependencies_parsed_at":null,"dependency_job_id":"939fae7e-63e7-4e8f-9d13-7e3df9d020c8","html_url":"https://github.com/FlyingFathead/Discord-GPT2-bot","commit_stats":null,"previous_names":["flyingfathead/discord-gpt2-bot"],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/FlyingFathead%2FDiscord-GPT2-bot","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/FlyingFathead%2FDiscord-GPT2-bot/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/FlyingFathead%2FDiscord-GPT2-bot/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/FlyingFathead%2FDiscord-GPT2-bot/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/FlyingFathead","download_url":"https://codeload.github.com/FlyingFathead/Discord-GPT2-bot/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":241170256,"owners_count":19921572,"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":["chatbot","chatbot-application","chatbot-framework","chatbots-framework","discord","discord-bot","discord-py","gpt-2","gpt-2-chatbot","gpt2","gpt2-bot","gpt2-chitchat","python","python311","tensorflow","tensorflow2"],"created_at":"2024-11-12T10:11:09.343Z","updated_at":"2026-05-02T08:34:02.567Z","avatar_url":"https://github.com/FlyingFathead.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Discord-GPT2-bot\nA simple Discord chatbot powered by OpenAI's GPT-2 model, designed to run on local TensorFlow setups.\n\n# Install\n1. **Clone the repository**\n\n```\ngit clone https://github.com/FlyingFathead/Discord-GPT2-bot\ncd Discord-GPT2-bot/\n```\n\n2. **Install dependencies**\n```\npip install -r requirements.txt\n```\n\n3. **Get the OpenAI GPT-2 model** and tune it according to your requirements. Place the model in the corresponding subdirectory (e.g., `models/124M/`). Ensure that the directory contains all necessary TensorFlow model files, including `vocab.bpe`, `encoder.json`, and `hparams.json`.\n\n4. **Set up the bot** (see the code; fix the variables to suit your use scenario):\n    - Save your Discord API bot token in `token.txt` (one line).\n    - Define the bot's authorized users in `authorized_users.txt` (one username per line; syntax i.e. `UserName#0` or `UserName#xxxx`).\n\n6. **Optional \u0026 additional configuration**\n   - Feel free to configure various replacement lists for elements like unwanted URLs, words, strings, allowed channels etc. Refer to the source code for a complete list of replaceable items.\n\n8. **Run** with `python Discord-GPT2-bot.py` and enjoy! (?)\n\n# Usage\nTalk to the bot and it should respond.\n\n  Commands:\n- `!goodnight` - the bot shuts down (user must be in the authorized users list, `authorized_users.txt` by default)\n- `!maxrolls x` - max number of replies to a single line (x = number of replies)\n- `!odds x` - odds (probability) of the bot answering; 0 for 0%, 1 for 100%, use fractions like 0.5 = 50%\n- `!temp x` - set the model's temperature (between 0 and 2). Optimal for an optimized model usually hangs at around 1.\n- `!alert` - send out a test alert (for testing, debug purposes etc)\n\n# Notes\nThis is mostly for humorous \u0026 testing purposes, although the code works perfectly fine when set up correctly, don't expect miracles out of the bot. Actual performance depends on fine-tuning and model size, etc. -- Feel free to expand on its functionalities and adapt it to your needs.\n\nFrom [FlyingFathead](https://github.com/FlyingFathead/), in collaboration with ChaosWhisperer.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fflyingfathead%2Fdiscord-gpt2-bot","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fflyingfathead%2Fdiscord-gpt2-bot","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fflyingfathead%2Fdiscord-gpt2-bot/lists"}