8 Surgery and Perioperative Care
Surgery combines technical skill, anatomical knowledge, and split-second decision-making under pressure. AI applications span preoperative risk assessment, intraoperative guidance, and postoperative monitoring. This chapter examines evidence-based AI tools for surgical specialties. You will learn to:
- Evaluate AI systems for surgical risk prediction and optimization
 - Understand computer vision applications in robotic and minimally invasive surgery
 - Assess AI tools for surgical phase recognition and workflow analysis
 - Navigate AI-assisted surgical planning and simulation
 - Identify postoperative complication prediction systems
 - Recognize limitations and failure modes of surgical AI
 - Balance AI augmentation with surgical judgment and technical skill
 
Essential for surgeons across all specialties, anesthesiologists, perioperative nurses, and surgical quality teams.
8.1 Introduction
Surgery stands apart from other medical specialties in its immediacy, irreversibility, and technical demands. While radiologists can analyze images over minutes, surgeons make split-second decisions with scalpel in hand. While internists can adjust management based on patient response, surgical decisions—once made—cannot be easily undone.
This unique context shapes how AI can and cannot help surgeons. The most promising applications assist with the cognitive work surrounding surgery (risk assessment, planning, outcome prediction) rather than replacing the surgeon’s hands or judgment during the operation itself.
This chapter examines surgical AI applications across the perioperative spectrum, from preoperative optimization through postoperative care, with critical attention to what works, what doesn’t, and what remains science fiction.
8.2 Preoperative AI Applications
8.2.1 Surgical Risk Prediction
The Clinical Problem:
Surgeons face a fundamental question before every operation: Will this patient tolerate this procedure? Traditional risk assessment relies on clinical judgment supplemented by scoring systems (ASA classification, NSQIP risk calculator, RCRI for cardiac surgery). These tools have limitations:
- Incorporate limited variables (20-30 factors)
 - Use linear models that miss complex interactions
 - Provide population-level estimates, not personalized predictions
 - Updated infrequently as new evidence emerges
 
Machine Learning Solutions:
Modern ML approaches improve risk prediction by:
- Analyzing larger feature sets: 100+ variables from EHR, imaging, labs, medications, vital signs, social determinants
 - Capturing nonlinear relationships: Age × frailty × procedure complexity interactions
 - Continuous learning: Models updated with new outcome data
 - Personalized predictions: Patient-specific risk estimates rather than population averages
 
Evidence:
The MySurgeryRisk algorithm developed at University of Florida analyzed 400,000+ surgical cases and significantly outperformed traditional risk models (bihorac2019mysurgeryriskal?):
- 30-day mortality prediction: AUC 0.94 (vs. 0.89 for ASA score)
 - Major complications: AUC 0.88 (vs. 0.82 for NSQIP)
 - ICU admission: AUC 0.91
 - Hospital length of stay: Better calibration across risk spectrum
 
Similar results from other institutions: Stanford, Partners Healthcare, Penn Medicine all report improved risk prediction using ML on local data.
Clinical Applications:
Preoperative Optimization: - Identify modifiable risk factors (anemia, hyperglycemia, nutritional deficits) - Triage patients for preoperative clinic vs. day-of-surgery admission - Guide prehabilitation referrals
Shared Decision-Making: - Provide personalized risk estimates during surgical consults - Facilitate discussions about alternative treatments - Support goals-of-care conversations for high-risk patients
Resource Allocation: - Predict ICU vs. floor bed requirements - Identify patients needing enhanced postoperative monitoring - Optimize OR scheduling based on predicted case duration
Quality Improvement: - Risk-adjust outcome comparisons between surgeons/hospitals - Identify outliers for focused improvement efforts - Benchmark performance against predicted outcomes
Critical Limitations:
⚠️ Risk calculators should inform, not dictate, surgical decisions:
- Algorithms miss important factors: patient goals, functional trajectory, social support, frailty nuances
 - High-risk patients may still benefit from surgery if alternative is certain poor outcome
 - Low-risk predictions don’t guarantee good outcomes
 - Models trained on one population may not generalize to different populations
 
