Exercise prescription generation method and device, equipment and storage medium

By acquiring user input information and utilizing an external knowledge base and a trained retrieval and generation model to generate personalized exercise prescriptions, the problem of professionalism and efficiency in exercise guidance for patients with chronic diseases is solved, and rapid and professional exercise prescription generation is achieved.

CN121439084APending Publication Date: 2026-01-30PEKING UNIVERSITY SHENZHEN HOSPITAL
View PDF 0 Cites 1 Cited by

Patent Information

Application Number
CN202511550771.2
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-10-28
Publication Date
2026-01-30

AI Technical Summary

Technical Problem

Patients with chronic diseases have an urgent need for guidance on scientific exercise therapy. Traditional medical consultations are time-consuming, and the professionalism of general artificial intelligence model interaction is insufficient.

Method used

By acquiring the user's target input information, a knowledge base is used for retrieval, and a trained retrieval generation model is used to output personalized exercise prescriptions. The knowledge base is periodically updated to maintain its professionalism, and the training model is iteratively trained using a labeled fine-tuning dataset to improve its professionalism and efficiency.

Benefits of technology

The generated exercise prescriptions are highly professional, shorten the generation time, improve the accuracy of retrieval and personalization, and enhance the user's rehabilitation effect.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN121439084A_ABST
    Figure CN121439084A_ABST
Patent Text Reader

Abstract

The invention relates to an exercise prescription generation method and device, equipment and a storage medium, and the method comprises the steps: obtaining target input information of a user, and achieving the standardization of the input information; on the basis of the target input information, retrieval is performed in the plug-in knowledge base to obtain the retrieval result matched with the target input information, so that the retrieval result is professional, and the retrieval accuracy is improved; the target input information and the retrieval result are input into the trained retrieval generation model, the exercise prescription is output, the retrieval generation model is iteratively trained according to the marked fine adjustment data set, compared with traditional medical consultation, the exercise prescription is output through the trained retrieval generation model, the generation time of the exercise prescription is shortened, and the user experience is improved. Compared with general artificial intelligence model interaction, the exercise prescription generated by the method is combined with the retrieval result of the plug-in knowledge base, and the method is more professional.
Need to check novelty before this filing date? Find Prior Art

Description

TECHNICAL FIELD

[0001] The present disclosure relates to the technical field of computer, and particularly relates to a generation method and device of exercise prescription, equipment and storage medium. BACKGROUND

[0002] At present, the scientific exercise therapy guidance demand of chronic disease patients is urgent, and the related guidance is mostly dependent on traditional medical consultation or general artificial intelligence model. The traditional medical consultation helps disease management and rehabilitation.

[0003] Generally, the traditional medical consultation consumes a long time, and the professional of the interaction of the general artificial intelligence model is insufficient.

[0004] Therefore, a generation method of exercise prescription is needed to solve the above problems. SUMMARY

[0005] In order to solve the above technical problems or at least partially solve the above technical problems, the present disclosure provides a generation method, device, equipment and storage medium of exercise prescription, so that the generated exercise prescription not only has professionalism, but also shortens the generation time of the exercise prescription.

[0006] In a first aspect, the embodiments of the present disclosure provide a generation method of exercise prescription, applied to a user's exercise rehabilitation scene, comprising: obtaining target input information of a user; based on the target input information, searching in an external knowledge base to obtain a search result matched with the target input information; inputting the target input information and the search result into a trained search generation model to output an exercise prescription, wherein the search generation model is iteratively trained according to a labeled fine-tuning data set.

[0007] Optionally, the obtaining target input information of a user comprises: obtaining original input information of a user; transforming the original input information to obtain input information in a preset format; preprocessing the input information in the preset format to obtain target input information of a user.

[0008] Optionally, before the searching in the external knowledge base based on the target input information to obtain the search result matched with the target input information, the method further comprises: periodically updating the external knowledge base.

[0009] Optionally, after the inputting the target input information and the search result into the trained search generation model to output the exercise prescription, the method further comprises: Based on the exercise prescription and the basic information of the user, logical reasoning is performed by an inference engine to generate a personalized exercise prescription.

[0010] Optionally, after inputting the target input information and the search result into the trained search generation model to output the exercise prescription, the method further comprises: Collecting feedback from the user; Based on the feedback, the trained search generation model is optimized.

[0011] Optionally, after inputting the target input information and the search result into the trained search generation model to output the exercise prescription, the method further comprises: Displaying the exercise prescription on a terminal interface, the input method of the terminal including text input and voice input; Judging the scenario mode of the terminal; Based on the scenario mode of the terminal being a ringing mode, the exercise prescription is voice broadcasted.

[0012] In a second aspect, the embodiments of the present disclosure provide a training method of a search generation model, comprising: Obtaining an initial training data set; Labeling the initial training data set to form a labeled fine-tuning data set; Dividing the fine-tuning data set into a training set and a validation set, training an initial search generation model using the training set to obtain a search generation model; Evaluating the search generation model through the validation set to obtain evaluation indicators; Based on the evaluation indicators reaching a preset threshold, obtaining the trained search generation model as described in the first aspect.

[0013] In a third aspect, the embodiments of the present disclosure provide a generation device of an exercise prescription, applied to a user's exercise rehabilitation scenario, comprising: A first obtaining module for obtaining target input information of a user; A search module for searching in an external knowledge base based on the target input information to obtain search results matching the target input information; An input-output module for inputting the target input information and the search results into a trained search generation model to output an exercise prescription, the search generation model being iteratively trained according to a labeled fine-tuning data set.

