Python
import os
from dataframer import Dataframer
client = Dataframer(
api_key=os.environ.get("DATAFRAMER_API_KEY"), # This is the default and can be omitted
)
evaluation = client.dataframer.evaluations.retrieve(
"182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e",
)
print(evaluation.id)curl https://df-api.dataframer.ai/api/dataframer/evaluations/$EVALUATION_ID/ \
-H "Authorization: Bearer $DATAFRAMER_API_KEY"{
"id": "f4e64db3-3cac-4706-9fd0-c6695ae4694a",
"run_id": "a98715da-921d-4326-bbf8-208f8bcc2956",
"status": "SUCCEEDED",
"distribution_analysis": [
{
"property_name": "sentiment",
"total_samples": 100,
"requested_distributions": {
"positive": 40,
"negative": 30,
"neutral": 30
},
"expected_distributions": {
"positive": 42,
"negative": 30,
"neutral": 28
},
"evaluated_distributions": {
"positive": 45,
"negative": 28,
"neutral": 27
},
"total_samples_analyzed": 100
}
],
"sample_classifications": [
{
"id": "ad7913d9-a0aa-4a80-83a7-70026e3c1f1d",
"evaluation_id": "f4e64db3-3cac-4706-9fd0-c6695ae4694a",
"sample_identifier": "sample_1",
"classifications": {
"sentiment": "positive",
"topic": "technology"
},
"created_at": "2025-01-15T10:30:00Z"
}
],
"completed_at": "2025-01-15T10:31:00Z",
"error_message": null,
"created_by_email": "user@example.com",
"created_at": "2025-01-15T10:30:00Z"
}
Evaluations
Get evaluation
Retrieve full evaluation details including distribution analysis
GET
/
api
/
dataframer
/
evaluations
/
{evaluation_id}
/
Python
import os
from dataframer import Dataframer
client = Dataframer(
api_key=os.environ.get("DATAFRAMER_API_KEY"), # This is the default and can be omitted
)
evaluation = client.dataframer.evaluations.retrieve(
"182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e",
)
print(evaluation.id)curl https://df-api.dataframer.ai/api/dataframer/evaluations/$EVALUATION_ID/ \
-H "Authorization: Bearer $DATAFRAMER_API_KEY"{
"id": "f4e64db3-3cac-4706-9fd0-c6695ae4694a",
"run_id": "a98715da-921d-4326-bbf8-208f8bcc2956",
"status": "SUCCEEDED",
"distribution_analysis": [
{
"property_name": "sentiment",
"total_samples": 100,
"requested_distributions": {
"positive": 40,
"negative": 30,
"neutral": 30
},
"expected_distributions": {
"positive": 42,
"negative": 30,
"neutral": 28
},
"evaluated_distributions": {
"positive": 45,
"negative": 28,
"neutral": 27
},
"total_samples_analyzed": 100
}
],
"sample_classifications": [
{
"id": "ad7913d9-a0aa-4a80-83a7-70026e3c1f1d",
"evaluation_id": "f4e64db3-3cac-4706-9fd0-c6695ae4694a",
"sample_identifier": "sample_1",
"classifications": {
"sentiment": "positive",
"topic": "technology"
},
"created_at": "2025-01-15T10:30:00Z"
}
],
"completed_at": "2025-01-15T10:31:00Z",
"error_message": null,
"created_by_email": "user@example.com",
"created_at": "2025-01-15T10:30:00Z"
}
Use this endpoint to poll for evaluation completion and retrieve results.
When an evaluation completes successfully, the response includes:
- conformance_score: Overall score (0-100) measuring how well samples match expected distributions
- distribution_analysis: Per-property comparison of expected vs observed percentages
- sample_classifications: How each generated sample was classified for each property
Authorizations
API Key authentication. Format: "Bearer YOUR_API_KEY"
Path Parameters
Unique identifier of the evaluation
Response
Evaluation details, including distribution analysis and sample classifications
Unique identifier for the evaluation
ID of the run being evaluated
Current status of the evaluation
Available options:
PENDING, PROCESSING, SUCCEEDED, FAILED Per-property comparison of expected vs observed distributions. Null until evaluation completes.
Show child attributes
Show child attributes
Classification results for each generated sample. Empty until evaluation completes.
Show child attributes
Show child attributes
When evaluation completed
Error message if evaluation failed
Email of the user who created the evaluation
When the evaluation was created

