Abstract
Objective
To optimize incision placement for uniportal endoscopic lumbar fusion using computational methods to maximize disc and endplate preparation.
Methods
We analyzed 605 axial lumbar MRI images from 121 patients in an institutional development cohort and 120 MRI images from 40 patients in an independent external validation cohort. A parametric MRI-based anatomical delineation system was developed to define the relevant surgical anatomy, and genetic algorithm optimization was used to determine optimal incision placement. Machine learning was then used to predict optimal incision positions from MRI-derived anatomical features, including disc morphology, Kambin’s triangle width, dural sac width, and posterior longitudinal ligament-to-skin distance.
Results
Genetic algorithm optimization identified level-specific optimal incision distances: 58.93 ± 10.19 mm (L1-2), 63.31 ± 9.84 mm (L2-3), 67.79 ± 12.82 mm (L3-4), 83.89 ± 13.69 mm (L4-5), and 95.28 ± 19.38 mm (L5-S1). Under a patient-level framework, the artificial neural network (ANN) showed the best performance in predicting the GA-derived optimal incision position from MRI-derived anatomical features (internal validation R2 = 0.935; external validation R2 = 0.918 [95% CI, 0.869–0.947] and MAE = 6.08 mm [95% CI, 5.17–7.10]). The model was deployed online for real-time patient-specific planning.
Conclusion
A web-based computational planning tool was developed to optimize incision placement and maximize disc and endplate preparation in uniportal endoscopic lumbar fusion. This approach may support patient-specific preoperative planning.
Keywords
Introduction
The concept of uniportal spinal endoscopy was pioneered by Kambin and Hijikata in the 1980s–1990s1–3 and has since undergone significant advancements, now reaching its third generation. 4 Initially, the spinal endoscope was utilized exclusively for discectomy due to the constraints of a narrow working canal. However, in recent years, the introduction of a wider working canal (OD: 9–10 mm; WC: 5.5 mm; angle: 12–20°) has facilitated the incorporation of larger surgical instruments, including Kerrison punches, burrs, chisels, curettes, pituitary forceps, and shavers. This evolution has made lumbar fusion surgery via uniportal spinal endoscopy a viable technique. Currently, two primary approaches are employed in uniportal spinal endoscopy: the posterior-lateral (facet-sparing) approach and the trans-Kambin approach, which involves facet resection. 5
While the trans-Kambin approach has traditionally preserved more of the facet joint, recent advancements, such as the Kambin Torpedo full-endoscopic lumbar interbody fusion technique, have enabled bilateral decompression through meticulous trajectory planning.
6
Despite these advancements, the limited working area of uniportal endoscopy, particularly with smaller instruments such as pituitary forceps, restricts the grasping field in comparison to traditional or biportal techniques (Figure 1). Instruments such as pituitary forceps or curettes primarily facilitate the removal of disc material visible in the central field of view. Given that the incision in endoscopic surgery is typically less than one centimeter, it serves as a pivotal rotational fulcrum for endoscopic maneuvers. Surgical movements are performed in a fan-shaped sweeping motion around this fulcrum to access the target site for grinding, tissue retrieval, or excision. As a result, the placement of the incision is a critical factor influencing the achievable volume of disc and cartilage endplate preparation during surgery (Figure 2). On the left is a traditional pituitary forcep. The forceps are noticeably larger than the pituitary forceps used in the uniportal endoscope, shown in the middle and on the right. The left image illustrates traditional surgery. In this the pituitary forceps can be adjusted freely in the angle and position. In contrast, the middle and right images depict uniportal endoscopic discectomy, in which the incision acts as a rotational pivot or fulcrum, limiting the extent of discectomy and endplate preparation.

