An intelligent chatbot built with Python, TensorFlow, and Natural Language Processing (NLP). This project demonstrates how to build and deploy a simple conversational AI capable of understanding user intent and generating relevant responses.
Additionally, this repository includes a Mac Mini M2 optimized security assistant CLI tool that performs comprehensive file system analysis and security risk assessment.
- Intent recognition using custom-trained LSTM model
- Clean, structured NLP pipeline (tokenization, stemming, vectorization)
- FastAPI-powered backend for real-time chatbot responses
- Easy to train and customize with new intents
- Deployment-ready for Render, Hugging Face Spaces, or local Docker
- Comprehensive file system scanning and analysis
- Real-time security risk assessment and monitoring
- Detailed vulnerability reporting with mitigation recommendations
- Continuous monitoring capabilities
- M2 chip optimized for performance
- Python 3.10+
- TensorFlow
- scikit-learn
- FastAPI
- Jupyter Notebooks
- JSON for intent training data
AI-Chatbot/
├── data/
│ └── intents.json # Sample training data (intents, responses)
├── model/
│ └── chatbot_model.h5 # Trained TensorFlow model (generated)
├── notebooks/
│ └── training.ipynb # Notebook for training and evaluation
├── app/
│ ├── main.py # FastAPI app serving the chatbot
│ └── requirements.txt # Dependencies
├── assistant/
│ ├── cli.py # Security assistant CLI tool
│ ├── scanner.py # File system scanner
│ ├── security_analyzer.py # Security risk assessment engine
│ ├── reporter.py # Report generation
│ └── requirements.txt # Assistant dependencies
├── README.md
└── .gitignore
- Clone the repository
git clone https://github.com/jdgiles26/AI-Chatbot.git
cd AI-Chatbot- Create a virtual environment and install dependencies
python3 -m venv venv
source venv/bin/activate
pip install -r app/requirements.txt-
Train the model Open
notebooks/training.ipynband run all cells to train and save the model. -
Run the FastAPI server
uvicorn app.main:app --reloadThen visit http://127.0.0.1:8000/docs to test your chatbot API.
- Install the assistant CLI dependencies
pip install -r assistant/requirements.txt- Make the assistant executable
chmod +x assistant/cli.py- Run security scan
python3 assistant/cli.py scan --path /path/to/scan- Generate security report
python3 assistant/cli.py report --output security_report.json- Start continuous monitoring
python3 assistant/cli.py monitor --interval 300Send POST requests to /predict endpoint:
{
"message": "Hello"
}The assistant CLI provides comprehensive security analysis:
- Scans file system for potential security risks
- Identifies suspicious files and permissions
- Monitors file changes in real-time
- Generates detailed reports with mitigation steps
This project is licensed under the MIT License. See the LICENSE file for details.
For questions and support, please open an issue on GitHub.