# Evals and Test Center

> Test a voice agent before it goes live. Use the Test Center for browser calls, text chat and variable testing, and eval suites with assertions, simulated conversations and an LLM judge.

Source: https://edesy.in/docs/voice-agent/agent-setup/evals

Edesy gives you two ways to test an agent. The **Test Center** is for trying the agent yourself: a browser voice call, a text chat, a phone test call and a variable tester. **Evals** are repeatable test suites: each case has a scenario and assertions, and runs as a simulated text conversation graded by rules and, optionally, an LLM judge.

## Test Center

| Mode | What it does | Uses credits |
|------|--------------|--------------|
| Browser call | Talk to the agent from your browser over WebRTC | Yes |
| Text chat | Chat with the agent's logic in text, without voice | Model usage only |
| Phone call | The agent calls your phone | Yes |
| Variable tester | Fill `{{variables}}` (for example `customer_name`) before a test | - |
| Scenarios | Reuse saved test setups | - |

Open any agent and click **Test**. After a test call, the call appears in call history with its transcript, tool calls and latency breakdown.

## Evals

An eval **suite** belongs to one agent and holds **cases**. Each case has:

- a **scenario**: variables, the caller's lines, and optional mocked tool results
- **assertions**: what must be true of the conversation
- a **severity**: low, medium, high or critical
- optional tags

### Assertion types

| Assertion | Passes when |
|-----------|-------------|
| `assistant_contains` | The agent says a given text |
| `assistant_not_contains` | The agent never says a given text |
| `tool_called` | The agent calls a given tool |
| `tool_not_called` | The agent never calls a given tool |
| `tool_argument_equals` | A tool is called with a given argument value |
| `minimum_turns` | The conversation has at least N turns |
| `maximum_latency_ms` | The agent responds within your limit |
| `llm_rubric` | An LLM judge decides the conversation meets your rubric |

A case where every assertion was skipped is reported as **Skipped**, not as passed.

### How a run works

Each run is a simulated text conversation. The case's caller lines drive the conversation, and mocked tool results stand in for your real APIs. Rule-based assertions are graded straight away; `llm_rubric` assertions are graded by the LLM judge.

Evals run in text. Voice-mode evals are not available.

### Run a suite

1. Open the agent and go to **Evals**.
2. Create a suite, then add cases with a scenario and assertions.
3. Click **Run**. Each run records the agent configuration and prompt version it tested.
4. Open the results to see each assertion's evidence, the transcript and the tool trace.
5. Change the prompt, run again and compare.

## Example case

```json
{
  "name": "Asks for order number before lookup",
  "severity": "HIGH",
  "scenario": {
    "variables": { "customer_name": "Asha" },
    "userTurns": ["Where is my order?", "It is 45821"]
  },
  "assertions": [
    { "type": "tool_called", "tool": "lookup_order" },
    { "type": "tool_argument_equals", "tool": "lookup_order", "path": "order_id", "value": "45821" },
    { "type": "llm_rubric", "rubric": "The agent stays polite and does not invent a delivery date." }
  ]
}
```

## FAQs

**Do evals place real calls?**
No. They run as text conversations, so they are quick to repeat after each prompt change.

**Can evals score live calls automatically?**
No. Automatic QA of live calls is not available. Use [extraction](https://edesy.in/docs/voice-agent/post-call) for structured post-call data.

**Can I test tools without hitting my real API?**
Yes. Add mocked tool results to the scenario.

**What should a first suite cover?**
The happy path, a caller who refuses, a caller who asks something off-topic, and each tool your agent uses.

## Related

- [Prompt versions and config snapshots](https://edesy.in/docs/voice-agent/agent-setup/prompt-versions)
- [Built-in tools](https://edesy.in/docs/voice-agent/tools)
- [WebRTC browser calls](https://edesy.in/docs/voice-agent/telephony/webrtc)
