Preparing and Submitting Measurements

Overview

The overall steps involved in telemedicine solutions when submitting measurements are as follows:

  1. Telemedicine Solution displays instructions for measurement methods from the ActivityDefinitions to the end-users.

  2. Users perform the measurement.

  3. Telemedicine Solution collects measurement data from devices

  4. Telemedicine Solution shall ensure measurement units conform to expected standards, and perform any necessary conversions.

  5. Telemedicine Solution shall submit Measurements using $submit-measurement, with multiple measurements partitioned by similar resolved timing for efficient processing.

Collecting Measurement Data from Devices

Determining Which Device(s) to Use

When a ServiceRequest referenced from a citizen’s CarePlan has a status set to active, it is expected that the required measurement device(s) has been provided to the individual performing the measurement. Typically (but not necessarily) this individual is a citizen.

Once the devices are provided, the following FHIR resources are created or, for the first two, reused:

  • FHIR Device representing the particular device instance

  • FHIR DeviceMetric represents the state and details of the particular device instance

  • FHIR DeviceUseStatement which establishes relationships between the Device, Patient, and CarePlan.

Determining when to use the same device for multiple measurements

In some cases, the same Device is expected to be used for multiple, different measurements. Whether that is the case, the Telemedicine solution can determine this by looked at the PlanDefintion. This is done by the citizen’s CarePlan references a PlanDefinition where an activity group in the PlanDefinition (or its possible sub-PlanDefinition(s)) has the code SDG (Same Device Group).

An activity group is represented as a PlanDefinition.action with sub-activities defined as PlanDefinition.action.action. As per the recursive construct of PlanDefinition.action.action, an activity group can be nested, in principle at any nesting level. A Same Device Group is a PlanDefinition.action or PlanDefinition.action.action with code set to Coding with code = SDG, system = http://ehealth.sundhed.dk/cs/activitydefinition-code.

See the ValueSet Activity Definition Code - eHealth Infrastructure v3.3.0 for details on the concept of SDG.

All the sub-activities of a Same Device Group are expected to be measured using the same device.

Presenting Instructions for Measuring Method

The citizen’s CarePlan refers to several ServiceRequest for activities to perform. Each ServiceRequest refers to an ActivityDefinition containing definitional details. Such details can be text and/or pictures to display to the individual performing the measurement just before or during measuring. These possible texts/pictures reside in ActivityDefinition.relatedArtifact with:

  • RelatedArtifact.type = documentation

  • RelatedArtifact.label = automatic or manual for use with automatic and manual entry collection of data, respectively.

  • RelatedArtifact.document can contain a contained Attachment with text to display. Currently, the Clinical Administrative Application produces a contained Attachment where Attachment.data contains markdown format (with markdown specified in Attachment.contentType).

  • RelatedArtifact.resource can refer to a DocumentReference resource containing a picture to display. Picture data is captured in DocumentReference.content.attachment.data with the format specified in DocumentReference.content.attachment.contentType.

It is expected that a Telemedicine Solution detects whether measuring is performed automatically or by manual entry and examines whether the corresponding ActivityDefinition.relatedArtifact (as defined above) is present. If so, the Telemedicine Solution is expected to display the text and/or picture to the user.

Presenting Offsets between Activities and Duration of Activity

The offset between activities has different meanings depending on where used. The citizen’s CarePlan refers to a PlanDefinition in which offset can be defined between its comprised activities through PlanDefinition.action.relatedAction.offset. In the following, it is assumed that the Patient-specific adjustments of measurement regimes (in ServiceRequest.timing) have not veered off significantly from the intention for offset and/or measurement regimes described in sub-elements of PlanDefinition.action, at least for the same-group activities.

  • When defined between activities within the same activity group, the PlanDefinition.action.relatedAction.offset (typically in the variant offsetDuration) defines a pause between the activities often specified in minutes or seconds.

  • When defined between activities no in the same activity group, the same offset defines different measurement regimes, for instance, that one activity starts a month after another activity ends. The offset is often specified in months or days.

 

