Multi-agent information processing method and device, equipment and storage medium

Multiple expert agents are screened through neural network model and vector retrieval technology, and combined with historical routing information to dynamically adjust the weight, solving the accuracy of user intention recognition and routing, and achieving efficient information processing and dialogue quality improvement.

CN120372006APending Publication Date: 2025-07-25BAIDU (CHINA) CO LTD
View PDF 0 Cites 2 Cited by

Patent Information

Application Number
CN202510375265.8
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-03-26
Publication Date
2025-07-25

AI Technical Summary

Technical Problem

In the multi-expert agent framework, how to accurately identify user intentions and efficiently route to the most suitable expert agent to avoid irrelevant or misinformation transmission, affecting the quality of conversations and work efficiency.

Method used

The neural network model and vector search technology are used to generate a collection of candidate agents through the classification model, and the target agent is selected based on historical routing information, and the decision is made using a weighted scoring or voting mechanism, and the weight is dynamically adjusted to optimize the decision results.

Benefits of technology

It improves the coverage and accuracy of user input, improves the quality of conversations and work efficiency, reduces single-point misjudgment, and enhances the flexibility and accuracy of the system.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120372006A_ABST
    Figure CN120372006A_ABST
Patent Text Reader

Abstract

The invention provides an information processing method and device based on multiple agents, equipment and a storage medium, relates to the technical field of computers, in particular to the technical fields of artificial intelligence, deep learning, routing decision and the like, and can be used for application scenes such as generative search, document intelligent editing, intelligent assistants, virtual assistants and intelligent e-commerce. According to the specific implementation scheme, natural language input in any form provided by a target object is received; sending the natural language input to the classification model to obtain a plurality of candidate agents output by the classification model so as to construct a first candidate agent set; querying a candidate agent corresponding to at least one similar input of the natural language input in a historical routing set to obtain a second candidate agent set; screening out a target agent meeting a preset condition from the two sets; sending the natural language input to the target agent to obtain a processing result of the target agent for the natural language input; and outputting the processing result to the target object.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present disclosure relates to the field of computer technology, especially to the fields of artificial intelligence, deep learning, routing decision-making, etc., and can be used in application scenarios such as generative search, intelligent document editing, intelligent assistants, virtual assistants, intelligent e-commerce, etc. It is especially applicable to multiple scenarios such as intelligent customer service, voice dialogue robots, automated question answering systems, and operation and maintenance systems. Background Art

[0002] With the continuous development of large model technology, multi-expert agent frameworks are being increasingly widely adopted in various application scenarios. Within this framework, each "expert agent" focuses on a specific field or task, thus being able to efficiently solve professional problems in their respective fields.

[0003] This way of division of labor and cooperation improves the efficiency and accuracy of handling complex tasks. Summary of the Invention

[0004] The present disclosure provides a multi-agent based information processing method, apparatus, device, and storage medium.

[0005] According to one aspect of the present disclosure, there is provided a multi-agent based information processing method, including:

[0006] Receiving natural language input in any form provided by a target object;

[0007] Sending the natural language input to a classification model to obtain multiple candidate agents output by the classification model, so as to construct a first candidate agent set; and,

[0008] Querying candidate agents corresponding to at least one similar input of the natural language input in a historical routing set to obtain a second candidate agent set;

[0009] Screening out target agents that meet preset conditions from the first candidate agent set and the second candidate agent set;

[0010] Sending the natural language input to the target agent to obtain a processing result of the target agent for the natural language input;

[0011] Outputting the processing result to the target object.

[0012] According to another aspect of the present disclosure, there is provided a multi-agent based information processing apparatus, including:

[0013] A receiving module, configured to receive natural language input in any form provided by a target object;

[0014] A building module for sending a natural language input to a classification model to obtain multiple candidate agents output by the classification model, so as to build a first set of candidate agents; and,

[0015] A query module for querying, in a historical routing set, candidate agents corresponding to at least one similar input of the natural language input to obtain a second set of candidate agents;

[0016] A screening module for screening out target agents that meet preset conditions from the first set of candidate agents and the second set of candidate agents;

[0017] A sending module for sending the natural language input to the target agent to obtain a processing result of the target agent for the natural language input;

[0018] An output module for outputting the processing result to a target object.

[0019] According to another aspect of the present disclosure, there is provided an electronic device, including:

[0020] At least one processor; and

[0021] A memory communicatively connected to the at least one processor; wherein,

[0022] The memory stores instructions executable by the at least one processor, and when the instructions are executed by the at least one processor, the at least one processor is enabled to execute any method in the embodiments of the present disclosure.

[0023] According to another aspect of the present disclosure, there is provided a non-transitory computer-readable storage medium storing computer instructions, wherein the computer instructions are used to cause the computer to execute any method in the embodiments of the present disclosure.

[0024] According to another aspect of the present disclosure, there is provided a computer program product, including a computer program, which when executed by a processor, implements any method in the embodiments of the present disclosure.

[0025] It should be understood that the content described in this part is not intended to identify the key or important features of the embodiments of the present disclosure, nor is it used to limit the scope of the present disclosure. Other features of the present disclosure will become easily understood through the following description. BRIEF DESCRIPTION OF THE DRAWINGS

