with one click
adaline-evaluators
// Create and manage evaluators in Adaline to score prompt outputs. Use when setting up LLM-as-a-judge, JavaScript, text-matcher, cost, latency, or response-length evaluators.
// Create and manage evaluators in Adaline to score prompt outputs. Use when setting up LLM-as-a-judge, JavaScript, text-matcher, cost, latency, or response-length evaluators.
Create and manage evaluation datasets in Adaline. Use when building test cases, adding dataset columns/rows, importing data, or triggering dynamic columns.
Fetch deployed prompt snapshots from Adaline at runtime. Use when integrating prompt deployments, environment-based latest lookups, prompt caching, or pinned deployment IDs.
Run and manage evaluations in Adaline to test prompt quality at scale. Use when creating evaluation runs, polling status, analyzing results, or cancelling runs.
High-level guide for integrating your AI application with Adaline. Use when starting a new Adaline integration, choosing between API/SDK approaches, or planning which Adaline features to adopt.
Send traces and spans to Adaline for AI agent observability. Use when instrumenting LLM calls, tools, retrieval, embeddings, guardrails, or custom operations.
Create and manage prompts in Adaline via the v2 API or SDK clients. Use when programmatically creating prompts, updating prompt drafts, listing prompts, or reading prompt/playground data.
| name | adaline-evaluators |
| description | Create and manage evaluators in Adaline to score prompt outputs. Use when setting up LLM-as-a-judge, JavaScript, text-matcher, cost, latency, or response-length evaluators. |
Evaluators define how Adaline scores prompt outputs. Each evaluator is attached to a prompt and dataset. Evaluation runs use an evaluator to produce per-row grades, scores, reasons, and aggregate metrics.
Key terms:
typeactive or archivedSet these environment variables when credentials are available:
ADALINE_API_KEY — workspace API key from Admin > API KeysADALINE_PROJECT_ID — project IDADALINE_PROMPT_ID — prompt to attach evaluators toADALINE_DATASET_ID — dataset for evaluator runsBase URL: https://api.adaline.ai/v2
{
"type": "llm-as-a-judge",
"value": "Pass only if the response answers the question and all factual claims are grounded in the reference answer."
}
{
"type": "javascript",
"value": "const parsed = JSON.parse(output); return parsed.answer ? 'pass' : 'fail';"
}
{
"type": "text-matcher",
"value": {
"operator": "contains-all",
"value": ["Summary", "Recommendation"]
}
}
Operators: regex, equals, starts-with, ends-with, contains-all, contains-any, not-contains-any.
These evaluator types use a comparison rule directly as value:
{
"type": "latency",
"value": {
"value": 2000,
"unit": "ms",
"operator": "less"
}
}
Operators: less, greater, equals.
| Symptom | Fix |
|---|---|
API rejects group | Remove it; current config is discriminated by type only |
| Text matcher rejected | Use value.operator and value.value, not pattern / patterns |
| Cost/latency rejected | Use comparison rule directly as config.value, not nested under threshold |
| List response lacks config | List returns lightweight summaries; call GET evaluator for full config |
| Evaluation needs multiple evaluators | Create one evaluation run per evaluatorId |
curl -X POST "https://api.adaline.ai/v2/prompts/$ADALINE_PROMPT_ID/evaluators" \
-H "Authorization: Bearer $ADALINE_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"projectId": "project_abc123",
"title": "Factual accuracy",
"datasetId": "dataset_abc123",
"config": {
"type": "llm-as-a-judge",
"value": "Pass only if the answer is accurate and cites the provided context."
}
}'
await adaline.prompts.evaluators.list({ promptId, limit: 20 });
await adaline.prompts.evaluators.create({ promptId, evaluator });
await adaline.prompts.evaluators.get({ promptId, evaluatorId });
await adaline.prompts.evaluators.update({ promptId, evaluatorId, evaluator: { title: 'Updated' } });
await adaline.prompts.evaluators.delete({ promptId, evaluatorId });
await adaline.prompts.evaluators.list(prompt_id=prompt_id, limit=20)
await adaline.prompts.evaluators.create(prompt_id=prompt_id, evaluator=evaluator)
await adaline.prompts.evaluators.get(prompt_id=prompt_id, evaluator_id=evaluator_id)
await adaline.prompts.evaluators.update(prompt_id=prompt_id, evaluator_id=evaluator_id, evaluator=patch)
await adaline.prompts.evaluators.delete(prompt_id=prompt_id, evaluator_id=evaluator_id)
See references/api.md for the full REST contract with all config shapes.