A multi-agent collaborative discussion method, system, and storage medium based on hierarchical context and divergence-driven approach.
By employing a hierarchical context and divergence-driven multi-agent collaborative discussion method, the problems of context redundancy and process disorder in multi-topic and multi-expert scenarios are solved, achieving an efficient and orderly discussion process and structured output results.
Patent Information
- Application Number
- CN202611390706.2
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2026-09-09
- Publication Date
- 2026-11-10
AI Technical Summary
Existing multi-agent collaborative discussion technologies suffer from problems such as contextual redundancy, weakened role characteristics, disordered processes, repeated debates, and unstructured results in scenarios involving multiple topics, multiple experts, and multiple rounds of speaking. These issues make it difficult to achieve efficient and orderly recovery of the discussion process and analysis of the results.
It adopts a hierarchical context management system, including a role setting layer, a knowledge base layer, and a dialogue history layer. Combined with a divergence-driven approach, it dynamically adjusts the speaking order of agents through expert direction priority ranking and semantic divergence detection, and performs accurate recovery and structured output after interruption.
It improves the context management capabilities of multi-agent collaborative discussions, reduces redundancy and repetitive debates, enhances process controllability and the structure of results, and ensures the continuity of the discussion process and the efficiency of resource utilization.
Smart Images

Figure CN123070167A_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the fields of artificial intelligence and natural language processing, and in particular to a multi-agent collaborative discussion method, system, and storage medium based on hierarchical context and divergence-driven approaches. Background Technology
[0002] With the development of artificial intelligence technology, large language models, with their strong natural language understanding, content generation, and semantic reasoning capabilities, have been gradually applied to scenarios such as corporate strategic planning, technical solution demonstration, project review, policy consultation, and expert-assisted decision-making. Compared with the traditional approach of relying on multiple domain experts to conduct centralized discussions in offline meetings, using large language models to construct intelligent agents with different professional roles can, to a certain extent, reduce the cost of expert organization and coordination, and improve the information processing efficiency of the discussion process.
[0003] Existing multi-agent collaborative technologies typically employ multiple agents with different functions or roles to jointly complete a target task. For example, coordinating agents, content-generating agents, review agents, or virtual expert agents from different domains can be set up, and corresponding viewpoints or task results can be generated through serial calls, parallel calls, or multi-turn dialogues. Some solutions can also determine whether different agents participate in the current dialogue based on the current discussion context, or improve the completeness and accuracy of reasoning results through multi-turn debates among multiple agents.
[0004] However, existing multi-agent processing methods still have certain shortcomings in long-term collaborative seminars involving multiple topics, multiple experts, and multiple rounds of presentations.
[0005] On the one hand, when multi-agent systems invoke large language models in multiple rounds, they need to continuously provide the model with expert role information, relevant discussion knowledge, and historical dialogues. Current methods typically concatenate different types of contextual information before inputting it into the large language model, lacking hierarchical management based on the update frequency and lifecycle of different contextual information. Consequently, relatively stable information such as role settings and domain knowledge may be repeatedly constructed and transmitted during multiple model invocations, increasing context length and token consumption. Simultaneously, as historical dialogues grow, early role setting information is easily diluted by subsequent content, causing the agent's role characteristics to weaken or shift during long dialogues.
[0006] On the other hand, existing multi-agent collaborative methods typically employ either a fixed-order invocation or a free-flowing dialogue approach. While the fixed-order approach ensures a structured process, it struggles to dynamically adjust the speaking order based on different discussion topics and to address important controversies that arise during the discussion. Free-flowing dialogue or fixed-round debate, while increasing the degree of interaction freedom, lacks clear agenda constraints and speaking sequence control, and may still result in multiple rounds of repeated debate even without substantial disagreements, leading to increased model invocations and computational resource consumption. Therefore, existing technologies struggle to simultaneously balance the structured nature of the discussion process with the ability to dynamically and deeply discuss key controversial issues.
[0007] Furthermore, in multi-agent discussions, different experts may arrive at differing judgments or conflicting recommendations regarding the same technical issue. Existing technologies typically lack a mechanism to automatically identify disagreements based on generated statements and select relevant experts to continue targeted debates according to specific points of contention. Some multi-agent debate methods employ pre-set fixed participants and fixed rounds, making it difficult to dynamically determine which agents should continue participating based on the content of the disagreements, easily leading to repetitive statements with low relevance to the points of contention.
[0008] Meanwhile, multi-topic, multi-agent workshops typically involve continuous large language model calls and lengthy processing procedures. In the event of network interruptions, service failures, or server restarts, if the system only saves the final results and not the current topic, current speaking position, or completed speaking records, the workshop often needs to re-execute the completed model calls after it resumes. This not only increases computational resources and model call costs but also makes it difficult to ensure that the workshop content remains continuous with the content before the interruption.
[0009] Furthermore, the discussion results generated by large language models are typically output in natural language text format. Due to the inherent non-determinism of large language model output, even under the same task requirements, the output format may differ. When subsequent systems need to further extract information such as consensus, disagreements, suggestions, matters requiring clarification, or action plans, the free-text format of discussion minutes is not conducive to stable parsing and structured storage, and also increases the difficulty for subsequent solution generation, data analysis, and decision support modules to automatically process the discussion results.
[0010] Therefore, how to hierarchically manage role information, domain knowledge, and dialogue history during multi-agent collaborative discussions to reduce contextual redundancy in long dialogues and maintain consistency among agent roles; how to controllably arrange the speaking order of multiple agents based on the discussion agenda and dynamically select relevant agents to trigger cross-debates based on semantic differences in existing speeches; and how to achieve accurate recovery after a discussion is interrupted and improve the structured output and parsing capabilities of discussion results have become problems to be solved in existing multi-agent collaborative discussion technologies. Summary of the Invention
[0011] In view of this, the purpose of this invention is to provide a multi-agent collaborative discussion method, system and storage medium based on hierarchical context and disagreement-driven approach, so as to improve the context management capability, discussion process controllability and dispute resolution capability of multi-agents in multi-topic, multi-expert and multi-round speaking scenarios, reduce the problem of repeated debates in the absence of substantial disagreement and repeated execution of completed model calls after discussion is interrupted, and improve the continuity, structure and subsequent processing capability of discussion results.
[0012] To achieve the above objectives, the present invention provides the following technical solution: In one possible implementation, a multi-agent collaborative discussion method based on hierarchical context and divergence-driven approaches is provided, including: The process involves acquiring the discussion topic, participating agent configuration information, and discussion data related to the discussion topic; establishing a hierarchical context for each participating agent; the hierarchical context includes at least a role setting layer, a knowledge base layer, and a dialogue history layer; wherein the role setting layer stores the role configuration information of the corresponding participating agent; the knowledge base layer stores domain knowledge information related to the discussion topic and is shared by multiple participating agents; and the dialogue history layer updates the generated speech content as the discussion progresses. An agenda is constructed based on the discussion topic, and multiple participating agents are sorted according to the priority of expert directions corresponding to the discussion topic to obtain the agent speaking sequence for the current topic. The current agent to speak is determined sequentially according to the agent's speaking sequence. The role setting layer, the knowledge base layer, the current dialogue history layer, and the task instructions corresponding to the current topic are constructed as input data for the speaking model. The large language model is called to generate the speaking content of the current agent to speak, and the dialogue history layer is updated using the speaking content. After the preset basic speaking completion conditions are met, semantic divergence detection is performed on the speaking content of multiple participating agents generated under the current topic to obtain divergence detection results used to characterize whether there is a divergence of opinion. The divergence detection results include at least the divergence existence state and the divergence focus corresponding to the existence of a divergence of opinion. When the divergence detection result indicates the existence of a divergence of opinion and the preset debate triggering condition is met, at least two target debate agents are determined from the participating agents who have already spoken based on the divergence focus. The divergence focus, the existing speaking content related to the divergence focus, and the hierarchical context corresponding to each target debate agent are constructed as debate model input data. The large language model is called to generate cross-debate content for each target debate agent regarding the divergence focus. Based on the statements already generated under the current topic, and in conjunction with the cross-debate content when cross-debate is triggered, the discussion results corresponding to the current topic are generated.
[0013] In one possible implementation, The role setting layer, knowledge base layer, and dialogue history layer are maintained separately according to different lifecycles; The role setting layer is established when the corresponding participating intelligent agent is initialized, and maintains at least one of the following during the discussion: role description, professional field, experience background and speaking constraints. The knowledge base layer is constructed at the start of the current workshop session based on the workshop topic and is shared by multiple participating agents during the current workshop session; The dialogue history layer is updated using a progressive sliding window. When the number of generated messages does not exceed a preset message count threshold, the corresponding message content is retained. When the number of generated messages exceeds the preset message count threshold, at least a portion of the historical messages that exceed the sliding window are compressed, while the original content of at least a portion of the recent messages located within the sliding window is retained.
[0014] In one possible implementation, The agenda includes at least one discussion topic, and each discussion topic includes at least a topic title and corresponding discussion points; Based on the discussion topic, a corresponding expert direction priority list is determined, and the speaking sequence of each participating agent is determined based on the matching relationship between the direction label corresponding to each participating agent and the expert direction priority list; The speaking sequence of the intelligent agents includes at least a host intelligent agent and multiple professional intelligent agents. The host intelligent agent generates guiding remarks for the current topic before the multiple professional intelligent agents, and generates a corresponding topic summary after the professional intelligent agents' speeches on the current topic and the cross-debate when the conditions are met.
[0015] In one possible implementation, The semantic divergence detection of the statements made by multiple participating agents under the current topic includes: The speech content generated by multiple participating intelligent agents in response to the current topic is used as input data for the disagreement detection model. A large language model is called to perform semantic analysis on the multiple speech contents to determine whether there are different judgments and / or conflicting recommendations on the same issue. When a disagreement is detected, the output should include structured disagreement detection data, which should at least include a disagreement presence identifier, the focus of the disagreement, and the identifiers of the parties involved in the disagreement. The preset debate triggering conditions include: The number of participating agents who have spoken on the current topic has reached the preset number; The structured disagreement detection data indicates the existence of identifiable disagreements; and The current topic has not yet undergone cross-debate, or the time interval since the last cross-debate meets the preset interval condition.
[0016] In one possible implementation, Based on the points of contention, target debate agents are identified from the participating agents who have already spoken, including: The corresponding direction matching parameters are determined based on the matching relationship between the divergence focus and the direction labels of each participating agent; The corresponding semantic relevance parameters are determined based on the degree of semantic relevance between the points of disagreement and the speech content generated by each participating agent. The comprehensive relevance of each participating agent to the point of disagreement is determined based on the direction matching parameters and the semantic relevance parameters, and the target debate agent is selected from the participating agents that have already spoken based on the comprehensive relevance. Among them, the participating intelligent agents corresponding to the identifiers of the dissent participants are given priority to be identified as the target debate intelligent agents, and participating intelligent agents with a comprehensive relevance lower than a preset relevance threshold are excluded; The overall relevance is determined based on the weighted result of the direction matching parameter and the semantic relevance parameter; For each discussion topic, set an upper limit on the number of cross-debate rounds and an upper limit on the number of target debate agents per round.
[0017] In one possible implementation, it also includes: During the process of multiple participating intelligent agents speaking according to the speaking sequence of the intelligent agents, a speaking index is maintained to represent the current speaking position, and after the participating intelligent agent finishes speaking, the corresponding speaking content and positioning information are persistently stored. The location information includes at least one of the following: discussion identifier, topic identifier, agent identifier, message sequence identifier, and current speaking position; When the discussion process is interrupted and then resumed, the persistent speech content and the location information are read. Based on the location information, the speech nodes that were completed before the interruption and the corresponding next speech node to be executed are determined. The completed speech content is restored to the dialogue history layer, and the subsequent discussion process continues from the next speech node to be executed.
[0018] In one possible implementation, it also includes: After completing at least one discussion topic, the input data for the minutes generation model is constructed based on the content of the speeches, cross-debate content and / or topic summary under the corresponding topic, and the preset structured data pattern constraints are provided to the large language model to call the large language model to generate structured discussion minutes. The structured meeting minutes shall include at least one of the following: basic meeting information, topic information, discussion summary, core conclusions, consensus information, disagreement information, recommendations, and matters to be clarified; The summary data output by the large language model is parsed sequentially according to at least two levels of parsing strategy. If the previous level of parsing fails, the next level of parsing is automatically executed, and the successfully parsed structured seminar minutes are persistently stored. The structured seminar minutes adopt one of the structured data formats, namely JSON, YAML, or XML. When using the JSON format, the data structure of the structured seminar minutes is constrained by JSON Schema.
[0019] In one possible implementation, a multi-agent collaborative discussion system based on hierarchical context and divergence-driven mechanisms is provided, comprising: The context management module is used to build and maintain a hierarchical context for multiple participating intelligent agents. The hierarchical context includes at least a role setting layer, a knowledge base layer, and a dialogue history layer. The role setting layer is used to store the role configuration information of the corresponding participating intelligent agent. The knowledge base layer is used to store domain knowledge information related to the discussion topic and shared by multiple participating intelligent agents. The dialogue history layer is used to update the generated speech content as the discussion progresses. The seminar scheduling module is used to construct an agenda based on the seminar topic, sort multiple participating agents according to the priority of expert directions corresponding to the seminar topic, and determine the agent to speak in order according to the sorting results. The large language model invocation module is used to construct the role setting layer, knowledge base layer, current dialogue history layer, and task instructions corresponding to the current topic of the agent to speak as input data for the speech model, and then invoke the large language model to generate the corresponding speech content. The disagreement detection module is used to perform semantic disagreement detection on the speech content of multiple participating agents under the current topic after the preset basic speech completion conditions are met, in order to determine whether there is a disagreement and the corresponding focus of the disagreement when there is a disagreement. The debate control module is used to determine at least two target debate agents from the participating agents who have already spoken when there are differences of opinion and the preset debate triggering conditions are met, based on the focus of the differences, and to call the large language model to make each of the target debate agents generate cross-debate content around the focus of the differences. The discussion results generation module is used to add the cross-debate content to the dialogue history layer, and generate the discussion results for the current topic based on the speech content corresponding to the current topic and the cross-debate content.
[0020] In one possible implementation, it also includes: The data persistence module is used to store at least one of the following: discussion agenda, participating agent configuration, speaking content, current speaking position, hierarchical context data, and structured discussion minutes; The breakpoint recovery module is used to maintain a speech index that represents the current speaking position during the discussion, and after the discussion is interrupted, it determines the speaking node that was completed before the interruption and the corresponding next speaking node to be executed based on the speaking index and at least one of the topic identifier, agent identifier and message sequence identifier in the persistent speaking record. The speaking content corresponding to the completed speaking node is restored to the dialogue history layer, and the subsequent discussion process is continued from the next speaking node to be executed. The minutes generation module is used to construct input data for the minutes generation model based on at least one of the following: the content of speeches generated during the current discussion, the content of cross-debate, and the summary of topics. It calls the large language model to generate structured discussion minutes according to the constraints of the preset structured data pattern, and performs structured parsing on the minutes data output by the large language model through a multi-level parsing strategy. The front-end display module is used to display at least one of the following: the discussion agenda, the speeches of the participating intelligent agents, and the structured discussion minutes; The streaming output module is used to send the speech content of the participating intelligent agents generated by the large language model to the front-end display module via server push event SSE or WebSocket protocol.
[0021] In one possible implementation, a computer-readable storage medium is provided having a computer program stored thereon, which, when executed by a processor, causes the processor to perform the above-described multi-agent collaborative research method based on hierarchical context and divergence-driven approaches.
[0022] Based on the above technical solutions, the multi-agent collaborative discussion method, system, and storage medium of the present invention, based on hierarchical context and divergence-driven approach, establishes a hierarchical context for each participating agent, including a role setting layer, a knowledge base layer, and a dialogue history layer. It also constructs an agent speaking sequence based on the discussion topic and expert priority, enabling different types of contextual information to be organized and maintained accordingly. Furthermore, it allows multiple participating agents to participate in the discussion in an order matching the current discussion topic. After completing basic speeches, semantic divergence detection is performed on the speeches of multiple participating agents. When a divergence is detected and a preset debate trigger condition is met, the target debate agent is determined based on the focus of the divergence, and cross-debate content is generated around this focus. This allows for further discussion of relevant agents on actual controversial issues, reducing unnecessary model calls caused by using fixed participants or fixed debate processes, and improving the orderliness, relevance, and resource utilization efficiency of the multi-agent collaborative discussion process.
[0023] The present invention has at least the following beneficial effects: By dividing the context of participating agents into a role setting layer, a knowledge base layer, and a dialogue history layer, and maintaining them separately according to different lifecycles, relatively stable role configuration information, domain knowledge information shared within the workshop conversation, and dialogue information that changes dynamically with the workshop process can be managed separately. This reduces redundancy caused by the mixed maintenance of different types of context information and helps maintain the consistency of participating agent role settings and domain knowledge during long-term workshops.
[0024] By using a progressive sliding window to update the dialogue history layer, the earlier historical statements are compressed when the number of statements exceeds a preset threshold, while the original content of recent statements is retained. This allows for the control of the dialogue history length while preserving necessary historical semantic information, reducing the growth in model input size caused by the continuous accumulation of historical statements during long-term, multi-round discussions.
[0025] By prioritizing expert directions based on the discussion theme and determining the speaking sequence of participating agents by combining their direction tags, professional agents that are highly relevant to the current discussion theme or topic can participate in the discussion in a predetermined order. Combined with the guiding remarks and topic summary by the moderator agent, the agenda organization capability and speaking sequence controllability of the multi-agent discussion process can be further enhanced.
[0026] By performing semantic disagreement detection on the speech content of multiple participating agents after the preset basic speech completion conditions are met, and outputting the disagreement existence identifier, disagreement focus, and disagreement participant identifier in a structured manner, different judgments or conflicting recommendations can be identified from the already formed discussion content, thereby providing a basis for whether to conduct cross-debate and on what issues to conduct cross-debate.
[0027] By simultaneously combining the matching relationship between the focus of disagreement and the directional labels of participating agents, as well as the semantic relevance between the focus of disagreement and existing speech content, the comprehensive relevance of each participating agent to the focus of disagreement can be determined. Based on this, target debate agents can be selected, which can make the agents participating in cross-debate highly relevant to the actual disputed issues and reduce invalid or repetitive speeches generated by agents with low relevance participating in the debate. By limiting the number of debate rounds and the number of agents participating in each round, the number of model calls can be further controlled.
[0028] By maintaining the speaking index corresponding to the current speaking position during the sequential speaking process of the agents, and persistently storing the speaking content and positioning information such as discussion identifier, topic identifier, agent identifier, and message order identifier, the completed speaking nodes and the next speaking node to be executed can be accurately identified after the discussion is interrupted, and the subsequent discussion can continue from the corresponding position. This reduces the repeated execution of large language model calls that have already been completed when the interruption is resumed, and improves the continuity and recovery efficiency of the discussion process.
[0029] By generating structured discussion minutes based on the content of speeches, cross-debates, and / or topics, and by using structured data schemas such as JSON Schema, YAML Schema, or XML Schema to constrain the output of the large language model, the discussion results can be expressed according to a predetermined data structure. This facilitates the subsequent storage, retrieval, and further processing of information such as consensus, disagreements, suggestions, and matters to be clarified by the system.
[0030] By setting at least two levels of parsing strategies for the minutes data output by large language models, and automatically adopting the next level of parsing strategy when the previous level fails, the fault tolerance of nondeterministic model output in the structured parsing process can be improved, thereby increasing the usability and persistence success rate of structured seminar minutes.
[0031] By modularizing functions such as context management, discussion scheduling, large language model invocation, disagreement detection, debate control, breakpoint recovery, minutes generation, and data persistence, and by streaming the model-generated speech content through SSE or WebSocket protocols, the continuous execution, result display, and data management of multi-agent discussion processes can be supported, thereby improving the overall feasibility of multi-agent collaborative discussion systems. Attached Figure Description
[0032] Figure 1 This is a schematic diagram of the overall architecture of the multi-agent collaborative discussion system of the present invention; Figure 2 This is a schematic diagram of the three-layer context model structure of the present invention; Figure 3 This is a schematic diagram of the multi-agent sequential speech control process of the present invention; Figure 4 This is a schematic diagram of the breakpoint resume mechanism of the present invention; Figure 5 This is a schematic diagram of the JSON Schema structure of the structured minutes of this invention. Detailed Implementation
[0033] The present invention will be further described in detail below with reference to the accompanying drawings and specific embodiments. It should be understood that the following embodiments are only used to illustrate the technical solutions of the present invention, and are not intended to limit the scope of protection of the present invention. Without departing from the technical concept of the present invention, equivalent substitutions, combinations, or modifications made by those skilled in the art based on this specification can all be considered as embodiments of the present invention.
[0034] In this embodiment, the "participating intelligent agent" refers to a virtual expert intelligent agent built based on a large language model and configured with corresponding role information; the "discussion topic" refers to the overall problem addressed in a collaborative discussion; the "discussion agenda" refers to the specific discussion items divided according to the discussion topic; the "hierarchical context" refers to the context information used when calling the large language model to generate the participating intelligent agents' speeches, which is managed according to different information types and lifecycles; the "disagreement" refers to different participating intelligent agents forming different judgments on the same issue, conflicting recommendations, or different technical route choices; and the "cross-debate" refers to, after detecting the disagreement, selecting some participating intelligent agents related to the focus of the disagreement to continue supplementary arguments around the focus of the disagreement.
[0035] This invention employs hierarchical management of contextual information used in multi-agent discussions, and arranges the speaking order of multiple participating agents based on a preset agenda and expert priority. After the initial speeches are completed, it detects discrepancies based on the content of the speeches already generated by the participating agents, and selects agents related to the focus of the discrepancy for cross-debate when preset conditions are met. This ensures that the multi-agent discussion process has both process controllability and the ability to dynamically and deeply discuss controversial issues. Furthermore, this invention can also restore the discussion location after interruption through a speech index and persistent data, and generate structured discussion minutes according to a preset structure.
[0036] I. System Overall Architecture like Figure 1As shown, a multi-agent collaborative discussion system based on hierarchical context and divergence-driven architecture of the present invention may include a data persistence layer 101, a large language model invocation layer 102, a three-layer context management layer 103, a discussion scheduling engine layer 104, and a front-end presentation layer 105.
[0037] The data persistence layer 101 is used to store data generated or used during collaborative discussions. The data may include at least one of the following: discussion topic, discussion agenda, participating agent configuration, domain knowledge data, participating agent speech content, current discussion status, speaking position data, and structured discussion minutes.
[0038] In one implementation, the data persistence layer 101 includes speech record data, expert configuration data, and structured minutes data. Each speech record can be associated with a corresponding discussion identifier, discussion topic, participating agent, speaking order, and speech content for use in subsequent context updates, discussion recovery, and minutes generation.
[0039] The large language model call layer 102 is used to encapsulate the large language model call interface, and construct the hierarchical context output by the three-layer context management layer 103 and the current task instructions generated by the discussion scheduling engine layer 104 as model input data, and send them to the large language model to obtain the speech content, disagreement detection results, cross-debate content or structured discussion minutes of the corresponding participating agents.
[0040] The large language model calling layer 102 can adapt to one or more large language models, and its specific model type is not limited. In one embodiment, the large language model calling layer 102 is also provided with an SSE streaming output adapter to continuously send the text content generated step by step by the large language model to the front-end display layer 105.
[0041] The three-layer context management layer 103 is used to construct and maintain the hierarchical context used by participating agents in the current discussion. The hierarchical context includes a role setting layer, a knowledge base layer, and a dialogue history layer. Each context layer has different information content and a maintenance lifecycle.
[0042] The discussion scheduling engine layer 104 serves as the control layer for the collaborative discussion process. It is used to perform tasks such as discussion agenda management, determining the speaking order of participating agents, controlling the invocation of participating agents, detecting disagreements, triggering cross-debates, maintaining speaking positions, and generating structured discussion minutes.
[0043] In one implementation, the discussion scheduling engine layer 104 may include an agenda manager, a multi-agent invocation controller, a disagreement detection and debate control unit, a breakpoint state maintenance unit, and a minutes generator.
[0044] The agenda manager is used to construct the discussion agenda based on the discussion topic and determine each discussion topic and its discussion points; the multi-agent invocation controller is used to determine the speaking sequence of agents based on the priority of expert directions and to trigger the corresponding participating agents to speak in sequence according to the speaking sequence; the disagreement detection and debate control unit is used to determine whether there is a disagreement based on the multiple participating agents' speeches that have been generated, and to determine the target debate agent when the preset debate triggering conditions are met; the breakpoint state maintenance unit is used to maintain the current discussion topic and the current speaking position; and the minutes generator is used to generate structured discussion minutes based on the speaking content generated during the discussion.
[0045] The front-end presentation layer 105 is used to receive user input and display the discussion process. The front-end presentation layer 105 may include a discussion configuration interface, an agenda display interface, a participating agent speech display interface, and a structured discussion minutes display interface. When using SSE streaming output, the front-end presentation layer 105 can render the speeches of the corresponding participating agents in real time while the large language model continuously generates text.
[0046] When performing a seminar task, the user inputs or confirms the seminar topic and participating agent configuration through the front-end display layer 105; the seminar scheduling engine layer 104 constructs the agenda according to the seminar topic and determines the speaking order of the participating agents; the three-layer context management layer 103 constructs the corresponding hierarchical context for the agent to speak; the large language model invocation layer 102 invokes the large language model based on the hierarchical context and the current task instruction to generate the speaking content of the agent to speak; the generated speaking content is updated to the dialogue history layer and saved to the data persistence layer 101; after the basic speech is completed, the seminar scheduling engine layer 104 further performs divergence detection and cross-debate processing, and forms a structured seminar summary after the seminar is completed.
[0047] Two- or three-layer context model like Figure 2 As shown, this invention divides the contextual information of the large language model that needs to be input during collaborative discussion into a role setting layer, a knowledge base layer, and a dialogue history layer, and maintains them according to their respective lifecycles.
[0048] The role setting layer is used to store role configuration information related to the corresponding participating intelligent agent. The role configuration information may include at least one of the following: role name, professional direction, knowledge scope, experience background, speaking style, and output constraints.
[0049] For example, in a technical solution demonstration scenario, participating intelligent agents may include a meeting host intelligent agent, an overall architecture intelligent agent, a core technology intelligent agent, a security and compliance intelligent agent, a cost control intelligent agent, and an implementation and maintenance intelligent agent; in a corporate strategic planning scenario, participating intelligent agents may include a meeting host intelligent agent, a strategic management intelligent agent, an industry analysis intelligent agent, a financial planning intelligent agent, and a risk management intelligent agent.
[0050] The role setting layer can be constructed during the initialization of participating agents. In the current workshop session, the role setting layer of the corresponding participating agent usually remains unchanged, thereby enabling the same participating agent to maintain a relatively stable professional direction and expression constraints in multiple rounds of speaking.
[0051] The knowledge base layer is used to store domain knowledge information related to the current discussion topic.
[0052] The domain knowledge information can come from at least one of the following: user-provided data, pre-configured knowledge bases, and data obtained by calling the knowledge extraction module according to the discussion topic.
[0053] For example, in discussing the upgrade path after enterprise capability assessment, the knowledge base layer can include basic enterprise information, capability assessment data, scores for each capability dimension, strengths and weaknesses analysis, benchmarking analysis data, current capability level, target capability level, capability gap, and target construction requirements.
[0054] For technical solution demonstration scenarios, the knowledge foundation layer can include technical specification documents, candidate technical solutions, competitor analysis data, and industry standard documents; for project review scenarios, the knowledge foundation layer can include project plans, feasibility analysis data, and resource constraints.
[0055] The knowledge foundation layer can be built once at the start of the current workshop session and shared by multiple participating agents. This eliminates the need to rebuild domain knowledge data identical to the workshop topic for each participating agent.
[0056] The dialogue history layer is used to save the speeches made by participating agents during the current discussion and is dynamically updated as the discussion progresses.
[0057] In one implementation, the dialogue history layer is maintained using a progressive sliding window mechanism.
[0058] Set a preset threshold N for the number of messages. When the number of currently generated messages does not exceed N, the complete content of the corresponding message can be saved in the dialogue history layer; when the number of generated messages exceeds N, at least some of the earlier messages located before the recent sliding window are compressed, and the complete content of the most recent N messages is retained.
[0059] For example, when N is set to 6, the complete text of the 6 most recent speeches by participating agents can be retained, while previous speeches can be converted into brief historical summaries. These historical summaries may include the identifiers of the participating agents and the main content of their respective speeches.
[0060] In one specific implementation, a preset number of characters can be extracted from early speeches to form compressed information. For example, the first M characters of each speech can be retained and combined with the corresponding participating agent identifier to form a historical summary.
[0061] In another implementation, a large language model can be used to perform semantic summarization processing on early statements before the sliding window to form a corresponding compressed summary.
[0062] By using the above method, the size of the complete historical text can be limited as the dialogue history continues to grow, while ensuring that subsequent participating agents can still obtain the main information from previous discussions.
[0063] When calling a large language model to generate the speech of a participating agent, the model input data can be constructed in the order of "role setting layer - knowledge base layer - dialogue history layer - current task instruction".
[0064] The role setting layer defines the professional identity and expression boundaries of the agent currently speaking; the knowledge base layer provides basic facts and domain data related to the current discussion topic; the dialogue history layer provides the previously formed discussion process; and the current task instruction is used to limit the discussion topics and specific discussion requirements that the agent currently speaking needs to focus on.
[0065] III. Agenda-based Multi-Agent Timing Seminar Process like Figure 3 As shown, the present invention controls the timing of speech of multiple participating intelligent agents based on a preset agenda.
[0066] First, obtain the seminar configuration. The seminar configuration includes at least the seminar topic and the configuration information of the participating agents, and may also include background materials provided by the user, seminar type, and other seminar parameters.
[0067] The discussion agenda is constructed based on the discussion theme. The discussion agenda may include one or more discussion topics, and each discussion topic may include a topic title and at least one discussion point.
[0068] For example, in the discussion on the path of enterprise intelligent manufacturing upgrade, multiple discussion topics can be set up, such as "path to improve the level of production automation" and "strategies to make up for the shortcomings in supply chain management capabilities".
[0069] After the discussion agenda is formed, a priority list of expert directions is determined according to the discussion topic or type. Then, multiple participating agents are sorted according to their direction tags to form the speaking sequence of agents corresponding to the current discussion topic.
[0070] For example, for technical solution demonstration seminars, the priority of expert directions can be set as meeting moderation, overall architecture, core technology, security and compliance, cost control, and implementation and maintenance; for corporate strategic planning seminars, the priority of expert directions can be set as meeting moderation, strategic management, industry analysis, financial planning, and risk management.
[0071] The speaking sequence of the agent can be pre-configured according to the actual discussion type, and is not limited to the specific order mentioned above.
[0072] Regarding the current discussion topic, the meeting facilitator agent is first identified as the agent to speak, and an opening speech is generated using a large language model. This opening speech can combine the current discussion topic, relevant data from the knowledge base layer, and key points of the discussion, explaining the background of the current problem and proposing specific questions requiring analysis by multiple specialized agents.
[0073] Subsequently, the scheduling engine layer 104 determines the professional agents as the current agents to speak according to the agent speaking sequence.
[0074] For each agent currently waiting to speak, the three-layer context management layer 103 reads the role setting layer, the knowledge base layer shared in the current seminar, and the dialogue history layer at the current moment corresponding to the agent, and together with the task instructions corresponding to the current seminar topic, constructs the input data for the speaking model.
[0075] The large language model invocation layer 102 invokes the large language model based on the speech model input data to generate the speech content of the current speech agent.
[0076] After each participating agent finishes speaking, the corresponding speech content is written to the data persistence layer 101 and added to the dialogue history layer, so that subsequent participating agents can obtain the previously generated speech information.
[0077] Once all the pre-defined professional agents corresponding to the current discussion topic have completed their basic statements, the discussion will proceed to the disagreement detection phase.
[0078] If there are no disagreements that need further attention, the meeting chair agent can generate a summary of the topics based on the statements already made by the various professional agents under the current discussion topic.
[0079] If a disagreement is detected and the preset debate triggering conditions are met, the cross-debate stage will begin first. After the cross-debate is completed, the meeting moderator agent will synthesize the basic statements and cross-debate content to generate a topic summary.
[0080] After completing the current discussion topic, you can move on to the next discussion topic and repeat the above process of speaking in sequence, checking for differences, and summarizing, until all discussion topics are completed.
[0081] IV. Disagreement Detection and Cross-Debate Mechanism After multiple specialized agents have completed their basic statements on the current discussion topic, this invention does not perform a fixed number of multi-agent debates, but rather determines whether there are any differences of opinion worthy of further discussion based on the multiple statements that have already been made.
[0082] Specifically, the speech content of multiple participating agents under the current discussion topic is used as input data for the disagreement detection model, and a large language model is called to perform semantic analysis on the speech content to determine whether different participating agents have formed different judgments or conflicting recommendations on the same issue.
[0083] In one implementation, the divergence detection result is represented using structured data and includes at least the divergence state (has_divergence) and the divergence focus. When a specific divergence is detected, it may further include the divergence participant identifier (conflicting_parties).
[0084] For example, the discrepancy detection results can indicate that there are two different technical judgments: "process optimization should be completed before automation transformation" and "process optimization and automation transformation can be carried out simultaneously," and the corresponding issues can be identified as the focus of the discrepancy.
[0085] After obtaining the disagreement detection results, further determine whether the preset debate triggering conditions are met.
[0086] The preset debate triggering conditions may include: the number of participating agents who have completed basic speeches under the current discussion topic reaches a preset number; the divergence detection result indicates that there is an identifiable divergence of opinion; and the current discussion topic has not yet triggered a cross-debate, or the time interval between the current cross-debate and the previous cross-debate meets at least one of the following conditions.
[0087] In one implementation, cross-debate can be triggered when all of the above conditions are met simultaneously. For example, the first cross-debate is triggered when at least three professional agents have spoken, the disagreement detection result indicates that there is a clear disagreement, and the current discussion topic has not yet undergone cross-debate.
[0088] Once it is determined that cross-debate is required, the target debate agent is selected from the participating agents who have already spoken, based on the focus of the disagreement.
[0089] In one implementation, the direction matching parameters can be determined first based on the matching relationship between the divergence focus and the direction labels of each participating agent. For example, when the divergence focus mainly involves cybersecurity issues, the participating agent with the direction label "Network and Security" can obtain a higher direction matching parameter.
[0090] Subsequently, semantic correlation parameters are determined based on the degree of semantic correlation between the points of disagreement and the speech content already generated by each participating agent.
[0091] The comprehensive relevance of each participating agent to the point of disagreement can be calculated based on the direction matching parameters and semantic relevance parameters, and the target debate agent can be determined according to the comprehensive relevance.
[0092] In one specific implementation, the overall relevance can be calculated as follows: Overall relevance = Directional matching parameter × 0.4 + Semantic relevance parameter × 0.6.
[0093] The weights described above are merely one feasible example. In other implementations, different weights can be set based on the discussion topic, the number of agents, or the actual scheduling strategy.
[0094] When the disagreement detection results already include direct disagreement participants, the direct disagreement participants can be given priority to enter the target debate agent set, and one or more other participating agents can be selected as supplementary debate participants based on the comprehensive relevance.
[0095] When the overall relevance of a participating agent is lower than the preset relevance threshold, it may not be identified as a target debate agent, even if the preset number of target debate agents has not yet reached the maximum number, in order to reduce speeches that are less relevant to the focus of the disagreement.
[0096] In one implementation, each round of cross-debate may select 2-3 target debate agents.
[0097] After identifying the target debate agent, the focus of the disagreement, relevant existing viewpoints, current discussion topics, and the hierarchical context corresponding to the target debate agent are constructed as input data for the debate model, and the large language model is called to generate the corresponding cross-debate content.
[0098] After the cross-debate content is generated, it is added to the dialogue history layer and serves as the data basis for the subsequent speeches of the target debate agent, the summary of the meeting moderator agent, and the generation of structured discussion minutes.
[0099] To prevent cross-debate from expanding indefinitely, the number of debate rounds and the maximum number of participating agents can be further set.
[0100] For example, each discussion topic can be subject to a maximum of two rounds of cross-debate, with no more than three target debate agents participating in each round. When the preset limit for the number of debate rounds is reached or the disagreements no longer meet the conditions for continuing the debate, the cross-debate will terminate, and the meeting facilitator agent will generate a summary of the current discussion topic.
[0101] V. SSE Streaming Output and Resume Download like Figure 4 As shown, during the process of multiple participating intelligent agents generating speeches in sequence, the present invention can also set up streaming output and breakpoint resume mechanism.
[0102] In one implementation, the large language model calling layer 102 uses a server push event (SSE) to send the text generated in real time by the large language model to the front-end display layer 105.
[0103] Each SSE message can include a message type identifier and corresponding message content. Message types can include token, status, done, and error, etc. The front-end presentation layer 105 renders the speech of the currently participating agent step by step based on the received messages.
[0104] In order to restore the current discussion process in the event of network interruption, browser closure, service failure or server restart, the system maintains speaking position data for the current discussion process.
[0105] In one implementation, current_expert_index is maintained to indicate the position of the currently executing or next-to-be-executed participating agent in the current agent's speaking sequence.
[0106] The system can also maintain current_agenda_index to indicate the position of the currently executing discussion topic.
[0107] Each time a participating agent finishes speaking, the agent's speech content and corresponding location information are written to the data persistence layer 101, and the corresponding speaking position is updated.
[0108] The speech record may include fields such as discussion_id or session_id, expert_id, content, message_order, and message_meta. The message_meta may also include topic_idx and other information used to locate the discussion position.
[0109] In one implementation, the data used for breakpoint recovery may include session_id, current_expert_index, current_agenda_index, discussion status, collected_speeches, interrupted_at, and context_snapshot at the time of interruption.
[0110] When the discussion process is interrupted and then resumed, the system reads the persisted discussion state and speaking records, and determines the interruption point based on current_expert_index and / or topic_idx, expert_id, or message_order in the last speaking record.
[0111] Subsequently, the completed speeches are restored to the dialogue history layer, and the next speech node to be executed is determined, from which the subsequent discussion continues.
[0112] For example, suppose the agent's speaking sequence includes expert 0, expert 1, expert 2, and expert 3. When expert 0 and expert 1 have finished speaking, and expert 2 is interrupted while speaking, the system saves the completed speaking content of expert 0 and expert 1, as well as their current speaking positions.
[0113] After resuming the discussion, the completed speeches of Expert 0 and Expert 1 are reloaded to the dialogue history layer, and the unfinished speech of Expert 2 is re-executed according to the saved speech position. Then, the discussion process of Expert 3 and subsequent discussions continues without regenerating the speeches of Expert 0 and Expert 1.
[0114] In another implementation, instead of maintaining a separate current_expert_index, the last completed message can be determined based on the message_order in the message record, and the next message node to be executed can be determined accordingly.
[0115] Therefore, the specific index fields of the breakpoint recovery mechanism can be set according to the system data structure. Its core lies in using the persisted speech results and speech positions to determine the completed processing nodes and the next processing nodes to be executed.
[0116] VI. Generation of Structured Seminar Minutes like Figure 5 As shown, after completing one or more discussion topics, a structured discussion summary can be generated based on the speeches of participating agents, cross-debate content, and topic summaries formed during the discussion process.
[0117] In one implementation, a JSON Schema is used to define the target data structure for the structured seminar minutes, and the JSON Schema is added to the model input data as a constraint for the minutes generation task.
[0118] Structured meeting minutes can include fields such as title, meeting_info, background, full_summary, topics, overall_conclusions, action_plan, and risk_items.
[0119] Each topic field corresponds to a discussion topic and can further include subfields such as topic, discussion_summary, core_conclusions, consensus, diversity, recommendations, and pending.
[0120] Among them, discussion_summary is used to record the main discussion content of the current discussion topic; core_conclusions is used to record the core conclusions formed on the current discussion topic; consensus is used to record the consensus reached by different participating agents; diversity is used to record the differences of opinion that have not been completely eliminated; recommendations are used to record the suggestions formed based on the discussion; and pending is used to record issues that still need further confirmation.
[0121] The action_plan can record follow-up matters based on the discussion results according to different priorities; the risk_items can record the risks that may exist when implementing the corresponding recommendations.
[0122] When calling the large language model to generate minutes, the speaking data, cross-debate data, and topic summary of the current seminar are combined with JSON Schema to construct the input data for the minutes generation model, and the large language model is constrained to output minutes data according to the corresponding structure.
[0123] Considering the inherent uncertainty in the results generated by large language models, multi-level structured parsing can be performed after obtaining the model output.
[0124] In one implementation, you can first try to directly parse the JSON output of the large language model; if direct parsing fails, extract the JSON content from the Markdown code block and parse it again; if you still cannot complete the overall JSON parsing, perform structured extraction on the output text according to preset fields, and set default values for some non-critical missing fields or mark the missing fields as incomplete.
[0125] When no valid structured data can be obtained from any level of structured parsing, the corresponding raw_text field can be retained to avoid the loss of the original model output.
[0126] In another implementation, the output of the large language model can be parsed step by step in the order of code block tag matching, complete JSON object matching, and opening and closing bracket matching.
[0127] Both of the above-mentioned multi-level parsing methods are used to improve the success rate of parsing structured minutes under different output formats. The specific parsing order can be set according to the output features of the large language model.
[0128] After parsing is complete, the structured discussion minutes are written into the structured data fields of the data persistence layer 101 so that the subsequent solution generation module, data analysis module or decision support module can read the corresponding fields.
[0129] In one implementation, further constraints can be imposed on certain outputs in the minutes. For example, in a discussion scenario where it is undesirable to introduce uncertain timeframes and investment budgets prematurely, the large language model can be restricted from generating specific time periods and investment amounts in the minutes, and high, medium, and low priorities can be used to indicate the order of events.
[0130] In other application scenarios, time fields such as deadlines can also be set in structured data according to the needs of downstream systems. Therefore, the specific field settings can be adjusted according to the minutes structure requirements corresponding to different seminar tasks. Specific Implementation Example
[0131] This embodiment uses an expert discussion on the upgrade path after a manufacturing enterprise's intelligent manufacturing capability assessment as an example to illustrate the complete execution process of the present invention.
[0132] A manufacturing company has completed a smart manufacturing capability maturity assessment and needs to organize collaborative discussions among smart agents from multiple professional fields based on the assessment results in order to formulate recommendations for subsequent capability upgrades.
[0133] The current discussion topic is "Expert Discussion on the Intelligent Manufacturing Upgrade Path of Company A".
[0134] The system is configured with eight participating intelligent agents, namely the conference host intelligent agent, intelligent manufacturing intelligent agent, industrial engineering intelligent agent, production line automation intelligent agent, software engineering intelligent agent, information security intelligent agent, lean production intelligent agent, and systems engineering intelligent agent.
[0135] In this process, different participating intelligent agents are configured with corresponding professional directions, experience backgrounds, and speaking constraints in the role setting layer.
[0136] The knowledge base layer includes Company A's basic corporate information, intelligent manufacturing capability maturity assessment data, benchmarking analysis data, and target construction requirements.
[0137] For example, Company A has an annual output value of approximately 800 million yuan and about 1,200 employees, with 12 existing production lines. Its overall smart manufacturing capability maturity score is 3.2 / 5.0, with a production capability score of 3.8, a supply chain management score of 2.8, an information integration score of 3.5, and an information security score of 2.5. The company's current goal is to further improve its existing capability level, but there are corresponding capability gaps in supply chain collaboration, information security systems, and data integration.
[0138] The system constructs multiple discussion topics based on the aforementioned discussion theme, including "Pathways to Improve Production Automation Level" and "Strategies to Address Shortcomings in Supply Chain Management Capabilities".
[0139] The following explanation uses "the path to improve the level of production automation" as an example.
[0140] The meeting's facilitator first generated guiding remarks based on the role setting layer, knowledge base layer, and current discussion topics, and then raised discussion questions about how to determine the priority order and corresponding technical paths for automation upgrades of the existing 12 production lines.
[0141] Subsequently, the discussion scheduling engine layer 104 determines the intelligent manufacturing agent, industrial engineering agent, production line automation agent, software engineering agent, information security agent, lean production agent, and other corresponding agents as the current agents to speak, according to the preset expert direction priority.
[0142] The intelligent manufacturing agent proposes to prioritize the automation upgrade of some core production lines based on enterprise assessment data, and adopts relatively low-cost digital transformation solutions for other production lines.
[0143] After making the statement, add it to the dialogue history layer.
[0144] Subsequently, based on the aforementioned statements, the Industrial Engineering Intelligent Agent further analyzed the situation and proposed that before implementing automation upgrades on some production lines, process standardization and value stream analysis should be carried out first.
[0145] The production line automation intelligent agent proposes that for production lines with high process maturity, process optimization and automation equipment integration can be carried out in parallel, rather than adopting a sequential approach of optimizing processes first and then upgrading automation.
[0146] Other participating agents continued to complete their basic statements according to the agent speaking sequence.
[0147] After the basic speeches are completed, the system will construct the speeches of multiple participating agents under the current discussion topic as input data for the disagreement detection model.
[0148] Through semantic analysis, the large language model determined that the industrial engineering agent and the production line automation agent had differing opinions on whether process optimization and automation transformation should be performed sequentially or in parallel during the production line automation upgrade process, and identified this issue as the focus of the disagreement.
[0149] The system further determines that the number of professional agents who have spoken meets the preset number requirement, there are currently identifiable differences of opinion, and the current discussion topic has not yet undergone cross-debate, thus triggering a cross-debate.
[0150] Based on the focus of the disagreement, the directional labels of each participating agent, and the semantic relevance of their existing statements, the industrial engineering agent and the production line automation agent were identified as the direct participants in the disagreement, and the lean manufacturing agent was selected as the third target debate agent.
[0151] During the cross-debate, the Industrial Engineering Agent further explained that directly implementing automation on low-maturity production lines might perpetuate existing inefficient processes; the Production Line Automation Agent pointed out that for production lines with higher process maturity, a parallel approach could be used to shorten the overall transformation cycle; and the Lean Manufacturing Agent further proposed determining transformation strategies based on the process maturity of different production lines.
[0152] Based on the above cross-debate, a discussion was held on adopting differentiated automation upgrade methods according to the maturity of production line processes. For example, for production lines with high process maturity, process optimization and automation can be promoted in parallel; for production lines with low process maturity, process optimization can be prioritized.
[0153] After the cross-debate, the meeting moderator summarizes the current discussion topics by combining the basic presentations and cross-debate content of the intelligent agents.
[0154] Subsequently, the system followed the same discussion process to handle other discussion topics such as "strategies to address shortcomings in supply chain management capabilities".
[0155] After all the discussion topics are completed, the speeches of the participating agents, the content of cross-debates, and the topic summaries generated from each discussion topic will be used as input data for the minutes generation model, and a complete structured discussion minutes will be generated based on JSON Schema.
[0156] The structured discussion minutes can record the discussion summary, core conclusions, consensus, diversity, recommendations, and pending items for each discussion topic, and form an overall action plan and risk items. Example
[0157] This embodiment uses the expert demonstration of a data center migration technology solution as an example to further illustrate the applicability of the present invention to different research fields.
[0158] The seminar topic was "Demonstration of Technical Routes for Data Center Migration".
[0159] The participating agents include the conference host agent, the overall architecture agent, the network and security agent, the storage and database agent, and the cost and implementation agent.
[0160] The role setting layer stores the professional direction and speaking constraints corresponding to the aforementioned participating intelligent agents.
[0161] The knowledge base layer includes a description of the existing data center architecture, business downtime window constraints, and comparative data on two candidate migration technology routes. For example, the business downtime window is required to be no more than 4 hours.
[0162] The seminar agenda included two topics: “Technology Route Selection” and “Migration Risk Control”.
[0163] Regarding the topic of "Technology Route Selection," each participating intelligent agent gave a basic presentation in the following order: meeting moderation, overall architecture, network and security, storage and database, and cost and implementation.
[0164] After the basic speeches are completed, the system performs divergence detection on the speeches of multiple participating agents and detects that the network and security agent tends to use a physically isolated private network to complete the data migration, while the cost and implementation agent tends to reuse the existing public network and combine it with an encrypted tunnel for migration. The two parties have a difference of opinion on the migration network technology route.
[0165] The system identifies the differences in these technical approaches as the focus of the disagreement and selects the network and security agent and the cost and implementation agent as the target debate agents to conduct cross-debate.
[0166] After the cross-debate is completed, the meeting moderator will summarize the corresponding speeches to form a topic summary and continue to work on subsequent discussion topics.
[0167] After all discussion topics have been completed, the corresponding discussion minutes are generated using the same structured minutes generation mechanism as in Example 1.
[0168] Therefore, it is evident that the hierarchical context management, sequential speech control, disagreement detection, target debate agent selection, and breakpoint resumption mechanisms of this invention do not rely on specific professional fields. After changing the specific data in the role setting layer and knowledge base layer, it can be applied to technical solution demonstrations, project reviews, corporate strategic planning, policy consultation, and other discussion scenarios requiring collaborative analysis from multiple professional directions.
[0169] VIII. Alternative Implementation Methods and System Implementation The specific implementation of the above embodiments can also be adjusted according to the actual application scenario.
[0170] For compressing the dialogue history layer, character truncation can be used to form a short summary, or a large language model can be called to perform semantic summarization on early statements in order to further preserve the core ideas in early statements.
[0171] The sequence of agent speeches can be determined by prioritizing expert directions, or dynamically based on the current discussion topic and existing speeches. For example, the next agent to speak can be determined based on the semantic relevance of candidate agents to the current topic and any uncovered areas of expertise.
[0172] The output of the large language model can be sent to the front end via SSE or through communication methods such as WebSocket. When using WebSocket, users can also perform operations such as pausing, skipping the current speech, or inserting user notes during the discussion.
[0173] The location information used for breakpoint recovery can be current_expert_index, message_order, or a combination of the current discussion topic and the participant agent identifier.
[0174] Structured seminar minutes can be in JSON format, or other structured data formats such as YAML or XML, depending on the requirements of downstream interfaces.
[0175] Disagreement detection can employ a large language model to perform semantic analysis on the statements of multiple participating agents, or it can convert the statements of different participating agents into text embedding vectors and determine whether there are differences of opinion by calculating the similarity between the vectors corresponding to different statements. When using the vector method, the viewpoint of the corresponding participating agent can be identified as a candidate disagreement viewpoint if the similarity is below a preset threshold.
[0176] The method described in this invention can be executed by a corresponding multi-agent collaborative discussion system. The system may include at least one of the following modules: context management module, discussion scheduling module, large language model invocation module, disagreement detection module, debate control module, data persistence module, breakpoint recovery module, minutes generation module, and front-end display module.
[0177] The module comprises the following components: Context Management, which constructs the role setting layer, knowledge base layer, and dialogue history layer; Discussion Scheduling, which constructs the agenda and determines the speaking sequence of agents; Large Language Model Invocation, which invokes the large language model based on the hierarchical context and current task instructions; Disagreement Detection, which determines the disagreement detection result based on the speeches of multiple participating agents under the current discussion topic; Debate Control, which identifies the target debate agent based on the focus of disagreement and controls cross-debate; Breakpoint Recovery, which restores interrupted discussions based on speaking position data and persistent speeches; and Minutes Generation, which generates structured discussion minutes.
[0178] The present invention also provides a computer-readable storage medium storing a computer program that, when executed by a processor, causes the processor to perform the aforementioned multi-agent collaborative research method based on hierarchical context and divergence-driven approach.
[0179] It should be noted that the context layer name, number of agents, expert direction priority, sliding window size, comprehensive relevance weight, relevance threshold, number of cross-debate participants, number of cross-debate rounds, data field name, and structured minutes field used in the above embodiments are only used to illustrate one or more specific implementations of the present invention, and are not intended to limit the scope of protection of the present invention.
[0180] Without changing the basic technical concept of "hierarchically managing context information at different lifecycles, organizing basic speeches by multiple participating agents based on the discussion agenda, and then selecting relevant participating agents for cross-debate based on the differences in viewpoints in the basic speeches," those skilled in the art can adjust the above parameters, data structures, and processing order according to the specific discussion scenario.
Claims
1. A multi-agent collaborative discussion method based on hierarchical context and divergence-driven approach, characterized in that, include: The process involves acquiring the discussion topic, participating agent configuration information, and discussion data related to the discussion topic; establishing a hierarchical context for each participating agent; the hierarchical context includes at least a role setting layer, a knowledge base layer, and a dialogue history layer; wherein the role setting layer stores the role configuration information of the corresponding participating agent; the knowledge base layer stores domain knowledge information related to the discussion topic and is shared by multiple participating agents; and the dialogue history layer updates the generated speech content as the discussion progresses. An agenda is constructed based on the discussion topic, and multiple participating agents are sorted according to the priority of expert directions corresponding to the discussion topic to obtain the agent speaking sequence for the current topic. The current agent to speak is determined sequentially according to the agent's speaking sequence. The role setting layer, the knowledge base layer, the current dialogue history layer, and the task instructions corresponding to the current topic are constructed as input data for the speaking model. The large language model is called to generate the speaking content of the current agent to speak, and the dialogue history layer is updated using the speaking content. After the preset basic speaking completion conditions are met, semantic divergence detection is performed on the speaking content of multiple participating agents generated under the current topic to obtain divergence detection results used to characterize whether there is a divergence of opinion. The divergence detection results include at least the divergence existence state and the divergence focus corresponding to the existence of a divergence of opinion. When the divergence detection result indicates the existence of a divergence of opinion and the preset debate triggering condition is met, at least two target debate agents are determined from the participating agents who have already spoken based on the divergence focus. The divergence focus, the existing speaking content related to the divergence focus, and the hierarchical context corresponding to each target debate agent are constructed as debate model input data. The large language model is called to generate cross-debate content for each target debate agent regarding the divergence focus. Based on the statements already generated under the current topic, and in conjunction with the cross-debate content when cross-debate is triggered, the discussion results corresponding to the current topic are generated.
2. The multi-agent collaborative discussion method based on hierarchical context and divergence-driven approach according to claim 1, characterized in that, The role setting layer, knowledge base layer, and dialogue history layer are maintained separately according to different lifecycles; The role setting layer is established when the corresponding participating intelligent agent is initialized, and maintains at least one of the following during the discussion: role description, professional field, experience background and speaking constraints. The knowledge base layer is constructed at the start of the current workshop session based on the workshop topic and is shared by multiple participating agents during the current workshop session; The dialogue history layer is updated using a progressive sliding window. When the number of generated messages does not exceed a preset message count threshold, the corresponding message content is retained. When the number of generated messages exceeds the preset message count threshold, at least a portion of the historical messages that exceed the sliding window are compressed, while the original content of at least a portion of the recent messages located within the sliding window is retained.
3. The multi-agent collaborative discussion method based on hierarchical context and divergence-driven approach according to claim 1, characterized in that, The agenda includes at least one discussion topic, and each discussion topic includes at least a topic title and corresponding discussion points; Based on the discussion topic, a corresponding expert direction priority list is determined, and the speaking sequence of each participating agent is determined based on the matching relationship between the direction label corresponding to each participating agent and the expert direction priority list; The speaking sequence of the intelligent agents includes at least a host intelligent agent and multiple professional intelligent agents. The host intelligent agent generates guiding remarks for the current topic before the multiple professional intelligent agents, and generates a corresponding topic summary after the professional intelligent agents' speeches on the current topic and the cross-debate when the conditions are met.
4. The multi-agent collaborative discussion method based on hierarchical context and divergence-driven approach according to claim 1, characterized in that, The semantic divergence detection of the statements made by multiple participating agents under the current topic includes: The speech content generated by multiple participating intelligent agents in response to the current topic is used as input data for the disagreement detection model. A large language model is called to perform semantic analysis on the multiple speech contents to determine whether there are different judgments and / or conflicting recommendations on the same issue. When a disagreement is detected, the output should include structured disagreement detection data, which should at least include a disagreement presence identifier, the focus of the disagreement, and the identifiers of the parties involved in the disagreement. The preset debate triggering conditions include: The number of participating agents who have spoken on the current topic has reached the preset number; The structured disagreement detection data indicates the existence of identifiable disagreements; and The current topic has not yet undergone cross-debate, or the time interval since the last cross-debate meets the preset interval condition.
5. The multi-agent collaborative discussion method based on hierarchical context and divergence-driven approach according to claim 4, characterized in that, Based on the points of contention, target debate agents are identified from the participating agents who have already spoken, including: The corresponding direction matching parameters are determined based on the matching relationship between the divergence focus and the direction labels of each participating agent; The corresponding semantic relevance parameters are determined based on the degree of semantic relevance between the points of disagreement and the speech content generated by each participating agent. The comprehensive relevance of each participating agent to the point of disagreement is determined based on the direction matching parameters and the semantic relevance parameters, and the target debate agent is selected from the participating agents that have already spoken based on the comprehensive relevance. Among them, the participating intelligent agents corresponding to the identifiers of the dissent participants are given priority to be identified as the target debate intelligent agents, and participating intelligent agents with a comprehensive relevance lower than a preset relevance threshold are excluded; The overall relevance is determined based on the weighted result of the direction matching parameter and the semantic relevance parameter; For each discussion topic, set an upper limit on the number of cross-debate rounds and an upper limit on the number of target debate agents per round.
6. The multi-agent collaborative discussion method based on hierarchical context and divergence-driven approach according to claim 1, characterized in that, Also includes: During the process of multiple participating intelligent agents speaking according to the speaking sequence of the intelligent agents, a speaking index is maintained to represent the current speaking position, and after the participating intelligent agent finishes speaking, the corresponding speaking content and positioning information are persistently stored. The location information includes at least one of the following: discussion identifier, topic identifier, agent identifier, message sequence identifier, and current speaking position; When the discussion process is interrupted and then resumed, the persistent speech content and the location information are read. Based on the location information, the speech nodes that were completed before the interruption and the corresponding next speech node to be executed are determined. The completed speech content is restored to the dialogue history layer, and the subsequent discussion process continues from the next speech node to be executed.
7. The multi-agent collaborative discussion method based on hierarchical context and divergence-driven approach according to claim 1, characterized in that, Also includes: After completing at least one discussion topic, the input data for the minutes generation model is constructed based on the content of the speeches, cross-debate content and / or topic summary under the corresponding topic, and the preset structured data pattern constraints are provided to the large language model to call the large language model to generate structured discussion minutes. The structured meeting minutes shall include at least one of the following: basic meeting information, topic information, discussion summary, core conclusions, consensus information, disagreement information, recommendations, and matters to be clarified; The summary data output by the large language model is parsed sequentially according to at least two levels of parsing strategy. If the previous level of parsing fails, the next level of parsing is automatically executed, and the successfully parsed structured seminar minutes are persistently stored. The structured seminar minutes adopt one of the structured data formats, namely JSON, YAML, or XML. When using the JSON format, the data structure of the structured seminar minutes is constrained by JSON Schema.
8. A multi-agent collaborative discussion system based on hierarchical context and divergence-driven mechanisms, characterized in that, include: The context management module is used to build and maintain a hierarchical context for multiple participating intelligent agents. The hierarchical context includes at least a role setting layer, a knowledge base layer, and a dialogue history layer. The role setting layer is used to store the role configuration information of the corresponding participating intelligent agent. The knowledge base layer is used to store domain knowledge information related to the discussion topic and shared by multiple participating intelligent agents. The dialogue history layer is used to update the generated speech content as the discussion progresses. The seminar scheduling module is used to construct an agenda based on the seminar topic, sort multiple participating agents according to the priority of expert directions corresponding to the seminar topic, and determine the agent to speak in order according to the sorting results. The large language model invocation module is used to construct the role setting layer, knowledge base layer, current dialogue history layer, and task instructions corresponding to the current topic of the agent to speak as input data for the speech model, and then invoke the large language model to generate the corresponding speech content. The disagreement detection module is used to perform semantic disagreement detection on the speech content of multiple participating agents under the current topic after the preset basic speech completion conditions are met, in order to determine whether there is a disagreement and the corresponding focus of the disagreement when there is a disagreement. The debate control module is used to determine at least two target debate agents from the participating agents who have already spoken when there are differences of opinion and the preset debate triggering conditions are met, based on the focus of the differences, and to call the large language model to make each of the target debate agents generate cross-debate content around the focus of the differences. The discussion results generation module is used to add the cross-debate content to the dialogue history layer, and generate the discussion results for the current topic based on the speech content corresponding to the current topic and the cross-debate content.
9. The multi-agent collaborative discussion system based on hierarchical context and divergence-driven approach according to claim 8, characterized in that, Also includes: The data persistence module is used to store at least one of the following: discussion agenda, participating agent configuration, speaking content, current speaking position, hierarchical context data, and structured discussion minutes; The breakpoint recovery module is used to maintain a speech index that represents the current speaking position during the discussion, and after the discussion is interrupted, it determines the speaking node that was completed before the interruption and the corresponding next speaking node to be executed based on the speaking index and at least one of the topic identifier, agent identifier and message sequence identifier in the persistent speaking record. The speaking content corresponding to the completed speaking node is restored to the dialogue history layer, and the subsequent discussion process is continued from the next speaking node to be executed. The minutes generation module is used to construct input data for the minutes generation model based on at least one of the following: the content of speeches generated during the current discussion, the content of cross-debate, and the summary of topics. It calls the large language model to generate structured discussion minutes according to the constraints of the preset structured data pattern, and performs structured parsing on the minutes data output by the large language model through a multi-level parsing strategy. The front-end display module is used to display at least one of the following: the discussion agenda, the speeches of the participating intelligent agents, and the structured discussion minutes; The streaming output module is used to send the speech content of the participating intelligent agents generated by the large language model to the front-end display module via server push event SSE or WebSocket protocol.
10. A computer-readable storage medium having a computer program stored thereon, characterized in that, When the computer program is executed by the processor, the processor performs the multi-agent collaborative research method based on hierarchical context and divergence-driven approach as described in any one of claims 1-7.
