GUIDELINE TUTORIAL II

Introduction

Creating the Guideline

Metadata

Definitions

Rules

Overview and Trial Run


INTRODUCTION

This tutorial guide is a supplement to the Archetypes guide, utilising existing models to provide a step-by-step demonstration on how to design basic guidelines for different types of clinical decision support (CDS) applications using the GDL Editor.

It is vital the model of a clinical concept is founded on solid scientific basis, and therefore it is essential that proper research has been done ahead of construction. When published, any user should be able to quickly review the material the model is based on; always make sure to list the references.

Resources containing more in-depth information are listed at the end of the document for quick access in case they are needed. There is also a link to our CDS Apps Overview page on GitHub containing over 100 demo applications (using 250+ archetypes) available in this section.
The guide has been written by the Clinical Modelling Group at Cambio Healthcare Systems.

All the best,
Clinical Modelling Group

Contributors
Eneimi Allwell-Brown
Jimmy Axelsson
Syeeda S. Farruque
Dennis Forslund

CREATING THE GUIDELINE

In order to generate data for storage and documentation, a guideline is required. Guidelines are used to express clinical rules and algorithms. Their format is based on a publicly available specification called the Guideline Definition Language (GDL). Guidelines use one or more archetypes to mimic the rules used in clinical practice. Even if two guidelines use the same archetypes they can be used to model different concepts in accordance with their respective rules.

This guide provides step-by-step instructions on building a common protocol-based guideline model using the Guideline Definition Language (GDL) Editor. This example builds on the steps from the earlier introductory guide that provides instructions on installing and setting up the GDL Editor, and is an extension on the previous guide on creating an archetype for the Apgar score model.

The Apgar score is a long established clinical tool that helps clinicians assess the health of new-born infants. The tool’s name is a mnemonic taken from the first letters of the words that represent the five aspects measured when assessing the patient; Appearance, Pulse, Grimace, Activity and Respiration. The Apgar score generates an accumulated total score as well as an overall assessment based on the result of the clinical examination. An image of the finished guideline is displayed below.

METADATA

First, add metadata under the Description tab which is opened upon launching the program:

  1. Name the guideline.
  2. Enter the author details including organisation and date of creation.
  3. Select Author draft from the Authorship lifecycle drop-down menu.
  4. Add the copyright.
  5. Use the + to add and – to remove keywords. The pencil icon can be used to edit existing keywords.
  6. Enter the name of any contributor.

Next, enter text into the 1. Description, 2. Purpose, 3. Use, 4. Misuse and 5. References sections:

Once all the metadata is filled in, ensure the model is saved.

DEFINITIONS

After all the metadata has been added, the next tab to go to is the Definitions tab.

Complete definitions of the finished Apgar score guideline are displayed in the image below. There is one input (EHR) archetype and one output (CDS) archetype. Each archetype contains attribute elements of the five clinical parameters, with the EHR archetype assigning an additional event time element. The CDS archetype also holds a total score element for generating an accumulated sum.

To instantiate the EHR archetype and its components, simply follow the instructions.

  1. Drag and drop the Archetype instantiation object into the main modelling area.
  2. Drag and drop five Element instantiation objects on top of the already instantiated blank archetype.
  3. Drag and drop the Predicate (Function) element on top of the already instantiated blank archetype. This element will ensure the values used in the tool are always the most recent (event time max).

Assign the blank elements as shown below:

  1. Click on Archetype within the archetype instantiation slot.
  2. Select EHR from the domain drop-down menu.
  3. Select the Apgar observation archetype from the list.
  4. Click on Accept.

Then, assign the five Apgar score parameters into their respective element instantiation field by following the instructions.

  1. Click into the first Element field of the listed element instantiations.
  2. Select the first of the five Apgar options (Respiratory effort).
  3. Click on Accept.

Repeat this process for the rest of the parameters. As each of the parameters are entered into their respective element instantiation sections, the Name field is automatically filled in. This second field is editable, permitting a more unique and descriptive term to be entered if required. The resulting view is displayed below.

The last part to enter is the Predicate (Function) element:

  1. Click on Element within the Predicate (Function) slot.
  2. Select the Event time attribute.
  3. Click on Accept.
  4. Choose max from the event time drop-down menu.

Instantiating the CDS (output) archetype follows the same principles.

  1. Drag and drop the Archetype instantiation object to the main modelling area.
  2. Drag and drop six Element instantiation objects on top of the already instantiated blank archetype.

Then, assign the five Apgar score parameters into their respective element instantiation field following the same method as before, only this time make sure the archetype domain is set to CDS instead of EHR. For the sixth and last slot, choose the count element Total score from the list. The resulting view is displayed below.

RULES

Once all the definitions have been created, they can be used to construct the rules for the Apgar score application. New rules are created by clicking on Add rule, and can be modelled in a number of ways. Below, a common method for protocol-based guidelines like the Apgar score is displayed.