It is expected that a Telemedicine Solution treats offset between activities in the same activity group as a pause for which a countdown or count-up should be presented to the user (typically the individual following the plan). In case it is not specified whether to perform a countdown or count up (this is currently not modelled), the Telemedicine Solution shall perform a countdown.

An activity may be described with a duration for actually performing the activity, beside a measurement regime. When this is the case, the:

  • PlanDefinition.action.timing[x] describes its measurement regime, while

  • ActivityDefinition.timingRange or, typically, ActivityDefinition.timingDuration describes the duration of actually performing the activity

 

Ensuring the Use of Proper Units

A measurement submitted as an Observation shall conform to the measurement unit expected by the eHealth infrastructure. See Interactions with the Terminology Service | Determining the proper code, system and unit for Quantity.

Preparing Measurements for Submission

Determining Resolved Timing to Use

When submitting measurements, it is mandatory to specify the resolved timing (see Adhering to Care Plans and Measurement Regimes | When an Activity is Supposed to Happen The Notion of Resolved Timing ) information in the ehealth-resolved-timing element of Observation, QuestionnaireResponse and Media. The structure of ehealth-resolved-timing contains:

  • serviceRequestVersionId which must specify the current FHIR technical version of the ServiceRequestreferenced in basedOn element of Observation, QuestionnaireResponse and Media.

  • start - start datetime of resolved timing period. This is mandatory when the type is Resolved.

  • end - end datetime of resolved timing period. This is mandatory when the type is Resolved.

  • type

    • Resolved if the ServiceRequest has a measurement regime supported by the infrastructure

    • Unresolved if the ServiceRequest has a measurement regime not supported by the infrastructure

    • Adhoc, if the ServiceRequest has a measurement regime, is specified as ad-hoc or the measurement was collected as per request from a practitioner.

One way to determine what resolved time to used is to invoke the get-patient-procedures operation.

Determining Qualities

Preparing a QuestionnaireResponse for a Questionnaire with Embedded, Simple Calculation(s)

As described in Managing Questionnaires | Preparing a Questionnaire with Embedded, Simple Calculations, a Questionnaire defined with the eHealth profile ehealth-questionnaire-advanced (see ehealth-questionnaire-advanced - eHealth Infrastructure v3.3.0 ) can contain variables and expressions.

The application used for filling in answers to a Questionnaire in a QuestionnaireResponse of this profile has the responsibility to evaluate embedded expressions and capture the results in the corresponding placeholders in the QuestionnaireResponse.

Saving a Draft QuestionnaireResponse

A draft QuestionnaireResponse can be saved by creating a new QuestionnaireResponse with status in-progress and subsequently updating it. This is performed through QuestionnaireResponse Create and Update, respectively, which is enabled for status in-progress only. Whether it is used for autosave or manually initiated, the client should refrain from calling QuestionnaireResponse Update unless actual changes have been made to the QuestionnaireResponse. Calling QuestionnaireResponse Update without actual change leads to unnecessary load and will not result in a change of the QuestionnaireResponse in the database anyway.

When creating/updating a draft QuestionnaireResponse, make sure the following elements are set:

  • status is in-progress

  • basedOn references the ServiceRequest stating that answering of questionnaire should be performed as an activity

  • resolvedTiming reflects the resolved timing with which the QuestionnaireResponse is intended to be submitted (as final).

 

Preparing an Observation for a Value Entered or Calculated in a QuestionnaireResponse

A Patient’s CarePlan can be based on a PlanDefinition (and one or more ActivityDefinition referenced from it) where:

  • PlanDefinition.action.participant.type is set to device, and/or

  • ActivityDefinition.participant.type is set to the device

This participant type signifies that the activity must be carried out by a solution, typically the Citizen Solution.

