Preprocessed ePI (p(ePI))
p(ePI) (Preprocessed ePI) is the intermediate state of an ePI after semantic annotations have been embedded by Preprocessors, preparing it for Lens execution.
Creation Process
Raw ePI → Preprocessor(s) → p(ePI)
Preprocessors transform ePI by:
- Analyzing narrative text
- Identifying medically relevant sections
- Linking to standard terminologies
- Embedding annotations in FHIR structure
Structure
p(ePI) retains the ePI Bundle structure but adds:
HtmlElementLink Extensions
In the Composition resource:
{
"extension": [{
"url": "http://hl7.eu/fhir/ig/gravitate-health/StructureDefinition/HtmlElementLink",
"extension": [{
"url": "elementClass",
"valueString": "diabetes-warning"
}, {
"url": "concept",
"valueCodeableConcept": {
"coding": [{
"system": "http://snomed.info/sct",
"code": "73211009",
"display": "Diabetes mellitus"
}]
}
}]
}]
}
HTML Class Attributes
In the Composition narrative (text.div):
<p class="diabetes-warning">
Use with caution in patients with diabetes.
</p>
Stacking
p(ePI) may result from multiple Preprocessors:
- First preprocessor: ePI → p(ePI)₁
- Second preprocessor: p(ePI)₁ → p(ePI)₂
- Final p(ePI) contains all annotations
Usage
p(ePI) is consumed by:
- Lens Execution Environment (LEE) during Focusing
- Lenses for decision logic
- Focusing Inspector for visualization
Key Characteristics
- Original content preserved: Text unchanged from ePI
- Semantically enriched: Linked to medical concepts
- Machine-readable: Annotations enable automated processing
- Lens-ready: Prepared for attention modification
Examples
See Gravitate-Health IG processed ePI examples.
Related Concepts
- ePI - Original content
- Preprocessor - Creates p(ePI)
- Lens - Consumes p(ePI)
- LEE - Processes p(ePI)
- Standard Terminologies - Annotation codes
- f(ePI) - Next stage output
- Focusing - Overall workflow