FHIR Chat · CodeSystems and Concepts · implementers

Stream: implementers

Topic: CodeSystems and Concepts


view this post on Zulip Brendan Keeler (Jul 01 2021 at 20:00):

How can you fetch all codes/concepts belonging to a code system that is set to not-present? Preferably with paging :smile:

view this post on Zulip Grahame Grieve (Jul 01 2021 at 21:32):

not-present means that you can't. probably.

view this post on Zulip Grahame Grieve (Jul 01 2021 at 21:32):

it depends....

view this post on Zulip Jim Steel (Jul 05 2021 at 03:59):

You could try sending a ValueSet/$expand request with a POST body like:

{
  "resourceType": "ValueSet",
  "compose": {
    "include": [{
      "system": "http://my.code.system.url"
    }]
  }
}

view this post on Zulip Robert McClure (Jul 06 2021 at 19:28):

@Jim Steel That is like starting up a car to drive when the tire is flat and assuming that when the car runs, the flat will resolve.;-)

view this post on Zulip Lloyd McKenzie (Jul 06 2021 at 19:40):

Not necessarily. When you query the SNOMED code system, you might well get 'not present' - because while the terminology server has full awareness of all the SNOMED codes, it has no intention of trying to list them when it exposes the CodeSystem resource. On the other hand, an expand operation might work just fine.

view this post on Zulip Jim Steel (Jul 06 2021 at 21:09):

Exactly

view this post on Zulip Jim Steel (Jul 06 2021 at 21:57):

Its second-guessing the flat-tyre light, saying "maybe if I start the car, I can work out if its just the warning light that's not working, and the tyres might be fine"

view this post on Zulip Lloyd McKenzie (Jul 06 2021 at 22:05):

It does point out a short-coming in the CodeSystem resource - we can't differentiate "this is what I'm prepared to tell you right now" from "this is what I actually know and am capable of telling you"

view this post on Zulip Lloyd McKenzie (Jul 06 2021 at 22:45):

Should we introduce an 'availableContent' element alongside 'content' that could declare what the system actually has for the code system (as opposed to what it's displaying)?

view this post on Zulip Peter Jordan (Jul 06 2021 at 22:54):

IMO, a CodeSystem resource, in tandem with a TerminologyCapabilities resource, should enable a terminology server to inform clients of what it provides with regard to a particular code system. If not - and page size/ completeness requests - may be exceptions, then extensions are required. I doubt if any Terminology Server will return all the concepts from a particular edition and version of SNOMED CT, and there may be a case of adding a property to TerminologyCapabilities to indicate that. However, as @Jim Steel says, ValueSet is the appropriate resource for requesting concepts from code systems, and the implicit ValueSet capability allows a single URI to serve as a value set definition and the basis for the expansions and other value set references.

view this post on Zulip Robert McClure (Jul 07 2021 at 15:23):

I'm very perplexed by this thread. If a code system resource has CodeSystem.content = not-present then by deffinition the resource does not have any content: "None of the concepts defined by the code system are included in the code system resource." I hope that you are not suggesting that it is ok to have the FHIR representaation of a code system say this, but somehow in the back room the FHIR server still acts like it actually has the content. That is alarming and improper. And if you tell me it is because a value set has the content instead I'm going to work to fix that because we don't use value sets to store and serve up code systems anymore.

view this post on Zulip Lloyd McKenzie (Jul 07 2021 at 16:21):

It's not alarming or improper. It's normal. The "no content" is talking about "what's present in this CodeSystem instance". It's not speaking at all about what capability the system has. You'll never find a terminology server that exposes the SNOMED CT code system with a content value other than 'no content' or 'example only'. But you'll certainly find lots of terminology servers that support all/most SNOMED CT codes.

view this post on Zulip Lloyd McKenzie (Jul 07 2021 at 16:22):

Value set expansions offer a paged way to navigate through a subset of codes from a code system. CodeSystem resources have no paging mechanism and really aren't designed to allow exposing the codes from 'large/infinite' code systems.

view this post on Zulip Rob Hausam (Jul 08 2021 at 02:02):

Yes, I agree with Lloyd. This is expected behavior of most (probably all) FHIR terminology servers, particularly for the large code systems. The TerminologyCapabilities resource should (assuming it is available) be able to tell you what code systems the server supports (which it obviously needs the code system contents to do) - you wouldn't necessarily be able to or want to try to rely on a CodeSystem resource instance to tell you that.


Last updated: Apr 12 2022 at 19:14 UTC