Annotate text
Annotate text with language corrections and semantic tags. Useful for processing colloquial transcriptions.
This endpoint requires authentication. Include your API key in the Authorization header.
Request Body
| Parameter | Type | Required | Description |
|---|---|---|---|
model | valsea-annotate | Yes | |
text | string | Yes | Text to annotate. |
response_format | json | verbose_json | No | Default: json |
language | string | No | Optional language hint (e.g. "singlish"). |
enable_correction | boolean | No | Enable language/grammar correction. |
enable_tags | boolean | No | Enable semantic tagging. |
Code Examples
curl -X POST https://api.valsea.ai/v1/annotations \
-H "Authorization: Bearer YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"model": "valsea-annotate",
"text": "Hello, world"
}'
Response
Minimal (json)
| Field | Type | Description |
|---|---|---|
text | string | |
annotations | array |
Verbose (verbose_json)
| Field | Type | Description |
|---|---|---|
text | string | |
raw_text | string | |
accent_corrections | array | |
semantic_tags | array | |
annotated_text | string | |
annotations | array |
Errors
| Status | Description |
|---|---|
401 | Missing or invalid API key |
402 | Insufficient credits |