For the complete documentation index, see llms.txt. This page is also available as Markdown.

AI Customer Support Agent Example

Measure support deflection by connecting ticket workflows, tool costs, human escalation, and resolved-ticket outcomes.

AI support agents can classify tickets, search knowledge, draft responses, update support systems, and decide when a customer needs a human. The business value is not just ticket volume; it is whether the agent resolves routine work at a lower cost while escalating the cases that still need human judgment.

This example simulates a support queue across three motions — ticket triage, ticket resolution, and escalation handling — with three terminal outcomes per ticket: deflected, escalated, or converted (an upsell or renewal during the support session). The result is a deflection-economics view rather than a deflection-rate count.

For the broader outcome-measurement pattern across these examples, see the overview page.

What You'll See

When the run completes, these Revenium views populate with the demo data:

  • ROI dashboard — support-agent cost vs. deflected human handling cost plus upsell value, with net value.

  • Deflection Rate — share of tickets resolved without human handling.

  • Outcome Mix — deflected vs. escalated vs. converted (upsell) tickets.

  • Cost Composition — AI model spend, tool spend (KB search, CRM lookup, ticket update), and human escalation review cost.

  • Tool Cost ratio — share of cost driven by support tools vs. the model itself.

  • Traces — per-ticket sequence of classify → KB search → draft → verify → ticket update.

  • Performance — transaction count and duration outliers, useful for high-volume support batches.

Run It

The example scripts ship in the public SDK repo, not on PyPI. Clone the repo first, then run from inside it:

git clone https://github.com/revenium/revenium-python-sdk.git
cd revenium-python-sdk
pip install revenium-python-sdk
python examples/agentic_outcomes/support.py --count 5

Set REVENIUM_API_KEY (a write-scope key, rev_sk_…, generated at app.revenium.ai → Integrations) before running. Use --dry-run or --plan to preview, or --force-outcome ESCALATED to drive a specific outcome path.

View The Source

The runnable scenario lives in the public SDK:

Customize

The top of support.py exposes the customization points: SCENARIOS (triage / resolution / escalation mix and step sequences), LLM_STEPS and TOOL_STEPS (reusable step templates), OUTCOME_WEIGHTS (deflection / escalation / conversion rates), UPSELL_VALUE_RANGE, and the ESCALATION_TOOL cost. Tweak to match your support motion. For the full TUNABLES reference, see the TUNABLES section of the examples README.

Why This Matters

Support automation can look successful if you only count resolved tickets, but cost and escalation behavior change the story. A deflected ticket is valuable when the total cost of the agent and tools is lower than the human work it avoided. This example connects the support workflow, the operational cost, and the ticket outcome so teams can reason about deflection as unit economics.

Notes

  • Values are illustrative demo values, not support benchmark claims.

  • Prompt details in the UI depend on your workspace prompt-capture settings.

  • Keep first runs small enough that individual ticket traces are easy to inspect.

Last updated

Was this helpful?