Skip to content

Add modular support for triage pipeline and documentation#19

Open
Mayank2142 wants to merge 3 commits into
interviewstreet:mainfrom
Mayank2142:main
Open

Add modular support for triage pipeline and documentation#19
Mayank2142 wants to merge 3 commits into
interviewstreet:mainfrom
Mayank2142:main

Conversation

@Mayank2142
Copy link
Copy Markdown

HackerRank Orchestrate: Multi-Domain Support Triage Agent 🤖

Welcome to the Multi-Domain Support Triage Agent, built for the HackerRank Orchestrate 24-Hour Hackathon. This agent is a highly modular, intelligent support triage system designed to process user support tickets across multiple platforms (HackerRank, Claude, Visa), classify them, retrieve context from a domain-specific corpus, and make autonomous decisions to either auto-reply or safely escalate.

✨ Key Features

  • Modular Architecture: Clean separation of concerns with dedicated modules for Classification, Retrieval, Decision Making, and Natural Language Generation.
  • RAG Integration: Leverages an advanced Retrieval-Augmented Generation (RAG) engine to strictly ground responses in the provided support corpus—minimizing hallucinations.
  • Intelligent Routing & Escalation: Autonomously identifies high-risk tickets (e.g., PII requests, billing disputes, critical bugs) and routes them through a strict escalation matrix.
  • Traceable Execution: Every decision is backed by a generated justification and logged transparently for seamless audits.

📁 System Architecture

The data processing pipeline is orchestrated through the following components:

  • classifier.py: Categorizes incoming tickets (e.g., bug, product_issue, invalid) and extracts targeted product areas.
  • retrieval.py: Searches the domain-specific data corpus to fetch grounded evidence for the user query.
  • decision.py: Determines whether a ticket can be confidently auto-replied or if it must be escalated to a human agent based on strict risk evaluation.
  • generator.py: Crafts professional, empathetic, and evidence-grounded natural language responses.
  • pipeline.py: Orchestrates the full lifecycle of a ticket from ingestion to the final output CSV.

🚀 Setup

Ensure you have your environment variables set (e.g., OPENAI_API_KEY or ANTHROPIC_API_KEY) using a .env file or exported directly. Then, install the required dependencies:

pip install -r requirements.txt

🛠 Run the Agent

To execute the triage agent on the full support tickets dataset, use the following command:

cd code/
python main.py \
  --tickets ../support_tickets/support_tickets.csv \
  --data ../data/ \
  --output ../support_tickets/output.csv \
  --log ../run_log.txt

🧪 Validation & Testing

To run the agent on the smaller sample dataset for quick testing and validation:

cd code/
python main.py \
  --tickets ../support_tickets/sample_support_tickets.csv \
  --data ../data/ \
  --output ../support_tickets/sample_output.csv \
  --log ../run_log.txt

📊 Output Format

The output is written to a CSV file containing the following strictly formatted columns:
status, product_area, response, justification, request_type

  • status: replied or escalated
  • product_area: A clear domain category (e.g., screen, fraud, api_integration)
  • response: The grounded natural language answer, or a standard escalation message
  • justification: A trace of how the agent arrived at its decision
  • request_type: product_issue, feature_request, bug, or invalid

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Development

Successfully merging this pull request may close these issues.

1 participant