Annotation API
/text_annotation
GET | Annotate a block of text, based on the specified dictionaries. |
---|
Parameters
Name | Located in | Description | Type |
---|---|---|---|
dictionaries | query | dictionary names, delimited by comma (',') | String |
text | query | a block of text | String |
rich | query | set it to 'true' for rich output | Boolean |
threshold | query | similarity threshold for cut-off | Float |
Responses
200 annotation result in the PubAnnotation JSON Format
400 Bad Request, e.g., a mandatory parameter setting is missing.
POST | Same as above, but a block (or blocks) of text can be given in JSON |
---|
Parameters
Name | Located in | Description | Type |
---|---|---|---|
body | body | a JSON object with a block of text | Array of Object |
rich | query | set it to 'true' for rich output | Boolean |
threshold | query | similarity threshold for cut-off | Float |
Responses
200 annotation result in PubAnnotation JSON Format
400 Bad Request, e.g., a mandatory parameter setting is missing.
/annotation_tasks
POST | To create an annotation task to a block of text (or blocks of text). |
---|
Parameters
Name | Located in | Description | Type |
---|---|---|---|
dictionaries | query | dictionaries, delimited by comma (',') | String |
body | body | a JSON object with a block of text, or an array of multiple JSON objects | Array of Object |
rich | query | set it to 'true' for rich output | Boolean |
threshold | query | similarity threshold for cut-off | Float |
Responses
201 The URL from which the result of annotation to be retrieved will be informed through the Location header
Headers
Name | Description | Type | Format |
---|---|---|---|
Location | The URL from which the result of annotation to be retrieved | string | url |
400 Bad Request, e.g., a mandatory parameter setting is missing.
503 The request is valid, but the server is unavailable to fulfil it due to, e.g., server overload.
/annotation_tasks/{id}
/annotation_results/{id}
GET | To retrieve the result of annotation |
---|
Parameters
Name | Located in | Description | Type |
---|---|---|---|
id | path | the id of annotation result | String |