Clinical Bottom Line: Use risk prediction AI to enhance shared decision-making and optimize preoperative preparation. Do not deny surgery based solely on algorithmic risk scores.
8.2.2 Preoperative Planning and Simulation
AI-Assisted Anatomical Segmentation:
Surgical planning for complex cases (oncologic resections, liver surgery, orthopedic reconstructions) traditionally requires manual analysis of CT/MRI to identify anatomy, plan approaches, and anticipate challenges. AI automates and enhances this process:
Applications:
Oncologic Surgery: - Tumor segmentation and volumetry - Relationship to critical structures (vessels, bile ducts, nerves) - Predicted resection margins - Assessment of resectability
Liver Surgery: - Vascular and biliary anatomy mapping - Liver volumetry for donation or resection planning - Future liver remnant calculation - Virtual hepatectomy simulation
Orthopedic Surgery: - Joint replacement planning (alignment, component sizing) - Osteotomy planning for deformity correction - Fracture reduction simulation - Bone tumor resection planning
Neurosurgery: - Brain tumor segmentation and eloquent cortex mapping - Surgical approach trajectory planning - Vascular anatomy for aneurysm clipping - Epilepsy focus localization
Evidence:
Studies across multiple surgical specialties show AI segmentation (Hashimoto et al. 2018): - Reduces planning time by 60-80% compared to manual segmentation - Achieves inter-rater reliability comparable to expert-to-expert agreement - Improves standardization of preoperative assessment (Topol 2019) - Enhances patient counseling with 3D visualizations
Limitations:
- Segmentation errors can propagate to surgical plans (always verify)
 - Quality depends on input imaging (motion artifacts, contrast timing)
 - Doesn’t account for intraoperative findings (adhesions, variant anatomy)
 - Most effective for anatomy-driven procedures with good imaging
 
3D Printing and Surgical Models:
AI-segmented anatomy can be converted to 3D-printed models for: - Pre-surgical rehearsal of complex cases - Patient education and consent - Trainee education - Custom surgical guides and implants
Clinical Impact: Mixed. Some studies show reduced operative time and improved outcomes for complex cases; others show no benefit beyond surgeon confidence. Cost and workflow integration remain barriers to widespread adoption.
8.3 Intraoperative AI Applications
8.3.1 Computer Vision in Minimally Invasive Surgery
The laparoscope and robotic camera create continuous video streams—ideal data for computer vision AI. Applications range from documentation to real-time guidance, with varying degrees of validation and clinical readiness.
Surgical Phase Recognition:
What it does: AI analyzes surgical video and identifies current phase (e.g., “dissection of gallbladder from liver bed” in laparoscopic cholecystectomy)
How it works: Deep learning models trained on annotated surgical videos learn to recognize instrument configurations, anatomical landmarks, and surgeon actions characteristic of each phase.
Performance: - Accuracy >90% for laparoscopic cholecystectomy (twinanda2017endonet?) - Works across multiple procedures (bariatric, colorectal, gynecologic) - Real-time capability (15-30 frames/second)
Potential applications: - Context-aware instrument tracking - Automated surgical documentation - OR efficiency analysis - Surgical skill assessment - Adverse event detection
Current status: Primarily research tool. Limited clinical deployment because phase recognition alone doesn’t provide actionable guidance—surgeons already know which phase they’re in.
Future potential: Phase recognition is foundational for more advanced applications (predictive alerts, context-aware instrument suggestions).
Anatomical Structure Recognition:
The promise: Computer vision identifies critical anatomy (bile ducts, ureters, vessels) to prevent surgical injury.
The reality: This is extraordinarily difficult and not yet clinically reliable.
Why it’s hard:
- Visual variability: Blood, smoke, retraction, lighting changes, cautery artifacts
 - Anatomical variants: Textbook anatomy is the exception, not the rule
 - Dynamic deformation: Tissue moves, stretches, changes appearance continuously
 - Occlusion: Critical structures often partially hidden
 - Context-dependence: What looks like ureter may be vessel or adhesion band
 
