Data models

Response and model types returned by the AnnotationQueue SDK.

All data models are importable from the SDK and work with IDE autocomplete:

from fi.queues import (
    AnnotationLabel, QueueDetail, QueueItem, Score,
    QueueProgress, QueueAnalytics, QueueAgreement,
    AddItemsResponse, ExportToDatasetResponse, ImportAnnotationsResponse,
)

AnnotationLabel

FieldTypeDescription
idstrLabel UUID
namestrLabel name
typestrLabel type (categorical, text, numeric, star, thumbs_up_down)
descriptionOptional[str]Label description
settingsOptional[Dict[str, Any]]Type-specific configuration (see Label Settings by Type)

QueueDetail

FieldTypeDescription
idstrQueue UUID
namestrQueue name
descriptionOptional[str]Queue description
instructionsOptional[str]Annotator instructions
statusOptional[str]Queue status (draft, active, paused, completed)
assignment_strategyOptional[str]Assignment strategy (manual, round_robin, load_balanced)
annotations_requiredOptional[int]Annotations needed per item
reservation_timeout_minutesOptional[int]Reservation timeout in minutes
requires_reviewOptional[bool]Whether review is required
created_atOptional[str]Creation timestamp
updated_atOptional[str]Last update timestamp
item_countOptional[int]Total items in queue
completed_countOptional[int]Completed items count

QueueItem

FieldTypeDescription
idstrItem UUID
source_typeOptional[str]Source entity type
source_idOptional[str]Source entity UUID
statusOptional[str]Item status (pending, in_progress, completed)
orderOptional[int]Item order in queue
assigned_toOptional[str]Assigned user ID
created_atOptional[str]Creation timestamp

Score

FieldTypeDescription
idOptional[str]Score UUID
label_idOptional[str]Label UUID
label_nameOptional[str]Label display name
valueOptional[Any]Annotation value
score_sourceOptional[str]Origin (human, api, auto, imported)
notesOptional[str]Free-text notes
annotator_idOptional[str]Annotator user ID
annotator_nameOptional[str]Annotator display name
source_typeOptional[str]Source entity type
source_idOptional[str]Source entity UUID
created_atOptional[str]Creation timestamp

QueueProgress

FieldTypeDescription
totalintTotal items
pendingintPending items
in_progressintIn-progress items
completedintCompleted items
skippedintSkipped items
progress_pctOptional[float]Completion percentage
annotator_statsOptional[List[Dict]]Per-annotator statistics

QueueAnalytics

FieldTypeDescription
throughputOptional[Dict]Throughput metrics — contains daily (list of {"date", "count"} entries for the last 30 days), total_completed (int), and avg_per_day (float)
annotator_performanceOptional[List[Dict]]Per-annotator performance — each entry has user_id, name, completed, and last_active
label_distributionOptional[Dict]Distribution of annotations across labels — keyed by label ID, each with name, type, and values (value-to-count mapping)
status_breakdownOptional[Dict[str, int]]Item count by status (e.g. {"pending": 5, "completed": 10})
totalOptional[int]Total items in the queue

QueueAgreement

FieldTypeDescription
overall_agreementOptional[float]Overall agreement percentage
per_labelOptional[List[Dict]]Agreement broken down by label
annotator_pairsOptional[List[Dict]]Pairwise annotator agreement

AddItemsResponse

FieldTypeDescription
addedintNumber of items added
duplicatesintNumber of duplicate items skipped
errorsOptional[List[Dict]]Any errors encountered

ExportToDatasetResponse

FieldTypeDescription
dataset_idOptional[str]Dataset UUID
dataset_nameOptional[str]Dataset name
rows_createdOptional[int]Number of rows created

ImportAnnotationsResponse

FieldTypeDescription
importedintNumber of annotations imported
Was this page helpful?

Questions & Discussion