[0014] In a fourth aspect, the embodiments of the present disclosure provide a training device of a search generation model, comprising: A second obtaining module for obtaining an initial training data set; The labeling module is configured to label the initial training data set to form a labeled fine-tuning data set. The training module is configured to divide the fine-tuning data set into a training set and a validation set, train an initial retrieval generation model using the training set, and obtain a retrieval generation model. The evaluation module is configured to evaluate the retrieval generation model through the validation set and obtain an evaluation index. The obtaining module is configured to obtain the trained retrieval generation model according to the first aspect when the evaluation index reaches a preset threshold.

[0015] In a fifth aspect, the embodiments of the present disclosure provide an electronic device, comprising: a memory; a processor; and a computer program; The computer program is stored in the memory and configured to be executed by the processor to implement the method according to the first aspect or the second aspect.

[0016] In a sixth aspect, the embodiments of the present disclosure provide a computer-readable storage medium having a computer program stored thereon, wherein the computer program is executed by a processor to implement the method according to the first aspect or the second aspect.

[0017] In a seventh aspect, the embodiments of the present disclosure further provide a computer program product comprising a computer program or instructions, which, when executed by a processor, implement the method according to the first aspect or the second aspect.

[0018] The method, device, equipment and storage medium for generating a motion prescription provided by the embodiments of the present disclosure achieve input information standardization by obtaining target input information of a user; based on the target input information, retrieval is performed in an external knowledge base to obtain a retrieval result matched with the target input information, so that the retrieval result is professional and the retrieval accuracy is improved; the target input information and the retrieval result are input into a trained retrieval generation model to output a motion prescription, the trained retrieval generation model is iteratively trained based on a labeled fine-tuning data set, compared with traditional medical consultation, the present disclosure outputs a motion prescription through the trained retrieval generation model, which shortens the generation time of the motion prescription, and compared with general artificial intelligence model interaction, the motion prescription generated by the present disclosure combines the retrieval result of the external knowledge base and is more professional. BRIEF DESCRIPTION OF DRAWINGS

[0019] The accompanying drawings, which are incorporated into and form part of the specification, illustrate embodiments consistent with the present disclosure and, together with the specification, serve to explain the principles of the present disclosure.

[0020] In order to more clearly illustrate the technical solutions in the embodiments of the present disclosure or the prior art, the following will briefly introduce the drawings needed to be used in the embodiments or prior art description. Obviously, for those skilled in the art, other drawings can also be obtained based on these drawings without creative labor.

[0021] Figure 1 A flow chart of a method for generating an exercise prescription provided by an embodiment of the present disclosure is shown in FIG. 3A. Figure 2 An example diagram of a search result of a chronic disease exercise therapy knowledge base provided by an embodiment of the present disclosure is shown in FIG. 3B. FIG. 3(A) is a schematic diagram of a terminal interface provided by an embodiment of the present disclosure. FIG. 3(B) is a schematic diagram of a terminal interface provided by an embodiment of the present disclosure. FIG. 3(C) is a schematic diagram of a terminal interface provided by an embodiment of the present disclosure. Figure 4 A flow chart of a method for generating an exercise prescription provided by another embodiment of the present disclosure is shown in FIG. 4. Figure 5 A flow chart of a training method for searching a generation model provided by an embodiment of the present disclosure is shown in FIG. 5. Figure 6 A structural schematic diagram of a device for generating an exercise prescription provided by an embodiment of the present disclosure is shown in FIG. 6. Figure 7 A structural schematic diagram of a training device for searching a generation model provided by an embodiment of the present disclosure is shown in FIG. 7. Figure 8 A structural schematic diagram of an electronic device provided by an embodiment of the present disclosure is shown in FIG. 8. Figure 9 A structural schematic diagram of an electronic device provided by an embodiment of the present disclosure is shown in FIG. 8. DETAILED DESCRIPTION

[0022] In order to more clearly illustrate the technical solutions in the embodiments of the present disclosure or the prior art, the following will briefly introduce the drawings needed to be used in the embodiments or prior art description. Obviously, for those skilled in the art, other drawings can also be obtained based on these drawings without creative labor.

[0023] It should be understood that the steps described in the method embodiments of this disclosure may be performed in different orders and / or in parallel. Furthermore, the method embodiments may include additional steps and / or omit the steps shown. The scope of this disclosure is not limited in this respect.

[0024] The term "comprising" and its variations as used herein are open-ended inclusions, meaning "including but not limited to". The term "based on" means "at least partially based on". The term "one embodiment" means "at least one embodiment"; the term "another embodiment" means "at least one additional embodiment"; the term "some embodiments" means "at least some embodiments". Definitions of other terms will be given in the description below.

[0025] It should be noted that the concepts of "first" and "second" mentioned in this disclosure are used only to distinguish different devices, modules or units, and are not used to limit the order of functions performed by these devices, modules or units or their interdependencies.

[0026] It should be noted that the terms "a" and "a plurality of" used in this disclosure are illustrative rather than restrictive, and those skilled in the art should understand that, unless otherwise expressly indicated in the context, they should be understood as "one or more".

[0027] The names of messages or information exchanged between multiple devices in the embodiments of this disclosure are for illustrative purposes only and are not intended to limit the scope of such messages or information.

[0028] With the continuous development of artificial intelligence technology, general artificial intelligence models have made significant progress in the field of natural language processing. Currently, patients with chronic diseases have an urgent need for guidance on scientific exercise therapy, and such guidance largely relies on traditional medical consultation or general artificial intelligence models, with traditional medical consultation assisting in disease management and rehabilitation.

[0029] Traditional medical consultations are typically time-consuming; general artificial intelligence models lack sufficient professionalism in their interaction.

