Neural network-based postoperative diet intake nutrition evaluation system for weight loss surgery
By using Transformer-RL model and multi-dimensional analysis technology in the postoperative nutrition assessment system of weight loss surgery, the problem that traditional systems cannot capture individual differences and dynamic changes is solved, and accurate assessment and dynamic adjustment of postoperative patients' dietary intake are achieved, which significantly improves the postoperative recovery effect.
Patent Information
- Application Number
- CN202510496928.1
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-04-21
- Publication Date
- 2025-05-23
- Estimated Expiration
- 2045-04-21
AI Technical Summary
The traditional postoperative nutrition assessment system of weight loss surgery cannot effectively capture individual differences between patients and dynamic changes in the postoperative recovery process, resulting in inaccurate nutrition assessment results and difficult to adapt to the needs of patients at different stages of recovery.
A nutritional assessment system for postoperative dietary intake of weight loss surgery is adopted based on neural network, and a Transformer-RL model is used to combine channel separation, fragment extraction, location embedding, situation embedding and decision tree path optimization strategies to conduct multi-dimensional analysis through deep learning technology and dynamically adjust nutritional plans.
It has achieved accurate nutritional assessment of the dietary intake of patients after surgery, which can promptly respond to changes in patients' dietary needs during postoperative rehabilitation, ensure the scientificity and effectiveness of nutritional intake, and greatly improve the postoperative recovery effect.
Smart Images

