Cognitive chain enhanced college student group psychological health dialogue system construction method

By building a cognitive chain-enhanced dialogue system for college students, the problem of the lack of mental theory in mental health dialogue between large language models is solved, and the accurate understanding and support of college students' emotional and psychological needs is achieved.

CN119785979AActive Publication Date: 2025-04-08NORTHWESTERN POLYTECHNICAL UNIV
View PDF 6 Cites 0 Cited by

Patent Information

Application Number
CN202411956569.5
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-12-29
Publication Date
2025-04-08
Estimated Expiration
2044-12-29

AI Technical Summary

Technical Problem

The existing large language models lack mental theory in mental health dialogues, making it difficult to understand and deal with the complex emotional and psychological needs of college students.

Method used

By building a cognitive chain-enhanced dialogue system for college students' group mental health, obtaining the target data set, fine-tuning the ChatGLM-6b model, and building a library of college students' group mental cognitive chains to enhance the model's mental theory understanding ability.

Benefits of technology

It has achieved natural and smooth dialogues with strong emotional support, which can better understand the psychological state and emotional needs of college students, provide accurate and personalized support, and improve the personalization and accuracy of dialogues.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119785979A_ABST
    Figure CN119785979A_ABST
Patent Text Reader

Abstract

The invention discloses a cognitive chain enhanced college student group psychological health dialogue system construction method. The method comprises the following steps: acquiring a target data set, collecting a plurality of dialogues from the target data set, and taking each dialogue as each seed dialogue; cue words about college students and mental health doctors are obtained, and the cue words comprise college student topics; inputting the cue word and one seed dialogue into a ChatGPT model, generating a group of self-chat dialogues about the cue word, and generating multiple groups of self-chat dialogues about different college student topics in the cue word by changing the college student topics in the cue word and each seed dialogue for multiple times in the ChatGPT model; and performing fine adjustment on the ChatGLM-6b model through a target algorithm based on multiple groups of self-chat dialogues about different college student topics in the cue words to obtain a college student group mental health model. The technical problem that an existing large language model lacks a mental theory is solved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the technical field of college students' mental health dialogue, and in particular to a method for constructing a cognitive chain-enhanced college students' group mental health dialogue system. Background Art

[0002] In the context of rapid social development, college students are facing pressure and challenges in academics, interpersonal relationships, and future planning. These factors often lead to mental health problems such as mood swings, anxiety, and depression. Therefore, it is particularly important to provide effective and timely emotional support and mental health counseling for college students.

[0003] The goal of this study is to build an emotional support dialogue system for college students to address mental health challenges such as academic pressure, interpersonal relationships, and emotional distress. The system uses advanced natural language processing technology and psychological principles to provide college students with personalized, accurate emotional support and mental health counseling, aiming to help them better understand and regulate their emotional states and improve their mental health.

[0004] However, there are many challenges in applying large language models (LLMs) to the field of mental health. First, the sensitivity and complexity of mental health conversations require language models to have natural and fluent language generation capabilities, deep empathy and emotional understanding capabilities. At the same time, the model should also be able to provide personalized interaction and support based on the individual differences in the psychological and emotional needs of college students. Second, large language models need to have a theory of mind (ToM) to understand situations and predict reactions, and provide responses that meet needs. However, one of the largest language models today (GPT-4) still lacks a theory of mind. Summary of the invention

[0005] The embodiment of the present invention provides a method for constructing a cognitive chain-enhanced psychological health dialogue system for college students, so as to at least solve the technical problem that the existing large language model lacks a theory of mind.

[0006] According to one aspect of an embodiment of the present invention, a method for constructing a cognitive chain-enhanced psychological health dialogue system for college students is provided. The method may include: obtaining a target data set, collecting a number of dialogues from the target data set, and taking each dialogue as each seed dialogue; obtaining prompt words about college students and mental health doctors, wherein the prompt words include college student topics; inputting the prompt words and a seed dialogue into a ChatGPT model to generate a group of self-chat dialogues about the prompt words, and generating multiple groups of self-chat dialogues about different college student topics in the prompt words by changing the college student topics in the prompt words and each seed dialogue multiple times in the ChatGPT model; fine-tuning the ChatGLM-6b model through a target algorithm based on multiple groups of self-chat dialogues about different college student topics in the prompt words to obtain a college student group mental health model; constructing a college student group mental cognition chain library based on several initial mental cognition chains and multiple college student topics, wherein; obtaining a question information; retrieving three semantically related target mental cognition chains from the college student group mental cognition chain library according to the question information; inputting the question information and the three target mental cognition chains into the college student group mental health model to obtain a group of target replies about the question information and each target mental cognition chain, wherein one question information and one target mental chain correspond to one target reply.

[0007] Optionally, the process of fine-tuning the ChatGLM-6b model based on multiple groups of self-chat dialogues on different college student topics in the prompt words through a target algorithm to obtain a college student group mental health model is:

[0008] in, is the original parameter matrix of the ChatGLM-6b model, , The parameter matrix added when training the ChatGLM-6b model for any self-chat dialogue on different college student topics, It is the parameter matrix of the mental health model for college students.

[0009] Optionally, the expression of the tuning parameter matrix is:

[0010] in, , , , is the rank of the tuning parameter matrix, is the first low-rank matrix, is the second lowest rank matrix.

[0011] Optionally, the method of constructing a mental cognitive chain library of a college student group based on several initial mental cognitive chains and multiple college student topics includes: inputting an initial mental cognitive chain and a corresponding college student topic into the ChatGPT model to obtain a mental cognitive chain about the college student topic; for an initial mental cognitive chain, traversing all college student topics corresponding to the initial mental cognitive chain to obtain all mental cognitive chains corresponding to the initial mental cognitive chain; traversing all initial mental cognitive chains to obtain all mental cognitive chains corresponding to all initial mental cognitive chains; and constructing a mental cognitive chain library of a college student group based on all mental cognitive chains.

[0012] Optionally, the mental cognition chain includes five nodes, which are: situation, clue, thought, action and emotion.

[0013] Optionally, the mental cognition chain includes four nodes, which are: situation, clue, thought and action plus emotion.

[0014] Beneficial effects of the present invention: 1. Dataset construction and model fine-tuning: By constructing a dataset specifically for college students and combining the instruction fine-tuning technology of a large language model, the present invention successfully built a large model of college students' mental health that can generate natural, fluent and emotionally supportive speech. This model can better understand the psychological state and emotional needs of college students and provide them with more accurate and personalized support.

[0015] 2. Formalization and application of theory of mind: This invention innovatively formalizes the theory of mind (ToM) into a mental cognitive chain specifically for college students and integrates it into the AI ​​system, so that the system can not only understand the literal meaning of the text, but also deeply understand the psychological and emotional state of the college student group. This progress significantly enhances the system's ability to understand college students' cognition, provide targeted help and generate personalized content. BRIEF DESCRIPTION OF THE DRAWINGS

[0016] The drawings described herein are used to provide a further understanding of the present invention and constitute a part of this application. The exemplary embodiments of the present invention and their descriptions are used to explain the present invention and do not constitute an improper limitation of the present invention. In the drawings: Figure 1 It is a flowchart of a method for constructing a cognitive chain enhanced college student group mental health dialogue system according to an embodiment of the present invention. DETAILED DESCRIPTION

[0017] In order to enable those skilled in the art to better understand the scheme of the present invention, the technical scheme in the embodiments of the present invention will be clearly and completely described below in conjunction with the drawings in the embodiments of the present invention. Obviously, the described embodiments are only embodiments of a part of the present invention, not all embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work should fall within the scope of protection of the present invention.

[0018] It should be noted that the terms "first", "second", etc. in the specification and claims of the present invention and the above-mentioned drawings are used to distinguish similar objects and to describe a specific order or sequence. It should be understood that the terms used in this way can be interchanged where appropriate, so that the embodiments of the present invention described herein can be implemented in an order other than those illustrated or described herein. In addition, the terms "including" and "having" and any variations thereof are intended to cover non-exclusive inclusions, for example, a process, method, system, product or device that includes a series of steps or units is not necessarily limited to those steps or units that are clearly listed, but may include other steps or units that are not clearly listed or inherent to these processes, methods, products or devices.

[0019] Example 1 According to an embodiment of the present invention, a method for constructing a cognitive chain enhanced mental health dialogue system for college students is provided. It should be noted that the steps shown in the flowchart of the accompanying drawings can be executed in a computer system containing at least one set of computer executable instructions, and although a logical order is shown in the flowchart, in some cases, the steps shown or described can be executed in an order different from that shown here.

[0020] Figure 1 is a flow chart of a method for constructing a cognitive chain enhanced college student group mental health dialogue system according to an embodiment of the present invention. Figure 1 As shown, the method comprises the following steps: Step S101, obtaining a target data set, collecting a number of conversations from the target data set, and taking each conversation as a seed conversation.

[0021] In this embodiment, a target data set is obtained, wherein the target data set is ESConv and ETMHS, and several dialogues are collected from the target data set, and each dialogue is used as a seed dialogue.

[0022] Step S102, obtaining prompt words about college students and mental health doctors, wherein the prompt words include college student topics.

[0023] In this embodiment, for example, the prompt word may be: Please help me generate a chat dialogue, the two parties are a college student and a mental health doctor, the college student's topic is that his pet has passed away, and he needs a mental health doctor to comfort and counsel him. Please refer to the following example: Seed dialogue.

[0024] Step S103, input the prompt word and a seed dialogue into the ChatGPT model to generate a group of self-chat dialogues about the prompt word, and generate multiple groups of self-chat dialogues about different college student topics in the prompt word in the ChatGPT model by multiple changes in the college student topic in the prompt word and each seed dialogue.

[0025] In this embodiment, for example, the prompt word can be: Please help me generate a chat dialogue. The two parties are a college student and a mental health doctor. The topic of the college student is that his pet has passed away and he needs a mental health doctor to comfort and counsel him. Please refer to the following example: seed dialogue. The prompt word and the seed dialogue are input into the ChatGPT model to generate a group of self-chat dialogues about the prompt word, and the college student topic and the seed dialogue are changed multiple times to generate multiple groups of self-chat dialogues about different college student topics in the prompt word. This is only an example for illustration without specific limitation.

[0026] Step S104, based on multiple groups of self-chat dialogues about different college student topics in the prompt words, the ChatGLM-6b model is fine-tuned through the target algorithm to obtain a mental health model for the college student group.

[0027] In this embodiment, based on multiple groups of self-chat dialogues about different college student topics in the prompt words, the ChatGLM-6b model parameters are fine-tuned by the LoRA method to obtain a mental health model for the college student group. The LoRA method optimizes the rank decomposition matrix of the dense layer during the adjustment process, so that specific dense layers in the neural network can be indirectly trained without changing the pre-trained weights.

[0028] Step S105, constructing a mental cognition chain library of the college student group based on a number of initial mental cognition chains and a plurality of college student topics.

[0029] In this embodiment, a mental cognition chain library of the college student group is constructed based on a number of initial mental cognition chains and a plurality of college student topics.

[0030] Step S106, obtaining a question information, and retrieving three semantically related target mental cognitive chains from the mental cognitive chain library of the college student group according to the question information.

[0031] In this embodiment, a question information is obtained, for example, my pet passed away, and three semantically related target mental cognitive chains are retrieved from the mental cognitive chain library of the college student group based on the question information.

[0032] Step S107, input a question information and three target mental cognitive chains into the psychological health model of the college student group, and obtain a set of target replies about a question information and each target mental cognitive chain, wherein a question information and a target mental chain correspond to a target reply.

[0033] In this embodiment, the question information and each target mental cognitive chain are input into the psychological health model of the college student group to obtain a set of target replies about one question information and each target mental cognitive chain, wherein one question information and one target mental chain correspond to one target reply.

[0034] The above method of this embodiment is further introduced below.

[0035] As an optional embodiment, in step S104, the process of fine-tuning the ChatGLM-6b model based on multiple groups of self-chat dialogues on different college student topics in the prompt words through the target algorithm to obtain the college student group mental health model is:

[0036] in, is the original parameter matrix of the ChatGLM-6b model, , The parameter matrix added when training the ChatGLM-6b model for any self-chat dialogue on different college student topics, It is the parameter matrix of the mental health model for college students.

[0037] In this embodiment, the parameters of the ChatGLM-6b model are fine-tuned by the LoRA method according to multiple groups of self-chat dialogues on different college student topics in the prompt words, and a mental health model of the college student group after the adjustment is obtained.

[0038] As an optional implementation method, the expression of the tuning parameter matrix is:

[0039] in, , , , is the rank of the tuning parameter matrix, is the first low-rank matrix, is the second lowest rank matrix.

[0040] As an optional implementation method, step S105, based on several initial mental cognitive chains and multiple college student topics, constructing a mental cognitive chain library of the college student group, includes: inputting an initial mental cognitive chain and a corresponding college student topic into the ChatGPT model to obtain a mental cognitive chain about the college student topic; for an initial mental cognitive chain, traversing all college student topics corresponding to the initial mental cognitive chain to obtain all mental cognitive chains corresponding to the initial mental cognitive chain; traversing all initial mental cognitive chains to obtain all mental cognitive chains corresponding to all initial mental cognitive chains; and constructing a mental cognitive chain library of the college student group based on all mental cognitive chains.

[0041] In this embodiment, for example, the human thinking process: what is the scenario, what is the clue, what is the thought, what is the action, what is the emotion, when facing a topic, is input into the ChatGPT model to obtain a mental cognition chain about the college student topic, and for an initial mental cognition chain, all college student topics corresponding to the initial mental cognition chain are traversed to obtain all mental cognition chains corresponding to the initial mental cognition chain, and all initial mental cognition chains are traversed to obtain all mental cognition chains corresponding to all initial mental cognition chains; based on all mental cognition chains, a mental cognition chain library of the college student group is obtained.

[0042] As an optional implementation mode, the mental cognition chain includes five nodes, and the five nodes are: situation, clue, thought, action and emotion.

[0043] In this embodiment, for example, the situation is: I don’t want to hand in my homework, not handing it in once, the clue is: my teacher is very good and will not make things difficult for students, the thought is: I can not hand in my homework this time, the action is: I will not hand in my homework this time, and the emotion is that I am very happy.

[0044] As an optional implementation mode, the mental cognition chain includes four nodes, and the four nodes are: situation, clue, thought and action plus emotion.

[0045] In this embodiment, for example, situation: I don’t want to hand in my homework, not handing it in once, clue: My teacher is very good and will not make things difficult for students, thought: I can not hand in my homework this time, action plus emotion: I am very happy that I don’t have to hand in my homework this time.

[0046] In an embodiment of the present invention, a target data set is obtained, and several conversations are collected from the target data set, and each conversation is used as a seed conversation; prompt words about college students and mental health doctors are obtained, wherein the prompt words include college student topics; the prompt words and a seed conversation are input into the ChatGPT model to generate a group of self-chat conversations about the prompt words, and in the ChatGPT model, multiple groups of self-chat conversations about different college student topics in the prompt words are generated by repeatedly changing the college student topics in the prompt words and each seed conversation; based on the multiple groups of self-chat conversations about different college student topics in the prompt words, the ChatGLM-6b model is fine-tuned through the target algorithm to obtain a college student group mental health model; based on several initial mental cognitive chains and multiple college student topics, a mental health model is constructed. A mental cognitive chain library for college students; obtain a question information, and retrieve three semantically related target mental cognitive chains from the mental cognitive chain library for college students according to the question information; input a question information and the three target mental cognitive chains into the mental health model of the college students, and obtain a set of target replies about a question information and each target mental cognitive chain, wherein a question information and a target mental chain correspond to a target reply, which solves the technical problem that the existing large language model lacks a theory of mind, achieves the goal of building a high-quality mental health dialogue dataset covering multiple emotional states, trains a large language model focusing on the mental health of college students, and innovatively integrates the mental cognitive chain of college students into the dialogue system, improving the technical effect of personalization and accuracy of the dialogue.

[0047] The serial numbers of the above embodiments of the present invention are only for description and do not represent the advantages or disadvantages of the embodiments.

[0048] In the above embodiments of the present invention, the description of each embodiment has its own emphasis. For parts that are not described in detail in a certain embodiment, reference can be made to the relevant descriptions of other embodiments.

[0049] In the several embodiments provided in this application, it should be understood that the disclosed technical content can be implemented in other ways. Among them, the device embodiments described above are only schematic. For example, the division of units can be a logical function division. There may be other division methods in actual implementation. For example, multiple units 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 units or modules, which can be electrical or other forms.

[0050] The units described as separate components may or may not be physically separated, and the components shown as units may or may not be physical units, that is, they may be located in one place or distributed over multiple units. Some or all of the units may be selected according to actual needs to achieve the purpose of the present embodiment.

[0051] In addition, each functional unit in each embodiment of the present invention may be integrated into a first processing unit, or each unit may exist physically separately, or two or more units may be integrated into one unit. The above-mentioned integrated unit may be implemented in the form of hardware or in the form of software functional units.

[0052] The above are only preferred embodiments of the present invention. It should be pointed out that, for ordinary technicians in this technical field, several improvements and modifications can be made without departing from the principles of the present invention. These improvements and modifications should also be regarded as the scope of protection of the present invention.

Claims

1. A method for constructing a cognitive chain-enhanced college student group psychological health dialogue system, characterized in that: include: Obtain a target data set, collect several dialogues from the target data set, and use each dialogue as a seed dialogue; Obtain prompt words about college students and mental health practitioners, wherein the prompt words include college student topics; Input a prompt word and a seed conversation into the ChatGPT model to generate a set of self-chat conversations about the prompt word. In the ChatGPT model, by changing the college student topic in the prompt word and each seed conversation multiple times, multiple sets of self-chat conversations about different college student topics in the prompt word are generated. Based on multiple groups of self-chat dialogues about different topics of college students in the prompt words, the ChatGLM-6b model was fine-tuned through the target algorithm to obtain the mental health model of college students. Based on several initial mental cognition chains and multiple topics of college students, a mental cognition chain library of college students is constructed; Obtain a question information, and retrieve three semantically related target mental cognitive chains from the mental cognitive chain library of the college students according to the question information; A question message and three target mental cognitive chains are input into the mental health model of college students, and a set of target replies about a question message and each target mental cognitive chain is obtained, among which one question message and one target mental chain correspond to one target reply.

2. The method according to claim 1, characterized in that The process of fine-tuning the ChatGLM-6b model based on multiple groups of self-chat dialogues on different college student topics in the prompt words through the target algorithm to obtain the mental health model of the college student group is as follows: in, is the original parameter matrix of the ChatGLM-6b model, , The parameter matrix added when training the ChatGLM-6b model for any self-chat dialogue on different college student topics, It is the parameter matrix of the mental health model for college students.

3. The method according to claim 2, characterized in that The expression of the tuning parameter matrix is: in, , , , is the rank of the tuning parameter matrix, is the first low-rank matrix, is the second lowest rank matrix.

4. The method according to claim 1, characterized in that: Based on several initial mental cognition chains and multiple college student topics, a mental cognition chain library of college students is constructed, including: Input an initial mental cognition chain and its corresponding college student topic into the ChatGPT model to obtain a mental cognition chain about the college student topic; For an initial mental cognition chain, traverse all the corresponding college student topics of the initial mental cognition chain to obtain all the mental cognition chains corresponding to the initial mental cognition chain; Traverse all initial mental cognition chains to obtain all mental cognition chains corresponding to all initial mental cognition chains; Construct a mental cognitive chain library for college students based on all mental cognitive chains.

5. The method according to claim 1, characterized in that The mental cognition chain includes five nodes, which are: situation, clue, thought, action and emotion.

6. The method according to claim 5, characterized in that The mental cognition chain includes four nodes, which are: situation, clue, thought and action plus emotion.

7. A computer system, characterized in that include: One or more processors, and a computer-readable storage medium for storing one or more programs, wherein when the one or more programs are executed by the one or more processors, the one or more processors are enabled to implement the method of claim 1.

8. A computer-readable storage medium, characterized in that Computer executable instructions are stored, and when the instructions are executed, they are used to implement the method of claim 1.

9. A computer program product, characterized in that The invention comprises computer executable instructions, which are used to implement the method of claim 1 when being executed.

Citation Information

Patent Citations

  • Psychological field data generation method and device, psychological field model training method and device and storage medium

    CN117828063A

  • Natural language processing method, device and equipment and readable storage medium

    CN118445387A

  • Emotion support dialogue method based on user belief

    CN119106687A

  • Psychological consultation method, device and equipment based on artificial intelligence and storage medium

    CN119153040A

  • Door device for dangerous goods storage

    KR102168276B1