[0030] To address this issue, this disclosure provides a method for generating exercise prescriptions, which will be described below with reference to specific embodiments.

[0031] Figure 1A flowchart of a method for generating an exercise prescription is provided in the embodiments of the present disclosure. The method can be performed by an exercise prescription generation apparatus, which can be implemented in software and / or hardware, and can be configured in an electronic device, such as a server or a terminal, where the terminal specifically includes a mobile phone, a community rehabilitation terminal, a computer, a tablet computer, and the like. In addition, the method can be applied to the application scenario of generating an exercise prescription. It can be understood that the method for generating an exercise prescription provided in the embodiments of the present disclosure can also be applied in other scenarios.

[0032] Figure 1 A flowchart of a method for generating an exercise prescription is provided in the embodiments of the present disclosure. The method can be performed by an exercise prescription generation apparatus, which can be implemented in software and / or hardware, and can be configured in an electronic device, such as a server or a terminal, where the terminal specifically includes a mobile phone, a community rehabilitation terminal, a computer, a tablet computer, and the like. In addition, the method can be applied to the application scenario of generating an exercise prescription. It can be understood that the method for generating an exercise prescription provided in the embodiments of the present disclosure can also be applied in other scenarios. Figure 1 As shown in the method, the specific steps include the following: S101, obtaining target input information of a user.

[0033] The terminal obtains the target input information of the user, which refers to a set of core information that can accurately reflect the individual situation and rehabilitation needs of the user after processing.

[0034] Optionally, obtaining the target input information of the user includes: obtaining original input information of the user; transforming the original input information to obtain input information in a preset format; and preprocessing the input information in the preset format to obtain the target input information of the user.

[0035] Specifically, the terminal obtains original input information of a user, the original input information refers to initial information directly submitted by the user through various interaction modes without any processing, including input voice and input text of the user, information extracted by a third-party system, and objective data automatically collected and synchronized by an Internet of Things (IoT) device. For example, the input voice and the input text can be a user's exercise demand, disease type, symptom description, and body condition. The IoT device can be a heart rate bracelet or a sports watch. The objective data can be a physiological index and exercise records. The terminal converts the original input information of the user, that is, uniformly maps the original input information of different types and different formats into input information in a preset format through format conversion and semantic analysis, wherein the preset format refers to a data format defined in advance for standardizing information storage and transmission. For example, the preset format includes fixed field classification, field naming rules, and data types. The terminal pre-processes the input information in the preset format, that is, performs optimization operations such as cleaning, completion, verification, and association on the input information in the preset format to obtain target input information of the user, so as to improve the accuracy, integrity, and logic of the target input information.

[0036] In S102, based on the target input information, a search is performed in an external knowledge base to obtain a search result matched with the target input information.

[0037] The external knowledge base refers to a database that stores professional knowledge in the field of exercise rehabilitation independently of the retrieval generation model.

[0038] The terminal performs a search in the external knowledge base through an external knowledge base interface according to the target input information. The external knowledge base interface supports efficient search and query operations. After the search, a search result matched with the target input information is obtained. The search result refers to professional knowledge content filtered from the external knowledge base, which has a similarity to the target input information in multiple dimensions such as disease type, body state, exercise scene, and rehabilitation demand, and reaches a preset similarity threshold. For example, the preset similarity threshold can be 95%, or other numerical values, which can be set according to actual conditions.

[0039] Optionally, the external knowledge base includes a chronic disease exercise therapy knowledge base and other related field knowledge bases.

[0040] Figure 2 An example of a search result of the chronic disease exercise therapy knowledge base provided by the embodiments of the present disclosure is shown in the figure, wherein the question is part of the original input information of the user, and the answer is the search result matched with the target input information.

[0041] S103, input the target input information and the search result into the trained search generation model to output the exercise prescription, wherein the search generation model is iteratively trained according to the labeled fine-tuning data set.

[0042] The exercise prescription refers to a standardized exercise guidance scheme containing core elements such as exercise type, exercise duration, exercise intensity, exercise frequency, and matters needing attention.

[0043] The terminal inputs the target input information and the search result into the trained search generation model, which is iteratively trained according to the labeled fine-tuning data set. The trained search generation model combines the user's personal information and professional knowledge to generate a professional and personalized exercise prescription. It can be understood that the trained search generation model will automatically avoid the risk points mentioned in the search result to ensure the safety of the exercise prescription.

[0044] The embodiments of the present disclosure achieve input information standardization by obtaining the target input information of the user. Based on the target input information, the search result matched with the target input information is obtained by searching in the external knowledge base, so that the search result has professionalism and the search accuracy is improved. The target input information and the search result are input into the trained search generation model to output the exercise prescription. The search generation model is iteratively trained according to the labeled fine-tuning data set. Compared with traditional medical consultation, the present disclosure outputs the exercise prescription through the trained search generation model, which shortens the generation time of the exercise prescription. Compared with the general artificial intelligence model interaction, the exercise prescription generated by the present disclosure combines the search result of the external knowledge base and is more professional.

[0045] On the basis of the above-mentioned embodiments, before searching in the external knowledge base based on the target input information to obtain the search result matched with the target input information, the method further comprises: periodically updating the external knowledge base.

[0046] The terminal performs regular update of the external knowledge base at a preset fixed time interval, cooperates with medical experts, and introduces a medical expert evaluation link in the update process to reflect the latest research results and clinical practice results, and at the same time contains non-fixed time emergency update triggered based on special events (such as major guidelines release, breakthrough research), forming a double-mode update mechanism of "regular + emergency". The fixed time can be one week, two weeks, one month, one quarter, etc., which can be set according to actual conditions, and the present embodiment is not limited.

[0047] In some embodiments, after the terminal periodically updates the external knowledge base, the updating state of the external knowledge base is checked. When the updating state of the external knowledge base is the latest state, the external knowledge base in the latest state is used for retrieval to obtain a retrieval result matched with the target input information. When the updating state of the external knowledge base is not the latest state, the external knowledge base is updated to obtain the external knowledge base in the latest state, and the external knowledge base in the latest state is used for retrieval to obtain a retrieval result matched with the target input information.

[0048] The embodiments of the present disclosure perform regular updating of the external knowledge base at fixed time intervals, so that the professional knowledge is iterated periodically, the scientific conclusions and literature materials of the external knowledge base are ensured to be the latest, the timeliness of the content of the external knowledge base is ensured, the professional and reliability of the content of the external knowledge base are strengthened, the dynamic adaptation capability of the external knowledge base is improved, and the out-of-date prescription suggestion caused by updating lag is avoided.

[0049] In some embodiments, after the target input information and the retrieval result are input into the trained retrieval generation model to output a movement prescription, the method further includes: based on the movement prescription and the basic information of the user, logical reasoning is performed by an inference engine to generate a personalized movement prescription.

[0050] The basic information of the user at least includes one of the following: user height, user weight, user age, user movement scene, user disease type, user movement history, and user movement target.

[0051] The terminal starts the inference engine, performs logical reasoning according to the movement prescription and the basic information of the user, analyzes the movement prescription, and adaptively adjusts to generate a personalized movement prescription. It can be understood that the personalized movement prescriptions obtained by different users are different.

[0052] The embodiments of the present disclosure generate a personalized movement prescription by performing logical reasoning by the inference engine according to the movement prescription and the basic information of the user, so that the movement prescription is more suitable for the user, and the rehabilitation effect and safety of the movement prescription are strengthened.

[0053] In some embodiments, after the target input information and the retrieval result are input into the trained retrieval generation model to output a movement prescription, the method further includes: collecting feedback opinions of the user; and based on the feedback opinions, the trained retrieval generation model is optimized.

[0054] The terminal collects feedback of the user, the feedback including instant feedback of exercise, deep text feedback, and IoT device assisted feedback. The feedback is screened and analyzed, invalid feedback is removed, valid feedback that matches the exercise prescription, action safety, and individual ability is retained, the core optimization direction of the retrieval generation model is determined after the training is completed, the valid feedback after the analysis is converted into user fine-tuning data, and the retrieval generation model after the training is completed is optimized according to the user fine-tuning data. The retrieval generation model after the training is completed is optimized according to the user feedback, so as to ensure that the exercise prescription that adapts to the user's condition is provided for the user, the rehabilitation effect of the user is improved, and the long-term competitiveness of the retrieval generation model is enhanced.

[0055] In some embodiments, after the target input information and the retrieval result are input into the trained retrieval generation model to output the exercise prescription, the method further includes: displaying the exercise prescription on a terminal interface, the input mode of the terminal including text input and voice input; determining the scenario mode of the terminal; and voice broadcasting the exercise prescription based on the scenario mode of the terminal being a ringing mode.

[0056] The terminal displays the exercise prescription on a terminal interface, the input mode of the terminal including text input and voice input, wherein the text input refers to a way of inputting text information by a terminal keyboard, a handwriting board, etc., and the voice input refers to a way of inputting voice information through a terminal microphone and converting the voice information into text through system recognition, the two input modes constituting a multimodal interaction portal together; determining the scenario mode of the terminal, different scenario modes corresponding to different user needs, the scenario mode of the terminal including a silent mode, a vibration mode, a ringing mode, etc., which are state modes preset by the terminal system for adapting to different use environments; and voice broadcasting the exercise prescription based on the scenario mode of the terminal being a ringing mode, and not starting voice broadcasting or asking the user if the scenario mode is a silent mode or a vibration mode, thereby providing support for the flexibility of voice broadcasting and ensuring timely broadcasting without disturbing others. The scenario-based adaptation of voice broadcasting is realized.

[0057] FIGS. 3(A), 3(B), and 3(C) are schematic diagrams of a terminal interface provided by an embodiment of the present disclosure, as shown in FIG. 3(A), a terminal interface is opened, and the terminal interface displays: an introduction 301, a function 302, an explanation 303, and an immediate experience 305; clicking the immediate experience 305 can obtain the terminal interface shown in FIG. 3(B), and the terminal interface shown in FIG. 3(B) displays: a greeting 305, a prompt 306, a text input 307, and a voice input 308; clicking the text input 307, the terminal interface displays a keyboard for inputting text; and clicking the voice input 308 can obtain the terminal interface shown in FIG. 3(C), and the terminal interface shown in FIG. 3(C) displays: a cancel 309 and the voice input 308, and the terminal can recognize the voice of the user by long pressing the voice input 308.

[0058] Exemplarily, the brief introduction 301 can be "Hello, I am the AI health assistant"; the function 302 can be "Your personal sports health consultant, providing you with 24-hour consultation services, ensuring that you can obtain professional sports guidance at any time"; the description 303 can be "Instant sports health assistant, ready at any time", "24-hour sports health consultant, personalized health management". The greeting 305 can be "Hello, I am the AI health assistant, nice to meet you! I am your sports health consultant, providing you with 24-hour consultation services, ensuring that you can obtain professional sports guidance at any time. Do you have any questions you want to ask me? Send it to me and try it~"; the prompt 306 can be "What are the training programs for cervical spondylosis?", "I have a sore neck, how do I exercise?", etc.

