Skip to content

About

No description, website, or topics provided.

Resources

Stars

0 stars

Watchers

0 watching

Forks

Latest commit

 

History

1 Commit

Folders and files

NameName
Last commit message
Last commit date
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Thoughtful AI Customer Support Agent

A simple conversational agent that answers questions about Thoughtful AI's agents (EVA, CAM, PHIL) using a predefined dataset, with a friendly fallback for unrelated questions.

Features

  • Conversational UI: Web-based chat interface (Gradio).
  • Predefined answers: Matches user questions to a hardcoded QA set in temp.json.
  • Similarity matching: Uses fuzzy matching so rephrased questions still get the right answer.
  • Fallback: When no good match is found, responds with a helpful message and suggests related topics.
  • Error handling: Handles empty input, missing dataset, and invalid JSON gracefully.

Setup

  1. Python: Use Python 3.10+ (for list[dict] type hints; works on 3.9 with from __future__ import annotations if needed).

  2. Install dependencies:

    pip install -r requirements.txt
  3. Dataset: Ensure temp.json is in the same directory as agent.py (included in this repo).

Run the app

python app.py

Then open the URL shown in the terminal (e.g. http://127.0.0.1:7860) in your browser.

Project structure

  • agent.py – Core logic: load QA dataset, similarity matching, get_answer() with fallback.
  • app.py – Gradio chat UI and entry point.
  • temp.json – Predefined questions and answers about Thoughtful AI.
  • requirements.txt – Python dependencies.

Usage tips

  • Try questions like: "What does EVA do?", "Tell me about Thoughtful AI's Agents", "How does PHIL work?"
  • Rephrased or partial questions (e.g. "EVA?" or "benefits of your agents") are matched when similar enough to the dataset.
  • Off-topic questions receive the fallback message guiding users back to agent-related topics.

Evaluation notes

  • Functionality: Conversation flow and retrieval from the dataset are implemented; fallback is used when no match is found.
  • Code quality: Single-purpose functions, type hints, and a clear split between agent logic and UI.
  • Robustness: Empty input, missing/corrupt temp.json, and unexpected errors in get_answer are handled with clear user-facing messages.

About

No description, website, or topics provided.

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages