Skip to content

riddhima-7321/Mutli-agent-ai

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

3 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Multi-Agent AI Document Processor

A functional multi-agent AI system that classifies document types (Email, JSON, PDF), determines their intent (Invoice, RFQ, Complaint, etc.), and routes them to specialized agents. Built in Python and powered by gpt-3.5-turbo via OpenRouter. #DEMO watch it here v=https://youtu.be/zEoiCeRG9To

Features

  • Classifier Agent — Identifies file type & intent using GPT-3.5
  • Email Agent — Extracts sender, urgency, and summary for CRM usage
  • JSON Agent — Validates and reformats structured invoice/RFQ payloads
  • Shared Memory — Logs format, intent, source, timestamp, and results

Project Structure

multi-agent-ai/ ├── agents/ │ ├── classifier_agent.py │ ├── email_agent.py │ └── json_agent.py ├── memory/ │ └── memory_manager.py ├── inputs/ │ ├── sample_email.txt │ └── sample_invoice.json ├── main.py ├── config.py ├── requirements.txt └── README.md

Setup

1. Clone the Repo

git clone https://github.com/yourusername/multi-agent-ai.git
cd multi-agent-ai

2. Install Dependencies
bash
Copy
Edit
pip install -r requirements.txt
3. Add Your OpenRouter API Key
Open config.py and set your API key and model:

python
Copy
Edit
OPENROUTER_API_KEY = "your-openrouter-api-key"
MODEL = "openai/gpt-3.5-turbo"
🚀 Run the App
Run the system on a sample file (email or JSON):

bash
Copy
Edit
python main.py inputs/sample_email.txt
🧪 Sample Input
sample_email.txt
vbnet
Copy
Edit
Subject: Request for Quotation

Hi,

We’re planning to purchase 500 units of your Model X product. Please send us a quote with pricing and delivery schedule.

Best,
Alex
sample_invoice.json
json
Copy
Edit
{
  "invoice_id": "INV-2025-0007",
  "amount": 1299.50,
  "date": "2025-05-30"
}
📦 Output Example
json
Copy
Edit
{
  "sender": "unknown@example.com",
  "summary": "Subject: Request for Quotation\n\nHi,\n\nWe’re planning to purchase 500 units of your Model X product.",
  "urgency": "low"
}
All outputs are stored in memory/logs.json for traceability.

🔧 Tech Stack
Python 3.8+

OpenRouter API

GPT-3.5 Turbo (openai/gpt-3.5-turbo)

JSON-based memory store

✅ To Do
 Add PDF Agent

 Improve sender extraction from emails

 Add Streamlit UI

 Support async job queue

📄 License
This project is licensed under the MIT License.

🙋‍♀️ Author
Made with ❤️ by Riddhima
Powered by OpenRouter + OpenAI

yaml
Copy
Edit

---

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages