Skip to main content

Eval APIs

Version: aju17f20mq

Use the reference below for request and response fields and operation-specific requirements.

Overview

Read traces and scores, curate datasets, and read evaluation runs. These are evaluation and observability operations.

Authentication​

Use an authorized backend sk_… key in X-API-Key; most evaluation operations do not need an end-user identity; record-score requires an attributable verified subject. A console JWT belongs to the separate console surface. See Authentication.

Projects​

Tenant context comes from the authenticated request. Client-supplied X-Tenant-Id, X-User-Id or X-Project-Id do not grant authority. The current public integration uses the default project. Do not rely on project headers for separate project, test/live or customer isolation on this API.

User IDs in read filters identify evaluated subjects; they do not assert the caller’s identity. Machine credentials do not establish a human reviewer. Reviewer attribution is taken from trusted caller context when available. HTTP 424 means evaluation is not provisioned for the selected scope. Contact your Travila operator; repeating the same request will not provision it.

Current API limits​

record-score currently maps numeric and boolean values and sends the resolved target as a trace ID. Categorical/text and observation/session/dataset-run scoring are not faithfully implemented despite their schema enum values. delete-score does not currently enforce per-author ownership. Restrict this API to trusted evaluation operators until those controls are qualified.

Pagination​

Cursor lists are list-traces, list-observations, list-scores, list-sessions and list-dataset-runs. Send pageSize, then the exact returned cursorPage.nextCursor as cursor. Continue after a short or empty page when that cursor is present. Other lists use one-based page/pageSize. Only trace lists can return an optional exact total; an unavailable total is not zero. Keep the same scope, filters and time window across pages. Old traces can lack entity tags.

Reading responses​

contentRedacted: true reports redaction, while its absence is not proof that content is verbatim or free of sensitive information.

Related guide: Measure and improve quality

Field naming​

Requests accept snake_case or camelCase field names; responses use camelCase. Ordinary default-valued scalars and empty repeated fields can be omitted. Explicitly present optional scalars, map values and well-known JSON types follow their own presence rules: an explicit false, 0 or empty value is not universally equivalent to absence. Decode each field according to its schema. 64-bit integers use JSON strings; preserve their precision. Unknown request fields are generally discarded before validation, so a typo can silently change behavior. This is not a guarantee that arbitrary fields or future client contracts are supported. See API conventions.

These examples use cursor pagination where indicated. Older API versions can use page numbers. Match your client to the API available to your account. To attribute a turn to a dataset run, set the experiment block on send-message or send-message-sync when the turn is sent; there is no operation that associates traces with a run after they have been recorded.

Traces​

Read the trace an LLM turn produced, and the observations inside it.

Sessions​

Group traces by session.

Scores​

Read scores and record numeric or boolean reviewer ratings on traces. Other target and value types are not currently supported for score writes.

Score configs​

Define the rating scales reviewers pick from.

Comments​

Free-text notes attached to a trace, observation or session.

Datasets​

Curate evaluation datasets and the items in them.

Dataset runs​

Record what a harness scored on a dataset, and read past runs back.

Annotation queues​

Queue items for human review and mark them done.

Overview​

Aggregate counts and score averages for a time window.

Server 1​

Travila API

https://api.travila.ai

X-API-Key​

Authorized tenant backend secret key (sk_…). Most evaluation operations do not need an end-user identity; record-score requires an attributable verified subject. Keep the key out of client apps; authorization and provisioning still apply.

Authentication credentials

SettingValue
Security scheme typeapiKey
header parameter nameX-API-Key

Operations​

Document ID: DOC-API-evals-overview. Section identities and revisions.

SectionStable reference
OverviewDOC-API-evals-overview#overview
AuthenticationDOC-API-evals-overview#authentication
ProjectsDOC-API-evals-overview#projects
Current API limitsDOC-API-evals-overview#current-adapter-limits
PaginationDOC-API-evals-overview#pagination
Reading responsesDOC-API-evals-overview#reading-responses
Field namingDOC-API-evals-overview#field-naming
TracesDOC-API-evals-overview#reference-group-1
SessionsDOC-API-evals-overview#reference-group-2
ScoresDOC-API-evals-overview#reference-group-3
Score configsDOC-API-evals-overview#reference-group-4
CommentsDOC-API-evals-overview#reference-group-5
DatasetsDOC-API-evals-overview#reference-group-6
Dataset runsDOC-API-evals-overview#reference-group-7
Annotation queuesDOC-API-evals-overview#reference-group-8
OverviewDOC-API-evals-overview#reference-group-9
Server 1DOC-API-evals-overview#reference-server-1
X-API-KeyDOC-API-evals-overview#authentication-apiKeyAuth