title | emoji | colorFrom | colorTo | sdk | sdk_version | app_file | pinned |
---|---|---|---|---|---|---|---|
GradioGPT |
🚀 |
red |
orange |
gradio |
3.32.0 |
app.py |
false |
A perfect starting template for your amazing new shiny GPT application that comes with a gradio demo
gradioGPT.webm
- LangChain
ChatOpenAI
- Streaming
- State management so multiple users can use it
- UI with Gradio
- types and comments
Create a .env
file with your OpenAI API Key
echo "OPENAI_API_KEY=<YOUR_API_KEY>" > .env
You .env
should look like
OPENAI_API_KEY=<YOUR_KEY>
You can use python virtual env
python -m venv .venv
source .venv/bin/activate
pip install -r requirements.txt
Then
cd src
gradio app.py
Using gradio
is great because it gives you hot reloading
Easy peasy
docker build -t gradio-app .
docker run --rm -it -p 7860:7860 \
-e GRADIO_SERVER_NAME=0.0.0.0 \
-v $(pwd)/.env:/app/.env \
gradio-app
Then, navigate to http://0.0.0.0:7860/
You can also change the python version used (defaults to 3.11
) by
docker build --build-arg PYTHON_VERSION=3.9 -t gradio-app .
Want to contribute? Thanks a lot! Please Fork it and PR it 🙏