Skip to content
This repository has been archived by the owner on Jun 5, 2023. It is now read-only.
/ Discord-ThreadGPT Public archive

A (arguably badly written) Discord Bot that implements ChatGPT using acheong08's revChatGPT library

Notifications You must be signed in to change notification settings

Jecket22/Discord-ThreadGPT

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

ThreadGPT

"oh wow, another ChatGPT Discord Bot"

This utilizes revChatGPT to run a fairly simple Discord Bot that can split up each conversation into separate threads. Hence the name! (im a genius)

Configuration

Edit .env accordingly.
This config contains your Bot token and your OpenAI API key. Example:

bot_token=MTc3MDFubw...
openai_api_key=sk_d2VlZA...

config.json contains various settings, such as file/folder locations for storing conversations and the base-prompt.
You can also set "bot_knows_usernames" to true so that the bot knows the nickname (or username if no nickname is set) of the user the bot is talking to.

{
    "db_file": "convos.db",
    "convo_folder": "conversations",
    "main_base_prompt": "You are ChatGPT, a large language model trained by OpenAI. Respond conversationally and adjust to the user's language.",
    "bot_knows_usernames": false
}

Usage

The bot has two commands as of now:

/createchat - Opens up a pop-up asking for a prompt, then creates a thread assosciated with the converstaion generated.
/ask <prompt> - Ask with a prompt in a chat.

Notice of lacking functionality or issues

  • There is currently no implementation of disallowing a conversation to continue.
  • There is no shortcut-command for /createchat. I'll consider making that sometime soon.
  • This is currently using a specific version of revChatGPT. The newest version (newer than 3.3.1) has a different implementation of the save/load function, which I personally am a little confused over of how to implement it properly.

About

A (arguably badly written) Discord Bot that implements ChatGPT using acheong08's revChatGPT library

Topics

Resources

Stars

Watchers

Forks