Figure CN120032808A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of health data analysis, and in particular to a neural network-based dietary intake nutrition assessment system for patients after weight loss surgery. Background Art
[0002] With the continuous development of science and technology, although the traditional postoperative nutritional assessment system for weight loss surgery has helped patients' recovery to a certain extent, it still has some shortcomings: First, the traditional system often ignores the individual differences of patients and the dynamic changes in the postoperative recovery process, resulting in the nutritional assessment results may not be accurate enough, and the patient's diet plan cannot be adjusted in time; secondly, the traditional system ignores the comprehensive analysis of the patient's multi-dimensional data, or has low sensitivity to certain influencing factors; for example, the dietary needs of postoperative patients not only depend on the intake, but are also closely related to the body's recovery, metabolic changes and the patient's individual health status; traditional methods often cannot effectively capture these complex relationships, resulting in poor assessment accuracy and difficulty in adapting to the needs of patients at different stages of recovery; therefore, there is an urgent need for a postoperative dietary intake nutritional assessment system for weight loss surgery based on a neural network, which uses a deep learning model to conduct a multi-dimensional analysis of the patient's health data, combined with a personalized optimization path, and dynamically adjusts the nutrition plan to ensure the effectiveness of postoperative rehabilitation. Summary of the invention
[0003] The present invention provides a postoperative dietary intake nutrition assessment system for weight loss surgery based on a neural network, which aims to optimize postoperative nutritional assessment through deep learning technology, provide patients with personalized dietary advice, and support postoperative recovery and long-term health management. In the system, a Transformer-RL model combining channel separation, fragment extraction, position embedding, context embedding and decision tree path optimization strategy is first used to process complex postoperative health data. This model can more efficiently analyze the health data of patients and generate preliminary nutritional assessment results. In order to further improve the accuracy of the assessment and the adaptability of the system, the system optimizes the reasoning path in the Transformer-RL model through path optimization technology. Specifically, the marginal reward optimization loss function is adopted, combined with value optimization, contrastive learning, Bellman optimality, logarithmic loss and reward normalization strategies, to optimize the generation process of the initial reasoning path. The optimization scheme can evaluate the potential of the path in real time, ensure that the evaluation results fully consider the personalized needs of patients and the actual situation of postoperative recovery, thereby generating the optimal reasoning path and further improving the accuracy of nutritional assessment. Through the above technical steps, the present invention realizes a system that can dynamically adjust the nutritional plan and accurately evaluate the dietary intake of postoperative patients, providing scientific and effective support for the rehabilitation of postoperative patients.
[0004] The present invention provides a postoperative dietary intake nutrition assessment system for weight loss surgery based on a neural network, the system comprising a data acquisition module, a data preprocessing module, a nutrition assessment module, an optimization assessment module and a program adjustment module:
[0005] The data collection module collects the patient's basic information, diet records, postoperative recovery data, and nutritional needs data, and integrates them as postoperative health data;
[0006] The data preprocessing module removes redundancy, processes missing values, standardizes and cleans the postoperative health data to generate refined health data;
[0007] Nutritional assessment module: Establish a Transformer model, optimize the Transformer model by combining channel separation, fragment extraction, position embedding, context embedding and decision tree path optimization strategy, build a Transformer-RL model, process and refine health data through the Transformer-RL model, and generate nutritional assessment results; the Transformer-RL model includes an encoder layer and a linear layer;
[0008] The optimization evaluation module combines value optimization, contrastive learning, Bellman optimality, logarithmic loss and reward normalization to construct a marginal reward optimization loss function. The marginal reward optimization loss function is used to optimize the Transformer-RL model and generate optimized nutritional evaluation results.
[0009] The plan adjustment module adjusts nutritional needs based on the optimized nutritional assessment results, dynamically adjusts the nutritional plan, improves postoperative recovery effects and supports long-term health management.
[0010] Furthermore, the process of generating the nutrition assessment result by the nutrition assessment module specifically includes the following steps:
[0011] Step S1: Channel separation: Perform channel separation on the refined health data, process different categories of data independently, separate the influences between different data dimensions, thereby improving the prediction accuracy of the model and generating separated health data;
[0012] Step S2: segment extraction: the separated health data is divided into time series segments, each of which represents the health data characteristics in different time periods, and a health data segment set is generated;
[0013] Step S3: Position embedding: adding position codes to the health data segment set, maintaining time order and time correlation, and generating an embedded information health data segment set;
[0014] Step S4: Linear projection: Mapping the embedded information health data segment set into health data feature representation through linear projection;
[0015] Step S5: encoder processing: processing the health data feature representation through the encoder layer to generate encoder feature data;
[0016] Step S6: Decision tree optimization: Processing encoder feature data through decision tree path optimization strategy to generate an initial reasoning path;
[0017] Step S7: Output: Flatten the initial reasoning path and generate the nutritional assessment result through a linear layer.
[0018] Further, step S5 specifically includes the following steps:
[0019] Step S51: introducing a context embedding mechanism and a multi-head attention mechanism, dynamically adjusting the multi-head attention mechanism through the context embedding mechanism, constructing a context-multi-head attention mechanism, focusing on health data feature representation in parallel through the context-multi-head attention mechanism, learning the dependencies between different types of health data feature representations, and generating attention mechanism feature data;
[0020] Step S52: Perform additive normalization and feedforward operations on the attention mechanism feature data to enhance the stability and expressiveness of the data and generate encoder feature data.
[0021] Further, step S6 specifically includes the following steps:
[0022] Step S61: Convert the encoder feature data into a logarithmic probability distribution, and construct a candidate path set according to the logarithmic probability distribution, where the candidate path set is divided into an unterminated candidate path and a terminated candidate path;
[0023] Step S62: performing an expansion operation on the unterminated candidate paths to ensure that the exploration scope covers the potential solution space and generate an expanded reasoning path set;
[0024] Step S63: traverse the extended reasoning path set, perform reasoning, generate new reasoning paths, and improve the candidate path set. In each round of reasoning, ensure the breadth and depth of reasoning path exploration, ensure that the potential of each reasoning path is fully evaluated, and generate a complete reasoning path set; the complete reasoning path set contains multiple reasoning paths;
[0025] Step S64: For each reasoning path in the complete reasoning path set, the Bellman error and the logit value are used to score, the potential of each reasoning path is evaluated, and the current optimal reasoning path is selected as the initial reasoning path.
[0026] Furthermore, the process of generating the optimized nutrition assessment result by the optimization assessment module specifically includes the following steps:
[0027] Step B1: Evaluate the reward difference of the initial reasoning path by optimizing the loss function through the marginal reward;
[0028] Step B2: Optimize the initial reasoning path according to the reward difference, generate the optimal reasoning path, optimize the Transformer-RL model according to the optimal reasoning path, and generate the optimized nutritional evaluation result.
[0029] By adopting the above scheme, the beneficial effects achieved by the present invention are as follows:
[0030] The present invention provides a post-operative dietary intake nutritional assessment system for weight loss surgery based on a neural network. By combining advanced deep learning methods and multi-dimensional data processing technology, the accurate nutritional assessment of post-operative dietary intake for weight loss surgery is successfully achieved. The Transformer-RL model adopted by the system can efficiently process complex post-operative health data, and accurately capture various health characteristics of patients in the post-operative recovery process through technologies such as channel separation, fragment extraction, position embedding and context embedding, thereby providing a more personalized dietary assessment for post-operative patients. The method enables the assessment system to respond to changes in the patient's dietary needs during the post-operative recovery process in a timely manner, ensuring the scientificity and effectiveness of nutritional intake, and greatly improving the post-operative recovery effect.
[0031] By introducing path optimization technology, the present invention further improves the reasoning accuracy and adaptability of the system; the use of marginal reward optimization loss function enables the system to adjust the reasoning path in real time, optimize the accuracy of the nutritional assessment results, and ensure that the system can dynamically adapt to the patient's personalized needs and recovery progress; combined with value optimization, contrastive learning, and Bellman optimality and other technologies, the model can not only fully evaluate the potential of each reasoning path, but also optimize the reasoning path through multiple rounds of reasoning, thereby enhancing the accuracy of the evaluation results; the optimized reasoning path can better adapt to the postoperative recovery needs of different patients, thereby improving the practicality and accuracy of the system;
[0032] In summary, the beneficial effect of the present invention is that, by introducing advanced neural network technology and path optimization algorithm, the problems of low accuracy and poor adaptability in traditional postoperative nutritional assessment methods are solved; the system can not only evaluate the patient's nutritional needs in real time based on personalized health data, but also dynamically adjust the diet plan to ensure the nutritional intake and rehabilitation effect of postoperative patients; the implementation of this technology provides a more accurate and efficient solution for dietary management after weight loss surgery, significantly improves the patient's postoperative recovery quality, and provides strong technical support for long-term health management. BRIEF DESCRIPTION OF THE DRAWINGS
[0033] Figure 1 A schematic diagram of a module of a neural network-based dietary intake and nutritional assessment system for weight loss surgery provided by the present invention;
[0034] Figure 2 Schematic diagram of the structure of the Transformer-RL model in Example 2. DETAILED DESCRIPTION
[0035] The technical solutions in the embodiments of the present invention will be clearly and completely described below in conjunction with the drawings in the embodiments of the present invention. Obviously, the described embodiments are only part of the embodiments of the present invention, rather than all the embodiments; based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without making creative work are within the scope of protection of the present invention.
[0036] Embodiment 1, according to Figure 1 The present invention provides a postoperative dietary intake nutrition assessment system for weight loss surgery based on a neural network, the system comprising a data acquisition module, a data preprocessing module, a nutrition assessment module, an optimization assessment module and a program adjustment module:
[0037] The data collection module collects the patient's basic information, diet records, postoperative recovery data, and nutritional needs data, and integrates them as postoperative health data;
[0038] The data preprocessing module removes redundancy, processes missing values, standardizes and cleans the postoperative health data to generate refined health data;
[0039] Nutritional assessment module: Establish a Transformer model, optimize the Transformer model by combining channel separation, fragment extraction, position embedding, context embedding and decision tree path optimization strategy, build a Transformer-RL model, process and refine health data through the Transformer-RL model, and generate nutritional assessment results; the Transformer-RL model includes an encoder layer and a linear layer;
[0040] The optimization evaluation module combines value optimization, contrastive learning, Bellman optimality, logarithmic loss and reward normalization to construct a marginal reward optimization loss function. The marginal reward optimization loss function is used to optimize the Transformer-RL model and generate optimized nutritional evaluation results.
[0041] The plan adjustment module adjusts nutritional needs based on the optimized nutritional assessment results, dynamically adjusts the nutritional plan, improves postoperative recovery effects and supports long-term health management.
[0042] Embodiment 2, according to Figure 2This embodiment is based on the first embodiment. In this embodiment, the nutrition assessment module processes and refines health data through the Transformer-RL model to generate a nutrition assessment result, which specifically includes the following steps:
[0043] Step S1: Channel separation: Perform channel separation on the refined health data, process different categories of data independently, separate the influences between different data dimensions, thereby improving the prediction accuracy of the model and generating separated health data;
[0044] Step S2: segment extraction: the separated health data is divided into time series segments, each time series segment represents the health data characteristics in different time periods, and a health data segment set is generated;
[0045] Step S3: Position embedding: adding position codes to the health data segment set, maintaining time order and time correlation, and generating an embedded information health data segment set;
[0046] Step S4: Linear projection: Mapping the embedded information health data segment set into health data feature representation through linear projection;
[0047] Step S5: encoder processing: processing the health data feature representation through the encoder layer to generate encoder feature data;
[0048] Step S6: Decision tree optimization: Processing encoder feature data through decision tree path optimization strategy to generate an initial reasoning path;
[0049] Step S7: Output: Flatten the initial reasoning path and generate the nutritional assessment result through a linear layer.
[0050] Embodiment 3: This embodiment is based on embodiment 1. In this embodiment, the process of generating the nutrition assessment result specifically includes the following steps:
[0051] Step E1: Channel separation: Perform channel separation on the refined health data, process different categories of data independently, separate the influences between different data dimensions, thereby improving the prediction accuracy of the model and generating separated health data;
[0052] Step E2: segment extraction: the separated health data is divided into time series segments, each of which represents the health data characteristics in different time periods, and a health data segment set is generated;
[0053] Step E3: Position embedding: adding position codes to the health data segment set, maintaining time order and time correlation, and generating an embedded information health data segment set;
[0054] Step E4: Linear projection: Mapping the embedded information health data segment set into health data feature representation through linear projection;
[0055] Step E5: encoder processing: processing the health data feature representation through the encoder layer to generate encoder feature data;
[0056] Step E6: Output: The encoder feature data is flattened and passed through a linear layer to generate the nutritional assessment result.
[0057] Embodiment 4: This embodiment is based on embodiment 2. In this embodiment, step S5 specifically includes the following steps:
[0058] Step S51: introducing a context embedding mechanism and a multi-head attention mechanism, dynamically adjusting the multi-head attention mechanism through the context embedding mechanism, constructing a context-multi-head attention mechanism, focusing on health data feature representation in parallel through the context-multi-head attention mechanism, learning the dependencies between different types of health data feature representations, and generating attention mechanism feature data;
[0059] Step S52: Perform additive normalization and feedforward operations on the attention mechanism feature data to enhance the stability and expressiveness of the data and generate encoder feature data.
[0060] Embodiment 5: This embodiment is based on embodiment 2. In this embodiment, step S5 specifically includes the following steps:
[0061] Step R1: Introduce a multi-head attention mechanism, which focuses on the feature representation of health data in parallel, learns the dependencies between different types of health data, and generates attention mechanism feature data;
[0062] Step R2: Perform additive normalization and feedforward operations on the attention mechanism feature data to enhance the stability and expressiveness of the data and generate encoder feature data.
[0063] Embodiment 6: This embodiment is based on embodiment 4. In this embodiment, step S6 specifically includes the following steps:
[0064] Step S61: Convert the encoder feature data into a logarithmic probability distribution, and construct a candidate path set according to the logarithmic probability distribution, where the candidate path set is divided into an unterminated candidate path and a terminated candidate path;
[0065] Step S62: performing an expansion operation on the unterminated candidate paths to ensure that the exploration scope covers the potential solution space and generate an expanded reasoning path set;
[0066] Step S63: traverse the extended reasoning path set, perform reasoning, generate new reasoning paths, and improve the candidate path set. In each round of reasoning, ensure the breadth and depth of reasoning path exploration, ensure that the potential of each reasoning path is fully evaluated, and generate a complete reasoning path set; the complete reasoning path set contains multiple reasoning paths;
[0067] Reasoning is performed for 20 rounds;
[0068] Step S64: For each reasoning path in the complete reasoning path set, the Bellman error and logit value are used to score, evaluate the potential of each reasoning path, and select the current optimal reasoning path as the initial reasoning path. The formula used is as follows:
[0069] ;
[0070] in, represents the time step, represents the Bellman error, Represents the time step status, Represents the time step status, Indicates action; Indicates in status Next action Instant rewards, represents the discount factor, Indicates status The value function of Indicates status The value function under ;
[0071] ;
[0072] in, represents the logit value, represents the transposed weight vector, Indicates in status Next action The eigenvector of
[0073] ;
[0074] in, represents the inference path index, represents the reasoning path, represents the score of the reasoning path, Represents the reasoning path All Perform the summation.
[0075] Embodiment 7, this embodiment is based on embodiment 6. In this embodiment, the process of generating the optimized nutrition assessment result by the optimization assessment module specifically includes the following steps:
[0076] Step B1: Evaluate the reward difference of the initial reasoning path by optimizing the loss function through the marginal reward. The formula used is as follows:
[0077] ;
[0078] in, represents the dynamic value marginal loss function, represents the expected value, and represents a path identifier; and Denote paths respectively; Indicates the path After the current state, the next state inferred is, Indicates the path After the current state, the next state is inferred; represents the reference strategy distribution, represents the hyperparameter, represents the reward function; Indicates the path In Status The optimal value of Indicates the path In Status The optimal value of Represents the logarithm of the result after the Sigmoid function;
[0079] Step B2: Optimize the initial reasoning path according to the reward difference, generate the optimal reasoning path, optimize the Transformer-RL model according to the optimal reasoning path, and generate the optimized nutritional evaluation result.
[0080] The present invention and its embodiments are described above, which is not restrictive. What is shown in the accompanying drawings is only one of the embodiments of the present invention, and the actual structure is not limited to this. In short, if ordinary technicians in this field are inspired by it and do not deviate from the purpose of the invention, they can creatively design structural methods and embodiments similar to the technical solution, which should all fall within the scope of protection of the present invention.
Claims
1. A post-operative dietary intake and nutritional assessment system for weight loss surgery based on a neural network, comprising a data preprocessing module, wherein the data preprocessing module generates refined health data; characterized in that: The system also includes a nutrition assessment module and an optimization assessment module; The nutrition assessment module: establishes a Transformer model, optimizes the Transformer model by combining channel separation, fragment extraction, position embedding, context embedding and decision tree path optimization strategy, constructs a Transformer-RL model, processes and refines health data through the Transformer-RL model, and generates nutrition assessment results; The optimization evaluation module combines value optimization, contrastive learning, Bellman optimality, logarithmic loss and reward normalization to construct a marginal reward optimization loss function, optimizes the Transformer-RL model through the marginal reward optimization loss function, and generates an optimized nutritional evaluation result.
2. According to claim 1, a neural network-based diet intake and nutrition assessment system for post-bariatric surgery, characterized in that: The Transformer-RL model consists of an encoder layer and a linear layer.
3. The neural network-based diet intake and nutrition assessment system for post-bariatric surgery according to claim 2, characterized in that: The process of generating the nutrition assessment result by the nutrition assessment module specifically includes the following steps: Step S1: performing channel separation on the refined health data to generate separated health data; Step S2: Divide the separated health data into time series segments to generate a set of health data segments; Step S3: adding position codes to the health data segment set, maintaining time order and time correlation, and generating an embedded information health data segment set; Step S4: Mapping the embedded information health data segment set into health data feature representation through linear projection; Step S5: Processing the health data feature representation through the encoder layer to generate encoder feature data; Step S6: Processing encoder feature data through a decision tree path optimization strategy to generate an initial reasoning path; Step S7: Flatten the initial reasoning path and generate the nutritional assessment result through a linear layer.
4. The neural network-based diet intake and nutrition assessment system for post-bariatric surgery according to claim 3, characterized in that: Step S5 specifically includes the following steps: Step S51: introducing a context embedding mechanism and a multi-head attention mechanism, dynamically adjusting the multi-head attention mechanism through the context embedding mechanism, constructing a context-multi-head attention mechanism, and focusing on health data feature representation in parallel through the context-multi-head attention mechanism to generate attention mechanism feature data; Step S52: Perform additive normalization and feedforward operations on the attention mechanism feature data to generate encoder feature data.
5. The neural network-based diet intake and nutrition assessment system for post-bariatric surgery according to claim 3, characterized in that: Step S6 specifically includes the following steps: Step S61: Convert the encoder feature data into a logarithmic probability distribution, and construct a candidate path set according to the logarithmic probability distribution, where the candidate path set is divided into an unterminated candidate path and a terminated candidate path; Step S62: performing an expansion operation on the unterminated candidate paths to generate an expanded reasoning path set; Step S63: traverse the extended reasoning path set, perform reasoning, improve the candidate path set, and generate a complete reasoning path set, where the complete reasoning path set includes multiple reasoning paths; Step S64: For each reasoning path in the complete reasoning path set, the Bellman error and the logit value are used to score, the potential of each reasoning path is evaluated, and the current optimal reasoning path is selected as the initial reasoning path.
Citation Information
Patent Citations
Explanatable recommendation method based on reinforcement learning and path reasoning
CN117033793A
Weight reduction postoperative management method and system based on artificial intelligence
CN117809811A
Nutrition assessment method and system after tonsil enucleation
CN118173229A
Quality safety optimization method and system based on multi-modal vertical large model technology
CN119130268A
Personalized nutrition intake recommendation method and device, equipment and storage medium
CN119400360A