[0026] The drawings are used to better understand the solution and do not constitute a limitation to the present disclosure. Among them:

[0027] Figure 1 is a schematic flowchart of an information processing method based on multiple agents according to an embodiment of the present disclosure;

[0028] Figure 2 is a schematic flowchart of screening target agents through weighted scoring according to an embodiment of the present disclosure;

[0029] Figure 3 is a schematic flowchart of screening target agents through voting according to an embodiment of the present disclosure;

[0030] Figure 4 is a schematic flowchart of optimization when agents cannot be retrieved according to an embodiment of the present disclosure;

[0031] Figure 5 is a schematic flowchart of optimization for newly added agents according to an embodiment of the present disclosure;

[0032] Figure 6 is a schematic overall framework flowchart of an information processing method based on multiple agents according to an embodiment of the present disclosure;

[0033] Figure 7 is a schematic flowchart of a decision-making mechanism according to an embodiment of the present disclosure;

[0034] Figure 8 is a schematic structural diagram of an information processing device based on multiple agents according to an embodiment of the present disclosure;

[0035] Figure 9 is a block diagram of an electronic device for implementing the information processing method based on multiple agents according to an embodiment of the present disclosure. Detailed implementation manners

[0036] The following makes an explanation of exemplary embodiments of the present disclosure with reference to the accompanying drawings. Various details of the embodiments of the present disclosure are included to facilitate understanding, and they should be considered merely exemplary. Therefore, those of ordinary skill in the art should recognize that various changes and modifications can be made to the embodiments described herein without departing from the scope of the present disclosure. Similarly, for clarity and conciseness, descriptions of well-known functions and structures are omitted in the following description.

[0037] Terms such as "first" and "second" in the present disclosure are used to distinguish similar objects and do not necessarily need to describe a specific order or sequence. In addition, the terms "include" and "have" and any variations thereof are intended to cover non-exclusive inclusion. For example, a method, system, product, or device including a series of steps or units does not necessarily have to be limited to those steps or units clearly listed, but may include other steps or units not clearly listed or inherent to these processes, methods, products, or devices.

[0038] With the rapid development of large model technology, more and more multi-expert agents are also being applied in various scenarios to handle complex tasks. Among them, each expert agent can focus on knowledge or skills in a specific field and provide accurate question answers or service suggestions for users through its expertise.

[0039] However, this specialization also introduces new challenges, namely: when a user initiates a question or request, how to accurately identify the user's intention and efficiently route the request to the most suitable expert agent. Once the user's intention fails to be correctly parsed, it may lead to the transmission of irrelevant or incorrect information to the user, thereby affecting the conversation quality and work efficiency.

[0040] In view of this, the embodiments of the present disclosure provide an information processing method based on multi-agents. By simultaneously adopting a neural network model and a vector retrieval technology, agents that can accurately identify user input can be screened out, so as to significantly improve the coverage and accuracy of new user input and enhance the user experience. As Figure 1 shown, it is a schematic flowchart of the information processing method based on multi-agents provided by the embodiments of the present disclosure, mainly including the following content:

[0041] S101, Receive natural language input in any form provided by the target object.

[0042] The natural language input in any form includes but is not limited to text expressions, texts converted from speech, text paragraphs in a specific format, etc. Of course, it can also include image data.

[0043] S102, Send the natural language input to a classification model to obtain multiple candidate agents output by the classification model, so as to construct a first candidate agent set.

[0044] The classification model is a trained deep learning model that can output multiple candidate agents related to the natural language input provided by the target object and use them as the first candidate agent set.

[0045] During implementation, a pre-trained language model with classification capabilities and natural language processing capabilities can be selected as the base model to be trained for the classification model. For example, BERT (Bidirectional Encoder Representations from Transformers, a deep learning model) or other Transformers (a deep learning model) models. By collecting the inputs of multiple target objects in history and their corresponding agent types, after performing deduplication, classification, and noise filtering operations on them, training data samples with agent type labels are formed. Then, based on the obtained training data samples, the pre-trained language model is fine-tuned to obtain a classification model that can input and output potential agent types for any natural language input.

[0046] Among them, deduplication is to deduplicate the queries with a relatively large number of repetitions in the historical inputs (queries) of the target objects, so as to retain a certain amount of queries and their corresponding agent types;

[0047] Classification is to ensure that it is consistent with the classified queries and their corresponding agent types in the database when constructing data training samples;

[0048] Noise filtering is to filter out the queries in the historical inputs of the target objects that are not relevant to the business capabilities provided by the agent.

[0049] In addition, during implementation, when the classification model outputs the predicted agents, it will also output the classification confidence of each predicted agent. The top n agents with the highest classification confidence can be selected as candidate agents. That is, the classification model outputs the agents that are recommended to process the natural language input.

[0050] S103. Query the candidate agents corresponding to at least one similar input of the natural language input in the historical routing set to obtain a second candidate agent set.

[0051] The historical routing set records a large number of natural language inputs processed in the past and their corresponding routing information, that is, which agents these natural language inputs are routed to for processing respectively.

[0052] During implementation, multiple historical natural language inputs similar to the natural language input can be queried in the historical routing set. Based on the obtained multiple historical natural language inputs, multiple candidate agents corresponding to these multiple historical natural language inputs are obtained to obtain a second agent set.

[0053] S104. Screen out the target agents that meet the preset conditions from the first candidate agent set and the second candidate agent set.

[0054] Among them, the preset condition may be: the candidate agent that best matches the requirements expressed by the natural language input provided by the target object. The specific way to measure the matching degree of this matching is not limited in the embodiments of the present disclosure.

[0055] S105. Send the natural language input to the target agent, and obtain the processing result of the target agent for the natural language input.

[0056] After screening out the target agent that meets the preset conditions, route the natural language input to the target agent, so that the target agent processes the natural language input according to its own functions and algorithms.

[0057] S106. Output the processing result to the target object.

[0058] In the embodiments of the present disclosure, when using a classification model to process the natural language input provided by the target object, the generalization ability of the classification model can be utilized. In the case of the lack of exactly the same historical queries, the first candidate agent set for processing the natural language input can still be obtained. By querying the candidate agents corresponding to at least one similar input of the natural language input in the historical routing set, the second candidate agent set can be obtained, which can maximize the utilization of existing historical data, reduce unnecessary errors, reduce the model hallucination of the classification model, and improve the accuracy of screening out the target agent. Therefore, screening out the target agent that meets the preset conditions from the first candidate agent set and the second candidate agent set can combine the respective advantages of the classification model and the historical routing information set, realize the complementary advantages of the classification model and historical data, reduce single-point misjudgment while improving the coverage and accuracy of the natural language input provided by the target object, and ultimately improve the information processing accuracy and user experience.

[0059] In the embodiments of the present disclosure, the target agent that meets the preset conditions can be screened out from the first candidate agent set and the second candidate agent set based on the method of weighted scoring. Weighted scoring is a decision-making method that evaluates and compares different candidate agents by assigning different weights to different criteria or factors. In the embodiments of the present disclosure, the specific process is as Figure 2 shown, including:

[0060] S201. Based on the weights corresponding to the classification model and the weights corresponding to the historical routing set, determine the recommendation values of multiple candidate agents in the first candidate agent set and the second candidate agent set.

[0061] S202. Select the candidate agent with the largest recommendation value as the target agent that meets the preset conditions.

[0062] That is, both the classification model and the historical routing set are assigned their respective weights. These two weights reflect the importance of the classification model's prediction results and historical routing experience when determining the final target agent. The setting of these weights can be dynamically adjusted according to the actual business or usage time. During implementation, a weight test set can be constructed, and the weights of the two can be optimized by testing the loss between the weighted scoring results and the training labels. For example, multiple sets of weights can be pre-designed. Under the settings of these multiple weights through the weight test set, the weighted scoring results corresponding to each set of weights are obtained, and the set of weights closest to the training labels is selected as the final weight to be used.

[0063] During implementation, the recommendation value of the candidate agent can be calculated through weighted calculation, and then the most suitable target agent can be selected to process the natural language input, as shown in formula (1):

[0064] Score(Agent i ) = α × P_BERT(Agent_i) +

[0065] (1 - α) × max(Sim_Faiss(Agent_i)) (1)

[0066] In formula (1), Score(Agent i ) is the recommendation value of the i-th candidate agent in the first candidate agent set and the second candidate agent set obtained; α is the weight corresponding to the classification model; P_BERT(Agent_i) is the classification confidence of the i-th candidate agent in the first candidate agent set; (1 - α) is the weight corresponding to the historical routing set; max(Sim_Faiss(Agent i )) is the similarity between the historical natural language input corresponding to the i-th candidate agent in the second candidate agent set and the natural language input to be processed currently. For the i-th candidate agent, when it is not included in the first candidate agent set, the value of P_BERT(Agent_i) is 0; similarly, when it is not included in the second candidate agent set, the value of max(Sim_Faiss(Agent i )) is 0.

[0067] In the embodiments of the present disclosure, by assigning weights to the classification model and the historical routing set and comprehensively calculating the recommendation value, these two different types of information can be fully integrated to screen out the target agent that meets the preset conditions to process the natural language input, which can avoid the limitations of making decisions relying only on a single information source, and thus improve the dialogue quality and work efficiency.

[0068] In addition, as data accumulates, the reliability and effectiveness of the classification model and the historical routing set also change, and their corresponding weights can be dynamically adjusted to further optimize the decision-making results.

[0069] In some other embodiments, in addition to screening target agents based on the aforementioned weighted scoring method, target agents that meet preset conditions can also be screened from the first candidate agent set and the second candidate agent set based on a voting method. The specific process is as Figure 3 shown, including:

[0070] S301, vote on multiple candidate agents in the first candidate agent set and the second candidate agent set to obtain the vote values of the multiple candidate agents.

[0071] S302, select the candidate agent with the largest vote value as the target agent that meets the preset conditions.

[0072] That is, the classification model will cast the first number of votes for each candidate agent it recommends; similarly, the historical routing set will also cast the second number of votes for each candidate agent it recommends. And the vote value of each candidate agent is the sum of all the votes obtained in the first candidate agent set and the second candidate agent set. Finally, the vote values of all candidate agents are compared, and the candidate agent with the largest vote value is selected as the final target agent.

[0073] In the embodiments of the present disclosure, by using the voting method to screen out the candidate agent with the largest vote value from the first candidate agent set and the second candidate agent set as the target agent that meets the preset conditions, the advantages of the classification model and the historical routing information set are combined, so that the finally screened target agent can process natural language input more accurately.

[0074] In the embodiments of the present disclosure, when using the classification model to process the natural language input provided by the target object, there may be a situation where the corresponding agent type cannot be retrieved, or when querying for similar inputs of the natural language input in the historical routing set, the corresponding agent type cannot be retrieved.

[0075] During implementation, for the above situations, corresponding optimizations can be carried out. The specific optimization process is as Figure 4 shown:

[0076] S401, obtain the maximum classification confidence of each candidate agent from the first candidate agent set; wherein, the classification model is also used to output the classification confidence of multiple candidate agents.

[0077] S402. When the maximum classification confidence is less than the first preset threshold and greater than the second preset threshold, continue to perform the operation of querying candidate agents corresponding to at least one similar input of the natural language input in the historical routing set to obtain a second set of candidate agents.

[0078] That is, obtain the maximum classification confidence of each candidate agent from the first set of candidate agents. The classification confidence refers to the degree of certainty of the classification model about whether a certain agent is suitable for processing the natural language input. The first preset threshold and the second preset threshold are used to judge the reliability of the classification result. The first preset threshold is greater than the second preset threshold.

[0079] When the maximum classification confidence is less than the first preset threshold and greater than the second preset threshold, it means that the classification model cannot very confidently infer a reasonable target agent. The operation of querying candidate agents corresponding to at least one similar input of the natural language input in the historical routing set to obtain a second set of candidate agents can be continued. After that, based on the first set of candidate agents and the second set of candidate agents, the information of the two can be integrated by means such as weighted scoring and voting mechanism to screen out the target agent most suitable for processing the natural language input.

[0080] In the embodiments of the present disclosure, through the judgment mechanism based on classification confidence, when the preliminary result given by the classification model is not very confident, the operation of querying candidate agents corresponding to at least one similar input of the natural language input in the historical routing set to obtain a second set of candidate agents can be continued, and the information of the classification model and the historical routing set can be flexibly used in different situations, which can improve the accuracy and reliability of the routing decision for natural language input.

[0081] S403. When the maximum classification confidence is greater than the first preset threshold, determine the candidate agent corresponding to the maximum classification confidence as the target agent that meets the preset conditions.

[0082] That is, when the maximum classification confidence is greater than the first preset threshold, it means that the classification model has a high degree of certainty that a certain candidate agent can process the natural language input. In this case, the output result of the classification model has a high reliability, and the candidate agent corresponding to this maximum classification confidence can be directly determined as the target agent that meets the preset conditions, without the need to combine historical routing information to obtain a second set of candidate agents for additional screening.

[0083] In the embodiments of the present disclosure, when the maximum classification confidence is greater than the first preset threshold, the candidate agent corresponding to the maximum classification confidence is determined as the target agent that meets the preset conditions, which can make full use of the advantages of the classification model to greatly shorten the time for screening the target agent and improve the efficiency of the target agent in processing natural language input.

[0084] In some embodiments, when a similar input to the natural language input is not found in the historical routing set, a guiding statement is output to guide the target object to clarify the requirements for the agent.

[0085] That is, when a similar input to the natural language input is not found in the historical routing set, at least one round of guiding statements can be provided to the target object to guide the target object to clarify the requirements for the agent. Based on the new information provided by the target object, the classification model and the historical routing set are used again to process the updated natural language input to screen out the most suitable target agent.

[0086] In the embodiments of the present disclosure, when there is no reliable historical data for reference, directly allocating an agent may lead to inaccurate results. By providing guiding statements, the target object can be guided to more clearly describe its own requirements, so as to ensure that the natural language input provided by the target object can be more accurately routed to the most suitable target agent.

[0087] In actual application scenarios, new agents may be added to meet more diverse task requirements. For new agents, due to the lack of historical data or the empty search results, the historical routing set cannot provide effective support. At this time, the process shown in Figure 5 can be adopted for processing:

[0088] S501. For the newly added agent, construct an input sample corresponding to the newly added agent.

[0089] S502. Store the correspondence between the input sample and the newly added agent in the historical routing set.

[0090] That is, in order to be able to accurately identify and call the newly added agent in the process of routing the natural language input to the corresponding newly added agent for processing in the future, it is necessary to construct the corresponding key and core input sample for the newly added agent before the newly added agent goes online. And store the correspondence between the constructed input sample and the newly added agent in the historical routing set, so that when processing the natural language input of the target object in the future, a similar input sample to the natural language input can be searched in the historical routing set. If it is found that the natural language input is similar to a stored input sample, the natural language input can be directly routed to the newly added agent corresponding to the input sample for processing.

[0091] In the embodiments of the present disclosure, the correspondence between the newly added agent and the input sample is stored in the historical routing set, enriching the historical data of the system. As the correspondence between the input sample and the newly added agent accumulates, the historical routing set has a higher reference value for matching various tasks with agents. Correspondingly, the coverage and accuracy of the natural language input for the target object will also increase.

[0092] In the embodiments of the present disclosure, the classification model requires an adaptation and learning process for the new agent, enabling the new agent to enhance its understanding of specific tasks.

[0093] Therefore, for the newly added agent, the weight corresponding to the classification model decreases as the number of input samples of the newly added agent in the historical routing set increases, until it decreases to the target weight.

[0094] During implementation, the historical statements of each agent can be processed into vectors and stored in the vector library. A real-time monitoring system can be built to continuously monitor the number of vectors corresponding to the newly added agent in the vector library. During implementation, multiple thresholds can be set. When the number of vectors reaches the pre-set threshold each time, the weight test process is automatically triggered. By analyzing the input samples of the newly added agent in the historical routing set, the weight corresponding to the classification model is dynamically adjusted to ensure that the weight decreases reasonably as the number of input samples increases.

[0095] In addition, a mechanism for counting the usage frequency of agents can be established to record the frequency of correction of the newly added agent. If the correction frequency of the newly added agent is relatively high within a certain time period, it indicates that its application scenario or data pattern may have changed significantly. At this time, the weight of the classification model needs to be adjusted specifically until the target weight is reached.

[0096] In the embodiments of the present disclosure, for the newly added agent, adjusting the weight corresponding to the classification model according to the number of input samples in the historical routing set can more accurately adjust the weight of the classification model, ensure appropriate attention is given at different stages, and thus improve the accuracy of finally selecting the target agent.

[0097] In some scenarios, there may be a situation where there are multiple target agents that meet the preset conditions, that is, the natural language input of the target object corresponds to the functions of multiple candidate agents, and the scores obtained through the processing of the classification model and the query processing in the historical routing set are relatively close, resulting in them possibly being simultaneously determined as target agents that meet the preset conditions.

[0098] In this case, guiding statements can be output based on the multiple target agents to guide the target object to clarify its requirements for the agent.

[0099] For example, the natural language input provided by the target object contains requests with multiple intents: "I need to complete a certain operation, but I have encountered two related problems. On the one hand, I need to handle new matters; on the other hand, I also want to review the previous records." Eventually, the target agents that meet the preset conditions may include target agent A that focuses on handling new matters and target agent B that focuses on querying historical records. Since their scores are close and it is difficult to make a direct decision, the system calls a large question-and-answer model to output guiding statements to guide the target object to clarify its requirements for the agents.

[0100] Among them, the guiding statement output by the large question-and-answer model can be: "Do you focus on handling new matters or reviewing previous records?" Subsequently, based on the clear feedback of the target object, the target agent that meets the requirements of the target object can be selected.

[0101] In the embodiments of the present disclosure, in the case where there are multiple target agents that meet the preset conditions, by providing guiding statements to the target object to clarify its requirements for the target agents, the most suitable target agent for processing the request can be determined more precisely, thereby improving the accuracy of routing the natural language input to the target agent.

[0102] In some embodiments, in order to improve the efficiency of screening target agents, the natural language input may further include an agent identification field. If there is a valid field value in this field in the natural language input, it is determined that the target object has clearly identified the target agent, and then the agent corresponding to the valid field can be used as the target agent to process the natural language input.

[0103] In summary, the overall process of the multi-agent information processing method provided in the embodiments of the present disclosure is as Figure 6 shown:

[0104] S601, Receive the natural language input provided by the target object.

[0105] S602, Determine whether the natural language input carries an agent identification field with a valid field value. If so, directly route the natural language input to the target agent corresponding to the valid field value, and process the natural language input based on the target agent; if not, continue to execute S603.

[0106] S603, Send the natural language input to the intent layer to obtain the target vector of the natural language input, and process the target vector through a classification model to screen out the Top N candidate agents to obtain the first candidate agent set; and, query the candidate agents corresponding to at least one similar input of the target vector in the historical routing set, and screen out the Top M candidate agents to obtain the second candidate agent set. Among them, both N and M are positive integers greater than 1.

[0107] S604. Input the first candidate agent set and the second candidate agent set selected into the decision-making layer to select target agents that meet the preset conditions.

[0108] S605. Route the natural language input to the selected target agents through the routing layer, so that the target agents can further process the natural language input.

[0109] In the embodiments of the present disclosure, the decision-making process of the decision-making layer is as Figure 7 shown:

[0110] S701. Input the selected Top N candidate agents and the selected Top M candidate agents into the fusion decision-making module in the decision-making layer.

[0111] S702. The fusion decision-making module obtains the optimal weights corresponding to the classification model and the historical routing set respectively.

[0112] S703. The fusion decision-making module performs weighted calculation based on the optimal weights through formula (1) described above to select the final target agents.

[0113] S704. Route the natural language input to the selected target agents through the routing layer, so that the target agents can further process the natural language input.

[0114] In summary, through the multi-agent information processing method provided by the embodiments of the present disclosure, the classification model and the results of the historical routing set are fused to obtain the most likely agent types, so as to balance accuracy and scalability in both new input and known input scenarios.

[0115] Among them, the classification model has a certain generalization ability and can still output target agents for processing the natural language input of the target object even in the absence of exactly the same historical input. The historical routing set can reuse the existing historical data to the greatest extent, that is, the input statements of the target object in history and their corresponding agent types, so as to reduce unnecessary errors and reduce the model hallucination of the classification model. And fusing the classification model and the results of the historical routing set can reduce the risk of mis-distributing agents due to the error of a certain model.

[0116] In addition, some models in the classification model, such as BERT, can improve throughput through methods such as online / offline inference and distributed deployment. When querying at least one similar input of the natural language input in the historical routing set, an efficient vector retrieval can be performed through a method such as Faiss (Facebook AI Similarity Search, a similarity search method), enabling similarity search to be completed in milliseconds for data at the scale of tens of thousands or even millions. In this way, the information processing method based on multi-agent provided by the embodiments of the present disclosure can be extended to more extensive and large-scale application scenarios.

[0117] Based on the same technical concept, an information processing device 800 based on multi-agent is also proposed in the embodiments of the present disclosure, as Figure 8 shown, including:

[0118] A receiving module 801, configured to receive a natural language input in any form provided by a target object;

[0119] A building module 802, configured to send the natural language input to a classification model to obtain a plurality of candidate agents output by the classification model, so as to build a first candidate agent set; and,

[0120] A query module 803, configured to query candidate agents corresponding to at least one similar input of the natural language input in the historical routing set to obtain a second candidate agent set;

[0121] A screening module 804, configured to screen out target agents that meet a preset condition from the first candidate agent set and the second candidate agent set;

[0122] A sending module 805, configured to send the natural language input to the target agent to obtain a processing result of the target agent for the natural language input;

[0123] An output module 806, configured to output the processing result to the target object.

[0124] In some embodiments, the screening module includes:

[0125] A determination unit, configured to determine recommendation values of a plurality of candidate agents in the first candidate agent set and the second candidate agent set based on the weight corresponding to the classification model and the weight corresponding to the historical routing set;

[0126] A first selection unit, configured to select the candidate agent with the largest recommendation value as the target agent that meets the preset condition.

[0127] In some embodiments, the screening module includes:

[0128] A voting unit for voting on multiple candidate agents in the first candidate agent set and the second candidate agent set to obtain the vote values of the multiple candidate agents;

[0129] A second selection unit for selecting the candidate agent with the largest vote value as the target agent that meets the preset conditions.

[0130] In some embodiments, it further includes a preprocessing module for:

[0131] Obtaining the maximum classification confidence of each candidate agent from the first candidate agent set; wherein, the classification model is further used to output the classification confidence of the multiple candidate agents;

[0132] In the case where the maximum classification confidence is less than the first preset threshold and greater than the second preset threshold, continue to trigger the query module to execute the operation of querying the candidate agents corresponding to at least one similar input of the natural language input in the historical routing set to obtain the second candidate agent set.

[0133] In some embodiments, it further includes:

[0134] A determination module for, in the case where the maximum classification confidence is greater than the first preset threshold, determining the candidate agent corresponding to the maximum classification confidence as the target agent that meets the preset conditions.

[0135] In some embodiments, it further includes:

[0136] A first output module for, in the case where no similar input of the natural language input is found in the historical routing set, outputting a guiding statement to guide the target object to clarify the requirements for the agent.

[0137] In some embodiments, it further includes an optimization module for:

[0138] Constructing an input sample corresponding to the newly added agent for the newly added agent;

[0139] Storing the correspondence between the input sample and the newly added agent in the historical routing set.

[0140] In some embodiments, for the newly added agent, the weight corresponding to the classification model decreases as the number of input samples of the newly added agent in the historical routing set increases until it decreases to the target weight.

[0141] In some embodiments, it further includes a second output module for:

[0142] In the case where there are multiple target agents that meet the preset conditions, outputting a guiding statement based on the multiple target agents to guide the target object to clarify the requirements for the agent.

[0143] For the descriptions of the specific functions and examples of the modules and sub - modules of the device according to the embodiments of the present disclosure, reference may be made to the relevant descriptions of the corresponding steps in the above - mentioned method embodiments, which will not be elaborated herein.

[0144] In the technical solution of the present disclosure, the acquisition, storage, and application of the user's personal information involved all comply with the provisions of relevant laws and regulations and do not violate public order and good customs.

[0145] According to the embodiments of the present disclosure, the present disclosure also provides an electronic device, a readable storage medium, and a computer program product.

[0146] Figure 9 FIG. shows a schematic block diagram of an exemplary electronic device 900 that can be used to implement the embodiments of the present disclosure. The electronic device is intended to represent various forms of digital computers, such as, for example, a laptop computer, a desktop computer, a workbench, a personal digital assistant, a server, a blade server, a mainframe computer, and other suitable computers. The electronic device can also represent various forms of mobile devices, such as, for example, a personal digital assistant, a cellular phone, a smart phone, a wearable device, and other similar computing devices. The components shown herein, their connections and relationships, and their functions are merely exemplary and are not intended to limit the implementation of the present disclosure described herein and / or claimed.

[0147] As Figure 9 shown, the device 900 includes a computing unit 901, which can execute various appropriate actions and processes according to a computer program stored in a read - only memory (ROM) 902 or a computer program loaded from a storage unit 908 into a random - access memory (RAM) 903. In the RAM 903, various programs and data required for the operation of the device 900 can also be stored. The computing unit 901, the ROM 902, and the RAM 903 are connected to each other via a bus 904. An input / output (I / O) interface 905 is also connected to the bus 904.

[0148] A plurality of components in the device 900 are connected to the I / O interface 905, including: an input unit 906, such as a keyboard, a mouse, etc.; an output unit 907, such as various types of displays, speakers, etc.; a storage unit 908, such as a disk, an optical disc, etc.; and a communication unit 909, such as a network card, a modem, a wireless communication transceiver, etc. The communication unit 909 allows the device 900 to exchange information / data with other devices through a computer network such as the Internet and / or various telecommunication networks.

[0149] The computing unit 901 can be various general-purpose and / or special-purpose processing components with processing and computing capabilities. Some examples of the computing unit 901 include, but are not limited to, a central processing unit (CPU), a graphics processing unit (GPU), various dedicated artificial intelligence (AI) computing chips, various computing units running machine learning model algorithms, a digital signal processor (DSP), and any suitable processor, controller, microcontroller, etc. The computing unit 901 executes the various methods and processes described above, such as the information processing method for multiple agents. For example, in some embodiments, the information processing method for multiple agents can be implemented as a computer software program that is tangibly contained in a machine-readable medium, such as the storage unit 908. In some embodiments, part or all of the computer program can be loaded and / or installed onto the device 900 via the ROM 902 and / or the communication unit 909. When the computer program is loaded into the RAM 903 and executed by the computing unit 901, one or more steps of the information processing method for multiple agents described above can be executed. Alternatively, in other embodiments, the computing unit 901 can be configured to execute the information processing method for multiple agents in any other suitable manner (e.g., by means of firmware).

[0150] Various embodiments of the systems and techniques described above in this document can be implemented in digital electronic circuit systems, integrated circuit systems, field-programmable gate arrays (FPGAs), application-specific integrated circuits (ASICs), application-specific standard products (ASSPs), systems-on-a-chip (SOCs), complex programmable logic devices (CPLDs), computer hardware, firmware, software, and / or combinations thereof. These various embodiments can include: being implemented in one or more computer programs that can be executed and / or interpreted on a programmable system including at least one programmable processor, which can be a special-purpose or general-purpose programmable processor that can receive data and instructions from a storage system, at least one input device, and at least one output device, and transmit the data and instructions to the storage system, the at least one input device, and the at least one output device.

[0151] The program code for implementing the methods of the present disclosure can be written in any combination of one or more programming languages. These program codes can be provided to a processor or controller of a general-purpose computer, a special-purpose computer, or other programmable data processing device, such that when the program codes are executed by the processor or controller, the functions / operations specified in the flowcharts and / or block diagrams are implemented. The program code can be executed entirely on the machine, partially on the machine, as an independent software package partially on the machine and partially on a remote machine, or entirely on a remote machine or server.

[0152] In the context of this disclosure, a machine-readable medium can be a tangible medium that can contain or store a program for use by or in connection with an instruction execution system, apparatus, or device. A machine-readable medium can be a machine-readable signal medium or a machine-readable storage medium. A machine-readable medium can include, but is not limited to, electronic, magnetic, optical, electromagnetic, infrared, or semiconductor systems, apparatus, or devices, or any suitable combination of the foregoing. More specific examples of a machine-readable storage medium would include an electrical connection based on one or more wires, a portable computer diskette, a hard disk, a random access memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or Flash memory), an optical fiber, a portable compact disc read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the foregoing.

[0153] In order to provide interaction with a user, the systems and techniques described herein can be implemented on a computer having: a display device (e.g., a CRT (cathode ray tube) or LCD (liquid crystal display) monitor) for displaying information to the user; and a keyboard and a pointing device (e.g., a mouse or a trackball) by which the user can provide input to the computer. Other kinds of devices can also be used to provide interaction with the user; for example, the feedback provided to the user can be any form of sensory feedback (e.g., visual feedback, auditory feedback, or tactile feedback); and input from the user can be received in any form (including acoustic input, speech input, or tactile input).

[0154] The systems and techniques described herein can be implemented in a computing system including backend components (e.g., as a data server), or a computing system including middleware components (e.g., an application server), or a computing system including frontend components (e.g., a user computer having a graphical user interface or a web browser through which the user can interact with an implementation of the systems and techniques described herein), or a computing system including any combination of such backend components, middleware components, or frontend components. The components of the system can be interconnected by any form or medium of digital data communication (e.g., a communication network). Examples of communication networks include: a local area network (LAN), a wide area network (WAN), and the Internet.

[0155] A computer system can include a client and a server. The client and the server are generally far apart from each other and typically interact through a communication network. The relationship between the client and the server is generated by computer programs running on the respective computers and having a client-server relationship with each other. The server can be a cloud server, can also be a server of a distributed system, or a server incorporating a blockchain.

[0156] It should be understood that the various forms of processes shown above can be used, with steps reordered, added, or deleted. For example, the steps described in this disclosure can be executed in parallel, sequentially, or in a different order, as long as the desired results of the technical solution disclosed in this disclosure can be achieved, and no limitation is imposed herein.

[0157] The above specific embodiments do not constitute a limitation on the scope of protection of this disclosure. Those skilled in the art should understand that various modifications, combinations, sub - combinations, and substitutions can be made according to design requirements and other factors. Any modifications, equivalent substitutions, and improvements made within the principles of this disclosure shall be included within the scope of protection of this disclosure.

Claims

1. An information processing method based on multi - agents, comprising: Receiving a natural language input in any form provided by a target object; Sending the natural language input to a classification model to obtain a plurality of candidate agents output by the classification model, so as to construct a first candidate agent set; And, Querying candidate agents corresponding to at least one similar input of the natural language input in a historical routing set to obtain a second candidate agent set; Screening out target agents that meet preset conditions from the first candidate agent set and the second candidate agent set; Sending the natural language input to the target agent to obtain a processing result of the target agent for the natural language input; Outputting the processing result to the target object.

2. The method according to claim 1, wherein, The screening out target agents that meet preset conditions from the first candidate agent set and the second candidate agent set includes: Based on the weights corresponding to the classification model and the weights corresponding to the historical routing set, determining the recommendation values of a plurality of candidate agents in the first candidate agent set and the second candidate agent set; Selecting the candidate agent with the largest recommendation value as the target agent that meets the preset conditions.

3. The method according to claim 1, wherein The screening out target agents that meet preset conditions from the first candidate agent set and the second candidate agent set includes: Voting on a plurality of candidate agents in the first candidate agent set and the second candidate agent set to obtain the vote values of the plurality of candidate agents; Selecting the candidate agent with the largest vote value as the target agent that meets the preset conditions.

4. The method according to any one of claims 1 - 3, further comprising: Obtaining the maximum classification confidence of each candidate agent from the first candidate agent set; wherein, the classification model is further used to output the classification confidences of the plurality of candidate agents; In the case where the maximum classification confidence is less than a first preset threshold and greater than a second preset threshold, continuing to perform the operation of querying candidate agents corresponding to at least one similar input of the natural language input in the historical routing set to obtain a second candidate agent set.

5. The method according to claim 4, further comprising: In the case where the maximum classification confidence is greater than the first preset threshold, determining the candidate agent corresponding to the maximum classification confidence as the target agent that meets the preset conditions.

6. The method according to any one of claims 1 - 5, further comprising: In the case where no similar input of the natural language input is queried in the historical routing set, outputting a guiding statement to guide the target object to clarify the requirements for the agent.

7. The method according to any one of claims 1 - 6, further comprising: Constructing an input sample corresponding to the new agent; Storing the correspondence between the input sample and the new agent in the historical routing set.

8. The method according to claim 2, wherein For the newly added agent, the weight corresponding to the classification model decreases as the number of input samples of the newly added agent in the historical routing set increases, until it decreases to the target weight.

9. The method according to any one of claims 1-8, further comprising: In the case where there are multiple target agents that meet the preset conditions, based on the multiple target agents, a guiding statement is output to guide the target object to clarify the requirements for the agent.

10. An information processing device based on multiple agents, comprising: A receiving module, configured to receive natural language input in any form provided by a target object; A constructing module, configured to send the natural language input to a classification model to obtain multiple candidate agents output by the classification model, so as to construct a first candidate agent set; And, A query module, configured to query candidate agents corresponding to at least one similar input of the natural language input in a historical routing set to obtain a second candidate agent set; A screening module, configured to screen out target agents that meet the preset conditions from the first candidate agent set and the second candidate agent set; A sending module, configured to send the natural language input to the target agent to obtain a processing result of the target agent for the natural language input; An output module, configured to output the processing result to the target object.

11. An electronic device, comprising: At least one processor; And A memory communicatively connected to the at least one processor; wherein, The memory stores instructions executable by the at least one processor, and the instructions are executed by the at least one processor so that the at least one processor can execute the method according to any one of claims 1-9.

12. A non-transitory computer-readable storage medium storing computer instructions, wherein, The computer instructions are used to cause the computer to execute the method according to any one of claims 1-9.

13. A computer program product, comprising a computer program, where the computer program implements the method according to any one of claims 1-9 when executed by a processor.

Citation Information

Cited By

  • Multi-agent-based information processing method and device, electronic equipment and medium

    CN121279411A

  • Multi-agent based information processing method and device, electronic equipment and medium

    CN121279411B