Skip to content

eerhshr/support-agent

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

9 Commits
 
 
 
 
 
 
 
 

Repository files navigation

E-Commerce Support Agent

My first AI-powered customer support agent for e-commerce, built with Gemini and LangChain.

This agent uses Retrieval-Augmented Generation (RAG) to provide grounded answers from the Hugging Face E-Commerce Customer Support QA dataset. It demonstrates how to build a vector index, retrieve relevant knowledge, and generate concise answers using a modern LLM.


Installation

  1. Clone the repository

    git clone https://github.com/eershr/e-commerce-support-agent.git
    cd e-commerce-support-agent
    
  2. Install dependencies

    pip install -r requirements.txt
  3. Build the index and run the agent

    python scripts/build_index.py
    python scripts/run_qa.py

Example:

Screenshot 2025-09-07 at 4 02 32 PM

Project Overview & Learnings

Dataset:

  • Used the Hugging Face E-Commerce Customer Support QA dataset in parquet format.

Embeddings:

  • Chose text-embedding-004 for semantic embeddings.
  • Why text-embedding-004? Default choice for new RAG pipelines in 2025.
  • Provides better semantic clustering, multilingual support, and domain generalization.

Vector store choice:

  • Used FAISS instead of Chroma.
  • FAISS is fast, memory-efficient, and ideal for large datasets.
  • Ease of integration into local environments and AI frameworks like LangChain.

Pipeline choice:

  • Used RetrievalQA instead of a fully Runnable pipeline.
  • Simpler to implement for question-answering.
  • Runnable pipelines provide more flexibility but require more setup and are better for multi-step reasoning or custom transformations.

Other key learnings:

  • Prompt design is critical — adding instructions like “Answer only using the provided context” significantly improves answer quality.
  • FAISS retrieval + structured Q&A documents ensures the agent rarely answers “I don’t know.”

About

AI agent for e-commerce customer support with Gemini and LangChain

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages