Skip to main content

Agent Options

The repository contains two voice-agent implementations. Run one agent service at a time for the calling flow you want.

Sarvam Agent

Command:
Pipeline:
Key settings:
Qualification fields:
  • machine_interest
  • location
  • budget
  • first_product
  • units_per_day
  • local_demand
  • new_or_expand
  • partnership
  • operators_needed
  • own_brand
  • seriousness
  • factory_visit
  • video_demo

OpenAI Realtime Agent

Command:
Pipeline:
Key settings:
Qualification fields:
  • product_interest: carbon cleaning, battery regeneration, car wash, franchise, or unsure
  • location
  • budget: below 10 lakhs, 10-25 lakhs, or >25 lakhs

Save Behavior

Both agents:
  1. Build a transcript/history during the call.
  2. Extract structured qualification from the transcript.
  3. Remove null values.
  4. Save the JSON to calls.qualification.
  5. Mark the call called.
  6. Hang up or finish the room.
If the participant disconnects first, the agent attempts a partial save. If no useful answers exist, it marks the call failed and can schedule a retry.

Language Behavior

agent_realtime.py contains detection and reply guidance for English and Indian-language user intent, including local-language and romanized-language handling. It also normalizes saved qualification values back to English-only structured data so downstream CRM payloads stay consistent.

Call Limits

OpenAI Realtime mode watches maximum call age:
When the maximum duration is reached, the agent saves available qualification data and hangs up.