The extent of endplate and disc preparation directly impacts fusion success by determining the contact area for bone graft placement. A larger graft-bone interface enhances the likelihood of successful fusion. Studies suggest that at least 40% of the transverse sectional area of the vertebral bodies should be covered by the graft to ensure adequate axial load-bearing capacity postoperatively. 7 Additionally, research indicates that achieving more than 30% endplate and disc preparation improves structural stability and fusion rates. Biomechanical analysis has demonstrated that a vertebral endplate surface coverage exceeding 30% is necessary to achieve rigid interbody fusion, with a higher proportion of vertebral bodies exhibiting sufficient load-bearing capacity at this threshold.8,9 Furthermore, bone graft volume plays a crucial role in fusion outcomes. A graft volume exceeding 12 cm3 has been associated with significantly improved fusion rates. Given that the average lumbar disc volume is approximately 17 cm3, achieving an adequate bone graft volume that sufficiently covers the original disc area is essential for successful fusion. 10 However, attaining this target requires extensive discectomy and meticulous endplate preparation to create an optimal space for graft placement. 11
Previous studies have shown that even with larger incisions in MIS-TLIF, performing discectomy in the posterior-contralateral quadrant remains challenging. 12 Unlike traditional methods, endoscopic approaches allow for precise cartilage endplate preparation while preserving the bony endplate. A study has demonstrated that the bone graft area and area ratio were significantly higher in the endoscopic than in the mini-open TLIF group. 13 However, since the incision for uniportal endoscopic fusion is approximately one centimeter, it serves as a pivotal hinge for endoscopic maneuvering. When combined with the constraints of smaller discectomy instruments compared to those used in traditional open or minimally invasive surgery, meticulous preoperative planning becomes essential. The extent of the discectomy varies depending on incision placement, making optimization critical to maximizing disc and endplate removal. The greater the extent of endplate and disc preparation, the larger the available space for intervertebral bone graft insertion, increasing the contact surface area between the graft and the vertebral bony endplate. This increased graft-endplate interface has been associated with improved biomechanical conditions for fusion in previous studies. However, despite the known biomechanical and clinical significance of these factors, systematic research on the influence of incision placement on surgical outcomes in uniportal spinal endoscopic fusion remains limited, particularly across different lumbar levels and patient anatomies. Recent advancements in medical informatics increasingly leverage robust hybrid models and metaheuristic optimization to navigate complex nonlinear dynamics, proving effective across diverse clinical and real-time diagnostic domains.14–16 By adopting a similar computational framework, this study aligns with the evolving trend of using advanced AI-driven algorithms to enhance planning precision in constrained surgical environments.
Here, we aimed to determine the optimal incision placement for uniportal spinal endoscopic fusion across different lumbar levels, patient anatomies, and body thickness conditions. The objective was to optimize incision positioning to maximize model-derived disc and endplate preparation and to improve the feasibility of inserting larger cages, double cages, and greater bone graft volume during uniportal endoscopic fusion. We hypothesized that computationally optimized incision placement would provide greater model-derived disc access and preparation capacity than conventional empiric planning.
Methods
Study design
This was a retrospective imaging-based cohort study that used parametric modeling and genetic algorithms to determine the optimal surgical incision site. To improve clinical applicability, machine learning models were developed to predict the GA-derived optimal incision site from patient-specific anatomical parameters measured on MRI. These anatomical measurements can be readily obtained in routine practice and entered into a web-based system built on the best-performing predictive model to provide real-time estimation of the optimal incision site.
Data collection
This retrospective imaging study used a revised institutional development cohort consisting of 605 axial lumbar MRI images derived from 121 patients with degenerative lumbar conditions. All institutional images were preoperative MRI scans, and axial slices at each lumbar level were obtained at the mid-disc level.
The institutional imaging cohort was derived from patients undergoing evaluation for uniportal endoscopic lumbar interbody fusion because of low back pain with radicular symptoms or neurological deficits refractory to conservative treatment. Eligible diagnoses included lumbar spondylolisthesis or instability with spinal stenosis, degenerative disc disease with central or bilateral foraminal stenosis, and recurrent lumbar disc herniation. All lumbar levels with adequate axial MRI quality were included in the analysis. Images were excluded if key anatomical landmarks required for parametric measurement were not clearly visible or if image quality was substantially degraded by artifact or poor resolution.
In addition, an independent external validation cohort consisting of 120 MRI images from 40 patients was obtained from the publicly available Lumbar Spine MRI Dataset on Mendeley Data. 17 The original dataset consists of anonymized lumbar spine MRI scans from patients with symptomatic low back pain and includes axial and sagittal images primarily focused on the lower lumbar spine and lumbosacral junction. In the present study, axial mid-disc images were selected from this dataset for external validation. This dataset was used to evaluate model performance on a non-institutional data source. However, detailed patient-level clinical diagnoses and complete acquisition protocol information were not fully available in the public dataset description.
Parametric modeling
A parametric program was developed using Grasshopper® to identify and outline spinal structures and define the geometric relationships required for optimization (Figure 3). The primary advantage of this parametric program is that it allows rapid delineation of measurement regions by adjusting predefined parameter sliders, thereby avoiding time-consuming manual redrawing for each image.
18
Each axial MRI image was first imported into the parametric environment, and the image scale was calibrated so that all subsequent geometric parameters corresponded to real anatomical dimensions (Figures 4 and 5). We used a parametric program to delineate various spinal structures, including their respective dimensional ranges and lengths. By utilizing a parametric program and programming techniques, we delineated anatomical structures and accurately calculated the actual areas and lengths of these structures through precise mathematical conversion. Grasshopper®-based parametric modeling interface for incision optimization. An axial MRI image is imported into the parametric environment, and the disc contour is defined using slider-controlled reference lines and arc curves. The anterior–posterior diameter, transverse width, anterior and posterior curvature, posterior indentation, Kambin’s triangle borders, and PLL-to-skin distance are adjusted to match the MRI anatomy. The actual PLL-to-skin distance measured on MRI is entered as a numeric calibration value so that all geometric outputs correspond to real anatomical dimensions. The incision position is treated as a variable parameter, and the removable disc area (blue region) is recalculated automatically for each incision location. A genetic algorithm is then used to identify the incision position that maximizes the removable disc area.


