Traditional Chinese medicine nursing resource optimization and allocation method based on machine learning
By using the A2FSeg dual-path fusion perception model and multi-objective optimization based on machine learning, the problem of processing multi-source heterogeneous data in TCM nursing resource scheduling was solved, achieving accurate reflection of TCM nursing constitution and cyclical patterns, and improving the flexibility and responsiveness of resource scheduling.
Patent Information
- Application Number
- CN202511344283.6
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-09-19
- Publication Date
- 2025-12-30
- Estimated Expiration
- Not applicable · inactive patent
AI Technical Summary
Existing TCM nursing resource scheduling technologies are unable to effectively handle noise, missing data, and real-time emergencies in multi-source heterogeneous data, resulting in staggered scheduling, resource waste, and service delays. Furthermore, they lack in-depth modeling of TCM nursing constitution classification, treatment cycle, and equipment linkage, resulting in insufficient adaptive adjustment capabilities.
The A2FSeg dual-path fusion perception model based on machine learning is adopted to generate a stable baseline feature map of nursing needs through the average fusion path, and the feature channel weights are dynamically adjusted by the adaptive attention fusion path. Combined with the multi-objective optimization function system and rolling re-optimization strategy, the final resource scheduling scheme is generated.
It significantly improved the accuracy of spatiotemporal demand heatmap segmentation, reduced peak-shifting and resource waste, enhanced the ability to respond to emergencies, and ensured patient experience and resource utilization efficiency.
Smart Images

