A date annotator takes as input a clinical note and outputs a list of predicted date annotations found in the clinical note. This OpenAPI document describes the specification of the NLP Sandbox Date Annotator API. This specification includes the schemas of the input and output data, and the requirements that this annotator must meet if you want to benchmark its performance on nlpsandbox.io.
The GitHub repository nlpsandbox/date-annotator-example provides an example implementation of the NLP Sandbox Date Annotator API in Python-Flask. By the end of the tutorial available in the README, you will have built a Docker image for this NLP Sandbox tool. You will then be able to submit this image to nlpsandbox.io to benchmark its performance.
Your NLP Sandbox tool must meet the following requirements before evaluating its performance on nlpsandbox.io.
The endpoint /
must redirect to /api/v1/tool
.
The endpoint /ui
must redirect to the Swagger User Interface (UI).
The output of this tool must be reproducible: a given input should always generate the same output.
To ensure the results are reproducible and robust, and the data are secured, this tool must not connect to any remote server. When benchmarked on nlpsandbox.io, this tool will not be able to connect to remote servers.
Return the date annotations found in a clinical note
required | object (Note) A clinical note |
{- "note": {
- "identifier": "awesome-note",
- "text": "On 12/26/2020, Ms. Chloe Price met with Dr. Prescott in Seattle.",
- "type": "loinc:LP29684-5",
- "patientId": "awesome-patient"
}
}
{- "textDateAnnotations": [
- {
- "start": 42,
- "length": 10,
- "text": "10/26/2020",
- "dateFormat": "MM/DD/YYYY",
- "confidence": 95.5
}
]
}
{- "name": "awesome-nlp-tool",
- "version": "1.0.6",
- "license": "apache-2.0",
- "repository": "github:awesome-org/awesome-nlp-tool",
- "description": "An awesome NLP Tool that takes as input X and outputs Y.",
- "author": "Awesome Team",
- "authorEmail": "author@example.com",
- "type": "nlpsandbox:date-annotator",
- "apiVersion": "1.2.0"
}
{- "tools": [
- {
- "name": "awesome-nlp-tool",
- "version": "1.0.6",
- "license": "apache-2.0",
- "repository": "github:awesome-org/awesome-nlp-tool",
- "description": "An awesome NLP Tool that takes as input X and outputs Y.",
- "author": "Awesome Team",
- "authorEmail": "author@example.com",
- "type": "nlpsandbox:date-annotator",
- "apiVersion": "1.2.0"
}
]
}