monarch-initiative / phenopacket2prompt

GA4GH Phenopacket to LLM prompt
https://monarch-initiative.github.io/phenopacket2prompt/
MIT License
3 stars 2 forks source link

No age of onset seems to default to "in adulthood", regardless of language #29

Closed leokim-l closed 5 months ago

leokim-l commented 5 months ago

I was a bit worried about the following, happening a lot in the STX phenopackets (1 year olds presenting HPO terms in adulthood). E.g. in prompts/en/STX_P_05_en-prompt.txt, we have:

The proband was a 1-year, 7-month old child who presented in adulthood with Neonatal hypotonia, Bilateral tonic-clonic seizure [...]

After some digging there do not seem to be bugs (related to this) in the phenopacket-store (@pnrobinson you hypothesised a bug in the STX cohort). I did find other cases, e.g. in the CLXN gene, file name "phenopacket-store/CLXN/PMID_36727596_OP-1110II1.json".

From prompts/en/PMID_36727596_OP_1110_II1_en-prompt.txt: The proband was a 12-year old adolescent female who presented in adulthood with Pulmonary arterial hypertension [...]

This happens in all languages.

My buest guess is some bug in one of the following (/src/main/.../model/): 1) PpktIndividual.java, lots of age related functions, not sure exactly which does what. 2) HpoOnsetAge.java 3) somewhere in the phenopacket-schema we import.

pnrobinson commented 5 months ago

The bug was in this method "onsetTermAtAgeOf", which had an inappropriate default statement. At least it is easy to fix!

pnrobinson commented 5 months ago

fixed