Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/ibensusan/simple-chatbot
A basic Python chatbot that responds to user input based on predefined keywords.
https://github.com/ibensusan/simple-chatbot
Last synced: 8 days ago
JSON representation
A basic Python chatbot that responds to user input based on predefined keywords.
- Host: GitHub
- URL: https://github.com/ibensusan/simple-chatbot
- Owner: iBensusan
- License: mit
- Created: 2024-11-08T17:31:50.000Z (about 1 month ago)
- Default Branch: main
- Last Pushed: 2024-11-09T10:31:00.000Z (about 1 month ago)
- Last Synced: 2024-11-09T11:25:37.156Z (about 1 month ago)
- Language: Python
- Size: 1000 Bytes
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# Simple Python Chatbot
A basic Python chatbot that can respond to a limited set of questions or keywords. This chatbot analyzes user input and gives predefined responses based on keywords it detects. It’s an excellent project for practicing control flow, dictionaries, and user input handling in Python.
## Features
- **Keyword-Based Responses**: Uses a dictionary to map user input keywords to predefined responses.
- **User-Friendly Interaction**: Continuously chats with the user until they decide to exit by typing "bye."
- **Real-Time Information**: Provides the current time and day using Python’s `datetime` module.## Requirements
- Python 3.x
## Installation
1. Clone this repository or download the project files:
```bash
git clone https://github.com/username/simple-chatbot-python.git
cd simple-chatbot-python
```2. Ensure you have Python 3 installed:
```bash
python --version
```## Usage
1. Run the chatbot script:
```bash
python simple_chatbot.py
```2. The chatbot will greet you and ask for input. Type any question or keyword such as:
- "hello"
- "what's the time?"
- "tell me about python"3. To exit the chat, simply type "bye."
## Example Workflow
1. Run the program.
2. Input a greeting like "hi."
3. Ask a question such as "what’s the time?" or "what is Python?"
4. Type "bye" to end the conversation.## Files
- `simple_chatbot.py`: The main Python script implementing the chatbot functionality.
- `README.md`: Project description and usage instructions.## License
This project is licensed under the MIT License.