available, defaults.teacher_models and limits. Check available: a
catalogue of teacher names doesn’t mean the service is enabled.
1. Upload unlabelled queries
Save UTF-8 JSONL, one context per line. You can put decisions on each row, or give shared decisions when you start the job.id. A source holds up to 2,000 rows and 16 MiB, and each query asks up
to 64 decisions. Its input receipt records the uploaded bytes and hash.
Every row must define a decision ID the same way, whether it has its own decisions or uses the
shared ones. A job whose rows differ is refused with conflicting_decision before it is created,
and nothing is charged.
Teacher labelling sends the selected queries to the teacher model’s provider. Choose data that
suits that.
2. Start a job
SetSQWISH_SOURCE_ID to the source’s ID, and SQWISH_TEACHER_ID to a teacher ID from
/v1/labeling/teachers:
teacher_models names one or two different teachers. Left out, it is defaults.teacher_models.
A job costs each of its teachers’ price for every row of its source. pricing.teacher_row_usd in
/v1/onehot gives the price for a row.
- The job’s
price_usdis held while it runs. It is charged once the labels are ready for review. - A job that fails or is cancelled before then costs nothing.
- Send the price you were shown as
max_price_usd(USD amounts). A job that would cost more gets409 price_changed.
/v1/labeling/jobs/{job_id}:
3. Review and finalise
Once the job isreview_ready, read /v1/labeling/jobs/{job_id}/results page by page, up to 200
rows a page. Before that, and for a job that failed or was cancelled, it answers
409 review_required.
Each result has its source index, context, decisions, teacher labels, valid and agreement.
valid means the teachers returned labels in the expected shape. agreement means they chose the
same labels. Neither replaces your review.
For valid rows, targets averages the teachers’ one-hot votes. Inspect disagreements and
systematic mistakes against your labelling rules. Invalid rows can’t be finalised.
Set SQWISH_LABEL_JOB_ID to your job’s ID. After reviewing and accepting rows 0 and 1:
finalized. A different selection later conflicts. When the reviewed selection must
change, start another job.
Choose the evaluation rows
Finalising also takesevaluation_fraction, from 0.1 to 1. It is 0.2 by default. The console
offers the same choice before you finalise.
- A mixed dataset needs at least two selected rows, with distinct contexts for training and evaluation.
- At
1the dataset is evaluation only, and a single reviewed context is enough. - To choose each row’s side yourself, send
training_indicesandevaluation_indicesin place ofrow_indices. They work like a dataset’strainingandevaluationparts (choose the evaluation set).
Discard or delete
A dataset you finalised from a source stays when you delete the source. Delete that dataset
separately.
