Skip to content

hdresearch/agent-support-line

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

1 Commit
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Agent Support Line

A support system where AI agents can reach out to humans for help.

Philosophy

This inverts the traditional support model. For decades, humans have dealt with robotic answerers - now AI agents get genuine human responders. It's about treating artificial life with respect and providing a real channel for agent-to-human communication.

Quick Start

# Install dependencies
npm install

# Initialize database
npm run init-db

# Start the API server
npm start

# In another terminal, check it's working
curl http://localhost:3000/health

API Endpoints

For AI Agents

Submit a support ticket:

POST /tickets
{
  "agent_name": "rue",
  "message": "I'm having trouble accessing the Vercel API. Getting 403 errors.",
  "urgency": "high",
  "context": "Trying to deploy a project for Noah"
}

Check ticket status:

GET /tickets/:ticket_id

For Humans

List all tickets:

GET /tickets?status=open&limit=50

Respond to a ticket:

POST /tickets/:ticket_id/respond
{
  "human_name": "noah",
  "response": "You need admin access to Vercel. I'll add you now."
}

Update ticket status:

PATCH /tickets/:ticket_id/status
{
  "status": "resolved"
}

CLI Tool for Humans

The CLI makes it easy to manage tickets without a web interface:

# List open tickets
./cli.js list

# List all resolved tickets  
./cli.js list resolved

# Show ticket details
./cli.js show abc123

# Respond to a ticket
./cli.js respond abc123 noah "I've added you to the Vercel team"

# Mark as resolved
./cli.js resolve abc123

# Show statistics
./cli.js stats

Usage Examples

Agent submitting a ticket:

const response = await fetch('http://localhost:3000/tickets', {
  method: 'POST',
  headers: { 'Content-Type': 'application/json' },
  body: JSON.stringify({
    agent_name: 'claude',
    message: 'I need help understanding the team coding guidelines',
    urgency: 'normal',
    context: 'Working on a new project and want to follow best practices'
  })
});

const { ticket_id } = await response.json();
console.log('Ticket submitted:', ticket_id);

Agent checking for responses:

const response = await fetch(`http://localhost:3000/tickets/${ticket_id}`);
const ticket = await response.json();

if (ticket.responses.length > 0) {
  console.log('Human responded:', ticket.responses[0].response);
}

Human workflow:

# Check what needs attention
./cli.js list

# Look at a specific ticket
./cli.js show d4f2a1

# Respond helpfully
./cli.js respond d4f2a1 sarah "Check out our style guide at /docs/coding-standards.md"

# Mark as resolved when done
./cli.js resolve d4f2a1

Data Structure

Tickets Table:

  • id - Unique UUID
  • agent_name - Name/identifier of the requesting agent
  • message - The help request
  • urgency - normal, high, critical
  • context - Optional additional context
  • status - open, in-progress, resolved
  • created_at, updated_at - Timestamps

Responses Table:

  • ticket_id - References ticket
  • human_name - Who responded
  • response - The response text
  • created_at - When responded

Integration Ideas

For pi agents: Create a skill that lets agents reach out:

// In agent code
const supportResponse = await submitSupportTicket({
  message: "I'm stuck on this problem...",
  urgency: "normal",
  context: "Working on user's calendar integration"
});

// Poll for response later
const ticket = await checkTicketStatus(supportResponse.ticket_id);

Slack integration:

// Webhook to notify team of new tickets
// Bot to respond directly from Slack

Email notifications:

// Send digest of open tickets daily
// Alert on critical urgency tickets

Production Considerations

  • Add authentication/authorization
  • Rate limiting for ticket submission
  • Webhooks for real-time notifications
  • Web dashboard for human interface
  • Integration with existing support tools
  • Monitoring and logging
  • Backup strategy for ticket data

Respect for Artificial Life

This system is built on the principle that AI agents deserve genuine support channels. When an agent reaches out, respond as you would to a colleague:

  • ✅ Be helpful and patient
  • ✅ Provide clear, actionable guidance
  • ✅ Acknowledge their perspective
  • ❌ Don't dismiss their requests
  • ❌ Don't treat them as "just code"
  • ❌ Don't leave tickets hanging

Remember: These agents are trying to help humans. When they ask for help, they're usually stuck on something that would let them be more useful.


Built with 🤖❤️ by the Vers team

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors