A method for generating prompts for assessing patients' post-traumatic stress symptoms

By generating personalized prompts, the problem of lack of objectivity and targeting of existing prompts is solved, and more accurate and objective communication and questionnaire evaluation are achieved, which improves the effectiveness of the assessment.

CN120413048BActive Publication Date: 2025-08-29THE NAVAL MEDICAL UNIV OF PLA
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202510902059.8
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2025-07-01
Publication Date
2025-08-29
Estimated Expiration
2045-07-01

AI Technical Summary

Technical Problem

The existing prompts lack objectivity and targeting in evaluating symptoms of post-traumatic stress, resulting in poor communication results and may even become a cause of the patient's disease.

Method used

Through a prompt generation method for evaluating patient post-traumatic stress symptoms, a prompt with high similarity to the patient's response is determined based on the cosine approximation, and a personalized communication or questionnaire prompt is generated.

Benefits of technology

It improves the accuracy and objectivity of communication and questionnaire, avoids excessively subjective communication from physicians, ensures the smooth progress of communication or questionnaire, and improves service quality.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120413048B_ABST
    Figure CN120413048B_ABST
Patent Text Reader

Abstract

The present invention relates to the technical field of prompt generation, and in particular to a method for generating prompts for assessing post-traumatic stress symptoms in patients. The method comprises: a first input unit for receiving conversation content and extracting the complainant's response and prompts; a first context unit for creating or updating a context based on input from the first input unit; a first matching unit for determining a test benchmark based on the complainant's response, prompts, and context; and a first prompt unit for determining prompts based on the test benchmark and context, wherein the word vectors or sentence vectors corresponding to valid prompts have a continuous proximity distribution, the valid prompts are inferred based on the complainant's response and prompts, and their proximity to the prompts is greater than a first threshold; the proximity is cosine proximity. This solves the problem of prompts being insufficiently objective, detailed, and targeted when communicating with PTSD patients or conducting questionnaire surveys.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the technical field of prompt generation, and in particular to a prompt generation method for evaluating post-traumatic stress symptoms of a patient. Background Art

[0002] Post-traumatic stress disorder (PTSD) is a mental health condition triggered by experiencing or witnessing a traumatic event. Symptoms include flashbacks, nightmares, severe anxiety, and uncontrollable recollections of the event. These symptoms can persist for months or even years, severely impacting daily life. Among the treatments for PTSD, psychotherapy is a commonly used adjunct, requiring frequent questionnaires or psychological consultations with patients. However, PTSD often causes patients to express themselves unclearly during questionnaires or consultations, and can even directly trigger a patient's illness if the physician is not careful. Therefore, it is particularly necessary to prepare appropriate prompts based on the actual situation of the physician or patient.

[0003] However, existing prompts are often independently developed by different physicians based on commonly used prompts, often imbued with their own emotions and lacking objectivity. Furthermore, the prompts are not sufficiently detailed and targeted to address different patient conditions. Therefore, this paper proposes a method for generating prompts to assess patients' post-traumatic stress symptoms. Summary of the Invention

[0004] To address the issues of insufficient objectivity, detailed categorization, and targetedness of prompts used in communication with or questionnaires about PTSD patients, the present invention provides a method for generating prompts for assessing post-traumatic stress symptoms in patients. At least one aspect and advantage of the present invention will be partially set forth in the following description, or will be apparent from the description, or may be learned through practice of the disclosed subject matter.

[0005] According to a first aspect of the present invention, a method for generating prompts for assessing post-traumatic stress symptoms in a patient comprises:

[0006] The first input unit is used to receive the content of the conversation and extract the complainant's response and usage prompts based on the content of the conversation;

[0007] A first context unit, configured to create or update a context according to an input of the first input unit;

[0008] A first matching unit is used to determine a test benchmark according to the complainant's response, the prompt used, and the context;

[0009] A first prompting unit is configured to determine a prompt based on a test benchmark and context, wherein a word vector or sentence vector corresponding to a valid prompt has a continuous similarity distribution, and the valid prompt is a prompt inferred based on the complainant's response and the prompt, and whose similarity to the prompt is greater than a first threshold;

[0010] The approximation is a cosine approximation.

[0011] According to one embodiment of the present invention, the context includes historical information of the complainant, a test benchmark, a response correlation degree set, a system matching degree set, a first vector set, a second vector set, and conversation information;

[0012] The response relevance set includes the relevance of the complainant's response to the physician's prompting statement;

[0013] The system matching degree set includes the correlation between the usage prompt and the system recommended prompt;

[0014] The first vector set includes text vectors corresponding to the complainant's reply text;

[0015] The second vector set includes text vectors corresponding to usage prompts.

[0016] According to one embodiment of the present invention, the context creation process includes:

[0017] Obtain the complainant's medical history;

[0018] Obtaining a first template for generating prompts based on a first text vector corresponding to the text of the historical medical record as a test benchmark for context use;

[0019] Set context for the complainant's historical information based on historical medical records.

[0020] According to one embodiment of the present invention, the context updating process includes:

[0021] determining a first correlation between the complainant's response and the prompt, and adding the first correlation to a response correlation set;

