Skip to main content

Synthetic data

Preview

Describe the data you need in plain English. Autessa generates realistic, varied rows that match your columns, with invalid and duplicate rows removed.

When to use it​

  • You need test data for an app, a demo, or a load test, without real customer data.
  • You need many example conversations or records to test an agent or a classifier.
  • You want a dataset file (JSONL or CSV) to train or evaluate a model.

Quickstart​

  1. Get a free API key. New accounts get $100 of free credits for your first month, no card needed.
  2. Optional: send a description to POST /clients/synthetic-data/schema/propose to get suggested columns.
  3. Send the description, columns, and a row count to POST /clients/synthetic-data/generate.
curl -X POST https://api.autessa.com/clients/synthetic-data/generate \
-H "Authorization: $AUTESSA_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"description": "Support tickets for an online shoe store. Mix of returns, sizing, and late deliveries.",
"rowCount": 10,
"columnDefinitions": [
{"columnName": "subject", "columnType": "SHORT_TEXT"},
{"columnName": "body", "columnType": "LONG_TEXT"},
{"columnName": "priority", "columnType": "SINGLE_SELECT", "allowedValues": ["low", "normal", "urgent"]}
]
}'

The response has rows (each maps column name to value), rowCount, and rejectedRowCount. Nothing is stored.

Larger sets: background jobs​

  1. POST /clients/synthetic-data/jobs with name, description, rowCount, columnDefinitions, targetType: "DATASET_FILE", and fileFormat (JSONL or CSV). You get a jobId.
  2. Poll GET /clients/synthetic-data/jobs/{jobId} for status and progressPct.
  3. GET /clients/synthetic-data/jobs/{jobId}/export returns a downloadUrl for the file.

Set writeMode: "REVIEW" to look at staged rows first (/preview), then /approve or /discard.

How it works​

  • It writes rows in batches and checks each row against your column types and allowed values.
  • It tracks what it has already written, so later batches stay varied instead of repeating.
  • It drops invalid and duplicate rows and tries again to reach your count.
  • sampleRowsJson (a JSON array as a string) gives it example rows to match in style.

Column types: SHORT_TEXT, LONG_TEXT, INTEGER, FLOAT, BOOLEAN, SINGLE_SELECT, MULTI_SELECT, DATETIME. Add a columnComment to say what a column holds.

The synth package​

The synth package wraps this API in TypeScript (@autessa/synth), Python (autessa-synth) and Java (com.autessa:autessa-synth). It needs only the core package, and reads AUTESSA_API_KEY.

  • Python: pip install "autessa-synth @ git+https://github.com/Autessa-Inc/autessa-python#subdirectory=packages/autessa-synth" (install autessa-core the same way first). After release: pip install autessa-synth.
  • TypeScript: after release, npm install @autessa/synth. During the preview, build it from the autessa-js repository as its README describes.
  • Java: the com.autessa:autessa-synth artifact, plus autessa-spring-boot-starter for Spring Boot. During the preview, build autessa-java from source first.

Propose a schema, then generate rows​

import { Synth } from "@autessa/synth";

const synth = new Synth();
const { schema } = await synth.proposeSchema({ description: "support tickets for a bike shop" });
const { rows } = await synth.generate({
description: "support tickets for a bike shop",
columns: schema.columnDefinitions,
rowCount: 20,
});
console.log(rows[0]);

Many rows: jobs, review and export​

A job runs in the background and writes a dataset file (JSONL or CSV). With an API key, jobs always write files. With writeMode: "REVIEW", it stops at AWAITING_REVIEW so you can look at a batch, drop rows, and approve.

const jobId = await synth.createJob({
name: "tickets", description: "support tickets", rowCount: 5000,
fileFormat: "JSONL", writeMode: "REVIEW",
});
await synth.waitForJob(jobId); // stops at AWAITING_REVIEW, or when finished
const { rows, batchId } = await synth.preview(jobId);
await synth.excludeRows(jobId, batchId!, [3, 7]);
await synth.approve(jobId);
await synth.waitForJob(jobId);
const { downloadUrl } = await synth.export(jobId);
CallWhat it does
proposeSchemaSuggested columns for a description.
generateA small set of rows right away.
createJob, getJob, listJobs, waitForJobMany rows in the background.
preview, approve, discard, cancelReview a staged batch, then keep it, throw it away, or stop the job.
append, excludeRows, regenerateBatchAdd rows, drop rows, or redo a batch before approving.
exportA download link for the job's file.

Python uses snake_case (propose_schema, wait_for_job, ...) and has AsyncSynth.

Use the rows in evals and tests​

Two helpers turn rows into plain data, so the synth package doesn't depend on any other Autessa package:

  • toEvalCases(rows, mapping) makes one grading case per row, in the shape Evaluations grade takes.
  • toSeed(rows) makes rows for a local test's seed: block, or for table(x).seed(...) in the CDK's offline tests.
import { toEvalCases, toSeed } from "@autessa/synth";

const cases = toEvalCases(rows, { user: "question", expectedOutcome: "expected", agentInstructions: "You help with orders." });
const seed = toSeed(rows, ["orderId", "status"]);

Limits​

  • /generate is for small sets. Use a job for more rows.
  • Each job has a maximum row count. The API tells you if a request is over it.
  • With an API key, jobs write files. To fill an AutessaDB table, use the Builder.
  • Usage is billed to your company. See Billing.

API reference​

Synthetic Data API

Benchmarks​

None for synthetic data. See Benchmarks for what we publish.