diff --git a/protocols/DougiePop_comprehensive-retrieval-of-patient-appointment-records_c994be04/README.md b/protocols/DougiePop_comprehensive-retrieval-of-patient-appointment-records_c994be04/README.md new file mode 100644 index 00000000..83325aed --- /dev/null +++ b/protocols/DougiePop_comprehensive-retrieval-of-patient-appointment-records_c994be04/README.md @@ -0,0 +1,25 @@ +# Summary of the Comprehensive Retrieval of Patient Appointment Records Protocol + +The goal of this protocol is to ensure a complete and accurate retrieval of patient appointment records from the healthcare facility's electronic health record (EHR) system. This process aims to enhance healthcare delivery and administrative planning by providing a detailed overview of patient appointments. + +The protocol begins by identifying the initial population, which includes all registered patients within the EHR system, covering all departments and specialties. From this broad group, a subset is selected, focusing on patients who have had at least one appointment scheduled in the past 12 months. The protocol then outlines specific exclusion criteria to refine this subset further, ensuring that only relevant and active records are considered. + +Key recommendations include verifying the integrity of appointment data, generating comprehensive reports, documenting follow-up actions, and updating the EHR system to reflect any changes in appointment status. These steps are designed to maintain data accuracy and support effective healthcare management. + +### Important Information: + +- **Initial Population**: All registered patients in the EHR system, across all departments and specialties. +- **Subset in Consideration**: Patients with at least one appointment in the last 12 months. +- **Exclusion Criteria**: + 1. Patients who have opted out of data sharing or have privacy restrictions. + 2. Deceased patients with archived records. + 3. Patients with canceled appointments not rescheduled within 12 months. + 4. Patients marked as 'no-show' without follow-up or rescheduling. + +- **Actions Required**: + 1. **Diagnostic**: Cross-reference appointment data with departmental scheduling systems to ensure completeness. + 2. **Administrative**: Generate detailed reports of appointments, including date, time, department, and healthcare provider. + 3. **Therapeutic**: Document and communicate any necessary follow-up actions from past appointments. + 4. **Data Management**: Update the EHR system to reflect changes in appointment status, ensuring data accuracy for future retrievals. + +This protocol is essential for providing a comprehensive view of patient appointments, facilitating improved healthcare delivery and administrative efficiency. \ No newline at end of file diff --git a/protocols/DougiePop_comprehensive-retrieval-of-patient-appointment-records_c994be04/comprehensive-retrieval-of-patient-appointment-records.py b/protocols/DougiePop_comprehensive-retrieval-of-patient-appointment-records_c994be04/comprehensive-retrieval-of-patient-appointment-records.py new file mode 100644 index 00000000..7183d6bc --- /dev/null +++ b/protocols/DougiePop_comprehensive-retrieval-of-patient-appointment-records_c994be04/comprehensive-retrieval-of-patient-appointment-records.py @@ -0,0 +1,61 @@ +import arrow +from canvas_workflow_kit.patient import Patient +from canvas_workflow_kit.patient_recordset import PatientEventRecordSet +from canvas_workflow_kit.protocol import ClinicalQualityMeasure, ProtocolResult, STATUS_DUE, STATUS_SATISFIED +from canvas_workflow_kit.recommendation import DiagnoseRecommendation, AdministrativeRecommendation, InstructionRecommendation, DataManagementRecommendation +from canvas_workflow_kit.value_set import ValueSet +from canvas_workflow_kit.value_set.v2022 import OfficeVisit, BehavioralHealthFollowUpVisit, EncounterToDocumentMedications +from canvas_workflow_kit.value_set.v2020 import BmiEncounterCodeSet +class OptOutValueSet(ValueSet): + pass +class ClinicalProtocol(ClinicalQualityMeasure): + def in_initial_population(self) -> bool: + return True + def in_denominator(self) -> bool: + start_date = arrow.now().shift(months=-12) + end_date = arrow.now() + appointments = self.patient.reason_for_visits.find(OfficeVisit).before(end_date).after(start_date) + return len(appointments) > 0 + def in_numerator(self) -> bool: + opt_out = self.patient.conditions.find(OptOutValueSet) + deceased = self.patient.conditions.find(ValueSet).before(arrow.now()) + canceled_appointments = self.patient.reason_for_visits.find(OfficeVisit).before(arrow.now()).after(arrow.now().shift(months=-12)) + no_show_appointments = self.patient.reason_for_visits.find(OfficeVisit).before(arrow.now()).after(arrow.now().shift(months=-12)) + return len(opt_out) == 0 and len(deceased) == 0 and len(canceled_appointments) == 0 and len(no_show_appointments) == 0 + def compute_results(self) -> ProtocolResult: + result = ProtocolResult() + if not (self.in_initial_population() and self.in_denominator()): + result.status = STATUS_SATISFIED + else: + result.status = STATUS_DUE + if not self.in_numerator(): + diagnose_recommendation = DiagnoseRecommendation( + key='diagnose', + condition=OptOutValueSet, + title='Diagnose Opt-Out', + narrative='Diagnose the patient’s opt-out status.', + patient=self.patient + ) + administrative_recommendation = AdministrativeRecommendation( + key='administrative', + title='Generate Appointment Report', + narrative='Generate a comprehensive report of all appointments.', + patient=self.patient + ) + instruction_recommendation = InstructionRecommendation( + key='instruction', + title='Document Follow-Up Actions', + narrative='Ensure follow-up actions from past appointments are documented.', + patient=self.patient + ) + data_management_recommendation = DataManagementRecommendation( + key='data_management', + title='Update EHR System', + narrative='Update the EHR system to reflect changes in appointment status.', + patient=self.patient + ) + result.add_recommendation(diagnose_recommendation) + result.add_recommendation(administrative_recommendation) + result.add_recommendation(instruction_recommendation) + result.add_recommendation(data_management_recommendation) + return result \ No newline at end of file diff --git a/protocols/DougiePop_comprehensive-retrieval-of-patient-appointment-records_c994be04/diagram.dot b/protocols/DougiePop_comprehensive-retrieval-of-patient-appointment-records_c994be04/diagram.dot new file mode 100644 index 00000000..fac40837 --- /dev/null +++ b/protocols/DougiePop_comprehensive-retrieval-of-patient-appointment-records_c994be04/diagram.dot @@ -0,0 +1,35 @@ +digraph { + rankdir=TB; + + // Population Nodes + InitialPopulation [label="Initial Population", shape=box, style=rounded, color=green, fontcolor=green, comment="All registered patients within the healthcare facility's EHR system."]; + SubsetInConsideration [label="Subset in Consideration", shape=box, style=rounded, color=green, fontcolor=green, comment="Patients with at least one appointment scheduled within the last 12 months."]; + FinalPopulation [label="Final Population", shape=box, style=rounded, color=green, fontcolor=green, comment="Patients meeting all criteria for appointment record retrieval."]; + + // Criterion Nodes + AppointmentLast12Months [label="Appointment Last 12 Months", shape=ellipse, color=blue, fontcolor=blue, comment="Patients with at least one appointment scheduled within the last 12 months."]; + NotOptedOut [label="Not Opted Out", shape=ellipse, color=blue, fontcolor=blue, comment="Patients who have not opted out of data sharing or have unrestricted access to their appointment records."]; + NotDeceased [label="Not Deceased", shape=ellipse, color=blue, fontcolor=blue, comment="Patients who are not deceased and whose records are active in the EHR system."]; + NotCanceled [label="Not Canceled", shape=ellipse, color=blue, fontcolor=blue, comment="Patients whose appointments were not canceled without rescheduling within the 12-month period."]; + NotNoShow [label="Not No-Show", shape=ellipse, color=blue, fontcolor=blue, comment="Patients whose appointments are not marked as 'no-show' without follow-up or rescheduling."]; + + // Actions Nodes + Diagnostic [label="Diagnostic", shape=ellipse, color=blue, fontcolor=blue, comment="Verify the integrity and completeness of the appointment data."]; + Administrative [label="Administrative", shape=ellipse, color=blue, fontcolor=blue, comment="Generate a comprehensive report of all appointments for the subset of patients."]; + Therapeutic [label="Therapeutic", shape=ellipse, color=blue, fontcolor=blue, comment="Ensure follow-up actions from past appointments are documented and communicated."]; + DataManagement [label="Data Management", shape=ellipse, color=blue, fontcolor=blue, comment="Update the EHR system to reflect changes in appointment status."]; + + // Edges + InitialPopulation -> AppointmentLast12Months [label="if", color=blue, fontcolor=blue]; + AppointmentLast12Months -> NotOptedOut [label="and", color=blue, fontcolor=blue]; + NotOptedOut -> NotDeceased [label="and", color=blue, fontcolor=blue]; + NotDeceased -> NotCanceled [label="and", color=blue, fontcolor=blue]; + NotCanceled -> NotNoShow [label="and", color=blue, fontcolor=blue]; + NotNoShow -> SubsetInConsideration [label="then", color=blue, fontcolor=blue]; + + SubsetInConsideration -> Diagnostic [label="if", color=blue, fontcolor=blue]; + Diagnostic -> Administrative [label="and", color=blue, fontcolor=blue]; + Administrative -> Therapeutic [label="and", color=blue, fontcolor=blue]; + Therapeutic -> DataManagement [label="and", color=blue, fontcolor=blue]; + DataManagement -> FinalPopulation [label="then", color=blue, fontcolor=blue]; +} \ No newline at end of file diff --git a/protocols/DougiePop_comprehensive-retrieval-of-patient-appointment-records_c994be04/diagram.svg b/protocols/DougiePop_comprehensive-retrieval-of-patient-appointment-records_c994be04/diagram.svg new file mode 100644 index 00000000..01a0bcc7 --- /dev/null +++ b/protocols/DougiePop_comprehensive-retrieval-of-patient-appointment-records_c994be04/diagram.svg @@ -0,0 +1,198 @@ + + + + + + +%3 + + + +InitialPopulation + + +Initial Population + + + + + +AppointmentLast12Months + + +Appointment Last 12 Months + + + + + +InitialPopulation->AppointmentLast12Months + + +if + + + +SubsetInConsideration + + +Subset in Consideration + + + + + +Diagnostic + + +Diagnostic + + + + + +SubsetInConsideration->Diagnostic + + +if + + + +FinalPopulation + + +Final Population + + + + + +NotOptedOut + + +Not Opted Out + + + + + +AppointmentLast12Months->NotOptedOut + + +and + + + +NotDeceased + + +Not Deceased + + + + + +NotOptedOut->NotDeceased + + +and + + + +NotCanceled + + +Not Canceled + + + + + +NotDeceased->NotCanceled + + +and + + + +NotNoShow + + +Not No-Show + + + + + +NotCanceled->NotNoShow + + +and + + + +NotNoShow->SubsetInConsideration + + +then + + + +Administrative + + +Administrative + + + + + +Diagnostic->Administrative + + +and + + + +Therapeutic + + +Therapeutic + + + + + +Administrative->Therapeutic + + +and + + + +DataManagement + + +Data Management + + + + + +Therapeutic->DataManagement + + +and + + + +DataManagement->FinalPopulation + + +then + + + diff --git a/protocols/DougiePop_comprehensive-retrieval-of-patient-appointment-records_c994be04/spec.yaml b/protocols/DougiePop_comprehensive-retrieval-of-patient-appointment-records_c994be04/spec.yaml new file mode 100644 index 00000000..65ea70c1 --- /dev/null +++ b/protocols/DougiePop_comprehensive-retrieval-of-patient-appointment-records_c994be04/spec.yaml @@ -0,0 +1,9 @@ +status: "draft" +githubUrl: "" +contributors: + - username: "DougiePop" +referencePapers: + - title: "Patient Appointment Records Retrieval Protocol" + description: "This protocol outlines the process for retrieving and managing patient appointment records from the EHR system. It focuses on patients with appointments in the last 12 months, excluding those with privacy restrictions, cancellations, or no-shows. Actions include verifying data integrity, generating reports, documenting follow-ups, and updating appointment statuses to ensure accurate healthcare delivery and planning." + url: "" +