Frailty
Presentation
The following components extract mentions of frailty across the different domains of the Practical Geriatric Assessment (PGA), along with a couple domains that are not strictly speaking part of the PGA, but were considered relevant for frailty evaluation by the clinicians involved in the development process. Each component is based on the ContextualMatcher component.
Some general considerations about those components:
- Extracted entities are stored in
doc.entsanddoc.spans. For instance, theeds.functional_statuscomponent stores matches indoc.spans["functional_status"]. - Matches have an associated
_.{domain}attribute taking a value amonghealthy,altered_nondescript,altered_mild,altered_severeandother, indicating the level of alteration of the match for the corresponding domain. Some terms may match for several frailty domains at once. For example, "EHPAD" will have both its_.functional_statusand_.social_statusstatuses set toaltered_severe. - Some components are tailored to match some well-defined and standardized frailty scores, rather than the corresponding broader frailty domain. However, these components store their matches in
doc.spansboth under their own name and their corresponding domain name, and the matches will have attributes corresponding to the score itself, with the found value, and to the domain with the level of alteration. For example, a pipeline with theeds.adl_scorecomponent would match the phrase "adl_score 6/6" and store it both indoc.spans["adl_score"]anddoc.spans["functional_status"]. The match would have a_.adl_scoreattribute set to6.0, and a_.functional_statusattribute set tohealthy. -
Those components work on normalized documents. Please use the
eds.normalizerpipeline with the following parameters:import edsnlp, edsnlp.pipes as eds ... nlp.add_pipe( eds.normalizer( accents=True, lowercase=True, quotes=True, spaces=True, pollution=dict( information=True, bars=True, biology=True, doctors=True, web=True, coding=True, footer=True, ), ), )
Use qualifiers
Those components should be used with a qualification pipeline to avoid extracted unwanted matches. At the very least, you can use available rule-based qualifiers (eds.negation, eds.hypothesis and eds.family). It is also possible to use a deep-learning-based qualifier model, but for privacy purposes, such models can't be shared publicly for now.
On the medical definition of frailty
Those components were developped to extract chronic alterations, and not acute events.
Aggregation
For relevant phenotyping, matches should be aggregated at the document-level. For instance, a document containing an evaluation of the functional_status of a patient may have several terms matched by the eds.functional_status component, some of which of different levels of alteration. Thus, a good and simple aggregation rule is, for each domain, to
- disregard all entities tagged as irrelevant by the qualification component(s)
- take the maximum (i.e., the most severe) status of the leftover entities