A subscription to JoVE is required to view this content. Sign in or start your free trial.

Method Article

An Experimental Framework for Compatibility- and Capacity-Aware Doctor-Patient Matching in Online Consultation

80 views

⸱

DOI:

10.3791/71608

⸱

August 7th, 2026

 , 

In This Article

Summary

This protocol presents a scalable experimental framework for doctor-patient matching in online medical consultation platforms. By jointly integrating patient-centered clinical compatibility and physician-side service capacity into a hybrid scoring model, this method optimizes matching accuracy, minimizes patient wait times, and ensures a balanced distribution of physician workload.

Abstract

Large-scale online medical consultation platforms require effective algorithm-assisted doctor-patient matching to balance patient-centered fit and operational efficiency. Existing approaches often optimize either clinical compatibility or physician capacity independently, leading to prolonged waiting times and uneven workloads. This protocol presents a scalable experimental framework to jointly incorporate compatibility and capacity into a hybrid matching score. Using a simulated dataset comprising 240 physicians, 3,600 patient requests, and 9,785 candidate pairs, the method quantifies compatibility (e.g., specialty alignment, mode fit) and capacity (e.g., load ratio, estimated waiting time). The framework evaluates candidate pairs through a hybrid score and compares performance against rule-based, compatibility-only, and capacity-only benchmark strategies across 12 evaluation folds. Representative results demonstrate that the hybrid framework achieves superior matching quality, including a mean precision at rank 1 of 0.740 and an F1 score of 0.714. Furthermore, it yields high operational efficiency with a capacity fill rate of 0.825 and a short mean estimated waiting time of 5.52 h. By maximizing mean patient satisfaction (4.43/5.00) and minimizing load imbalance (0.195), this framework provides a practical protocol for intelligent consultation routing and platform management.

Introduction

Online medical consultation has become an increasingly important mode of healthcare delivery, extending access to medical services beyond conventional face-to-face encounters1. In China, the expansion of internet telemedicine has been reinforced by policy development, market growth, and deeper integration with the broader healthcare system, making digital consultation an increasingly important component of healthcare organization2. Large-scale evidence from internet hospitals further indicates that online consultation services are now operating at substantial scale, functioning as a meaningful part of routine service provision rather than a marginal supplement3. At the same time, asynchronous telemedicine has broadened the scope of remote care by allowing flexible interaction patterns, improving accessibility while concurrently increasing the operational complexity of digital consultation platforms4.

As these platforms expand, their performance cannot be judged solely by technical availability. Patient experience and service quality have become central outcomes of digital care delivery5. Recent research has shown that the use of online consultation systems is associated with measurable differences in patient experience, especially concerning access, convenience, and appointment processes6. However, digital consultation also generates additional physician workload, including message handling and work performed outside routine clinical hours, which makes capacity management a central operational concern7. This challenge is intensified by the uneven distribution of demand across physicians, because visible service cues such as reviews, ratings, and other profile information can channel patient traffic toward a limited subset of highly visible doctors8. Doctor-patient assignment on online consultation platforms is, therefore, not merely a patient-side search problem, as physicians may also show selective response preferences when facing heterogeneous consultation requests9.

From the patient's perspective, the choice of online consultation is inherently multidimensional. Users simultaneously weigh waiting time, physician qualifications, hospital level, service mode, and consultation cost when choosing care options10. Consistent with this complexity, a recent systematic review concluded that online medical consultation platforms require recommendation mechanisms capable of reducing information overload and better aligning patient needs with physician resources11. Methodological studies have accordingly begun to introduce structured matching approaches, including dynamic stable matching under incomplete information, to improve doctor-patient allocation in online consultation environments12. More recent recommendation research has further emphasized that doctor-patient matching should improve allocation efficiency while reducing excessive concentration of demand around highly visible physicians from top-tier hospitals13. Mixed-method evidence shows substantial heterogeneity in telemedicine preferences, indicating that a one-size-fits-all allocation logic is unlikely to be sufficient at platform scale14. Despite these advances, the existing literature tends to treat compatibility-related factors and physician capacity constraints as separate problems, even though online consultation platforms must manage both relational fit and service absorbability simultaneously11.