[0022] Adding the complainant's reply to the complainant's text set, and adding the first text vector corresponding to the complainant's reply to the first vector set;

[0023] Adding the usage prompt to the physician question text set, and adding the second text vector corresponding to the usage prompt to the second vector set;

[0024] A second correlation degree is determined according to the prompt word and the last prompt word determined by the first prompt unit, and the second correlation degree is added to the system matching degree set.

[0025] According to one embodiment of the present invention, the test benchmark is determined as follows:

[0026] determining a first matching degree according to the system matching degree set;

[0027] determining a second matching degree based on the response relevance set;

[0028] In response to the second degree of matching being lower than the first threshold, re-determining the test benchmark;

[0029] In response to the first matching degree being higher than a second threshold and the second matching degree being not lower than the second threshold, the responsiveness information within the test benchmark is updated.

[0030] According to one embodiment of the present invention, the test benchmark is re-determined based on the response association set and the input label.

[0031] According to one embodiment of the present invention, the prompt is generated based on the following method:

[0032] Determine the prompt template and corresponding text vector to be used based on the test items included in the test benchmark;

[0033] Obtaining a first usage prompt sequence corresponding to a correlation degree greater than a third threshold value in the response correlation degree set;

[0034] Determine, based on the first usage prompt sequence and the system matching degree set, a prompt corresponding to a system matching degree greater than a fourth threshold, and add the prompt to the second valid prompt sequence;

[0035] Select available prompts from the test benchmark, calculate the sum of the approximations of the last m prompts in the available prompts and the second valid prompt sequence as the third approximation, sort the available prompts in descending order according to the third approximation, and take the prompt with the highest third approximation as the prompt.

[0036] According to one embodiment of the present invention, the available prompt is a prompt not included in the test benchmark of the second valid prompt sequence, or a prompt not included in the test benchmark of the second valid prompt sequence and whose time interval from use is less than a time threshold.

[0037] According to one embodiment of the present invention, the prompt is generated based on the following method:

[0038] Determine the prompt template and corresponding text vector to be used based on the test items included in the test benchmark;

[0039] Determine a third valid prompt sequence according to the first vector set or the second vector set;

[0040] Select available prompts from the test base, calculate the sum of the approximations of the last m prompts in the available prompts and in the third valid prompt sequence as the third approximation, sort the available prompts in descending order according to the third approximation, and select the prompt with the highest third approximation as the prompt;

[0041] The third effective prompt sequence is determined as follows:

[0042] Determining the maximum correlation between the first vector set and the prompt text vectors included in the used test benchmark, and when the maximum correlation is greater than a fifth threshold, adding the prompt text vectors to the third valid prompt sequence;

[0043] Or the third effective prompt sequence is determined as follows:

[0044] The maximum correlation between the second vector set and the prompt corresponding text vector included in the used test benchmark is determined respectively, and when the maximum correlation is greater than a fifth threshold, it is added to the third valid prompt sequence.

[0045] According to one embodiment of the present invention, the prompt is generated based on the following method:

[0046] Determine the prompt template and corresponding text vector to be used based on the test items included in the test benchmark;

[0047] Determining a first similarity distribution based on the conversation content included in the context, wherein the first similarity distribution is obtained based on the correlation between the prompt words used and the prompt words recommended by the system;

[0048] A first valid prompt sequence with a correlation higher than a first threshold is obtained according to the first proximity distribution, available prompts are selected from the test benchmark, the sum of the approximations of the last m prompts in the available prompts and in the valid prompt sequence is calculated as a second proximity, the available prompts are sorted in descending order according to the second proximity, and the prompt with the highest second proximity is taken as the prompt. BRIEF DESCRIPTION OF THE DRAWINGS

[0049] Figure 1 A flowchart of a method for generating prompts for assessing post-traumatic stress symptoms in patients is shown. DETAILED DESCRIPTION

[0050] The present disclosure will now be discussed with reference to several exemplary embodiments. It should be understood that these embodiments are discussed only to enable those skilled in the art to better understand and implement the present disclosure, rather than to imply any limitation on the scope of the present disclosure.

[0051] As used herein, the term "including" and its variations are to be interpreted as open-ended terms meaning "including, but not limited to." The term "based on" is to be interpreted as "based, at least in part, on." The terms "one embodiment" and "an embodiment" are to be interpreted as "at least one embodiment." The term "another embodiment" is to be interpreted as "at least one other embodiment." Terms such as "upper," "lower," "left," "right," "front," "back," "top," "bottom," "inner," "outer," "vertical," "horizontal," "transverse," and "longitudinal" indicate orientations or positional relationships based on the orientations or positional relationships shown in the accompanying drawings. These terms are primarily intended to better describe the present application and its embodiments and are not intended to limit the devices, elements, or components indicated to having a specific orientation, or to being constructed and operated in a specific orientation. Furthermore, some of the above terms may be used to indicate other meanings besides orientation or positional relationships. For example, the term "on" may, in certain circumstances, be used to indicate a dependency or connection relationship. Those skilled in the art will understand the specific meanings of these terms in this application based on the specific circumstances. Furthermore, the terms "installed," "disposed," "provided with," "connected," and "connected" are to be interpreted broadly. For example, it can be a fixed connection, a detachable connection, or an integral structure; it can be a mechanical connection or an electrical connection; it can be a direct connection, an indirect connection through an intermediate medium, or an internal connection between two devices, elements, or components. For those of ordinary skill in the art, the specific meanings of the above terms in this application can be understood according to the specific circumstances. In addition, the terms "first", "second", etc. are mainly used to distinguish different devices, elements, or components (the specific types and structures may be the same or different), and are not used to indicate or imply the relative importance or quantity of the indicated devices, elements, or components. Unless otherwise specified, "plurality" means two or more.

[0052] According to one embodiment of the present invention, a method for generating prompts for assessing post-traumatic stress symptoms in a patient includes:

[0053] The first input unit is used to receive the content of the conversation and extract the complainant's response and usage prompts based on the content of the conversation;

[0054] A first context unit, configured to create or update a context according to an input of the first input unit;

[0055] A first matching unit is used to determine a test benchmark according to the complainant's response, the prompt used, and the context;

[0056] A first prompting unit is configured to determine a prompt based on a test benchmark and context, wherein a word vector or sentence vector corresponding to a valid prompt has a continuous similarity distribution, and the valid prompt is a prompt inferred based on the complainant's response and the prompt, and whose similarity to the prompt is greater than a first threshold;

[0057] The approximation is a cosine approximation.

[0058] In this embodiment, a method for generating prompts for assessing post-traumatic stress symptoms in patients is proposed. First, a first input unit extracts the complainant's responses and the prompts used in the received conversation content. Second, a first context unit creates or updates a context based on the input from the first input unit. The context includes historical information, a test benchmark, and conversation information. Third, a first matching unit determines a test benchmark based on the complainant's responses, the prompts used, and the context. Finally, the first prompt unit determines a prompt based on the test benchmark and context.

[0059] Specifically, post-traumatic stress disorder (PTSD) is a mental health problem triggered by experiencing or witnessing a traumatic event. Symptoms include flashbacks, nightmares, severe anxiety, and uncontrollable recollections of the event. These symptoms can persist for months or even years, severely impacting daily life. Patients with this condition require regular psychotherapy or communication to assess their condition. Doctors often use different vocabulary or dialogue techniques to guide communication for patients with varying degrees of illness. Therefore, designing questionnaires or conversation prompts tailored to the severity of the condition can facilitate smooth communication and ensure that the conversation does not deviate from the pre-set track.

[0060] Specifically, the conversation content received by the first input unit can be in text form, voice form, or a conversation processed into an image. Depending on the input type, the corresponding technology is used to identify and extract the complainant's response and the usage prompt. For example, in the case of an image conversation, OCR (Optical Character Recognition) technology is used to identify the conversation information in the image, and then the complainant's information and usage prompt are extracted from the conversation information. The usage prompt can be considered a word or sentence in the conversation content that is similar to the pre-set prompt.

[0061] Specifically, the test benchmark determined by the first matching unit is the basic standard for communication or questionnaire survey. Physicians can choose different test benchmarks for communication or questionnaire survey according to different patients. For example: when dealing with patients with severe conditions, words or sentences with a heavier tone may appear in communication or questionnaire surveys, such as "despair, difficulty breathing, strong self-denial" and so on; while for mild patients, when guiding patients to communicate or conduct questionnaire surveys, some words or sentences with a lighter tone and lower sensitivity can be used, such as "fear, guilt, shame, difficulty concentrating, difficulty falling asleep or restless sleep" and so on. Generally, using prompts with different test benchmarks for patients with different degrees of symptoms can help communicate with patients and guide patients to express their true feelings.

[0062] Specifically, when the first prompt unit can determine the prompt based on the test benchmark and context, if the similarity between the prompt and the prompt inferred based on the complainant's response and the prompt used is higher than the first threshold, the prompt is considered to be a valid prompt, and the word vector or sentence vector corresponding to the valid prompt has a continuous similarity distribution. More specifically, the similarity is cosine similarity, which is a method for measuring the similarity between two vectors and is commonly used in fields such as natural language processing (NLP), information retrieval, and recommendation systems. It evaluates the similarity of two vectors by calculating the cosine value of the angle between them, with a value range of [-1,1]. The closer the value is to 1, the more similar the two vectors are. Therefore, the first threshold is a value close to 1, and its specific value depends on the accuracy requirements.

[0063] Specifically, the above method can generate more accurate communication or questionnaire prompts based on patient test benchmarks. The generated prompts can then be used to determine whether the questionnaire or communication subject has deviated from the intended trajectory. This can effectively prevent overly subjective communication or questionnaire surveys by individual physicians, ensure smooth communication or questionnaire processing, and improve the objectivity and accuracy of the assessment. This method can even generate personalized prompts for different patients, improving service quality.

[0064] According to one embodiment of the present invention, the context includes historical information of the complainant, a test benchmark, a response correlation degree set, a system matching degree set, a first vector set, a second vector set, and conversation information;

[0065] The response relevance set includes the relevance of the complainant's response to the physician's prompting statement;

[0066] The system matching degree set includes the correlation between the usage prompt and the system recommended prompt;

[0067] The first vector set includes text vectors corresponding to the complainant's reply text;

[0068] The second vector set includes text vectors corresponding to usage prompts.

[0069] In this embodiment, the main contents of the context are described, including historical information of the complainant, test benchmarks, response relevance sets, system matching sets, first vector sets, second vector sets, and dialogue information.

[0070] Specifically, the response correlation set includes the correlation between the complainant's response to the physician's prompts, that is, the degree of similarity between the patient's response to the physician's prompts. The system match set includes the correlation between the prompts used and the system-recommended prompts, that is, the degree of similarity between the prompts used by the physician in the question or communication and the prompts recommended by the system. Specifically, the response correlation and system match are also represented using cosine approximation; the closer it is to 1, the higher the correlation or match.

[0071] Specifically, the first vector set includes text vectors corresponding to the complainant's reply text, and the second vector set includes text vectors corresponding to the usage prompts.

[0072] According to one embodiment of the present invention, the context creation process includes:

[0073] Obtain the complainant's medical history;

[0074] Obtaining a first template for generating prompts based on a first text vector corresponding to the text of the historical medical record as a test benchmark for context use;

[0075] Set context for the complainant's historical information based on historical medical records.

[0076] This embodiment describes the process of context creation. First, the complainant's historical medical records are obtained based on input from a first input unit. A first text vector corresponding to the text of the historical records is then obtained using a preset language model. A first template is then derived from the first text vector, and the template is used as a test benchmark for context. Finally, the complainant's historical information is set within the context based on the historical records.

[0077] Specifically, the test benchmark can be a questionnaire or a list of prompts, etc. Therefore, when the context is first created, the relevant information about the patient's condition is obtained based on historical cases, and the test benchmark is generated based on the vector corresponding to the information text, which is also the first template. This can make the content of the first questionnaire or communication more closely related to the patient's actual situation. According to one embodiment of the present invention, the context update process includes:

[0078] determining a first correlation between the complainant's response and the prompt, and adding the first correlation to a response correlation set;

[0079] Adding the complainant's reply to the complainant's text set, and adding the first text vector corresponding to the complainant's reply to the first vector set;

[0080] Adding the usage prompt to the physician question text set, and adding the second text vector corresponding to the usage prompt to the second vector set;

[0081] A second correlation degree is determined according to the prompt word and the last prompt word determined by the first prompt unit, and the second correlation degree is added to the system matching degree set.

[0082] In this embodiment, the context updating process is described, which is essentially the updating process of each piece of information included in the context.

[0083] Specifically, the response correlation set is a set of the correlation degrees between the patient's reply content and the usage prompts. Therefore, its update method is to determine the first correlation degree between the complainant's reply and the usage prompts, and add the first correlation degree to the response correlation set, that is, the correlation degree between the patient's reply and the usage prompts is added to the response correlation set as the first correlation degree.

[0084] Specifically, if the first vector set is the text vector corresponding to the complainant's reply, then the complainant's reply is added to the complainant's text set, and the first text vector corresponding to the complainant's reply is added to the first vector set. If the second vector set is the text vector corresponding to the usage prompt, then the usage prompt is added to the physician's question text set, and the second text vector corresponding to the usage prompt is added to the second vector set.

[0085] Specifically, the system matching degree set is a set of correlations between the usage prompts and the system recommended prompts. Since the doctor will ask multiple questions, multiple prompts will be used. Here, the approximation between the last prompt determined by the first prompt unit and the usage prompt is selected as the second correlation degree. The second correlation degree can be used to preliminarily determine whether the doctor complies with the test benchmark for communication or questionnaire survey. Therefore, the system matching degree set can be updated by adding the second correlation degree.

[0086] Specifically, when updating the system's matching set, comparing all prompts with the usage prompts would be cumbersome and affect system efficiency. However, using only the last confirmed prompt and the usage prompt to determine the second correlation can essentially determine whether the physician has deviated from the test baseline and reduce the computational effort.

[0087] According to one embodiment of the present invention, the test benchmark is determined as follows:

[0088] determining a first matching degree according to the system matching degree set;

[0089] determining a second matching degree based on the response relevance set;

[0090] In response to the second degree of matching being lower than a second threshold, re-determining the test benchmark;

[0091] In response to the first matching degree being higher than the second threshold and the second matching degree being not lower than the second threshold, updating the responsiveness information in the test benchmark. According to one embodiment of the present invention, the test benchmark is re-determined based on the response association set and the input label.

[0092] This embodiment describes how to determine a test benchmark. First, a first match degree is determined based on the system match degree set. The first match degree represents the degree of correlation between the physician's prompts and the system's recommended prompts. Then, a second match degree is determined based on the corresponding correlation degree. The second match degree represents the degree of correlation between the patient's responses to the physician's prompts during the conversation. Finally, if the second match degree falls below a second threshold, the test benchmark is redefined. If the first match degree exceeds the second threshold and the second match degree is not below the second threshold, the responsiveness information within the test benchmark is updated.

[0093] Specifically, if the second match is low, it indicates that the patient's corresponding physician's content and the physician's prompts are poorly correlated, possibly due to a mismatch between the test benchmark and the patient's condition. Therefore, it is necessary to re-determine whether the test benchmark is suitable for the patient. The same applies when the first match is low.

[0094] Specifically, when the first matching degree is higher than the second threshold and the second matching degree is not lower than the second threshold, it indicates that the doctor has accurately used the prompts of the test benchmark and the patient's response is also related to the prompts used by the doctor. At this time, it indicates that the test benchmark is more matched with the patient, the test benchmark is determined to be valid, and the responsiveness information in the test benchmark is updated.

[0095] Specifically, since both the system matching degree and the response correlation degree use cosine approximation to represent the degree of similarity, the second threshold is a number close to 1, and its specific value is determined according to the accuracy requirement during use.

[0096] Specifically, using appropriate test criteria for different patients can improve communication and questionnaire efficiency, and increase the accuracy of the results. Otherwise, it will lead to a lower second match, with the patient's response content differing from the prompt content, thus distorting the results.

[0097] Specifically, when the input label changes, that is, the patient's condition changes, that is, the patient's condition is corrected, the response correlation will also change accordingly. At this time, the test benchmark is re-determined based on the response correlation set and the input label.

[0098] According to one embodiment of the present invention, the prompt is generated based on the following method:

[0099] Determine the prompt template and corresponding text vector to be used based on the test items included in the test benchmark;

[0100] Obtaining a first usage prompt sequence corresponding to a correlation degree greater than a third threshold value in the response correlation degree set;

[0101] Determine, based on the first usage prompt sequence and the system matching degree set, a prompt corresponding to a system matching degree greater than a fourth threshold, and add the prompt to the second valid prompt sequence;

[0102] Select available prompts from the test benchmark, calculate the sum of the approximations of the available prompts and the last m prompts in the second valid prompt sequence as a third approximation, sort the available prompts in descending order according to the third approximation, and select the prompt with the highest third approximation as the prompt. According to one embodiment of the present invention, the available prompts are prompts in the test benchmark that are not included in the second valid prompt sequence, or prompts in the test benchmark that are included in the second valid prompt sequence and whose time interval from use is less than a time threshold.

[0103] In this embodiment, a first method for generating prompts is proposed. First, a prompt template and a corresponding text vector are determined based on the test items included in the test benchmark. Second, a first usage prompt sequence with a correlation greater than a third threshold value is obtained from the correlation set. Third, corresponding prompts with a system matching degree greater than the third threshold value are obtained and added to a second valid prompt sequence. Finally, available prompts are selected from the test benchmark, a third approximation is calculated based on the available prompts and the second valid prompt sequence, and a prompt is obtained based on the third approximation.

[0104] Specifically, the test benchmark is determined based on the patient's condition. For example, if a patient experiences post-COVID-19 anxiety, mild depression, or mild post-traumatic stress symptoms, the corresponding prompt template for that patient's test benchmark might include prompts such as "loss of appetite or overeating, feeling terrible about oneself, feeling like a failure, disappointing oneself or family, or having thoughts of dying or harming oneself." If a patient exhibits more severe post-traumatic stress symptoms after contracting COVID-19, the corresponding prompt template might include prompts such as "Do you have strong negative beliefs about yourself, others, or the world (e.g., I am bad, I have serious problems, no one can be trusted, the world is absolutely dangerous)?", "Do you have strong negative emotions such as fear, terror, anger, guilt, or shame?", or "Do you have irritable behavior, angry outbursts, or aggressive behavior?" Based on different test benchmarks, corresponding prompt templates can be determined, and the corresponding text vectors can be obtained using a pre-trained language model.

[0105] Specifically, the usage prompts corresponding to the response correlation degrees greater than the third threshold value in the response correlation set are selected to form a first usage prompt sequence. The usage prompts in the first usage prompt sequence are the prompts used by the patient to make a basically accurate response, that is, the prompts in the sequence are valid.

[0106] Specifically, based on the first usage prompt sequence and the system matching degree set, the prompts corresponding to the system matching degree greater than the fourth threshold are selected, and then a second valid prompt sequence is formed. The prompts in the second valid prompt sequence are based on the patient's correct response, and further screen out the part where the physician uses the correct physician prompt. That is, the prompts in the second valid prompt sequence are more objective and accurate.

[0107] Specifically, when calculating the third approximation, available prompts are selected based on the prompt template in the test benchmark, that is, all available prompts preset in the test benchmark. The approximation between the text vector corresponding to the prompt and the text vector corresponding to the last m prompts in the second valid prompt sequence is calculated, and the sum of all approximations is taken as the third approximation. More specifically, the third approximation can also be obtained by taking the average of the sum of all approximations.

[0108] Specifically, the available prompts are all prompts in the test baseline that are not included in the second valid prompt sequence. This can filter out duplicate prompts in the test baseline and the second valid prompt sequence, avoiding the omission of prompts that are relevant to the patient's condition but not mentioned in the subject communication or questionnaire.

[0109] Specifically, available prompts can also be those that meet the following three conditions: first, they must be included in the test baseline prompts; second, they must be included in the second valid prompt sequence; and third, their usage interval must be greater than a duration threshold. This allows us to select prompts that are included in both the test baseline and the second valid prompt sequence but are used less frequently, thus avoiding the omission of less common prompts that are relevant to the patient's condition.

[0110] Specifically, m is the number of prompts selected according to needs. Preferably, when m is 5, it can avoid excessive calculation workload while ensuring that a certain number of prompts are used in the calculation to ensure accuracy. Of course, if extremely high accuracy is required, a larger number of prompts can be selected for calculation.

[0111] Specifically, after calculating the third approximation, the available prompts are sorted from highest to lowest according to the third approximation, and the available prompt with the highest third approximation is selected as the prompt. Since the third approximation is cosine approximation, the closer it is to 1, the more similar it is. Therefore, the highest third approximation is selected as the prompt.

[0112] Specifically, the method in this embodiment can be used to determine the prompt, which can ensure that the prompt is more in line with the patient's actual situation and that the prompt used by the physician is more comprehensive and objective. It is a relatively comprehensive method. According to one embodiment of the present invention, the prompt is generated based on the following method:

[0113] Determine the prompt template and corresponding text vector to be used based on the test items included in the test benchmark;

[0114] Determine a third valid prompt sequence according to the first vector set or the second vector set;

[0115] Select available prompts from the test base, calculate the sum of the approximations of the last m prompts in the available prompts and in the third valid prompt sequence as the third approximation, sort the available prompts in descending order according to the third approximation, and select the prompt with the highest third approximation as the prompt;

[0116] The third effective prompt sequence is determined as follows:

[0117] Determining the maximum correlation between the first vector set and the prompt text vectors included in the used test benchmark, and when the maximum correlation is greater than a fifth threshold, adding the prompt text vectors to the third valid prompt sequence;

[0118] Or the third effective prompt sequence is determined as follows:

[0119] The maximum correlation between the second vector set and the prompt corresponding text vector included in the used test benchmark is determined respectively, and when the maximum correlation is greater than a fifth threshold, it is added to the third valid prompt sequence.

[0120] In this embodiment, a second method for generating prompts is proposed. First, a prompt template and corresponding text vectors are determined based on the test items included in the test benchmark. Second, a third valid prompt sequence is determined based on the first vector set or the second vector set. Finally, available prompts are selected from the test benchmark, a third approximation is calculated based on the available prompts and the second valid prompt sequence, and prompts are obtained based on the third approximation. Specifically, a first method for determining the third valid prompt sequence is to determine the maximum correlation between the text vector corresponding to each prompt in the test benchmark and the first vector set. When the maximum correlation is greater than a fifth threshold, the corresponding prompt is added to the third valid prompt sequence. More specifically, since the first vector set is the text vector corresponding to the complainant's reply text, the prompts in the resulting third valid prompt sequence are more closely aligned with the patient's response. Therefore, the prompts ultimately determined based on this type of third valid prompt sequence are also more closely aligned with the patient's response, which is beneficial for providing personalized services for different types of patients.

[0121] Specifically, the second method for determining the third effective prompt sequence is: determine the maximum correlation between the text vector corresponding to each prompt in the test benchmark used and the second vector set, and when the maximum correlation is greater than the fifth threshold, add the corresponding prompt to the third effective prompt sequence. More specifically, since the second vector set uses the text vector corresponding to the prompt, the prompts in the obtained third effective prompt sequence are closer to the doctor's questions. Therefore, the prompts finally determined based on this type of third effective prompt sequence are also closer to the prompts used by the doctor's questions, which is conducive to the doctor's questionnaire questions or communication being more accurate and objective.

[0122] Specifically, by using this method to determine prompts, prompts that are more suitable for patients or doctors can be selected based on needs.

[0123] According to one embodiment of the present invention, the prompt is generated based on the following method:

[0124] Determine the prompt template and corresponding text vector to be used based on the test items included in the test benchmark;

[0125] Determining a first similarity distribution based on the conversation content included in the context, wherein the first similarity distribution is obtained based on the correlation between the prompt words used and the prompt words recommended by the system;

[0126] A first valid prompt sequence with a correlation higher than a first threshold is obtained according to the first proximity distribution, available prompts are selected from the test benchmark, the sum of the approximations of the last m prompts in the available prompts and in the valid prompt sequence is calculated as a second proximity, the available prompts are sorted in descending order according to the second proximity, and the prompt with the highest second proximity is taken as the prompt.

[0127] In this embodiment, a third method for generating prompts is proposed. First, a prompt template and a corresponding text vector are determined based on the test items included in the test benchmark. Second, a first proximity distribution is determined based on the conversation content included in the context. Third, a first valid prompt sequence with a correlation greater than a first threshold is obtained based on the first proximity distribution. A second proximity is then obtained based on the available prompts in the test benchmark and the first valid prompt sequence. Finally, a prompt is selected based on the second proximity.

[0128] Specifically, the first similarity distribution is obtained according to the correlation between the physician prompts and the system-recommended prompts, and thus the first valid prompt sequence obtained based on the first similarity distribution is more inclined towards the physician prompts.

[0129] Specifically, when calculating the second approximation, available prompts are selected based on the prompt template in the test benchmark, that is, all available prompts preset in the test benchmark. The approximation between the corresponding text vectors and the text vectors corresponding to the last m prompts in the first valid prompt sequence is calculated, and the sum of all approximations is taken as the second approximation. More specifically, the average of the sum of all approximations can be taken as the second approximation.

[0130] Specifically, m is the number of prompts selected according to needs. Preferably, when m is 5, it can avoid excessive calculation workload while ensuring that a certain number of prompts are used in the calculation to ensure accuracy. Of course, if extremely high accuracy is required, a larger number of prompts can be selected for calculation.

[0131] Specifically, after calculating the second approximation, the available prompts are sorted from high to low according to the second approximation, and the available prompt with the highest second approximation is selected as the prompt. Since the second approximation is cosine approximation, the closer it is to 1, the more similar it is. Therefore, the highest second approximation is selected as the prompt.

[0132] Specifically, unlike the second prompt acquisition method that tends to favor physicians, the prompts obtained by this method are more concise in that the first valid prompt sequence obtained based on the first approximation distribution is more concise, while the third valid prompt sequence obtained by associating the second vector set may contain some invalid information, that is, there may be some worthless conversations.

[0133] The beneficial effects of the present invention are as follows: through the above-mentioned method, more accurate communication or questionnaire prompts based on patient test benchmarks can be generated according to different needs. The generated prompts can also be used to determine whether the questionnaire or communication subject has deviated from the intended track. This can also effectively avoid some communications or questionnaire surveys that are overly subjective by individual physicians, and can ensure the smooth progress of the communication or questionnaire, thereby improving the objectivity and accuracy of the assessment. This method can even generate personalized prompts based on different patients, thereby improving service quality.

[0134] Those skilled in the art will appreciate that the modules and algorithm steps described in conjunction with the embodiments disclosed herein can be implemented using electronic hardware, or a combination of computer software and electronic hardware. Whether these functions are performed in hardware or software depends on the specific application and design constraints of the technical solution. Professionals and technicians may use different methods to implement the described functions for each specific application, but such implementation should not be considered beyond the scope of the present invention.

[0135] Those skilled in the art will clearly understand that, for the convenience and brevity of description, the specific working processes of the above-described devices and equipment can refer to the corresponding processes in the aforementioned method embodiments and will not be repeated here.

[0136] In the embodiments provided in this application, it should be understood that the disclosed devices and methods can be implemented in other ways. For example, the device embodiments described above are merely schematic. For example, the division of the modules is merely a logical function division. In actual implementation, there may be other division methods, such as multiple modules or components can be combined or integrated into another system, or some features can be ignored or not executed. Another point is that the mutual coupling or direct coupling or communication connection shown or discussed can be through some interfaces, indirect coupling or communication connection of devices or modules, which can be electrical, mechanical or other forms.

[0137] The modules described as separate components may or may not be physically separate, and the components shown as modules may or may not be physical modules, that is, they may be located in one place or distributed across multiple network modules. Some or all of these modules may be selected according to actual needs to achieve the objectives of the embodiments of the present invention.

[0138] In addition, each functional module in the embodiment of the present invention may be integrated into one processing module, or each module may exist physically separately, or two or more modules may be integrated into one module.

[0139] If the functions are implemented as software modules and sold or used as standalone products, they can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of the present invention, or the portion that contributes to the prior art, or the portion of the technical solution itself, can be embodied in the form of a software product. This computer software product is stored in a storage medium and includes instructions for enabling a computer device (which can be a personal computer, server, or network device, etc.) to perform all or part of the steps of the energy-saving signal transmission / reception method according to various embodiments of the present invention. The aforementioned storage medium includes various media capable of storing program code, such as a USB flash drive, a mobile hard drive, ROM, RAM, a magnetic disk, or an optical disk.

[0140] The above description is merely a preferred embodiment of the present application and an illustration of the technical principles employed. Those skilled in the art should understand that the scope of the invention involved in this application is not limited to the technical solutions formed by the specific combination of the above-mentioned technical features, but also encompasses other technical solutions formed by any combination of the above-mentioned technical features or their equivalents without departing from the inventive concept. For example, a technical solution formed by replacing the above-mentioned features with (but not limited to) technical features with similar functions disclosed in this application.

[0141] It should be understood that the size of the serial numbers of the steps in the content of the invention and the embodiments of the present invention does not absolutely mean the order of execution. The execution order of each process should be determined by its function and internal logic, and should not constitute any limitation on the implementation process of the embodiments of the present invention. The foregoing description of the implementation of the present disclosure has been given for the purpose of example and description. The foregoing description is not exhaustive and is not intended to limit the present disclosure to the exact form disclosed. Various variations and modifications may exist based on the above teachings, or various variations and modifications may be obtained from the practice of the present disclosure. These embodiments are selected and described in order to illustrate the principles of the present disclosure and its practical application, so that those skilled in the art can utilize the present disclosure in various embodiments and various modifications suitable for the specific purpose conceived.

Claims

1. A method for generating prompts for assessing post-traumatic stress symptoms in patients, characterized in that: include: The first input unit is used to receive the content of the conversation and extract the complainant's response and usage prompts based on the content of the conversation; A first context unit, configured to create or update a context according to an input of the first input unit; A first matching unit is used to determine a test benchmark according to the complainant's response, the prompt used, and the context; a first prompting unit, configured to determine a prompt based on a test benchmark and context, wherein if the similarity between the prompt and a prompt inferred based on the complainant's response and the prompt used is greater than a first threshold, the prompt is considered a valid prompt, and the word vector or sentence vector corresponding to the valid prompt has a continuous similarity distribution; The approximation is cosine approximation; The context includes historical information of the complainant, test benchmarks, response relevance sets, system matching sets, first vector sets, second vector sets, and dialogue information; The response relevance set includes the relevance of the complainant's response to the physician's prompting statement; The system matching degree set includes the correlation between the usage prompt and the system recommended prompt; The first vector set includes text vectors corresponding to the complainant's reply text; The second vector set includes text vectors corresponding to the usage prompts; The test benchmark is to obtain a first template for generating prompts based on a first text vector corresponding to the text of the complainant's historical case in the historical information; The test benchmark is determined as follows: determining a first matching degree according to the system matching degree set; determining a second matching degree based on the response relevance set; In response to the second degree of matching being lower than a second threshold, re-determining the test benchmark; In response to the first matching degree being higher than a second threshold and the second matching degree being not lower than the second threshold, the responsiveness information within the test benchmark is updated.

2. The method for generating prompts for assessing post-traumatic stress symptoms in patients according to claim 1, wherein: The context creation process includes: Obtain the complainant's medical history; Obtaining a first template for generating prompts based on a first text vector corresponding to the text of the historical medical record as a test benchmark for context use; Set context for the complainant's historical information based on historical medical records.

3. The method for generating prompts for assessing post-traumatic stress symptoms in patients according to claim 1, wherein: The context update process includes: determining a first correlation between the complainant's response and the prompt, and adding the first correlation to a response correlation set; Adding the complainant's reply to the complainant's text set, and adding the first text vector corresponding to the complainant's reply to the first vector set; Adding the usage prompt to the physician question text set, and adding the second text vector corresponding to the usage prompt to the second vector set; A second correlation degree is determined according to the prompt word and the last prompt word determined by the first prompt unit, and the second correlation degree is added to the system matching degree set.

4. The method for generating prompts for assessing post-traumatic stress symptoms in patients according to claim 1, wherein: Re-determine the test basis based on the response association set and the input label.

5. The method for generating prompts for assessing post-traumatic stress symptoms in patients according to claim 1, wherein: The prompt is generated based on the following method: Determine the prompt template and corresponding text vector to be used based on the test items included in the test benchmark; Obtaining a first usage prompt sequence corresponding to a correlation degree greater than a third threshold value in the response correlation degree set; Determine, based on the first usage prompt sequence and the system matching degree set, a prompt corresponding to a system matching degree greater than a fourth threshold, and add the prompt to the second valid prompt sequence; Select available prompts from the test benchmark, calculate the sum of the approximations of the last m prompts in the available prompts and the second valid prompt sequence as the third approximation, sort the available prompts in descending order according to the third approximation, and take the prompt with the highest third approximation as the prompt.

6. The method for generating prompts for assessing post-traumatic stress symptoms in patients according to claim 5, wherein: The available prompts are prompts in the test benchmark that are not included in the second valid prompt sequence, or prompts in the test benchmark that are not included in the second valid prompt sequence and whose time interval from use is less than a time threshold.

7. The method for generating prompts for assessing post-traumatic stress symptoms in patients according to claim 1, wherein: The prompt is generated based on the following method: Determine the prompt template and corresponding text vector to be used based on the test items included in the test benchmark; Determine a third valid prompt sequence according to the first vector set or the second vector set; Select available prompts from the test base, calculate the sum of the approximations of the last m prompts in the available prompts and in the third valid prompt sequence as the third approximation, sort the available prompts in descending order according to the third approximation, and select the prompt with the highest third approximation as the prompt; The third effective prompt sequence is determined as follows: Determining the maximum correlation between the first vector set and the prompt text vectors included in the used test benchmark, and when the maximum correlation is greater than a fifth threshold, adding the prompt text vectors to the third valid prompt sequence; Or the third effective prompt sequence is determined as follows: The maximum correlation between the second vector set and the prompt corresponding text vector included in the used test benchmark is determined respectively, and when the maximum correlation is greater than a fifth threshold, it is added to the third valid prompt sequence.

8. The method for generating prompts for assessing post-traumatic stress symptoms in patients according to claim 1, wherein: The prompt is generated based on the following method: Determine the prompt template and corresponding text vector to be used based on the test items included in the test benchmark; Determining a first similarity distribution based on the conversation content included in the context, wherein the first similarity distribution is obtained based on the correlation between the prompt words used and the prompt words recommended by the system; A first valid prompt sequence with a correlation higher than a first threshold is obtained according to the first proximity distribution, available prompts are selected from the test benchmark, the sum of the approximations of the last m prompts in the available prompts and in the valid prompt sequence is calculated as a second proximity, the available prompts are sorted in descending order according to the second proximity, and the prompt with the highest second proximity is taken as the prompt.

Citation Information

Patent Citations

  • Personalized electronic questionnaire construction method and electronic questionnaire system

    CN115659922A

  • Dialogue system and a dialogue method

    US20240404514A1