Here's a quick overview of how to run it locally.
- Set up OpenAI
You'll need an OpenAI API key.
- Clone repo
git clone https://github.com/lehmannerich/next-chatbot.git
- Install dependencies
npm i
- Set up environment variables
Create a .env file in the root of the repo with the following variables:
OPENAI_API_KEY="sk-YOURAPIKEYHERE"
- Run app
npm run dev
Thanks to Mckay Wrigley for his open source repos - I forked this as a starting point.
Thanks to the Vercel Template - I took a lot of code from it.
If you have any questions, feel free to reach out to me on Twitter!
This app isn't perfect - don't rely on it.
The behaviour with the input on mobile is a bit weird.