To address this gap, this method aims to establish a scalable experimental framework for compatibility- and capacity-aware doctor-patient matching on large-scale online medical consultation platforms. The rationale behind this technique is that optimizing either clinical preference or physician service capacity in isolation leads to prolonged waiting times, uneven physician workloads, and suboptimal consultation experiences. The primary advantage of this hybrid strategy over alternative rule-based or single-objective allocation techniques is its ability to jointly model patient needs, physician characteristics, and dynamic service constraints to maintain workload balance and high patient satisfaction12. By detailing the construction of the hybrid matching score and the fold-based evaluation process, this protocol provides a practical basis for intelligent consultation routing. Readers can leverage this methodological framework to determine whether a dual-aware matching logic is appropriate for optimizing triage, resource allocation, and workflow management in their specific digital health applications.

Access restricted. Please log in or start a trial to view this content.

Protocol

The evaluation dataset used in this protocol was computationally simulated from aggregated, de-identified operational distributions and contained no actual or identifiable human participant data. Consequently, the study was deemed exempt from full ethical review by the Institutional Review Board (IRB) of NingboTech University (Exemption No. NT9918276).

1. Data preparation and cohort definition

  1. Establish the physician pool containing 240 active online physicians across eight consultation specialties: Internal Medicine, Cardiology, Neurology, Dermatology, Pediatrics, Gynecology, Orthopedics, and Psychiatry.
  2. Extract and define the following variables for each physician record: specialty, sex, professional title (Resident, Attending, Associate Chief, or Chief), hospital tier (Primary, Secondary, or Tertiary), years of practice, years of online consultation experience, consultation fee, nominal daily consultation capacity, current daily load, historical rating, mean first reply time, historical acceptance rate, follow-up service rate, and supported consultation mode (Text, Text plus Voice, or Text plus Voice plus Video).
  3. Establish the patient request pool containing 3,600 consultation requests.
    NOTE: To contextualize the evaluation's temporal dimension, this pool is calibrated to represent a continuous 30-day operational period encompassing both standard weekdays and weekends. This timeframe is designed to capture routine cyclical variations in patient demand while explicitly excluding extreme atypical periods (e.g., major national holidays or peak epidemic outbreaks) to establish a stable, steady-state baseline for algorithmic performance evaluation.
  4. Extract and define the following variables for each patient request: age, sex, target specialty, severity level (Low, Moderate, or High), urgency level (Routine, Urgent, or Priority), budget ceiling, preferred physician gender (Male, Female, or No Preference), preferred consultation mode (Text, Voice, or Video), prior platform visits, digital engagement level, comorbidity count, city tier, and preferred contact period.
  5. Clean the dataset by excluding any records with missing values in specialty, consultation fee, daily capacity, current load, mean first reply time, severity, urgency, budget ceiling, preferred consultation mode, or preferred physician gender. Ensure all retained records are complete before proceeding to pair generation.

2. Candidate pair generation

  1. Generate candidate doctor-patient pairs using a specialty-first retrieval rule. For each patient request, retrieve the first physicians who match the patient’s target specialty.
  2. Expand the retrieval window to adjacent high-frequency specialties that remain active on the platform on the same day only if fewer than two active physicians with remaining consultation capacity are available in the initial target specialty.
    NOTE: In this protocol, "adjacency" is structurally defined by established clinical cross-referral patterns and anatomical or symptomatic overlap (e.g., routing a patient from Cardiology to General Internal Medicine), while "high-frequency" specifically refers to specialties ranking in the top quartile (top 25%) of historical daily consultation request volume on the platform.
  3. Link each patient to two to four candidate physicians, aiming for an empirically derived mean number of approximately 2.72 candidates per request. Establish the final candidate-pair layer containing 9,785 pairs. See Figure 1 for the overall study workflow.

