1. Introduction to workflow technology
Representation of healthcare processes in a workflow
editor and their execution in a workflow engine
Vojtech Huser MD PhD
Harm Scherpbier, MD, MS
AMIA 2012, Tutorial (3hrs)
2. Agenda
Part 1: Introduction, history, overview
Part 2: Standards, SDO, related theories
Part 3: Practical tools demonstration
Part 4: Conclusion
This presentation is also at this URL
http://www.slideshare.net/vojtech_huser/presentations
Accompanying bibliography and other files
http://code.google.com/p/healthflow/downloads/list
2
Vojtech Huser, Harm Scherpbier: workflow tutorial
3. Part 1: Introduction to workflow technology(WT)
Need for specifying workflow within IT systems
History of workflow technology
prior 1960s-1980s
development after 1990
Components of workflow technology (process definition,
execution engine, analytical components)
Benefits of implementing a workflow server within a
generic IT system
Major workflow vendors and open-source workflow
technology tools
Future development and research challenges
Published case studies in Healthcare
Difference: Workflow engine vs. Decision Support engine
WT in healthcare (HS) 3
Vojtech Huser, Harm Scherpbier: workflow tutorial
4. Part 2: WT standards, SDOs, related
theories
Workflow management coalition’s (WfMC)
standards
Definition of WT terms
XML process definition language
(BPMN 2.0 (stored as XPDL 2.2))
Other standardization efforts
Business Process Execution Language (BPEL)
Business Process Modeling Notation (BPMN)
Research-originated WT standards
Petri Nets theory and its relationship to workflows
4
Vojtech Huser, Harm Scherpbier: workflow tutorial
5. Part 3: Practical tools demos
MainLine Health case study
Demo of an JaWE editor (and engine)
Process mining tool (ProM, Nitro, DISCO)
5
Vojtech Huser, Harm Scherpbier: workflow tutorial
10. Part 1: Introduction to workflow technology
Need for specifying workflow within IT systems
History of workflow technology
prior 1960s-1980s
development after 1990
Components of workflow technology (process definition,
execution engine, analytical components)
Benefits of implementing a workflow server within a
generic IT system
Major workflow vendors and open-source workflow
technology tools
Workflow Technology applied industries and healthcare
Future development and research challenges
10
Vojtech Huser, Harm Scherpbier: workflow tutorial
11. Workflow technology
BPM = business process management
Adaptive workflow (Adaptive Case
Management)
Computer supported collaborative work
(CSCW)
Why workflow?
Separation of data into databases
Separation of UI from IT system core
Separation of process knowledge
11
Vojtech Huser, Harm Scherpbier: workflow tutorial
12. Process Example
Koetter (2007)
12
Vojtech Huser, Harm Scherpbier: workflow tutorial
14. Workflow patterns examples
Parallel Split: When an intrusion alarm is received,
trigger the dispatch-patrol activity and the inform-police
activity immediately.
Exclusive Choice: After the review election activity is
complete, either the declare results or the recount votes
activity is undertaken.
Multi Choice: Depending on the nature of the
emergency call, one or more of the despatch-police,
despatch-fire-engine and despatch-ambulance activities
is immediately initiated.
14
Vojtech Huser, Harm Scherpbier: workflow tutorial
16. Part 1: Introduction to workflow technology
Need for specifying workflow within IT systems
History of workflow technology
prior 1960s-1980s
development after 1990
Components of workflow technology (process definition,
execution engine, analytical components)
Benefits of implementing a workflow server within a
generic IT system
Major workflow vendors and open-source workflow
technology tools
Workflow Technology applied industries and healthcare
Future development and research challenges
16
Vojtech Huser, Harm Scherpbier: workflow tutorial
17. WT development
1960s
Petri Nets (Carl A. Petri PhD work)
1960s-present
Workflow components of various systems
1999
WfMC: terminology
2000s
2002: XPDL 1.0 2005 XPDL 2.0 2008 XPDL 2.1
BPMN standard
2010s
BPMN 2.0
XPDL 2.2 17
22. Part 1: Introduction to workflow technology
Need for specifying workflow within IT systems
History of workflow technology
prior 1960s-1980s
development after 1990
Components of workflow technology (process
definition, execution engine, analytical components)
Benefits of implementing a workflow server within a
generic IT system
Major workflow vendors and open-source workflow
technology tools
Workflow Technology applied industries and healthcare
Future development and research challenges
22
23. Automating Workflow
Defined by Workflow Management
Coalition (WfMC)
www.wfmc.org
Terminology and Glossary
http://www.wfmc.org/standards/docs/TC-
1011_term_glossary_v3.pdf
23
24. Terms
Workflow
The automation of a business process, in
whole or part, during which documents,
information or tasks are passed from one
participant to another for action, according to a
set of procedural rules.
WfMS = Workflow Management System
BPM = Business Process Management
BPMS = Business Process Management System
24
32. Part 1: Introduction to workflow technology
Need for specifying workflow within IT systems
History of workflow technology
prior 1960s-1980s
development after 1990
Components of workflow technology (process definition,
execution engine, analytical components)
Benefits of implementing a workflow server within
a generic IT system
Major workflow vendors and open-source workflow
technology tools
Workflow Technology applied industries and healthcare
Future development and research challenges
32
33. WT benefits
Non-programmers understand processes
Non-programmers can modify processes
Analytical tools
Faster IT system development (SOA+WT)
33
34. Part 1: Introduction to workflow technology
Need for specifying workflow within IT systems
History of workflow technology
prior 1960s-1980s
development after 1990
Components of workflow technology (process definition,
execution engine, analytical components)
Benefits of implementing a workflow server within a
generic IT system
Major workflow vendors and open-source
workflow technology tools
Workflow Technology applied industries and healthcare
Future development and research challenges
34
35. Choice of Wf vendor
Major player
TIBCO
BEA
Global 360
IBM
Other
Fujitsu
IBM
Oracle
Microsoft
SAP
Lombardi
Open source
JBOSS
Taverna
Together
Bonita
YAWL
http://java-source.net/open-
source/workflow-engines
35
43. Part 1: Introduction to workflow technology
Need for specifying workflow within IT systems
History of workflow technology
prior 1960s-1980s
development after 1990
Components of workflow technology (process definition,
execution engine, analytical components)
Benefits of implementing a workflow server within a
generic IT system
Major workflow vendors and open-source workflow
technology tools
Workflow Technology applied industries and
healthcare
Future development and research challenges
43
Vojtech Huser, Harm Scherpbier: workflow tutorial
44. Use of WT
Pioneer domains
Banking
Manufacturing
Shipping
Government authorities
Pharmaceutical
Healthcare
Gartner 2008 report: <5% use
44
Vojtech Huser, Harm Scherpbier: workflow tutorial
45. Overview of Healtchare WT articles
Haux R, Seggewies C, Baldauf-Sobez W, Kullmann P, Reichert H, Luedecke
L, et al. Soarian - workflow management applied for health care. Methods Inf
Med. 2003;42(1):25-36.
J. Emanuele and L. Koetter, "Workflow Opportunities and Challenges in
Healthcare," in 2007 BPM & Workflow Handbook, 2007.
L. Koetter, "MRSA infection control with workflow technology," Spring AMIA
Conference, Orlando, FL, 2007.
R. Hess, "The Chester County Hospital: Case Study," in 2007 Excellence in
Practice: Moving the Goalposts., 2007.
Process Mining of Clinical Workflows for Quality and Process Improvement
http://chuckwebster.com/process-mining/HIMSS12/process-mining-clinical-
workflows-quality-process-mprovement.pdf
Huser V, Narus SP, Rocha RA. Evaluation of a flowchart-based EHR query
system: a case study of RetroGuide. J Biomed Inform 2010;43(1):41-50.
Huser V, Rasmussen LV, Oberg R, Starren JB. Representation and
execution of clinical decision support using workflow engine technology.
BMC Med Res Methodol 45
Vojtech Huser, Harm Scherpbier: workflow tutorial
46. Process Definition
A process is:
Multiple steps…
For multiple people…
Over time…
To achieve a goal.
46
Vojtech Huser, Harm Scherpbier: workflow tutorial
47. Main Line Health examples
Clinical Guidelines and Core Measures
Infection Control - e.g. CLABSI
Adverse Drug Events prevention
Heparin Protocol, Insulin Drip Rate Calculator
Research Protocols
… and more
First: look at the Alerts worklist to see these at
work…
48. Foley Reminders, ADE’s
Foley Workflow Goal: Timely removal, reduce risk for
UTIs
ADE Workflow Goal: Early detection of ADEs, change
medications
49. AMI and CHF Pathways
Identify patients, initiate pathway, apply Core Measures
AMI:
CHF:
50. Video: CHF pathway
Video of CHF pathway
50
Vojtech Huser, Harm Scherpbier: workflow tutorial
51. Central Line Insertion Checklist
Guidance to most
preferred line location
Guidelines
Checklist!!
55. Dr. Clark Piatt
Short video – Dr. Clark Piatt on automated
Central Line management
55
Vojtech Huser, Harm Scherpbier: workflow tutorial
56. Workflow Engine for Clinical Trials
Osteoporosis Research Study - Dr. Matthew DiPaola MD,
supported by Sharpe-Strumia Foundation, performed at
Lankenau Hospital, with LIMR research staff – 2008 –
2009
Objective: identify patients >65 years old, with hip
fracture, and initiate endocrinology management in the
acute phase of the care. Identify and treat osteoporosis,
by endocrinologist, to prevent future fractures.
Identify Candidates – Consent/Enroll – Randomize -
Automate Study Protocol – Collect Data
60. Clinical Trial Management
Goal: Identify Candidates for Clinical Trials, and Track
Enrolled Patients
Implement Protocols – including randomization
61. Heparin Alert Utilization for Sept. 2011 thru Jan. 2012
Percent Alert Utilization Per Site
100
90
75
80 74
69 68 67 71 67
70 61 64 60 61
60 54 54 September
October
50 November
37 December
40 January
30
17
20
10
0
LMC BMH PH Volume of Alerts Per Site
300
234
200 187
171 173 September
October
143 November
113 December
January
100 87
69 73
55 50
35 38
24 15
0
LMC BMH PH
62. Workflow Engine vs. Rules
Engine
Workflow Engine with Rules Engine Rules Engine
Process Automation / Business Rule-based Clinical Decision
Process Management Support
Multiple steps, over time, for Single decision point for single
multiple users user
State-aware: keeps track of point
in time and waits (listens) for Not State-aware – runs at trigger
next event to happen event
Asynchronous
Plug-in services (EAI) Synchronous
Graphical programming
63. Part 1: Introduction to workflow technology
Need for specifying workflow within IT systems
History of workflow technology
prior 1960s-1980s
development after 1990
Components of workflow technology (process definition,
execution engine, analytical components)
Benefits of implementing a workflow server within a
generic IT system
Major workflow vendors and open-source workflow
technology tools
Workflow Technology applied industries and healthcare
Future development and research challenges
63
Vojtech Huser, Harm Scherpbier: workflow tutorial
64. Future of WT
Improvements
Adoption is growing
Software tools sophistication is improving
Competition, consolidation
Future similar to a database server inclusion in
IT systems
Standards consolidation
Research challenges
Process model visualization challenges
Process model cross-vendor portability
Adaptive workflow
64
Vojtech Huser, Harm Scherpbier: workflow tutorial
68. Part 2: WT standards, SDOs, related
theories
Workflow management coalition’s (WfMC)
standards
Definition of WT terms
XML process definition language (XPDL)
Other standardization efforts
Business Process Execution Language (BPEL)
Business Process Modeling Notation (BPMN)
Research-originated WT standards
Petri Nets theory and its relationship to workflows
68
Vojtech Huser, Harm Scherpbier: workflow tutorial
69. Part 2: WT standards, SDOs, related
theories
Workflow management coalition’s (WfMC)
standards
Definition of WT terms
XML process definition language (XPDL)
Other standardization efforts
Business Process Execution Language (BPEL)
Business Process Modeling Notation (BPMN)
Research-originated WT standards
Petri Nets theory and its relationship to workflows
69
Vojtech Huser, Harm Scherpbier: workflow tutorial
71. Part 2: WT standards, SDOs, related
theories
Workflow management coalition’s (WfMC)
standards
Definition of WT terms
XML process definition language (XPDL)
Other standardization efforts
Business Process Execution Language (BPEL)
Business Process Modeling Notation (BPMN)
Research-originated WT standards
Petri Nets theory and its relationship to workflows
71
Vojtech Huser, Harm Scherpbier: workflow tutorial
73. Workflow Technology
Business process management system (BPMS)
Workflow = The automation of a business process, in whole or
part, during which documents, information or tasks are passed from
one participant to another for action, according to a set of procedural
rules.
Workflow Process = A set of one or more linked procedures or
activities which collectively realize a business objective or policy
goal, normally within the context of an organizational structure
defining functional roles and relationships (definition vs. instance)
Worklist Handler = A software component that manages the
interaction between the user and the worklist maintained by a
workflow engine
(task display, completion, acceptance, referral)
WfMC: Terminology & Glossary, Document Number WFMC-TC-1011, Feb 99
http://www.wfmc.org/index.php?option=com_docman&task=doc_download&gid=93&Itemid=74
73
Vojtech Huser, Harm Scherpbier: workflow tutorial
74. Part 2: WT standards, SDOs, related
theories
Workflow management coalition’s (WfMC)
standards
Definition of WT terms
XML process definition language (XPDL)
Other standardization efforts
Business Process Execution Language (BPEL)
Business Process Modeling Notation (BPMN)
Research-originated WT standards
Petri Nets theory and its relationship to workflows
74
Vojtech Huser, Harm Scherpbier: workflow tutorial
75. XPDL
XML file based on a XSD schema
http://wfmc.org/xpdl.html
http://www.xpdl.org/standards/xpdl-2.2/bpmnxpdl_40a.xsd
First introduced in 1999
Conformance testing available
http://www.xpdl.org/cloudapps.html
Exchange format
Adoption (70+ products)
http://wfmc.org/xpdl-implementations.html
75
Vojtech Huser, Harm Scherpbier: workflow tutorial
80. Part 2: WT standards, SDOs, related
theories
Workflow management coalition’s (WfMC)
standards
Definition of WT terms
XML process definition language (XPDL)
Other standardization efforts
Business Process Execution Language (BPEL)
Business Process Modeling Notation (BPMN)
Research-originated WT standards
Petri Nets theory and its relationship to workflows
80
Vojtech Huser, Harm Scherpbier: workflow tutorial
81. WT standards
Historical
WSDL
Current major
XPDL, BPMN, BPEL
Proprietary (vendor specific):
JBPM (JBoss)
Win Workflow Foundation (Microsoft)
T2Flow->SCUFL2 (Taverna)
internal format (Weka)
Research ones
YAWL
81
Vojtech Huser, Harm Scherpbier: workflow tutorial
83. Part 2: WT standards, SDOs, related
theories
Workflow management coalition’s (WfMC)
standards
Definition of WT terms
XML process definition language (XPDL)
Other standardization efforts
Business Process Execution Language (BPEL)
Business Process Modeling Notation (BPMN)
Research-originated WT standards
Petri Nets theory and its relationship to
workflows
83
Vojtech Huser, Harm Scherpbier: workflow tutorial
84. Petri Nets
Mathematical theory
Basics
Petri net consist two types of nodes: places
and transitions.
A place may have zero or more tokens.
Graphic representations :Places (circles),
transitions (bars), arcs (arrows), and
tokens (dots)
p1 t1 p2
84
Vojtech Huser, Harm Scherpbier: workflow tutorial
85. Definition of Petri Net
C = ( P, T, F)
Places (circles)
P = { p1, p2, p3, …, pn}
Transitions (bars)
T = { t1, t2, t3, …, tn}
Flow relations (arcs)
F ⊂ (P × T ) ∪ (T × P )
Extensions
Hierarchical Petri Netns
Coloured Petri Nets
85
Vojtech Huser, Harm Scherpbier: workflow tutorial
89. HS Demo (30 min)
Editor and EMR portions
Activy example
Basic editing
Roundtrip between editor and EMR
(changes)
MLM logic vs. flowchart logic
89
Vojtech Huser, Harm Scherpbier: workflow tutorial
90. Main Line Health Demo
Integration points to EMR via services:
Events
Decision Rules
Tasks, messages, actions
Wait-steps
Nesting
Workflow Engine Demonstration:
http://intranet/Soarian/Support/Links.htm
91. VH Demo part (30 min)
Screenshot tour of editor, processes and
process mining
editor
process mining tool
91
Vojtech Huser, Harm Scherpbier: workflow tutorial
101. 2012: Mercy Health case study
Process Mining of Clinical Workflows for Quality and Process Improvement
http://chuckwebster.com/process-mining/HIMSS12/process-mining-clinical-workflows-
quality-process-mprovement.pdf
101
Vojtech Huser, Harm Scherpbier: workflow tutorial
104. Agenda for part 4
Vojtech’s points
Harm’s points
104
Vojtech Huser, Harm Scherpbier: workflow tutorial
105. Modelling paradigm
Flowcharts
Several historical revisions
Different vendors used different paradigm
Standardization (BPMN)
Swim lanes example
Split/Join example
Annotation elements
Complex flowcharts
Flowchart can’t remove it
different views, hierarchical layers
Exception handling
General standards (XPDL) vs. medicine specific standards
(GLIF, SAGE)
105
Vojtech Huser, Harm Scherpbier: workflow tutorial
106. Healthcare is different
Current workflow standards
YAWL
Current workflow vendors implementations
Complexity of medicine
106
Vojtech Huser, Harm Scherpbier: workflow tutorial
107. WT and EHR vendors
Current status
One vendor uses a third party workflow engine
Variable support for workflow constructs
Work list (push [single clinician, team], pull)
Obtain current performer of a certain role
Obtain patient data
Maintain process state
Limited or now workflow features
107
Vojtech Huser, Harm Scherpbier: workflow tutorial
108. WT and EHR vendors
Future state
Status quo stays
More vendors adopt 3rd party workflow engine
Internal “CDS [rule] engines” gain more
workflow features
New CDS standard with workflow components
HL7 DSS
108
Vojtech Huser, Harm Scherpbier: workflow tutorial
109. Sage flowchart example
P. Ram (2004)
“Executing Clinical Practice Guidelines
Using the SAGE Execution Engine,”
Medinfo, pp. 251-5, 2004
SAGE’s decision maps
subflows
Rule-in and Rule-out
contructs
Linking workflow engine
with a rule engine
109
Vojtech Huser, MD, PhD
114. maintenance:
title: Hepatitis A Immunization MLM;;
library:
links: to be added;;
knowledge:
type: data_driven;;
data:
/* text within curly brackets would be replaced with an institution’s own query */
Let PatientIDRecord BE OBJECT [AccountNum, Name, Birthdate, Sex];
LET Patient BE Read As PatientIDRecord Latest {select accountnum, name, dateofbirth, sex from EHR} ;
LET HAVRIX BE Read As Medication {select med, form, dose, route, schedule from EHR where med = ‘HAVRIX’} ;
LET TWINRIX BE Read As Medication {select med, form, dose, route, schedule from EHR where med = ‘TWINRIX’} ;
Let GenericMessage BE OBJECT [MessageID, MessageCode, Message_Text];
Let Vaccine_Message BE New GenericMessage;
;;
evoke: outpatient_visit;;
logic:
/* Check age */
if
Patient_Age Is Null
then
/* Rules-one previous vaccination. */
if
Count(VAQTA) + Count(HAVRIX) + Count(TWINRIX) = 1
then
Needs_second_dose := true;
endif;
/* Second dose young people */
if
Apply_young_patient_rules and
Needs_second_dose and
Exist(VAQTA) and
Latest VAQTA Occurred Before 6 months Ago
then
Vaccine_Message.Message_Text := "Give VAQTA vaccine, 25U, IM now. This completes Hepatitis A vaccinations.";
Conclude true;
endif; 114
if
Vojtech Huser, Harm Scherpbier: workflow tutorial
117. WT and healthcare institutions
Current status
No adoption (majority, Gartner report)
EHR vendor supports WT
3rd party engine implementation
(Marshfield Clinic)
Different institutions are at different stages
117
Vojtech Huser, Harm Scherpbier: workflow tutorial
120. Learnings
Powerful
Complex
Importance of integration to EMR
EMR represents the users, the data, and the
transactions
Need for services: events, work-lists, tasks
and notifications, actions (e.g. orders), EAI
120
Vojtech Huser, Harm Scherpbier: workflow tutorial
121. Healthcare Processes
Healthcare Processes waiting to be
automated:
Clinical Pathways, Care Management
Transitions and Discharges
Surveillance and monitoring
Administrative processes
… and many more
Many opportunities for use of BPM
technology in healthcare
121
Vojtech Huser, Harm Scherpbier: workflow tutorial
122. Platform for outsourced knowledge
Currently: managing decision rules
internally, linked into the workflows
Future: opportunity to call outside
knowledge sources
HL7 DSS, OpenCDS standards
122
Vojtech Huser, Harm Scherpbier: workflow tutorial
123. Future of BPM in Healthcare?
Opportunity, processes to be automated?
Yes!
Technology available? Yes!
Advantage of BPM over other decision
support and process management tools?
Yes!
Can healthcare organizations manage the
complexity (build and maintain)? Maybe…
123
Vojtech Huser, Harm Scherpbier: workflow tutorial
124. Questions ?
Covered topics
Introduction to workflow technology
WT standards
Examples
WT and healthcare
Contact us
vojtech.huser at nih.gov
124
Vojtech Huser, Harm Scherpbier: workflow tutorial
Vojtech Huser, Harm Scherpbier: workflow tutorial Morgridge: Project proposal Get harm’s email address for the end open Tset EAI enteprise application integration Clinical bckground or CS background Researcher vs. production health Have you open ad workflow editor before Have about and any w standartd Are you familiar with Arden syntax or any other CDS paradigms such as GLIF, SAGE, PRoForma, GELLO
In spring 2012, the WfMC completed XPDL 2.2 as the fifth revision of this specification. XPDL 2.2 builds on version 2.1 by introducing support for the process modeling extensions added to BPMN 2.0. Vojtech Huser, Harm Scherpbier: workflow tutorial Morgridge: Project proposal
Vojtech Huser, Harm Scherpbier: workflow tutorial Morgridge: Project proposal NOTICE: we can also defin a process where only IT tools play a role. (no humans) bad news: now we became a wheel in an big machine (workers) good news: now we won’t have to remember the order and maintain the record of in which order we run what applications. Executable visio. (managers)
Vojtech Huser, Harm Scherpbier: workflow tutorial Morgridge: Project proposal system only participants mode retrospective mode real time mode (waiting application for next event) (instead of read next event)
How do we decide where to place the line? Used best practices. Built in stops – like hand washing. Does it happen? Not sure, but we are trying to focus attention.
Opportunities to coach VAP - Oral care every 2 hours. If VAP and check was missed, use as coaching opportunity. Missed opportunity.
maintenance: title: Hepatitis A Immunization MLM;; mlmname: Hep_A_Immunization;; arden: Version 2.8;; version: 1.00;; institution: Intermountain Health Care;; author: Peter Haug, M.D.;; specialist: Peter Haug M.D.;; date: 2011-09-10;; validation: testing;; library: purpose: Suggest initial dose of Hepatitis A vaccine schedule.;; explanation: ;; keywords: Hepatitis A; vaccine; immunization;; citations: to be added. ;; links: to be added;; knowledge: type: data_driven;; data: /* text within curly brackets would be replaced with an institution’s own query */ Let PatientIDRecord BE OBJECT [AccountNum, Name, Birthdate, Sex]; LET Patient BE Read As PatientIDRecord Latest {select accountnum, name, dateofbirth, sex from EHR} ; LET outpatient_visit BE EVENT {storage of ambulatory registration} LET Medication BE OBJECT [Drug_Name, Form, Dosage, Route, Schedule] LET VAQTA BE Read As Medication {select med, form, dose, route, schedule from EHR where med = ‘VAQTA’} ; LET HAVRIX BE Read As Medication {select med, form, dose, route, schedule from EHR where med = ‘HAVRIX’} ; LET TWINRIX BE Read As Medication {select med, form, dose, route, schedule from EHR where med = ‘TWINRIX’} ; Let GenericMessage BE OBJECT [MessageID, MessageCode, Message_Text]; Let Vaccine_Message BE New GenericMessage; ;; evoke: outpatient_visit;; logic: /* Check age */ if Patient_Age Is Null then Patient_Age := Now – Patient.Birthdate; endif; if Patient_Age Less Than 12 months then Conclude False ; endif; /* Young Patient */ if Patient_Age Greater Than 12 months and Patient_Age Less Than or Equal 18 years then Apply_young_patient_rules := true; endif; /* Older Patient */ if Patient_Age Greater Than 18 years then Apply_older_patient_rules := true; endif; /* Rules-no previous vaccine. */ if Exist(VAQTA) or Exist(HAVRIX) or Exist(TWINRIX) then Hepatitis_vaccination:= true; endif; if Apply_young_patient_rules and Not Hepatitis_vaccination then Vaccine_Message.Message_Text := "Give VAQTA vaccine, 25U, IM now and repeat in 6 to 18 months."; Conclude true; endif; if Apply_older_patient_rules and Not Hepatitis_vaccination then Vaccine_Message.Message_Text := "Give VAQTA vaccine, 50U, IM now and repeat in 6 to 18 months."; Conclude true; endif; /* Rules-one previous vaccination. */ if Count(VAQTA) + Count(HAVRIX) + Count(TWINRIX) = 1 then Needs_second_dose := true; endif; /* Second dose young people */ if Apply_young_patient_rules and Needs_second_dose and Exist(VAQTA) and Latest VAQTA Occurred Before 6 months Ago then Vaccine_Message.Message_Text := "Give VAQTA vaccine, 25U, IM now. This completes Hepatitis A vaccinations."; Conclude true; endif; if Apply_young_patient_rules and Needs_second_dose and Exist(HAVRIX) and Latest HAVRIX Occurred Before 6 months Ago then Vaccine_Message.Message_Text := "Give HAVRIX vaccine, 720EL.U, IM now. This completes Hepatitis A vaccinations."; Conclude true; endif; if Apply_young_patient_rules and Needs_second_dose and Exist(TWINRIX) and Latest TWINRIX Occurred Before 1 months Ago then Vaccine_Message.Message_Text := "Give TWINRIX vaccine, 720 EL.U/20ug, IM now. This is the second Hepatitis A/B vaccination."; Conclude true; endif; /* Second dose Older people */ if Apply_older_patient_rules and Needs_second_dose and Exist(VAQTA) and Latest VAQTA Occurred Before 6 months Ago then Vaccine_Message.Message_Text := "Give VAQTA vaccine, 50 U, IM now. This completes Hepatitis A vaccinations."; Conclude true; endif; if Apply_older_patient_rules and Needs_second_dose and Exist(HAVRIX) and Latest HAVRIX Occurred Before 6 months Ago then Vaccine_Message.Message_Text := "Give HAVRIX vaccine, 1440 U, IM now. This completes Hepatitis A vaccinations."; Conclude true; endif; if Apply_older_patient_rules and Needs_second_dose and Exist(TWINRIX) and Latest TWINRIX Occurred Before 1 months Ago then Vaccine_Message.Message_Text := "Give TWINRIX vaccine, 720EL.U/20ug, IM now. This is the second Hepatitis A/B vaccination."; Conclude true; endif; /* Third dose of TWINRIX */ if Exist(TWINRIX) and Count(TWINRIX) = 2 and Latest(TWINRIX) Occurred Before 5 months Ago then Vaccine_Message.Message_Text := "Give TWINRIX vaccine, 720EL.U/20ug, IM now. This completes Hepatitis A/B vaccinations."; Conclude true; endif; ;; action: write Vaccine_Message.Message_Text;; end: Vojtech Huser, Harm Scherpbier: workflow tutorial Morgridge: Project proposal