curl --request GET \
--url https://api.galtea.ai/evaluations \
--header 'Authorization: Bearer <token>'import requests
url = "https://api.galtea.ai/evaluations"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://api.galtea.ai/evaluations', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.galtea.ai/evaluations",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.galtea.ai/evaluations"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Authorization", "Bearer <token>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://api.galtea.ai/evaluations")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.galtea.ai/evaluations")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_body[
{
"id": "eval_123",
"metricId": "metric_123",
"sessionId": "session_123",
"productId": "product_123",
"userId": "user_123",
"status": "SUCCESS",
"inferenceResultId": "ir_123",
"score": 0.95,
"reason": "High quality response",
"error": "<string>",
"canRetry": false,
"creditsUsed": 1,
"judgeInputTokens": 4100,
"judgeOutputTokens": 16800,
"judgeReasoningTokens": 12400,
"judgeTraceChars": 5000000,
"judgeTraceBudgetChars": 120000,
"judgeTraceSentChars": 119950,
"conversationSimulatorVersion": "1.0.0",
"humanEvaluatorId": "<string>",
"humanEvaluatorStartedAt": "2023-11-07T05:31:56Z",
"humanScore": 123,
"humanReason": "<string>",
"humanEvaluatorFinishedAt": "2023-11-07T05:31:56Z",
"failedTurns": [
"<string>"
],
"monitorId": "<string>",
"monitorSettledAtTurn": 123,
"monitorSamplingPercentage": 123,
"runId": "<string>",
"deletedAt": "2023-11-07T05:31:56Z",
"evaluatedAt": "2023-11-07T05:31:56Z",
"metricLegacyAt": "2023-11-07T05:31:56Z",
"passed": true,
"metricPassThreshold": 0.5,
"metricDisabledAt": "2023-11-07T05:31:56Z",
"metricExcludedFromAnalyticsAt": "2023-11-07T05:31:56Z",
"metricExcludedByUserId": "<string>",
"testCaseLegacyAt": "2023-11-07T05:31:56Z",
"scoreBreakdown": {
"version": 123,
"model": "<string>",
"type": "yes_no",
"value": 123,
"confidence": 123,
"pYes": 0.5,
"goodAnswer": "yes",
"probabilities": {},
"levelScores": [
123
],
"doesNotApply": true
},
"confidence": 0.9,
"dataRegion": "EU",
"longInput": true,
"createdAt": "2023-11-07T05:31:56Z",
"metricRevisionNumber": 3,
"metricRevisionName": "<string>"
}
]{
"error": "NotFound",
"message": "Product not found"
}{
"error": "NotFound",
"message": "Product not found"
}Get evaluations
Get list of evaluations with pagination and filtering. See Evaluations.
curl --request GET \
--url https://api.galtea.ai/evaluations \
--header 'Authorization: Bearer <token>'import requests
url = "https://api.galtea.ai/evaluations"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://api.galtea.ai/evaluations', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.galtea.ai/evaluations",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.galtea.ai/evaluations"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Authorization", "Bearer <token>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://api.galtea.ai/evaluations")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.galtea.ai/evaluations")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_body[
{
"id": "eval_123",
"metricId": "metric_123",
"sessionId": "session_123",
"productId": "product_123",
"userId": "user_123",
"status": "SUCCESS",
"inferenceResultId": "ir_123",
"score": 0.95,
"reason": "High quality response",
"error": "<string>",
"canRetry": false,
"creditsUsed": 1,
"judgeInputTokens": 4100,
"judgeOutputTokens": 16800,
"judgeReasoningTokens": 12400,
"judgeTraceChars": 5000000,
"judgeTraceBudgetChars": 120000,
"judgeTraceSentChars": 119950,
"conversationSimulatorVersion": "1.0.0",
"humanEvaluatorId": "<string>",
"humanEvaluatorStartedAt": "2023-11-07T05:31:56Z",
"humanScore": 123,
"humanReason": "<string>",
"humanEvaluatorFinishedAt": "2023-11-07T05:31:56Z",
"failedTurns": [
"<string>"
],
"monitorId": "<string>",
"monitorSettledAtTurn": 123,
"monitorSamplingPercentage": 123,
"runId": "<string>",
"deletedAt": "2023-11-07T05:31:56Z",
"evaluatedAt": "2023-11-07T05:31:56Z",
"metricLegacyAt": "2023-11-07T05:31:56Z",
"passed": true,
"metricPassThreshold": 0.5,
"metricDisabledAt": "2023-11-07T05:31:56Z",
"metricExcludedFromAnalyticsAt": "2023-11-07T05:31:56Z",
"metricExcludedByUserId": "<string>",
"testCaseLegacyAt": "2023-11-07T05:31:56Z",
"scoreBreakdown": {
"version": 123,
"model": "<string>",
"type": "yes_no",
"value": 123,
"confidence": 123,
"pYes": 0.5,
"goodAnswer": "yes",
"probabilities": {},
"levelScores": [
123
],
"doesNotApply": true
},
"confidence": 0.9,
"dataRegion": "EU",
"longInput": true,
"createdAt": "2023-11-07T05:31:56Z",
"metricRevisionNumber": 3,
"metricRevisionName": "<string>"
}
]{
"error": "NotFound",
"message": "Product not found"
}{
"error": "NotFound",
"message": "Product not found"
}Authorizations
Query Parameters
Filter by monitor alert IDs (returns only the evaluations of the sessions the alert linked when it opened (its bad sessions, or its sessions with no score), made by the alert's monitor, on the alert's metric family, or on the families a Specification alert measured when it opened). At most 10 IDs.
10Sort instructions (field and direction pairs). Sorting by confidence puts evaluations with no confidence last in both directions. Sorting by agreement orders by the agreement of the judge score with the reported human score, and puts evaluations with no agreement (no judge score or no human score) last in both directions. Sorting by humanScore, humanEvaluatorId or humanEvaluatorFinishedAt orders by the value each evaluation reports: the case annotation on an AI-judged metric, the evaluation itself on a HUMAN_EVALUATION one. Evaluations with no such value come last ascending and first descending, and ties go by id. A caller gets 400 for a sort on a field it sees as null on any product the list reaches (evaluation.readInference).
Keep evaluations whose agreement with the human review is greater than this value (0 to 1). Agreement is 1 minus the distance between the judge score and the human score, so 1 means the same score. An evaluation with no judge score or no human score never matches. A value outside 0 to 1 returns 400.
Keep evaluations whose agreement with the human review is greater than or equal to this value (0 to 1). Agreement is 1 minus the distance between the judge score and the human score, so 1 means the same score. An evaluation with no judge score or no human score never matches. A value outside 0 to 1 returns 400.
Keep evaluations whose agreement with the human review is less than this value (0 to 1). Agreement is 1 minus the distance between the judge score and the human score, so 1 means the same score. An evaluation with no judge score or no human score never matches. A value outside 0 to 1 returns 400.
Keep evaluations whose agreement with the human review is less than or equal to this value (0 to 1). Agreement is 1 minus the distance between the judge score and the human score, so 1 means the same score. An evaluation with no judge score or no human score never matches. A value outside 0 to 1 returns 400.
Response
Evaluations retrieved successfully