0
votes

I'm new to FHIR and having some basic questions: I need to transform my raw txt data file into FHIR resource format for storage. Please find my questions and my solutions below and let me know if anything doesn't look appropriate. Thank you very much!

  1. URL for category:code:system not resolved?

In the example of resource observation https://www.hl7.org/fhir/observation-example-sample-data.html. The URL for "category:code:system" can't be resolved (http://terminology.hl7.org/CodeSystem/observation-category). I wondered if I should use the following link instead https://www.hl7.org/fhir/codesystem-observation-category.html#observation-category for the system value?

"category": [
    {
        "coding": [
            {
                "system": "https://www.hl7.org/fhir/codesystem-observation-category.html#observation-category",
                "code": "activity",
                "display": "Activity"
            }
        ]
    }
]
  1. If I can't find controlled terminology code (for example, SNOMED or LOINC) for my measurements, I use text instead to describe the measurement.

The measurements including: Rotation rate (x,y,z axis), acceleration (x,y,z axis) from apple watch accelerometer and gyroscope, type of utensil (fork, hand, ...) used during the meal and datetime the meal was started/end. I couldn't find appropriate controlled terminology for my measurements so I use text to describe, for example:

"code": {
    "text": "acceleration"
}
  1. Use observation resource for meal time and utensil records.

My raw data in txt file (Time:Event observed):

2019-05-23 17:01:31 +0000: meal started

2019-05-23 17:10:37 +0000: meal completed

2019-05-23 17:16:07 +0000: utensil used is 3

For FHIR version, as the 3 records belongs to the same session. I use 4 components to store all the information (Datetime meal started and completed, datetime when type of utensil was recorded, and type of utensil been used).

"component": [
    {
        "code": {
            "text": "meal started"
        },
        "valueDateTime": "2019-05-23T17:01:31+00:00"
    },
    {
        "code": {
            "text": "meal completed"
        },
        "valueDateTime": "2019-05-23T17:10:37+00:00"
    },
    {
        "code": {
            "text": "datetime, untensil used"
        },
        "valueDateTime": "2019-05-23T17:16:07+00:00"
    },
    {
        "code": {
            "text": "utensil"
        },
        "valueString": [
            "3"
        ]
    }
1

1 Answers

0
votes
  1. The system of a coded type does not need to be a resolvable url. It is a unique identifier in the form of a url for the code system the code comes from. A url is more readable to human eyes than for example an OID, and as an added benefit there could be a server responding. Although for all the code systems I've seen used in FHIR, there is not. So in this case, you should just use http://terminology.hl7.org/CodeSystem/observation-category

If you need to verify the code+system, it is up to your implementation to either use a terminology service for that, or implement your own terminology validation.

For 2. and 3. it could be helpful to discuss your use case within the FHIR community on https://chat.fhir.org. There might be others working on similar projects, or to give you guidance on the best approach. It will be better for interoperability if you would use coded values. For example, I would not know what your utensil nr '3' is so that's not interoperable. If you had used the Snomed code for 'fork', that would have been be much clearer.