Skip to main content
POST
/
v1
/
simulation
Run Scenarios
curl --request POST \
  --url https://api.eqho.ai/v1/simulation \
  --header 'Content-Type: application/json' \
  --header 'X-API-KEY: <api-key>' \
  --data '{
  "agent_id": "string",
  "scenario_ids": [
    "string"
  ]
}'
{
  "_id": "<string>",
  "account_id": "<string>",
  "agent_id": "<string>",
  "scenario_ids": [
    "<string>"
  ],
  "info": {
    "num_trials": 123,
    "max_steps": 123,
    "max_errors": 123,
    "agent_info": {
      "agent_id": "<string>",
      "ai_settings": {
        "ai_model": "<string>",
        "frequency_penalty": 123,
        "max_tokens": 123,
        "presence_penalty": 123,
        "temperature": 123
      }
    },
    "simulated_lead_info": {
      "ai_settings": {
        "ai_model": "<string>",
        "frequency_penalty": 123,
        "max_tokens": 123,
        "presence_penalty": 123,
        "temperature": 123
      }
    }
  },
  "created_at": "2023-11-07T05:31:56Z",
  "completed_at": "2023-11-07T05:31:56Z",
  "total_runs": 123,
  "completed_runs": 0,
  "final_score": 123,
  "pass_hat_ks": {},
  "avg_agent_cost": 123
}

Authorizations

X-API-KEY
string
header
required

Body

application/json
agent_id
string
required

ID of the Agent to run the simulation on

Required string length: 24
scenario_ids
string[] | null
required

IDs of the simulation scenarios being run in this simulation. If not provided, all scenarios will be run.

simulated_lead_llm_args
object

The model to use for the user

num_trials
integer
default:1

The number of trials to run the simulation on.

Required range: 1 <= x <= 32
max_steps
integer
default:100

The maximum number of steps to run the simulation.

Required range: 1 <= x <= 5000
max_errors
integer
default:5

The maximum number of tool errors allowed in a row.

Required range: x >= 1

Response

Successful Response

The results of a simulation run

_id
string
required
account_id
string
required

Account ID that owns this simulation run

agent_id
string
required

ID of the Agent being simulated

scenario_ids
string[]
required

IDs of the Simulation Scenarios being run

info
object
required

Information.

total_runs
integer
required

The total number of simulation runs in this batch

created_at
string<date-time>
completed_at
string<date-time> | null

The end time of the simulation.

completed_runs
integer
default:0

The number of completed simulation runs

final_score
number | null

The final score of the simulation. Computed as the average reward over all scenarios.

pass_hat_ks
object | null

Average score in trial/pass k

avg_agent_cost
number | null

The average cost of the agent over all scenarios.