evaluators

Get evaluator spend

Changed on

Returns per-day LLM evaluator spend for the requested 7-day period, grouped by evaluator, resource, or run rule. Exactly one of group_by, evaluator_id, session_id, or dataset_id is required. resource_id, type, feedback_key, tag_value_id, and agent_id may be supplied with group_by to narrow listing aggregations.

get/api/v1/platform/evaluators/spend

Request

  • Base URL
    https://api.smith.langchain.com
  • URL
    https://api.smith.langchain.com/api/v1/platform/evaluators/spend
  • Auth
    • API key in header X-API-Key
    • or API key in header X-Tenant-Id
    • or HTTP bearer

Query parameters

group_bystring

Aggregation mode: 'evaluator', 'resource', or 'run_rule'. Mutually exclusive with entity filters.

evaluator_idstring

Filter to a specific evaluator (UUID). Mutually exclusive with group_by.

session_idstring

Filter to a specific project (UUID). Mutually exclusive with group_by.

dataset_idstring

Filter to a specific dataset (UUID). Mutually exclusive with group_by.

resource_idstring[]

Filter grouped results to evaluators attached to all supplied project or dataset IDs. Only valid with group_by.

typestring

Filter grouped results by evaluator type: 'llm', 'code' or 'decision_model'. Only valid with group_by.

feedback_keystring

Filter grouped results by evaluator feedback key. Only valid with group_by.

tag_value_idstring[]

Filter grouped results to evaluators, projects, or datasets tagged with all supplied tag value IDs. Only valid with group_by.

agent_idstring

Filter grouped results to spend from evaluator attachments on the agent's environments or tagged datasets. Only valid with group_by.

period_startstring required

Start of the 7-day window (YYYY-MM-DD).

Response

OK

period_endstring
period_startstring

Changes