Figure CN121237343A_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of traditional Chinese medicine nursing technology, and in particular to a method for optimizing the allocation of traditional Chinese medicine nursing resources based on machine learning. Background Technology
[0002] With the increasing demand for TCM nursing services, medical institutions are facing increasingly complex challenges in the allocation and scheduling of patient care resources. TCM nursing services are subject to multiple constraints such as the continuity of treatment courses, individualized physical conditions, and collaboration between equipment and technicians. Furthermore, the business data sources are diverse, including heterogeneous data such as electronic medical record systems, appointment queuing systems, nursing workstation logs, and text medical orders. Existing nursing resource scheduling technologies are usually based on rule tables, single optimization models, or simple data weighting predictions, which make it difficult to robustly model and dynamically respond to strong noise, missing data, and real-time emergencies in multi-source heterogeneous data.
[0003] Traditional data fusion and nursing demand forecasting methods either employ simple fusion strategies such as weighted averaging, which cannot distinguish between information noise and sudden demand signals. This leads to peak misjudgment, resource waste, or service delays in actual scheduling plans. Conventional optimization scheduling frameworks lack in-depth modeling of business characteristics such as TCM nursing constitution classification, treatment cycle, and equipment linkage, making it difficult to ensure the feasibility and continuity of scheduling plans under strong constraints. In addition, existing scheduling systems have weak adaptive adjustment capabilities to sudden situations. When real-time disturbances occur, it is difficult to repair the allocation results in a timely and controllable manner, affecting patient experience and resource utilization efficiency. Summary of the Invention
[0004] One objective of this invention is to propose a machine learning-based method for optimizing the allocation of TCM nursing resources. This invention can significantly improve the accuracy of spatiotemporal demand heatmap segmentation, effectively reflect individual constitution and cyclical patterns in TCM nursing, and significantly reduce peak shifts, false peaks, and resource waste caused by data drift in scheduling schemes.
[0005] A method for optimizing the allocation of TCM nursing resources based on machine learning according to an embodiment of the present invention includes:
[0006] Acquire and preprocess multi-source datasets of TCM nursing services to generate standardized multi-source datasets of TCM nursing services.
[0007] The standardized TCM nursing business multi-source dataset is input into the A2FSeg dual-path fusion perception model, and a stable nursing demand baseline feature map is generated using the average fusion path.
[0008] In the A2FSeg dual-path fusion perception model, the adaptive attention fusion path is used to dynamically adjust the feature channel weights according to the real-time scenario to generate a sensitive nursing demand compensation feature map.
[0009] The stable nursing demand baseline feature map and the sensitive nursing demand compensation feature map are fused to output a nursing demand heat map and an urgency mask.
[0010] Based on the aforementioned nursing demand heat map and urgency mask, physical constitution classification matching constraints, treatment interval constraints, and equipment linkage constraints are generated to form a set of hard constraints and a set of soft constraints.
[0011] A multi-objective optimization function system is constructed, and the nursing demand heat map is used as the cost field, and the hard constraint set and soft constraint set are used as constraint inputs. The multi-objective optimization function system is solved by constraint programming to obtain an initial feasible resource scheduling scheme that satisfies all hard constraint sets.
[0012] Using the urgency mask as the rolling cost, the initial feasible resource scheduling scheme is improved by a rolling re-optimization strategy to generate the final resource scheduling scheme.
[0013] Optionally, the preprocessing includes:
[0014] The data from the electronic medical record system, the appointment queuing system, the nursing workstation logs, and the text medical orders were uniformly summarized, and a data record was constructed for each piece of original TCM nursing data.
[0015] The original data records of TCM nursing were normalized to form a set of normalized data records;
[0016] Each data record in the format-normalized data record set is de-identified to form a de-identified data record set.
[0017] Semantic mapping processing is performed on each data record in the de-identified data record set to form a semantically consistent data record set, which serves as a standardized multi-source dataset for TCM nursing services.
[0018] Optionally, the step of generating a stable care needs baseline feature map using the average fusion pathway includes:
[0019] The standardized TCM nursing business multi-source dataset is divided into multiple feature channel sets based on data source labels and TCM time phase labels.
[0020] The data tensor of each feature channel is input into the constitution-adaptive gating unit. The constitution-adaptive gating unit adjusts the constitution code of each patient and performs weighting and gating on different features of the data tensor through weights and constitution bias terms, and outputs constitution-sensitive features.
[0021] For each physical sensitivity feature, meridian-spatial embedding encoding is performed at the location of each time slot, nursing unit, and skill tag to output location-enhanced features;
[0022] The augmentation features at all locations are weighted according to the Yin-Yang balanced weights, and the multi-source stable sensing tensor is output.
[0023] The multi-source stable sensing tensor is input into the three-dimensional convolutional decoder and normalized to obtain a stable care demand baseline heatmap.
[0024] Optionally, the A2FSeg dual-path fusion sensing model includes:
[0025] In the A2FSeg adaptive attention fusion pathway, a stable nursing demand baseline heatmap is used as the query tensor, all location enhancement features are used as key tensors and value tensors, and real-time scene event embedding tensors are simultaneously accessed.
[0026] By using a linear mapping function, the baseline heatmap of stable nursing needs is converted into a query vector. The enhanced features of each location are converted into scene bias key vectors and into value vectors. The scene bias term is summed for each scene bias key vector. The inner product of the query vector and the scene bias key vector is calculated for each time slot, nursing unit, and skill tag position. The scene bias term is then added to the inner product to obtain the attention score.
[0027] All attention scores are exponentially normalized in two dimensions: data source channel and TCM time phase, to obtain real-time scene adaptive attention weights;
[0028] For each data source channel and each TCM time phase, the corresponding real-time scene adaptive attention weight is multiplied by its value vector minus the multi-source stable perception tensor to obtain the sensitive residual feature;
[0029] By weighted summing of all sensitive residual features across two dimensions—data source channel and TCM time phase—a sensitive nursing demand compensation feature map is obtained.
[0030] Optionally, the output nursing demand heatmap and urgency mask includes:
[0031] For the baseline feature map of stable nursing needs and the compensation feature map of sensitive nursing needs, learnable fusion gating weights are introduced at the positions of each time slot, nursing unit and skill tag to perform weighted summation, so as to obtain the fusion nursing needs feature map.
[0032] The fused nursing demand feature map is input into the dual-branch mask generation module. In the first branch, a nursing demand heat map is output through continuous three-dimensional convolution operation and sigmoid activation function.
[0033] In the second branch of the dual-branch mask generation module, an urgency mask is generated by extracting key perturbation information based on the fusion of nursing demand feature map and real-time scene event embedding tensor.
[0034] Optionally, forming the set of hard constraints and the set of soft constraints includes:
[0035] Based on the nursing needs heat map and urgency mask, combined with patient constitution coding and TCM nursing knowledge graph, at each time slot, nursing unit and skill tag position, according to the constitution-nursing behavior compatibility matrix, the feasibility of constitution adaptation for each patient at the time slot, nursing unit and skill tag position is judged for each patient according to the constitution-nursing behavior compatibility matrix.
[0036] Based on the patient's historical appointment information and treatment plan information, at each time slot, nursing unit, and skill tag position of the nursing needs heat map and urgency mask, for adjacent nursing arrangements of the same patient, it is determined whether the treatment interval constraint is met according to the requirements of the lower and upper bounds of the treatment interval.
[0037] Based on the nursing demand heatmap, urgency mask and equipment resource status matrix, according to the matching relationship between nursing tasks and equipment capabilities, under each time slot, nursing unit and skill tag, it is determined whether the equipment linkage constraints are met;
[0038] Feasibility of physical fitness matching, treatment interval constraints, and equipment linkage constraints are organized as a set of hard constraints. Based on the numerical thresholds of the nursing demand heat map and urgency mask, as well as the business rules of traditional Chinese medicine nursing, some scheduling goals and preferences are set as a set of soft constraints.
[0039] Optionally, the feasibility of physical fitness is used to determine whether the patient meets the physical fitness matching requirements under the current nursing resource configuration:
[0040] If the combination of patient constitution code and current skill tag in constitution-nursing behavior compatibility matrix is marked as feasible, then the constitution adaptation feasibility is 1; otherwise, the constitution adaptation feasibility is 0.
[0041] The feasibility of physical fitness is used to determine whether the patient meets the physical fitness matching requirements under the current nursing resource allocation:
[0042] If the combination of patient constitution code and current skill tag in constitution-nursing behavior compatibility matrix is marked as feasible, then the constitution adaptation feasibility is 1; otherwise, the constitution adaptation feasibility is 0.
[0043] The device linkage constraint is used to determine whether the current skill tag is compatible with the device capability and whether the device is in a usable state:
[0044] If the combination is marked as feasible in the skill tag and device capability compatibility matrix, and the device availability in the device resource status matrix under the current time slot and care unit is 1, then the device linkage constraint is 1; otherwise, the device linkage constraint is 0.
[0045] Optionally, obtaining the initial feasible resource scheduling scheme that satisfies the entire set of hard constraints includes:
[0046] Based on the nursing demand heatmap, the scheduling cost is calculated for each patient under each time slot, nursing unit, and skill tag.
[0047] Construct a multi-objective optimization function system that minimizes patient waiting time, maximizes treatment continuity, and maximizes treatment room utilization.
[0048] The hard constraint set and the soft constraint set are used as input constraints for scheduling feasibility and preference conditions;
[0049] Based on the multi-objective optimization function system, scheduling cost tensor, hard constraint set and soft constraint set, a constrained optimization model is constructed;
[0050] The constrained programming algorithm is used to solve the constrained optimization model. Under the premise that all hard constraints are satisfied, a set of initial feasible resource scheduling schemes that meet the scheduling feasibility conditions are output.
[0051] Optionally, the goal of minimizing patient waiting time is achieved by statistically analyzing each nursing service assigned to a patient under all time slots, nursing units, and skill tags, calculating the difference between the time slot and the patient's registered time slot, and summing the results for all patients, time slots, nursing units, and skill tags to obtain the total waiting time. The goal is to minimize the total waiting time.
[0052] The goal of maximizing treatment continuity is achieved by subtracting the time interval between consecutive care arrangements from the standard treatment interval for each patient, and summing the absolute values of the time interval differences between all consecutive care arrangements for all patients. The sum is taken as the treatment continuity loss, and the goal is to minimize this treatment continuity loss and maximize treatment continuity.
[0053] The goal of maximizing the utilization of treatment rooms is achieved by statistically analyzing all time slots and care units. Under each time slot and care unit, a time slot and care unit are considered to be effectively utilized as long as at least one skill tag is assigned to any patient. The total number of effectively utilized time slots and care units is summed to maximize the total number of effectively utilized time slots and care units.
[0054] Optionally, the initial feasible resource scheduling scheme is improved by performing a rolling re-optimization strategy, including:
[0055] Based on the initial feasible resource scheduling plan, the nursing service arrangements for all time slots covered by the rolling time window are re-evaluated within each rolling time window;
[0056] Within the scrolling time window, position each patient, time slot, nursing unit, and skill tag.
[0057] Within the rolling time window, the resource allocation results of the completed or executed parts of the initial feasible resource scheduling scheme are retained, and the resource allocation schemes that have not yet been executed are optimized in a rolling manner to construct a local rolling optimization model;
[0058] In the local rolling optimization model, the set of hard constraints and the set of soft constraints that are consistent with all initial feasible resource scheduling schemes are used as constraints for rolling optimization. Only when all constraints are satisfied can the allocation variable be assigned a value of one.
[0059] Within the rolling time window, the resource allocation results of the unexecuted portion are optimized based on the local rolling optimization model and the complete set of hard constraints and soft constraints. After optimization, the newly obtained resource allocation results within the rolling window are concatenated with the resource allocation results of the executed portion and the un-rolled optimized portion to form a complete resource scheduling scheme. The rolling re-optimization process is then repeated to form the final resource scheduling scheme.
[0060] The beneficial effects of this invention are:
[0061] (1) This invention introduces the A2FSeg dual-pathway structure in the field of nursing resource scheduling, organically combining average fusion with adaptive attention mechanism, and performs constitution-sensitive feature encoding, time phase modeling and meridian spatial embedding on multi-source heterogeneous data. In the average fusion path, the constitution-adaptive gating unit and meridian-space embedding are used to construct robust fusion features of multi-source data, and Yin-Yang balance weighting is introduced to achieve noise suppression, robustness to missing data and fine modeling of the distribution of sudden time periods. It can significantly improve the accuracy of spatiotemporal demand heat map segmentation, effectively reflect the individual constitution and periodic patterns in TCM nursing, and significantly reduce the peak shifts, false peaks and resource waste caused by data drift in the scheduling scheme.
[0062] (2) The adaptive attention fusion path of the present invention dynamically generates attention weights based on real-time scene embedding. Through the query-key-value mechanism, residual compensation is performed on the sudden occurrence of sensitive scenes that the stable path fails to capture. This effectively improves the automatic identification and allocation capabilities for sudden situations such as emergency order insertion, peak scheduling and equipment bottlenecks. Using the urgency mask as the input of rolling re-optimization cost, combined with local window rearrangement and constraint planning, minute-level and continuously feasible scheduling repair is achieved. This greatly improves the system's adaptability to dynamic disturbances, alleviates patient waiting, ensures the continuity of treatment and equipment utilization, and is superior to the flexibility and responsiveness of traditional global static scheduling and single MIP scheduling. Attached Figure Description
[0063] The accompanying drawings are provided to further illustrate the invention and form part of the specification. They are used in conjunction with embodiments of the invention to explain the invention and do not constitute a limitation thereof. In the drawings:
[0064] Figure 1 This is a flowchart of a machine learning-based method for optimizing the allocation of TCM nursing resources proposed in this invention. Detailed Implementation
[0065] Example 1: Reference Figure 1 A machine learning-based method for optimizing the allocation of TCM nursing resources includes:
[0066] Acquire and preprocess multi-source datasets of TCM nursing services to generate standardized multi-source datasets of TCM nursing services.
[0067] In this embodiment, the preprocessing includes:
[0068] The data from the electronic medical record system, the appointment queuing system, the nursing workstation logs, and the text medical orders were uniformly summarized, and a data record was constructed for each piece of original TCM nursing data.
[0069] Each original data record for TCM nursing includes a data timestamp, patient identification code, corresponding content value of the data record, and data source label.
[0070] The original data records of TCM nursing were normalized to form a set of normalized data records;
[0071] The format normalization process performs a unified encoding mapping for different data sources in terms of time granularity, structural format and naming rules, so that each data record includes a unified standard timestamp, patient identification code, numerical content converted according to a unified field structure and data source label.
[0072] Each data record in the format-normalized data record set is de-identified to form a de-identified data record set.
[0073] The desensitization process includes removing directly identifiable information fields and using a hash encryption function to convert the patient identification code. The conversion result is used as the desensitized patient identification code to replace the original patient identification code. Each updated data record includes a timestamp adjusted according to a unified time standard, the desensitized patient identification code, the numerical content converted according to a unified field structure, and the data source tag, forming a set of desensitized data records.
[0074] Semantic mapping processing is performed on each data record in the de-identified data record set to form a semantically consistent data record set, which serves as a standardized multi-source dataset for TCM nursing services.
[0075] Semantic mapping processing includes mapping semantic representations from different data sources based on a unified semantic dictionary, ensuring that the numerical content of each data record is standardized to a unified conceptual space. Each data record includes a timestamp adjusted according to a unified time standard, a desensitized patient identification code, a structured nursing data value after semantic mapping, and a data source label.
[0076] The standardized TCM nursing business multi-source dataset is input into the A2FSeg dual-path fusion perception model, and the average fusion path is used to generate a stable nursing demand baseline feature map.
[0077] In this embodiment, a stable care needs baseline feature map is generated using the average fusion pathway, including:
[0078] The standardized TCM nursing business multi-source dataset is divided into multiple feature channel sets based on data source labels and TCM time phase labels.
[0079] The number of feature channels is equal to the product of the number of data sources and the number of TCM time phases. Each feature channel corresponds to a data tensor of a data source under a certain TCM time phase. Each data tensor is expanded in three dimensions: time slot, nursing unit, and skill label.
[0080] The data tensor of each feature channel is input into the constitution-adaptive gating unit. The constitution-adaptive gating unit adjusts the constitution code of each patient and performs weighting and gating on different features of the data tensor through weights and constitution bias terms, and outputs constitution-sensitive features.
[0081]
[0082] Among them, CAGU is the body fitness adaptive gating unit, X (c,h) κ represents the data tensor of the c-th data source at the h-th TCM time phase. p To code the patient's constitution, W g Wf For convolution kernel groups, is the body bias term, σ(·) is the Sigmoid function, and ⊙ is the Hadamard product.
[0083] For each physical sensitivity feature, meridian-spatial embedding encoding is performed at the location of each time slot, nursing unit, and skill tag to output location-enhanced features;
[0084] Meridian-spatial embedding coding is generated by the angle information of the meridian partition corresponding to the nursing unit. Meridian-spatial embedding coding is added to the constitution-sensitive features element by element to output position-enhanced features.
[0085]
[0086] Among them, F (c,h) (t,l,s) represents the constitution-sensitive feature value corresponding to time slot t, nursing unit l, and skill tag s under the c-th data source channel and the h-th TCM time phase, reflecting the patient's constitution encoding κ under the dimensions of time, location, and skill. p The nursing needs characteristics of ) This represents the feature value enhanced by the meridian-spatial embedding encoding, that is, on the basis of the original constitution-sensitive features, information related to the nursing unit space and the meridian division of traditional Chinese medicine is superimposed. M l The meridian-spatial embedding code for the l-th nursing unit is a feature vector generated for each nursing unit, used to combine traditional Chinese medicine meridian knowledge with the nursing spatial structure. φ l This represents the meridian zone angle code corresponding to the l-th nursing unit, which combines prior knowledge of spatial and meridian distribution in Traditional Chinese Medicine theory, sin(φ) l )||cos(φ l ) indicates the angle encoding φ l The spatial embedding feature is formed by concatenating the sine and cosine operations, where || represents the vector concatenation operation.
[0087] The augmentation features at all locations are weighted according to the Yin-Yang balanced weights, and the multi-source stable sensing tensor is output.
[0088] The calculation of Yin-Yang balance weights combines the comprehensive score of abnormal missing time delays for each data source with the sinusoidal function distribution of TCM time phase. The sum of all Yin-Yang balance weights is one, and the weighted output is a multi-source stable perception tensor. The multi-source stable perception tensor is consistent with the input features in the three dimensions of time slot, nursing unit, and skill label.
[0089]
[0090] Among them, F avgThis represents the fused multi-source stable perception tensor, used to reflect the robust characteristics of nursing needs under different data sources and TCM time phases. Its dimensions are T×L×S, corresponding to time slots, nursing units, and skill tags, respectively. src This indicates the number of data source channels. In this invention, data includes data from the electronic medical record system, appointment queuing system, nursing workstation logs, and text medical orders. Therefore, C src =4, C phase This indicates the number of time phases in Traditional Chinese Medicine (TCM), based on the Twelve Time Phases theory. (C) phase =12, ω (c,h) This represents the Yin-Yang balance weighting coefficient corresponding to the c-th data source and the h-th TCM time phase, used to reflect the combined modulating effect of multi-source data quality and time rhythm on the fusion result. The summation sign is... This represents a weighted aggregation of feature tensors from all data sources and under all TCM time phases, Γ (c) Γ represents the comprehensive score of data anomalies, missing data, and latency for the c-th data source channel. (j) The score represents the combined score of data anomalies, missing data, and latency for the j-th data source channel.
[0091] The multi-source stable sensing tensor is input into the three-dimensional convolutional decoder and normalized to obtain a stable care demand baseline heatmap.
[0092] In Example 1, the three-dimensional convolutional decoder performs convolution operations on the multi-source stable perception tensor in three dimensions: time slot, nursing unit, and skill label. It extracts temporal features, spatial features, and skill label features through multiple sets of convolutional kernels, aggregates various features, and obtains the baseline feature response value of nursing needs. Normalization is applied to the baseline feature response value of nursing needs obtained by convolution processing to make the response values of different nursing units and skill labels have a uniform and comparable scale. The normalized data is the stable nursing needs baseline heatmap. The stable nursing needs baseline heatmap is consistent with the multi-source stable perception tensor before convolution processing in the three dimensions of time slot, nursing unit, and skill label.
[0093] In the A2FSeg dual-path fusion perception model, the adaptive attention fusion path is used to dynamically adjust the feature channel weights according to the real-time scenario to generate a feature map for sensitive nursing needs compensation.
[0094] In this embodiment, the A2FSeg dual-path fusion sensing model includes:
[0095] In the A2FSeg adaptive attention fusion pathway, a stable nursing demand baseline heatmap is used as the query tensor, all location enhancement features are used as key tensors and value tensors, and real-time scene event embedding tensors are simultaneously accessed.
[0096] Each element of the real-time scene event embedding tensor is used to express the coding strength of insertion events, equipment downtime events, and queue peak events on a specific time slot and care unit.
[0097] By using a linear mapping function, the baseline heatmap of stable nursing needs is converted into a query vector. The enhanced features of each location are converted into scene bias key vectors and into value vectors. The scene bias term is summed for each scene bias key vector. The inner product of the query vector and the scene bias key vector is calculated for each time slot, nursing unit, and skill tag position. The scene bias term is then added to the inner product to obtain the attention score.
[0098] In Example 1, a set of trained linear weights and additive biases are applied to each element of the stable nursing demand baseline heatmap for each time slot, nursing unit, and skill tag using a linear mapping function. This maps the features of each three-dimensional location to a fixed-length vector. All these vectors form a query vector set. For each element in the enhanced features of each location, a set of independently trained linear weights and additive biases are also applied. This maps the features of each three-dimensional location to a scene bias key vector and a value vector, respectively. At each time slot and nursing unit location of the scene bias key vector, the corresponding real-time scene event is embedded into the tensor value. This value is then weighted and adjusted using a set of trainable bias parameters and added to the scene bias key vector at that location to obtain a scene bias key vector containing scene information. At each time slot, nursing unit, and skill tag location, the query vector and the corresponding scene bias key vector are multiplied and accumulated element-wise. The result is used as the attention score for that location to measure the correlation between the current nursing demand baseline and multi-source, multi-time features, as well as the impact of the real-time scene.
[0099] All attention scores are exponentially normalized in two dimensions: data source channel and TCM time phase, to obtain real-time scene adaptive attention weights;
[0100] Real-time scene-adaptive attention weights are used to measure the feature contribution of each data source channel and each TCM time phase under the current time slot, nursing unit, and skill label.
[0101] For each data source channel and each TCM time phase, the corresponding real-time scene adaptive attention weight is multiplied by its value vector minus the multi-source stable perception tensor to obtain the sensitive residual feature;
[0102] Sensitive residual features are used to highlight sudden, local anomalies or scene-specific information that the average fusion path fails to capture.
[0103]
[0104] in, For sensitive residual characteristics, For real-time scene adaptive attention weights, It is a value vector.
[0105] By weighted summing of all sensitive residual features across two dimensions—data source channel and TCM time phase—a sensitive nursing demand compensation feature map is obtained.
[0106] Each position in the sensitive nursing demand compensation feature map represents the sensitive compensation amount for nursing demand under the current time slot, nursing unit, and skill tag, taking into account the dynamic nature of real-time scenarios and the heterogeneous characteristics of multi-source data, so as to realize the dynamic perception of sudden scenarios and the automatic adjustment of feature weights.
[0107] Feature fusion is performed on the baseline feature map of stable nursing needs and the compensation feature map of sensitive nursing needs to output a nursing needs heat map and an urgency mask.
[0108] In this embodiment, the output of the nursing needs heatmap and urgency mask includes:
[0109] For the baseline feature map of stable nursing needs and the compensation feature map of sensitive nursing needs, learnable fusion gating weights are introduced at the positions of each time slot, nursing unit and skill tag to perform weighted summation, so as to obtain the fusion nursing needs feature map.
[0110] In Example 1, the learnable fusion gating weights are used to measure the balance requirements of stable and sensitive features in the current region. The fusion process is as follows: the baseline feature value of stable nursing needs and the compensation feature value of sensitive nursing needs under the current time slot, nursing unit and skill label are multiplied by the learnable fusion gating weights and subtracted by one, respectively. The results are added together to obtain the fused nursing needs feature value. The fusion process is repeated for all time slots, nursing units and skill labels to obtain the fused nursing needs feature map. The learnable fusion gating weights are obtained by the fusion gating network through joint learning of the current real-time scene event embedding tensor and feature map.
[0111] The fused nursing demand feature map is input into the dual-branch mask generation module. In the first branch, a nursing demand heat map is output through continuous three-dimensional convolution operations and the Sigmoid activation function.
[0112] In Example 1, the first branch of the dual-branch mask generation module performs convolutional feature extraction on the fused nursing demand feature values under each time slot, nursing unit, and skill label of the fused nursing demand feature map using continuous three-dimensional convolution operations. Convolutional feature extraction refers to sliding and scanning the fused nursing demand feature map with a fixed window, statistically analyzing the feature information of the location and its surrounding area under each time slot, nursing unit, and skill label, and synthesizing them into a new feature representation. The results of all convolutional feature extraction are input into the Sigmoid activation function at the location of each time slot, nursing unit, and skill label to obtain a normalized nursing demand heat score under each time slot, nursing unit, and skill label. All normalized nursing demand heat scores are collected together to obtain the nursing demand heat map.
[0113] In the second branch of the dual-branch mask generation module, an urgency mask is generated by extracting key perturbation information based on the fusion of nursing demand feature map and real-time scene event embedding tensor.
[0114] In Example 1, at each time slot, nursing unit, and skill tag location, the fused nursing demand feature value at that location and the corresponding element of the real-time scene event embedding tensor are used as inputs and fed into an urgency perception function. The urgency perception function is a set of neural network mappings obtained through end-to-end training, which can automatically learn the combined effect of the fused nursing demand feature value and the scene event intensity on scheduling urgency. The neural network consists of several fully connected layers and normalized activation functions, and is optimized through supervised learning paired with scheduling history tags. The output is the urgency score under the current time slot, nursing unit, and skill tag. The urgency score reflects the urgency of prioritizing scheduling in the current spatiotemporal skill area, and is a continuous value from zero to one or a binary label. The urgency score is aggregated from all locations to form an urgency mask.
[0115] Based on the heat map of nursing needs and the urgency mask, physical constitution classification matching constraints, treatment interval constraints and equipment linkage constraints are generated to form a set of hard constraints and a set of soft constraints.
[0116] In this embodiment, the formation of a hard constraint set and a soft constraint set includes:
[0117] Based on the nursing needs heat map and urgency mask, combined with patient constitution coding and TCM nursing knowledge graph, at each time slot, nursing unit and skill tag position, according to the constitution-nursing behavior compatibility matrix, the feasibility of constitution adaptation for each patient at the time slot, nursing unit and skill tag position is judged for each patient according to the constitution-nursing behavior compatibility matrix.
[0118] The constitution-nursing behavior compatibility matrix is a pre-defined business rule table based on the TCM nursing knowledge graph, domain clinical experience, and nursing standardization norms. The constitution-nursing behavior compatibility matrix analyzes the adaptation relationship between different patient constitution types and nursing skill tags. In the matrix, each combination of constitution code and nursing skill tag is assigned a compatibility tag. A compatibility tag value of one indicates that the constitution and nursing skill tag are compatible and suitable for nursing operations. A compatibility tag value of zero indicates that there is a contraindication or it is not recommended to perform the operation between the current constitution and nursing skill tag.
[0119] In this embodiment, the feasibility of physical fitness matching is used to determine whether the patient meets the physical fitness matching requirements under the current nursing resource configuration:
[0120] If the combination of patient constitution code and current skill tag in constitution-nursing behavior compatibility matrix is marked as feasible, then the constitution adaptation feasibility is 1; otherwise, the constitution adaptation feasibility is 0.
[0121] The feasibility of physical fitness matching is used to determine whether a patient meets the physical fitness matching requirements under the current nursing resource allocation:
[0122] If the combination of patient constitution code and current skill tag in constitution-nursing behavior compatibility matrix is marked as feasible, then the constitution adaptation feasibility is 1; otherwise, the constitution adaptation feasibility is 0.
[0123] Device linkage constraints are used to determine whether the current skill tag is compatible with the device's capabilities and whether the device is in a usable state:
[0124] If the combination is marked as feasible in the skill tag and device capability compatibility matrix, and the device availability in the device resource status matrix under the current time slot and care unit is 1, then the device linkage constraint is 1; otherwise, the device linkage constraint is 0.
[0125] Based on the patient's historical appointment information and treatment plan information, at each time slot, nursing unit, and skill tag position of the nursing needs heat map and urgency mask, for adjacent nursing arrangements of the same patient, it is determined whether the treatment interval constraint is met according to the requirements of the lower and upper bounds of the treatment interval.
[0126] Based on the nursing demand heatmap, urgency mask and equipment resource status matrix, according to the matching relationship between nursing tasks and equipment capabilities, under each time slot, nursing unit and skill tag, it is determined whether the equipment linkage constraints are met;
[0127] In each time slot and nursing unit, the system aggregates in real time the equipment usage status, idle occupancy information, fault alarm data, and maintenance scheduling records uploaded by the nursing business management platform, equipment monitoring system, and IoT terminals. The availability, occupancy, and maintenance status of each device in each time slot and nursing unit are standardized. Each element of the equipment resource status matrix represents the resource availability status of a specific device in a specific time slot and nursing unit. If the device is available in that time slot and nursing unit, the corresponding element of the equipment resource status matrix is set to one; otherwise, it is set to zero.
[0128] Feasibility of physical fitness matching, treatment interval constraints, and equipment linkage constraints are organized as a set of hard constraints. Based on the numerical thresholds of the nursing demand heat map and urgency mask, as well as the business rules of traditional Chinese medicine nursing, some scheduling goals and preferences are set as a set of soft constraints.
[0129] The set of hard constraints ensures that all resource allocation results meet the feasibility requirements in terms of physical condition classification, treatment schedule, and equipment availability. The set of soft constraints includes patient waiting time targets, skill priority matching targets, and nursing unit balanced utilization targets. Each soft constraint is specified by business rules or learning model parameters. The set of soft constraints is used to balance the efficiency and fairness of resource allocation during the scheduling process. It is not mandatory to meet, but it helps to improve the overall scheduling quality.
[0130] A multi-objective optimization function system is constructed, and the nursing demand heat map is used as the cost field, and the hard constraint set and soft constraint set are used as constraint inputs. The multi-objective optimization function system is solved by constraint programming to obtain an initial feasible resource scheduling scheme that satisfies all hard constraint sets.
[0131] In this embodiment, an initial feasible resource scheduling scheme that satisfies the entire set of hard constraints is obtained, including:
[0132] Based on the nursing demand heatmap, the scheduling cost is calculated for each patient under each time slot, nursing unit, and skill tag.
[0133] The scheduling cost is used to represent the resource consumption and demand intensity of patients under the combination of time slot, nursing unit and skill tag. The scheduling cost is obtained by subtracting the nursing demand heat score from the nursing demand heat score and adding it to the nursing urgency score. The subtraction of the nursing demand heat score reflects the current resource gap, and the nursing urgency score reflects the current priority treatment needs. All costs are multiplied by an adjustable weight coefficient to balance the influence of different factors.
[0134] Construct a multi-objective optimization function system that minimizes patient waiting time, maximizes treatment continuity, and maximizes treatment room utilization.
[0135] In this embodiment, the goal of minimizing patient waiting time is achieved by statistically analyzing each nursing service assigned to a patient under all time slots, nursing units, and skill tags, calculating the difference between the time slot and the patient's registered time slot, and summing the results for all patients, time slots, nursing units, and skill tags to obtain the total waiting time. The goal is to minimize the total waiting time.
[0136]
[0137] Where, δ t,l,s,p ∈{0,1} indicates whether patient p is assigned nursing care services at t,l,s, where a p For patient registration time slots, P is the total number of patients or the patient index, representing all individual patients who need to participate in nursing scheduling; T is the number of time slots, representing the number of time segments or time steps that are discretized within the entire nursing scheduling cycle; L is the number of nursing units, representing all nursing space units that can participate in scheduling; and S is the number of skill tags, representing all nursing skill types or nursing behavior tags that participate in scheduling.
[0138] The goal of maximizing treatment continuity is to find the difference between the time interval between consecutive care arrangements and the standard treatment interval for each patient, and to sum the absolute values of the time interval differences between all consecutive care arrangements for all patients. The sum is taken as the treatment continuity loss, and the goal is to minimize this treatment continuity loss and maximize treatment continuity.
[0139]
[0140] Among them, T p Let t1 and t2 be the set of consecutive treatment time slots for patient p, where t1 and t2 are times, and μ is the time slot. p This is the standard treatment interval.
[0141] The goal of maximizing treatment room utilization is to statistically analyze all time slots and care units. Under each time slot and care unit, as long as at least one skill tag is assigned to any patient, that time slot and care unit is considered to be effectively utilized. The total number of effectively utilized time slots and care units is summed to maximize the total number of effectively utilized time slots and care units.
[0142]
[0143] in, The objective of this indicator function is to maximize the effective usage of the treatment room within each time slot.
[0144] Use the sets of hard constraints and soft constraints as input restrictions for scheduling feasibility and preference conditions:
[0145] The physical fitness constraint requires that the binary variable of the nursing service assigned to each patient under each time slot, each nursing unit, and each skill tag cannot exceed the physical fitness feasibility indicator of the position. The physical fitness feasibility indicator is that nursing service assignment is allowed when it is temporarily set, and not allowed when it is zero.
[0146] The treatment interval constraint requires that for each patient, the treatment interval feasibility constraint value is equal to one under all consecutive treatment time slots, that is, the time interval between two nursing operations must be within the specified range, otherwise the allocation is not allowed.
[0147] The device linkage constraint requires that the binary variable of the nursing service assigned to each patient under each time slot, each nursing unit, and each skill tag cannot exceed the sum of the device linkage constraint values of all devices under each time slot, nursing unit, and skill tag. Nursing service assignment is only allowed when there is at least one device linkage constraint value of one.
[0148] Based on the multi-objective optimization function system, scheduling cost tensor, hard constraint set and soft constraint set, a constrained optimization model is constructed;
[0149] The optimization objective of the constrained optimization model is to minimize the sum of the objective function that minimizes patient waiting time multiplied by the patient waiting time weight coefficient, the objective function that maximizes treatment continuity multiplied by the treatment continuity weight coefficient, and the objective function that maximizes treatment room utilization multiplied by the treatment room utilization weight coefficient, plus the sum of the products of all scheduling cost tensors and the binary variables of patient-assigned nursing services. The patient waiting time weight coefficient, treatment continuity weight coefficient, and treatment room utilization weight coefficient are non-negative real numbers used to adjust the priority among multiple objectives.
[0150] The constrained programming algorithm is used to solve the constrained optimization model. Under the premise that all hard constraints are satisfied, a set of initial feasible resource scheduling schemes that meet the scheduling feasibility conditions are output.
[0151] In Example 1, when solving the constrained optimization model using the constrained programming algorithm, all decision variables for resource scheduling are constructed based on the nursing demand heatmap, urgency mask, physical fitness feasibility, treatment interval constraint, equipment linkage constraint, and related soft constraint objectives. Each decision variable represents whether a patient is allocated nursing services under a specific time slot, nursing unit, and skill tag. All decision variables are initialized to zero to indicate an unallocated state. During the solution process, the constrained programming algorithm progressively assigns values to all decision variables. Before allocating nursing services to a patient under a specific time slot, nursing unit, and skill tag, it first checks whether the physical fitness feasibility, treatment interval constraint, and equipment linkage constraint are all equal to one. Only when all hard constraints are equal to one is the allocation of nursing services allowed. Decision variables are assigned a value of one, otherwise they remain zero. As decision variables are assigned values, the current value of each main objective function and the cumulative deviation of all soft constraint objectives are calculated in real time. If all hard constraints are satisfied on the entire scheduling table after all decision variables are assigned values, then the allocation result is a feasible solution. Among all feasible solutions, the allocation result that minimizes the weighted objective value is selected as the initial feasible resource scheduling scheme by comparing the weighted sum of each objective function. The initial feasible resource scheduling scheme includes the allocation decisions of all patients under all time slots, all nursing units, and all skill tags, and ensures that all hard constraint sets are satisfied and all scheduling feasibility conditions are met. It also comprehensively considers the nursing demand heatmap, urgency mask, and soft constraint optimization objectives.
[0152] Using urgency masks as the rolling cost, the initial feasible resource scheduling scheme is improved by a rolling re-optimization strategy to generate the final resource scheduling scheme.
[0153] In this embodiment, the initial feasible resource scheduling scheme is improved by performing a rolling re-optimization strategy, including:
[0154] Based on the initial feasible resource scheduling plan, the nursing service arrangements for all time slots covered by the rolling time window are re-evaluated within each rolling time window;
[0155] The rolling time window is used to determine the time range within which the current system needs to be re-optimized. The length of the rolling time window is equal to the length of the rolling window. The starting point of the rolling time window is the current system time slot, and all time slots contained in the rolling time window are arranged consecutively.
[0156] Within the rolling time window, the urgency score for each patient, time slot, nursing unit, and skill tag position is used as the rolling cost weight;
[0157] The rolling cost weight is used to indicate the priority of the current position in the current rolling re-optimization.
[0158] Within the rolling time window, the resource allocation results of the completed or executed parts of the initial feasible resource scheduling scheme are retained, and the resource allocation schemes that have not yet been executed are optimized in a rolling manner to construct a local rolling optimization model;
[0159] Within the rolling time window, the resource allocation results that have been completed or executed are retained, while only the resource allocation results that have not yet been executed are re-optimized. The re-optimization process involves weighted summation of the rolling cost weights and the variables to be allocated under all patients, time slots, nursing units, and skill tags within the rolling time window. The goal of the weighted summation is to minimize the total weighted sum. The local rolling optimization model is the sum of the products of the rolling cost weights and the corresponding allocation variables under all patients, time slots, nursing units, and skill tags within the rolling time window. The local rolling optimization model is used to measure the overall urgency and rationality of the current allocation plan.
[0160] In the local rolling optimization model, the set of hard constraints and the set of soft constraints that are consistent with all initial feasible resource scheduling schemes are used as constraints for rolling optimization. Only when all constraints are satisfied can the allocation variable be assigned a value of one.
[0161] The physical fitness constraint requires that the allocation variables under each patient, time slot, nursing unit, and skill tag cannot exceed the physical fitness feasibility indicator. The treatment interval constraint requires that the time interval between all consecutive nursing arrangements must be within the specified range. The equipment linkage constraint requires that the allocation variables under each patient, time slot, nursing unit, and skill tag cannot exceed the sum of the equipment availability of all equipment at the corresponding location.
[0162] Within the rolling time window, the resource allocation results of the unexecuted portion are optimized based on the local rolling optimization model and the complete set of hard constraints and soft constraints. After optimization, the newly obtained resource allocation results within the rolling window are concatenated with the resource allocation results of the executed portion and the un-rolled optimized portion to form a complete resource scheduling scheme. The rolling re-optimization process is then repeated to form the final resource scheduling scheme.
[0163] The concatenated resource scheduling scheme adopts the latest optimization results within the rolling window, while retaining the original allocation results in the completed and non-rolling optimized parts.
[0164] As the system progresses, the rolling time window slides continuously, and the rolling re-optimization process is repeated within each new rolling window period. Each optimization dynamically adjusts the allocation priority and resource configuration based on the latest urgency mask, ultimately forming a complete and executable final resource scheduling scheme covering the entire scheduling cycle. The final resource scheduling scheme ensures that the service allocation under all patients, time slots, nursing units, and skill tags satisfies all hard constraints and responds to the urgency and dynamic changes of resource configuration within the rolling time window to the greatest extent.
[0165] Example 2: In the TCM nursing resource dispatch center of a hospital, after the system accesses multi-source business data such as electronic medical records, appointment queues, nursing logs, and medical orders, it automatically standardizes, desensitizes, and semantically maps all the data. The nursing business on that day includes four types of projects: acupuncture, moxibustion, cupping, and massage. The nursing unit consists of five independent treatment rooms with a total of ten nursing doctors. The patient constitution types covered by the business are divided into six categories: Yin deficiency, Yang deficiency, Qi deficiency, and blood stasis.
[0166] One morning, the nursing scheduling system automatically completed the following entire process:
[0167] Starting at 2:00 AM each day, the system periodically aggregates all the latest nursing appointments, doctor check-ins, equipment status, and temporary medical orders from night shift doctors, generating a total of 2187 original TCM nursing data records, which are then uniformly converted into a standardized data format. In this round of data processing, 95% of the data was automatically matched to standard fields, and the remaining portion was corrected by a semantic mapping dictionary.
[0168] At 7:30 AM that day, the A2FSeg model was activated, automatically splitting all multi-source nursing data into 48 feature channels based on data source tags and TCM time-phase tags. Taking patient A as an example, the data showed a "Yin deficiency" constitution tag between 6:00 and 7:00 AM, requesting cupping services, requiring a female doctor, and having a record of making up for unfinished massage from the previous day. The model automatically identified the corresponding time, constitution, and nursing behavior in the data, pushing the data into a constitution-adaptive gating unit. The gating unit assigned specific feature channel weights, increasing the weight of "Yin deficiency + morning + cupping" by 17%, accurately capturing potential high-demand signals. After fusion, the nursing demand heat score generated by the model showed that the demand for cupping services during this period was 8.4 points (out of 10), the highest in the entire department.
[0169] At 8:05, the system simultaneously received an alarm from the nursing station that a cupping device, numbered D3, was detected to be faulty in treatment unit S2. The device status changed from "available" to "disabled." The urgency mask immediately reflected the decreased availability and increased waiting risk of cupping in unit S2 from 9:00 to 10:00. The adaptive attention fusion pathway automatically input real-time events such as device malfunctions and changes in doctor scheduling into the model, increasing the weight of all service features in S2 during this period by 21% and decreasing the weight of irrelevant features by 15%. Based on the fusion gating output, the system generated a high-precision nursing demand heatmap and urgency mask. Within 10 seconds, the system updated the scheduling suggestion, reassigning patient A and 5 other patients with concentrated but unaffected cupping service needs to units S3 and S4.
[0170] During the business constraint integration process, the system automatically compares each appointment service item against the constitution-skill compatibility matrix. In Example 2, patient B has a Qi deficiency constitution and schedules moxibustion. The system determines that the compatibility flag between Qi deficiency constitution and moxibustion is 1, allowing scheduling. Patient C, however, has a Yin deficiency constitution and requests massage with a male doctor. The system detects that massage should not be repeated within 48 hours of the previous day's massage service, thus the treatment interval constraint takes effect, and the system automatically postpones their scheduling to the following afternoon. In the equipment linkage constraint, the system synchronously reads the equipment availability matrix to ensure that each nursing unit's service allocation for each time period has corresponding available equipment.
[0171] In the actual scheduling process, the system generates an initial feasible scheduling plan based on a multi-objective optimization model (waiting time, treatment continuity, and utilization rate). During the peak period of 8:40-10:00, the system scheduled a total of 45 patients, including 18 for cupping, 14 for massage, and 13 for moxibustion. The average patient waiting time was 16 minutes, the maximum waiting time was 33 minutes, the treatment failure rate was only 1 / 45, and the utilization rate of all equipment increased to 94%. During the same period, when scheduling similar cases using traditional scheduling methods (using static weighting and manual fine-tuning), the average waiting time was 29 minutes, the maximum waiting time was 61 minutes, the treatment failure rate was 5 / 45, and the equipment utilization rate was only 78%.
[0172] At 9:35, a new patient, D, requested an acupuncture appointment due to acute pain. Upon detecting an urgency mask value of 0.96, the system automatically triggered a rolling re-optimization, inserting D into the originally scheduled slot of treatment unit S5 at 10:10. The originally scheduled patient, E, was automatically postponed. The entire adjustment took 27 seconds without manual intervention. The event log shows that this rolling re-ordering did not violate any patient suitability, treatment interval, or equipment availability constraints, and the system simultaneously ensured the optimal solution for soft constraint objectives (waiting time, resource balance, etc.).
[0173] In a week-long simulation of actual operations, the scheduling system using the method of this invention dispatched a total of 2,457 patients, experienced 23 order insertions, 17 temporary equipment outages, and 11 instances of doctors requesting leave. The average dispatch and repair time for all emergencies was 1 minute and 52 seconds, with a maximum repair delay of 6 minutes and 14 seconds. In comparison, the average manual dispatch and repair time for emergencies using traditional methods was 19 minutes and 37 seconds, with a maximum repair delay of 68 minutes.
[0174] The method of this invention had a total average patient waiting time of 17.1 minutes over one week, compared to 31.5 minutes in the control method; the treatment continuity failure rate was 1.1%, compared to 6.7% in the control group; and the equipment utilization rate was 92.6%, compared to 77.2% in the control group.
[0175] The sample data used for model training is shown in Table 1 below:
[0176] Table 1. Sample data used for model training
[0177]
[0178] Example 2 shows that the method of the present invention can automatically and quickly adjust the scheduling without breaking the hard constraints in the event of sudden equipment shutdown, order insertion, and treatment course changes. The waiting time and treatment course default rate are significantly better than the traditional method, and the resources are utilized more fully.
[0179] The above description is only a preferred embodiment of the present invention, but the scope of protection of the present invention is not limited thereto. Any equivalent substitutions or modifications made by those skilled in the art within the scope of the technology disclosed in the present invention, based on the technical solution and inventive concept of the present invention, should be covered within the scope of protection of the present invention.
Claims
1. A method for optimizing deployment of traditional Chinese medicine nursing resources based on machine learning, characterized in that, The method comprises the following steps: acquire and preprocess the multi-source data set of traditional Chinese nursing business to generate a standardized multi-source data set of traditional Chinese nursing business; input the standardized multi-source data set of traditional Chinese nursing business into an A2FSeg dual-path fusion perception model, and generate a stable nursing demand baseline feature map by using an average fusion path; in the A2FSeg dual-path fusion perception model, generate a sensitive nursing demand compensation feature map by using an adaptive attention fusion path to dynamically adjust the feature channel weight according to the real-time scene; fuse the stable nursing demand baseline feature map and the sensitive nursing demand compensation feature map, and output a nursing demand heat map and a urgency mask; generate a constitution classification matching constraint, a treatment interval constraint and a equipment linkage constraint based on the nursing demand heat map and the urgency mask, and form a hard constraint set and a soft constraint set; construct a multi-objective optimization function system, take the nursing demand heat map as a cost field, take the hard constraint set and the soft constraint set as constraint inputs, solve the multi-objective optimization function system by using constraint programming, and obtain an initial feasible resource scheduling scheme that meets all the hard constraint set; take the urgency mask as a rolling cost, and execute a rolling re-optimization strategy improvement on the initial feasible resource scheduling scheme to generate a final resource scheduling scheme.
2. The machine learning-based traditional Chinese medicine nursing resource optimization and deployment method according to claim 1, characterized in that, The preprocessing comprises the following steps: unify and collect electronic medical record system data, appointment queuing system data, nursing workstation log data and text medical order data, and construct a data record according to each piece of traditional Chinese nursing original data; perform format normalization processing on the traditional Chinese nursing original data record to form a format normalized data record set; perform desensitization processing on each data record in the format normalized data record set to form a desensitization data record set; perform semantic mapping processing on each data record in the desensitization data record set to form a semantic consistency data record set, and take the semantic consistency data record set as the standardized multi-source data set of traditional Chinese nursing business.
3. The method of claim 2, wherein, The method for generating a stable nursing demand baseline feature map by using an average fusion path comprises the following steps: divide the standardized multi-source data set of traditional Chinese nursing business into a plurality of feature channel sets according to data source labels and traditional Chinese time phase labels; input the data tensor of each feature channel into a constitution adaptive gating unit, adjust each patient constitution code by the constitution adaptive gating unit, weight and gate different features of the data tensor by a weight value and a constitution bias term, and output constitution sensitive features; perform meridian-space embedding coding on each constitution sensitive feature at the position of each time slot, nursing unit and skill label, and output position enhanced features; weight all the position enhanced features according to Yin-Yang balance weights, and output a multi-source stable perception tensor; input the multi-source stable perception tensor into a three-dimensional convolution decoder, and perform normalization processing to obtain a stable nursing demand baseline heat map.
4. The method of claim 3, wherein, The A2FSeg dual-path fusion perception model comprises: In the A2FSeg adaptive attention fusion channel, the stable nursing demand baseline heat map is taken as a query tensor, all position enhanced features are taken as key tensors and value tensors, and real-time scene event embedding tensors are synchronously accessed; The stable nursing demand baseline heat map is converted into a query vector by a linear mapping function, each position enhanced feature is converted into a scene bias key vector and a value vector, and the scene bias item is added to each scene bias key vector to calculate the inner product of the query vector and the scene bias key vector at each time slot, nursing unit, and skill label position, and the scene bias item is superimposed on the inner product to obtain an attention score; All attention scores are exponentially normalized in the data source channel and the traditional Chinese time phase dimensions to obtain real-time scene adaptive attention weights; For each data source channel and each traditional Chinese time phase, the corresponding real-time scene adaptive attention weight is multiplied by the result of subtracting the value vector from the multi-source stable perception tensor to obtain a sensitive residual feature; All sensitive residual features are weighted and summed in the data source channel and the traditional Chinese time phase dimensions to obtain a sensitive nursing demand compensation feature map.
5. The method of claim 4, wherein, The output nursing demand heat map and urgency mask include: The stable nursing demand baseline feature map and the sensitive nursing demand compensation feature map are weighted and summed at each time slot, nursing unit, and skill label position by introducing a learnable fusion gate weight to obtain a fusion nursing demand feature map; The fusion nursing demand feature map is input into a double-branch mask generation module, and in the first branch, a continuous three-dimensional convolution operation and a Sigmoid activation function are used to output a nursing demand heat map; In the second branch of the double-branch mask generation module, based on the fusion nursing demand feature map and the real-time scene event embedding tensor, a key disturbance information is extracted to generate an urgency mask.
6. The method of claim 5, wherein, The formation of the hard constraint set and the soft constraint set includes: Based on the nursing demand heat map and the urgency mask, combined with the patient constitution code and the traditional Chinese nursing knowledge graph, at each time slot, nursing unit, and skill label position, the constitution-nursing behavior compatibility matrix is used to judge the constitution adaptation feasibility of each patient at the time slot, nursing unit, and skill label position; Based on the patient historical appointment information and the treatment plan information, at each time slot, nursing unit, and skill label position of the nursing demand heat map and the urgency mask, the adjacent nursing arrangements of the same patient are judged whether the treatment interval constraints are satisfied according to the treatment interval lower bound and the treatment interval upper bound requirements; Based on the nursing demand heat map, the urgency mask, and the equipment resource state matrix, according to the nursing task and equipment capability matching relationship, it is judged whether the equipment linkage constraint is satisfied at each time slot, nursing unit, and skill label; The constitution adaptation feasibility, the treatment interval constraint, and the equipment linkage constraint are arranged as a hard constraint set, and part of the scheduling target and preference is set as a soft constraint set according to the numerical threshold of the nursing demand heat map and the urgency mask and the traditional Chinese nursing business rules.
7. The method of claim 6, wherein, The body constitution adaptation feasibility is used to determine whether the patient meets the body constitution matching requirement under the current nursing resource configuration: If the combination of the patient's body constitution code and the current skill label in the body constitution-nursing behavior compatibility matrix is marked as feasible, the body constitution adaptation feasibility is 1, otherwise the body constitution adaptation feasibility is 0; The body constitution adaptation feasibility is used to determine whether the patient meets the body constitution matching requirement under the current nursing resource configuration: If the combination of the patient's body constitution code and the current skill label in the body constitution-nursing behavior compatibility matrix is marked as feasible, the body constitution adaptation feasibility is 1, otherwise the body constitution adaptation feasibility is 0; The equipment linkage constraint is used to determine whether the current skill label and the equipment capability are compatible and the equipment is in an available state: If the combination in the skill label and equipment capability compatibility matrix is marked as feasible, and the equipment availability in the equipment resource state matrix under the current time slot and nursing unit is 1, the equipment linkage constraint is 1, otherwise the equipment linkage constraint is 0.
8. The method of claim 7, wherein, The initial feasible resource scheduling scheme that meets the entire set of hard constraints includes: According to the nursing demand heat map, for each patient, calculate the scheduling cost value under each time slot, nursing unit and skill label; A multi-objective optimization function system of the patient waiting time minimization objective, the course continuity maximization objective and the treatment room utilization maximization objective is constructed; S63. The set of hard constraints and the set of soft constraints are used as input limit conditions for scheduling feasibility and preference conditions; Based on the multi-objective optimization function system, the scheduling cost tensor, the set of hard constraints and the set of soft constraints, a constraint optimization model is constructed; The constraint optimization model is solved by using a constraint programming algorithm, and an initial feasible resource scheduling scheme that meets the scheduling feasibility conditions is output under the premise that all hard constraints are met.
9. The method of claim 8, wherein, The patient waiting time minimization objective is to calculate the difference between the time slot and the patient registration time slot for each nursing service assigned to the patient under all time slots, nursing units and skill labels, and sum all patients, time slots, nursing units and skill labels to obtain the total waiting time, the goal is to minimize the total waiting time; The course continuity maximization objective is to calculate the difference between the time interval of consecutive nursing arrangements and the standard course interval for each patient, and sum the absolute values of the time interval differences of all consecutive nursing arrangements for all patients, and the total sum is the course continuity loss, the goal is to minimize the course continuity loss and maximize the course continuity; The treatment room utilization maximization objective is to count all time slots and nursing units, and as long as at least one skill label is assigned to any patient under each time slot and nursing unit, the time slot and nursing unit are considered to be effectively utilized, and the total number of all effectively utilized time slots and nursing units is summed, the goal is to maximize the total number of effectively utilized time slots and nursing units.
10. The method of claim 9, wherein, The initial feasible resource scheduling scheme is improved by performing a rolling re-optimization strategy, including: Based on the initial feasible resource scheduling scheme, the nursing service arrangement in all time slots covered by the rolling time window is re-evaluated in each rolling time window; In the rolling time window, the resource allocation results of the completed or executed part of the initial feasible resource scheduling scheme are retained, and the resource allocation scheme that has not been executed is optimized in a rolling manner to construct a local rolling optimization model; In the local rolling optimization model, the hard constraint set and the soft constraint set consistent with all the initial feasible resource scheduling schemes are used as the limiting conditions for rolling optimization, and the assignment variable can only be assigned a value of one when all the constraints are satisfied; In the rolling time window, the resource allocation results of the part that has not been executed are optimized based on the local rolling optimization model and all the hard constraint set and soft constraint set, and after optimization, the newly obtained resource allocation results in the rolling window are spliced with the resource allocation results of the executed part and the non-rolling optimization part to form a complete resource scheduling scheme, and the rolling re-optimization process is repeated to form the final resource scheduling scheme.