metadata
license: mit
title: Fastlane Chat GPT for e-commerce
sdk: gradio
emoji: 🚀
colorFrom: gray
colorTo: blue
short_description: This project is about a RAG system for e-commerce
FastLane E-commerce Chatbot
This project provides a Retrieval-Augmented Generation (RAG) system that involves Elastisearch, OpenAI, FastAPI and Gradio components. The system is about an e-commerce chatbot for product and orders searches and leverages Natural Language Processing (NLP) for understanding user intent.
Modular Structure for Maintainability:
The system was designed with a focus on maintainability and scalability. Here's a breakdown of the core components:
- main.py: The entry point for the application, where the FastAPI app is defined and run.
- models/ (Directory): Contains Pydantic models for data validation and defining data structures used throughout the application.
query.py
: Defines models for user queries.product.py
: Defines models for representing product data.customer.py
: Defines models for representing customer data.order.py
: Defines models for representing order data.
- services/ (Directory): Encapsulates the core business logic of the application.
elasticsearch.py
: Handles interactions with the Elasticsearch instance for product searches.nlp.py
: Provides functionalities for Natural Language Processing (NLP) to understand user intent.utils.py
: Provides functions that are used by several components of the system.
- routes/ (Directory): Defines API endpoints for interacting with the chatbot functionalities. Each feature has its dedicated module:
search_products.py
: Handles routes related to product search functionalities.query_handler
: Handles routes related to the processing of the query introduced by users.purchase.py
: Handles routes related to purchase functionalities (add to cart, checkout, etc.).order_management.py
: Handles routes related to managing orders (tracking, history).account_management.py
: Handles routes related to account management (sign-in, update information).customer_support.py
: Handles routes related to customer support functionalities (returns, payments, etc.).
This modular structure promotes separation of concerns, making the code easier to understand, maintain, and extend in the future.
Getting Started:
(Provide instructions on how to set up and run the application, including any dependencies or environment variables required.)
Further Development:
- Generating more comprehensive responses based on intent, entities, and search results.
- Enhance security features for handling sensitive user data.
- Implement user authentication and authorization mechanisms.