The workflow was semi-manual and operator-assisted. The intervertebral disc contour was first defined by matching the anterior–posterior diameter and transverse width of the disc to the MRI image using slider-controlled reference lines. The anterior and posterior disc boundaries were then modeled using symmetric arc curves. Because the left and right sides were mirrored, only one side required direct adjustment. The curvature of the anterior and posterior disc margins was controlled by adjustable X- and Y-axis coordinates of predefined control points, allowing the disc contour to closely fit the MRI appearance. In cases where the posterior disc margin showed indentation near the dural sac, an additional adjustable curvature parameter was used to reproduce this concavity and improve contour fitting.
After the disc contour had been defined, the medial and lateral borders of Kambin’s triangle were determined by identifying the lateral edge of the dural sac and the exiting nerve root, respectively. The distance from the posterior longitudinal ligament (PLL) to the skin surface was then defined by adjusting the relative position of the skin line and PLL line. The actual measured PLL-to-skin distance was entered as a numeric parameter to calibrate the entire model to real anatomical dimensions.
Wound incisions were standardized at 1 cm in width to simulate the entry point of a wide working-channel endoscope. The inner and outer margins of the incision were connected to the medial and lateral borders of Kambin’s triangle using straight lines representing the achievable working corridor after soft-tissue compression. Crucially, the dural sac and exiting nerve root served as explicit clinical bounds; the model constrained the surgical trajectory within these risk structures to ensure the endoscopic path remained within a safe zone, treating neural proximity as a geometric constraint rather than merely a measured feature. The intersection between these lines and the disc contour defined the removable disc region.
The incision position was treated as a variable parameter. By systematically changing the incision location along the skin surface, the removable disc area was recalculated for each position. A genetic algorithm was then used to identify the incision position that maximized the removable disc area relative to the total disc area. The same parametric template, landmark definitions, and adjustment procedure were used for all images to ensure consistency across cases.
Measurement reliability
To assess inter-rater reliability of the MRI-derived anatomical measurements used in the parametric workflow, 30 MRI images from different patients were independently measured by two spine surgeons. Intraclass correlation coefficients (ICC) were calculated using a two-way random-effects model with absolute agreement for each anatomical parameter, including PLL-to-skin depth, dural sac width, disc AP diameter, disc width, and Kambin’s triangle base width.
Optimization methods
Grasshopper’s Galapagos optimization tool, which implements a genetic algorithm (GA), was used to determine the optimal wound incision placement, defined as the position that maximizes the removable disc area in absolute terms (mm2) and as a percentage of the total disc area. The incision parameter was constrained to move horizontally along the skin surface, with the medial boundary set at the midline. The lateral boundary was not fixed in the computational model so that the geometric solution space could be fully explored (Figure 6), although in clinical practice the feasible incision range is additionally influenced by anatomical and ergonomic considerations. While the lateral search boundary was conceptually open, the GA-optimized incisions consistently converged within a clinically reasonable range, as the marginal increase in resectable area diminishes significantly at further lateral positions. This figure illustrates the program operations. The Galapagos optimization tool, which employs a genetic algorithm (GA), was used to calculate the optimal incision placement to maximize the removable disc area.
Because intervertebral discs show irregular and patient-specific morphology, GA was used as an iterative search method rather than a closed-form mathematical solution. The GA was configured using the Galapagos evolutionary solver with the following parameters: population size 50, maximum stagnation count 50, initial boost 3, maintain rate 5%, and inbreeding rate 50%. In addition, the annealing solver was enabled with a temperature of 100%, a cooling rate of 0.95, and a drift rate of 0.25%. These parameters were selected empirically to balance convergence stability and computational efficiency within the Grasshopper/Galapagos environment. In preliminary testing, parameter adjustments mainly affected convergence speed rather than the final optimized incision position. However, because a systematic sensitivity analysis of GA parameters, including population size, stagnation count, and annealing settings, was not performed, the possibility that parameter settings may influence convergence behavior or optimality confirmation in anatomically complex cases cannot be completely excluded.
The optimization workflow used the parametric model to define disc geometry, PLL-to-skin distance, Kambin’s triangle borders, and dural sac width. The incision position was treated as a variable, and for each candidate position the removable disc area was calculated automatically. Galapagos evaluated each candidate using the removable disc area as the fitness function and iteratively refined the population until the maximum value was reached. The optimization adhered to strict anatomical constraints, where the dural sac and exiting nerve root acted as the medial and lateral limits of the instrument path to ensure the predicted incision consistently favored clinical safety.
Feature selection
The features selected in this study encompass fundamental clinical variables, derived variables designed to capture key anatomical characteristics, and categorical variables representing spinal levels. The fundamental variables include the anterior-posterior diameter and width of the intervertebral disc, describing the disc’s morphology; the distance from the skin surface to the posterior longitudinal ligament, reflecting variations in body shape; the width of the base of Kambin’s triangle, representing the available disc entrance space; and the width of the dural sac, indicating the position of the inner margin of Kambin’s triangle.
To further enhance the model’s predictive capability, three ratio-based derived variables were incorporated: the ratio of the disc’s anterior-posterior diameter to its width, capturing overall disc shape; the ratio of soft tissue thickness (from the skin surface to the posterior longitudinal ligament) relative to the disc’s anterior-posterior diameter, providing insight into body shape relative to disc size; and the ratio of disc width to dural sac width. These ratios standardize measurements across different patient anatomies and characterize the spatial relationship between Kambin’s triangle and the disc.
Additionally, spinal levels from L1–L2 to L5–S1 were included as categorical variables using one-hot encoding to account for level-specific anatomical differences and improve the model’s generalizability across patients.
A univariate analysis was initially conducted to evaluate the linear correlation of each feature with the target variable, forming the basis for feature selection. Both continuous and categorical variables were assessed to ensure a comprehensive representation of anatomical characteristics. Various feature combinations, including reduced and full feature sets, were tested to prevent the exclusion of any potentially informative variables. Because model-dependent feature importance may be influenced by multicollinearity and algorithm-specific bias, feature importance was interpreted only as exploratory and not used as the sole criterion for feature retention, consistent with recent discussions in machine learning-based clinical prediction research. 19
Machine learning approach
Pandas was used for data handling and feature engineering, and Scikit-learn was used for one-hot encoding, standardization, principal component analysis, and grouped dataset splitting.
The GA implemented in Grasshopper’s Galapagos tool was used to optimize incision placement by maximizing the removable disc area. However, because GA-based optimization requires specialized software and manual contour definition, it is not readily accessible for routine preoperative planning. To address this limitation, the GA-derived optimal incision sites were used as target values for machine learning models based on MRI-derived anatomical parameters that are readily measurable in clinical practice.
Machine learning models, including Linear Regression, Random Forest, Gradient Boosting, ElasticNet, and artificial neural networks (ANNs), were trained to predict optimal incision position using anatomically relevant MRI-derived parameters.
In the final pipeline, raw numeric MRI features were first standardized using a StandardScaler fitted on the internal training subset only. Principal component analysis (PCA) was then applied to the scaled numeric variables, retaining 90% of cumulative variance. The PCA-derived features were combined with one-hot encoded lumbar level variables and subsequently standardized again before final ANN training.
Model development followed the patient-level split described in the Statistical analysis section. The ANN training procedure was repeated 10 times using different random seeds to reduce sensitivity to random initialization, and the final model was selected according to the highest internal validation R2. External validation was subsequently performed using the independent non-institutional dataset.
The final ANN architecture consisted of an input layer, two hidden dense layers with 32 and 16 neurons, ReLU activation, dropout layers (rate 0.1), L2 regularization, and a linear output layer. The model was optimized using Adam with a learning rate of 0.0005, a batch size of 8, and early stopping based on validation loss. Full reporting of model architecture, preprocessing, and training parameters was provided to ensure reproducibility, in accordance with current recommendations for clinical machine learning studies. 20
The best-performing model was selected for deployment according to internal validation performance. Matplotlib was used to visualize training loss curves, residual distributions, calibration plots, and Bland–Altman plots.
For deployment, the final model was integrated into Hugging Face, with preprocessing steps directly embedded into the pipeline using StandardScaler. Real-time predictions were facilitated through a Gradio interface, allowing surgeons to input patient-specific parameters and receive optimized wound incision recommendations (Figure 7). Graphical abstract illustrating the complete computational workflow of the study, including: (1) parameter-based mapping of disc shape and nerve spacing from MRI cross-sections using a calibrated Grasshopper® bounding system; (2) genetic algorithm optimization in Galapagos to identify the incision that yields the largest discectomy area; (3) extraction of MRI-derived anatomical parameters as model inputs; (4) selection and training of the best-performing machine-learning model using GA-optimized incision positions as ground-truth targets; and (5) deployment of the final ANN model as an online calculator for real-time prediction of the optimal incision location.
Model training and deployment were performed using Google Colab and Hugging Face without paid cloud services.
Statistical analysis
To prevent data leakage arising from multiple lumbar levels within the same patient, all data splitting procedures were performed at the patient level using medical record number (MRN) as the grouping variable. The internal split comprised 480 training images from 96 patients and 125 validation images from 25 patients, with no overlapping MRNs between subsets. The external validation cohort included 120 images from 40 patients and had no overlap with the institutional development cohort.
Within-patient clustering was further assessed using mixed-effects analysis as a diagnostic sensitivity assessment, rather than as a component of the final ANN modeling pipeline. The intraclass correlation coefficient was 0.035, indicating low but nonzero within-patient correlation. This corresponded to a design effect of 1.14 and an effective sample size of approximately 530 from 605 observations.
Inter-rater reliability was assessed using intraclass correlation coefficients calculated with a two-way random-effects model with absolute agreement. Model performance was evaluated using R2, mean squared error, and mean absolute error. External validation was performed using the independent non-institutional MRI dataset. Bootstrap-derived confidence intervals were calculated for validation metrics, and agreement between predicted and actual incision positions was further assessed using calibration analysis, residual analysis, and Bland–Altman analysis.
Ethical approval
Ethical approval for this retrospective study was obtained from the Institutional Review Board of our hospital (approval number: 24MMHIS571e). All MRI data were collected under IRB approval and were fully anonymized prior to analysis. No identifiable patient information was used, and all procedures complied with institutional ethical standards and relevant regulations.
Results
Patient demographics and anatomical measurements
The patients’ ages ranged from 58 to 83 years, with a mean age of 71.5 ± 7.2 years. The sex distribution was 45% male and 55% female. Using the parametric 2D modeling capabilities of Grasshopper, we delineated the lumbar intervertebral discs, dural sac width, Kambin’s triangle base width, and the depth from the PLL to the body surface for each spinal segment. Picture Archiving and Communication System measurements of the PLL-to-surface depth from MRI axial slice images at the disc levels were used to derive actual dimensions and areas for all other parameters. This approach enabled precise calculation of averages and standard deviations for each parameter across different spinal levels.
Measurement reliability
Inter-rater agreement for the MRI-derived anatomical measurements was excellent. The ICC values were 0.994 for PLL-to-skin depth, 0.976 for dural sac width, 0.981 for disc AP diameter, 0.987 for disc width, and 0.968 for Kambin’s triangle base width, indicating minimal measurement variability.
Lumbar morphometric analysis
The mean and standard deviation of the disc area from L1-2 to L5-S1 were as follows: 1438.58 ± 252.16, 1702.11 ± 328.99, 1847.52 ± 303.86, 1950.8 ± 350.4, and 1795.82 ± 593.46 mm2, respectively (Figure 8). Similarly, the mean and standard deviation of the Kambin’s triangle base width were 10.12 ± 1.74, 12.74 ± 2.27, 13.05 ± 1.59, 16.88 ± 1.87, and 16.88 ± 3.23 mm, respectively (Figure 9). Box plot illustrating the mean and standard deviation of the disc areas across the spinal levels from L1-2 to L5-S1. Box plot showing the mean and standard deviation of the Kambin triangular base width across the spinal levels from L1-2 to L5-S1.

Additionally, the disc AP-to-width ratio, which represents the general shape of the disc, progressively decreased from L1-2 to L5-S1, with mean values and standard deviations of 0.78 ± 0.04, 0.77 ± 0.04, 0.74 ± 0.04, 0.72 ± 0.04, and 0.67 ± 0.05, respectively. The ratio of disc width to dural sac width, which indicates whether Kambin’s triangle primarily overlaps the inner or outer portion of the disc, also varied across spinal levels. The mean values and standard deviations were 4.51 ± 0.76, 5.16 ± 1.31, 4.98 ± 0.55, 5.44 ± 0.73, and 5.85 ± 1.92, respectively. Furthermore, the ratio of disc anterior-posterior diameter to depth, which reflects the relationship between disc size and soft tissue thickness, exhibited slight variations across spinal levels. The mean values were 0.58 ± 0.11, 0.61 ± 0.11, 0.64 ± 0.13, 0.64 ± 0.13, and 0.59 ± 0.12 for L1–2, L2–3, L3–4, L4–5, and L5–S1, respectively.
Genetic algorithm-based incision optimization
We designed a parametric Grasshopper program to set the incision position as a variable. The incision’s inner edge was connected to the outer edge of Kambin’s triangle base, while the outer edge of the incision was connected to the inner edge of Kambin’s triangle base, forming straight-line connections. The intersections of these lines with the disc contour were calculated to determine the maximum achievable disc area. Galapagos was employed to compute the optimal incision positions using a GA, defined as the positions that maximize the removable intervertebral disc area. These computed positions represent the incision sites that allow for the largest possible disc resection surface, ensuring the most effective access for uniportal endoscopic lumbar interbody fusion. The computed incision positions, expressed as mean ± standard deviation, were 58.93 ± 10.19, 63.31 ± 9.84, 67.79 ± 12.82, 83.89 ± 13.69, and 95.28 ± 19.38 mm for spinal levels L1-2 to L5-S1, respectively (Figure 10). The boxplot displaying the computed optimal incision positions, represented as mean ± standard deviation, across spinal levels from L1-2 to L5-S1.
The final proportions and area of the disc prepared for each spinal segment were as follows: L1-2 (41% ± 5%, 600.27 ± 146.25 mm2), L2-3 (47% ± 5%, 798.77 ± 213.18 mm2), L3-4 (45% ± 5%, 838.74 ± 162.58 mm2), L4-5 (53% ± 4%, 1039.82 ± 199.18 mm2), and L5-S1 (53% ± 5%, 964.82 ± 355.14 mm2).
Anatomical and surgical parameters across lumbar levels (L1-2 to L5-S1).
This table summarizes key anatomical and surgical measurements for lumbar levels (L1-2 to L5-S1), with values expressed as mean ± standard deviation.
Variable descriptions:
Disc_AP (mm): Anteroposterior diameter of the disc indicating its depth.
Disc_Width (mm): Lateral width of the disc reflecting its transverse size.
Cord width (mm): transverse width of the spinal cord defining the medial border of Kambin’s triangle.
Kambin_Triangle_Base (mm): Width of Kambin’s triangle base, representing the entry width of the disc for discectomy, surgical handling, and endplate preparation.
PLL_To_Skin_Depth (mm): Depth from the posterior longitudinal ligament to the skin, representing tissue thickness and body shape.
AnatomicDisc_Area (mm2): Total surface area of the disc.
Resectable_Disc_Percentage (%): Proportion of the disc accessible for discectomy and surgical handling.
Disc_AP_to_Width_Ratio: Ratio of disc depth to width describing the shape.
Disc_Width_to_Cord_Width_Ratio: Ratio of disc width to spinal cord width, defining the medial border of the Kambin’s triangle relative to the disc.
Disc_AP_to_Depth_Ratio: Ratio of disc depth to PLL-to-skin depth, reflecting the disc size relative to tissue thickness.
Incision (mm): optimal incision distance from the spinal process, calculated for maximum discectomy, surgical handling, and endplate preparation area.
Machine learning model development
Univariate analysis was initially conducted to evaluate the linear correlation of each feature with the target variable, and features with low correlation were considered for removal. However, subsequent experiments demonstrated that removing these features led to a substantial decline in the model’s predictive performance, suggesting that certain features with low univariate correlation still provided crucial information in a nonlinear multivariate model.
As a result, all features—including continuous and categorical variables—were retained to comprehensively represent anatomical characteristics and improve the model’s predictive accuracy.
Model evaluation and performance
Comparison of predictive performance among machine learning models using the independent external validation dataset. The artificial neural network (ANN) achieved the best performance, with the lowest mean squared error (MSE) and highest R², compared with linear regression, ElasticNet, random forest, and gradient boosting.
After model selection, the ANN training procedure was repeated 10 times using different random seeds, and the final model was selected based on the highest internal validation performance. Across the 10 repeated runs, internal validation performance remained stable, with R2 values ranging from 0.9285 to 0.9350 and MAE values ranging from 3.64 to 3.87 mm.
For the final ANN model, external validation yielded an MSE of 64.41, an MAE of 6.08 mm, and an R2 of 0.918. The bootstrap-derived 95% confidence intervals were 45.26–91.53 for MSE, 5.17–7.10 mm for MAE, and 0.869–0.947 for R2.
To assess robustness against measurement variability, a noise-based sensitivity analysis was performed by introducing small perturbations to the MRI-derived input features in the external validation dataset. Model performance remained stable, supporting the robustness of the ANN under realistic measurement variation. Additionally, we closely monitored the final ANN model by analyzing the training and validation loss curves to detect potential overfitting. The loss curves showed rapid early convergence followed by stable plateauing without marked divergence between the training and validation sets, suggesting good convergence and no obvious overfitting.
Additional regression-model evaluation on the external validation dataset demonstrated strong agreement between predicted and actual incision positions. The predicted-versus-actual plot showed close agreement across the measurement range, the calibration plot demonstrated good alignment between predicted and observed means, and Bland–Altman analysis showed minimal mean bias with acceptable limits of agreement (Figures 11–13). However, a small number of cases exceeded the 95% limits of agreement. Post hoc review of the largest outlier suggested an atypical soft-tissue configuration, including an unusually thick adipose layer along the presumed access corridor, which may have affected anatomical landmark interpretation and model prediction. Predicted-versus-actual plot for external validation. The scatter plot shows the relationship between predicted and measured incision distances in the external validation dataset. The dashed red line represents the line of identity. Most data points are closely aligned with the identity line, indicating good predictive accuracy of the model. Calibration plot for external validation. Mean predicted values are plotted against mean observed values within prediction bins. The dashed red line represents perfect agreement. The close alignment of the calibration curve with the identity line indicates good calibration of the regression model. Bland–Altman plot for external validation. The Bland–Altman plot shows the difference between predicted and observed incision distances against their mean. The central dashed line represents the mean difference, and the upper and lower dashed lines indicate the 95% limits of agreement. Most data points fall within the limits of agreement, demonstrating acceptable agreement between predicted and actual measurements.


Cloud deployment for real-time use
Finally, the trained ANN model was deployed on a cloud-based platform to facilitate real-time machine learning inference for surgeons performing endoscopic lumbar interbody fusion. The model calculates the optimal incision position to maximize disc and endplate preparation, integrating patient-specific parameters for personalized surgical planning. The optimized model was successfully deployed on a cloud server, allowing surgeons to input patient anatomical measurements and receive real-time predictions of the optimal incision site (Figure 14). The service is accessible at the following URL: https://huggingface.co/spaces/KTChienSpine/Trans-Kambin_Endo_Fusion_Incision_Calculator. User interface of the ANN-based endo fusion optimal incision calculator. The calculator accepts MRI-derived anatomical parameters as inputs and returns the predicted optimal incision location and estimated discectomy area.
Discussion
This study integrates four distinct technological components, leveraging software traditionally employed in architectural parametric and optimization design to introduce a novel approach to surgical structural optimization. 21 Specifically, we employed parametric modeling with Grasshopper, optimization using Galapagos GA, machine learning-based predictive modeling, and the deployment of an interactive web-based API. The Grasshopper parametric modeling framework facilitated the rapid and precise extraction of spinal anatomical features from axial MRI slices, eliminating the need for manual contour tracing and distance measurements. Subsequently, the Galapagos GA was employed to determine the optimal incision placement to maximize discectomy volume. Given the irregular and patient-specific morphology of intervertebral discs, GA was used to iteratively search for the incision position that maximized removable disc area. However, GA-based optimization requires specialized software and training, limiting its practical application for routine preoperative planning. To address this challenge, we collected optimal incision placement data and analyzed its correlation with basic MRI-derived parameters using machine learning. This approach enabled us to develop a predictive model that allows for preoperative planning without necessitating GA computation. Finally, the ANN model was deployed on Hugging Face using a user-friendly Gradio interface for real-time incision-planning support. Clinically, this workflow is intended as a preoperative decision-support tool rather than a replacement for surgeon judgment. The model provides a patient-specific computational reference for incision planning and trajectory optimization in uniportal endoscopic lumbar fusion. It was evaluated using internal patient-level validation and an independent external MRI dataset, with performance assessed by R2, MSE, MAE, bootstrap confidence intervals, calibration analysis, and Bland–Altman analysis. However, prospective clinical validation using intraoperative disc preparation quality, fusion outcomes, and patient-reported outcomes remains necessary before routine clinical adoption.
Spinal morphometry and incision optimization
Our anatomical measurements confirmed that disc dimensions progressively increase at lower lumbar levels. The transverse disc length increased from 47.69 ± 4.8 mm at L1-2 to 57.76 ± 8.95 mm at L5-S1, while the anterior-posterior disc length increased from 36.98 ± 3.05 mm at L1-2 to 41.24 ± 3.85 mm at L4-5, followed by a slight decrease to 38.43 ± 5.44 mm at L5-S1. These trends and measurement ranges were consistent with previous studies.22–24 The progressive widening of lower lumbar discs, reflected by the decreasing AP-to-width ratio, indicates a more elliptical morphology at caudal levels. This necessitates a more lateral incision placement to optimize discectomy volume.
The Kambin triangle base dimensions also expanded caudally, ranging from 10.12 ± 1.74 mm at L1-2 to 16.88 ± 3.23 mm at L5-S1. This morphometric adaptation explains why larger or double cages are preferentially recommended for L4-5 and L5-S1, as certain cage designs require a minimum entry width of 18 mm.25–28 Our measured Kambin’s triangle base widths were largely consistent with previously reported data.29–31
Exploratory feature-response analysis in our machine learning model demonstrated that a wider Kambin triangle base was associated with a more laterally optimized incision location. Additionally, a lower disc width-to-dural sac width ratio, indicative of a laterally positioned medial border of the Kambin triangle, also correlated with more lateral incision placement. Furthermore, a greater PLL-to-skin distance, which suggests increased patient body mass, was similarly associated with a laterally shifted optimal incision location. These findings emphasize the significant influence of anatomical variability on incision planning in uniportal endoscopic fusion. This explains why a fixed empiric incision distance cannot provide optimal access in all patients, and supports the need for a patient-specific computational planning approach.
The trend of resectable disc area and bone graft space
Disc area followed a similar pattern, increasing from 1438.58 ± 252.16 mm2 at L1-2 to 1950.8 ± 350.4 mm2 at L4-5 before slightly decreasing to 1795.82 ± 593.46 mm2 at L5-S1 due to characteristic bilateral posterior-corner flattening. The resectable disc area, representing the available space for bone graft insertion, increased from 600.27 ± 146.25 mm2 at L1-2 to 1039.82 ± 199.18 mm2 at L4-5, followed by a minor reduction to 964.82 ± 355.14 mm2 at L5-S1. The resectable area, when multiplied by intraoperatively measured disc height, provides an estimate of the bone graft volume that can be inserted during uniportal endoscopic lumbar fusion surgery. However, because patient-specific disc height was not incorporated into the current parametric optimization or machine learning pipeline, these volumetric values should be interpreted as approximate planning estimates rather than precise patient-specific predictions.
Based on previously published intervertebral height data, 24 the estimated insertable bone graft volumes for each level were 6.00 (L1-2), 9.25 (L2-3), 10.44 (L3-4), 14.37 (L4-5), and 12.53 mL (L5-S1). Understanding these average insertable volumes is useful for preoperative planning, as insufficient or excessive graft filling may influence mechanical stability within the intervertebral space. In this study, optimized incision placement consistently achieved more than 30% disc preparation, which is comparable to previously reported biomechanical thresholds associated with adequate interbody support.8,9 However, the recommended graft volume of approximately 12 cm3 was achievable mainly at L4–5 and L5–S1, 10 suggesting that anatomical constraints at upper lumbar levels may limit the available graft space even with optimized incision positioning.
Average optimal incision placement
The average optimal incision distances from the spinous process were approximately 59 mm at L1-2, 63 mm at L2-3, 68 mm at L3-4, 84 mm at L4-5, and 95 mm at L5-S1. These values serve as a practical reference for preoperative planning, particularly in settings where real-time computational tools are unavailable. However, individual variability in spinal anatomy and body habitus can significantly influence these distances, underscoring the need for a patient-specific approach. This reinforces the importance of our Trans-Kambin Endo-Fusion Incision Calculator, which leverages advanced computational techniques to provide precise, patient-specific incision guidance for uniportal lumbar fusion procedures.
Study limitations
A key limitation is that the institutional development cohort was derived from a single center and may therefore reflect institution-specific patient characteristics, MRI acquisition protocols, and measurement practices. Although external validation was performed using an independent public dataset, detailed diagnoses and complete imaging protocols were not fully available for that cohort, which may limit generalizability and contribute to anatomical variability. Further multicenter validation is required before routine clinical adoption. Although patient-level splitting was used to prevent data leakage, the final ANN did not explicitly model residual within-patient clustering; mixed-effects analysis and ICC calculation were therefore used only as diagnostic sensitivity assessments.
In addition, the machine learning models predict GA-derived optimal incision positions rather than directly validated clinical outcomes. The optimization target was defined as the incision location that maximizes model-derived removable disc area within a simplified 2D geometric framework. Therefore, the predicted target should be interpreted as a computational planning surrogate rather than an outcome-proven predictor of fusion success, complication rate, or intraoperative preparation quality. Although this model reflects the constrained working corridor of uniportal endoscopic lumbar fusion, it does not fully capture real operative factors such as three-dimensional instrument angulation, tissue elasticity, variable tissue resistance, patient positioning, fluoroscopic interpretation, or surgeon-dependent technique. Moreover, because the model was developed according to a specific surgical planning concept, the optimal incision location may vary across surgeons, techniques, and clinical settings. Although related studies support the clinical importance of adequate disc and endplate preparation, there is currently no definitive evidence demonstrating that maximizing the model-derived removable disc area directly translates into improved fusion rates or better patient outcomes. Prospective clinical validation comparing computationally planned incision placement with conventional empiric incision planning, using actual intraoperative disc preparation quality and postoperative clinical or radiographic outcomes as endpoints, is therefore required before routine clinical adoption.
Future directions
Future research should prospectively validate the optimized incision placement by assessing fusion rates, operative time, intraoperative disc preparation quality, and patient-reported outcomes. Additionally, integrating the system with surgical navigation platforms and AI-driven imaging segmentation could facilitate real-time, automated surgical guidance, reducing reliance on manual input and enhancing precision in minimally invasive spine surgery. Future validation studies across various demographic groups and clinical settings are recommended to enhance the external validity of our findings.
Conclusion
In this study, parametric modeling, genetic algorithm optimization, and machine learning were integrated to develop a computational planning framework for patient-specific incision placement in uniportal endoscopic lumbar fusion. The final model was developed using a patient-level analytical pipeline and further evaluated using an independent non-institutional external dataset. The ANN demonstrated the best predictive performance for incision location and was implemented in a web-based interface for real-time planning support using MRI-derived anatomical parameters. By optimizing incision placement and maximizing model-derived disc and endplate preparation, this approach may increase the feasibility of larger cage insertion, double-cage placement, and greater bone graft delivery during surgery. These findings support the feasibility of this approach as a preoperative planning aid; however, further prospective and multicenter validation is required before broader clinical implementation.
Footnotes
Ethical considerations
The study was performed according to the Helsinki Declaration and approved by the Institutional Review Board of the institution where the study was conducted (approval number: 24MMHIS571e).
Consent to participate
We confirm that informed consent was waived due to the retrospective nature of the study and the use of anonymized data.
Author contributions
Funding
The authors received no financial support for the research, authorship, and/or publication of this article.
Declaration of conflicting interests
The authors declared no potential conflicts of interest with respect to the research, authorship, and/or publication of this article.
Data Availability Statement
The raw institutional MRI images used in this study cannot be publicly shared due to ethical, institutional, and patient confidentiality considerations. However, all fully de-identified derived parametric datasets and reproducibility materials have been made publicly available in the GitHub repository:
. The repository includes the derived anatomical measurements, GA-derived optimal incision distances, full preprocessing and model-training code, validation and result-generation scripts, trained ANN model files, preprocessing bundles, deployment-related files, and generated analytical results. These materials allow independent replication of the machine learning analysis, verification of the reported results, and confirmation of the deployed model pipeline. The external validation dataset was obtained from the publicly available Lumbar Spine MRI Dataset on Mendeley Data.
17
Guarantor
Kai-Ting Chien, MD, serves as the guarantor of this work and accepts full responsibility for the integrity and accuracy of the data and analysis.
