This is a streamline web application project, using the chatGPT openAI API
- Anaconda installed on the system
- Create an environment for this project (recommended) and install the packages listed in requirements.txt
conda create -n openai python==3.10
conda activate openai
pip install -r requirements.txt
- Run the python app GPT.py from streamlit
streamlit run GPT.py
StreamGPT.mp4
- To create a Docker container, a Dockerfile is provided. Make sure Docker Desktop is installed, and the OpenAI API key is stored in a .env folder, the Dockerfile contains the following.
FROM python:3.10-slim
ADD . .
RUN pip install -r requirements.txt
EXPOSE 8500
ENTRYPOINT ["streamlit","run"]
CMD ["./GPT.py","--server.headless","true","--server.fileWatcherType","none","--browser.gatherUsageStats","false","--server.port=8500","--server.address=0.0.0.0"]
- To build the Docker image from the Dockerfile, run the following command:
docker build -t streamgpt .
- To run a Docker container of the application on port 8500:
docker run -p 8500:8500 streamgpt