3. Pairwise variable operationalization

  1. Define all pairwise variables used in score construction prior to benchmarking. Refer to Table 1 for the prespecified definitions, thresholds, and score mappings.
  2. Code specialty match (S) as 1 when the physician specialty is identical to the patient target specialty, and 0 otherwise.
  3. Code mode fit (M) as 1 when the physician’s supported mode fully covers the patient’s preferred mode, and 0 otherwise.
  4. Code gender-preference fit (G) as 1 when the patient selects No Preference or when the physician's sex matches the stated preference, and 0 otherwise.
  5. Code affordability fit (A) as 1 when the physician fee is less than or equal to the patient’s budget ceiling, 0.5 when the fee exceeds the budget by no more than 20%, and 0 when the fee exceeds the budget by more than 20%.
  6. Normalize the physician historical rating using the observed physician-level range (minimum 4.10, maximum 4.98). Calculate the normalized quality score (Q) using the following formula:
    Q calculation formula diagram: Q=(Rating-4.10)/(4.98-4.10), educational research use.   (1)
    Set values below 4.10 after truncation to 0, and values above 4.98 to 1.
  7. Define urgency-response fit (U) based on the patient urgency and the physician's mean first reply time as specified in Table 1.
  8. Calculate the physician load ratio by dividing the current daily load by the nominal daily capacity. Calculate remaining same-day slots by subtracting the current daily load from the nominal daily capacity.
  9. Calculate the estimated waiting time (in hours) using the following formula:
    Predicted waiting time equation; workload management; formula for support response prediction.
    This construction serves as a heuristic estimate inspired by basic queuing theory principles, where a physician's baseline mean first-reply time is penalized by their real-time utilization rate (Current Daily Load / Daily Capacity).
    NOTE: The urgency adjustment factor is set to 0.80 for Priority requests, 0.90 for Urgent requests, and 1.00 for Routine requests. These adjustment factors are implemented as prespecified operational weights to enforce prioritized routing for severe cases, rather than empirically derived coefficients.

4. Matching score construction

  1. Construct the matching framework using a compatibility module and a capacity module, as detailed in Figure 2.
  2. Compute the compatibility score as a weighted linear combination of the patient-centered matching factors:
    Compatibility score equation, Σ coefficients; educational formula, educational analysis. (3)
  3. Compute the capacity score from the load-ratio score (L), remaining-slot score (R), and waiting-time score (W). Assign the categorical scores for , , and based on the thresholds defined in Table 1. Calculate the capacity score as:
    Static equilibrium; Capacity Score formula ΣFx=0; diagram for educational analysis. (4)
  4. Calculate the final hybrid score by integrating the compatibility and capacity components:
    Hybrid score formula; equation for compatibility and capacity analysis in data evaluation. (5)
  5. Fix the 0.60–0.40 weighting scheme before evaluation.
    NOTE: This predetermined ratio is guided by a fundamental principle of healthcare services. Clinical appropriateness and patient-centered fit must serve as the primary routing criteria to ensure medical safety, while still applying a substantial mathematical penalty to severe capacity constraints, which aligns with established triage literature that prioritizes clinical suitability over operational throughput.
  6. Do not tune these weights after outcome inspection to prevent overfitting and ensure reproducibility.
    NOTE: Researchers adopting this protocol are highly encouraged to conduct comprehensive sensitivity analyses or employ objective multi-criteria decision-making techniques (e.g., the Analytic Hierarchy Process [AHP] or entropy weighting) to tailor the framework to their platform's specific operational load.

5. Match selection and strategy benchmarking

  1. Perform benchmarking over 12 repeated evaluation folds. For each fold, sample 300 patient requests without replacement from the full patient pool.
    ​NOTE: This simple random sampling approach is intentionally used to simulate the stochastic, unpredictable nature of patient arrival streams characteristic of real-time online consultation platforms, rather than imposing an artificial structural balance on incoming demand.
  2. Retain all candidate pairs linked to those sampled requests within the respective fold.
  3. Benchmark four distinct allocation strategies independently on the same fold-specific candidate-pair layer:
    1. For the rule-based baseline, rank candidates by exact specialty match, then by lower consultation fee, and finally by higher historical rating.
    2. For a compatibility-only strategy, select the candidate with the highest compatibility score.
    3. For a capacity-only strategy, select the candidate with the highest capacity score.
    4. For the hybrid strategy, select the candidate with the highest hybrid score.
  4. Select the candidate physician with the highest final strategy-specific score as the final match for each patient request.
  5. Resolve any ties (identical scores to three decimal places) by selecting the candidate with the lower estimated waiting time, followed by the higher compatibility score, and finally the higher historical rating.

