Artificial intelligence-based task processing method and device, computer equipment and medium
Through artificial intelligence-based task processing methods, complex tasks are decomposed and processed in sequence, solving the problem of slow task processing response speed in the existing technology, improving efficiency and user experience.
Patent Information
- Application Number
- CN202411661678.4
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-11-19
- Publication Date
- 2025-02-25
AI Technical Summary
The prior art has low response speed when handling complex tasks, which affects the user experience.
Using an artificial intelligence-based task processing method, we use the task request submitted by the user, extract the task data for pre-processing, use the preset large language model to perform task analysis, decompose it into multiple target subtasks, and process it in sequence, and gradually display the task processing results.
It improves the efficiency and accuracy of task processing, reduces user waiting time, provides timely and transparent task progress information, and significantly improves the user experience.
Smart Images

Figure CN119513422A_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the field of artificial intelligence development technology and financial technology, and in particular to artificial intelligence-based task processing methods, devices, computer equipment and storage media. Background Art
[0002] With the rapid development of artificial intelligence technology in many fields such as intelligent dialogue, virtual assistants and customer service, related business systems have been able to handle increasingly complex tasks. These tasks often involve a large amount of data calculation, logical reasoning and information integration, aiming to provide users with more accurate and personalized services. However, when handling these complex tasks, the system faces a significant challenge: the task processing time is long, causing users to wait for a long time to get a complete answer.
[0003] The existing task processing method is usually that after the user submits the task, the system immediately starts calculating and returns the result to the user after all calculations are completed. Although this method can ensure the integrity of the answer, when processing complex tasks, the system often takes a long time to complete due to the large amount of calculation and complex logic. This not only reduces the system's response speed, but also seriously affects the user experience. Summary of the invention
[0004] The purpose of the embodiments of the present application is to propose a task processing method, device, computer equipment and storage medium based on artificial intelligence to solve the technical problem that the existing task processing method has a low response speed when processing complex tasks, which affects the user experience.
[0005] In order to solve the above technical problems, the embodiment of the present application provides a task processing method based on artificial intelligence, which adopts the following technical solutions:
[0006] Determine whether a task request submitted by a user through a front-end interface is received; wherein the task request carries task data;
[0007] If so, extracting the task data from the task request;
[0008] Preprocessing the task data to obtain corresponding target task data;
[0009] Performing task analysis on the target task data based on a preset target large language model to obtain a corresponding task analysis result;
[0010] Generating a plurality of target subtasks including an execution order based on the task analysis result;
[0011] The target subtasks are processed in sequence based on the execution order, and the generated task processing results of the target subtasks are displayed in the front-end interface according to the execution order.
[0012] Furthermore, the step of performing task analysis on the target task data based on the preset target large language model to obtain a corresponding task analysis result specifically includes:
[0013] Performing format conversion processing on the target task data to obtain corresponding designated task data;
[0014] Calling the target large language model;
[0015] Inputting the specified task data into the target large language model;
[0016] The designated task data is task planned and decomposed by the target large language model to obtain a corresponding task analysis result; wherein the task analysis result includes a list of subtasks, a description of each subtask, and an execution order and dependency relationship of each subtask.
[0017] Furthermore, the step of generating a plurality of target subtasks including an execution order based on the task analysis result specifically includes:
[0018] Obtaining a list of the subtasks, a description of each subtask, and an execution order and dependency relationship of each subtask from the task parsing result;
[0019] Generating a corresponding plurality of initial subtasks based on the list of subtasks and the description of each subtask;
[0020] Based on the execution order and dependency relationship of each subtask, the multiple initial subtasks are sorted in execution order to obtain sorted initial subtasks;
[0021] The target subtask is generated based on the sorted initial subtasks.
[0022] Furthermore, the step of preprocessing the task data to obtain corresponding target task data specifically includes:
[0023] Removing irrelevant information from the task data to obtain corresponding first task data;
[0024] Extract key elements from the first task data to obtain corresponding second task data;
[0025] performing standardization processing on the second task data to obtain corresponding third task data;
[0026] The third task data is used as the target task data.
[0027] Furthermore, after the step of sequentially processing each of the target subtasks based on the execution order and displaying the generated task processing results of each of the target subtasks in the front-end interface according to the execution order, it also includes:
[0028] Determine whether all the target subtasks have been processed;
[0029] If yes, obtain the preset message generation strategy;
[0030] Summarizing the task processing results of all the target subtasks based on the message generation strategy to obtain corresponding summary messages;
[0031] The summary message is displayed on the front-end interface.
[0032] Furthermore, the task processing method based on artificial intelligence also includes:
[0033] Constructing a specified task identifier corresponding to the task request;
[0034] Constructing a specified message queue corresponding to the specified task identifier;
[0035] The task processing results of each of the target subtasks are stored in the designated message queue.
[0036] Furthermore, after the step of storing the task processing results of each of the target subtasks in the designated message queue, the method further includes:
[0037] Obtaining a specified timeout period corresponding to the specified message queue;
[0038] Based on the specified timeout period, determining whether the specified message queue meets the cleaning condition;
[0039] If so, clear the specified message queue.
[0040] In order to solve the above technical problems, the embodiment of the present application further provides a task processing device based on artificial intelligence, which adopts the following technical solution:
[0041] A first judgment module is used to judge whether a task request submitted by a user through a front-end interface is received; wherein the task request carries task data;
[0042] An extraction module, configured to extract the task data from the task request;
[0043] A preprocessing module, used to preprocess the task data to obtain corresponding target task data;
[0044] A parsing module, used to perform task parsing processing on the target task data based on a preset target large language model to obtain a corresponding task parsing result;
[0045] A generation module, used to generate a plurality of target subtasks including an execution order based on the task analysis result;
[0046] A processing module is used to process each of the target subtasks in sequence based on the execution order, and display the generated task processing results of each of the target subtasks in the front-end interface according to the execution order.
[0047] In order to solve the above technical problems, the embodiment of the present application further provides a computer device, which adopts the following technical solution:
[0048] Determine whether a task request submitted by a user through a front-end interface is received; wherein the task request carries task data;
[0049] If so, extracting the task data from the task request;
[0050] Preprocessing the task data to obtain corresponding target task data;
[0051] Performing task analysis on the target task data based on a preset target large language model to obtain a corresponding task analysis result;
[0052] Generating a plurality of target subtasks including an execution order based on the task analysis result;
[0053] The target subtasks are processed in sequence based on the execution order, and the generated task processing results of the target subtasks are displayed in the front-end interface according to the execution order.
[0054] In order to solve the above technical problems, the embodiment of the present application further provides a computer-readable storage medium, which adopts the following technical solution:
[0055] Determine whether a task request submitted by a user through a front-end interface is received; wherein the task request carries task data;
[0056] If so, extracting the task data from the task request;
[0057] Preprocessing the task data to obtain corresponding target task data;
[0058] Performing task analysis on the target task data based on a preset target large language model to obtain a corresponding task analysis result;
[0059] Generating a plurality of target subtasks including an execution order based on the task analysis result;
[0060] The target subtasks are processed in sequence based on the execution order, and the generated task processing results of the target subtasks are displayed in the front-end interface according to the execution order.
[0061] Compared with the prior art, the embodiments of the present application have the following beneficial effects:
[0062] The present application first determines whether a task request submitted by a user through a front-end interface is received; wherein the task request carries task data; if so, extracts the task data from the task request; then pre-processes the task data to obtain corresponding target task data; then performs task parsing processing on the target task data based on a preset target large language model to obtain corresponding task parsing results; subsequently generates multiple target subtasks including an execution order based on the task parsing results; finally, processes each of the target subtasks in sequence based on the execution order, and displays the generated task processing results of each of the target subtasks in the front-end interface according to the execution order. After receiving a task request carrying task data submitted by a user through the front-end interface, the present application will pre-process the task data in the task request to obtain target task data, and then perform task analysis on the target task data based on the use of the target large language model to decompose the target task data into multiple target sub-tasks including an execution order, and will automatically and intelligently process each target sub-task in sequence based on the execution order, and display the generated task processing results of each target sub-task in the front-end interface in the execution order, so as to gradually output the intermediate response results of the target sub-tasks to the user in batches, thereby improving the efficiency and accuracy of task processing, reducing user waiting time, and providing users with timely and transparent task progress information, effectively improving the user experience. BRIEF DESCRIPTION OF THE DRAWINGS
[0063] In order to more clearly illustrate the scheme in the present application, a brief introduction is given below to the drawings required for use in the description of the embodiments of the present application. Obviously, the drawings described below are some embodiments of the present application. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying any creative work.
[0064] Figure 1 is an exemplary system architecture diagram to which the present application may be applied;
[0065] Figure 2 A flowchart of an embodiment of an artificial intelligence-based task processing method according to the present application;
[0066] Figure 3 is a structural schematic diagram of an embodiment of an artificial intelligence-based task processing device according to the present application;
[0067] Figure 4 It is a structural diagram of an embodiment of a computer device according to the present application. DETAILED DESCRIPTION
[0068] Unless otherwise defined, all technical and scientific terms used herein have the same meaning as those commonly understood by technicians in the technical field of the present application; the terms used in the specification of the application herein are only for the purpose of describing specific embodiments and are not intended to limit the present application; the terms "including" and "having" and any variations thereof in the specification and claims of the present application and the above-mentioned drawings are intended to cover non-exclusive inclusions. The terms "first", "second", etc. in the specification and claims of the present application or the above-mentioned drawings are used to distinguish different objects, not to describe a specific order.
[0069] Reference to "embodiments" herein means that a particular feature, structure, or characteristic described in conjunction with the embodiments may be included in at least one embodiment of the present application. The appearance of the phrase in various locations in the specification does not necessarily refer to the same embodiment, nor is it an independent or alternative embodiment that is mutually exclusive with other embodiments. It is explicitly and implicitly understood by those skilled in the art that the embodiments described herein may be combined with other embodiments.
[0070] In order to enable those skilled in the art to better understand the solution of the present application, the technical solution in the embodiments of the present application will be clearly and completely described below in conjunction with the accompanying drawings.
[0071] like Figure 1 As shown, the system architecture 100 may include a terminal device 101, a network 102 and a server 103. The terminal device 101 may be a laptop 1011, a tablet computer 1012 or a mobile phone 1013. The network 102 is used to provide a medium for a communication link between the terminal device 101 and the server 103. The network 102 may include various connection types, such as wired, wireless communication links or optical fiber cables, etc.
[0072] The user can use the terminal device 101 to interact with the server 103 through the network 102 to receive or send messages, etc. Various communication client applications can be installed on the terminal device 101, such as web browser applications, shopping applications, search applications, instant messaging tools, email clients, social platform software, etc.
[0073] The terminal device 101 can be any electronic device with a display screen and supporting web browsing. In addition to the laptop computer 1011, tablet computer 1012 or mobile phone 1013, the terminal device 101 can also be an e-book reader, an MP3 player (Moving Picture Experts Group Audio Layer III), an MP4 (Moving Picture Experts Group Audio Layer IV), a laptop computer, a desktop computer, etc.
[0074] The server 103 may be a server that provides various services, such as a background server that provides support for a web page displayed on the terminal device 101 .
[0075] It should be noted that the artificial intelligence-based task processing method provided in the embodiment of the present application is generally executed by a server / terminal device, and accordingly, the artificial intelligence-based task processing device is generally set in the server / terminal device.
[0076] It should be understood that Figure 1 The number of terminal devices, networks and servers in the embodiment is only for illustration. Any number of terminal devices, networks and servers may be provided according to implementation requirements.
[0077] Continue to refer Figure 2 , showing a flowchart of an embodiment of an artificial intelligence-based task processing method according to the present application. According to different requirements, the order of the steps in the flowchart can be changed, and some steps can be omitted. The artificial intelligence-based task processing method provided in the embodiment of the present application can be applied to any scenario where task processing is required, and the artificial intelligence-based task processing method can be applied to products in these scenarios, for example, task processing in the financial insurance field. The artificial intelligence-based task processing method comprises the following steps:
[0078] Step S201, determining whether a task request submitted by a user through a front-end interface is received; wherein the task request carries task data.
[0079] In this embodiment, the task processing method based on artificial intelligence is executed on the electronic device (for example Figure 1The server / terminal device shown in the figure) can obtain task data through a wired connection or a wireless connection. It should be noted that the above-mentioned wireless connection methods may include but are not limited to 3G / 4G / 5G connection, WiFi connection, Bluetooth connection, WiMAX connection, Zigbee connection, UWB (ultra wideband) connection, and other wireless connection methods currently known or developed in the future. The executor of this application is a task processing system, or simply referred to as the system. A user can submit a complex task request carrying task data through the front-end interface of the client corresponding to the system. The above-mentioned task data may be in text form, including detailed descriptions, requirements, constraints, etc. Exemplarily, in the business scenario of task processing in finance and insurance, the above-mentioned task requests may include task requests such as policy inquiries, consultation on claims procedures, and insurance product recommendations.
[0080] Step S202: If yes, extract the task data from the task request.
[0081] In this embodiment, the task data carried in the task request may be extracted by performing information parsing on the task request.
[0082] Step S203, preprocessing the task data to obtain corresponding target task data.
[0083] In this embodiment, the above-mentioned specific implementation process of preprocessing the task data to obtain the corresponding target task data will be further described in detail in subsequent specific embodiments of the present application, and will not be elaborated on here.
[0084] Step S204: performing task analysis processing on the target task data based on a preset target large language model to obtain a corresponding task analysis result.
[0085] In this embodiment, the above-mentioned specific implementation process of performing task analysis processing on the target task data based on the preset target large language model to obtain the corresponding task analysis result will be further described in detail in the subsequent specific embodiments of this application, and will not be elaborated in detail here.
[0086] Step S205: generating a plurality of target subtasks including an execution order based on the task analysis result.
[0087] In this embodiment, the specific implementation process of generating multiple target subtasks including execution order based on the task analysis result will be further described in detail in subsequent specific embodiments of the present application, and will not be elaborated on here.
[0088] Step S206 , processing each of the target subtasks in sequence based on the execution order, and displaying the generated task processing results of each of the target subtasks in the front-end interface according to the execution order.
[0089] In this embodiment, by selecting a suitable execution engine for each target subtask, it can be the above-mentioned target large language model, or it can be another AI model, a service interface, an internal function, etc. Then each target subtask is assigned to the corresponding execution engine for processing in the order of execution. And ensure that each target subtask is correctly assigned and that the execution engine has the resources and permissions required to process the task. After the completion of each target subtask, the corresponding partial result (task processing result) is generated. The partial results can be in the form of text, numbers, images, etc., depending on the type of subtask and the output requirements. Among them, the partial results can be stored in an appropriate location for subsequent processing and combination. Specifically, storage solutions such as databases, file systems, or cloud storage can be used. In addition, the completion results (task processing results) of each target subtask are returned to the user in batches. Specifically, according to the needs and preferences of the user, the task processing results of each target subtask generated can be displayed in the front-end interface in the order of execution using text, reports, visual charts, etc.
[0090] The system breaks down complex requests into multiple phased subtasks and provides batch responses for each subtask based on the use of message queues, so that users can obtain task progress in a timely manner.
[0091] Batch response includes: when processing each subtask, the system gradually generates and pushes partial results. Each batch response corresponds to the progress of a subtask, and users can gradually understand the results of each stage of the task.
[0092] Message queue: The system maintains a message queue for each task ID corresponding to each task request, records the batch responses of each subtask, ensures that messages are pushed in order, and facilitates users to track task progress. Specifically, Redis can be used as the storage engine of the message queue, and the message queue can be managed through rpush and lpop operations.
[0093] The present application first determines whether a task request submitted by a user through a front-end interface is received; wherein the task request carries task data; if so, extracts the task data from the task request; then pre-processes the task data to obtain corresponding target task data; then performs task parsing processing on the target task data based on a preset target large language model to obtain corresponding task parsing results; subsequently generates multiple target subtasks including an execution order based on the task parsing results; finally, processes each of the target subtasks in sequence based on the execution order, and displays the generated task processing results of each of the target subtasks in the front-end interface according to the execution order. After receiving a task request carrying task data submitted by a user through the front-end interface, the present application will pre-process the task data in the task request to obtain target task data, and then perform task analysis on the target task data based on the use of the target large language model to decompose the target task data into multiple target sub-tasks including an execution order, and will automatically and intelligently process each target sub-task in sequence based on the execution order, and display the generated task processing results of each target sub-task in the front-end interface in the execution order, so as to gradually output the intermediate response results of the target sub-tasks to the user in batches, thereby improving the efficiency and accuracy of task processing, reducing user waiting time, and providing users with timely and transparent task progress information, effectively improving the user experience.
[0094] In some optional implementations of this embodiment, step S204 includes the following steps:
[0095] The target task data is format converted to obtain corresponding designated task data.
[0096] In this embodiment, the target task data is converted into a format that can be understood by the target large language model, which may include converting the target task data into a specific encoding method, adding prompt words or context information, and the like.
[0097] The target large language model is called.
[0098] In this embodiment, a matching LLM model can be selected as the target large language model according to the task type and complexity of the task data. Different LLM models may be good at processing different types of tasks, such as text generation, logical reasoning, mathematical calculation, etc.
[0099] The designated task data is input into the target large language model.
[0100] In this embodiment, the designated task data may be sent as a model input to the target large language model, and the target large language model may be requested to perform task planning and decomposition processing on the designated task data.
[0101] The designated task data is task planned and decomposed by the target large language model to obtain a corresponding task analysis result; wherein the task analysis result includes a list of subtasks, a description of each subtask, and an execution order and dependency relationship of each subtask.
[0102] In this embodiment, the target large language model performs task planning and decomposition processing on the input specified task data, and outputs detailed information including task planning and decomposition, that is, the above-mentioned task parsing result. The detailed information including task planning and decomposition may at least include a list of subtasks, a description of each subtask, and the execution order and dependency relationship of each subtask.
[0103] The present application obtains the corresponding designated task data by performing format conversion processing on the target task data; then calls the target large language model; then inputs the designated task data into the target large language model; and subsequently performs task planning and decomposition processing on the designated task data through the target large language model to obtain the corresponding task analysis result. The present application obtains the designated task data by performing format conversion processing on the target task data, and then performs task planning and decomposition processing on the designated task data based on the use of the target large language model, so that the corresponding task analysis results can be generated quickly and accurately, the analysis efficiency of the designated task data is improved, and the accuracy of the generated task analysis results is ensured. This is conducive to the subsequent accurate generation of multiple target subtasks including the execution order based on the obtained task analysis results.
[0104] In some optional implementations, step S205 includes the following steps:
[0105] A list of the subtasks, a description of each subtask, and an execution order and dependency relationship of each subtask are obtained from the task parsing result.
[0106] In this embodiment, the task parsing result returned by the target large language model can be parsed to extract a list of corresponding subtasks, a description of each subtask, and an execution order and dependency relationship of each subtask.
[0107] A plurality of corresponding initial subtasks are generated based on the list of subtasks and the description of each subtask.
[0108] In this embodiment, a plurality of specific initial subtasks may be generated according to the above subtask list, and based on the description of each subtask, it is ensured that each initial subtask has a clear description, expected results and necessary context information.
[0109] Based on the execution order and dependency relationship of each subtask, the multiple initial subtasks are sorted in execution order to obtain sorted initial subtasks.
[0110] In this embodiment, all initial subtasks can be sorted according to the execution order and dependency relationship between each subtask to ensure that all preconditions are met before executing each initial subtask, thereby obtaining sorted initial subtasks, that is, the final target subtasks.
[0111] The target subtask is generated based on the sorted initial subtasks.
[0112] In this embodiment, the generated sorted initial subtasks may be used as the target subtasks.
[0113] The present application obtains the list of subtasks, the description of each subtask, and the execution order and dependency of each subtask from the task analysis result; then generates a corresponding plurality of initial subtasks based on the list of subtasks and the description of each subtask; then sorts the execution order of the plurality of initial subtasks based on the execution order and dependency of each subtask to obtain the sorted initial subtasks; and subsequently generates the target subtask based on the sorted initial subtasks. The present application generates a corresponding plurality of initial subtasks based on the list of subtasks extracted from the task analysis result and the description of each subtask; then sorts the execution order of the plurality of initial subtasks based on the execution order and dependency of each subtask extracted from the task analysis result, thereby achieving rapid and accurate generation of a plurality of target subtasks containing an execution order, improving the accuracy and intelligence of the generated target subtasks.
[0114] In some optional implementations, step S203 includes the following steps:
[0115] The task data is processed to remove irrelevant information to obtain corresponding first task data.
[0116] In this embodiment, the above-mentioned process of removing irrelevant information includes: text cleaning and irrelevant content filtering. Specifically, text cleaning includes: using regular expressions or text processing libraries to identify and delete irrelevant characters in the task description, such as extra spaces, line breaks, special symbols, etc. Irrelevant content filtering includes: identifying and deleting sentences or paragraphs that are irrelevant to the task. Among them, this can be achieved through natural language processing (NLP) technology, such as keyword extraction, sentence similarity calculation, etc. It can also be based on rule-based methods, such as checking whether a sentence contains specific keywords or phrases.
[0117] The first task data is processed to extract key elements to obtain corresponding second task data.
[0118] In this embodiment, the key element extraction process includes keyword extraction, entity recognition and dependency parsing. Specifically, keyword extraction includes: using NLP technology (such as TF-IDF, TextRank and other algorithms) to extract keywords in the task description. These keywords can be nouns, verbs or adjectives, which can summarize the main content and requirements of the task. Entity recognition includes: using named entity recognition (NER) technology to identify entities in the task description, such as names of people, places, organizations, etc. This helps to understand the context and background information of the task. Dependency parsing includes: using dependency syntactic analysis technology to analyze the sentence structure in the task description and identify the dependency relationship between words. This helps to understand the logical relationship and semantic structure in the task.
[0119] The second task data is standardized to obtain corresponding third task data.
[0120] In the present embodiment, the above-mentioned standardization processing includes text formatting, data normalization and unit conversion processing. Specifically, text formatting includes: using a text processing library or a custom formatting function to convert the task description into a unified format, such as a title, paragraph, list, etc. This is helpful for subsequent processing and display. Data normalization includes: using methods such as minimum-maximum normalization and Z-score normalization to normalize the numerical data contained in the task description. Normalization can ensure that the numerical data is comparable in subsequent processing. Unit conversion includes: using a unit conversion library or a custom conversion function to convert different measurement units contained in the task description. This can ensure that the numerical data is consistent in subsequent processing.
[0121] The third task data is used as the target task data.
[0122] The present application obtains the corresponding first task data by removing irrelevant information from the task data; then extracts key elements from the first task data to obtain the corresponding second task data; then standardizes the second task data to obtain the corresponding third task data; and subsequently uses the third task data as the target task data. The present application removes irrelevant information from the task data, extracts key elements, and standardizes the task data, thereby achieving intelligent and accurate preprocessing of the task data, ensuring the data quality of the generated target task data, and providing a reliable data foundation for subsequent task planning and decomposition steps.
[0123] In some optional implementations, after step S206, the electronic device may further perform the following steps:
[0124] Determine whether all the target subtasks have been processed.
[0125] In this embodiment, it is detected whether all target subtasks have been processed. If all target subtasks have been completed, the processing flow of the summary phase is entered; otherwise, the remaining subtasks are processed continuously.
[0126] If yes, get the preset message generation strategy.
[0127] In this embodiment, the strategy content of the message generation strategy includes: generating a summary message that includes the overall execution status of the task, summarizes each stage of the task, points out possible erroneous reasoning and proposes correction suggestions. The summary message only summarizes the message type of response, and does not include thought messages.
[0128] Specifically, for a summary message, the is_final field is true, indicating that the message is a summary message, and there is only one summary message in the message queue. Message types are divided into thought and response. Thought represents the reasoning process of the system, and response represents the response result of the system. The former is usually displayed as a status message for secondary display, and the latter is displayed as a result message for primary display. Between different response messages, the system may insert some thought messages so that users can better understand the reasoning process of the system.
[0129] The task processing results of all the target subtasks are summarized based on the message generation strategy to obtain corresponding summary messages.
[0130] In this embodiment, the task processing results of all target subtasks can be summarized according to the policy content of the message generation policy, so as to generate a corresponding summary message. By summarizing all the response contents corresponding to the target subtasks generated previously, it can help users understand the process and results of task execution more comprehensively.
[0131] The summary message is displayed on the front-end interface.
[0132] In this embodiment, the summary message can be pushed to the corresponding designated message queue. After receiving the summary message during the polling process, the client stops polling and displays the summary message in the front-end interface. Specifically, the client obtains the messages in the message queue by polling to achieve real-time message push until the summary message is received (is_final is true).
[0133] This application determines whether all the target subtasks have been processed; if so, obtains a preset message generation strategy; then summarizes the task processing results of all the target subtasks based on the message generation strategy to obtain a corresponding summary message; and subsequently displays the summary message in the front-end interface. When this application detects that all the target subtasks have been processed, it will intelligently summarize the task processing results of all the target subtasks based on the use of the message generation strategy to obtain a summary message, and will display the summary message in the front-end interface, so that it can help users to more comprehensively understand the process and results of task execution by viewing the summary message, thereby improving the user's experience.
[0134] In some optional implementations of this embodiment, the electronic device may further perform the following steps:
[0135] Construct a specified task identifier corresponding to the task request.
[0136] In this embodiment, after receiving a task request, the system will generate a unique designated task identifier (message_id) corresponding to the task request, which is used to track all related messages and tasks of the task request.
[0137] A specified message queue corresponding to the specified task identifier is constructed.
[0138] In this embodiment, a separate message queue is created for each task ID in advance using a message queue system (such as Redis). The message queue makes it easy for users to track the response content of each batch and ensure that messages are pushed in order for easy management and backtracking. In this embodiment, a unique designated message queue is created for the specified task ID. The designated message queue will be used to store all batch responses to the above task requests. Each batch response contains a message_id field that is used to identify which request the response belongs to.
[0139] The task processing results of each of the target subtasks are stored in the designated message queue.
[0140] In this embodiment, during the task processing of the target subtask, the partial results of each sub-target task can be encapsulated into batch response messages. The batch response message contains multiple fields, such as code (indicating message status), content (specific response content), message_type (message type, such as thought or response), is_final (indicating whether the message is a summary message), etc. Then the generated batch response messages corresponding to each target subtask are pushed to the corresponding designated message queue according to the execution order.
[0141] Among them, the client can obtain these response messages from the specified message queue through polling or long connection. Specifically, the client can poll through the URL to obtain the response message in the message queue. In addition, the client processes the received response messages in sequence and displays the task progress in real time on the front-end interface. Specifically, according to the received batch response messages, the client can gradually display the progress of the task on the page. If the message type is thought, the reasoning process of the system may be displayed in a secondary way; if the message type is response, it is used as the main display content.
[0142] In addition, the system also supports concurrent requests from multiple users. The message_id and message queues of different users do not conflict with each other, ensuring that each user's request is processed independently. By using the batch response mechanism, users can obtain progress information in a timely manner during the execution of complex tasks, reducing waiting time and improving user experience.
[0143] In addition, the system is also equipped with a priority queue mechanism, so that important tasks (such as emergency insurance claims) can be given higher priority and processed first, thus ensuring the efficient processing of critical tasks.
[0144] The present application constructs a designated task identifier corresponding to the task request; then constructs a designated message queue corresponding to the designated task identifier; and subsequently stores the task processing results of each of the target subtasks in the designated message queue. The present application constructs a designated task identifier corresponding to the task request, and then constructs a designated message queue corresponding to the designated task identifier, and then stores the task processing results of each of the target subtasks in the designated message queue, thereby realizing intelligent caching of the task processing results of the target subtask, which is beneficial to the subsequent use of the designated message queue, and realizing the display of the generated task processing results of each target subtask in the front-end interface according to the execution order.
[0145] In some optional implementations of this embodiment, after the step of storing the task processing results of each of the target subtasks in the designated message queue, the electronic device may further perform the following steps:
[0146] Get the specified timeout period corresponding to the specified message queue.
[0147] In this embodiment, a corresponding designated timeout period may be set for a designated message queue according to actual business requirements to ensure that a user can view the response history corresponding to a task request within a period of time.
[0148] Based on the specified timeout period, determine whether the specified message queue meets the cleanup condition.
[0149] In this embodiment, if it is detected that the existence time of the designated message queue exceeds the designated timeout time, it is determined that the designated message queue meets the cleaning condition; otherwise, it is determined that the designated message queue does not meet the cleaning condition.
[0150] If so, clear the specified message queue.
[0151] In this embodiment, if it is detected that the designated message queue meets the cleaning condition, the designated message queue is determined to be in an expired state, and the designated message queue is automatically cleaned up to release memory resources.
[0152] The present application obtains the specified timeout time corresponding to the specified message queue; then based on the specified timeout time, determines whether the specified message queue meets the cleaning condition; if so, cleans up the specified message queue. The present application automatically and intelligently cleans up the specified message queue to release memory resources based on the specified timeout time corresponding to the specified message queue. This can improve the smoothness of the system operation.
[0153] In some optional implementations, the user information obtained is subject to the user's consent and complies with relevant laws and policies.
[0154] In addition, the non-Company software tools or components that appear in the embodiments of the present application are merely examples and do not represent actual use.
[0155] In addition, this application proposes a batch response and post-summary mechanism, which can break down complex tasks into multiple subtasks, gradually output intermediate response results to users, and generate a comprehensive summary after the task is completed, helping users review the progress of the task and provide a reference for subsequent operations. This mechanism reduces user waiting time and improves the transparency of task processing and user experience. This application is particularly suitable for insurance assistant scenarios. When dealing with complex insurance-related businesses, such as policy interpretation, claims process guidance, and insurance product recommendations, the batch response and post-summary mechanism can significantly improve the user experience. Users can get timely feedback during the task execution and get a comprehensive summary after the task is completed, which helps to make more informed decisions.
[0156] Exemplary application cases of insurance assistants may include:
[0157] Scenario Case 1: Interpretation of insurance policy.
[0158] When a user submits a complex policy inquiry, the system splits the question into multiple subtasks: first, the basic terms of the policy are explained, then the specific terms (for example, the insured amount, exemption clauses, etc.) are gradually processed, and after all the terms are interpreted, a summary is generated to help the user understand the policy content as a whole.
[0159] Scenario Case 2: Claims Process Guidance.
[0160] When a user inquires about the steps for claims settlement, the AI assistant breaks down the process into multiple stages, returning a list of required materials, time requirements for different stages, required documents, and finally providing a summary including possible potential issues and solutions.
[0161] Scenario Case 3: Insurance product recommendation.
[0162] The system gradually pushes recommended insurance products based on the user's personal information and needs, first pushing the core product information, then pushing the terms, advantage analysis, etc. Finally, the system provides a summary based on all the recommended content to help users make the final decision.
[0163] It should be understood that the order of execution of the steps in the above embodiment does not necessarily mean the order of execution. The execution order of each process should be determined by its function and internal logic, and should not constitute any limitation on the implementation process of the embodiment of the present invention.
[0164] It should be emphasized that in order to further ensure the privacy and security of the above task processing results, the above task processing results can also be stored in a blockchain node.
[0165] The blockchain referred to in this application is a new application model of computer technologies such as distributed data storage, peer-to-peer transmission, consensus mechanism, encryption algorithm, etc. Blockchain is essentially a decentralized database, a string of data blocks generated by cryptographic methods. Each data block contains a batch of network transaction information, which is used to verify the validity of its information (anti-counterfeiting) and generate the next block. Blockchain can include the underlying blockchain platform, platform product service layer, and application service layer.
[0166] The embodiments of the present application can acquire and process relevant data based on artificial intelligence technology. Among them, artificial intelligence (AI) is the theory, method, technology and application system that uses digital computers or machines controlled by digital computers to simulate, extend and expand human intelligence, perceive the environment, acquire knowledge and use knowledge to obtain the best results.
[0167] AI basic technologies generally include sensors, dedicated AI chips, cloud computing, distributed storage, big data processing technology, operation / interaction systems, mechatronics, etc. AI software technologies mainly include computer vision technology, robotics technology, biometrics technology, speech processing technology, natural language processing technology, and machine learning / deep learning.
[0168] Those skilled in the art can understand that all or part of the processes in the above-mentioned embodiments can be implemented by instructing the relevant hardware through computer-readable instructions, and the computer-readable instructions can be stored in a computer-readable storage medium. When the program is executed, it can include the processes of the embodiments of the above-mentioned methods. Among them, the aforementioned storage medium can be a non-volatile storage medium such as a disk, an optical disk, a read-only memory (ROM), or a random access memory (RAM).
[0169] It should be understood that, although the steps in the flowchart of the accompanying drawings are displayed in sequence as indicated by the arrows, these steps are not necessarily executed in sequence in the order indicated by the arrows. Unless otherwise specified herein, there is no strict order restriction on the execution of these steps, and they can be executed in other orders. Moreover, at least a part of the steps in the flowchart of the accompanying drawings may include multiple sub-steps or multiple stages, and these sub-steps or stages are not necessarily executed at the same time, but can be executed at different times, and their execution order is not necessarily sequential, but can be executed in turn or alternately with other steps or at least a part of the sub-steps or stages of other steps.
[0170] Further references Figure 3 , as a response to the above Figure 2 The present application provides an embodiment of a task processing device based on artificial intelligence. Figure 2 Corresponding to the method embodiment shown, the device can be specifically applied to various electronic devices.
[0171] like Figure 3 As shown, the task processing device 300 based on artificial intelligence described in this embodiment includes: a first judgment module 301, an extraction module 302, a pre-processing module 303, a parsing module 304, a generation module 305 and a processing module 306. Among them:
[0172] The first judgment module 301 is used to judge whether a task request submitted by a user through a front-end interface is received; wherein the task request carries task data;
[0173] An extraction module 302 is used to extract the task data from the task request;
[0174] A preprocessing module 303 is used to preprocess the task data to obtain corresponding target task data;
[0175] The parsing module 304 is used to perform task parsing processing on the target task data based on a preset target large language model to obtain a corresponding task parsing result;
[0176] A generating module 305, configured to generate a plurality of target subtasks including an execution order based on the task analysis result;
[0177] The processing module 306 is used to process each of the target subtasks in sequence based on the execution order, and display the generated task processing results of each of the target subtasks in the front-end interface according to the execution order.
[0178] In this embodiment, the operations performed by the above modules or units correspond one-to-one to the steps of the artificial intelligence-based task processing method in the aforementioned implementation mode, and will not be repeated here.
[0179] In some optional implementations of this embodiment, the parsing module 304 includes:
[0180] The conversion submodule is used to perform format conversion processing on the target task data to obtain corresponding designated task data;
[0181] A calling submodule, used to call the target large language model;
[0182] An input submodule, used for inputting the specified task data into the target large language model;
[0183] The first processing submodule is used to perform task planning and decomposition processing on the specified task data through the target large language model to obtain corresponding task analysis results; wherein the task analysis results include a list of subtasks, a description of each subtask, and an execution order and dependency relationship of each subtask.
[0184] In this embodiment, the operations performed by the above modules or units correspond one-to-one to the steps of the artificial intelligence-based task processing method in the aforementioned implementation mode, and will not be repeated here.
[0185] In some optional implementations of this embodiment, the generation module 305 includes:
[0186] An acquisition submodule, used to acquire the list of subtasks, the description of each subtask, and the execution order and dependency relationship of each subtask from the task parsing result;
[0187] A first generating submodule, configured to generate a plurality of corresponding initial subtasks based on the list of subtasks and the description of each subtask;
[0188] A sorting submodule, used to sort the execution order of the multiple initial subtasks based on the execution order and dependency relationship of each subtask to obtain sorted initial subtasks;
[0189] The second generating submodule is used to generate the target subtask based on the sorted initial subtasks.
[0190] In this embodiment, the operations performed by the above modules or units correspond one-to-one to the steps of the artificial intelligence-based task processing method in the aforementioned implementation mode, and will not be repeated here.
[0191] In some optional implementations of this embodiment, the preprocessing module 303 includes:
[0192] A second processing submodule is used to remove irrelevant information from the task data to obtain corresponding first task data;
[0193] A third processing submodule is used to extract key elements from the first task data to obtain corresponding second task data;
[0194] A fourth processing submodule, used for performing standardization processing on the second task data to obtain corresponding third task data;
[0195] A determination submodule is used to use the third task data as the target task data.
[0196] In this embodiment, the operations performed by the above modules or units correspond one-to-one to the steps of the artificial intelligence-based task processing method in the aforementioned implementation mode, and will not be repeated here.
[0197] In some optional implementations of this embodiment, the task processing device based on artificial intelligence further includes:
[0198] A judgment module, used to judge whether all the target subtasks have been processed;
[0199] A first acquisition module, used for, if yes, acquiring a preset message generation strategy;
[0200] A summary module, used to summarize the task processing results of all the target subtasks based on the message generation strategy to obtain corresponding summary messages;
[0201] A display module is used to display the summary message on the front-end interface.
[0202] In this embodiment, the operations performed by the above modules or units correspond one-to-one to the steps of the artificial intelligence-based task processing method in the aforementioned implementation mode, and will not be repeated here.
[0203] In some optional implementations of this embodiment, the task processing device based on artificial intelligence further includes:
[0204] A first building module, used to build a specified task identifier corresponding to the task request;
[0205] A second building module is used to build a specified message queue corresponding to the specified task identifier;
[0206] The storage module is used to store the task processing results of each of the target subtasks in the designated message queue.
[0207] In this embodiment, the operations performed by the above modules or units correspond one-to-one to the steps of the artificial intelligence-based task processing method in the aforementioned implementation mode, and will not be repeated here.
[0208] In some optional implementations of this embodiment, the task processing device based on artificial intelligence further includes:
[0209] A second acquisition module, used to acquire a specified timeout period corresponding to the specified message queue;
[0210] A third judgment module, used to judge whether the specified message queue meets the cleaning condition based on the specified timeout period;
[0211] The cleaning module is used to clean up the specified message queue if so.
[0212] In this embodiment, the operations performed by the above modules or units correspond one-to-one to the steps of the artificial intelligence-based task processing method in the aforementioned implementation mode, and will not be repeated here.
[0213] To solve the above technical problems, the present application also provides a computer device. Figure 4 , Figure 4 This is a basic structural block diagram of the computer device in this embodiment.
[0214] The computer device 4 includes a memory 41, a processor 42, and a network interface 43 that are interconnected through a system bus. It should be noted that the figure only shows a computer device 4 with components 41-43, but it should be understood that it is not required to implement all the components shown, and more or fewer components can be implemented instead. Among them, those skilled in the art can understand that the computer device here is a device that can automatically perform numerical calculations and / or information processing according to pre-set or stored instructions, and its hardware includes but is not limited to microprocessors, application specific integrated circuits (Application Specific Integrated Circuit, ASIC), programmable gate arrays (Field-Programmable Gate Array, FPGA), digital processors (Digital Signal Processor, DSP), embedded devices, etc.
[0215] The computer device may be a desktop computer, a notebook, a PDA, a cloud server, etc. The computer device may interact with the user through a keyboard, a mouse, a remote controller, a touch pad, or a voice control device.
[0216] The memory 41 includes at least one type of readable storage medium, and the readable storage medium includes flash memory, hard disk, multimedia card, card-type memory (for example, SD or DX memory, etc.), random access memory (RAM), static random access memory (SRAM), read-only memory (ROM), electrically erasable programmable read-only memory (EEPROM), programmable read-only memory (PROM), magnetic memory, disk, optical disk, etc. In some embodiments, the memory 41 can be an internal storage unit of the computer device 4, such as a hard disk or memory of the computer device 4. In other embodiments, the memory 41 can also be an external storage device of the computer device 4, such as a plug-in hard disk equipped on the computer device 4, a smart memory card (Smart Media Card, SMC), a secure digital (Secure Digital, SD) card, a flash card (FlashCard), etc. Of course, the memory 41 can also include both the internal storage unit of the computer device 4 and its external storage device. In this embodiment, the memory 41 is generally used to store the operating system and various application software installed on the computer device 4, such as computer-readable instructions of a task processing method based on artificial intelligence, etc. In addition, the memory 41 can also be used to temporarily store various types of data that have been output or are to be output.
[0217] The processor 42 may be a central processing unit (CPU), a controller, a microcontroller, a microprocessor, or other data processing chips in some embodiments. The processor 42 is generally used to control the overall operation of the computer device 4. In this embodiment, the processor 42 is used to run computer-readable instructions stored in the memory 41 or process data, such as computer-readable instructions for running the artificial intelligence-based task processing method.
[0218] The network interface 43 may include a wireless network interface or a wired network interface. The network interface 43 is generally used to establish a communication connection between the computer device 4 and other electronic devices.
[0219] Compared with the prior art, the embodiments of the present application have the following beneficial effects:
[0220] In an embodiment of the present application, after receiving a task request carrying task data submitted by a user through a front-end interface, the task data in the task request will be pre-processed to obtain target task data, and then task analysis will be performed on the target task data based on the use of a target large language model to decompose the target task data into multiple target sub-tasks including an execution order, and each target sub-task will be automatically and intelligently processed in sequence based on the execution order, and the generated task processing results of each target sub-task will be displayed in the front-end interface in the execution order, so as to gradually output the intermediate response results of the target sub-tasks to the user in batches, thereby improving the efficiency and accuracy of task processing, reducing user waiting time, and providing users with timely and transparent task progress information, effectively improving the user experience.
[0221] The present application also provides another embodiment, namely, providing a computer-readable storage medium, wherein the computer-readable storage medium stores computer-readable instructions, and the computer-readable instructions can be executed by at least one processor to enable the at least one processor to perform the steps of the above-mentioned artificial intelligence-based task processing method.
[0222] Compared with the prior art, the embodiments of the present application have the following beneficial effects:
[0223] In an embodiment of the present application, after receiving a task request carrying task data submitted by a user through a front-end interface, the task data in the task request will be pre-processed to obtain target task data, and then task analysis will be performed on the target task data based on the use of a target large language model to decompose the target task data into multiple target sub-tasks including an execution order, and each target sub-task will be automatically and intelligently processed in sequence based on the execution order, and the generated task processing results of each target sub-task will be displayed in the front-end interface in the execution order, so as to gradually output the intermediate response results of the target sub-tasks to the user in batches, thereby improving the efficiency and accuracy of task processing, reducing user waiting time, and providing users with timely and transparent task progress information, effectively improving the user experience.
[0224] Through the description of the above implementation methods, those skilled in the art can clearly understand that the above-mentioned embodiment methods can be implemented by means of software plus a necessary general hardware platform, and of course by hardware, but in many cases the former is a better implementation method. Based on such an understanding, the technical solution of the present application, or the part that contributes to the prior art, can be embodied in the form of a software product, which is stored in a storage medium (such as ROM / RAM, magnetic disk, optical disk), and includes a number of instructions for a terminal device (which can be a mobile phone, computer, server, air conditioner, or network device, etc.) to execute the methods described in each embodiment of the present application.
[0225] Obviously, the embodiments described above are only some embodiments of the present application, rather than all embodiments. The preferred embodiments of the present application are given in the accompanying drawings, but they do not limit the patent scope of the present application. The present application can be implemented in many different forms. On the contrary, the purpose of providing these embodiments is to make the understanding of the disclosure of the present application more thorough and comprehensive. Although the present application is described in detail with reference to the aforementioned embodiments, for those skilled in the art, it is still possible to modify the technical solutions recorded in the aforementioned specific implementation methods, or to perform equivalent replacement of some of the technical features therein. Any equivalent structure made using the contents of the specification and drawings of this application, directly or indirectly used in other related technical fields, is similarly within the scope of patent protection of this application.
Claims
1. A task processing method based on artificial intelligence, characterized in that: The steps include: Determine whether a task request submitted by a user through a front-end interface is received; wherein the task request carries task data; If so, extracting the task data from the task request; Preprocessing the task data to obtain corresponding target task data; Performing task analysis on the target task data based on a preset target large language model to obtain a corresponding task analysis result; Generating a plurality of target subtasks including an execution order based on the task analysis result; The target subtasks are processed in sequence based on the execution order, and the generated task processing results of the target subtasks are displayed in the front-end interface according to the execution order.
2. The task processing method based on artificial intelligence according to claim 1, characterized in that: The step of performing task analysis processing on the target task data based on the preset target large language model to obtain the corresponding task analysis result specifically includes: Performing format conversion processing on the target task data to obtain corresponding designated task data; Calling the target large language model; Inputting the specified task data into the target large language model; The designated task data is task planned and decomposed by the target large language model to obtain a corresponding task analysis result; wherein the task analysis result includes a list of subtasks, a description of each subtask, and an execution order and dependency relationship of each subtask.
3. The task processing method based on artificial intelligence according to claim 2, characterized in that: The step of generating a plurality of target subtasks including an execution order based on the task analysis result specifically includes: Obtaining a list of the subtasks, a description of each subtask, and an execution order and dependency relationship of each subtask from the task parsing result; Generating a corresponding plurality of initial subtasks based on the list of subtasks and the description of each subtask; Based on the execution order and dependency relationship of each subtask, the multiple initial subtasks are sorted in execution order to obtain sorted initial subtasks; The target subtask is generated based on the sorted initial subtasks.
4. The task processing method based on artificial intelligence according to claim 1, characterized in that: The step of preprocessing the task data to obtain corresponding target task data specifically includes: Removing irrelevant information from the task data to obtain corresponding first task data; Extract key elements from the first task data to obtain corresponding second task data; performing standardization processing on the second task data to obtain corresponding third task data; The third task data is used as the target task data.
5. The task processing method based on artificial intelligence according to claim 1, characterized in that: After the step of sequentially processing each of the target subtasks based on the execution order and displaying the generated task processing results of each of the target subtasks in the front-end interface according to the execution order, the method further includes: Determine whether all the target subtasks have been processed; If yes, obtain the preset message generation strategy; Summarizing the task processing results of all the target subtasks based on the message generation strategy to obtain corresponding summary messages; The summary message is displayed on the front-end interface.
6. The task processing method based on artificial intelligence according to claim 1, characterized in that: The task processing method based on artificial intelligence also includes: Constructing a specified task identifier corresponding to the task request; Constructing a specified message queue corresponding to the specified task identifier; The task processing results of each of the target subtasks are stored in the designated message queue.
7. The task processing method based on artificial intelligence according to claim 6, characterized in that: After the step of storing the task processing results of each of the target subtasks in the designated message queue, the method further includes: Obtaining a specified timeout period corresponding to the specified message queue; Based on the specified timeout period, determining whether the specified message queue meets the cleaning condition; If so, clear the specified message queue.
8. A task processing device based on artificial intelligence, characterized in that: include: A first judgment module is used to judge whether a task request submitted by a user through a front-end interface is received; wherein the task request carries task data; An extraction module, configured to extract the task data from the task request; A preprocessing module, used to preprocess the task data to obtain corresponding target task data; A parsing module, used to perform task parsing processing on the target task data based on a preset target large language model to obtain a corresponding task parsing result; A generation module, used to generate a plurality of target subtasks including an execution order based on the task analysis result; A processing module is used to process each of the target subtasks in sequence based on the execution order, and display the generated task processing results of each of the target subtasks in the front-end interface according to the execution order.
9. A computer device, characterized in that: It comprises a memory and a processor, wherein the memory stores computer-readable instructions, and when the processor executes the computer-readable instructions, the steps of the task processing method based on artificial intelligence as described in any one of claims 1 to 7 are implemented.
10. A computer-readable storage medium, characterized in that: The computer-readable storage medium stores computer-readable instructions, which, when executed by a processor, implement the steps of the artificial intelligence-based task processing method according to any one of claims 1 to 7.
Citation Information
Cited By
Task processing method and device, medium and equipment
CN119759589A