Search

CN-122019624-A - Task processing method, device, computer equipment, storage medium and product

CN122019624ACN 122019624 ACN122019624 ACN 122019624ACN-122019624-A

Abstract

The application relates to a task processing method, a task processing device, computer equipment, a storage medium and a product. The method comprises the steps of responding to a processing request of a target task, determining the task type of the target task, inquiring a first flow prompt word template corresponding to the task type from a template library based on the task type, generating a first task plan based on the target task and the first flow prompt word template, and performing task processing on the target task based on the first task plan to obtain a first processing result of the target task. By adopting the method, the task processing efficiency can be improved.

Inventors

  • HUANG BIN
  • ZHAO YANG

Assignees

  • 腾讯科技(深圳)有限公司

Dates

Publication Date
20260512
Application Date
20260126

Claims (16)

  1. 1. A method of task processing, comprising: determining a task type of a target task in response to a processing request of the target task; Inquiring a first flow prompt word template corresponding to the task type from a template library based on the task type; Generating a first task plan based on the target task and the first flow prompt word template; And performing task processing on the target task based on the first task plan to obtain a first processing result of the target task.
  2. 2. The method of claim 1, wherein the determining the task type of the target task in response to the processing request for the target task comprises: Responding to a processing request of a target task, and acquiring classification prompt information; And carrying out semantic analysis on the target task through a first large language model based on the classification prompt information to obtain the task type of the target task.
  3. 3. The method of claim 1, wherein the generating a first task plan based on the target task and the first flow hint word template comprises: Filling the target task and the first flow prompt word template into a prompt context template to obtain a prompt context; And generating a first task plan through a second large language model based on the prompt context.
  4. 4. The method of claim 3, wherein said populating the target task and the first flow hint word template to a hint context template to obtain a hint context, comprising: Acquiring an agent list based on the task type; and filling the task type, the agent list, the target task and the first flow prompt word template into a prompt context template to obtain a prompt context.
  5. 5. The method according to claim 1, wherein performing task processing on the target task based on the first task plan to obtain a first processing result of the target task includes: analyzing the first task plan to obtain at least two sub-tasks of the target task; invoking an agent corresponding to each subtask to process each subtask to obtain a processing result of each subtask; And fusing the processing results of the subtasks to obtain a first processing result of the target task.
  6. 6. The method of claim 5, wherein parsing the first task plan results in at least two sub-tasks of the target task, comprising: Analyzing the first task plan to obtain at least two subtasks of the target task and the dependency relationship among the subtasks; the method further comprises the steps of: Determining a dependency graph based on the dependency between the subtasks; And invoking an agent corresponding to each subtask to process each subtask to obtain a processing result of each subtask, wherein the processing result comprises the following steps: and calling the intelligent agent corresponding to each subtask to process each subtask based on the dependency graph to obtain a processing result of each subtask.
  7. 7. The method of claim 6, wherein the calling, based on the dependency graph, the agent corresponding to each subtask to process each subtask to obtain a processing result of each subtask includes: Determining at least one subtask processing chain based on the dependency graph; Invoking corresponding agents according to the processing sequence of the subtasks in each subtask processing chain; Based on the called agent, processing the subtasks in each subtask processing chain to obtain the processing result of each subtask processing chain; the step of fusing the processing results of the subtasks to obtain a first processing result of the target task includes: And fusing the processing results of the subtask processing chains to obtain a first processing result of the target task.
  8. 8. The method of claim 6, wherein the calling, based on the dependency graph, the agent corresponding to each subtask to process each subtask to obtain a processing result of each subtask includes: determining at least one dependency-free subtask based on the dependency graph; Invoking an agent corresponding to each independent subtask, and processing each independent subtask to obtain a processing result of each independent subtask; the step of fusing the processing results of the subtasks to obtain a first processing result of the target task includes: And fusing the processing results of the independent subtasks to obtain a first processing result of the target task.
  9. 9. The method according to any one of claims 1-8, further comprising: monitoring the processing state of the target task; Under the condition that the processing state of the target task is failure, determining a first abnormal condition of the target task; acquiring an exception handling constraint of the first exception condition; adding the exception handling constraint to the first flow prompt word template to obtain a second flow prompt word template; Generating a second task plan based on the target task and the second flow prompt word template; And performing task processing on the target task based on the second task plan to obtain a second processing result of the target task.
  10. 10. The method according to claim 9, wherein the method further comprises: collecting a second abnormal condition corresponding to the task type, wherein the second abnormal condition is an abnormal condition which does not occur; an exception handling constraint for the second exception condition is determined.
  11. 11. The method according to any one of claims 1-8, further comprising: Acquiring a newly added third flow prompt word template; And adding the third flow prompt word template to the template library.
  12. 12. The method of claim 1, wherein the task type is a vertical type including shopping, stock and write codes or a general type including information retrieval, multi-hop information screening, material querying and deep searching.
  13. 13. A task processing device, comprising: The determining module is used for responding to the processing request of the target task and determining the task type of the target task; The query module is used for querying a first flow prompt word template corresponding to the task type from a template library based on the task type; the generation module is used for generating a first task plan based on the target task and the first flow prompt word template; and the processing module is used for performing task processing on the target task based on the first task plan to obtain a first processing result of the target task.
  14. 14. A computer device comprising a memory and a processor, the memory storing a computer program, characterized in that the processor implements the steps of the method of any one of claims 1 to 12 when the computer program is executed.
  15. 15. A computer readable storage medium, on which a computer program is stored, characterized in that the computer program, when being executed by a processor, implements the steps of the method of any of claims 1 to 12.
  16. 16. A computer program product comprising a computer program, characterized in that the computer program, when being executed by a processor, implements the steps of the method of any one of claims 1 to 12.

