Downloads · 30 days
0
krishu654/my_env
my_env is a machine learning model from krishu654. Use it for the machine learning task on the model card, and read the license before you ship it in a product.
A realistic customer support environment where AI agents learn to categorize, prioritize, and resolve support tickets - a critical real-world business function.
Downloads · 30 days
0
Access
Public
Updated Apr 8, 2026
Repo size
—
Likes
0
Public
Click a slice to open those files.
.py5 KB · 36%
From the Hugging Face model README
A realistic customer support environment where AI agents learn to categorize, prioritize, and resolve support tickets - a critical real-world business function.
This environment simulates a customer support ticket queue that agents must manage. Support teams worldwide handle millions of tickets daily, and efficient triage is essential for customer satisfaction and retention.
Motivation: Poor ticket management leads to customer churn, SLA violations, and lost revenue. An AI agent that can intelligently triage support tickets would help companies:
Actions are JSON objects with the following fields:
| Action Type | Required Fields | Description |
|---|---|---|
categorize | ticket_id, category | Classify ticket (billing, technical, account, feature_request, complaint, general) |
prioritize | ticket_id, priority | Assign priority 1-5 (1=lowest, 5=highest) |
escalate | ticket_id, escalation_level | Escalate to higher support tier (1=team lead, 2=manager, 3=director) |
resolve | ticket_id | Mark ticket as resolved |
request_info | ticket_id | Request additional information from customer |
Each observation includes:
| Field | Type | Description |
|---|---|---|
tickets | array | List of pending tickets with metadata |
queue_position | integer | Current position in queue |
processed_count | integer | Number of tickets processed |
task_id | string | Task difficulty (easy/medium/hard) |
step_count | integer | Steps taken in current episode |
sla_deadline | integer | Hours until nearest SLA violation |
urgency_level | string | Queue urgency (critical/normal/low) |
Each ticket contains:
The reward function provides dense feedback throughout the episode:
| Action | Reward | Breakdown |
|---|---|---|
| Correct categorization | +0.7 | +0.7 for exact match, +0.3 for close |
| Accurate prioritization | Up to +0.6 | Based on closeness to correct priority |
| Appropriate escalation | +0.8 | +0.8 for correct level, -0.2 for unnecessary |
| Timely resolution | +0.5 | +0.15 efficiency bonus for quick handling |
| Progress | +0.05 per ticket | Cumulative progress through queue |
| SLA compliance | -0.2 per warning | Penalty for approaching SLA violations |
| Completion bonus | Up to +1.0 | Bonus based on SLA performance |
| Invalid actions | -0.3 | Penalty for targeting wrong ticket |
# Clone repository
git clone <repository-url>
cd customer-support-env
# Install dependencies
pip install -r requirements.txt
# Set OpenAI API key (for baseline agent)
export OPENAI_API_KEY="your-api-key-here"
# Run baseline evaluation
python baseline/baseline_agent.py
# Run tests
pytest tests/test_env.py -v