6. Outcome calculation

  1. Calculate the primary outcomes: precision at rank 1, recall, and F1 score.
  2. Assign ground-truth outcomes to all 9,785 candidate pairs before benchmarking using probability distributions derived from the empirical baseline dataset.
    NOTE: Use a fully labeled synthetic environment to enable calculation of precision and recall for all candidate pairs. A successful match is achieved if the consultation is completed, and patient satisfaction is 4.0 on a 5-point scale, and no 14-day revisit occurs due to dissatisfaction or mismatch.
  3. Calculate precision at rank 1 as the proportion of selected final matches that meet the successful-match criterion.
  4. Calculate recall as the proportion of all successful candidate pairs within a fold correctly selected by the strategy. Derive outcomes for non-selected candidate pairs from the fully labeled synthetic environment established in Step 6.2.
  5. Ensure that the recall metric accurately captures the algorithm's ability to identify all theoretically viable matches within the simulated candidate pool.
  6. Calculate the F1 score using the following formula:
    F1 score formula, equation; 2×Precision×Recall/(Precision+Recall); data analysis metric.   (6)
  7. Calculate secondary outcomes: capacity fill rate, mean estimated waiting time, mean patient satisfaction, consultation completion rate, 7-day follow-up rate, and reported improvement rate.
  8. Calculate the load imbalance index to evaluate the unevenness of the physician workload distribution within each fold:
    Load imbalance equation, symbol; static equilibrium analysis, educational math concept, formula diagram.   (7)
  9. Average the 12-fold-specific estimates to obtain the strategy-level summary values using the original score assignments.
  10. Conduct a multivariable logistic regression analysis within the subset of selected final matches to identify pair-level factors independently associated with successful matching.
  11. Include the following prespecified independent variables based on theoretical relevance: compatibility score, capacity score, estimated waiting time, affordability fit, specialty match, gender-preference fit, severity level, and urgency level.
  12. Employ a forced-entry variable selection strategy rather than a stepwise approach to preserve the model's theoretical structure.
  13. Assess multicollinearity using the Variance Inflation Factor (VIF). Confirm that all VIF values remain below 5.0 before final model estimation.
  14. Define statistical significance as a two-tailed p < 0.05, and report the results as adjusted odds ratios (aORs) with corresponding 95% confidence intervals (CIs).

Access restricted. Please log in or start a trial to view this content.

Results

Baseline characteristics of the physician pool and patient request pool

The simulated analytic dataset comprised 240 physicians and 3,600 patient consultation requests. The baseline characteristics of both sides of the matching system are summarized in Table 2, and the platform-side distribution patterns are illustrated in Figure 3.

Among the 240 physicians, 128 (53.3%) were female. The cohort demonstra...

Access restricted. Please log in or start a trial to view this content.

Discussion

The present protocol demonstrates a compatibility- and capacity-aware doctor-patient matching framework in a large-scale online medical consultation setting. The hybrid strategy achieved the most balanced overall performance across matching accuracy, waiting time, capacity utilization, patient satisfaction, and workload distribution. This result is crucial because digital consultation not only expands access but also shifts clinical work into after-hours activity, increasing the hidden workload when allocation logic over...

Access restricted. Please log in or start a trial to view this content.

Disclosures

The authors have nothing to disclose.

Acknowledgements

This research was funded by the Talent Introduction and Scientific Research Startup Project by NingboTech University: Research on Doctor Recommendation for Online Medical Consultation Platforms (1140157G20220699). This research was also supported by the Major Technological Innovation Project of Ningbo High-tech Zone (2023CX050007) and the Major Application Demonstration Project of “Science and Technology Innovation Yongjiang 2035”: Research on Standardization of Ningbo Dialect Based on Large-Scale Models and Demonstration of Intelligent Application Development (2024Z021).

Access restricted. Please log in or start a trial to view this content.

Materials

List of materials used in this article
NameCompanyCatalog NumberComments
Candidate doctor-patient pairsStudy-generatedN/APairwise variable derivation and match selection (9,785 candidate pairs)
IBM SPSS StatisticsIBM Corp.https://www.ibm.com/products/spss-statisticsStatistical analysis (Version 27)
Microsoft ExcelMicrosoft Corporationhttps://www.microsoft.com/microsoft-365/excelData management and descriptive summary (Version 2021)
Patient request recordsStudy-generatedN/ABaseline patient-side characteristics and preference parameters (3,600 consultation requests)
Physician recordsStudy-generatedN/ABaseline physician-side characteristics and capacity parameters (240 active physicians)
PythonPython Software Foundationhttps://www.python.orgSimulation, score construction, and benchmarking (Version 3.11)