[0059] The embodiment of the present disclosure displays the exercise prescription on the terminal interface; judges the scene mode of the terminal; and based on the scene mode of the terminal, the exercise prescription is broadcasted by voice in the ringing mode, which adapts to different use scenarios, reduces the use threshold, and improves the user experience.

[0060] Figure 4 The flowchart of the exercise prescription generation method provided by another embodiment of the present disclosure is shown in Figure 4 The method includes the following steps: S401, obtaining original input information of a user.

[0061] The terminal obtains the original input information of the user. The original input information refers to the initial information directly submitted by the user through various interaction methods without any processing, including the input voice and input text of the user, the information extracted by a third-party system, and the objective data automatically collected and synchronized by an Internet of Things (IoT) device. Exemplarily, the input voice and input text can be the exercise needs, disease types, symptom descriptions, and physical conditions of the user; the IoT device can be a heart rate bracelet, a sports watch, etc.; and the objective data can be physiological indicators and exercise records, etc.

[0062] S402, transforming the original input information to obtain input information in a preset format.

[0063] The terminal transforms the original input information of the user, that is, the original input information of different types and different formats is uniformly mapped to input information in a preset format through format conversion, semantic analysis, etc., wherein the preset format refers to a data format defined in advance for standardizing information storage and transmission, and exemplarily, the preset format includes fixed field classification, field naming rules, and data types.

[0064] S403, preprocessing the input information in the preset format to obtain target input information of the user.

[0065] The terminal pre-processes the input information in the preset format, and the pre-processing refers to optimization operations such as cleaning, complementing, checking, and associating the input information in the preset format, to obtain target input information of the user, so as to improve the accuracy, integrity, and logic of the target input information.

[0066] S404, periodically update the external knowledge base.

[0067] The terminal performs regular update of the external knowledge base according to a preset fixed time interval, cooperates with medical experts, and introduces a medical expert evaluation link in the update process, to reflect the latest research results and clinical practice results, and at the same time, includes non-fixed time emergency update triggered based on special events (such as major guidelines release and breakthrough research), to form a double-mode update mechanism of “regular + emergency”. The fixed time can be one week, two weeks, one month, one quarter, etc., and can be set according to actual conditions, which is not limited in the embodiment.

[0068] In some embodiments, after the terminal periodically updates the external knowledge base, the update state of the external knowledge base is checked, when the update state of the external knowledge base is the latest state, the external knowledge base based on the latest state is searched to obtain a search result matched with the target input information; when the update state of the external knowledge base is not the latest state, the external knowledge base is updated to obtain the external knowledge base in the latest state, and the external knowledge base in the latest state is searched to obtain a search result matched with the target input information.

[0069] S405, based on the target input information, search in the external knowledge base to obtain a search result matched with the target input information.

[0070] Specifically, the implementation process and principle of S405 and S102 are the same, which will not be repeated here.

[0071] S406, input the target input information and the search result into the trained search generation model, and output a motion prescription, the search generation model is iteratively trained according to the labeled fine-tuning data set.

[0072] Specifically, the implementation process and principle of S406 and S103 are the same, which will not be repeated here.

[0073] S407, based on the motion prescription and the basic information of the user, logical reasoning is performed through an inference engine to generate a personalized motion prescription.

[0074] The basic information of the user at least includes one of the following: user height, user weight, user age, user motion scene, user disease type, user motion history, and user motion target.

[0075] The terminal starts the reasoning engine, performs logical reasoning according to the above exercise prescription and the basic information of the user, analyzes the exercise prescription, and adaptively adjusts to generate a personalized exercise prescription. It can be understood that different users will obtain different personalized exercise prescriptions.

[0076] S408, collect the feedback of the user, and optimize the trained retrieval generation model based on the feedback.

[0077] The terminal collects the feedback of the user, which includes exercise immediate feedback, deep text feedback, and IoT device assisted feedback. The feedback is screened and analyzed, invalid feedback is removed, valid feedback that matches the exercise prescription, action safety, and individual ability is retained, the core optimization direction of the trained retrieval generation model is determined, the valid feedback after analysis is converted into user fine-tuning data, and the trained retrieval generation model is optimized according to the user fine-tuning data. According to the user feedback, the trained retrieval generation model is optimized to ensure that the user is provided with an exercise prescription that adapts to their own situation, improving the user's rehabilitation effect and enhancing the long-term competitiveness of the retrieval generation model.

[0078] S409, display the exercise prescription on the terminal interface, and the input mode of the terminal includes text input and voice input.

[0079] The terminal displays the exercise prescription on the terminal interface, and the input mode of the terminal includes text input and voice input, wherein the text input refers to a way of inputting text information by the terminal keyboard, handwriting board, etc.; the voice input refers to a way of inputting voice information through the terminal microphone and converting it into text through system recognition, and the two input modes together constitute a multi-modal interaction portal.

[0080] S410, judge the scenario mode of the terminal, and voice broadcast the exercise prescription based on the scenario mode of the terminal being in a ringing mode.

[0081] Judge the scenario mode of the terminal, different scenario modes correspond to different user needs, and the scenario mode of the terminal includes a silent mode, a vibration mode, a ringing mode, and other state modes preset by the terminal system for adapting to different use environments; voice broadcast the exercise prescription based on the scenario mode of the terminal being in a ringing mode, if it is in a silent mode or a vibration mode, do not start voice broadcast or ask the user, provide support for the flexibility of voice broadcast, and ensure timely broadcast without disturbing the public. Realize the scenario adaptation of voice broadcast.

