Behavior intervention system and method combining large language model and behavior analysis

By combining large language models and behavioral analysis, dynamic intervention is achieved in multiple fields based on the environment and behavioral conditions, solving the problem of insufficient flexibility in the existing technology intervention system in new scenarios, and improving the adaptability and application of the system Breadth.

CN119128065APending Publication Date: 2024-12-13刘佳
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202311600992.7
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2023-11-28
Publication Date
2024-12-13

AI Technical Summary

Technical Problem

Existing intervention systems lack flexibility and adaptability in new or unknown scenarios, and their interventions perform poorly in the face of new or changing environments.

Method used

Adopt a behavioral intervention system that combines large language model and behavioral analysis to collect and store data through observation databases and record knowledge bases, and use multi-agents and large language models to perform data analysis and intervention instructions generation to achieve dynamic adaptation to the environment and behavior. .

Benefits of technology

Without the need to train data for specific scenarios, the system can automatically run in multiple fields according to the environment and behavioral conditions, improving the flexibility and adaptability of the intervention system and promoting the cross-domain development of artificial intelligence applications.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119128065A_ABST
    Figure CN119128065A_ABST
Patent Text Reader

Abstract

The invention discloses a big language model and behavior analysis combined behavior intervention system and method, and belongs to the technical field of behavior intervention. The system for executing one or more effective intervention measures according to environment conditions and behavior conditions under the condition of multi-scene in a single field or multi-field and multi-scene combination is realized. The system does not need to carry out specific scene data training on a specific scene, does not need to carry out specific adjustment on related parameters for the specific scene, only needs to sort and extract behavior analysis knowledge and intervention knowledge and import the knowledge into a knowledge base in a voice or other media mode, and the system can automatically run according to the knowledge. The application development of the intervention system in the fields of medical health, psychological counseling, education, computer science and artificial intelligence, pet feeding, experimental observation and the like is greatly promoted, multi-field fusion research is accelerated, and the system has the trans-time significance of promoting artificial intelligence application to universal artificial intelligence application.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention belongs to the technical field of behavior intervention, and specifically relates to a behavior intervention system and method combining a large language model with behavior analysis. Background Art

[0002] Intervention systems are widely used in the fields of medical health, psychological counseling, education, computer science and artificial intelligence, pet breeding, experimental observation, etc., and have penetrated into every corner of people's work and life. Faced with a large number of intervention scenarios and a wide range of intervention needs, running intervention systems has become an essential means to improve intervention efficiency, improve intervention effects, and achieve intervention goals.

[0003] When running the intervention system, we first need to observe the behavioral state of the intervened object in the intervention scenario (hereinafter referred to as "behavior") and its surrounding environment (hereinafter referred to as "environment"), then organize and save the observed data into records for analysis, and then analyze these records to obtain intervention countermeasures and execution requirements (hereinafter referred to as "intervention instructions"), and finally complete the intervention according to the intervention instructions.

[0004] To this end, in the existing technology, improving the accuracy of the intervention system is often used as the main direction of optimization and improvement. This optimization usually requires a large amount of observation data annotation, and retraining is required when the task or environment changes. In order to make the intervention system more efficient, vertical field intervention systems are often operated in specific tasks or domain scenarios (hereinafter referred to as "scenarios"), such as speech recognition, image recognition, knowledge question and answer, or expert systems for specific scenarios. This makes the intervention system inflexible and inadaptable in new or unknown scenarios, and the intervention performance is poor when facing new or changing environments. Summary of the invention

[0005] 1. Technical problem to be solved by the invention

[0006] The purpose of the present invention is to solve the problem that the existing intervention system has no flexibility and adaptability in new or unknown scenarios and performs poorly in the face of new or changing environments.

[0007] 2. Technical solution

[0008] In order to achieve the above object, the technical solution provided by the present invention is:

[0009] A behavior intervention system combining a large language model with behavior analysis of the present invention comprises:

[0010] An observation database, wherein the observation database is used to collect and store observation data;

[0011] A record knowledge base, which is used to convert the observation data stored in the observation database into record knowledge of behavior records for collection and storage;

[0012] A recording multi-agent is communicatively connected to the observation database and the recording knowledge base, the recording multi-agent is connected to the analysis multi-agent and the behavior and state recording database, and the analysis multi-agent is connected to the intervention system control agent and the intervention multi-agent.

[0013] Preferably, the observation database is communicatively connected to an environment observation device and a behavior observation device, the environment observation device is used to obtain environment observation data and send it to the observation database, and the behavior observation device is used to obtain behavior observation data and send it to the observation database.

[0014] Preferably, the behavior observation device is communicatively connected to a vertical field behavior analysis model and sends the behavior observation data to the vertical field behavior analysis model, and the vertical field behavior analysis model is communicatively connected to a vertical field intervention device, and the vertical field behavior analysis model analyzes specific behavior observation data and outputs the vertical field observation data to an observation database or outputs vertical field intervention instructions to the vertical field intervention device.

[0015] Preferably, the observation database is also used to save environmental observation data, behavioral observation data, vertical field observation data and intervention data as a relational triple structure, and the record knowledge base decomposes any record knowledge into data description and data usage description, and vectorizes the data description and saves it as a vector triple structure.

[0016] Preferably, the workflow of recording multiple agents is:

[0017] Step S81, the recording multi-agent receives the recording request of the analysis multi-agent;

[0018] Step S82, the record multi-agent obtains the observation data query description text of the specified content from the record knowledge base through the observation data description text of the specified content through the similarity query network, and the result is used as the chat record text;

[0019] Step S83, the recording multi-agent obtains the observation data query description text of these observation data from the record knowledge base through the similarity query network according to the chat record text, and the result is used as the reference content text in a specific object array format;

[0020] Step S84: the recording multi-agent combines the reference content text and the prompt word text of the specified content with variables into a question text and asks the large language model to obtain an observation query instruction in JSON format;

[0021] Step S85, the recording multi-agent obtains a prompt word text in a specific object array format by using the precise query network to observe the query instruction, merges it into a question text, and asks the large language model to obtain a reply text, i.e., a behavior record;

[0022] Step S86: The recording multi-agent generates a write instruction for the behavior and status record database in combination with the behavior record text, and then executes the write instruction to save the behavior record into the behavior and status record database.

[0023] Preferably, the analyzing multi-agent, intervening multi-agent and recording multi-agent are all connected to a large language model, which accepts questions raised by the analyzing multi-agent, the intervening multi-agent or the recording multi-agent, performs large language model calculations to generate reply texts, and sends the generated reply texts to the corresponding analyzing multi-agent, the intervening multi-agent or the recording multi-agent that raised the questions.

[0024] Preferably, the intervention multi-agent generates a record request text with specified content or a status record request text with specified content at a specified time interval, and sends it to the analysis multi-agent as a status problem. The intervention multi-agent is connected to an intervention knowledge base, and the intervention knowledge base can decompose any intervention knowledge description text into an intervention action description text and an intervention instruction description text, and calculate the intervention action description text into vectorized data, and save them together as a vector triple structure ({ID, Vector, Metadata}, where ID expresses the text obtained after HASH calculation of the intervention action description text, Vector expresses the vectorized data calculated from the intervention action description text, and Metadata is a text in a specific object array format [[{Q: "intervention action description"; A: "intervention instruction description"}]].

[0025] Preferably, the analysis multi-agent includes a state analysis role analysis multi-agent and a behavior analysis role analysis multi-agent. The specific workflow is as follows:

[0026] S41, status analysis role analysis After responding to the status question, the multi-agent first converts the status question into a specific object array format, where the value of the request source is one of the texts "System", "Human" or "AI", the chat record text submitted by the intervening multi-agent is marked as "System", the voice inquiry device collects the voice and generates the status question through the voice recognition model, and the others are marked as "AI"), and in addition, a specified content prompt word text is generated, merged into a question text to ask the large language model, and the reply text, that is, the request type, is obtained;

[0027] S42, the state analysis role analysis multi-agent extracts the request type (state analysis, record request, behavior analysis) from the reply text, sends the request text of the record request type as a record request to the record multi-agent, and sends the request text of the behavior analysis type as an analysis request to the behavior analysis role analysis multi-agent;

[0028] S43, Status Analysis Role Analysis The multi-agent performs status analysis on the request type, combining the chat record text and a prompt word text of a specified content (distinguishing whether an answer is required, such as: "1. The content in the sentence that requires an answer is the status answer; 2. Other content that does not require an answer is an analysis request") into a question text and asks the large language model to obtain a reply text, i.e., the answer type;

[0029] S44, the state analysis role analysis multi-agent extracts the answer type (state answer type, analysis request type) from the reply text, and sends the request text of the analysis request type as an analysis request to the behavior analysis role analysis multi-agent;

[0030] S45, state analysis role analysis multi-agent pair is state answer type, according to the chat record text through similarity query network from the behavior and state record database specific object array format ([{Q: "record type"; A: "record description text"}], where the value of the record type is one of the texts "state record" or "behavior record") data as the reference content text, together with the state question into a question text to ask the large language model, and obtain the reply text, that is, the state answer;

[0031] S46. State analysis role analysis The multi-agent generates speech for the state answer through the speech generation model, and then plays it through the speech response device.

[0032] Preferably, the intervention multi-agent obtains a text in a specific object array format ([{Q: intervention action description; A: intervention instruction description}], where the intervention instruction description is a JSON format text) and a prompt word text with a specified content (generating a JSON instruction according to the specified intervention action) from the intervention knowledge base through a similarity query network for the intervention device name, and combines them into a question text to ask the large language model (LLMs) to obtain a reply text, i.e., the intervention instruction;

[0033] The intervention multi-agent encapsulates the intervention instruction into an API text required by the Internet of Things platform, and sends the API text to the Internet of Things platform according to the protocol requirements of the Internet of Things platform. After receiving the intervention instruction, the Internet of Things platform drives a specific intervention device (200) according to the parameters in the instruction.

[0034] A behavior intervention method combining a large language model and behavior analysis, the method adopts the above system, the method is

[0035] S1. Collect behavior analysis knowledge, intervention knowledge or intervention skill knowledge through expert review or intervention skill instructions generated by behavior and state analysis multi-agents, and store the knowledge data in the behavior and state record database;

[0036] S2, obtain environmental data through an environmental observation device, obtain behavioral data through a behavioral observation device, analyze other behavioral data through vertical field behavior analysis to obtain behavioral data in the vertical field, and intervention data in the form of logs generated by analyzing multi-agent intervention decisions, and store environmental data, behavioral data, and intervention data in a behavior and status record database;

[0037] S3. Define the two roles of behavior analysis and state analysis in analyzing multi-agents;

[0038] S3-1, the state analysis role responds to the state question or the defined state trigger condition, obtains a set of behavior records that meet the time feature vector similarity threshold interval and a set of behavior knowledge and intervention knowledge data that meet one or more vector feature similarity threshold intervals through querying the network, generates a state answer or state data, and stores the state data in the behavior record or in the form of log;

[0039] S3-2, the behavior analysis role is used to respond to intervention requests or defined behavior trigger conditions, obtain a set of behavior records that meet the time feature vector similarity threshold interval and a set of behavior knowledge and intervention knowledge data that meet one or more vector feature similarity threshold intervals by querying the network, generate intervention countermeasures, select corresponding intervention prompt word templates and intervention skill knowledge, and generate intervention skill instructions and intervention data in log form from the large language model.

[0040] 3. Beneficial effects

[0041] Compared with the prior art, the technical solution provided by the present invention has the following beneficial effects:

[0042] The present invention discloses a behavior intervention system and method combining a large language model with behavior analysis, including an observation database, the observation database is used to collect and store observation data; a record knowledge base, the record knowledge base is used to convert the observation data stored in the observation database into record knowledge of behavior records for collection and storage; a record multi-agent connected to the observation database and the record knowledge base, the record multi-agent is connected to an analysis multi-agent and a behavior and state record database, and the analysis multi-agent is connected to an intervention system control agent and an intervention multi-agent. A system is implemented to execute one or more effective intervention measures according to environmental conditions and behavior conditions in multiple scenarios in a single field or in multiple fields and multiple scenarios. The system does not need to train specific scene data for specific scenes, nor does it need to make specific adjustments to relevant parameters for specific scenes. It only needs to sort out and extract behavior analysis knowledge and intervention knowledge, and import them into the knowledge base in the form of voice or other media, and the system will automatically run according to the knowledge. It greatly promotes the application and development of intervention systems in the fields of medical health, psychological counseling, education, computer science and artificial intelligence, pet breeding, experimental observation, etc., accelerates multi-field integration research, and has the cross-era significance of promoting artificial intelligence applications to general artificial intelligence applications. BRIEF DESCRIPTION OF THE DRAWINGS

[0043] Figure 1 It is a schematic diagram of the overall structure of a behavior intervention system combining a large language model with behavior analysis according to the present invention;

[0044] Figure 2 The application structure of the system of the present invention is shown in FIG. Figure 1 ;

[0045] Figure 3 The application structure of the system of the present invention is shown in FIG. Figure 2 ;.

[0046] Explanation of the symbols in the schematic diagram:

[0047] 110. Environmental observation device; 120. Behavior observation device; 130. Vertical field behavior analysis model; 140. Vertical field intervention device; 200. Intervention device; 300. Observation database; 400. Analysis of multi-agent; 410. Analysis knowledge base; 500. Intervention system control agent; 600. Large language model; 700. Intervention of multi-agent; 710. Intervention knowledge base; 800. Recording of multi-agent; 810. Behavior and state recording database; 820. Recording knowledge base. DETAILED DESCRIPTION

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

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

[0050] In the present application, the terms "upper", "lower", "left", "right", "front", "back", "top", "bottom", "inner", "outer", "middle", "vertical", "horizontal", "lateral", "longitudinal" and the like indicate positions or positional relationships based on the positions or positional relationships shown in the drawings. These terms are mainly used to better describe the present application and its embodiments, and are not used to limit the indicated devices, elements or components to have a specific orientation, or to be constructed and operated in a specific orientation.

[0051] In addition, some of the above terms may be used to express other meanings in addition to indicating orientation or positional relationship. For example, the term "on" may also be used to express a certain dependency or connection relationship in some cases. For those of ordinary skill in the art, the specific meanings of these terms in this application can be understood according to specific circumstances.

[0052] In addition, the terms "installed", "set", "provided with", "connected", "connected", and "socketed" should be understood in a broad sense. 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, or an indirect connection through an intermediate medium, or it can be 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 specific circumstances.

[0053] It should be noted that, in the absence of conflict, the embodiments and features in the embodiments of the present application can be combined with each other. The present application will be described in detail below with reference to the accompanying drawings and in combination with the embodiments.

[0054] Example 1

[0055] See attached Figure 1 , a behavior intervention system combining a large language model with behavior analysis in this embodiment includes

[0056] An observation database 300, wherein the observation database 300 is used to collect and store observation data;

[0057] A record knowledge base 820, which is used to convert the observation data stored in the observation database 300 into record knowledge of behavior records for collection and storage;

[0058] The recording multi-agent 800 is communicatively connected to the observation database 300 and the recording knowledge base 820. The recording multi-agent 800 is connected to the analysis multi-agent 400 and the behavior and state recording database 810. The analysis multi-agent 400 is connected to the intervention system control agent 500 and the intervention multi-agent 700.

[0059] The observation database 300 is communicatively connected to an environment observation device 110 and a behavior observation device 120 . The environment observation device 110 is used to obtain environment observation data and send it to the observation database 300 . The behavior observation device 120 is used to obtain behavior observation data and send it to the observation database 300 .

[0060] The behavior observation device 120 is communicatively connected to the vertical field behavior analysis model 130 and sends the behavior observation data to the vertical field behavior analysis model 130. The vertical field behavior analysis model 130 is communicatively connected to the vertical field intervention device 140. The vertical field behavior analysis model 130 analyzes specific behavior observation data and outputs the vertical field observation data to the observation database 300 or outputs vertical field intervention instructions to the vertical field intervention device 140.

[0061] The observation database 300 is also used to save environmental observation data, behavioral observation data, vertical field observation data and intervention data as a relational triple structure. The record knowledge base 820 decomposes any record knowledge into data description and data usage description, and vectorizes the data description and saves it as a vector triple structure.

[0062] The workflow of recording multi-agent 800 is as follows

[0063] Step S81, the recording multi-agent 800 receives the recording request of the analysis multi-agent 400;

[0064] Step S82, the recording multi-agent 800 obtains the observation data query description text of the specified content from the recording knowledge base 820 through the similarity query network through the observation data description text of the specified content, and the result is used as the chat record text;

[0065] Step S83, the recording multi-agent 800 obtains the observation data query description text of these observation data from the recording knowledge base 820 through the similarity query network according to the chat record text, and the result is used as the reference content text in a specific object array format;

[0066] Step S84, the recording multi-agent 800 combines the reference content text and the prompt word text of the specified content with variables into a question text to query the large language model 600 to obtain an observation query instruction in JSON format;

[0067] Step S85, the recording multi-agent 800 obtains a prompt word text in a specific object array format by using the precise query network to observe the query instruction, merges it into a question text, and asks the large language model 600 to obtain a reply text, i.e., a behavior record;

[0068] Step S86: The recording multi-agent 800 generates a write instruction for the behavior and status record database in combination with the behavior record text, and then executes the write instruction to save the behavior record into the behavior and status record database 810.

[0069] The analysis multi-agent 400, intervention multi-agent 700, and recording multi-agent 800 are all connected to a large language model 600. The large language model 600 receives questions raised by the analysis multi-agent 400, intervention multi-agent 700, or recording multi-agent 800, performs large language model calculations to generate reply texts, and sends the generated reply texts to the corresponding analysis multi-agent 400, intervention multi-agent 700, or recording multi-agent 800 that raised the questions.

[0070] The intervention multi-agent 700 generates a record request text with specified content or a status record request text with specified content at a specified time interval, and sends it to the analysis multi-agent 400 as a status problem. The intervention multi-agent 700 is connected to an intervention knowledge base 710. The intervention knowledge base 710 can decompose any intervention knowledge description text into an intervention action description text and an intervention instruction description text, and calculate the intervention action description text into vectorized data, and save them together as a vector triple structure ({ID, Vector, Metadata}, where ID represents the text obtained after HASH calculation of the intervention action description text, Vector represents the vectorized data calculated from the intervention action description text, and Metadata is a text in a specific object array format [[{Q: "intervention action description"; A: "intervention instruction description"}]].

[0071] The analysis multi-agent 400 includes a state analysis role analysis multi-agent and a behavior analysis role analysis multi-agent. The specific workflow is as follows:

[0072] S41, status analysis role analysis After responding to the status question, the multi-agent first converts the status question into a specific object array format, where the value of the request source is one of the texts "System", "Human" or "AI", the chat record text submitted by the intervening multi-agent 700 is marked as "System", the voice inquiry device collects the voice and generates the status question through the voice recognition model (the chat record text marked as "Human", and the others are marked as "AI"), and in addition, a specified content prompt word text is generated, merged into a question text to ask the large language model 600, and a reply text, that is, the request type, is obtained;

[0073] S42, the state analysis role analysis multi-agent extracts the request type (state analysis, record request, behavior analysis) from the reply text, sends the request text of the record request type as a record request to the record multi-agent 800, and sends the request text of the behavior analysis type as an analysis request to the behavior analysis role analysis multi-agent;

[0074] S43, Status Analysis Role Analysis The multi-agent analyzes the request type as status analysis, and combines the chat record text and a prompt word text of a specified content (distinguishing whether an answer is required, such as: "1. The content in the sentence that requires an answer is a status answer; 2. Other content that does not require an answer is an analysis request") into a question text and asks the large language model 600 to obtain a reply text, that is, an answer type;

[0075] S44, the state analysis role analysis multi-agent extracts the answer type (state answer type, analysis request type) from the reply text, and sends the request text of the analysis request type as an analysis request to the behavior analysis role analysis multi-agent;

[0076] S45, state analysis role analysis multi-agent pair is of state answer type, based on the chat record text, through similarity query network, from the behavior and state record database specific object array format ([{Q: "record type"; A: "record description text"}], where the value of the record type is one of the texts "state record" or "behavior record") data as reference content text, and merge it with the state question into a question text to ask the large language model 600, and obtain the reply text, that is, the state answer;

[0077] S46. State analysis role analysis The multi-agent generates speech for the state answer through the speech generation model, and then plays it through the speech response device.

[0078] The intervention multi-agent 700 obtains a text in a specific object array format ([{Q: intervention action description; A: intervention instruction description}], where the intervention instruction description is a JSON format text) and a prompt word text with a specified content (generating a JSON instruction according to the specified intervention action) from the intervention knowledge base for the name of the intervention device 200 through a similarity query network, and combines them into a question text to ask the large language model (LLMs) to obtain a reply text, i.e., the intervention instruction;

[0079] The intervention multi-agent (700) encapsulates the intervention instruction into an API text required by the Internet of Things platform, and sends the API text to the Internet of Things platform according to the protocol requirements of the Internet of Things platform. After receiving the intervention instruction, the Internet of Things platform drives a specific intervention device 200 according to the parameters in the instruction.

[0080] The analysis multi-agent 400 of this embodiment is also connected to an analysis knowledge base 410, which is used to collect and store analysis knowledge description texts describing the conversion of behavior records in the behavior and state record database into state records, intervention data, and intervention requests;

[0081] Further, the analysis knowledge base can decompose any analysis knowledge description text into a record description text and an analysis description text, and calculate the record description text into vectorized data, and save them together as a vector type triple structure ({ID, Vector, Metadata}, where ID represents the text obtained after HASH calculation of the record description text, Vector represents the vectorized data calculated from the record description text, and Metadata is a specific object array format [[{Q: "description of the record phenomenon"; A: "intervention measures adopted"}], Q stores the description of the record phenomenon of a specific scene in the record description text, and A stores the description of the intervention measures adopted for the record phenomenon of a specific scene in the analysis description text] text);

[0082] Example 2

[0083] This embodiment provides a behavior intervention method that combines a large language model with behavior analysis. The method uses the system described in Example 1. The method is:

[0084] S1, collect behavior analysis knowledge, intervention knowledge or intervention skill knowledge through expert review or intervention skill instructions generated by behavior and state analysis multi-agents, and store the knowledge data in the behavior and state record database 810;

[0085] S2, obtaining environmental data through the environmental observation device 110, obtaining behavioral data through the behavioral observation device 120, analyzing other behavioral data through vertical field behavior analysis to obtain behavioral data in the vertical field, and intervention data in the form of logs generated by the analysis multi-agent 400 while generating intervention decisions, and storing the environmental data, behavioral data, and intervention data in the behavior and state record database 810;

[0086] S3, defining two roles, behavior analysis and state analysis, in the analysis multi-agent 400;

[0087] S3-1, the state analysis role responds to the state question or the defined state trigger condition, obtains a set of behavior records that meet the time feature vector similarity threshold interval and a set of behavior knowledge and intervention knowledge data that meet one or more vector feature similarity threshold intervals through querying the network, generates a state answer or state data, and stores the state data in the behavior record or in the form of log;

[0088] S3-2, the behavior analysis role is used to respond to intervention requests or defined behavior trigger conditions, obtain a set of behavior records that meet the time feature vector similarity threshold interval and a set of behavior knowledge and intervention knowledge data that meet one or more vector feature similarity threshold intervals by querying the network, generate intervention countermeasures, select corresponding intervention prompt word templates and intervention skill knowledge, and generate intervention skill instructions and intervention data in log form from the large language model.

[0089] The above-described embodiments only express a certain implementation mode of the present invention, and the description thereof is relatively specific and detailed, but it cannot be understood as limiting the patent scope of the present invention. It should be pointed out that, for ordinary technicians in this field, several modifications and improvements can be made without departing from the concept of the present invention, which all belong to the protection scope of the present invention. Therefore, the protection scope of the patent of the present invention shall be based on the attached claims.

Claims

1. A behavior intervention system combining a large language model with behavior analysis, characterized in that: It comprises an observation database (300), wherein the observation database (300) is used to collect and store observation data; A record knowledge base (820), the record knowledge base (820) is used to convert the observation data stored in the observation database (300) into record knowledge of behavior records for collection and storage; A recording multi-agent (800) is communicatively connected to the observation database (300) and the recording knowledge base (820), wherein the recording multi-agent (800) is connected to the analysis multi-agent (400) and the behavior and state recording database (810), and the analysis multi-agent (400) is connected to the intervention system control agent (500) and the intervention multi-agent (700).

2. The behavior intervention system combining a large language model and behavior analysis according to claim 1, characterized in that: The observation database (300) is communicatively connected to an environment observation device (110) and a behavior observation device (120), wherein the environment observation device (110) is used to obtain environment observation data and send it to the observation database (300), and the behavior observation device (120) is used to obtain behavior observation data and send it to the observation database (300).

3. The behavior intervention system combining a large language model and behavior analysis according to claim 2, characterized in that: The behavior observation device (120) is communicatively connected to a vertical field behavior analysis model (130) and sends the behavior observation data to the vertical field behavior analysis model (130). The vertical field behavior analysis model (130) is communicatively connected to a vertical field intervention device (140). The vertical field behavior analysis model (130) analyzes specific behavior observation data and outputs the vertical field observation data to an observation database (300) or outputs a vertical field intervention instruction to the vertical field intervention device (140).

4. The behavior intervention system combining a large language model with behavior analysis according to claim 3, characterized in that: The observation database (300) is also used to save environmental observation data, behavioral observation data, vertical field observation data and intervention data as a relational triple structure. The record knowledge base (820) decomposes any record knowledge into data description and data usage description, and vectorizes the data description and saves it as a vector triple structure.

5. The behavior intervention system combining a large language model with behavior analysis according to claim 1, characterized in that: The workflow of recording multi-agent (800) is as follows: Step S81, the recording multi-agent (800) receives a recording request from the analyzing multi-agent (400); Step S82, the recording multi-agent (800) obtains the observation data query description text of the specified content from the recording knowledge base (820) through the similarity query network through the observation data description text of the specified content, and the result is used as the chat record text; Step S83, the recording multi-agent (800) obtains the observation data query description text of these observation data from the recording knowledge base (820) through the similarity query network according to the chat record text, and the result is used as the reference content text in a specific object array format; Step S84, the recording multi-agent (800) combines the reference content text and the prompt word text of the specified content with variables into a question text and asks the large language model (600) to obtain an observation query instruction in JSON format; Step S85, the recording multi-agent (800) obtains a prompt word text in a specific object array format by using the precise query network to observe the query instruction, merges it into a question text, and asks the large language model (600) to obtain a reply text, i.e., a behavior record; Step S86: The recording multi-agent (800) generates a write instruction for the behavior and status record database in combination with the behavior record text, and then executes the write instruction to save the behavior record into the behavior and status record database (810).

6. The behavior intervention system combining a large language model and behavior analysis according to claim 1, characterized in that: The analysis multi-agent (400), intervention multi-agent (700), and recording multi-agent (800) are all connected to a large language model (600). The large language model (600) receives questions raised by the analysis multi-agent (400), intervention multi-agent (700), or recording multi-agent (800), performs large language model calculations to generate reply texts, and sends the generated reply texts to the corresponding analysis multi-agent (400), intervention multi-agent (700), or recording multi-agent (800) that raised the questions.

7. The behavior intervention system combining a large language model with behavior analysis according to claim 6, characterized in that: The intervention multi-agent (700) generates a record request text of specified content or a status record request text of specified content at a specified time interval, and sends it to the analysis multi-agent (400) as a status problem. The intervention multi-agent (700) is connected to an intervention knowledge base (710). The intervention knowledge base (710) can decompose any intervention knowledge description text into an intervention action description text and an intervention instruction description text, and calculate the intervention action description text into vectorized data, which are saved together as a vector type triple structure ({ID, Vector, Metadata}, where ID represents the text obtained after HASH calculation of the intervention action description text, Vector represents the vectorized data calculated from the intervention action description text, and Metadata is a text in a specific object array format [[{Q: "intervention action description"; A: "intervention instruction description"}]].

8. The behavior intervention system combining a large language model with behavior analysis according to claim 7, characterized in that: The analysis multi-agent (400) includes a state analysis role analysis multi-agent and a behavior analysis role analysis multi-agent. The specific workflow is as follows: S41, status analysis role analysis After responding to the status question, the multi-agent first converts the status question into a specific object array format, wherein the value of the request source is one of the texts "System", "Human" or "AI", the chat record text submitted by the intervening multi-agent (700) is labeled as "System", the voice inquiry device collects the voice and generates the status question through the voice recognition model, and the other is labeled as "AI"), and in addition, a specified content prompt word text is generated, merged into a question text to ask the large language model (600), and a reply text, that is, the request type, is obtained; S42, the state analysis role analysis multi-agent extracts the request type (state analysis, record request, behavior analysis) from the reply text, sends the request text of the record request type as a record request to the record multi-agent (800), and sends the request text of the behavior analysis type as an analysis request to the behavior analysis role analysis multi-agent; S43, Status Analysis Role Analysis The multi-agent performs status analysis on the request type, and combines the chat record text and a prompt word text of a specified content (distinguishing whether an answer is required, such as: "1. The content in the sentence that requires an answer is a status answer; 2. Other content that does not require an answer is an analysis request") into a question text and asks the large language model (600) to obtain a reply text, i.e., the answer type; S44, the state analysis role analysis multi-agent extracts the answer type (state answer type, analysis request type) from the reply text, and sends the request text of the analysis request type as an analysis request to the behavior analysis role analysis multi-agent; S45, state analysis role analysis multi-agent pair is of state answer type, based on the chat record text, through similarity query network, from the behavior and state record database specific object array format ([{Q: "record type"; A: "record description text"}], where the value of the record type is one of the texts "state record" or "behavior record") data as reference content text, and merge it with the state question into a question text to inquire the large language model (600), and obtain the reply text, that is, the state answer; S46. State analysis role analysis The multi-agent generates speech for the state answer through the speech generation model, and then plays it through the speech response device.

9. The behavior intervention system combining a large language model with behavior analysis according to claim 8, characterized in that: The intervention multi-agent (700) obtains a text in a specific object array format ([{Q: intervention action description; A: intervention instruction description}], where the intervention instruction description is a JSON format text) and a prompt word text with a specified content (generating a JSON instruction according to the specified intervention action) from the intervention knowledge base for the name of the intervention device (200) through a similarity query network, and combines them into a question text to inquire the large language model (600) to obtain a reply text, i.e., the intervention instruction; The intervention multi-agent (700) encapsulates the intervention instruction into an API text required by the Internet of Things platform, and sends the API text to the Internet of Things platform according to the protocol requirements of the Internet of Things platform. After receiving the intervention instruction, the Internet of Things platform drives a specific intervention device (200) according to the parameters in the instruction.

10. A behavior intervention method combining a large language model with behavior analysis, characterized in that: The method adopts the system according to any one of claims 1 to 9, and the method is S1. Collect behavior analysis knowledge, intervention knowledge or intervention skill knowledge through expert review or intervention skill instructions generated by behavior and state analysis multi-agents, and store the knowledge data in a behavior and state record database (810); S2, obtaining environmental data through the environmental observation device (110), obtaining behavioral data through the behavioral observation device (120), analyzing other behavioral data through vertical field behavior analysis to obtain behavioral data in the vertical field, and intervention data in the form of logs generated by the analysis multi-agent (400) when generating intervention decisions, and storing the environmental data, behavioral data, and intervention data in the behavior and state record database (810); S3, defining two roles of behavior analysis and state analysis in the analysis multi-agent (400); S3-1, the state analysis role responds to the state question or the defined state trigger condition, obtains a set of behavior records that meet the time feature vector similarity threshold interval and a set of behavior knowledge and intervention knowledge data that meet one or more vector feature similarity threshold intervals through querying the network, generates a state answer or state data, and stores the state data in the behavior record or in the form of log; S3-2, the behavior analysis role is used to respond to intervention requests or defined behavior trigger conditions, obtain a set of behavior records that meet the time feature vector similarity threshold interval and a set of behavior knowledge and intervention knowledge data that meet one or more vector feature similarity threshold intervals by querying the network, generate intervention countermeasures, select corresponding intervention prompt word templates and intervention skill knowledge, and generate intervention skill instructions and intervention data in log form from the large language model.