Python
import os
from scale_gp import SGPClient
client = SGPClient(
api_key=os.environ.get("SGP_API_KEY"), # This is the default and can be omitted
)
evaluation_metrics = client.evaluations.evaluation_metrics.retrieve(
"evaluation_id",
)
print(evaluation_metrics.evaluation_id)package main
import (
"context"
"fmt"
"github.com/stainless-sdks/sgp-go"
"github.com/stainless-sdks/sgp-go/option"
)
func main() {
client := sgp.NewClient(
option.WithAPIKey("My API Key"),
)
evaluationMetrics, err := client.Evaluations.EvaluationMetrics.Get(context.TODO(), "evaluation_id")
if err != nil {
panic(err.Error())
}
fmt.Printf("%+v\n", evaluationMetrics.EvaluationID)
}
curl --request GET \
--url https://api.egp.scale.com/v4/evaluations/{evaluation_id}/evaluation-metricsconst options = {method: 'GET'};
fetch('https://api.egp.scale.com/v4/evaluations/{evaluation_id}/evaluation-metrics', 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.egp.scale.com/v4/evaluations/{evaluation_id}/evaluation-metrics",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}HttpResponse<String> response = Unirest.get("https://api.egp.scale.com/v4/evaluations/{evaluation_id}/evaluation-metrics")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.egp.scale.com/v4/evaluations/{evaluation_id}/evaluation-metrics")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
response = http.request(request)
puts response.read_body{
"evaluation_id": "<string>",
"num_total_test_cases": 123,
"num_test_cases_labeled": 123,
"num_test_cases_flagged": 123,
"num_test_cases_fixed": 123,
"percentage_test_cases_fixed": 123,
"num_test_cases_unaudited": 123,
"percentage_test_cases_unaudited": 123,
"num_test_cases_approved": 123,
"percentage_test_cases_approved": 123,
"avg_labeling_time_per_test_case": 123,
"avg_num_test_cases_labeled_per_day": 123
}{
"detail": [
{
"loc": [
"<string>"
],
"msg": "<string>",
"type": "<string>",
"input": "<unknown>",
"ctx": {}
}
]
}Evaluations
Get Evaluation Metrics
GET
/
v4
/
evaluations
/
{evaluation_id}
/
evaluation-metrics
Python
import os
from scale_gp import SGPClient
client = SGPClient(
api_key=os.environ.get("SGP_API_KEY"), # This is the default and can be omitted
)
evaluation_metrics = client.evaluations.evaluation_metrics.retrieve(
"evaluation_id",
)
print(evaluation_metrics.evaluation_id)package main
import (
"context"
"fmt"
"github.com/stainless-sdks/sgp-go"
"github.com/stainless-sdks/sgp-go/option"
)
func main() {
client := sgp.NewClient(
option.WithAPIKey("My API Key"),
)
evaluationMetrics, err := client.Evaluations.EvaluationMetrics.Get(context.TODO(), "evaluation_id")
if err != nil {
panic(err.Error())
}
fmt.Printf("%+v\n", evaluationMetrics.EvaluationID)
}
curl --request GET \
--url https://api.egp.scale.com/v4/evaluations/{evaluation_id}/evaluation-metricsconst options = {method: 'GET'};
fetch('https://api.egp.scale.com/v4/evaluations/{evaluation_id}/evaluation-metrics', 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.egp.scale.com/v4/evaluations/{evaluation_id}/evaluation-metrics",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}HttpResponse<String> response = Unirest.get("https://api.egp.scale.com/v4/evaluations/{evaluation_id}/evaluation-metrics")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.egp.scale.com/v4/evaluations/{evaluation_id}/evaluation-metrics")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
response = http.request(request)
puts response.read_body{
"evaluation_id": "<string>",
"num_total_test_cases": 123,
"num_test_cases_labeled": 123,
"num_test_cases_flagged": 123,
"num_test_cases_fixed": 123,
"percentage_test_cases_fixed": 123,
"num_test_cases_unaudited": 123,
"percentage_test_cases_unaudited": 123,
"num_test_cases_approved": 123,
"percentage_test_cases_approved": 123,
"avg_labeling_time_per_test_case": 123,
"avg_num_test_cases_labeled_per_day": 123
}{
"detail": [
{
"loc": [
"<string>"
],
"msg": "<string>",
"type": "<string>",
"input": "<unknown>",
"ctx": {}
}
]
}Path Parameters
Response
Successful Response
The ID of the evaluation.
Total number of test cases.
Number of test cases labeled.
Number of test cases flagged.
Number of test cases fixed.
Percentage of test cases that were fixed.
Number of test cases unaudited.
Percentage of test cases that were unaudited.
Number of test cases approved.
Percentage of test cases that were approved.
Average time spent labeling per test case in seconds.
Average number of test cases labeled per day.