[0082] The embodiment of the present disclosure realizes input information standardization by obtaining target input information of a user; based on the target input information, retrieval is performed in an external knowledge base to obtain a retrieval result matched with the target input information, so that the retrieval result has professionalism and the retrieval accuracy is improved; the target input information and the retrieval result are input into a trained retrieval generation model, and a motion prescription is output. The retrieval generation model is iteratively trained according to a labeled fine-tuning data set. Compared with traditional medical consultation, the present disclosure outputs a motion prescription through the trained retrieval generation model, thereby shortening the generation time of the motion prescription. Compared with general artificial intelligence model interaction, the motion prescription generated by the present disclosure combines the retrieval result of the external knowledge base and is more professional.

[0083] Figure 5 A training method flowchart of a retrieval generation model provided by the embodiment of the present disclosure is shown in FIG. 5. Figure 5 The specific steps of the method include the following: S501, obtaining an initial training data set.

[0084] The terminal collects professional data in the field of chronic disease exercise therapy, including clinical practice cases, authoritative medical guideline documents, and academic research results, cleans the collected data to remove duplicate data and error data, and obtains an initial training data set. It can be understood that the initial training data set refers to a raw data set that has not been labeled.

[0085] S502, labeling the initial training data set to form a labeled fine-tuning data set.

[0086] The terminal labels the initial training data set. The labeling content includes input and output. The input can be user conditions and exercise needs, and the output can be an adaptive scheme and a scientific basis. An explicit correspondence between the input and the output is established, constraint rules are supplemented, and a labeled fine-tuning data set is formed.

[0087] S503, dividing the fine-tuning data set into a training set and a validation set, using the training set to train an initial retrieval generation model to obtain a retrieval generation model.

[0088] An initial retrieval generation model is built, associated with an external knowledge base, and a loss function for training the retrieval generation model is set. The loss function includes a generation content accuracy loss and a professional knowledge matching degree loss.

[0089] The terminal divides the fine-tuning data set into a training set and a validation set according to a preset ratio. The data set division needs to follow the random stratification principle. The initial retrieval generation model is trained using the training set. When the loss function converges to a preset threshold, the retrieval generation model is obtained.

[0090] S504, evaluate the retrieval generation model by the verification set to obtain an evaluation index.

[0091] The terminal evaluates the retrieval generation model by the verification set, and obtains evaluation indexes in multiple dimensions such as professionalism, adaptability, and integrity.

[0092] S505, based on the evaluation index reaching a preset threshold, obtaining the trained retrieval generation model of claim 1.

[0093] When the evaluation index reaches the preset threshold, the trained retrieval generation model of claim 1 is obtained. The preset threshold refers to the safety and professionalism requirements of the sports rehabilitation scene. For example, the preset threshold can be that the professional accuracy is greater than or equal to 90%, the adaptability is greater than or equal to 95%, and the integrity is greater than or equal to 99%. It can be understood that the preset threshold can also be set to other values that meet the requirements according to the actual situation. The preset threshold provided in the embodiment is only an example and is not limited by the embodiment.

[0094] The embodiment of the disclosure obtains an initial training data set, labels the initial training data set to form a labeled fine-tuning data set, divides the fine-tuning data set into a training set and a verification set, uses the training set to train an initial retrieval generation model to obtain a retrieval generation model, evaluates the retrieval generation model by the verification set to obtain an evaluation index, and obtains a trained retrieval generation model based on the evaluation index reaching a preset threshold. The trained retrieval generation model has the retrieval and generation capabilities of a general model, and also has professional judgment and personalized adaptation capabilities in the field, solving the defect of insufficient professionalism of the interaction of the artificial intelligence model in the prior art.

[0095] Figure 6 The structure diagram of the exercise prescription generation device provided by the embodiment of the disclosure is provided. The exercise prescription generation device can be a terminal as described in the above embodiment, or the exercise prescription generation device can be a component or assembly in the terminal. The exercise prescription generation device provided by the embodiment of the disclosure can perform the processing flow provided by the exercise prescription generation method embodiment, as shown in Figure 6 As shown in the figure, the exercise prescription generation device 60 includes a first acquisition module 61, a retrieval module 62, and an input / output module 63. The first acquisition module 61 is configured to acquire target input information of a user. The retrieval module 62 is configured to perform retrieval in an external knowledge base based on the target input information to obtain a retrieval result matched with the target input information. The input / output module 63 is configured to input the target input information and the retrieval result into a trained retrieval generation model, and output an exercise prescription. The retrieval generation model is iteratively trained according to the labeled fine-tuning data set.

[0096] Optionally, the first obtaining module 61 is further configured to obtain original input information of the user; transform the original input information to obtain input information in a preset format; and pre-process the input information in the preset format to obtain target input information of the user.

[0097] Optionally, the exercise prescription generation apparatus 60 further includes an updating module 64 configured to periodically update an external knowledge base before searching the external knowledge base based on the target input information to obtain a search result matched with the target input information.

[0098] Optionally, the exercise prescription generation apparatus 60 further includes a generation module 65 configured to input the target input information and the search result into a trained search generation model, output an exercise prescription, and then generate an individualized exercise prescription based on the exercise prescription and basic information of the user by logical reasoning through an inference engine.

[0099] Optionally, the exercise prescription generation apparatus 60 further includes an optimization module 66 configured to collect feedback opinions of the user after inputting the target input information and the search result into the trained search generation model and outputting the exercise prescription, and optimize the trained search generation model based on the feedback opinions.

[0100] Optionally, the exercise prescription generation apparatus 60 further includes a broadcast module 67 configured to display the exercise prescription on a terminal interface after inputting the target input information and the search result into the trained search generation model and outputting the exercise prescription, the input mode of the terminal includes text input and voice input; determine a scenario mode of the terminal; and voice broadcast the exercise prescription based on the scenario mode of the terminal being a ring mode.

