Ensure you have Python installed. It is recommended to use miniconda or conda for environment management.
-
Install Miniconda (if not already installed)
Download and install Miniconda from the official website:
-
Create a Conda Environment
Open your terminal or Anaconda Prompt and create a new environment:
conda create -n chatbot-env python=3.9 conda activate chatbot-env
-
Install Requirements
Navigate to the project directory and install the necessary packages:
cd /path/to/your/chatbot-streamlit-demo pip install -r requirements.txt -
Run the Streamlit Application
streamlit run streamlit_app.py The application will open in your web browser.
-
Build the Docker Image
Navigate to the project directory and build the Docker image:
docker build -t chatbot-streamlit-demo . -
Run the Docker Container
Run the Docker container, mapping port 8501:
docker run -p 8501:8501 chatbot-streamlit-demo
The application will be accessible in your web browser at
http://localhost:8501.
- streamlit_app.py: The main Streamlit application file, containing the chatbot UI and logic.
- database_tools.py: Contains functions for interacting with the sales_data.db database.
- requirements.txt: Lists all Python dependencies required for the project.
- streamlit_react_app.py: (Optional) Another Streamlit application, possibly demonstrating React integration.
- streamlit_react_tools_app.py: (Optional) Another Streamlit application, possibly demonstrating React tools integration.