References

  1. Shen T, Li Y, Chen X. A systematic review of online medical consultation research. Healthcare. 2024;12(17):1687.
  2. Cheng TC, Yip W. Policies, progress, and prospects for internet telemedicine in China. Health Syst Reform. 2024;10(2):2389570.
  3. Yang M, et al. The status and challenges of online consultation service in internet hospitals operated by physical hospitals in China: a large-scale pooled analysis of multicenter data. BMC Health Serv Res. 2025;25(1):611.
  4. Culmer N, et al. Asynchronous telemedicine: a systematic literature review. Telemed Rep. 2023;4(1):366–86.
  5. Fadaizadeh L, Velayati F, Arab-Zozani M. Satisfaction of patients and physicians with telehealth services during the COVID-19 pandemic: a systematic review and meta-analysis. Healthc Inform Res. 2024;30(3):206–23.
  6. Ge X, Chappell P, Ledger J, Bakhai M, Clarke GM. The use of online consultation systems and patient experience of primary care: cross-sectional analysis using the General Practice Patient Survey. J Med Internet Res. 2024;26:e51272.
  7. Mandal S, et al. Quantifying the impact of telemedicine and patient medical advice request messages on physicians’ work-outside-work. npj Digit Med. 2024;7(1):35.
  8. Wan Y, et al. Influencing factors and mechanism of doctor consultation volume on online medical consultation platforms based on physician review analysis. Internet Res. 2021;31(6):2055–75.
  9. Lu Y, Wang Q. Doctors’ preferences in the selection of patients in online medical consultations: an empirical study with doctor-patient consultation data. Healthcare. 2022;10(8):1435.
  10. Wang P, Huang Y, Li H, Xi X. Public preferences for online medical consultations in China: a discrete choice experiment. Front Public Health. 2023;11:1282387.
  11. Jiang H, Mi Z, Xu W. Online medical consultation service-oriented recommendations: systematic review. J Med Internet Res. 2024;26:e46073.
  12. Zhao M, Wang Y, Zhang X, Xu C. Online doctor-patient dynamic stable matching model based on regret theory under incomplete information. Socioecon Plann Sci. 2023;87:101615.
  13. Zhang Y, Wang T, Wang Y, Li X, Tang Y. A deep learning approach integrating multi-dimensional features for expert matching in healthcare question answering communities. Front Public Health. 2025;13:1633754.
  14. Jiang M, et al. Resident preferences for telemedicine services in China in the digital health era: mixed methods study. Patient Educ Couns. 2025;137:108909.
  15. Wang Y, Shi C, Wang X, Meng H, Chen J. The relationship between static characteristics of physicians and patient consultation volume in internet hospitals: quantitative analysis. JMIR Form Res. 2024;8:e56687.
  16. Dhunnoo P, et al. Evaluation of telemedicine consultations using health outcomes, user attitudes, and experiences: scoping review. J Med Internet Res. 2024;26:e53266.
  17. Yang F, Cheng Y, Yao R, Zhang X. What key factors affect patient satisfaction on online medical consultation platforms? A case study from China. Healthcare. 2025;13(5):540.
  18. Oudbier SJ, et al. Implementation barriers and facilitators of remote monitoring, remote consultation, and digital care platforms through the eyes of healthcare professionals: a review of reviews. BMJ Open. 2024;14(6):e075833.
  19. Khairat S, Lin J, Liu S. Patient and provider recommendations for improved telemedicine user experience in primary care: a multi-center qualitative study. Telemed Rep. 2023;4(1):34–43.
  20. Campbell K, et al. The impact of virtual consultations on the quality of primary care: systematic review. J Med Internet Res. 2023;25:e48920.
  21. Wu B, Liu QB, Guo X, Yang C. Investigating patients’ adoption of online medical advice. Decis Support Syst. 2024;176:114050.

Access restricted. Please log in or start a trial to view this content.

Reprints and Permissions

Explore More Articles

Compatibility ScoreCapacity ScoreHybrid Matching ScorePhysician WorkloadPatient SatisfactionOperational EfficiencySpecialty AlignmentIntelligent Consultation Routing