curl --request POST \
--url https://api.arize.com/v2/evaluators \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"space_id": "U3BhY2U6NDkzOkJaSkc=",
"name": "Hallucination Eval",
"description": "Detects hallucinated content in LLM responses",
"type": "template",
"version": {
"commit_message": "Initial version",
"template_config": {
"name": "hallucination",
"template": "You are an evaluation assistant. Given the following input and output, determine if the output contains hallucinated content.\n\nInput: {input}\nOutput: {output}\nReference: {reference}",
"include_explanations": true,
"use_function_calling_if_available": true,
"classification_choices": {
"hallucinated": 0,
"factual": 1
},
"direction": "maximize",
"data_granularity": "span",
"llm_config": {
"ai_integration_id": "TGxtSW50ZWdyYXRpb246MTI6YUJjRA==",
"model_name": "gpt-4o",
"invocation_parameters": {
"temperature": 0
},
"provider_parameters": {}
}
}
}
}
'{
"id": "RXZhbHVhdG9yOjEyOmFCY0Q=",
"name": "Hallucination Eval",
"description": "Detects hallucinated content in LLM responses",
"type": "template",
"space_id": "U3BhY2U6NDkzOkJaSkc=",
"created_at": "2026-02-16T22:05:47.900Z",
"updated_at": "2026-02-16T22:05:48.150Z",
"created_by_user_id": "VXNlcjoxOm5OYkM=",
"version": {
"id": "RXZhbHVhdG9yVmVyc2lvbjoxMDpYeVp3",
"evaluator_id": "RXZhbHVhdG9yOjEyOmFCY0Q=",
"commit_hash": "a3b1c9e4f7d2a0518e6c3bb9217f87d1c4e810f2",
"commit_message": "Initial version",
"type": "template",
"template_config": {
"name": "hallucination",
"template": "You are an evaluation assistant...",
"include_explanations": true,
"use_function_calling_if_available": true,
"classification_choices": {
"hallucinated": 0,
"factual": 1
},
"direction": "maximize",
"data_granularity": "span",
"llm_config": {
"ai_integration_id": "TGxtSW50ZWdyYXRpb246MTI6YUJjRA==",
"model_name": "gpt-4o",
"invocation_parameters": {
"temperature": 0
},
"provider_parameters": {}
}
},
"created_at": "2026-02-16T22:05:48.143Z",
"created_by_user_id": "VXNlcjoxOm5OYkM="
}
}Creates a new evaluator with an initial version.
Payload Requirements
name must be unique within the given space.type (top-level) selects the evaluator kind: template or code.
With template, provide version.template_config.
With code, provide version.code_config — where code_config.type is managed or custom (a separate discriminator within code_config, independent of the top-level type: code).version.template_config.name is the eval column name; must match ^[a-zA-Z0-9_\s\-&()]+$.version.template_config.template is the prompt template; use {variable} for placeholders (f-string format, e.g. {input}, {output}).version.template_config.classification_choices maps choice labels to numeric scores (e.g. {"relevant": 1, "irrelevant": 0}). When omitted, the evaluator produces freeform output.CodeConfig — managed evaluators (code_config.type: managed) use managed_evaluator and variables; custom evaluators (code_config.type: custom) use code, optional imports, and variables.id, created_at, updated_at, created_by_user_id) are rejected on input.Valid example (template evaluator)
{
"name": "Hallucination Detector",
"space_id": "U3BhY2U6MTpWNEth",
"type": "template",
"version": {
"commit_message": "Initial version",
"template_config": {
"name": "hallucination",
"template": "Given the input: {input}\nand the output: {output}\nIs the output a hallucination?",
"include_explanations": true,
"use_function_calling_if_available": true,
"classification_choices": {"hallucinated": 0, "factual": 1},
"llm_config": {
"ai_integration_id": "TGxtSW50ZWdyYXRpb246MTI6YUJjRA==",
"model_name": "gpt-4o",
"invocation_parameters": {"temperature": 0},
"provider_parameters": {}
}
}
}
}
Invalid example (type/config mismatch — template type with code_config)
{
"name": "Bad Evaluator",
"space_id": "U3BhY2U6MTpWNEth",
"type": "template",
"version": {
"commit_message": "Wrong config",
"code_config": {
"type": "custom",
"name": "my_eval",
"code": "class Evaluator: ...",
"variables": ["input"]
}
}
}
curl --request POST \
--url https://api.arize.com/v2/evaluators \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"space_id": "U3BhY2U6NDkzOkJaSkc=",
"name": "Hallucination Eval",
"description": "Detects hallucinated content in LLM responses",
"type": "template",
"version": {
"commit_message": "Initial version",
"template_config": {
"name": "hallucination",
"template": "You are an evaluation assistant. Given the following input and output, determine if the output contains hallucinated content.\n\nInput: {input}\nOutput: {output}\nReference: {reference}",
"include_explanations": true,
"use_function_calling_if_available": true,
"classification_choices": {
"hallucinated": 0,
"factual": 1
},
"direction": "maximize",
"data_granularity": "span",
"llm_config": {
"ai_integration_id": "TGxtSW50ZWdyYXRpb246MTI6YUJjRA==",
"model_name": "gpt-4o",
"invocation_parameters": {
"temperature": 0
},
"provider_parameters": {}
}
}
}
}
'{
"id": "RXZhbHVhdG9yOjEyOmFCY0Q=",
"name": "Hallucination Eval",
"description": "Detects hallucinated content in LLM responses",
"type": "template",
"space_id": "U3BhY2U6NDkzOkJaSkc=",
"created_at": "2026-02-16T22:05:47.900Z",
"updated_at": "2026-02-16T22:05:48.150Z",
"created_by_user_id": "VXNlcjoxOm5OYkM=",
"version": {
"id": "RXZhbHVhdG9yVmVyc2lvbjoxMDpYeVp3",
"evaluator_id": "RXZhbHVhdG9yOjEyOmFCY0Q=",
"commit_hash": "a3b1c9e4f7d2a0518e6c3bb9217f87d1c4e810f2",
"commit_message": "Initial version",
"type": "template",
"template_config": {
"name": "hallucination",
"template": "You are an evaluation assistant...",
"include_explanations": true,
"use_function_calling_if_available": true,
"classification_choices": {
"hallucinated": 0,
"factual": 1
},
"direction": "maximize",
"data_granularity": "span",
"llm_config": {
"ai_integration_id": "TGxtSW50ZWdyYXRpb246MTI6YUJjRA==",
"model_name": "gpt-4o",
"invocation_parameters": {
"temperature": 0
},
"provider_parameters": {}
}
},
"created_at": "2026-02-16T22:05:48.143Z",
"created_by_user_id": "VXNlcjoxOm5OYkM="
}
}Documentation Index
Fetch the complete documentation index at: https://arize-ax.mintlify.dev/docs/llms.txt
Use this file to discover all available pages before exploring further.
Most Arize AI endpoints require authentication. For those endpoints that require authentication, include your API key in the request header using the format
Body containing evaluator creation parameters with an initial version
Space global ID (base64)
Evaluator name (must be unique within the space)
Evaluator type. Use template with version.template_config, or code
with version.code_config.
template, code Payload for an evaluator version: exactly one of template_config or code_config.
Used both when creating an evaluator (initial version) and when appending a version.
Show child attributes
Evaluator description
Returns the created evaluator with its initial version
An evaluator defines reusable evaluation logic that can be attached to evaluation tasks. The type field determines the kind of evaluation: template (LLM-based template evaluation) or code (custom code evaluation).
The unique identifier for the evaluator
The name of the evaluator
The evaluator type: template (LLM-based) or code (managed built-in
evaluators or custom Python code — both are subtypes of code,
discriminated by the nested CodeConfig.type = managed | custom).
Applies to both the parent Evaluator.type field and every version's type
discriminator — a version's type must always match its parent evaluator's type.
template, code The unique identifier for the space the evaluator belongs to
When the evaluator was created
When the evaluator was last updated
The unique identifier for the user who created the evaluator
The resolved version of the evaluator
Show child attributes
The description of the evaluator
Was this page helpful?
Suggestions