Current evidence:
Research systems demonstrate: - 70-85% accuracy for identifying major structures in ideal conditions - Performance degrades significantly with bleeding, inflammation, obesity - False positives and false negatives both occur at unacceptable rates
Critical safety concern:
❌ Surgeons cannot rely on AI to definitively identify critical structures. Visual confirmation, tactile feedback, anatomical knowledge, and methodical dissection remain essential. AI suggesting “safe to divide this structure” is not acceptable with current technology.
More promising near-term application:
⚠️ Warning systems: AI detecting absence of expected structures (“ureter not identified in expected location—double-check before dividing anything”) may be safer than positive identification. Alert surgeons to uncertainty rather than provide false confidence.
8.3.3 AI in Robotic Surgery
Current State: No Autonomy
Despite “robotic surgery” terminology, da Vinci and similar systems are teleoperated tools, not autonomous robots. The surgeon controls every movement. AI plays minimal role in current clinical robotic systems.
Emerging AI Applications:
Surgical Skill Assessment: - AI analyzes instrument paths, economy of motion, smoothness - Provides objective feedback for training - Correlates with surgical experience and patient outcomes (gumbs2021artificial?) - Used in residency training programs
Tremor Filtering: - Robot compensates for physiologic tremor - Standard feature, not novel AI (rule-based filtering) - Improves precision for microsurgical tasks
Autonomous Task Execution (Research Only):
The STAR (Smart Tissue Autonomous Robot) performed supervised autonomous bowel anastomosis in pigs (shademan2016supervised?). This proof-of-concept demonstrated technical feasibility but:
❌ Not FDA-approved ❌ Not tested in humans ❌ Requires perfect conditions (no bleeding, adhesions, or unexpected anatomy) ❌ Slower than human surgeons ❌ Monitoring surgeon must be ready to intervene instantly
Verdict: Fully autonomous robotic surgery remains research. Variability of human anatomy, tissue properties, and intraoperative findings far exceeds AI’s ability to safely respond without human judgment.
More realistic future: Semi-autonomous assistance for repetitive sub-tasks (suturing, tissue dissection in clear planes) under continuous surgeon supervision.
8.4 Postoperative AI Applications
8.4.1 Complication Prediction
Surgical Site Infection (SSI) Prediction:
ML models predict SSI risk using: - Patient factors (diabetes, obesity, smoking, immunosuppression) - Operative characteristics (duration, complexity, contamination class) - Intraoperative variables (glucose control, normothermia, antibiotic timing) - Postoperative factors (drain output, pain scores)
Evidence: Modest improvements over clinical judgment alone (AUC 0.75-0.80 vs. 0.70-0.72).
Limitations: - High false positive rates (30-40%) limit actionability - Shouldn’t guide prophylactic antibiotic decisions (risk of resistance) - Best use: Enhanced surveillance for high-risk patients
Postoperative Delirium:
Prediction models incorporating preoperative cognitive assessment, anesthesia factors, and postoperative medications identify high-risk patients for: - Non-pharmacologic prevention (reorientation, sleep hygiene, family presence) - Avoidance of deliriogenic medications - Enhanced monitoring
Evidence: Better than clinical intuition, but delirium remains multifactorial and incompletely preventable.
Anastomotic Leak Prediction:
ML models analyzing postoperative labs (CRP trajectory), vital signs, and clinical notes can identify leak risk earlier than clinical suspicion alone.
Challenge: Rare outcomes (1-5% incidence) make model training difficult and false positive rates high.
8.4.2 Deterioration Monitoring
AI systems analyzing continuous vitals, lab trends, nursing documentation, and medication administration can detect patterns predicting clinical deterioration 6-12 hours before conventional early warning scores.
Applications: - Postoperative hemorrhage - Respiratory failure - Sepsis - Cardiac events
Evidence: Detection performance generally good, but high false positive rates create alert fatigue (similar to sepsis prediction challenges discussed in Chapter 9) (Wong et al. 2021; Beam, Manrai, and Ghassemi 2020).
Best Implementation: Integrate AI alerts with rapid response team protocols and ensure alerts are actionable (not just “patient is high-risk”) (Topol 2019).
8.5 Surgical Quality and Education
8.5.1 Video-Based Surgical Assessment
AI analysis of surgical videos enables objective skill assessment and quality improvement.
Applications:
Skill Scoring: - Objective assessment of technical performance - Identifies specific errors (tissue trauma, bleeding, inefficiency) - Provides quantitative feedback for training
Evidence: AI scores correlate strongly with expert human assessment and predict surgical outcomes (gumbs2021artificial?).
Benefits for surgical education: - Objective feedback supplements subjective faculty evaluation - Tracks skill progression over time - Identifies specific areas needing improvement - Benchmarks against peer performance
Quality Improvement: - Retrospective review of complications to identify technical factors - Process improvement for OR efficiency - Standardization of surgical techniques
Challenges: - Privacy and medicolegal concerns about routine recording - Surgeon resistance to surveillance - Doesn’t capture decision-making quality (only technical execution) - Storage and analysis infrastructure requirements
8.5.2 Natural Language Processing for Operative Notes
AI extraction of structured data from operative notes enables:
Quality Metrics: - Automated calculation of process measures (antibiotic timing, VTE prophylaxis) - Complication detection from dictated notes - Adherence to surgical best practices
Registry Auto-Population: - Reduces manual data entry burden for NSQIP, VASQIP, other registries - Improves data completeness and accuracy
Clinical Decision Support: - Extraction of critical operative details for downstream care (mesh type in hernia repair, prosthesis in joint replacement)
Evidence: High accuracy (>95%) for structured data elements. Challenges remain for nuanced surgical findings and judgment-based assessments.
8.6 Critical Limitations and Risks
Immediacy of Harm: Unlike diagnostic errors that can be caught through physician review, intraoperative AI errors cause immediate, potentially irreversible patient harm.
Complexity of Surgical Judgment: Surgery requires integration of visual, tactile, and proprioceptive information with anatomical knowledge, pattern recognition from thousands of prior cases, and real-time adaptation to unexpected findings. AI doesn’t replicate this.
Medico legal Implications: If a surgeon follows AI guidance and causes injury, liability is clear: the surgeon is responsible. If surgeon ignores AI warning and causes injury, plaintiff’s attorneys will argue AI was ignored. This creates defensive pressure to over-rely on AI even when clinical judgment suggests otherwise.
Technology Failure Modes: Computer vision fails with blood, smoke, optical artifacts. ML models fail with out-of-distribution inputs (unusual anatomy, rare findings). Risk models fail when patient circumstances differ from training data.
Trust Calibration: Surgeons must neither over-trust (following AI suggestions without verification) nor under-trust (ignoring useful AI alerts). Achieving appropriate calibration is difficult (Char, Shah, and Magnus 2018).
8.7 Evidence-Based Guidelines for Surgical AI Adoption
Before Adopting Any Surgical AI:
- Demand evidence: Prospective validation studies in diverse populations, not just retrospective accuracy metrics (Nagendran et al. 2020)
 - Understand training data: Was the model trained on cases like yours? (Procedure types, patient populations, institutional practices) (Beam, Manrai, and Ghassemi 2020)
 - Know the failure modes: How does the system fail? What are the error rates? What happens with unusual cases? (vabalas2019machine?)
 - Assess workflow integration: Does this fit your existing workflow or require disruptive changes?
 - Clarify liability: What does your malpractice carrier say about using this AI? What does hospital legal counsel advise?
 - Verify regulatory status: Is this FDA-cleared? For what specific indication?
 - Evaluate cost-effectiveness: Does the benefit justify the cost (both financial and cognitive/workflow burden)?
 
