Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Create a terminology service that validates local valuesets with external codesystems #2881

Open
ewoutkramer opened this issue Oct 3, 2024 · 1 comment

Comments

@ewoutkramer
Copy link
Member

Create a new ITerminologyService implementation that could do a $validate for a ValueSet, even if it does not have the codesystems mentioned in the valueset. This can be done by interpreting the composition rules in the ValueSet and then translating them to $lookups on a CodeSystem, basically bridging between a ValueSet (which the external server might not have) and the CodeSystem (which the external server could have).

That was Tim's idea, and I think we can make it work in some limited, but common cases. After studying the Java source code of the terminology client, we have concluded that Grahame is doing the same thing, in a very limited (but useful) way. We could copy that approach.

@tmprd
Copy link

tmprd commented Oct 4, 2024

Example Resource Instance snippet:

<diagnosis>
  <sequence value="1"/>
  <diagnosisCodeableConcept>
    <coding>
      <system value="http://hl7.org/fhir/sid/icd-10-cm"/>
      <code value="S06.0X1A"/>
    </coding>
  </diagnosisCodeableConcept>
  <type>
    <coding>
      <system value="http://terminology.hl7.org/CodeSystem/ex-diagnosistype"/>
      <code value="principal"/>
    </coding>
  </type>
</diagnosis>

Example Profile snippet:

<element id="ExplanationOfBenefit.diagnosis.diagnosis[x]">
  <path value="ExplanationOfBenefit.diagnosis.diagnosis[x]"/>
  <type>
    <code value="CodeableConcept"/>
  </type>
  <mustSupport value="true"/>
  <binding>
    <strength value="required"/>
    <valueSet value="http://hl7.org/fhir/us/carin-bb/ValueSet/CDCICD910CMDiagnosisCodes"/>
  </binding>
</element>

Example ValueSet snippet:

<compose>
  <include>
    <system value="http://hl7.org/fhir/sid/icd-10-cm"/>
  </include>
  <include>
    <system value="http://terminology.hl7.org/CodeSystem/icd9"/>
  </include>
</compose>

Example CodeSystem snippet (when using a local but incomplete version):

<content value="not-present"/>

Proposed Solution

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants