Release notes for NLP API 2.20
Contents
Summary
Added
- Added support for the LOINC ontology.
- Added support for medication relations.
- New type of qualifier relation:
duration/timefornew/old/chronic/acutequalifier values - Improved support for age expressions like
x year old - Annotation updates for Snomed, Medcin and RxNorm
Changed
- Updated RadLex ontology database and lookup.
Fixed
- Fixed default processing features for meaurement-relations, imagelink-relations, qualifier-relations, followup-relations so that the emtelligent-ontology is selected by default to populate the arguments needed for the relations.
- Fixed qualifier relations bug related to multiple qualifier relations with different types on the same argument
- Uncertainty and Negation bug fixes.
Security
- Removed flask-cors
allowed_headersargument (which seemingly has never done anything).
Compatibility
- API version 2 Release 20
- Python SDK and client v4.3.0 to v5.0.0
- Java SDK and client v3.0.2 to v3.1.0
- JSON result output schema v2.13 for emtellipro-json-2
The latest version of the SDK is required for the new features in this release. The JSON result output schemas are backward compatible for all v2.x versions of emtellipro-json-2.
LOINC ontology
The processing feature for explicitly asking for LOINC ontology is umlsloinc-ontology.
For the following example sentence:
The output from the engine using output json result format v2.13.0 adds a new ontology umls_loinc to the list of concepts and there is also an additional entity_type value for umls_loinc for entities that can be linked to the LOINC ontology. To illustrate the engine output for LOINC ontology, the focus in the example below is on one entity and linked concept:
Medication relations
The new relation called medication has been added to the NLP API engine. This relation captures the various pieces of information associated with a medication prescription.
Medication Relation Arguments
drug: A substance that has been prescribed to or taken by the patient. Examples: Albuterol, Fentanyl, Insulin, Heparin (Porcine), Vitamin B12, Fluticasone/Salmeteroldosage: Size or level of a dose of a particular drug, which can be unitless. Examples: 10/100, 81 mG, 10mL, sliding scale, Twenty (20) units, 20 milliequivalents, 20mEq, 81’, 1 g, 2%, 2ml/ml, 5 mcg/kg/minroute: The path by which the drug is introduced into the body. Examples: IV, by mouth, p.o., subcutaneous, drip, G-tube, Dobhoff Tube, sublingual, topically, sl, intramuscular, buccal, sc, hsq, NG, inhaledquantity: The amount of drug in prescribed dosage to be taken by patient, often without units and preceding a route. Examples: Two (2), 1, one to two, 1, 2mode: The form the drug comes in. Examples: caps, cream, capsules, gtt, inhaler, MDI, puffs, solution, tablets, sustained release, ointment, suspensionfrequency: How often the drug is to be taken by the patient. Examples: daily, tid, b.i.d., once daily with meals, twice a day for the next 8 days, q4H, q.24 hours, q. four to six hoursnecessity: If the drug is required or can be taken if needed. Examples: PRN, p.r.n., as needed, p.r.n. as neededmodifier: If the drug was discontinued or tapered off. This is not used at the moment but we have added this argument into the specification to account for future modification to the medication relation. Examples: discontinued, stopped, taper
An example sentence with all arguments:
- Relation #1
- drug:
Albuterol - mode:
inhaler - necessity:
as needed
- drug:
- Relation #2
- drug:
Aspirin - dosage:
81 mg - route:
p.o. - quantity:
one - frequency:
q.d.
- drug:
- Relation #3
- drug:
Humibid - dosage:
600 mg - frequency:
b.i.d. - modifier:
discontinued
- drug:
Note that a medication relation cannot have multiple drug entities but each of the other arguments is a list and can have multiple entities.
Similar to other processing features, this feature can be specified at the time of the processing API call through including the processing feature which will be called medication-relations.
For the input text Aspirin 81 mg p.o. one q.d. the relevant part of the json output looks like this:
New qualifier relation type
Existing qualifier relation types supported by the NLP API are size/severity and status. In this release we are adding a new type of qualifier relation called duration/time.
For the following sentence:
The new duration/time qualifier relation indicates that new qualifies the entity rib fracture.
These types of qualifier relations are only enabled for Radiology reports for SNOMED entities only.
For the following input sentence:
The output from NLP API engine in json format looks like this (non-essentials parts of the output are not shown):
Python SDK updates
You will need NLP API Python SDK 5.0.0 for the new features listed below . If you are using Output Database client, please use the migrate command to upgrade DB to the new version of engine and SDK.
LOINC ontology in Output Database
The new LOINC ontology appears in the following tables:
foundentityconceptfoundentitytype
The foundentityconcept table lists umls_loinc in the concept_ontology field:
The foundentitytype table lists the LOINC entity type information:
The found_entity_id can be used to connect to other tables in the database, e.g. foundentity, foundentityspan and concept.
Medication relations in Output Database
The emtellipro DB contains six new tables to capture the medication relation.
With the following schema:
Reference to the main argument of drug is provided in the medicationrelation table. The arguments are in the following tables:
All of these arguments are lists and all of them have the same table schema:
The same medication_id can be used for multiple entity_id entities.
New qualifier relation type called duration/time
The new qualifier relation type appears in the qualifierrelation table in emtellipro_db (the Python database client):
The qualifier_type field can now contain duration/time as the new type of qualifier relation.

