Criteria
Judge Criteria
Getting Started
Features
- Request Logs
- Datasets
- Fine Tuning
- Direct Preference Optimization (DPO)
- Evaluations
- Criteria
- Chat Completions
- Caching
- Updating Metadata Tags
- Pruning Rules
- Fallback
- Deployments
- External Models
API Reference
- Logs
- Chat Completions
- Datasets
- Models
- Criteria
Pricing
Criteria
Judge Criteria
Get a judgement of a completion against the specified criterion
POST
/
criteria
/
judge
curl --request POST \
--url https://api.openpipe.ai/api/v1/criteria/judge \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '{
"criterion_id": "<string>",
"input": {
"messages": [
{
"role": "system",
"content": "<string>",
"name": "<string>"
}
],
"tool_choice": "none",
"tools": [
{
"function": {
"name": "<string>",
"parameters": {},
"description": "<string>",
"strict": true
},
"type": "function"
}
]
},
"output": {
"reasoning_content": "<string>",
"content": null,
"refusal": "<string>",
"role": "assistant",
"function_call": {
"name": "",
"arguments": ""
},
"tool_calls": [
{
"id": "<string>",
"function": {
"name": "<string>",
"arguments": "<string>"
},
"type": "function"
}
]
}
}'
{
"score": 123,
"explanation": "<string>",
"usage": {
"total_tokens": 123
}
}
Authorizations
Bearer authentication header of the form Bearer <token>
, where <token>
is your auth token.
Body
application/json
Response
200
application/json
Successful response
The response is of type object
.
curl --request POST \
--url https://api.openpipe.ai/api/v1/criteria/judge \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '{
"criterion_id": "<string>",
"input": {
"messages": [
{
"role": "system",
"content": "<string>",
"name": "<string>"
}
],
"tool_choice": "none",
"tools": [
{
"function": {
"name": "<string>",
"parameters": {},
"description": "<string>",
"strict": true
},
"type": "function"
}
]
},
"output": {
"reasoning_content": "<string>",
"content": null,
"refusal": "<string>",
"role": "assistant",
"function_call": {
"name": "",
"arguments": ""
},
"tool_calls": [
{
"id": "<string>",
"function": {
"name": "<string>",
"arguments": "<string>"
},
"type": "function"
}
]
}
}'
{
"score": 123,
"explanation": "<string>",
"usage": {
"total_tokens": 123
}
}