Description

Task processing method, device, computer equipment, storage medium and product Technical Field The present application relates to the field of computer technologies, and in particular, to a task processing method, a task processing device, a computer device, a storage medium, and a product. Background With the continuous development of computer technology and internet technology, large language models (Large Language Model, LLM) are increasingly being used. Inference actions (Reason Act, reAct) are a structured prompting method that can guide LLM to process tasks in a manner similar to human resolution. ReAct in the task processing process, task planning and task processing are performed autonomously, so that the task processing efficiency is low. Disclosure of Invention In view of the foregoing, it is desirable to provide a task processing method, apparatus, computer device, storage medium, and product that can improve task processing efficiency. In a first aspect, the present application provides a task processing method. The method comprises the steps of responding to a processing request of a target task, determining the task type of the target task, inquiring a first flow prompt word template corresponding to the task type from a template library based on the task type, generating a first task plan based on the target task and the first flow prompt word template, and performing task processing on the target task based on the first task plan to obtain a first processing result of the target task. In a second aspect, the application further provides a task processing device. The device comprises a determining module, a querying module, a generating module and a processing module, wherein the determining module is used for responding to a processing request of a target task and determining the task type of the target task, the querying module is used for querying a first flow prompt word template corresponding to the task type from a template library based on the task type, the generating module is used for generating a first task plan based on the target task and the first flow prompt word template, and the processing module is used for processing the target task based on the first task plan to obtain a first processing result of the target task. In a third aspect, the present application also provides a computer device. The computer equipment comprises a memory and a processor, wherein the memory stores a computer program, and the processor is used for responding to a processing request of a target task and determining the task type of the target task, inquiring a first flow prompt word template corresponding to the task type from a template library based on the task type, generating a first task plan based on the target task and the first flow prompt word template, and performing task processing on the target task based on the first task plan to obtain a first processing result of the target task. In a fourth aspect, the present application also provides a computer-readable storage medium. The computer readable storage medium is stored with a computer program, and when the computer program is executed by a processor, the method comprises the steps of responding to a processing request of a target task, determining the task type of the target task, inquiring a first flow prompt word template corresponding to the task type from a template base based on the task type, generating a first task plan based on the target task and the first flow prompt word template, and processing the target task based on the first task plan to obtain a first processing result of the target task. In a fifth aspect, the present application also provides a computer program product. The computer program product comprises a computer program, and when the computer program is executed by a processor, the method comprises the following steps of determining a task type of a target task in response to a processing request of the target task, inquiring a first flow prompt word template corresponding to the task type from a template library based on the task type, generating a first task plan based on the target task and the first flow prompt word template, and processing the target task based on the first task plan to obtain a first processing result of the target task. The task processing method, the device, the computer equipment, the storage medium and the product firstly respond to the processing request of the target task, determine the task type of the target task, then query a first flow prompt word template corresponding to the task type from a template library based on the task type of the target task, generate a first task plan based on the target task and the first flow prompt word template, and further process the target task based on the first task plan to obtain a first processing result of the target task. Therefore, the task type of the task is determined, then the flow prompt word template corresponding to the task type