Safe Implementation Practices:
- Pilot testing: Start with low-stakes applications, expand carefully based on performance
 - Parallel validation: Run AI alongside current practice, compare results before replacing current approach
 - Defined oversight: Clear protocols for who reviews AI outputs and how discrepancies are resolved
 - Incident reporting: Systems to capture AI errors or near-misses
 - Ongoing validation: Monitor real-world performance, don’t assume initial validation persists indefinitely
 - User training: Ensure all users understand AI capabilities, limitations, and appropriate use
 - Informed consent: Discuss AI use with patients when material to their decision-making
 
Red Flags (Avoid These AI Systems):
❌ Claims of autonomous surgical decision-making ❌ Black-box models with no explanation of predictions ❌ Lack of prospective validation studies ❌ Vendors unwilling to disclose training data characteristics ❌ No mechanism for reporting errors or failures ❌ Regulatory status unclear or misrepresented ❌ Pressure to adopt without adequate evaluation period
8.8 Future Directions
Realistic Near-Term Progress (2-5 years): - Routine integration of ML risk calculators into preoperative clinics - Expanded use of AI surgical planning for complex cases - Video-based quality feedback becoming standard in training - Better postoperative monitoring with AI-augmented early warning systems
Medium-Term Possibilities (5-10 years): - Improved real-time anatomical recognition (still with human verification required) - Context-aware intraoperative decision support (suggestions, not autonomous action) - Personalized surgical technique optimization based on patient anatomy - Semi-autonomous robotic assistance for specific sub-tasks under continuous human supervision
Long-Term Speculation (10+ years): - Highly accurate real-time tissue characterization (pathology-level information intraoperatively) - Predictive models anticipating surgical course and complications with high accuracy - Integration of multi-omic patient data into surgical decision-making - Robotic systems handling increasing proportions of routine surgical tasks (still under surgeon control)
Unlikely Despite Hype: - Fully autonomous robotic surgery without surgeon in the loop - AI replacing surgical judgment for complex, high-stakes decisions - Elimination of surgical complications through AI
8.9 Conclusion
Surgery is fundamentally a human activity requiring manual skill, real-time judgment, and adaptation to unique patient circumstances. AI can enhance the cognitive work surrounding surgery—risk assessment, planning, quality improvement—and may eventually provide useful intraoperative information. But the surgeon’s hands, eyes, judgment, and responsibility remain central.
The most successful surgical AI applications will be those that respect the complexity of surgery, acknowledge uncertainty transparently, augment rather than replace expertise, and prioritize patient safety over technological impressiveness.
Surgeons should embrace AI as a powerful adjunct while maintaining the healthy skepticism, independent verification, and personal accountability that define good surgical practice.