\section{Example Generated Programs}



Algorithm ~\ref{alg:liver-assessment} provides an illustrative example of the type of 
clinical logic executed by INFORM-CT. Starting from the segmented liver masses, 
the algorithm computes lesion-level attributes—including diameter, radiological 
features, and patient-specific risk factors—and applies the decision rules derived 
from the ACR guidelines to produce per-lesion recommendations. These are then 
aggregated into a patient-level follow-up recommendation. 

\input{algorithms/algorithm_liver}

While simplified for 
clarity, this example captures the core reasoning steps synthesized automatically 
by the planner–executor framework, which generates similar structured programs 
for all organs and guideline pathways.


{\noindent\textbf{Pipeline failures.}} {
We observe failure cases where segmentation is correct, but the downstream interpretation of imaging features is incorrect. For example, in one case the system correctly segmented three hepatic masses with sizes of approximately 2.0 cm, 0.7 cm, and 0.4 cm. According to the ground truth, the imaging appearance was benign and did not warrant additional follow-up. However, the model classified the findings as having “suspicious features,” which triggered a more conservative guideline pathway and an incorrect recommendation for further imaging. These failure could happen even though the question was decomposed into a small building blocks }

{\noindent\textbf{Planning strategies.}} {Here are a few examples demonstrating the planner solution to complex decisions required by the guidelines.
In Algorithm~\ref{alg:decompose_high_risk}, we illustrate the planner’s decomposition mechanism, where a top high-level concept (“high-risk features”) is expanded into a set of down atomic, interpretable VLM queries (e.g., mural nodules, solid components, ductal dilation). This produces per-factor confidence scores that can be explicitly aggregated according to clinical rules, yielding an interpretable risk assessment. }
\input{algorithms/algorithm_decomposed_high_risk_factors}

{Complementarily, The pipeline sometimes has to fuse global and local information, not only classification of  mass-level properties.  Algorithm~\ref{alg:mpd_comm_query} demonstrates the use of the VLM to answer a contextual anatomical question—main pancreatic duct (MPD) communication—that is not directly tied to the segmented lesion.}

% \input{figures/algorithm_lung}
% \input{figures/algorithm_pancreas}\textbf{}

\input{algorithms/algorithm_mpd_communication}

% \input{algorithms/algorithm_classical_meaures}
