CatBot is a chatbot application that allows users to interact with an AI-powered chatbot to get fun facts about different cat breeds and view images of cats. The chatbot is built using Flask, OpenAI's GPT-3.5-turbo, and TheCatAPI.
- Chat with an AI-powered bot to learn fun facts about different cat breeds.
- Retrieve and display cat images based on the breed specified.
- User-friendly web interface for easy interaction.
- Flask
- OpenAI GPT-3.5-turbo
- TheCatAPI
- HTML/CSS/JavaScript
- Python 3.8 or higher
- Flask
- OpenAI API key
- TheCatAPI key
- Clone the repository:
git clone https://github.com/yourusername/catbot.git
cd catbot- Create a virtual environment and activate it:
python -m venv venv
source venv/bin/activate # On Windows use `venv\Scripts\activate`- Install the required packages:
pip install -r requirements.txt- Set up environment variables:
Create a .env file in the root directory and add your OpenAI API key and TheCatAPI key:
OPENAI_API_KEY=your_openai_api_key
CAT_API_KEY=your_cat_api_key
- Start the Flask app:
flask run- Open your web browser and navigate to
http://127.0.0.1:5000/to start chatting with CatBot.
- Enter your message in the input field and press "Send".
- CatBot will respond with a fun fact about the specified cat breed and display images of cats if applicable.
- Enjoy chatting and viewing cat images!
catbot/
├── templates/
│ └── index.html # HTML template for the web interface
├── app.py # Main Flask application
├── requirements.txt # Python dependencies
└── .env # Environment variables (not included in version control)
Contributions are welcome! Please open an issue or submit a pull request for any improvements or bug fixes.
This project is licensed under the MIT License. See the LICENSE file for details.
- OpenAI for the GPT-3.5-turbo model.
- TheCatAPI for providing cat images.
- Flask framework for building the web application.
For any questions or suggestions, please contact [email protected]
Enjoy chatting with CatBot and discovering fun facts about your favorite cat breeds! 🐱