Task request processing method, device, electronic device and storage medium
By using a lightweight information list to identify the execution body function of the task request and send it to the big model, the problem of inefficiency in processing task requests is solved, and more efficient task request processing is achieved.
Patent Information
- Application Number
- CN202410881223.7
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2024-07-02
- Publication Date
- 2024-12-17
- Estimated Expiration
- 2044-07-02
AI Technical Summary
In the prior art, due to the limitation of data processing capabilities, the large model has low efficiency when processing task requests, and cannot effectively improve the specific execution method of the execution subject to process task requests.
By obtaining a list of lightweight information, identifying the functions that the executor of the task request has, and sending the task request and lightweight information list to the big model, obtaining all the necessary functions required for processing the task request returned by the big model. Execute sequential data to ensure that the data transmission volume does not exceed the upper limit of the data transmission volume of the large model.
It improves the efficiency of the large model to provide specific execution methods for the execution subject to handle task requests, increases the number of functions that the large model can process at one time, avoids the problem of not fully included function, and improves the efficiency of task request processing.
Smart Images

Figure CN118411100B_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the field of data processing technology, and in particular to a task request processing method, device, electronic device and computer storage medium. Background Art
[0002] At present, the application of big models in various industries has gradually formed a scale. The application scenarios of big models are diverse. For example, big models are used to provide services to execution entities. Specifically, for the task request provided by the user, the specific execution method required to execute the task request is obtained by means of big model analysis. However, in the prior art, due to the limitation of the data processing capacity of the big model, the efficiency of the specific execution method of the task request returned by the big model is low.
[0003] Therefore, how to improve the efficiency of large models in providing specific execution methods for execution entities to process task requests. Summary of the invention
[0004] The embodiment of the present application provides a task request processing method to improve the efficiency of a large model in providing a specific execution method for an execution subject to process a task request. The embodiment of the present application also provides a task request processing device, an electronic device, and a computer storage medium.
[0005] An embodiment of the present application provides a task request processing method, including: obtaining a task request to be processed; obtaining a lightweight information list, wherein the lightweight information in the lightweight information list is used to identify a function possessed by an execution subject that processes the task request, and the data volume of the lightweight information is less than the data volume of the fully quantitative description information of the function; sending the task request and the lightweight information list to a large model that can provide function call capability, and obtaining execution sequence data of all necessary functions required to run for processing the task request returned by the large model, wherein all necessary functions are functions among all functions identified by the lightweight information list, and the total data volume of the lightweight information list and the execution sequence data is no higher than the upper limit of the data transmission volume allowed by the large model for providing the execution subject with function call capability for processing the task request.
[0006] Compared with the prior art, the embodiment of the present application has the following advantages: the task request processing method provided by the embodiment of the present application, when the execution subject processes the task request, needs to determine the execution order data of all necessary functions required to run the task request through the function call capability of the large model. Based on the influence of the upper limit of the data transmission amount allowed by the function call capability provided by the large model, the full quantitative description information of each function that the execution subject has for processing the task request is lightweight processed here to obtain lightweight information. A lightweight information list is generated from multiple lightweight information, and the task request and the lightweight information list are sent to the large model to obtain the execution order data of all necessary functions required to run by the execution subject for processing the task request returned by the large model. The total data volume of the lightweight information list and the execution order data is less than the upper limit of the data transmission amount corresponding to the large model. In the lightweight information list, the data volume of the lightweight information is less than the data volume of the fully quantitative description information of the function. Based on this, the number of functions in the lightweight information list provided by the execution subject to the large model increases, avoiding the lightweight information list not fully containing all necessary functions required to run by the execution subject to process the task request. Thus, the large model can select all necessary functions required to run the task request from the large number of functions included in the lightweight information list at one time, and determine the execution order data of all necessary functions. Therefore, the embodiment of the present application improves the efficiency of the large model in providing the execution order data of all necessary functions required to run the execution subject to process the task request. BRIEF DESCRIPTION OF THE DRAWINGS
[0007] Figure 1 This is a first application scenario diagram of the task request processing method provided in an embodiment of the present application.
[0008] Figure 2-A The first schematic diagram of the interaction process between the execution subject and the large model provided in the embodiment of the present application.
[0009] Figure 2-B A second schematic diagram of the interaction process between the execution entity and the large model provided in an embodiment of the present application.
[0010] Figure 2-C This is a first schematic diagram of a lightweight information list provided in an embodiment of the present application.
[0011] Figure 2-D A second schematic diagram of a lightweight information list provided in an embodiment of the present application.
[0012] Figure 3 The large model provided in the embodiment of the present application determines the execution order of functions and the application scenario diagram of calling functions according to the task request.
[0013] Figure 4A flowchart for calling each function in sequence according to execution order data provided in an embodiment of the present application.
[0014] Figure 5 A second application scenario diagram of the task request processing method provided in an embodiment of the present application.
[0015] Figure 6 A flowchart of a task request processing method provided in the first embodiment of the present application.
[0016] Figure 7 This is a schematic diagram of a task request processing device provided in the second embodiment of the present application.
[0017] Figure 8 This is a schematic diagram of an electronic device provided in the third embodiment of the present application. DETAILED DESCRIPTION
[0018] Many specific details are described in the following description to facilitate a full understanding of the present application. However, the present application can be implemented in many other ways than those described herein, and those skilled in the art can make similar generalizations without violating the connotation of the present application, so the present application is not limited by the specific implementation disclosed below.
[0019] The terms used in this application are only for the purpose of describing specific embodiments and are not intended to limit this application. The descriptions used in this application and the appended claims, such as "a", "first", and "second", are not limitations on quantity or sequence, but are used to distinguish the same type of information from each other.
[0020] At present, the application of large models in various industries has gradually formed a scale. The application scenarios of large models are diverse. For example, large models are used to provide services to execution entities. Specifically, for the task request provided by the user, the specific execution method required to execute the task request is obtained with the help of large model analysis. Large models usually refer to artificial intelligence models with huge scale parameters and computing power, such as large language models (LLM, Large Language Model, is a language model composed of artificial neural networks with billions of weights or more parameters. It uses self-supervised learning or semi-supervised learning to train a large amount of unlabeled text, can generate natural language text or understand the meaning of language text, and can handle a variety of natural language tasks, such as text classification, question answering, dialogue, etc.). These models can handle large-scale data sets and complex tasks, so they are widely used. At present, the function call capability provided by large models is used to provide services for applications. However, in the prior art, due to the limitation of the data processing capability of large models, the efficiency of the specific execution method of returning task requests by large models is low. For example, in the scenario of using the Function Calling capability of the big model, the big model will convert the user's request into a form that the model can understand, here converted into a System Role Prompt, which is a special formatted instruction used to guide the model to execute a specific function or action. This instruction is usually more structured, designed to explicitly tell the model to call a preset function or service, and may contain necessary parameter information so that the model can accurately complete the corresponding function call.
[0021] In the embodiment of the present application, the function calling capability of the large model is used to call an external function API (Application Programming Interface, referred to as the function for processing task requests in this application), in which the information used to express the intention of the function call and the information of the function itself will be counted in the total number of tokens (basic units representing text input, such as single words, punctuation marks, special marks, and the token is taken as a single word in this application for illustration). Since the large model has an upper limit on the number of token data when processing any input, even if the task request is encapsulated in the form of a function call, this limitation cannot be broken. For example, the upper limit of the number of tokens allowed by the large model at a time is 4096. If the total number of tokens of the task request information, the function's own information, and the parameter information of the function call exceeds 4096, the large model cannot correctly parse and execute the function call. Therefore, how to improve the efficiency of the large model in providing a specific execution method for the execution subject to process task requests.
[0022] In order to solve the above technical problems, the present application provides a plurality of embodiments. The various embodiments provided by the present application are introduced below. The following first describes the application scenario of the task request processing method provided by the embodiment of the present application. The task request processing method provided by the embodiment of the present application can be applied to the process in which the execution subject processes the task request of the user, and the specific execution method of the execution subject to process the task request is determined by a large model that can provide function calling capability. Specifically, the execution order data of all necessary functions required to be run by the execution subject to process the task request is determined. According to the execution order data of all necessary functions, the execution subject calls all necessary functions in sequence to obtain the processing result of the task request.
[0023] Please refer to Figure 1 , which is a first application scenario diagram of the task request processing method provided in an embodiment of the present application. Figure 1 Include Figure 1 Page 1A, Figure 1 Page 1B, Figure 1 Page 1C, through Figure 1 Page 1A to Figure 1 In the process of page 1C, the user side implements the process of obtaining the processing result for the user's task request. Figure 1 Page 1A to Figure 1 The process of page 1C is a process diagram based on the scenario of the customer searching for the service and product information he needs on the user side. Figure 1 Page 1A shows any page of the user end, which includes a search box for customers to edit the search information they need. Figure 1 Page 1A also displays a list of some default merchants of the user terminal, and these default merchants may provide different types of goods. Based on the search information provided by the customer, the user terminal obtains the customer's task request information. Figure 1 Page 1B of the example shows that a customer has entered the search information "Help me search for the most popular dumpling shop nearby" in the search box. The user terminal detects the customer's search information and obtains the customer's task request information. Based on the task request information, the task request information is processed to obtain Figure 1 The processing result display page shown in page 1C. Figure 1 Page 1C of the task request shows the result of the task request, that is, the ranking information of the dumpling shops near the customer. Figure 1 Page 1B jumps to Figure 1The backend implementation logic is as follows: the user sends the task request information and the candidate function list information that can realize the task request to the big model that can provide function call capability. After analysis, the big model outputs the execution order data of all necessary functions required to run to realize the task request. The user calls these necessary functions in sequence according to the execution order data of all necessary functions, and finally obtains Figure 1 The result information displayed on page 1C. The interaction process between the user end and the big model here can be that the user end directly interacts with the big model, sending the task request information and the candidate function list information that can realize the task request, and the user end is the execution subject in this process. It can also be that the user end sends the task request information to the server end, and the server end sends the task request information and the candidate function list information that can realize the task request to the big model, and the server end is the execution subject in this process.
[0024] In addition, if it is a merchant terminal used by the merchant, the merchant can enter "Help me get the pending orders with the shortest order acceptance time" on the merchant terminal page, and the merchant terminal or the server corresponding to the merchant terminal and the big model will be connected according to Figure 2-A or Figure 2-B The information exchange between the execution subject and the big model is completed in this way, and the execution order data of all necessary functions required to run to process the task request is obtained. The merchant terminal executes each function in turn according to the execution order data to obtain the merchant's pending order list page. For another example, the distribution resource can enter "Help me get the list information of pending orders" on the page of the distribution resource terminal used by the distribution resource. The distribution resource terminal or the server corresponding to the distribution resource terminal and the big model are connected in accordance with Figure 2-A or Figure 2-B The information exchange between the execution subject and the big model is completed in this way, and the execution sequence data of all necessary functions required to process the task request is obtained. The distribution resource terminal executes each function in sequence according to the execution sequence data to obtain the list page of the distribution resource's to-be-delivered orders.
[0025] Among them, the execution subject determines the specific execution method corresponding to the task request with the help of the big model, which is specifically implemented in the following way: the execution subject sends the task request and the function information of the execution subject for processing the task request to the big model, and obtains the execution sequence data of all necessary functions required to run for processing the task request returned by the big model. Based on the influence of the upper limit of the data transmission volume allowed by the big model for the execution subject to provide function call capabilities for processing task requests, the total amount of data between the amount of data of the task request sent by the execution subject to the big model, the amount of data of the function information possessed by the execution subject, and the amount of data of the execution sequence data of all necessary functions returned by the big model needs to be less than or equal to the upper limit of the data transmission volume corresponding to the big model. The upper limit of the data transmission volume corresponding to the big model is expressed as the sum of the input data volume and the output data volume during one use of the big model is not greater than the upper limit of the data transmission volume.
[0026] In order to meet the requirements of the upper limit of the data transmission volume of the large model and increase the number of function types that the execution subject provides to the large model at one time, the lightweight information corresponding to the function is used in the embodiment of the present application to replace the fully quantitative description information of the function, obtain the lightweight information list, and the execution subject provides the task request and the lightweight information list to the large model. The lightweight information list contains a plurality of lightweight information, and the lightweight information is used to identify the function possessed by the execution subject that processes the task request. The amount of data of the lightweight information is less than the amount of data of the fully quantitative description information of the function. It increases the number of function types that the execution subject provides to the large model at one time, so that the large model can select all the necessary functions required to process the task request and determine the execution order data of all necessary functions from a large number of functions at one time. Therefore, the embodiment of the present application can improve the efficiency of the large model in determining the execution order data of all necessary functions required to process the task request.
[0027] Continuing with the above example, the large model obtains the task request and lightweight information list sent by the execution subject. The task request is "Help me open the store page of the most popular dumpling shop around me". In the lightweight information list, all necessary functions required to execute the task request are analyzed and obtained, and the execution order of all necessary functions is determined. For example, the execution order may be: "Function to obtain location->Function to search and locate surrounding delicacies->Function to take the first one->Function to obtain the store link (pass in the store ID)->Function to jump to the page".
[0028] The lightweight information list can be generated in at least one of the following ways: The first generation method: extract partial description information of the function from the full quantitative information list of the function. The partial description information of the function includes the name information of the function and the parameter information used to describe the functions that the function can implement; use the partial description information of the function as the lightweight information corresponding to the function, and generate a lightweight information list based on the partial description information of multiple functions. Please refer to Figure 2-A , which is a first schematic diagram of the interaction process between the execution subject and the large model provided in the embodiment of the present application. Figure 2-A In the example, the execution subject 100 sends the task request and the lightweight information list (api2, api11, api4, api6, api7, api5, api8, api13) to the large model 200, and the large model 200 returns to the execution subject 100 the execution order data of all necessary functions required to run the task request (api4->api11->api7). The lightweight information corresponding to each function in the lightweight information list includes the name information of the function and the parameter information used to describe the functions that the function can implement. For a detailed description of the process here, please refer to Figure 2-C Provide explanation. Figure 2-C This is a first schematic diagram of a lightweight information list provided in an embodiment of the present application. Figure 2-C The list includes a first type of lightweight information 101, which contains partial description information of each lightweight information representing a function; partial description information 102 of the first function, which includes the name information of the function and parameter information used to describe the functions that the function can achieve; and full description information 103 of the function, which includes the complete execution code of the function. Among them, the parameter information used to describe the functions that the function can achieve specifically refers to the functions that can be achieved by running the function. For example, the functions that the function can achieve are obtaining positioning or obtaining store links. The partial description information of the function mentioned in the partial description information 102 of the first function indicates that the function is a function for searching for nearby food through keywords and some other optional parameters.
[0029] Before the lightweight information list generated by the first method is sent to the large model, the large model is also trained. Specifically, the large model is trained through the partial description information of the function and the full description information of the function to obtain a large model that can identify the correspondence between the partial description information of the function and the full description information of the function. Therefore, after the execution subject sends the task request and the lightweight information list to the large model, the large model can correspond to the full description information of the function based on the partial description information of the function contained in the lightweight information list, determine the functions that the function can realize, and analyze and determine whether the function is a necessary function to run to process the task. The lightweight information list sent by the execution subject to the large model can be in the form of a collection of "{api2, api11, api4, api6, api7, api5, api8, api13}". Each element in the collection represents the partial description information of a function, for example, "api1" represents the partial description information of the function with the function name 1. The execution order data of all necessary functions that the execution subject needs to run to process the task request returned by the large model can be in the form of "api 4->api 11->api 7".
[0030] The second generation method: number the functions of the execution subject to obtain the number information corresponding to each function; use the number information of each function as the lightweight information corresponding to each function; and generate a lightweight information list based on the number information of multiple functions. Please refer to Figure 2-B , which is a second schematic diagram of the interaction process between the execution subject and the large model provided in the embodiment of the present application. Figure 2-B In the example, the execution subject 100 sends the task request and the lightweight information list (2, 11, 4, 6, 7, 5, 8, 13) to the large model 200, and the large model 200 returns the execution order data (4->11->7) of all necessary functions required to run the task request to the execution subject 100. The lightweight information corresponding to each function in the lightweight information list here includes the number information of each function. For a detailed description of the process, please refer to Figure 2-D Provide explanation. Figure 2-D A second schematic diagram of a lightweight information list provided in an embodiment of the present application. Figure 2-DThe second lightweight information list 104 is included, and the lightweight information in the lightweight information list is generated by the number information of each function; the fully quantitative description information 103 of the function includes the complete execution code of the function. The lightweight information list is obtained by the second generation method. During the training of the large model, the large model is trained by the number information of the function and the fully quantitative description information of the function to obtain a large model that can identify the correspondence between the number information of the function and the fully quantitative description information of the function. Therefore, after the execution subject sends the task request and the lightweight information list to the large model, the large model can correspond to the fully quantitative description information of the function according to the number information of the function contained in the lightweight information list, determine the functions that the function can realize, and thus analyze and determine whether the function is a necessary function required to run to process the task. Here, the lightweight information list sent by the execution subject to the large model can be in the form of a set of "{2, 11, 4, 6, 7, 5, 8, 13}". Each element in the set represents the number information of a function. The execution order data of all necessary functions that the execution subject returned by the large model needs to run to process the task request can be in the form of "4->11->7".
[0031] Based on the above two methods, the fully quantitative description information of the function is processed to obtain a lightweight information list. The execution subject sends the task request and the lightweight information list to the large model, and obtains the execution order data of all necessary functions returned by the large model to process the task request. The total data volume of the lightweight information list and the execution order data is less than the upper limit of the data transmission volume corresponding to the large model. The number of functions provided by the execution subject to the large model at one time is increased, which makes it easier for the large model to select all necessary functions from the larger number of functions included in the lightweight information list at one time, thereby determining the execution order data of all necessary functions. It improves the efficiency of the large model in providing specific execution methods for the execution subject to process task requests.
[0032] The above is a description of the process by which the execution subject uses the large model to obtain the execution order data of all necessary functions required to process the task request. The following describes the process by which the execution subject obtains the execution order data of all necessary functions and then calls all necessary functions in sequence. Figure 3 , which is a large model provided in an embodiment of the present application, which determines the execution order of functions and the application scenario diagram of calling functions according to task requests.
[0033] S301: The big model outputs an API list based on the task request and the lightweight information list. The execution subject provides the task request and the lightweight information list to the big model, and obtains the API list output by the big model with the help of the function calling capability of the big model. The lightweight information list obtained by the big model is as follows: Figure 3As shown in the first type of lightweight information list 101 in the figure, the lightweight information is obtained by extracting part of the function description information from the full quantitative description information of the function. The API list output by the large model contains the arrangement order data of all APIs required by the execution subject to process the task request. Figure 3 It is shown as "api4->api11->api7".
[0034] S302: Call each API in sequence according to the execution order data of the API in the API list. After obtaining the execution order data of all APIs output by the large model, call each API in sequence. Specifically, calling each API in sequence is to determine the full quantitative description information of the first API to be run among all APIs according to the execution order data of all APIs. Obtain the parameters required to run the first API, generate a first API instance, run the first API instance, and obtain the running result of the first API instance. Send the full quantitative description information of the first API instance and the running result of the first API instance to the large model, and obtain the first verification result of the large model on the full quantitative description information of the first API instance and the running result of the first API instance.
[0035] And so on, call all APIs respectively. The running result of the last API in the execution order data of all APIs is used as the processing result of processing the task request. The specific method of calling each API in sequence can be referred to Figure 4 Please refer to the flowchart shown in Figure 4 , which is a flowchart of calling each function in sequence according to the execution order data provided by an embodiment of the present application. S401: User input (voice or text). The user enters a task request on the user side, and the user side obtains the task request to be processed. For example, the user enters "Help me open the store page of the most popular dumpling shop around" in the input box. S402: Matching intent. The execution subject sends the task request and lightweight information to the big model. The execution order data of all necessary functions required to process the task request is obtained through the big model analysis. The execution subject here can be the user side or the service side of the service platform serving users. S403: Determine the target function. In this step, the big model returns the execution order data of all necessary functions required to process the task request. That is, the execution subject obtains the execution order data of all necessary functions required to process the task request.
[0036] S404: Calling by passing parameters. Calling all necessary functions in sequence, including: obtaining the fully quantified description information of the first necessary function to be run among all necessary functions according to the execution order data of all necessary functions. Obtaining the parameters required to run the first necessary function, and generating the first necessary function instance according to the fully quantified description information of the first necessary function and the parameters required to run the first necessary function. Figure 3 The arrangement order data of the API shown is "api4->api11->api7" for example. The first necessary function to be run is api4, the second necessary function to be run after the first necessary function is api11, and the third necessary function to be run after the second necessary function is api7. In the process of calling the first necessary function api4, the full description information of api4 and the parameters required to run api4 are obtained. According to the full description information of api4 and the parameters required to run api4, the api4 instance is obtained. The full description information of api4 represents the complete execution code of api4, such as Figure 2-C The fully quantified description information of the function in 103 is shown. The fully quantified description information of the api4 instance represents the complete execution code of api4 and the complete execution code of the parameters required to run api4. For example, the function represented by api4 is C=a+b, and the parameters for running api4 are, for example, a=2, b=3.
[0037] S405: Output the function result. Run the first necessary function instance and obtain the first running result of the first necessary function instance. For example, running the api4 instance is the complete execution code of api4 plus the complete execution code of the parameters required to run api4, and the first running result is C=5. S406: Determine the verification result of the output function result. Send the full quantitative description information of the first necessary function instance and the first running result of the first necessary function instance to the large model, and obtain the first verification result of the full quantitative description information and the first running result returned by the large model for the first necessary function instance. For example, the complete execution code of the api4 instance (that is, the complete execution code of api4 and the complete execution code of the parameters required to run api4) and the first running result C=5 are all sent to the large model. The large model analyzes whether the complete execution code of the api4 instance is accurate and whether the first running result C=5 is accurate, and then feeds back the first verification result. The first verification result refers to the result of the large model analyzing whether the full quantitative description information of the first necessary function instance and the first running result match. Combined with the above example, the complete execution code of the api4 instance (that is, the complete execution code of api4 and the complete execution code of the parameters required to run api4), as well as the first running result C=5 are both correct.
[0038] S407: If the verification result is not verified, then it is completed. If the first verification result indicates that the full quantitative description information and the first running result of the large model for the first necessary function instance have not passed the verification, then it is finished. If the first verification result indicates that the full quantitative description information and the first running result of the large model for the first necessary function instance have passed the verification, then the first running result is used as the parameter of the second necessary function to be run after the first necessary function. In other task requests, the execution order of the first necessary function and the second necessary function can be a parallel relationship, that is, the parameters of the second necessary function do not need to be obtained based on the running result of the first necessary function. Continue to execute step S402 and call the second necessary function. The calling method of the second necessary function is the same as the calling method of the first necessary function, and the calling process of the second necessary function is executed according to steps S402~S407. If the second necessary function is a function whose execution order of the execution order data of all necessary functions is at the end order, the second running result of the second necessary function instance is used as the processing result of the processing task request.
[0039] The above is the description process of the application scenario of the task request processing method provided by the embodiment of the present application. The following is a detailed description of the task request processing method provided by the embodiment of the present application in combination with the interface display diagram of the application scenario. Please refer to Figure 5 , which is a second application scenario diagram of the task request processing method provided in an embodiment of the present application. Figure 5 The process of obtaining the processing result for the user's task request is described, which includes: a necessary function sequence 501, a first necessary function instance 502, a second necessary function instance 503, a third necessary function instance 504, and a page jump 505. Here, it can be described from the perspective of the application terminal used by the developer who developed the logic code. The developer enables the user end to have the following functions through the technical solution provided by the embodiment of the present application: the user makes the task request required by the user on the current page of the user end, and the user end can jump from the current page to the display page after the task request is processed. The current page can be any page of the user end. For example, the user enters a task request of "ordering the most popular pizza nearby" on the first page of the user end, which is referred to as a pending task request. The user end jumps from the first page to the second page. The second page is the task request processing result page obtained after the user end processes according to the technical solution provided in the embodiment of the present application.
[0040] After the user end obtains the pending task request, it needs to use the function calling capability of the large model to determine the execution order data of all necessary functions required to process the task request. Therefore, here the user end can send the pending task request to the large model, or the user end can send the pending task request to the server, and the server sends the pending task request to the large model. When the large model obtains the task request, it also obtains the function information of the execution subject to process the task request, which is sent to the large model in the form of a lightweight information list. The large model returns the execution order data of all necessary functions that the execution subject needs to run to process the task request based on the task request and the lightweight information list. Among them, the execution subject can be represented as the user end of the online service platform, or as the server end of the online service platform.
[0041] Figure 5 This shows the process of the user calling all necessary functions in sequence according to the execution order data of all necessary functions to obtain the processing result of the task request, that is, the list of the most popular pizza shops nearby. Figure 5 The necessary function sequence 501 is as follows: "get CurrentLocation->get Location Ranking->Seach Food WithKeyword". Therefore, what the execution subject sends to the large model is a lightweight information list. Therefore, the execution order data returned by the large model is also described by the lightweight information in the lightweight information list, where "get current location", "get location ranking" and "search food with keywords" are the lightweight information corresponding to the three functions respectively. Among them, the execution subject calls all necessary functions in sequence according to the execution order data of all necessary functions to obtain the processing result of the task request, which is specifically implemented in the following way:
[0042] (1) Call the first necessary function to be run among all necessary functions. According to the execution order data of all necessary functions, obtain the fully quantitative description information of the first necessary function to be run among all necessary functions, and obtain the parameters required to run the first necessary function. According to the fully quantitative description information of the first necessary function and the parameters required to run the first necessary function, generate the fully quantitative description information of the first necessary function instance; and run the first necessary function instance to obtain the first running result of the first necessary function instance. Figure 5As shown, the first necessary function is "get current position", wherein the first necessary function instance 502 is the fully quantitative description information of "get current position". It is generated according to the fully quantitative description information of the first necessary function and the parameters required to run the first necessary function. The fully quantitative description information and the first running result of the first necessary function instance are sent to the large model, and the first verification result of the large model for the fully quantitative description information and the first running result of the first necessary function instance is obtained.
[0043] (2) Based on the first running result of the first necessary function instance, call the second necessary function to be run after the first necessary function among all necessary functions. If the first verification result indicates that the full quantitative description information and the first running result of the large model for the first necessary function instance have been verified, then according to the execution order data of all necessary functions, obtain the full quantitative description information of the second necessary function to be run after the first necessary function among all necessary functions, and obtain the parameters required to run the second necessary function. Generate the full quantitative description information of the second necessary function instance based on the full quantitative description information of the second necessary function and the parameters required to run the second necessary function; and run the second necessary function instance to obtain the second running result of the second necessary function instance. Figure 5 As shown, the second necessary function is "get position ranking", wherein the second necessary function instance 503 is the full quantitative description information of "get position ranking". It is generated according to the full quantitative description information of the second necessary function "get position ranking" and the parameters required to run the second necessary function.
[0044] The fully quantitative description information and the second operation result of the second necessary function instance are sent to the large model, and a second verification result of the large model for the fully quantitative description information and the second operation result of the second necessary function instance is obtained.
[0045] (2) Based on the second running result of the second necessary function instance, call the third necessary function to be run after the second necessary function among all necessary functions. If the second verification result indicates that the full quantitative description information and the second running result of the large model for the second necessary function instance have been verified, then according to the execution sequence data of all necessary functions, obtain the full quantitative description information of the third necessary function to be run after the second necessary function among all necessary functions, and obtain the parameters required to run the third necessary function. Based on the full quantitative description information of the third necessary function and the parameters required to run the third necessary function, generate the full quantitative description information of the third necessary function instance; and run the third necessary function instance to obtain the third running result of the third necessary function instance. Figure 5As shown, the third necessary function is "Use keywords to search for food", and the third necessary function instance 504 is the fully quantitative description information of "Use keywords to search for food". It is generated based on the fully quantitative description information of the third necessary function "Use keywords to search for food" and the parameters required to run the third necessary function. The fully quantitative description information of the third necessary function instance and the third running result are sent to the big model, and the third verification result of the big model for the fully quantitative description information and the third running result of the third necessary function instance is obtained. If the third verification result indicates that the big model has verified the fully quantitative description information and the third running result of the third necessary function instance, the third necessary function instance is the last necessary function in the execution sequence data of all necessary functions. Therefore, the third running result is used as the processing result of the task request, that is, the merchant list page about pizza at the second page display. If the second page is successfully displayed, it means that the big model has verified the fully quantitative description information and the third running result of the third necessary function instance, then in Figure 5 The page jump 505 in the display shows that the page jump is successful and the task is completed.
[0046] The above is a description of the application scenario of the task request processing method provided in the embodiment of the present application.
[0047] When processing a task request, the present application first converts the function information required to process the task request into lightweight information and generates a lightweight information list. The task request and the lightweight information list are sent to the large model, and the execution order data of all necessary functions required to process the task request are obtained with the help of the large model. What is sent to the large model in this process is a lightweight information list, rather than a list of fully quantitative description information of the function. The amount of data required for the information of each function is reduced, and more lightweight information of functions can be provided to the large model at one time, which facilitates the large model to analyze and determine all necessary functions required to process the task request in more lightweight information at one time, and return the execution order data of all necessary functions. Thus, when the upper limit of the data transmission amount allowed by the function call capability of the large model is met, the efficiency of the large model in providing the execution order data of all necessary functions for the execution subject to process the task request is improved.
[0048] The following describes another application scenario of the task request processing method provided in the embodiment of the present application. The task request processing method provided in the embodiment of the present application is applied to the instant delivery service scenario. The instant delivery service requires the execution subject to complete the tasks of each link in the instant delivery process within a preset time. Therefore, if the task request to be processed is an instant delivery service request, the execution subject is required to obtain the processing result of the instant delivery service request within the preset time. The execution subject obtains the processing result of the instant delivery service request within the preset time, that is, the execution subject obtains the execution sequence data of all necessary functions required to run to process the instant delivery service request within the preset time, and according to the execution sequence data of all necessary functions, calls all necessary functions in sequence to obtain the processing result of the instant delivery service request.
[0049] The execution subject obtains the execution sequence data of all necessary functions through the function calling capability provided by the large model. The process of calling all necessary functions in sequence is as follows: Obtain the fully quantitative description information of the necessary function instance corresponding to the necessary function, obtain the running result of running the necessary function instance, verify the fully quantitative description information of the necessary function instance and the running result of the necessary function instance through the large model, and if the verification passes, obtain the next necessary function according to the execution sequence data of all necessary functions. According to the execution sequence data of all necessary functions, perform the above operations on each necessary function respectively. Among them, the running result of the instance corresponding to the necessary function whose execution sequence data is at the end is the processing result corresponding to the task request. It can be seen that obtaining the execution sequence data of all necessary functions through the large model, and verifying the fully quantitative description information of the necessary function instance and the running result of the necessary function instance through the large model, not only requires the function calling capability of the large model, occupies the data transmission volume of the large model, but also the process will increase the processing time of the instant delivery service request, affecting the rate at which the user obtains the processing result of the instant delivery service request. Therefore, it is first determined that the task request to be processed is an instant delivery service request.
[0050] Among them, determining that the task request to be processed is an instant delivery service request can be achieved in the following way: obtaining the object type of the target object for sending the task request to be processed; sending the task request to be processed and the object type of the target object for sending the task request to an instant delivery service analysis model, and obtaining the probability that the task request to be processed output by the instant delivery service analysis model contains instant delivery features; if the probability that the task request to be processed contains instant delivery features is greater than a preset probability, determining that the task request to be processed is an instant delivery service request.
[0051] The instant delivery service analysis model is a model obtained by training with historical task requests and the object type of the target object that sends the historical task requests as sample data. The probability of the instant delivery feature contained in the task request to be processed is related to the instant delivery feature contained in the task request and the object type of the target object. If the object type of the target object is a customer, and the task request to be processed is a task request for a customer to place an order on the instant delivery service platform, or a task request for a customer to pick up the ordered goods, then the task request belongs to an instant delivery service request. Instant delivery service platforms, such as offline food delivery platforms, require the offline food delivery platform to provide customers with corresponding demand pages within a preset time for tasks such as customers ordering the required meals and customers picking up meals, so that customers can complete the corresponding operations. For another example, in an online medicine ordering platform, customers order the required medicines and customers pick up medicines because they have the need to obtain the relevant items immediately. Therefore, if a customer makes the above task request, it means that the task request is an instant delivery service request, and there is a requirement for the execution subject to process the above task request.
[0052] If the object type of the target object is a merchant, and the task request to be processed is a merchant's order-taking task request in the instant delivery service platform, or a merchant's order-issuing task request, then the task request belongs to an instant delivery service request. For example, an online food delivery platform contains multiple order tasks that have been completed by customers, which belong to the target merchant's order and require the merchant to perform an order-taking operation. After the merchant prepares the delivery object of the order, the commodity issues a single task request. The order of the online food delivery platform has requirements for the processing time from placing an order to the user receiving the goods. Therefore, each processing link needs to reduce the processing time as much as possible to improve the processing rate of the entire task chain. Therefore, the merchant's order-taking task request and order-issuing task request are both instant delivery service requests. If the object type of the target object is a delivery resource, the task request to be processed is a delivery resource order-taking task request in the instant delivery service scenario, a task request to collect a delivery object from a merchant, or a task request to send a delivery object to a user. For example, an online food delivery platform contains multiple merchant order-issuing tasks that have completed the preparation of goods, and a delivery resource is required to collect the order and deliver it. Delivery resource order-taking task requests, order-pickup task requests, and order-delivery task requests are all instant delivery service requests.
[0053] According to the instant delivery features contained in the pending task request and the object type of the target object to which the pending task request is sent, the task request is determined to be an instant delivery service request. For instant delivery service requests, it is necessary to increase the rate at which the execution subject obtains the processing results of the task request. This application improves the rate at which the execution subject obtains the processing results of the task request by increasing the rate at which the large model returns the execution sequence data of all necessary functions required to run to process the task request and increasing the verification rate of the large model for all necessary functions, thereby improving the user experience of the target object.
[0054] After determining that the task request to be processed is an instant delivery service request, in order to increase the rate of obtaining the processing results of the instant delivery service request, the present application needs to save the time occupied by the above processing process of the large model, and improve the rate at which the large model processes the above tasks. Specifically, it can be processed in the following ways: The first task request processing method: determine whether the task request to be processed is an instant delivery service request; if so, obtain the verified functions that have been verified by the large model in historical task requests from all necessary functions returned by the large model, and obtain the remaining necessary functions of the necessary functions except the verified functions; obtain the verified function instance corresponding to the verified function, and the running result of running the verified function instance; obtain the remaining necessary function instances corresponding to the remaining necessary functions, and the running result of running the remaining necessary function instances; the fully quantitative description information of the remaining necessary function instances and the remaining necessary The running result corresponding to the function instance is verified by the big model to obtain the remaining necessary function instances verified by the big model; the processing result of the task request is obtained according to the running results of the verified function instances and the running results of the remaining necessary function instances verified by the big model; wherein the completed verification function is the function that has been verified by the big model in the historical task request for the fully quantitative description information of the function instance corresponding to the function and the running result obtained by running the function instance; the fully quantitative description information of the function instance is generated by the fully quantitative description information of the function and the parameters required to run the function, and the parameters required to run the function are parameters determined by the execution subject.
[0055] Among them, the obtaining of the verified function instance corresponding to the verified function and the running result of the verified function instance can be achieved in the following way: obtaining the fully quantitative description information of the verified function and obtaining the parameters required to run the verified function in the task request; generating a verified function instance corresponding to the verified function according to the fully quantitative description information of the verified function and the parameters required to run the verified function in the task request; running the verified function instance to obtain the running result of the verified function instance.
[0056] Among them, the verification operation of the fully quantitative description information of the remaining necessary function instance and the operating results corresponding to the remaining necessary function instance through the large model to obtain the remaining necessary function instance verified by the large model can be achieved in the following way: the fully quantitative description information of the remaining necessary function instance and the operating results corresponding to the remaining necessary function instance are sent to the large model, and the fifth verification result of the fully quantitative description information of the remaining necessary function instance and the operating results corresponding to the remaining necessary function instance returned by the large model is obtained; if the fifth verification result indicates that the large model has verified the fully quantitative description information of the remaining function instance and the operating results corresponding to the remaining function instance, it means that the remaining necessary verification function instance is the remaining necessary function instance that has been verified by the large model.
[0057] Among them, obtaining the processing result of the task request based on the running results of the verified function instance and the running results of the remaining necessary function instances verified by the large model can be achieved in the following way: according to the execution order data of all the necessary functions, determining the necessary function whose execution order is at the end of all the necessary functions; if the necessary function at the end is a verified function, taking the running result of the verified function instance corresponding to the verified function as the processing result of the task request; if the necessary function at the end is the remaining necessary function that has been verified by the large model, taking the running results of the remaining necessary function instances corresponding to the remaining necessary functions as the processing result of the task request.
[0058] After obtaining the processing result of the task request based on the above method, it also includes obtaining the confirmation operation of the target object for the processing result of the task request to complete the task request; if the necessary function at the end is a verified function, then the confirmation operation of obtaining the processing result of the target object for the task request includes: obtaining the confirmation operation of the target object for the running result of the verified function instance at the end; if the necessary function at the end is the remaining necessary function that has been verified by the big model, then the confirmation operation of obtaining the processing result of the target object for the task request includes: obtaining the confirmation operation of the target object for the running result of the remaining necessary function instance at the end. For example, the task request to be processed is "order the most popular pizza nearby", and the execution order data of all necessary functions required to run to process the task request returned by the big model is "get current location" -> "get location ranking" -> "search food using keywords". Among them, "get current location" belongs to the function that has been verified by the big model in the historical task request, so this time there is no need for the big model to verify the instance and running result of this function.
[0059] The first way to improve the task request processing rate is to obtain the execution order data of all necessary functions returned by the big model for processing the task request, and then the execution subject first analyzes all necessary functions to see if there are any functions that have been verified by the big model in historical task requests. If so, these verified functions do not need to be verified by the big model again. The remaining necessary functions except the verified functions are then verified by the big model. This method reduces the number of times the big model performs verification operations on necessary functions, saves the time for the big model to perform verification operations on necessary functions, and improves the rate at which the big model performs verification operations on necessary functions. It further improves the rate at which the execution subject obtains the processing results of task requests.
[0060] In this method, the target object confirms the processing result of the task request. Therefore, after the running parameters and running results that have been verified by the function instance are confirmed by the target object, the accuracy of the running parameters and running results that have been verified by the function instance when processing the task request can be guaranteed.
[0061] In addition, it also includes a second method for processing task requests: determine whether the task request to be processed is an instant delivery service request; if so, predict multiple candidate functions that need to be run to process the task request, obtain the verified functions among the multiple candidate functions that have been verified by the large model in historical task requests, and obtain the remaining necessary functions among the multiple candidate functions except the verified functions; obtain a first data volume corresponding to the task request, a fourth data volume of lightweight information corresponding to the multiple candidate functions contained in the lightweight information list, and a third data volume corresponding to the execution order data of all necessary functions returned by the large model; add the first data volume, the fourth data volume and the third data volume to obtain the first Second comprehensive data volume; determine whether the second comprehensive data volume is less than the upper limit of the data transmission volume of the large model; if so, continue to determine whether the difference between the upper limit of the data transmission volume and the second comprehensive data volume is greater than a fourth preset difference threshold; if so, send the task request, the lightweight information list, and the fully quantitative description information of the instance of at least one of the multiple remaining necessary functions and the running result of the instance of the at least one remaining necessary function to the large model at the same time, and obtain the execution sequence data of all the necessary functions returned by the large model, as well as the sixth verification result of the fully quantitative description information of the instance of at least one remaining necessary function and the running result of the instance of the at least one remaining necessary function.
[0062] For example, the task request to be processed is "Order the most popular pizza nearby", and the multiple candidate functions that need to be run include: "Get current location", "Get location ranking", "Search for food using keywords", and "Page jump function". Among them, "Get current location" and "Get location ranking" are functions that have been verified by the big model in historical task requests, so there is no need for the big model to verify the instances and running results of these two functions this time. Therefore, when sending a lightweight information list to the big model, if the sum of the data volume of the task request, the data volume of the lightweight information list, and the predicted data volume of the execution sequence data is less than the upper limit of the data transmission quantity of the big model, then when sending the task request and the lightweight information list to the big model, the full quantitative description information and running results of the unprocessed function instances can also be generated at the same time, and the big model will return the execution sequence data and the verification results of the function at the same time. This method can reduce the number of interactions between the execution subject and the big model.
[0063] If the operation of the at least one remaining necessary function is based on the operation result of another necessary function among all the necessary functions, then the task request, the lightweight information list, and the fully quantitative description information of the instance of at least one remaining necessary function among the multiple remaining necessary functions and the operation result of the instance of the at least one remaining necessary function are sent to the large model at the same time, including: sending the task request, the lightweight information list, and the fully quantitative description information of the instance of at least one remaining necessary function among the multiple remaining necessary functions to the large model at the same time; the operation parameters in the instance of the at least one remaining necessary function are incomplete operation parameters. If the operation parameters of the function sent to the large model at the same time are obtained based on the operation results of other functions, the instance of the function sent to the large model this time does not contain all of its operation parameters, and the large model verifies the function instance containing incomplete operation parameters.
[0064] The second way to improve the processing rate of task requests is that before the execution subject sends the task request and the lightweight information list to the large model, it first analyzes and obtains multiple candidate functions required to process the task request, and then compares the multiple candidate functions with the historical function list corresponding to the historical task request to determine the historical functions among the multiple candidate functions that have been verified by the large model in the historical task request. For the historical functions that have completed the verification, there is no need for the large model to verify them again this time. If the sum of the data volume of the task request, the data volume of the lightweight information list, and the data volume of the predicted execution order data is less than the upper limit of the data transmission volume of the large model, the full quantitative description information of at least one remaining function instance in the multiple candidate functions and its running results can also be added and sent to the large model for verification at the same time. This process can reduce the number of information exchanges between the execution subject and the large model, and also reduce the number of verifications of the candidate functions by the large model, thereby saving the time for the large model to verify the candidate functions, improving the verification rate of the candidate functions by the large model, and further improving the rate at which the execution subject obtains the processing results of the task request.
[0065] In addition, a third method for processing task requests is also included: determining whether the task request to be processed is an instant delivery service request; if so, splitting the task request into multiple sub-task requests; determining whether there are matching historical task requests that have been processed by the large model among the multiple sub-task requests, and if so, obtaining the remaining sub-task requests to be processed in the multiple sub-task requests except the matching historical task requests; sending the task request and the lightweight information list to the large model that can provide function calling capabilities, and obtaining the execution order data of all necessary functions returned by the large model for processing the task request, including: sending the remaining sub-task requests to be processed and the lightweight information list to the large model, and obtaining the execution order data of all necessary functions returned by the large model for processing the remaining sub-task requests to be processed.
[0066] The third way to improve the task request processing rate is that the execution subject splits the task request to be processed and obtains multiple pending subtasks. If some of the pending subtask requests among the multiple pending subtask requests are historical task requests that have been processed by the big model, there is no need for the big model to return the execution order data of the pending subtask request again. It is only necessary for the big model to return the execution order data of all necessary functions required to run the subtask request for the subtask request that has not been processed before. For example, the pending task request is "help me place an order for the hamburger package of YYY nearby", which belongs to the instant delivery service request. The task request is split into multiple pending subtask requests, including: the first pending subtask request is "help me search for the hamburger package page of YYY nearby", the second pending subtask request is "jump the hamburger package page to the bill of lading page for the hamburger package", and the third pending subtask request is "complete the order operation on the bill of lading page for the hamburger package". The first pending subtask request and the third subtask request in the above pending subtask requests both have corresponding historical task requests. The second pending subtask request is a subtask request that has not been processed by the large model. The large model is used to analyze the second pending subtask request to determine the execution order data of all necessary functions required to run it, so as to reduce the data calculation amount of the large model for the task request and improve the processing rate of the large model for the task request.
[0067] This method reduces the amount of data calculation required by the large model to determine the execution order data of all necessary functions required for the task request to run. For the interaction between the execution subject and the large model, because the network transmission rate is low or the large model needs to process a large number of task requests, the third method is used to reduce the amount of data calculation required by the large model for each task request, that is, to increase the processing rate of the large model for task requests, and further increase the rate at which the execution subject obtains the processing results of the task request.
[0068] First embodiment
[0069] The first embodiment of the present application provides a task request processing method. The specific flow chart is as follows: Figure 6 As shown, it is a flowchart of a task request processing method provided in the first embodiment of the present application. Figure 6 The task request processing method shown includes: step S601 to step S603. In the first embodiment, the execution subject of the task request processing method can be a user end or a server end that provides services to users. The services provided to users can be online to offline services, such as takeaway services, in-store services, and product ordering services.
[0070] The execution subject cannot directly obtain all the necessary functions required to run and determine the execution order data of all necessary functions for the task request proposed by the user. Therefore, the execution subject needs to use the function calling capability of the large model to determine the execution order data of all necessary functions required to run to process the task request. Based on the influence of the upper limit of the data transmission amount allowed by the function calling capability of the large model, the execution subject needs to process the function information required to process the task request, obtain the lightweight information corresponding to the function, and generate a lightweight information list from multiple lightweight information. Send the task request and the lightweight information list to the large model, and obtain the execution order data of all necessary functions returned by the large model, which is also the lightweight information corresponding to the function. Therefore, the number of functions sent to the large model can be increased, and the large model can determine all necessary functions and the execution order data of all necessary functions at one time. Improve the efficiency of the large model in determining the execution order data of all necessary functions required to run by the execution subject to process the task request.
[0071] Step S601: Get the task request to be processed. This step is to get the task request to be processed, so as to determine the execution order data of all necessary functions that the execution subject needs to run to process the task request through the large model. Step S602: Get a lightweight information list, the lightweight information in the lightweight information list is used to identify the function of the execution subject that processes the task request, and the data volume of the lightweight information is less than the data volume of the full quantitative description information of the function. This step is to get the lightweight information list, specifically, after processing the full quantitative description information of the function, lightweight information is obtained, and a lightweight information list is generated from multiple lightweight information. The data volume of the lightweight information is less than the data volume of the full quantitative description information of the function. Therefore, sending the obtained lightweight information list to the large model can reduce the amount of data occupied by the information of each function, thereby increasing the number of functions sent to the large model.
[0072] Among them, the information types contained in the lightweight information in the lightweight information list include at least the following two types, so obtaining the lightweight information list can be achieved in at least the following two ways: The first way to obtain the lightweight information list, this way obtains the first type of lightweight information: extract partial description information of the function from the full description information of the function possessed by the execution subject, the partial description information of the function includes the name information of the function and parameter information used to describe the functions that can be implemented by the function; use the partial description information of the function as the lightweight information corresponding to the function, and generate the lightweight information list according to the partial description information of multiple functions. The full description information of a function is all the execution code information of the function. The partial description information of a function is the partial description information extracted from the full description information of the function. Please refer to Figure 2-C The partial description information 102 of the first function includes the name information of the function and the parameter information used to describe the functions that can be realized by the function. Figure 2-C The fully quantized description information 103 of the function includes the complete execution code of the function. Obtaining the lightweight information corresponding to the function, and then generating a lightweight information list according to the plurality of lightweight information, is based on the influence of the upper limit of the data transmission amount allowed by the function calling capability of the large model.
[0073] The obtaining of lightweight information corresponding to the function can be specifically implemented in the following manner: obtaining the predicted number of candidate functions that the execution subject has for processing the task request, and obtaining the data amount corresponding to the fully quantitative description information of the predicted number of candidate functions; predicting the predicted data amount corresponding to the execution order data returned by the large model for processing all necessary functions allowed by the task request; obtaining the data amount corresponding to the fully quantitative description information of the predicted number of candidate functions and the total data amount of the predicted data amount; determining the target data amount corresponding to the lightweight information list according to the total data amount and the upper limit of the data transmission amount corresponding to the large model; determining the target sub-data amount of the lightweight information corresponding to each function according to the target data amount corresponding to the lightweight information list and the predicted number of candidate functions that the execution subject has for processing the task request; determining the function information contained in the lightweight information corresponding to each function according to the target sub-data amount of the lightweight information corresponding to each function.
[0074] According to the total data volume and the upper limit of the data transmission volume corresponding to the large model, the target data volume corresponding to the lightweight information list is determined. Specifically, it can be determined whether the total data volume is greater than the upper limit of the data transmission volume. If greater than, the target data volume corresponding to the lightweight information list is determined according to the upper limit of the data transmission volume and the predicted data volume. For example, the upper limit of the data transmission volume corresponding to the large model is Token (number of words) as an example, and the upper limit of the data transmission volume corresponding to the large model is 4096 words. The total data volume of the data volume corresponding to the full quantitative description information of the candidate function of the predicted number and the predicted data volume is 6408 words. Because 6408 is greater than 4096, it is necessary to use a lightweight information list instead of the full quantitative description information of the function. The upper limit of the data transmission volume is subtracted from the predicted data volume corresponding to the execution sequence data to obtain the target data volume corresponding to the lightweight information list. For example, if the predicted data volume corresponding to the execution sequence data is 1000 words, the target data volume corresponding to the lightweight information list is 3096 words.
[0075] The number of functions contained in different task requests processed by the execution subject is different. According to the target data volume corresponding to the lightweight information list and the predicted number of candidate functions that the execution subject has for processing the task request, the target sub-number of lightweight information corresponding to each function is determined. Each function can realize different functions, and the type and number of parameters of the functions that can be realized are also different. The amount of sub-data required for the lightweight information corresponding to each function is also different, which needs to be analyzed specifically according to the specific function.
[0076] Based on the target data volume of the lightweight information list and the predicted number of candidate functions, the content of the lightweight information can be determined. If the predicted number of the candidate functions is not greater than the first predicted number threshold, it is determined that the lightweight information corresponding to each function may contain the name information of the function and the parameter information used to describe the achievable functions of the function. If the predicted data of the candidate function is greater than the first predicted number threshold and not greater than the second predicted number threshold, it is determined that the lightweight information corresponding to each function may contain the name information of the function. If the predicted number of the candidate function is greater than the second predicted data threshold, it is determined that the lightweight information corresponding to each function is the numbering information of each function.
[0077] Therefore, in addition to the first method of generating a lightweight information list, a second method of obtaining a lightweight information list can also be used, which obtains the second type of lightweight information: numbering the functions of the execution subject to obtain the numbering information corresponding to each function; and using the numbering information corresponding to each function as the lightweight information corresponding to each function.
[0078] In addition, the number of functions included in the lightweight information list obtained in the present application can be obtained by, on the one hand, performing lightweight information processing on all functions of the execution subject to obtain a lightweight information list; on the other hand, it can be obtained by performing lightweight information processing on some functions in the execution subject to obtain a lightweight information list. Based on the different numbers of functions included in the lightweight information list, the lightweight information list can be obtained in at least two ways as follows: The first: the lightweight information list contains lightweight information of all functions of the execution subject. Specifically, the acquisition of the lightweight information list includes: obtaining lightweight information of all functions of the execution subject, and generating the lightweight information list. The second: the lightweight information list contains lightweight information of some functions of the execution subject. Specifically, the acquisition of the lightweight information list includes: according to the semantic information of the task request, preliminarily predicting multiple candidate functions required to run to process the task request among all functions of the execution subject, obtaining lightweight information corresponding to the multiple candidate functions, and generating the lightweight information list.
[0079] Step S603: Send the task request and the lightweight information list to the large model that can provide function call capabilities, and obtain the execution order data of all necessary functions returned by the large model for processing the task request, wherein all necessary functions are functions among all functions identified by the lightweight information list, and the total data volume of the lightweight information list and the execution order data is not higher than the upper limit of the data transmission volume allowed by the large model for the execution subject to provide function call capabilities for processing the task request. After obtaining the task request to be processed in step S601 and obtaining the lightweight information list in step S602, step S603 sends the task request and the lightweight information list to the large model, and determines the execution order data of all necessary functions required for the execution subject to process the task request with the help of the large model.
[0080] Among them, before sending the lightweight information list to the large model, the large model needs to be trained in advance. Specifically, the large model is trained using the lightweight information and the full quantitative description information of the function to obtain a large model that can identify the correspondence between the lightweight information and the full quantitative description information of the function. After the large model is trained on the correspondence between the lightweight information and the full quantitative description information of the function, in the large model application stage, after the execution subject sends the lightweight information list to the large model, the large model can identify the full quantitative description information of the function represented by the lightweight information based on the lightweight information in the lightweight information list. Based on the different types of information contained in the lightweight information in the lightweight information list, the correspondence between the lightweight information and the full quantitative description information of the function is also different. Specifically, it includes at least the following two types:
[0081] The first type is that the lightweight information in the lightweight information list is partial description information of the function, and the partial description information of the function includes the name information of the function and parameter information used to describe the functions that the function can implement. The correspondence between the lightweight information and the full description information of the function includes: the correspondence between the partial description information of the function and the full description information of the function. For example, Figure 2-C Partial description information 102 of the first function, Figure 2-C The fully quantitative description information 103 of the function is used to train the large model in advance on the correspondence between the partial description information of the function and the fully quantitative description information of the function. In the application stage, the large model can identify the fully quantitative description information corresponding to the function based on the partial description information corresponding to each function contained in the obtained lightweight information list, thereby analyzing and determining the execution order data of all necessary functions that need to be run to process the task request. Based on the first type of correspondence, in step S603, the task request and the lightweight information list are sent to the large model that can provide function call capabilities, and the execution order data of all necessary functions that need to be run to process the task request returned by the large model is obtained, specifically: the task request and the list of partial description information of the function are sent to the large model, and the arrangement order of the partial description information of all necessary functions returned by the large model is obtained as the execution order data of all necessary functions.
[0082] Continue to combine Figure 2-C To explain, Figure 2-C The first lightweight information list 101 includes the partial description information corresponding to each function, for example, api1 represents the partial description information of the function with the function name 1. In the case where there are a large number of functions included in the lightweight information list, obtaining the lightweight information list in this way can allow the large model to obtain a large number of functions while meeting the upper limit of the data transmission volume of the large model, so that the large model can analyze all the necessary functions and their arrangement order data required to process the task request at one time according to the lightweight information list, and return the execution order data of all necessary functions.
[0083] The second type is that the lightweight information in the lightweight information list is the number information of the function. The correspondence between the lightweight information and the full quantitative description information of the function includes: the correspondence between the number information of the function and the full quantitative description information of the function. For example, Figure 2-DThe lightweight information represented by the second lightweight information list 104 is the numbering information of the function. The correspondence between the numbering information of the function and the fully quantitative description information of the function is pre-trained for the large model. During the application stage, the large model can identify the fully quantitative description information corresponding to the function based on the numbering information of each function contained in the obtained lightweight information list, thereby analyzing and determining the execution order data of all necessary functions that need to be run to process the task request. Based on the second type of correspondence, in step S603, the task request and the lightweight information list are sent to the large model that can provide function call capabilities, and the execution order data of all necessary functions returned by the large model for processing the task request is obtained. Specifically, the task request and the list of function numbering information are sent to the large model, and the arrangement order of the numbers of all necessary functions returned by the large model is obtained as the execution order data of all necessary functions. Continue to combine Figure 2-D To explain, Figure 2-D The second type of lightweight information list 104, wherein the lightweight information contained therein is the number information of each function, for example, 1 represents the number information of function 1. The second type of lightweight information is obtained, and the lightweight information list is generated, and the information of all functions possessed by the execution subject can be stored in the lightweight information list. After the large model obtains the lightweight information list, it is more conducive to analyzing and obtaining all necessary functions and their arrangement order data required to process the task request according to the number information of all functions possessed by the execution subject, and returning the execution order data of all necessary functions.
[0084] The above is the description process of the correspondence between the pre-trained lightweight information of the large model and the fully quantitative description information of the function. The following continues to describe the specific process of sending the task request and the lightweight information list to the large model that can provide function call capabilities. Based on the influence of the upper limit of the data transmission volume allowed by the large model for the execution subject to process the task request to provide function call capabilities, the lightweight information list is provided to the large model here. Among them, based on the comparison between the data volume of the lightweight information list, the data volume of the task request, and the sum of the data volume of the execution sequence data, and the upper limit of the data transmission volume, the data volume type of the function contained in the lightweight information list sent to the large model can be determined here in the following way. The details are as follows: obtaining a first data volume corresponding to the task request, a second data volume of fully quantitative description information corresponding to the function contained in the lightweight information list, and a third data volume corresponding to the execution order data of all necessary functions required to run for processing the task request returned by the large model; adding the first data volume, the second data volume and the third data volume to obtain a first comprehensive data volume; obtaining the upper limit of the data transmission volume allowed by the large model for the execution subject to provide function call capability for processing the task request; sending the task request and the lightweight information list to the large model that can provide function call capability, specifically: judging whether the first comprehensive data volume is greater than the upper limit of the data transmission volume, and if so, sending the task request and the lightweight information list to the large model.
[0085] The upper limit of the data transmission volume corresponding to the large model is expressed as the sum of the input data volume and the output data volume in one analysis process of the large model is not greater than the upper limit of the data transmission volume. The first data volume corresponding to the task request, the second data volume of the fully quantitative description information corresponding to the function contained in the lightweight information list, and the third data volume corresponding to the execution order data are aggregated to obtain the first comprehensive data volume. The relationship between the first comprehensive data volume and the upper limit of the data transmission volume corresponding to the large model is analyzed to determine whether to provide the lightweight information list or the list of fully quantitative description information of the function to the large model.
[0086] If the first comprehensive data volume is greater than the upper limit of the data transmission volume, it means that the proportion of the second data volume of the fully quantitative description information corresponding to the function contained in the lightweight information list in the first comprehensive data volume is greater than the preset proportion. If the fully quantitative description information of the function is sent to the large model, due to the influence of the upper limit of the data transmission volume of the large model, the large model has no available data transmission volume for returning the execution sequence data. For example, the first comprehensive data volume is 10590 words, the upper limit of the data transmission volume is 4096 words, and 10590 words is greater than 4096 words. Therefore, it is necessary to lightweight the fully quantitative description information of the function, obtain the lightweight information corresponding to the function, and generate a lightweight information list from multiple lightweight information. The task request and the lightweight information list are sent to the large model, so that the sum of the input data volume and the output data volume of the large model is not greater than the upper limit of the data transmission volume.
[0087] In addition, if the first comprehensive data volume is less than or equal to the upper limit of the data transmission volume, the task request and the fully quantitative description information corresponding to the function contained in the lightweight information list are sent to the large model. The first comprehensive data volume is less than or equal to the upper limit of the data transmission volume, indicating that the proportion of the second data volume of the fully quantitative description information corresponding to the function contained in the lightweight information list in the first comprehensive data volume is less than or equal to the preset proportion. Even if the fully quantitative description information of the function is sent to the large model, after occupying part of the data transmission volume of the large model, the remaining data transmission volume of the large model can meet the data volume required to return the execution sequence data. For example, the first comprehensive data volume is 3590 words, the upper limit of the data transmission volume is 4096 words, and 3590 words are less than 4096 words. Therefore, there is no need to perform lightweight processing on the fully quantitative description information of the function. The task request and the list of the fully quantitative description information of the function are sent to the large model, and the sum of the input data volume and the output data volume of the large model is not greater than the upper limit of the data transmission volume.
[0088] In addition, when the first comprehensive data volume is greater than the upper limit of the data transmission volume, it also includes the following situation: if the first comprehensive data volume is greater than the upper limit of the data transmission volume, and the difference between the first comprehensive data volume and the upper limit of the data transmission volume is less than or equal to the first preset difference threshold, then obtain the full quantitative description information of the first partial function in the function included in the lightweight information list and the lightweight information corresponding to the second partial function; send the task request, the full quantitative description information of the first partial function and the lightweight information corresponding to the second partial function to the large model, wherein the first partial function is the remaining functions in the lightweight information list except the second partial function.
[0089] The first comprehensive data volume is greater than the upper limit of the data transmission volume, and the difference between the first comprehensive data volume and the upper limit of the data transmission volume is less than or equal to the first preset difference threshold. For example, the first comprehensive data volume is 5990 words, the upper limit of the data transmission volume is 4096 words, and the difference between the first comprehensive data volume and the upper limit of the data transmission volume is 1894 words. The first preset difference threshold can be set to 2000 words. Then, the fully quantitative description information of the first part of the functions and the lightweight information of the second part of the functions in all the functions included in the lightweight information list can be sent to the large model. Therefore, the first comprehensive data volume is less than the upper limit of the data transmission volume, which can meet the requirement that the sum of the input data volume and the output data volume of the large model is less than or equal to the upper limit of the data transmission volume.
[0090] The obtaining of the fully quantitative description information of the first part of the functions included in the lightweight information list and the lightweight information corresponding to the second part of the functions can be achieved in the following way: obtaining the historical function list returned when the large model processes the historical task request; judging whether there is a historical function in the historical function list among the functions included in the lightweight information list; if so, taking the historical function in the lightweight information list as the second part of the functions, and taking the functions in all the lightweight information lists except the historical function as the first part of the functions.
[0091] The historical function list returned by processing the historical task request contains all the historical functions that need to be run to process the historical task request, as well as the execution order data of all historical functions. If the functions included in the lightweight information list contain historical functions in the historical function list, then the function belongs to a function that has been analyzed by the large model, and the large model has stored the correspondence between the lightweight information of the function and the fully quantitative description information of the function. For the part of the functions included in the lightweight information list that does not belong to the historical functions in the historical function list, it means that the large model has not analyzed this part of the function, so it is not clear what the correspondence between the lightweight information corresponding to this part of the function and the fully quantitative description information of the function is, so the fully quantitative description information of this part of the function can be sent to the large model. Therefore, the first part of the function can be a function that has not been analyzed by the large model in processing the historical task request, and the second part of the function can be a function that has been analyzed by the large model in processing the historical task request, and the correspondence between the fully quantitative description information of this part of the function and its corresponding lightweight information has been stored.
[0092] The above is to determine the data type of the function included in the lightweight information list sent to the large model based on the comparison between the data volume of the lightweight information list, the data volume of the task request, and the sum of the data volume of the execution sequence data, and the upper limit of the data transmission volume.
[0093] In step S602, based on the different numbers of functions included in the lightweight information list, the lightweight information list can be obtained in at least two ways as follows: First: the lightweight information list contains lightweight information of all functions possessed by the execution subject. Specifically, obtaining the lightweight information list includes: obtaining lightweight information of all functions possessed by the execution subject, and generating the lightweight information list. Correspondingly, in step S603, the execution order data of all necessary functions required to run for processing the task request returned by the large model is obtained in the following way: according to the semantic information of the task request, the execution order data of all necessary functions required to run for processing the task request is obtained from the lightweight information of all functions contained in the lightweight information list.
[0094] The lightweight information list contains lightweight information corresponding to all functions of the execution subject. After sending the lightweight information list to the large model, the large model obtains the lightweight information corresponding to each function from the lightweight information list, and obtains the full quantitative description information corresponding to each function based on the correspondence between the lightweight information and the full quantitative description information of the function. Analyze the semantic information corresponding to the full quantitative description information of each function to determine the functions implemented by each function. Finally, compare and analyze the functions implemented by all functions respectively with the functions that the functions required to process the task request should have, and obtain the execution order data of all necessary functions. For example, the execution subject generates a lightweight information list based on the lightweight information corresponding to all functions (for example, 200 functions) it has. The large model obtains the lightweight information list, analyzes the semantic information of all functions, selects all necessary functions required to run to process the task request from all functions, and determines the execution order data of all necessary functions.
[0095] The second type: the lightweight information list contains lightweight information of some functions possessed by the execution subject. Specifically, the acquisition of the lightweight information list includes: preliminarily predicting multiple candidate functions required to run to process the task request among all functions possessed by the execution subject according to the semantic information of the task request, acquiring lightweight information corresponding to the multiple candidate functions, and generating the lightweight information list. Correspondingly, in step S603, the execution order data of all necessary functions required to run to process the task request returned by the large model is obtained in the following manner: according to the semantic information of the task request, the execution order data of all necessary functions required to run to process the task request is obtained from the lightweight information corresponding to the multiple candidate functions contained in the lightweight information list.
[0096] Before the execution subject sends the lightweight information list to the large model, it first determines the multiple candidate functions required to process the task request based on the semantic information of each function and the semantic information of the task request. Among them, the number of multiple candidate functions required to process the task request is greater than the number of all necessary functions returned by the large model. The lightweight information list contains the lightweight information corresponding to the multiple candidate functions of the execution subject. After sending the lightweight information list to the large model, the large model obtains the lightweight information corresponding to the multiple candidate functions in the lightweight information list, and obtains the fully quantitative description information corresponding to the multiple candidate functions based on the correspondence between the lightweight information and the fully quantitative description information of the function. The semantic information corresponding to the fully quantitative description information of each candidate function is analyzed to determine the function corresponding to each candidate function. Finally, the functions corresponding to the multiple candidate functions are compared and analyzed with the functions that the functions required to process the task request should have, and the execution order data of all necessary functions are obtained. For example, the execution subject selects multiple candidate functions (for example, 20) from all the functions it has (for example, 200), and generates a lightweight information list according to the lightweight information corresponding to the multiple candidate functions. The large model obtains the semantic information of multiple candidate functions in the lightweight information list, selects all necessary functions required to run to process the task request from the multiple candidate functions, and determines the execution order data of all necessary functions.
[0097] After obtaining the execution order data of all necessary functions returned by the large model for processing the task request, the execution subject also calls all necessary functions in sequence according to the execution order data of all necessary functions to obtain the processing result of the task request. Calling all necessary functions in sequence can be calling the full quantitative description information of the necessary function instance corresponding to one necessary function at a time. The full quantitative description information of a necessary function instance is less than the upper limit of the data transmission amount corresponding to the large model, so it can meet the condition of the data transmission amount limit of the large model. In addition, it can also be calling the full quantitative description information of the necessary function instances corresponding to multiple necessary functions at a time, and the data amount of the full quantitative description information of the multiple necessary function instances is less than the upper limit of the data transmission amount. The following are described separately.
[0098] A first calling method of calling necessary functions in sequence: calling all necessary functions in sequence according to the execution order data of all necessary functions to obtain the processing result of the task request can be implemented as follows: obtaining the first necessary function to be run among all necessary functions according to the execution order data of all necessary functions; obtaining the fully quantitative description information of the first necessary function instance corresponding to the first necessary function, and obtaining the first running result obtained by running the first necessary function instance; sending the fully quantitative description information of the first necessary function instance and the first running result to the large model, and obtaining the first verification result of the fully quantitative description information of the first necessary function instance and the first running result returned by the large model; if the first verification result indicates that the large model If the model has verified the fully quantitative description information of the first necessary function instance and the first running result, then according to the execution order data of all the necessary functions, obtain the second necessary function to be run after the first necessary function of all the necessary functions; obtain the second verification result of the fully quantitative description information of the second necessary function instance corresponding to the second necessary function and the second running result corresponding to the second necessary function instance returned by the large model; if the second verification result indicates that the large model has verified the fully quantitative description information of the second necessary function instance and the second running result, and the order of the second necessary function to be run is at the end of the execution order data of all the necessary functions, then use the second running result as the processing result of the task request.
[0099] The step of obtaining the fully quantitative description information of the first necessary function instance corresponding to the first necessary function and obtaining the first operating result obtained by running the first necessary function instance can be achieved in the following manner: obtaining the fully quantitative description information of the first necessary function and obtaining the parameters required to run the first necessary function; generating the fully quantitative description information of the first necessary function instance according to the fully quantitative description information of the first necessary function and the parameters required to run the first necessary function, and running the first necessary function instance to obtain the first operating result corresponding to the first necessary function instance.
[0100] First, the process of calling the first necessary function is described in conjunction with the example mentioned in step S404 to step S406 in the scenario embodiment. In the process of calling the first necessary function api4, the full quantitative description information of api4 and the parameters required to run api4 are obtained, and the api4 instance is obtained according to the full quantitative description information of api4 and the parameters required to run api4. The full quantitative description information of api4 represents the complete execution code of api4, such as Figure 2-CThe fully quantified description information 103 of the function in is shown. The fully quantified description information of the api4 instance represents the complete execution code of api4 and the complete execution code of the parameters required to run api4. For example, the function represented by api4 is C=a+b, and the parameters for running api4 are, for example, a=2, b=3. Then, the first necessary function instance is run to obtain the first running result corresponding to the first necessary function instance. Running the api4 instance is the complete execution code of api4 plus the complete execution code of the parameters required to run api4, and the first running result is C=5. Finally, the large model performs verification processing. Specifically, the complete execution code of the api4 instance (that is, the complete execution code of api4 and the complete execution code of the parameters required to run api4) and the first running result C=5 are all sent to the large model. The large model analyzes whether the complete execution code of the api4 instance is accurate and whether the first running result C=5 is accurate, and then feeds back the first verification result. The first verification result indicates that the verification has passed, that is, the complete execution code of the api4 instance (that is, the complete execution code of api4 and the complete execution code of the parameters required to run api4) and the first running result C=5 are correct.
[0101] On this basis, based on the running result of the first necessary function, the second necessary function is called. In the process of calling the second necessary function, it specifically includes generating the fully quantitative description information of the second necessary function instance, running the second necessary function instance, and obtaining the second running result corresponding to the second necessary function instance. Specifically as follows: obtain the fully quantitative description information of the second necessary function, and obtain the parameters required to run the second necessary function; generate the fully quantitative description information of the second necessary function instance according to the fully quantitative description information of the second necessary function and the parameters required to run the second necessary function, and run the second necessary function instance to obtain the second running result corresponding to the second necessary function instance; the second verification result of the fully quantitative description information of the second necessary function instance corresponding to the second necessary function and the second running result corresponding to the second necessary function instance returned by the large model is specifically: send the fully quantitative description information of the second necessary function instance and the second running result to the large model, and obtain the fully quantitative description information of the second necessary function instance and the second running result returned by the large model. The second necessary function calling process is similar to the first necessary function calling process, which will not be repeated here.
[0102] The above describes the process of calling one necessary function at a time. In this process, each time the large model calls one necessary function instance, the sum of the input data volume and the output data volume of the large model is not greater than the upper limit of the data transmission volume corresponding to the large model. In addition, the large model can also call multiple necessary function instances at the same time, as long as the sum of the input data volume and the output data volume of the large model is not greater than the upper limit of the data transmission volume corresponding to the large model. The following describes a second calling method of calling necessary functions in sequence: specifically, obtaining the upper limit of the amount of data transmission allowed by the large model for the execution entity to provide function calling capabilities for processing the task request; taking the total amount of data corresponding to the fully quantitative description information of the first necessary function instance, the amount of data corresponding to the first running result, and the total amount of data corresponding to the predicted first prediction verification result as the first predicted data amount; taking the total amount of data corresponding to the fully quantitative description information of the second necessary function instance, the amount of data corresponding to the second running result, and the total amount of data corresponding to the predicted second prediction verification result as the second predicted data amount; if the sum of the first predicted data amount and the second predicted data amount is less than or equal to the upper limit of the amount of data transmission, then sending the fully quantitative description information and the first running result of the first necessary function instance, and the fully quantitative description information and the second running result of the second necessary function instance to the large model at the same time to obtain the first verification result and the second verification result returned by the large model.
[0103] For example, the upper limit of the data transmission volume corresponding to the large model is 4096 words, the first predicted data volume is 1500 words, and the second predicted data volume is 1300 words. The sum of the first predicted data volume and the second predicted data volume is 2800 words, which is less than the upper limit of the data transmission volume. This shows that even if the large model calls the first necessary function instance and the second necessary function instance at the same time, the sum of the input data volume and the output data volume of the large model does not exceed the upper limit of the data transmission volume of the large model. Therefore, the verification rate of the large model for the necessary function instance can be improved by sending the full quantitative description information of the first necessary function instance and the first operation result, as well as the full quantitative description information of the second necessary function instance and the second operation result to the large model.
[0104] The first predicted data volume and the second predicted data volume are added to obtain the third predicted data volume. If the third predicted data volume is less than the upper limit of the data transmission volume, and the difference between the upper limit of the data transmission volume and the third predicted data volume is greater than the second preset difference threshold, the number of necessary function instances sent to the large model at the same time is increased until the total predicted data volume corresponding to the preset number of necessary function instances is less than the upper limit of the data transmission volume, and the difference between the upper limit of the data transmission volume and the total predicted data volume is less than the third preset difference threshold. For example, the second preset difference threshold can be set to 1000 words. Combined with the above example, the difference between the upper limit of the data transmission volume and the third predicted data volume is 1296 words. If the total predicted data volume corresponding to the third necessary function is less than 1296 words, the number of necessary function instances sent to the large model at the same time can be increased, that is, the first necessary function instance, the second necessary function instance, and the third necessary function instance are called at one time, and the large model verifies the above three necessary function instances at one time. This method reduces the number of interactions between the execution subject and the big model in the verification process for necessary function instances, reduces the verification time of the big model for the information of necessary function instances, and improves the verification efficiency of the big model for the information of necessary function instances.
[0105] The above is a description process of two calling modes in which the execution subject calls all the necessary functions in sequence according to the execution order data of all the necessary functions to obtain the processing result of the task request.
[0106] In addition, in order to reduce the randomness of the output results returned by the large model and increase the certainty of the output results, an embodiment of the present application also includes setting the output result stability parameter of the large model. Specifically, the output result stability parameter of the large model is set to a target parameter value, and the target parameter value is used to indicate that the probability that the output result returned by the large model is the target result is greater than a preset probability; correspondingly, the probability that the execution order data of all necessary functions required to run to process the task request is the target execution order data is greater than the preset probability. The output result stability parameter of the large model is used to indicate the balance between the certainty and randomness of the output results of the large model. The output result stability parameter is temperature, and the larger the temperature value, the greater the randomness of the output results of the large model. The smaller the temperature value, the more concentrated the output results of the large model and the greater the certainty. If the temperature value is set to 0, the large model will generate a fixed output result for each input information.
[0107] In an embodiment of the present application, the output result stability parameter of the large model is set to the target parameter value, and the target parameter value can be 0. Specifically, the execution subject sends the task request and the lightweight information list to the large model, and the execution order data of all necessary functions returned by the large model is a fixed result. Based on the fixed result, when the execution subject continues to send further questions related to the execution order data to the large model, the large model returns further fixed results based on the fixed result. This process enables the output result of the large model to return a fixed result based on a fixed direction, avoiding the situation where the output results of related problems are more random.
[0108] After obtaining the execution order data of all necessary functions required to run for processing the task request returned by the large model, the execution subject can also store the execution order data of all necessary functions corresponding to the task request to analyze and process the execution order data of all necessary functions required to run for subsequent other task requests. Specifically, store the execution order data of all necessary functions required to run for processing the task request to be processed; obtain the subsequent task request to be processed; if the feature data of the subsequent task request to be processed is feature data that matches the feature data of the task request to be processed, then use the execution order data of all necessary data corresponding to the task request to be processed as the execution order data of all necessary functions required to run for processing the subsequent task request to be processed.
[0109] In order to improve the efficiency of obtaining the execution order data of all necessary functions corresponding to other subsequent task requests, the execution subject classifies the task requests with the same characteristic data to avoid the large model analyzing each task request to determine the execution order data of all necessary functions required to run. The large model is used to analyze and process the execution order data of all necessary functions required to run for different types of task requests that have not been processed before. This improves the efficiency of the large model in determining the execution order data of all necessary functions required to run for the execution subject to process the task request.
[0110] Here, the subsequent other task requests are analyzed based on the execution order data of all necessary functions required to run for processing the pending task request. If the feature data of a subsequent task request to be processed in the subsequent other task requests matches the feature data of the pending task request, the execution order data of all necessary functions required to run for the pending task request can be used as the execution order data of all necessary functions required to run for processing the subsequent task request to be processed. For example, the pending task request is "order the most popular pizza nearby", and the subsequent task request to be processed is "order the most popular dumplings nearby". The two task requests belong to the same type of task requests, and the execution order data of all necessary functions required to run for processing the two task requests are also the same, which are "get Current Location (get current location) -> get Location Ranking (get location ranking) -> Seach Food With Keyword (search food with keywords)". Therefore, there is no need to send the subsequent task request to be processed to the large model again for analysis and processing, which improves the efficiency of obtaining the execution order data of all necessary functions required to run for processing task requests.
[0111] The analysis of whether the feature data of the task request to be processed subsequently matches the feature data of the task request to be processed can be performed in the following two ways:
[0112] The first task request feature data matching analysis method: if the feature data of the subsequent task request to be processed is the feature data that matches the feature data of the task request to be processed, then the execution order data of all the necessary data corresponding to the task request to be processed is used as the execution order data of all the necessary functions required to run for processing the subsequent task request to be processed, which can be implemented by the following first method: obtaining the type of the subsequent task request to be processed and the type of the task request to be processed; if the type of the subsequent task request to be processed is the task request type that matches the type of the task request to be processed, then determining that the feature data of the subsequent task request to be processed is the feature data that matches the feature data of the task request to be processed; using the execution order data of all the necessary data corresponding to the task request to be processed as the execution order data of all the necessary functions required to run for processing the subsequent task request to be processed. The type of the subsequent task request to be processed is the task request type that matches the type of the task request to be processed. For example, in the above example, the type of the subsequent task request to be processed and the type of the task request to be processed are both the task request type of "ordering the most popular food nearby". Therefore, all the necessary functions required to run and the execution order data of all the necessary functions for processing task requests of the same type are the same.
[0113] The second task request feature data matching analysis method: if the feature data of the subsequent task request to be processed is the feature data that matches the feature data of the task request to be processed, then the execution sequence data of all the necessary data corresponding to the task request to be processed is used as the execution sequence data of all the necessary functions required to run for processing the subsequent task request to be processed. It can also be implemented in the following second method: obtain the semantic information of the subsequent task request to be processed and the semantic information of the task request to be processed; if it is determined that the feature data of the subsequent task request to be processed is the feature data that matches the feature data of the task request to be processed based on the semantic information of the subsequent task request to be processed and the semantic information of the task request to be processed, then the execution sequence data of all the necessary data corresponding to the task request to be processed is used as the execution sequence data of all the necessary functions required to run for processing the subsequent task request to be processed. By comparing the semantic information of the two task requests, it is determined whether the feature data of the two task requests match. If they match, the same execution sequence data of all necessary functions can be used.
[0114] According to the semantic information of the subsequent task request to be processed and the semantic information of the task request to be processed, determining that the feature data of the subsequent task request to be processed is feature data matching the feature data of the task request to be processed can be achieved in at least the following two ways:
[0115] The first task request semantic analysis method: the method of determining, based on the semantic information of the subsequent task request to be processed and the semantic information of the task request to be processed, that the feature data of the subsequent task request to be processed is feature data that matches the feature data of the task request to be processed, includes: obtaining a first semantic vector value corresponding to the semantic information of the task request to be processed, and a second semantic vector value corresponding to the semantic information of the subsequent task request to be processed; if the semantic vector matching degree between the first semantic vector value and the second semantic vector value is greater than a preset semantic vector matching degree threshold, determining that the feature data of the subsequent task request to be processed is feature data that matches the feature data of the task request to be processed. Determine whether the semantic information of the two task requests matches by the similarity between the semantic vector values corresponding to the semantic information of the two task requests; if they match, the feature data of the two task requests match.
[0116] The second task request semantic analysis method: the execution sequence data of all necessary data corresponding to the task request to be processed is used as the execution sequence data of all necessary functions required to run for processing the subsequent task request to be processed, including: according to the semantic information of the task request to be processed, obtaining multiple subtasks to be processed required to process the task request to be processed; according to the semantic information of the subsequent task request to be processed, obtaining multiple subsequent subtasks to be processed required to process the subsequent task request to be processed; searching for matching subtasks to be processed that match the multiple subsequent subtasks to be processed respectively among the multiple subtasks to be processed corresponding to the task request to be processed; determining the execution order of the necessary functions required to run the subsequent subtask to be processed corresponding to the matching subtask to be processed in the necessary function list corresponding to the subsequent task request to be processed according to the execution order of the necessary functions required to run the matching subtask to be processed in the execution sequence data of all necessary functions; determining the execution sequence data of all necessary functions required to run for processing the subsequent task request to be processed according to the execution order of the necessary functions respectively corresponding to the multiple subsequent subtasks to be processed.
[0117] For example, the task request to be processed is "Help me place an order for YYY's hamburger set", and the task request to be processed later is "Help me place an order for XXX's hamburger set". The task request to be processed "Help me place an order for YYY's hamburger set" is split into multiple subtasks to be processed, including the first subtask to be processed "Open the list page of YYY stores near the user", the second subtask to be processed "Select the target YYY store on the YYY store list page", the third subtask to be processed "Select the target hamburger set on the detailed information page of the target YYY store", and the fourth subtask to be processed "Display the bill of lading page for the target hamburger set". The task request to be processed later is "Help me place an order for XXX's hamburger set" is split into multiple subtasks to be processed later, including the first subtask to be processed "Open the list page of XXX stores near the user", the second subtask to be processed "Select the target XXX store on the XXX store list page", the third subtask to be processed "Select the target hamburger set on the detailed information page of the target XXX store", and the fourth subtask to be processed "Display the bill of lading page for the target hamburger set".
[0118] The first subtask to be processed matches the first subsequent subtask to be processed, the second subtask to be processed matches the second subsequent subtask to be processed, the third subtask to be processed matches the third subsequent subtask to be processed, and the fourth subtask to be processed matches the fourth subsequent subtask to be processed. Therefore, the function for processing the first subtask to be processed can be used as the function for processing the first subsequent subtask to be processed, and the execution order of the function corresponding to the first subtask to be processed in the execution order data of all necessary functions can be used as the execution order of the function corresponding to the first subsequent subtask to be processed in the execution order data of all necessary functions. By analogy, the execution order of the function of the second subsequent subtask to be processed in the execution order data of all necessary functions, the execution order of the function of the third subsequent subtask to be processed in the execution order data of all necessary functions, and the execution order of the function of the fourth subsequent subtask to be processed in the execution order data of all necessary functions are obtained respectively. According to the execution order of the function corresponding to each subsequent subtask to be processed, the execution order data of all necessary functions required to run the subsequent task to be processed is determined.
[0119] The above is a description process of two ways in which the execution subject determines whether to use the same execution order data of all necessary functions to process the task request by analyzing whether the characteristic data of two task requests match. In addition, in order to improve the efficiency of the large model in determining the execution order data of all necessary functions required to process other subsequent task requests, the execution subject can also establish a correspondence between the processed task request and the execution order data of all necessary functions corresponding to it, and predict the predicted execution order data of all predicted functions corresponding to other subsequent task requests based on the correspondence. Specifically, based on the task request to be processed and the execution order data of all necessary functions corresponding to the task request to be processed, a task function execution order association relationship is established between the task request to be processed and the execution order data of all necessary functions corresponding to the task request to be processed; the task function execution order association relationships corresponding to multiple different types of task requests are obtained; based on the task function execution order association relationship, the predicted execution order data of all predicted functions required for the execution subject to process the subsequent task request to be processed is predicted.
[0120] Steps S601 to S603 have determined the execution order data of all necessary functions required to run to process the task request through the large model. On this basis, the execution subject can establish a task function execution order association relationship between the task request to be processed and the execution order data of all necessary functions corresponding to the task request to be processed. Accordingly, the execution subject establishes corresponding task function execution order association relationships for multiple different types of task requests. Therefore, when determining the execution order data of all necessary functions required to run for subsequent other task requests, the task function execution order association relationship can be used to predict the predicted execution order data of all predicted functions required to run for subsequent other task requests.
[0121] In order to improve the accuracy of the predicted execution order data of all predicted functions obtained by the execution subject, the predicted execution order data of all predicted functions predicted for the subsequent other task requests and the subsequent other task requests can be further verified with the help of the big model. The processing process of the predicted execution order data by the big model includes the following two processing methods: the first processing method: the subsequent task request to be processed and the predicted execution order data of all predicted functions corresponding to the subsequent task request to be processed are sent to the big model, and the fourth verification result of the predicted execution order data of the subsequent task request to be processed and the predicted execution order data of all predicted functions returned by the big model is obtained; if the fourth verification result indicates that the big model has verified the predicted execution order data of the subsequent task request to be processed and the predicted execution order data of all predicted functions, then the predicted execution order data of all predicted functions are used as the execution order data of all necessary functions required to run the subsequent task request to be processed. The execution subject first predicts the predicted execution order data of all predicted functions corresponding to the subsequent task request to be processed according to the stored task function execution order association relationship. Then the big model verifies the predicted execution order data of the subsequent task request to be processed and all the corresponding predicted functions. There is an association between the subsequent task requests to be processed in this process and the task requests that have been processed historically by the large model. Therefore, the execution subject can predict the subsequent task requests to be processed based on the association relationship of the task function execution order. This method reduces the workload of the large model in analyzing the execution order data of all necessary functions corresponding to the subsequent task requests to be processed, and improves the efficiency of the large model in analyzing the execution order data of all necessary functions that need to be run for the execution subject to process the task request.
[0122] The second processing method: If the execution subject predicts the subsequent task request to be processed based on the stored task function execution order association relationship and obtains multiple candidate predicted execution order data of all predicted functions, then further use the large model to select the target execution order data of all necessary functions required to run the subsequent task request to be processed from the multiple candidate predicted execution order data of all predicted functions. Specifically, the predicted execution order data of all predicted functions includes multiple candidate predicted execution order data of all predicted functions; the subsequent task request to be processed and the multiple candidate predicted execution order data of all predicted functions corresponding to the subsequent task request to be processed are sent to the large model, and the target execution order data of all necessary functions required to run for the subsequent task request to be processed returned by the large model is obtained. The execution subject first predicts the subsequent task request to be processed based on the stored task function execution order association relationship and obtains multiple predicted execution order data of all predicted functions. Then, the target execution order data of all necessary functions required to run for the task request to be processed is selected from the multiple predicted execution order data of all predicted functions through the large model. This method also reduces the workload of the large model in analyzing the execution order data of all necessary functions corresponding to the task requests to be processed subsequently, and improves the efficiency of the large model in analyzing the execution order data of all necessary functions required to run by the execution entity to process the task requests.
[0123] Second embodiment
[0124] Corresponding to the embodiment corresponding to the application scenario of the task request processing method provided by the present application and the task request processing method provided by the first embodiment, the second embodiment of the present application also provides a task request processing device. Since the device embodiment is basically similar to the embodiment corresponding to the application scenario and the first embodiment, the description is relatively simple, and the relevant parts can be referred to the embodiment corresponding to the application scenario and the partial description of the first embodiment. The device embodiment described below is only illustrative.
[0125] Please refer to Figure 7, which is a schematic diagram of a task request processing device provided in the second embodiment of the present application. The task request processing device provided in the second embodiment of the present application includes: a task request acquisition unit 701, used to acquire a task request to be processed; a lightweight information list acquisition unit 702, used to acquire a lightweight information list, wherein the lightweight information in the lightweight information list is used to identify the function possessed by the execution subject that processes the task request, and the data volume of the lightweight information is less than the data volume of the fully quantitative description information of the function; an execution order data acquisition unit 703, used to send the task request and the lightweight information list to a large model that can provide function call capability, and obtain the execution order data of all necessary functions returned by the large model for processing the task request. The all necessary functions are functions among all functions identified by the lightweight information list, and the total data volume of the lightweight information list and the execution order data is not higher than the upper limit of the data transmission volume allowed by the large model for providing the function call capability for the execution subject to process the task request.
[0126] Third embodiment
[0127] Corresponding to the method of the first embodiment of the present application, the third embodiment of the present application further provides an electronic device. The electronic device includes: a processor; and a memory for storing a computer program. After the electronic device is powered on and the computer program is run by the processor, the method of the first embodiment is executed. Figure 8 As shown, Figure 8 This is a schematic diagram of an electronic device provided in the third embodiment of the present application. The electronic device specifically includes: at least one processor 801, at least one communication interface 802, at least one memory 803 and at least one communication bus 804; optionally, the communication interface 802 may be an interface of a communication module, such as an interface of a GSM module; the processor 801 may be a processor CPU, or an application specific integrated circuit ASIC (Application Specific Integrated Circuit), or one or more integrated circuits configured to implement the embodiments of the present invention. The memory 803 may include a high-speed RAM memory, and may also include a non-volatile memory (non-volatile memory), such as at least one disk storage. Among them, the memory 803 stores a program, and the processor 801 calls the program stored in the memory 803 to execute the method of the first embodiment of the present invention.
[0128] Fourth embodiment
[0129] Corresponding to the method of the first embodiment of the present application, the fourth embodiment of the present application also provides a computer storage medium. The computer storage medium stores a computer program, which is run by a processor to execute the method of the first embodiment. Although the present application is disclosed as above with a preferred embodiment, it is not intended to limit the present application. Any person skilled in the art can make possible changes and modifications without departing from the spirit and scope of the present application. Therefore, the scope of protection of the present application shall be subject to the scope defined by the claims of the present application. In a typical configuration, a computing device includes one or more processors (CPU), an input / output interface, a network interface, and a memory. The memory may include non-permanent memory in a computer-readable medium, a random access memory (RAM) and / or a non-volatile memory in the form of a read-only memory (ROM) or a flash memory (flash RAM). The memory is an example of a computer-readable medium. 1. Computer-readable media include permanent and non-permanent, removable and non-removable media. Information storage can be implemented by any method or technology. The information can be a computer-readable instruction, a data structure, a module of a program, or other data. Examples of computer storage media include, but are not limited to, phase change memory (PRAM), static random access memory (SRAM), dynamic random access memory (DRAM), other types of random access memory (RAM), read-only memory (ROM), electrically erasable programmable read-only memory (EEPROM), flash memory or other memory technology, compact disk read-only memory (CD-ROM), digital versatile disk (DVD) or other optical storage, magnetic cassettes, magnetic tape magnetic disk storage or other magnetic storage devices or any other non-transmission media that can be used to store information that can be accessed by a computing device. As defined herein, computer-readable media does not include non-transitory media such as modulated data signals and carriers. 2. It should be understood by those skilled in the art that the embodiments of the present application can be provided as methods, systems or computer program products. Therefore, the present application can take the form of a complete hardware embodiment, a complete software embodiment or an embodiment combining software and hardware. Moreover, the present application can take the form of a computer program product implemented on one or more computer-usable storage media (including but not limited to disk storage, CD-ROM, optical storage, etc.) containing computer-usable program code. It should be noted that the embodiments of the present application may involve the use of user data. In actual applications, user-specific personal data can be used in the scheme described in this article within the scope permitted by applicable laws and regulations, subject to the requirements of applicable laws and regulations of the country where the user is located (for example, with the user's explicit consent, effective notification to the user, etc.).It should be noted that the user information (including but not limited to user device information, user personal information, etc.) and data (including but not limited to data used for analysis, stored data, displayed data, etc.) involved in this application are all information and data authorized by the user or fully authorized by all parties, and the collection, use and processing of relevant data must comply with the relevant laws, regulations and standards of relevant countries and regions, and provide corresponding operation entrances for users to choose to authorize or refuse.
Claims
1. A task request processing method, characterized in that: include: Get pending task requests; Obtaining a lightweight information list, wherein the lightweight information in the lightweight information list is used to identify a function of an execution subject that processes the task request, wherein the lightweight information is obtained by processing the full quantitative description information of the function, and the data volume of the lightweight information is less than the data volume of the full quantitative description information of the function; The task request and the lightweight information list are sent to a large model capable of providing function calling capabilities, so that the large model obtains the function information of the execution entity for processing the task request, and obtains the execution sequence data of all necessary functions returned by the large model for processing the task request, wherein all necessary functions are functions among all functions identified by the lightweight information list, and the total data volume of the lightweight information list and the execution sequence data is no higher than the upper limit of the data transmission volume allowed by the large model for providing the function calling capability for the execution entity to process the task request.
2. The method according to claim 1, characterized in that Also includes: The large model is trained using the lightweight information and the fully quantitative description information of the function to obtain a large model that can identify the corresponding relationship between the lightweight information and the fully quantitative description information of the function.
3. The method according to claim 2, characterized in that The obtaining of the lightweight information list includes: Extracting partial description information of the function from the fully quantified description information of the function possessed by the execution subject, wherein the partial description information of the function includes name information of the function and parameter information used to describe functions that can be realized by the function; Using partial description information of the function as lightweight information corresponding to the function, and generating the lightweight information list according to partial description information of multiple functions; The correspondence between the lightweight information and the fully quantized description information of the function includes: the correspondence between the partial description information of the function and the fully quantized description information of the function.
4. The method according to claim 3, characterized in that The step of sending the task request and the lightweight information list to a large model capable of providing function call capability, and obtaining the execution order data of all necessary functions returned by the large model for processing the task request and required to be run, includes: The task request and a list of partial description information of the function are sent to the large model, and the arrangement order of the partial description information of all necessary functions returned by the large model is obtained as the execution order data of all necessary functions.
5. The method according to claim 1, characterized in that Also includes: According to the execution order data of all the necessary functions, all the necessary functions are called in sequence to obtain the processing result of the task request.
6. The method according to claim 5, characterized in that The step of calling all the necessary functions in sequence according to the execution order data of all the necessary functions to obtain the processing result of the task request includes: Obtaining a first necessary function to be executed among all the necessary functions according to the execution order data of all the necessary functions; Obtaining fully quantitative description information of a first necessary function instance corresponding to the first necessary function, and obtaining a first running result obtained by running the first necessary function instance; Sending the fully quantitative description information of the first necessary function instance and the first operation result to the large model, and obtaining a first verification result of the fully quantitative description information of the first necessary function instance and the first operation result returned by the large model; If the first verification result indicates that the full quantitative description information of the first necessary function instance and the first running result of the large model have been verified, then according to the execution order data of all the necessary functions, a second necessary function to be run after the first necessary function of all the necessary functions is obtained; Obtaining a second verification result of the second operation result corresponding to the second necessary function instance and the fully quantitative description information of the second necessary function instance corresponding to the second necessary function returned by the large model; If the second verification result indicates that the full quantitative description information of the second necessary function instance and the second running result of the large model have been verified and passed, and the order of the second necessary function to be executed is at the end of the execution order data of all necessary functions, then the second running result is used as the processing result of the task request.
7. The method according to claim 6, characterized in that The obtaining of fully quantitative description information of a first necessary function instance corresponding to the first necessary function, and obtaining a first running result obtained by running the first necessary function instance, includes: Obtaining fully quantitative description information of the first necessary function, and obtaining parameters required to run the first necessary function; According to the fully quantitative description information of the first necessary function and the parameters required to run the first necessary function, the fully quantitative description information of the first necessary function instance is generated, and the first necessary function instance is run to obtain a first running result corresponding to the first necessary function instance.
8. The method according to claim 6, characterized in that Also includes: Obtaining fully quantitative description information of the second necessary function, and obtaining parameters required to run the second necessary function; Generate the fully quantitative description information of the second necessary function instance according to the fully quantitative description information of the second necessary function and the parameters required to run the second necessary function, and run the second necessary function instance to obtain a second running result corresponding to the second necessary function instance; The obtaining of the second verification result of the fully quantitative description information of the second necessary function instance corresponding to the second necessary function and the second operation result corresponding to the second necessary function instance returned by the large model includes: The fully quantitative description information of the second necessary function instance and the second operation result are sent to the large model, and a second verification result of the fully quantitative description information of the second necessary function instance and the second operation result returned by the large model is obtained.
9. The method according to claim 1, characterized in that: Also includes: Setting the output result stability parameter of the large model to a target parameter value, wherein the target parameter value is used to indicate that the probability that the output result returned by the large model is the target result is greater than a preset probability; Correspondingly, the probability that the execution order data of all necessary functions required to run for processing the task request is the target execution order data is greater than the preset probability.
10. The method according to claim 1, characterized in that Also includes: Storing execution order data of all necessary functions required to run for processing the pending task request; Get the task request to be processed later; If the characteristic data of the subsequent task request to be processed matches the characteristic data of the task request to be processed, the execution sequence data of all necessary data corresponding to the task request to be processed will be used as the execution sequence data of all necessary functions required to run to process the subsequent task request to be processed.
11. The method according to claim 10, characterized in that If the characteristic data of the subsequent task request to be processed is characteristic data matching the characteristic data of the task request to be processed, then the execution sequence data of all necessary data corresponding to the task request to be processed is used as the execution sequence data of all necessary functions required to run for processing the subsequent task request to be processed, including: Obtaining the type of the task request to be processed subsequently and the type of the task request to be processed; If the type of the subsequent task request to be processed is a task request type that matches the type of the task request to be processed, then the characteristic data of the subsequent task request to be processed is determined to be characteristic data that matches the characteristic data of the task request to be processed; and the execution sequence data of all necessary data corresponding to the task request to be processed is used as the execution sequence data of all necessary functions required to run to process the subsequent task request to be processed.
12. The method according to claim 1, characterized in that The obtaining of the lightweight information list includes: Obtaining lightweight information of all functions of the execution subject, and generating a lightweight information list; The execution order data of all necessary functions required to run to process the task request returned by the large model is obtained in the following way: According to the semantic information of the task request, the execution order data of all necessary functions required to be run for processing the task request is obtained from the lightweight information of all functions included in the lightweight information list.
13. The method according to claim 1, characterized in that The obtaining of the lightweight information list includes: Preliminarily predicting multiple candidate functions required to run to process the task request from among all functions of the execution subject according to the semantic information of the task request, obtaining lightweight information corresponding to the multiple candidate functions, and generating the lightweight information list; The execution order data of all necessary functions required to run to process the task request returned by the large model is obtained in the following way: According to the semantic information of the task request, the execution order data of all necessary functions required to be run for processing the task request is obtained from the lightweight information respectively corresponding to the multiple candidate functions included in the lightweight information list.
14. An electronic device, characterized in that: include: processor; as well as The memory is used to store a computer program. After the electronic device is powered on and the computer program is run by the processor, the method according to any one of claims 1 to 13 is executed.
15. A storage medium, characterized in that: The storage medium stores a computer program, and the computer program is executed by a processor to perform the method according to any one of claims 1 to 13.
Citation Information
Patent Citations
Method for generating education text abstract based on idempotent mechanism of large language model
CN118211580A