One such use is a PlanDefinition with an activity for answering a COPD Assessment Test (CAT) Questionnaire followed by an activity for a CAT score “measurement”.

In this scenario, the CAT score measurement is an ActivityDefinition with:

  • code set to Coding code="MCS88137", system="urn:oid:1.2.208.184.100.8", display="CAT score;pt"

  • participant.type set to device

In the Questionnaire, the above Coding for CAT score is present in Questionnaire.item.code for a calculated element prepared such that a QuestionnaireResponse can contain the calculated CAT score.

On detecting the participant.type set to device, an Observation shall be prepared with a value derived from the CAT score contained in the QuestionnaireResponse.

 

Preparing Media and a derived Observation

A CarePlan can be based on a PlanDefinition (ActivityDefinition), where the activity is to take a clinical image, and submit it together with derived measurements. The application may choose to prepare one or more Media resources to describe the outcome. A Media resource must specify one of the following usage modes:

  • raw: the Media content is the original clinical image.

  • metadata: the Media has no content, but specifies the location on the patient´s body that is subject of the clinical image.

  • overlay: the Media content is a modified version of the original clinical image or an overlay graphic. The modification or overlay is created to mark features in the original image.

The Media can be grouped together using the `relatedTo` element. The Media can be submitted together, or individually in any order. If they are submitted individually, the grouping must be done after submissions using update. The connected Media will share a group identifier assigned by the eHealth infrastructure in the `series` element.

Measurements derived from the clinical image can be prepared with reference to the image using the `derivedFrom` element.

In this scenario, the image taking is an ActivityDefinition with:

  • `code` set to Coding `code="446080005", system="http://snomed.info/sct", display="Photography of wound (procedure)"`

and the assessment activity is an ActivityDefinition with:

  • `code` set to Coding `code="72287-6", system="http://loinc.org", display="Wound size panel"`

The Wound size panel is specifically supported by a profiling the Observation resource (https://build.fhir.org/ig/fut-infrastructure/implementation-guide/branches/FUT1-16721_CCRR0226_S2/StructureDefinition-ehealth-observation-wound-dimensions.html).

The service requests are fulfilled by submitting one or more Media and an Observation. The Media would have different usage modes., e.g.: a 'raw' image of the wound, and an 'overlay' image of the wound with the perimeter of the wound drawn. The Observation is derived from the overlay, and specifies one or more components of the wound size panel, e.g.: length, width, depth, area, and volume.

Example for Wound assessment.png

 

Submitting Measurements

Telemedicine Solution submits measurements using the $submit-measurement operation.

The access control for submit-measurement is described here: Access Control for submit-measurement and the roles her Role to Privilege mapping

Technically, Telemedicine Solution can submit multiple measurements in different ways, ranging from:

  • Submit each measurement in a separate call to $submit-measurement.

  • Submit all measurements from a wider measurement period in a single call to $submit-measurement.

As noted, all measurements must pertain to the same Patient and EpisodeOfCare.

Practitioners submit measurement

A practitioner with the role having the $submit-measurement privilege can call $submit-measurement, and thereby practitioner to submit measurement data (measurements, questionnaire responses, and/or images).

In that case the Observation.performed shall refer to a Practitioner (instead of the typical scenario where it refers to a Patient). It can thereby be indicated that the measurement was carried out by an employee on behalf of the citizen.

Updates to Media after submission

Measurements are immutable after submission, with a few exceptions. Previously submitted Media can be updated in the following cases:

  • Grouping Media by setting the `relatedTo` element. The Media linked must be based on the same ServiceRequest. Media connected through `relatedTo` will get the same identifier in the `series` element.

  • Updating metadata on a Media if the Media has usage mode ‘metadata’. That is elements `modality`, `view`, and `bodySite`.

  • Updating Media content if the Media has usage mode ‘overlay’.

  • Updating Media status to ‘stopped’ to indicate that the activity has been terminated prior to full completion.