The first rule, Set default (displayed in detail in the image below), allows the model to set a baseline value; a neutral or zero value to all CDS output in the event the user does not enter them.

The top Conditions pane contains each of the five Apgar score parameters instantiated from the Element exists condition from the right-hand list (1). On the bottom part of the screen, the resulting output value is set. A common way to model the default rule is to make it so that if there is no input (and consequently no generated output), the score is simply set to zero. In this case then, if there is no output, all parameters are each set to the alternative generating zero points (2).

To construct this rule, click on Add rule. Name the rule and click on Accept to generate a blank form. In the top Conditions pane, all five Apgar score parameters should be instantiated from the Element exists condition.

  1. Click on the Element slot.
  2. Select the Respiratory effort element from the CDS attribute list.
  3. Click on Accept

Repeat for all five parameters, and then choose the alternative does not exist from each drop-down menu.

Next, drag and drop Set (DataValue) from the Actions panel into its modelling area.

  1. Click into the Element field.
  2. Select the Respiratory effort element from the listed items – these are automatically CDS as only output type variables are allowed in the Actions section.
  3. Click on Accept.

Repeat for all parameters. Then click on DataValue and select the alternative generating zero points in accordance with the protocol provided below.

Apgar score0p1p2p
AActivity, muscle toneLimp or flaccidReduced toneNormal tone
PPulse, heart rateAbsent<100 beats per minute≥100 beats per minute
GGrimace, reflex irritabilityNo responseReduced responseNormal response
AAppearance, skin colourCompletely blueBody pink; extremities blueCompletely pink
RRespiration, respiratory effortAbsentWeak or irregularNormal

Rule pairs one to five are constructed for the five Apgar score parameters which, depending on the input, should each be able to generate a score of either one or two points in accordance with the protocol. Thus, there is one rule for each possible output value. The rules are triggered sequentially along the list i.e. if the input does not fulfill the first rule, the next one is tested and so forth. The very last rule (6) is where the sum total is calculated and stored.

  1. Click on Add rule.
  2. Name the rule Set Reflex irritability to 1.
  3. Click on Accept.

Drag and drop the Compare (DataValue) condition element from the right-hand side to the Conditions modelling area.

  1. Click on the Element field.
  2. Select Reflex irritability from the EHR attribute list.
  3. Click on Accept.

Select the == symbol from the drop-down menu.

  1. Click on DataValue.
  2. Select the ordinal value of 1 – Reduced response from the drop-down menu.

Once the selection is made, click on Accept to assign the value.

After assigning the condition, the action part of the rule is to be set; the resulting generated output should the condition be met. Drag and drop the Set (DataValue) action element to the Actions modelling area.

  1. Click on Element.
  2. Select the Reflex irritability attribute – these are automatically CDS as only output type variables are allowed in the Actions section.
  3. Click on Accept.
  1. Click on DataValue.
  2. Select the value 1 – Reduced response from the drop-down menu.

Once the selection has been made, click on Accept to assign it. The rule is now completed, and will generate an output of one point for the alternative “Reduced response” should it be entered as input for the parameter “Reflex irritability”. Repeat the process to create the next rule, Set Reflex irritability to 2, with the modification of selecting the alternative rendering two points in accordance with the protocol; “Normal response”. The finished rule is displayed below.

The rules for the other four parameters are modelled using the same principles.

Apgar score0p1p2p
AActivity, muscle toneLimp or flaccidReduced toneNormal tone
PPulse, heart rateAbsent<100 beats per minute≥100 beats per minute
GGrimace, reflex irritabilityNo responseReduced responseNormal response
AAppearance, skin colourCompletely blueBody pink; extremities blueCompletely pink
RRespiration, respiratory effortAbsentWeak or irregularNormal

To construct the final rule, click on Add rule and name it Calculate total score.

As output values have been generated through the already created rules, there are no conditions required for the calculation of total score; therefore, it only has a set action. Drag and drop Set (Attribute) into the actions modelling area.

  1. Click on Element attribute.
  2. Select the magnitude element from Total score.
  3. Click on Accept.
  1. Click on Expression.
  2. Select the Value attribute of the Reflex irritability CDS (output) element. This then translates into a gt-code for the item. The human-readable representation can be seen in the Expression viewer.

As the idea is for all output values to be added up into a total score, enter a + and then add the other four parameters in the same manner. The resulting expression is displayed below; note the use of parenthesis required to complete the expression.

Click on Accept to finish.

OVERVIEW AND TRIAL RUN

Once all the data has been added, the Terminology tab displays the codes:

All that is left is to test the model:

  1. Click on the Run button.
  2. Do not make any selections in the input section.
  3. Click on Execute.
  4. The Result panel at the bottom displays the default output (as in the Set default rule) and hence all elements as well as the total score are set to zero.
  1. Now enter some input values.
  2. Click on the Event time calendar icon to open the date box and select the date.
  1. Click on Execute.
  2. The generated result along with the calculated total score is displayed under Result.