Zing Forum

Reading

PathWISE: Multi-Agent System Converts Clinical Flowcharts into Executable Medical Decision Support—The Automated Revolution of Cancer Triage Pathways

Introducing the PathWISE system, a five-stage multi-agent pipeline that uses four LLM agents combined with deterministic auditing and a Java compiler to convert unstructured clinical flowcharts into validated, executable HL7 CQL clinical decision support services.

PathWISE临床路径医疗AICQLFHIRCDS Hooks多智能体系统癌症分诊临床决策支持医疗信息化
Published 2026-05-25 23:47Recent activity 2026-05-26 14:21Estimated read 8 min
PathWISE: Multi-Agent System Converts Clinical Flowcharts into Executable Medical Decision Support—The Automated Revolution of Cancer Triage Pathways
1

Section 01

PathWISE: Multi-Agent System Enables Automated Conversion of Clinical Flowcharts to Executable Medical Decision Support

PathWISE is a five-stage multi-agent pipeline system designed to address the digital divide where clinical flowcharts are 'human-readable but machine-unreadable'. It uses four LLM agents combined with deterministic auditing and a Java compiler to convert unstructured clinical flowcharts into validated, executable HL7 CQL clinical decision support services, which can be deployed as FHIR CDS Hooks services to facilitate the automation upgrade of healthcare informatization and clinical decision support.

2

Section 02

Digital Dilemma of Clinical Flowcharts and PathWISE's Core Mission

Clinical pathways are important tools for standardizing diagnosis and treatment and improving quality. However, pathways presented as visual flowcharts—containing visual information such as spatial topology and color coding—become 'non-computable artifacts', leading to a disconnect between guidelines and IT systems. PathWISE's mission is to convert these unstructured flowcharts into validated executable CQL libraries, addressing four core challenges: visual information extraction, semantic understanding, computability verification, and governance compliance.

3

Section 03

Five-Stage Multi-Agent Pipeline: Full Process from Flowchart to Executable Code

PathWISE's five-stage architecture includes:

  1. Structure Extraction Agent: Converts flowchart images into typed directed graphs, identifying nodes, edges, and semantic types;
  2. Path Enumeration Agent: Enumerates all patient journeys through deterministic graph traversal, achieving full coverage and reachability analysis;
  3. Semantic Audit Agent: Evaluates node definition completeness, terminology standardization, logical consistency, and data availability;
  4. CQL Generation Agent: Uses a terminology constraint strategy to generate zero-hallucination CQL code;
  5. Compilation Verification Layer: Ensures code syntax correctness and executability via the official Java CQL compiler.
4

Section 04

Technical Highlight: Separation Design of Deterministic Verification and LLM Reasoning

PathWISE's key design principle is to limit non-deterministic LLM reasoning to the knowledge extraction phase, while using deterministic graph mathematics and standard compilers to support verification steps. This separation brings three major advantages:

  • Auditability: Verification steps are reproducible, and issues can be precisely traced;
  • Error Isolation: LLM errors are captured by subsequent verification;
  • Progressive Improvement: Clearly distinguishes between LLM capability limitations and flowchart-specific issues, facilitating targeted optimization.
5

Section 05

Experimental Validation: Test Results on Five NHS Cancer Pathways

PathWISE was tested on five NHS pathways for colorectal cancer, lung cancer, skin cancer, upper gastrointestinal cancer, and breast cancer, covering complex scenarios with up to 183 nodes. Key metrics include:

Metric Result
Node audit coverage 100%
Syntax compilation success rate 100%
Terminology hallucination rate 0%
Number of governance findings 544
Patient journey coverage 100%
Governance findings are categorized into four types: missing definitions, unmapped terminology, ambiguous logic, and data gaps, providing directions for clinical improvement.
6

Section 06

Deployment Architecture: Seamless Integration with FHIR CDS Hooks Services

The CQL libraries generated by PathWISE can be deployed as FHIR CDS Hooks services. The interaction process is as follows:

  1. EHR Trigger: Sends a CDS Hook request when a doctor performs an operation;
  2. Data Acquisition: Retrieves patient data from the FHIR server;
  3. CQL Execution: Evaluates whether the patient meets the pathway criteria;
  4. Recommendation Generation: Generates personalized clinical recommendations;
  5. Card Return: Displays to the doctor in CDS Cards format to enable real-time decision support.
7

Section 07

Clinical Impact and Future Research Directions

Clinical Impact:

  • Improves guideline adherence and eliminates the 'guideline-practice gap';
  • Automates quality monitoring and identifies cases deviating from pathways;
  • Promotes cross-institutional pathway standardization and best practice sharing. Future Directions:
  • Multilingual expansion;
  • Dynamic pathway processing;
  • Patient-specific adaptation;
  • Multimodal input support (hand-drawn/oral).
8

Section 08

Conclusion: The Rigorous Path of Medical AI and the Paradigm Significance of PathWISE

PathWISE demonstrates the combination of LLM capabilities and medical reliability requirements. Through agent collaboration, deterministic verification, and progressive auditing, it ensures clinical safety. In the field of medical AI, 'move slowly and verify strictly' is a core principle. PathWISE's technical route provides a valuable reference paradigm for this field and will play an important role in improving medical quality and reducing errors.