arize-annotation

Creates and manages annotation configs (categorical, continuous, freeform label schemas) and annotation queues (human review workflows) on Arize. Applies human annotations to project spans via the Python SDK. Use when the user mentions annotation config, annotation queue, label schema, human feedbac

By arize-ai · 2,485 installs

npx skills add arize-ai/arize-skills --skill arize-annotation

Source repository · Upstream listing

Arize Annotation Skill SPACE — space flags accept a space name (e.g., my workspace ) or a base64 space ID (e.g., U3BhY2U6... ). Find yours with ax spaces list . This skill covers annotation configs (the label schema) and annotation queues (human review workflows), as well as programmatically annotating project spans via the Python SDK. Direction: Human labeling in Arize attaches values defined by configs to spans , dataset examples , experiment related records , and queue items in the product UI. This skill covers: ax annotation configs , ax annotation queues , and bulk span updates with ArizeClient.spans.update annotations . Prerequisites Proceed directly with the task — run the ax command you need. Do NOT check versions, env vars, or profiles upfront. If an ax command fails, troubleshoot based on the error: command not found or version error → see [references/ax setup.md](references/ax setup.md) 401 Unauthorized / missing API key → run ax profiles show to inspect the current profile. If the profile is missing or the API key is wrong, follow [references/ax profiles.md](references/ax profiles.md) to create/update it. If the user doesn't have their key, direct them to https://app.arize.com/admin API Keys Space unknown → run ax spaces list to pick by name, or ask the user Security: Never read .env files or search the filesystem for credentials. Use ax profiles for Arize credentials and ax ai integrations for LLM provider keys. Never ask the user to paste secrets into chat. For missing credentials, see [references/ax profiles.md](references/ax profiles.md). Concepts What is an Annotation Config? An annotation config defines the schema for a single type of human feedback label. Before anyone can annotate a span, dataset record, experiment output, or queue item, a config must exist for that label in the space. Field Description Name Descriptive identifier (e.g. Correctness , Helpfulness ). Must be unique within the space. Type CATEGORICAL (pick from a list), CONTINUOUS (numeric range), or FREEFORM (free text). Values For categorical: array of {"label": str, "score": number} pairs. Min/Max Score For continuous: numeric bounds. Optimization Direction Whether higher scores are better ( MINIMIZE ) or worse ( MAXIMIZE ). Used to render trends in the UI. Where labels get applied (surfaces) Surface Typical path Project spans Python SDK spans.update annotations (below) and/or the Arize UI Dataset examples Arize UI (human labeling flows); configs must exist in the space Experiment outputs Often reviewed alongside datasets or traces in the UI — see arize experiment, arize dataset Annotation queue items ax annotation queues CLI (below) and/or the Arize UI; configs must exist Always ensure the relevant annotation config exists in the space before expecting labels to persist. Basic CRUD: Annotation Configs List Create — Categorical Categorical configs present a fixed set of labels for reviewers to choose from. Common binary label pairs: correct / incorrect helpful / unhelpful safe / unsafe relevant / irrelevant pass / fail Create — Continuous Continuous configs let reviewers enter a numeric score within a defined range. Create — Freeform Freeform configs collect open ended text feedback. No additional flags needed beyond name and space. Get Update Each config type has its own update command. Only changed fields are updated. Freeform: Continuous: Categorical: space is required when using a name instead of ID. Each value supplies the complete categorical label list: it replaces existing labels rather than appending to them. Repeat value for every label that should remain, or omitted labels are removed. Delete Note: Deletion is irreversible. Any annotation queue associations to this config are also removed in the product (queues may remain; fix associations in the Arize UI if needed). Annotation Queues: ax annotation queues Annotation queues route records (spans, dataset examples, experiment runs) to human reviewers. Each queue is linked to one or more annotation configs that define what labels reviewers can apply. List / Get Create At least one annotation config id is required. Repeat annotation config id and annotator email to attach multiple configs or reviewers. Add Records Add records to an existing queue after creation. Records can come from spans (by project and time range) or dataset examples. record sources is required and accepts a JSON file path or inline JSON array. Each source specifies record type ( SPAN or EXAMPLE ) plus type specific fields: Span: project id , start time (ISO 8601), end time (ISO 8601), optional span ids Example: dataset id , example ids Update List flags ( annotation config id , annotator email ) fully replace existing values when provided — pass all desired values, not just the new ones. Delete List Records Submit an Annotation for a Record Annotations are upserted by config name — call once per annotation config. Supply at least one of score , label , or text . Assign a Record Assign users to review a specific record by repeating email ; this fully replaces existing assignments, so pass every assignee each time (passing no email flags clears all assignments): Delete Records Applying Annotations to Spans (Python SDK) Use the Python SDK to bulk apply annotations to project spans when you already have labels (e.g., from a review export or an external labeling tool). DataFrame column schema: Column Required Description context.span id yes The span to annotate annotation.<name .label one of Categorical or freeform label annotation.<name .score one of Numeric score annotation.<name .updated by no Annotator identifier (email or name) annotation.<name .updated at no Timestamp in milliseconds since epoch annotation.notes no Freeform notes on the span Limitation: Annotations apply only to spans within 31 days prior to submission. Troubleshooting Problem Solution ax: command not found See [references/ax setup.md](references/ax setup.md) 401 Unauthorized API key may not have access to this space. Verify at https://app.arize.com/admin API Keys Annotation config not found ax annotation configs list space SPACE (or use ax annotation configs get NAME OR ID space SPACE ) 409 Conflict on create Name already exists in the space. Use a different name or get the existing config ID. Queue not found ax annotation queues list space SPACE ; verify the queue name or ID Record not appearing in queue Ensure the annotation config linked to the queue exists; check ax annotation configs list space SPACE Span SDK errors or missing spans Confirm project name , space id , and span IDs; use arize trace to export spans Batch Annotate via CLI The ax CLI provides batch annotation commands for writing annotations at scale without the Python SDK. All commands accept a file (CSV, JSON, JSONL, or Parquet) with up to 1000 annotations per request and use upsert semantics (existing annotations with the same key are updated; new ones are created). Resource Command Skill Spans ax spans annotate PROJECT file annotations.json arize trace Dataset examples ax datasets annotate examples NAME OR ID file annotations.json arize dataset Experiment runs ax experiments annotate runs NAME OR ID file annotations.json dataset DATASET arize experiment All three commands support space SPACE . See the linked skills for full flag tables and file format details. Related Skills arize trace : Export spans to find span IDs and time ranges; batch annotate spans via ax spans annotate arize dataset : Find dataset IDs and example IDs; batch annotate examples via ax datasets annotate examples arize evaluator : Automated LLM as judge alongside human annotation arize experiment : Experiments tied to datasets and evaluation workflows; batch annotate runs via ax experiments annotate runs arize prompts : Manage prompt templates; annotate prompt outputs for quality tracking arize link : Deep links to annotation configs and queues in the Arize UI Save Credentials for Future Use See [references/ax profiles.md](references/ax profiles.md) § Save Credentials for Future Use.