Note: A new v2 branch is now available featuring major improvements and enhancements. While this main branch is fully cloneable and runnable from our GitHub repository, the v2 branch leverages a local Solr instance (diamond_core) for its advanced diamond search capabilities and integrates images and videos for an enriched user experience. For full details on the changes and setup instructions, please refer to the README in the v2 branch.
Welcome to Gemma, an AI-powered chatbot designed to assist users in finding the perfect diamond based on their preferences. This chatbot integrates advanced natural language processing (NLP) and machine learning techniques to provide personalized recommendations.
✔ Interactive Chatbot – Ask questions about diamonds, and get tailored recommendations.
✔ AI-Powered Search – Uses a FAISS-based hybrid search for accurate results.
✔ Expert Analysis – Provides professional insights on selected diamonds.
✔ User-Friendly Interface – A clean and intuitive web-based UI for seamless interaction.
Gemma/
│── app.py # Flask application entry point
│── chatbot.py # Chatbot logic and recommendation engine
│── templates/
│ ├── index.html # Web-based chat interface
│── diamonds.csv # Raw diamond dataset
│── diamond_dataframe.csv # Processed diamond data
│── requirements.txt # Required dependencies
│── README.md # Project documentation
│── .gitignore # Git ignored files
git clone https://github.com/yourusername/Gemma.git
cd Gemmapython -m venv venv
source venv/bin/activate # On macOS/Linux
venv\Scripts\activate # On Windowspip install -r requirements.txtCreate a .env file in the root directory and add the following:
GROQ_API_KEY=your_groq_api_key_hereReplace your_groq_api_key_here with your actual API key.
python app.pyThe chatbot will be available at:
🔗 http://127.0.0.1:5500/
- Open the Web Interface – Visit the running URL in your browser.
- Ask Questions – Type queries like "Find me a 1-carat round diamond" in the chat.
- Get Recommendations – The chatbot will return the best-matching diamonds along with expert insights.
- Data Processing: Loads and processes diamond data from
diamonds.csv. - Embedding Generation: Converts text descriptions into vector embeddings using
SentenceTransformer. - FAISS-Based Search: Uses FAISS for efficient similarity search.
- AI-Powered Responses: Integrates with Groq AI to generate natural language responses.
- Flask: Web framework for Python
- FAISS: Vector search library for efficient similarity searches
- SentenceTransformer: NLP model for text embeddings
- Groq API: AI-based chatbot response generation