Chirp uses the Discord and OpenAI APIs to receive and answer ChatGPT prompts from Discord.
Running requires creating a Discord Application, as well as an OpenAI API key. The Discord bot will also need to be added to a server.
Put the Discord token and OpenAI access tokens in a .env file with the following syntax:
discordtoken='yourkeyhere'
openaitoken='yourkeyhere'
There are three required gems to install:
After installing all prerequisites, the program can be run with:
ruby chirp.rb
Ask chirp a question using the following format in discord:
chirp [question body here]
Example usage:
Chirp supports DALLE images using the following format:
chirp paint [prompt here]
It returns a URL, which should be automatically embedded by Discord.
Example usage: