Currently submitted to: JMIR AI
Date Submitted: Oct 11, 2026
Open Peer Review Period: Oct 23, 2026 - Dec 18, 2026
(currently open for review)
Warning: This is an author submission that is not peer-reviewed or edited. Preprints - unless they show as "accepted" - should not be relied on to guide clinical practice or health-related behavior and should not be reported in news media as established information.
Guideline-Constrained Large Language Models for Auditable Clinical Decision Support: Development and Validation of Urology CoPilot
ABSTRACT
Background:
Evidence-based care improves outcomes, but consistent application is difficult: guidelines are numerous, complex, and frequently revised. Large language models (LLMs) may support adherence, but pre-training misses recent updates and open-ended generation risks hallucination. We hypothesized that constraining an LLM to a "Guideline Mode" using structured pathways would improve accuracy and auditability.
Objective:
To develop a guideline-constrained, retrieval-augmented LLM (Urology CoPilot) and compare its algorithm selection, next-step accuracy, and information-seeking behavior against unconstrained GPT-5.5 across 12 AUA algorithms.
Methods:
We converted 12 American Urological Association (AUA) algorithm PDFs into JSON decision-tree graphs and built Urology CoPilot, which uses embedding-based retrieval to identify the relevant algorithm from a free-text history of present illness (HPI). In “Guideline Mode,” GPT-5.5 is constrained to the retrieved pathway to locate the patient’s current node, recommend the next step or request missing data, and cite verbatim supporting evidence. We ran 102 HPIs matching an AUA algorithm (plus 10 out-of-scope HPIs) with Guideline Mode ON versus OFF, using the same model and prompt, and scored algorithm selection, next-step accuracy, and requests for additional information against strict algorithm adherence.
Results:
CoPilot retrieved the correct algorithm in 99 of 102 HPIs (97%); among 10 separate HPIs describing conditions absent from the database, 9 correctly returned none (90%). Among correctly retrieved HPIs, Guideline Mode ON recommended the guideline-concordant next step in 82.8% (82/99) versus 30.3% (30/99) OFF (difference 52.5 percentage points; 95% CI, 39.9 to 65.2; McNemar P < 0.001). The advantage concentrated at algorithm entry: 100% (44/44) versus 6.8% (3/44) at sentinel nodes (P < 0.001), compared to 69.1% (38/55) versus 49.1% (27/55) downstream (P = 0.052). At sentinel nodes, Guideline Mode ON requested additional information in 39 of 44 cases (88.6%) versus 4 of 44 (9.1%). Node localization was correct in 81.8% (81/99); all 17 next-step errors followed localization failure. In 10 HPIs reviewed by three urologists, attendings were guideline-concordant in 15 of 30 reviews (50%; Fleiss' κ = 0.07).
Conclusions:
Constraining LLM output to structured pathways improves accuracy and auditability. The benefit was largest at algorithm entry, where CoPilot requested missing workup rather than advancing an incompletely evaluated patient. Residual error was confined to node localization, an addressable failure mode.
Citation
Request queued. Please wait while the file is being generated. It may take some time.
Copyright
© The authors. All rights reserved. This is a privileged document currently under peer-review/community review (or an accepted/rejected manuscript). Authors have provided JMIR Publications with an exclusive license to publish this preprint on it's website for review and ahead-of-print citation purposes only. While the final peer-reviewed paper may be licensed under a cc-by license on publication, at this stage authors and publisher expressively prohibit redistribution of this draft paper other than for review purposes.