[0101] Figure 6 The exercise prescription generation apparatus of the illustrated embodiment can be used to execute the technical solutions of the exercise prescription generation method embodiment described above, and has similar principles and technical effects, which will not be described here again.

[0102] Figure 7 A structural schematic diagram of the training apparatus of the search generation model provided by the embodiments of the present disclosure is shown. The training apparatus of the search generation model can be a terminal as described in the above embodiments, or the training apparatus of the search generation model can be a component or assembly in the terminal. The training apparatus of the search generation model provided by the embodiments of the present disclosure can execute the processing flow provided by the training method of the search generation model, as shown in Figure 7 As shown, the training apparatus 70 of the search generation model includes a second obtaining module 71, a labeling module 72, a training module 73, an evaluation module 74, and a obtaining module 75. The second obtaining module 71 is configured to obtain an initial training data set. The labeling module 72 is configured to label the initial training data set to form a labeled fine-tuning data set. The training module 73 is configured to divide the fine-tuning data set into a training set and a validation set, train an initial retrieval generation model using the training set, and obtain a retrieval generation model. The evaluation module 74 is configured to evaluate the retrieval generation model through the validation set and obtain an evaluation index. The obtaining module 75 is configured to obtain the trained retrieval generation model according to the above method based on the evaluation index reaching a preset threshold.

[0103] Figure 7 The training device of the retrieval generation model of the illustrated embodiment can be used to execute the technical solutions of the training method embodiment of the retrieval generation model described above, and the implementation principles and technical effects are similar, which will not be described here.

[0104] Figure 8 The structure schematic diagram of the electronic device provided by the embodiment of the present disclosure is shown. The electronic device can be a terminal as described in the above embodiment. The electronic device provided by the embodiment of the present disclosure can execute the processing flow provided by the generation method embodiment of the motion prescription, as shown in Figure 8 As shown, the electronic device 80 includes a memory 81, a processor 82, a computer program and a communication interface 83; wherein the computer program is stored in the memory 81 and is configured to be executed by the processor 82 to execute the motion prescription generation method as described above.

[0105] Figure 9 The structure schematic diagram of the electronic device provided by the embodiment of the present disclosure is shown. The electronic device can be a terminal as described in the above embodiment. The electronic device provided by the embodiment of the present disclosure can execute the processing flow provided by the training method embodiment of the retrieval generation model, as shown in Figure 9 As shown, the electronic device 90 includes a memory 91, a processor 92, a computer program and a communication interface 93; wherein the computer program is stored in the memory 91 and is configured to be executed by the processor 92 to execute the training method of the retrieval generation model as described above.

[0106] In addition, the embodiment of the present disclosure also provides a computer readable storage medium, which stores a computer program, and the computer program is executed by a processor to implement the motion prescription generation method or the training method of the retrieval generation model described in the above embodiment.

[0107] In addition, the disclosure also provides a computer program product, which comprises a computer program or instructions, and the computer program or instructions are executed by a processor to implement the motion prescription generation method or the training method of the retrieval generation model.

[0108] It should be noted that the computer readable medium of the disclosure described above can be a computer readable signal medium or a computer readable storage medium or any combination of the above two. The computer readable storage medium may, for example, but is not limited to, an electrical, magnetic, optical, electromagnetic, infrared, or semiconductor system, device or instrument, or any combination of the above. More specific examples of computer readable storage medium can include, but are not limited to, electrical connection with one or more conductive wires, portable computer disk, hard disk, random access memory (RAM), read only memory (ROM), erasable programmable read only memory (EPROM or flash memory), optical fiber, portable compact disk read only memory (CD-ROM), optical storage device, magnetic storage device, or any suitable combination of the above. In the disclosure, the computer readable storage medium can be any tangible medium containing or storing programs, which can be used or combined with instruction execution system, device or instrument. In the disclosure, the computer readable signal medium can include data signals propagating in the baseband or as part of a carrier wave, which carries computer readable programs. Such propagating data signals can take various forms, including but not limited to electromagnetic signals, optical signals or any suitable combination of the above. The computer readable signal medium can also be any computer readable medium other than computer readable storage medium, which can send, propagate or transmit programs for use by or in combination with instruction execution system, device or instrument. The program code contained in the computer readable medium can be transmitted by any suitable medium, including but not limited to electrical wires, optical cables, RF (radio frequency), etc., or any suitable combination of the above.

[0109] In some embodiments, the client, server can communicate using any currently known or future developed network protocol, such as HTTP (HyperText Transfer Protocol), and can be interconnected with digital data communication (for example, communication network) of any form or medium. Examples of communication network include local area network ("LAN"), wide area network ("WAN"), Internet network (for example, Internet), and end-to-end network (for example, ad hoc end-to-end network), as well as any currently known or future developed network.

[0110] The above computer readable medium can be contained in the above electronic device; or can exist separately without being assembled into the electronic device.

[0111] The computer readable medium described above carries one or more programs, which when executed by the electronic device, cause the electronic device to: obtain target input information of a user; based on the target input information, perform retrieval in an external knowledge base to obtain a retrieval result matched with the target input information; input the target input information and the retrieval result into a trained retrieval generation model to output an exercise prescription, the retrieval generation model being iteratively trained according to a labeled fine-tuning data set.

[0112] In addition, the electronic device can also perform other steps in the exercise prescription generation method described above.

[0113] Computer program code for carrying out operations of the present disclosure can be written in one or more programming languages or combinations of languages including object oriented programming languages such as Java, Smalltalk, C++ as well as conventional procedural programming languages such as the "C" programming language or similar programming languages. The program code can execute entirely on the user's computer, partly on the user's computer, as a stand-alone software package, partly on the user's computer and partly on a remote computer or entirely on the remote computer or server. In the latter scenario, the remote computer can be connected to the user's computer through any type of network, including a local area network (LAN) or a wide area network (WAN), or the connection can be made to an external computer (for example, through the Internet using an Internet Service Provider).

[0114] The flow diagrams and the block diagrams in the drawings are illustrations of possible architectures, functions, and operations for systems, methods, and computer program products according to various embodiments of the present disclosure. In this regard, each block in the flow diagrams and the block diagrams can represent a module, a segment, or a portion of code, which comprises one or more executable instructions for implementing the specified logical function(s). It should also be noted that in some alternative implementations, the functions noted in the blocks can occur out of the order noted in the figures. For example, two blocks shown in succession may, in fact, be executed substantially concurrently or the blocks may

[0115] The units described in the embodiments of the present disclosure can be implemented by software, or by hardware. In some cases, the name of the unit does not constitute a limitation on the unit itself.

[0116] The functions described above in the present disclosure can be performed at least in part by one or more hardware logic components. For example, and without limitation, illustrative types of hardware logic components that can be used include: Field-programmable Gate Arrays (FPGAs), Application-specific Integrated Circuits (ASICs), Application-specific Standard Products (ASSPs), System-on-a-chip systems (SOCs), Complex Programmable Logic Devices (CPLDs), etc.

[0117] In the context of the present disclosure, a machine-readable medium can be a tangible medium that contains or stores a program for use by or in connection with an instruction execution system, apparatus, or device. The machine-readable medium can be a machine-readable signal medium or a machine-readable storage medium. A machine-readable medium can include, but is not limited to, an electronic, magnetic, optical, electromagnetic, infrared, or semiconductor system, apparatus, or device, or any suitable combination of the foregoing. More specific examples of the machine-readable storage medium will include one or more lines of electrical connections, portable computer disks, hard disk drives, random access memory (RAM), read-only memory (ROM), erasable programmable read-only memory (EPROM or Flash memory), optical fibers, portable compact disc read-only memories (CD-ROMs), optical storage devices, magnetic storage devices, or any suitable combination of the foregoing.

[0118] The above description is merely that of the specific embodiments of the present disclosure, and thus is not intended to limit the present disclosure. Various modifications to these embodiments can be apparent to those skilled in the art, and the generic principles defined herein can be implemented in other embodiments without departing from the spirit or scope of the disclosure. Accordingly, the present disclosure is not to be limited to the embodiments described herein but is to be accorded the widest scope consistent with the principles and novel features disclosed herein.

Claims

1. A method for generating an exercise prescription, applied to a user's exercise rehabilitation scenario, characterized in that, The method comprises: obtaining target input information of a user; based on the target input information, searching in an external knowledge base to obtain a search result matched with the target input information; inputting the target input information and the search result into a trained search generation model to output an exercise prescription, the search generation model being iteratively trained according to a labeled fine-tuning data set.

2. The method of claim 1, wherein, The method comprises: obtaining target input information of a user; obtaining original input information of the user; transforming the original input information to obtain input information in a preset format; 3. The method of claim 1, wherein, preprocessing the input information in the preset format to obtain the target input information of the user. Before searching in the external knowledge base based on the target input information to obtain a search result matched with the target input information, the method further comprises:

4. The method of claim 1, wherein, periodically updating the external knowledge base. After inputting the target input information and the search result into the trained search generation model to output an exercise prescription, the method further comprises:

5. The method of claim 1, wherein, based on the exercise prescription and the basic information of the user, performing logical reasoning through an inference engine to generate a personalized exercise prescription. After inputting the target input information and the search result into the trained search generation model to output an exercise prescription, the method further comprises: collecting feedback from the user; 6. The method of claim 1, wherein, based on the feedback, optimizing the trained search generation model. After inputting the target input information and the search result into the trained search generation model to output an exercise prescription, the method further comprises: displaying the exercise prescription on a terminal interface, the input mode of the terminal including text input and voice input; determining the scenario mode of the terminal; 7. A method for training a retrieval generation model, characterized in that, based on the scenario mode of the terminal being a ring mode, voice broadcasting the exercise prescription. The method comprises: obtaining an initial training data set; labeling the initial training data set to form a labeled fine-tuning data set; dividing the fine-tuning data set into a training set and a validation set, using the training set to train an initial search generation model to obtain a search generation model; evaluating the search generation model through the validation set to obtain evaluation indicators; 8. An exercise prescription generation apparatus applied to a user's exercise rehabilitation scene, characterized in that, based on the evaluation indicators reaching a preset threshold, obtaining the trained search generation model of claim 1. The device comprises: a first obtaining module for obtaining target input information of a user; a search module for searching in an external knowledge base based on the target input information to obtain a search result matched with the target input information; 9. An electronic device, comprising: an input / output module for inputting the target input information and the search result into a trained search generation model to output an exercise prescription, the search generation model being iteratively trained according to a labeled fine-tuning data set. comprises: a memory; a processor; and a computer program; 10. A computer-readable storage medium having stored thereon a computer program, characterized in that, wherein the computer program is stored in the memory and configured to be executed by the processor to implement the method of any one of claims 1-7. The computer program is executed by the processor to implement the method of any one of claims 1-7.

Citation Information

Cited By

  • Exercise prescription generation method, device and system based on clinical data, medium and equipment

    CN121709143A