Task processing method and device, electronic equipment and computer readable storage medium
By evaluating task difficulty and accuracy on the end device, selecting the target model with the smallest model parameters from multiple candidate models for task processing, solving the challenges of large-scale model deployment and local processing, and improving processing efficiency and accuracy.
Patent Information
- Application Number
- CN202411783909.9
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-12-05
- Publication Date
- 2025-03-28
AI Technical Summary
With the increase in the number of neural network models, deployment and application present great challenges, especially in terms of storage space and transmission bandwidth, while locally deploying models on end devices to meet privacy protection and timeliness needs, more efficient model parameter management is required.
By evaluating the evaluation information of the pending task, selecting the target model with the smallest amount of model parameters from multiple candidate models for task processing, using the difficulty determination model and the accuracy evaluation model to analyze the task difficulty and accuracy, thereby selecting the appropriate model for reasoning.
It improves the accuracy of processing results, while reducing unnecessary inference overhead, and overall improves the overall processing efficiency of pending tasks.
Smart Images

Figure CN119718573A_ABST
Abstract
Description
Technical Field
[0001] The present disclosure relates to the field of computer technology, and in particular to a task processing method, device, electronic device, and computer-readable storage medium. Background Art
[0002] As the accuracy of neural network models increases, the number of parameters in various models also increases dramatically. Some models have a huge number of parameters exceeding 100 billion, which brings huge challenges to deployment and application. At the same time, with the growing demand for privacy protection and timeliness, it has become necessary to deploy models locally on end devices, which puts higher requirements on further reducing the storage space of the model and the transmission bandwidth during model operation. Summary of the invention
[0003] The present disclosure provides a task processing method, device, electronic device and computer-readable storage medium.
[0004] In a first aspect, the present disclosure provides a task processing method, the task processing method comprising:
[0005] In response to receiving the task to be processed, determining evaluation information of the task to be processed;
[0006] According to the evaluation information, a matching target model is determined from multiple candidate models, where different candidate models have different model parameter amounts, and the target model is the model with the smallest model parameter amount among the candidate models that can process the task to be processed;
[0007] Call the target model to process the pending tasks and obtain the processing results of the pending tasks.
[0008] In a possible implementation, the evaluation information includes processing difficulty information, and determining the evaluation information of the task to be processed includes:
[0009] Determine a difficulty determination model from multiple candidate models, where the difficulty determination model is a model with the smallest number of model parameters among the multiple candidate models;
[0010] The task to be processed is analyzed and processed through the difficulty determination model to obtain processing difficulty information.
[0011] In a possible implementation, the task to be processed is analyzed and processed by a difficulty determination model to obtain processing difficulty information, including:
[0012] The task to be processed and the first prompt word are input into the difficulty determination model together, and the corresponding processing difficulty information is output. The first prompt word is used to guide the difficulty determination model to analyze and output the processing difficulty information of the task to be processed.
[0013] In a possible implementation, the task to be processed is analyzed and processed by a difficulty determination model to obtain processing difficulty information, including:
[0014] Input the task to be processed, the first prompt word and the second prompt word into the difficulty determination model together, and output the corresponding processing difficulty information and task analysis information for the task to be processed, wherein the first prompt word is used to guide the difficulty determination model to analyze and output the processing difficulty information of the task to be processed, and the second prompt word is used to guide the difficulty determination model to analyze and output the task analysis information of the task to be processed, and the task analysis information is used as prompt information for the target model to process the task to be processed;
[0015] Among them, calling the target model to process the pending task and obtaining the processing result of the pending task includes:
[0016] The tasks to be processed and task analysis information are input into the target model, and the processing results of the tasks to be processed are output.
[0017] In a possible implementation, the evaluation information includes processing difficulty information, and determining the evaluation information of the task to be processed includes:
[0018] Input the task to be processed into the pre-trained difficulty judgment model, and output the processing difficulty information of the task to be processed;
[0019] Among them, the difficulty judgment model is trained by the following method:
[0020] Determine a benchmark training set, which includes multiple sample tasks and corresponding sample processing results;
[0021] Determine a difficulty training set according to multiple candidate models and a benchmark training set, where the difficulty training set includes multiple sample tasks and corresponding difficulty labels;
[0022] The difficulty judgment model is trained based on the difficulty training set.
[0023] In a possible implementation, determining a difficult training set based on multiple candidate models and a benchmark training set includes:
[0024] Input the sample tasks into each candidate model respectively to obtain the sample prediction results of each candidate model;
[0025] Determine the difficulty label of the sample task based on the sample processing results and the sample prediction results of multiple candidate models;
[0026] The difficulty of the training set is determined based on multiple sample tasks and corresponding difficulty labels.
[0027] In a possible implementation, the difficulty label of the sample task is determined according to the sample processing result and the sample prediction results of multiple candidate models, including:
[0028] When there is at least one sample prediction result matching the sample processing result in the sample prediction results of the sample task, determining a matching candidate model, where the matching candidate model is a candidate model with the smallest model parameter amount among the candidate models corresponding to the matching sample prediction results;
[0029] Determine the difficulty label of the sample task according to the model parameter quantity of the matching candidate model;
[0030] When there is no sample prediction result matching the sample processing result in the sample prediction results of the sample task, the difficulty label is determined to be a difficulty label representing a preset maximum difficulty value.
[0031] In a possible implementation, the evaluation information includes accuracy information of a processing result of the task to be processed, and determining the evaluation information of the task to be processed includes:
[0032] Select an accuracy evaluation model from multiple candidate models according to a preset order, where the preset order is the order from small to large model parameter amount;
[0033] Process the tasks to be processed through the accuracy evaluation model to obtain the corresponding accuracy information and candidate processing results;
[0034] The method further comprises:
[0035] When the accuracy information obtained by the current accuracy evaluation model satisfies the accuracy condition, the candidate processing result determined by the accuracy evaluation model is output as the processing result of the task to be processed;
[0036] When the accuracy information obtained by the current accuracy evaluation model does not meet the accuracy condition, the next candidate model is determined as a new accuracy evaluation model according to a preset order, and the accuracy information is re-determined.
[0037] In a possible implementation, the model parameter quantity of the Nth candidate model in a preset order is greater than the sum of the model parameter quantities of the 1st candidate model to the N-1th candidate model, where N is an integer greater than 1.
[0038] In a possible implementation, the task to be processed includes any one of an image processing task, a speech processing task, a text processing task, and a video processing task.
[0039] In a second aspect, the present disclosure provides a task processing device, the task processing device comprising:
[0040] An information determination module, configured to determine evaluation information of the task to be processed in response to receiving the task to be processed;
[0041] A model matching module is used to determine a matching target model from multiple candidate models according to the evaluation information, wherein different candidate models have different model parameter amounts, and the target model is a model with the smallest model parameter amount among the candidate models that can process the task to be processed;
[0042] The task processing module is used to call the target model to process the pending tasks and obtain the processing results of the pending tasks.
[0043] In a third aspect, the present disclosure provides an electronic device comprising: at least one processor; and a memory communicatively connected to the at least one processor; wherein the memory stores one or more computer programs executable by the at least one processor, and the one or more computer programs are executed by the at least one processor so that the at least one processor can perform the above-mentioned task processing method.
[0044] In a fourth aspect, the present disclosure provides a computer-readable storage medium having a computer program stored thereon, wherein the computer program implements the above-mentioned task processing method when executed by a processor / processing core.
[0045] The embodiments provided by the present disclosure can select a model with matching parameter amounts to process tasks according to the processing difficulty of the tasks to be processed when multiple models with different parameter amounts are deployed on the end device. This method coordinates multiple large models with different parameter amounts and calls models with appropriate parameter scales for inference for tasks of different difficulty, thereby improving the accuracy of processing results while reducing unnecessary inference overhead, thereby improving the overall comprehensive processing effect of the tasks to be processed.
[0046] It should be understood that the content described in this section is not intended to identify the key or important features of the embodiments of the present disclosure, nor is it intended to limit the scope of the present disclosure. Other features of the present disclosure will become easily understood through the following description. BRIEF DESCRIPTION OF THE DRAWINGS
[0047] The accompanying drawings are used to provide a further understanding of the present disclosure and constitute a part of the specification. Together with the embodiments of the present disclosure, they are used to explain the present disclosure and do not constitute a limitation of the present disclosure. The above and other features and advantages will become more apparent to those skilled in the art by describing detailed example embodiments with reference to the accompanying drawings, in which:
[0048] Figure 1 A flowchart of a task processing method provided by an embodiment of the present disclosure;
[0049] Figure 2 A schematic diagram of a task processing process provided by an embodiment of the present disclosure;
[0050] Figure 3A schematic diagram of a task processing process when a task to be processed is a problem provided in an embodiment of the present disclosure;
[0051] Figure 4 A schematic diagram of another task processing process provided by an embodiment of the present disclosure;
[0052] Figure 5 A schematic diagram of another task processing process provided by an embodiment of the present disclosure;
[0053] Figure 6 A schematic diagram of another task processing process provided by an embodiment of the present disclosure;
[0054] Figure 7 A block diagram of a task processing device provided by an embodiment of the present disclosure;
[0055] Figure 8 A block diagram of an electronic device provided in an embodiment of the present disclosure. DETAILED DESCRIPTION
[0056] In order to enable those skilled in the art to better understand the technical solutions of the present disclosure, the exemplary embodiments of the present disclosure are described below in conjunction with the accompanying drawings, including various details of the embodiments of the present disclosure to facilitate understanding, which should be considered as merely exemplary. Therefore, those of ordinary skill in the art should recognize that various changes and modifications can be made to the embodiments described herein without departing from the scope and spirit of the present disclosure. Similarly, for the sake of clarity and conciseness, the description of well-known functions and structures is omitted in the following description.
[0057] In the absence of conflict, the various embodiments of the present disclosure and the various features therein may be combined with each other.
[0058] As used herein, the term "and / or" includes any and all combinations of one or more of the associated listed items.
[0059] The terms used herein are only used to describe specific embodiments and are not intended to limit the present disclosure. As used herein, the singular forms "a" and "the" are also intended to include plural forms, unless the context clearly indicates otherwise. It will also be understood that when the terms "including" and / or "made of" are used in this specification, the existence of features, wholes, steps, operations, elements and / or components is specified, but the existence or addition of one or more other features, wholes, steps, operations, elements, components and / or groups thereof is not excluded. "Connect" or "connected" and similar words are not limited to physical or mechanical connections, but can include electrical connections, whether direct or indirect.
[0060] Unless otherwise defined, all terms (including technical and scientific terms) used herein have the same meaning as commonly understood by those of ordinary skill in the art. It will also be understood that terms such as those defined in commonly used dictionaries should be interpreted as having a meaning consistent with their meaning in the context of the relevant art and the present disclosure, and will not be interpreted as having an idealized or overly formal meaning unless explicitly defined as such herein.
[0061] Large models (LM), especially large language models (LLM) such as GPT-3 (Generative Pre-trained Transformer-3) and GLM (General Language Model), have huge model parameters, which brings great challenges to their deployment and application.
[0062] The output stage of the large model is autoregressive, that is, a token is generated each time, and the generated token is used as input to generate the next token. Since a token is generated each time, and the entire model parameters must be loaded once each time a token is generated, bandwidth is the main bottleneck, not calculation. Reducing the amount of data transmitted for each iteration can speed up the reasoning speed. In the reasoning scenario of the large model, the amount of calculation to generate each token is much smaller than the amount of transmission of weight parameters, so compressing the total storage capacity or bandwidth transmission of the large model can greatly increase the reasoning speed.
[0063] In related technologies, the speed of inference model inference is improved by compressing weights, such as model quantization, model pruning, and low-rank decomposition. Model quantization refers to reducing the amplitude representation accuracy of model weights, compressing the 16-bit floating point number (fp16) representation of the weights into an 8-bit integer (int8) or a 4-bit integer (int4) or a lower bit width representation. Compared with the fp16 model performance, int4 precision quantization does not bring about a significant decline in model performance and is a mainstream method. Model pruning refers to discarding unimportant weights in model parameters to achieve sparsity. Low-rank decomposition refers to using the low-rank characteristics of the weight matrix to discard some of the singular values and singular vectors with less influence, decomposing the large weight matrix into the product of small weight matrices, thereby reducing the parameter storage amount.
[0064] Although the solutions in related technologies have effectively reduced the total storage of the model, there are still huge challenges in deploying it on the end device. During inference, the bandwidth to computation ratio of LLM is large, so weight transmission is still one of the main bottlenecks limiting the overall inference speed of the model.
[0065] In addition, large models of the same or different series often have different parameter scales. For example, the qwen2 series has models with different parameter amounts, such as 0.5B, 1.5B, 7B, and 72B. Models of the same series often have similar network structures, similar training data sets, and similar training settings, and thus have similar behaviors, that is, the model outputs are similar, but in terms of reasoning accuracy, the output of models with larger parameters is generally more accurate. The solutions in related technologies usually reduce the number of parameters or the amount of transmission of the model from the perspective of a single model, but fail to reduce the comprehensive reasoning cost from the perspective of multi-model collaboration.
[0066] According to the task processing method of the embodiment of the present disclosure, it is possible to start from the perspective of multiple models, select a model with a suitable parameter scale from multiple large models with different parameter amounts by evaluating the difficulty information of the task to be processed or the accuracy information of the processing, and call the model to perform task processing, thereby improving the accuracy of the processing results while reducing unnecessary reasoning overhead, thereby improving the overall processing efficiency of the tasks to be processed.
[0067] The task processing method according to the embodiment of the present disclosure can be executed by an electronic device such as a terminal device or a server, and the terminal device can be a vehicle-mounted device, a user equipment (User Equipment, UE), a mobile device, a user terminal, a terminal, a cellular phone, a cordless phone, a personal digital assistant (Personal Digital Assistant, PDA), a handheld device, a computing device, a vehicle-mounted device, a wearable device, etc. The method can be implemented by a processor calling a computer-readable program instruction stored in a memory. Alternatively, the method can be executed by a server.
[0068] Figure 1 A flowchart of a task processing method provided by an embodiment of the present disclosure. Figure 1 , the method comprising:
[0069] Step S10: In response to receiving the task to be processed, determining evaluation information of the task to be processed.
[0070] In a possible implementation, after receiving the task to be processed, the evaluation information of the task to be processed can be determined. The task to be processed can be any task that needs to be processed according to different application scenarios, for example, it can include any one of an image processing task, a speech processing task, a text processing task, and a video processing task. The evaluation information is used to evaluate the difficulty of the task to be processed or the reliability of the processing result, for example, it can include the processing difficulty information of the task to be processed and / or the accuracy information of the processing result of the task to be processed. Furthermore, the evaluation information can also include other information used to match the model for processing the task to be processed, such as task level information or model identification information.
[0071] Optionally, the processing difficulty information in the evaluation information is associated with the model parameter amount, and the difficulty of the task to be processed can be represented by a numerical value within a preset range. For example, the processing difficulty information can be a numerical value between 0-10, and the difficulty of the corresponding task represented from 0-10 gradually increases, and the corresponding model parameter amount also gradually increases. Alternatively, the difficulty level corresponding to the task to be processed can also be represented by a preset difficulty label, and the difficulty label and the model parameter amount can be pre-set to match the difficulty label with a lower difficulty level, and the model parameter amount matched is smaller. For example, the processing difficulty information can be any one of the difficulty labels of "difficult", "general" and "simple", and each label matches at least one model parameter amount. In the embodiment of the present disclosure, the correlation relationship between the processing difficulty information and the model parameter amount can be preset. Similarly, the accuracy information of the processing result of the task to be processed can also be represented by a numerical value or a preset accuracy label.
[0072] In one possible implementation, the processing difficulty information of the disclosed embodiment can be determined by performing a difficulty analysis on the task to be processed through a neural network model. The neural network model can be a candidate model for executing the task to be processed, that is, one of multiple candidate models pre-deployed in the electronic device for executing the task to be processed can be selected to determine the processing difficulty information corresponding to the task to be processed. The method of determining the processing difficulty information can directly perform a difficulty analysis through the candidate model for executing the task, without the need to deploy a new difficulty assessment model, thus saving the memory space required for the deployment model.
[0073] Furthermore, since the difficulty analysis process is a relatively simple analysis process and can be completed using a very small amount of parameters, the disclosed embodiment can use the candidate model with the smallest amount of model parameters among multiple candidate models as the difficulty determination model, and then analyze and process the task to be processed through the difficulty determination model to obtain processing difficulty information. That is, a difficulty determination model is determined from multiple candidate models to analyze the task difficulty of the task to be processed, wherein the difficulty determination model is the model with the smallest amount of model parameters among multiple candidate models. Therefore, the selection method of the difficulty determination model can also save the reasoning overhead required for the task difficulty analysis process, while improving the efficiency of the difficulty analysis process.
[0074] Optionally, when the type of the candidate model is a large language model, the process of selecting the candidate model as the difficulty determination model for difficulty analysis may include: inputting the task to be processed and the first prompt word into the difficulty determination model together, and outputting the corresponding processing difficulty information. Among them, the first prompt word is used to guide the difficulty determination model to analyze and output the processing difficulty information of the task to be processed. For example, when the task to be processed is to solve the text-based problem "Can the partial derivative of the multivariate function be continuous?", the above-mentioned text-based problem and the preset first prompt word "output processing difficulty information, which is a numerical value between 0-10" can be input into the difficulty determination model together, and the difficulty determination model analyzes and processes the difficulty of the task to be processed to obtain the corresponding processing difficulty information. The first prompt word and the task to be processed can be directly input into the difficulty determination model. Alternatively, the input form of the first prompt word and the task to be processed is determined according to a preset template, that is, when the task to be processed is a text-based problem, the first prompt word and the task to be processed can be generated into an input text based on the preset template, and then input into the difficulty determination model. The input text may be, for example, "Please perform a difficulty analysis on the question "Can a multivariate function be differentiable and its partial derivatives be continuous?" and output the processing difficulty information as a numerical value between 0 and 10."
[0075] Further, in the case where the type of the candidate model is a large language model, the difficulty analysis process can simultaneously determine the processing difficulty information and the task analysis information used to assist in task processing. That is, the process of selecting the candidate model as the difficulty determination model for difficulty analysis can also include: inputting the task to be processed and the first prompt word and the second prompt word into the difficulty determination model together, outputting the corresponding processing difficulty information and the task analysis information for the task to be processed, the first prompt word is used to guide the difficulty determination model to analyze and output the processing difficulty information of the task to be processed, the second prompt word is used to guide the difficulty determination model to analyze and output the task analysis information of the task to be processed, and the task analysis information is used as the prompt information for the target model to process the task to be processed. For example, when the task to be processed is to solve the text-based problem "Can the partial derivative of the multivariate function be derived to be continuous?", the first prompt word can be "difficulty analysis" and the second prompt word can be "simple reasoning task to be processed". The task analysis information determined based on this method can be further used in the processing process of the task to be processed, and the accuracy of the processing result of the task to be processed can be improved. And the task analysis information and the processing difficulty information are inferred together, without introducing additional computational overhead.
[0076] Optionally, the above-mentioned text-based question and the preset first prompt word and second prompt word can be input into the difficulty determination model together, and the difficulty determination model analyzes the difficulty of the task to be processed and performs simple reasoning on the problem to be processed at the same time, to obtain corresponding processing difficulty information and task analysis information. The first prompt word, the second prompt word and the task to be processed can be directly input into the difficulty determination model. Alternatively, the input form of the first prompt word, the second prompt word and the task to be processed is determined according to a preset template, that is, when the task to be processed is a text-based question, the first prompt word, the second prompt word and the task to be processed can be generated into an input text based on the preset template, and then input into the difficulty determination model. The input text can be, for example, "Please perform a difficulty analysis on the question "Can the partial derivatives of multivariate functions be derived to be continuous if they are differentiable?" and perform simple reasoning on the task to be processed, and output the processing difficulty information and task analysis information."
[0077] In one possible implementation, the neural network model used in the disclosed embodiment to determine the processing difficulty information may also be a model used only for difficulty analysis, that is, a difficulty judgment model used for difficulty analysis and multiple candidate models used to execute the task to be processed are simultaneously deployed in the electronic device, the difficulty judgment model is used only for difficulty analysis of the task to be processed, and the candidate model is used only for task processing. In other words, the method for determining the processing difficulty information may be to input the task to be processed into a pre-trained difficulty judgment model, and output the processing difficulty information of the task to be processed. Among them, the type of the difficulty judgment model may be any model capable of difficulty analysis, and the number of parameters of the model is less than the number of parameters of any candidate model, further reducing the inference overhead of the entire task processing process.
[0078] Optionally, the training process of the difficulty judgment model can be carried out in an electronic device. The training process of the difficulty judgment model can be trained together with a preset benchmark training set and multiple candidate models. Specifically, a benchmark training set including multiple sample tasks and corresponding sample processing results can be determined first, and a difficulty training set can be determined based on multiple candidate models and the benchmark training set, and the difficulty training set includes multiple sample tasks and corresponding difficulty labels. Then the difficulty judgment model is trained based on the difficulty training set. Among them, the difficulty training set can be determined by the result of processing each sample task by the candidate model respectively, that is, the sample task can be input into each candidate model respectively to obtain the sample prediction result of each candidate model. Then, based on the sample processing result and the sample prediction results of multiple candidate models, the difficulty label corresponding to each sample task is determined. Finally, the difficulty training set is determined based on multiple sample tasks and corresponding difficulty labels.
[0079] Since the embodiment of the present application jointly determines the corresponding difficulty label through the candidate model and the sample tasks in the benchmark training set, a strong correlation between the difficulty label and the model parameter quantity of the candidate model is achieved, thereby improving the accuracy of the difficulty label of each sample task in the obtained difficulty training set, and further improving the training effect of the difficulty judgment model.
[0080] Further, the difficulty label corresponding to each sample task is used to characterize the minimum model parameter amount required by the candidate model that can solve the sample task. Therefore, when there is at least one sample prediction result matching the sample processing result in the sample prediction result of the sample task, the matching candidate model can be determined, and the matching candidate model is the candidate model with the smallest model parameter amount among the candidate models corresponding to the matching sample prediction result. According to the model parameter amount of the matching candidate model, the difficulty label of the sample task is determined. The difficulty label can be directly determined as the model parameter amount of the matching candidate model, or the result after the model parameter amount of the matching candidate model is normalized as the difficulty label, or the model parameter amount of the matching candidate model can be mapped to the corresponding difficulty label according to other preset mapping rules. At the same time, when there is no sample prediction result matching the sample processing result in the sample prediction result of the sample task, the difficulty label can be directly determined as the difficulty label characterizing the preset maximum difficulty value. The determination method of the difficulty label can determine the difficulty label based on the minimum model parameter amount required for processing the task, and directly determine the difficulty of the task that cannot be processed as the maximum difficulty, further improving the accuracy of the difficulty label.
[0081] Step S20: Determine a matching target model from multiple candidate models based on the evaluation information.
[0082] In a possible implementation, an electronic device that executes the task processing method of the embodiment of the present disclosure may pre-deploy multiple candidate models, each candidate model may be used to independently process the task to be processed, different candidate models have different model parameter amounts, and the target model is a model with the smallest model parameter amount among the candidate models that can process the task to be processed. For different tasks to be processed, the candidate model in the embodiment of the present disclosure may be any pre-deployed neural network model that can perform the task to be processed. For example, in the case where the task to be processed is an image processing task, the multiple candidate models pre-deployed in the electronic device may be AlexNet networks, VGG networks, or AlexNet networks with different parameter amounts, etc. In the case where the task to be processed is a text processing task, the multiple candidate models pre-deployed in the electronic device may be NNLM models, Word2Vec models, or TextCNN models with different parameter amounts, etc. Alternatively, the candidate model may also be a large language model (LLM), that is, different candidate models may be models such as GPT-3 (Generative Pre-trained Transformer-3) or GLM (General Language Model) with different parameter amounts, which are used to input the task to be processed into the model in the form of a question for task processing.
[0083] Optionally, in the case where the evaluation information determined by the electronic device includes processing difficulty information, the electronic device can determine a matching target model from a plurality of pre-deployed candidate models according to the processing difficulty information, and the target model is a model with the smallest model parameter amount among the candidate models that can process the task to be processed. In other words, the target model is a candidate model with the smallest model parameter amount among all candidate models that can complete the processing of the task to be processed. Among them, the matching method of the target model can be to match the corresponding model parameter amount according to the correlation relationship between the processing difficulty information and the model parameter amount, and then determine the candidate model with the corresponding model parameter amount as the target model. Exemplarily, the electronic device can pre-set the processing difficulty information to one of the ten difficulty levels of difficulty 0, difficulty 1, difficulty 2, difficulty 3, difficulty 4, difficulty 5, difficulty 6, difficulty 7, difficulty 8 and difficulty 9, and pre-deploy five candidate models with model parameter amounts of 1B, 7B, 13B, 25B and 50B respectively. At the same time, the preset correlation relationship between the processing difficulty information and the model parameter amount is set as difficulty 0 and difficulty 1 corresponding to model parameter amount 1B, difficulty 2 and difficulty 3 corresponding to model parameter amount 7B, difficulty 4 and difficulty 5 corresponding to model parameter amount 13B, difficulty 6 and difficulty 7 corresponding to model parameter amount 24B, difficulty 8 and difficulty 9 corresponding to model parameter amount 50B. When the processing difficulty information included in the evaluation information is difficulty 4, the candidate model with a model parameter amount of 13B is determined as the target model.
[0084] Furthermore, the embodiment of the present disclosure may also pre-set a correlation between processing difficulty information and multiple model parameter quantities to select multiple candidate models from multiple candidate models as target models, and execute the tasks to be processed in a preset order through the multiple target models.
[0085] Step S30: call the target model to process the task to be processed and obtain the processing result of the task to be processed.
[0086] In a possible implementation, when the evaluation information includes processing difficulty information, after the electronic device determines the target model, it calls the target model to process the task to be processed and obtains the processing result of the task to be processed. Wherein, when the processing difficulty information is determined but the task analysis information is not determined, the task processing process can be directly inputting the task to be processed into the target model for task processing and obtaining the processing result of the task to be processed. When the processing difficulty information is determined and the task analysis information is also determined, the task processing process can also be inputting the task to be processed and the task analysis information into the target model and outputting the processing result of the task to be processed.
[0087] Optionally, when there are multiple target models, the target accuracy models can be determined in order from small to large model parameter quantities, and the task is processed by the current target accuracy model to obtain corresponding accuracy information and candidate processing results. When the current accuracy information meets the accuracy condition, the candidate processing result determined by the target accuracy model is output as the processing result of the task to be processed. When the accuracy information obtained by the current target accuracy model does not meet the accuracy condition, the next target model is determined as the new target accuracy model according to the preset order, and the accuracy information and candidate processing results are re-determined.
[0088] Figure 2 A schematic diagram of a task processing process provided by an embodiment of the present disclosure. Figure 2 As shown, after receiving the task to be processed, the electronic device can determine the processing difficulty information through the difficulty determination model selected from the candidate models. Among them, the task to be processed and the first prompt word can be input into the difficulty determination model together, and the difficulty determination model performs difficulty analysis on the task to be processed and outputs the processing difficulty information of the task to be processed. Furthermore, according to the processing difficulty information, a target model is determined from multiple candidate models, and then the task to be processed is input into the target model for processing and the corresponding processing result is output. Optionally, since the difficulty determination model and the target model are both determined from the candidate models, the target model may be the same model as the difficulty determination model.
[0089] Figure 3 A schematic diagram of a task processing process when the task to be processed is to answer a question provided in an embodiment of the present disclosure. Figure 3As shown, multiple candidate models include model 0, model 1 (model parameter 1B, 1 billion), model 2 (model parameter 7B, 7 billion), model 3 (model parameter 13B, 13 billion) ... model n (model parameter 170B, 170 billion), where n is a positive integer. When the task to be processed is a question that needs to be answered by a model, the task to be processed can be a text-based question "Can the partial derivative of a multivariate function be continuous if it is differentiable?" One of the multiple candidate models can be selected as the difficulty determination model, and then the question text "Can the partial derivative of a multivariate function be continuous if it is differentiable?" is input into the difficulty determination model ( Figure 3 Model 0) in , and output the corresponding processing difficulty information, Figure 3 The difficulty score is 75. When the preset association relationship between the processing difficulty information and the model parameter amount includes "the model parameter amount corresponding to the difficulty score 75 is 13B", the corresponding candidate model ( Figure 3 Model 3) in the example is used as the target model to solve the problem "Can the partial derivative of a multivariate function be continuous if it is differentiable?" and obtain the processing result, namely Figure 3 The answer to the question "A multivariate function that is differentiable does not necessarily mean that its partial derivatives are continuous" is: In order to reduce the overall inference process overhead, the difficulty determination model usually selects the candidate model with the smallest number of model parameters. Therefore, when the number of model parameters corresponding to the processing difficulty information is also the smallest, the task to be processed is directly processed through the difficulty determination model, and the corresponding processing result is output.
[0090] Figure 4 FIG. 1 is a schematic diagram of another task processing process provided by an embodiment of the present disclosure. Figure 4 As shown, after receiving the task to be processed, the electronic device can determine the processing difficulty information through the difficulty determination model selected from the candidate models. Among them, the task to be processed and the first prompt word and the second prompt word can be input into the difficulty determination model together, and the difficulty determination model performs difficulty analysis and task analysis on the task to be processed, and outputs the processing difficulty information and task analysis information of the task to be processed. Furthermore, a target model is determined from multiple candidate models according to the processing difficulty information, and then the task to be processed and the task analysis information are input into the target model together for processing, and the corresponding processing result is output. Optionally, since the difficulty determination model and the target model are both determined from the candidate models, the target model can be the same model as the difficulty determination model.
[0091] Figure 5 FIG. 1 is a schematic diagram of another task processing process provided by an embodiment of the present disclosure. Figure 5As shown, after receiving the task to be processed, the electronic device can determine the processing difficulty information through the difficulty judgment model obtained through training. The difficulty judgment model can be obtained through training of a difficulty training set, which includes multiple sample tasks and corresponding difficulty labels. The difficulty training set can be determined by a benchmark training set and multiple candidate models. After the task to be processed is input into the difficulty judgment model, the difficulty judgment model performs a difficulty analysis on the task to be processed and outputs the processing difficulty information of the task to be processed. Furthermore, the target model is determined from multiple candidate models based on the processing difficulty information, and then the task to be processed is input into the target model for processing and the corresponding processing result is output.
[0092] In a possible implementation, when the evaluation information includes the accuracy information of the processing result of the task to be processed, the evaluation information of the task to be processed can be determined by the candidate model used to process the task to be processed. Specifically, the electronic device can select an accuracy evaluation model from multiple candidate models according to a preset order, and the preset order can be the order of the model parameter quantity from small to large. Then the task to be processed is processed by the accuracy evaluation model to obtain the corresponding accuracy information and candidate processing results. Among them, the candidate processing result is the result obtained by processing the task to be processed according to the currently selected accuracy evaluation model, and the accuracy information is obtained together with the candidate processing result to characterize whether the candidate processing result is reliable.
[0093] Furthermore, when the accuracy information obtained by the current accuracy assessment model satisfies the accuracy condition, the candidate processing result determined by the accuracy assessment model is output as the processing result of the task to be processed. When the accuracy information obtained by the current accuracy assessment model does not meet the accuracy condition, the next candidate model is determined as a new accuracy assessment model according to a preset order, and the accuracy information is re-determined. The accuracy information may be a value within a preset range, and the accuracy condition may be that the accuracy information is greater than a preset accuracy threshold.
[0094] Optionally, the model parameter amount of the Nth candidate model in the preset order is greater than the sum of the model parameter amounts of the 1st to N-1th candidate models, and N is an integer greater than 1. Based on the above technical features, the cost of reasoning with multiple candidate models with smaller model parameter amounts can be made less than the cost of directly reasoning with a candidate model with a larger model parameter amount, thereby improving the accuracy of the reasoning result while saving the overall reasoning cost.
[0095] Figure 6 FIG. 1 is a schematic diagram of another task processing process provided by an embodiment of the present disclosure. Figure 6As shown, after receiving the task to be processed, the electronic device may not perform difficulty analysis, and may determine the final output processing result together with the candidate processing results and accuracy information determined by multiple candidate models in the process of processing the task to be processed. That is, the electronic device may select candidate model N as the accuracy evaluation model from multiple candidate models according to the preset order of model parameter quantity from small to large, process the task to be processed through the accuracy evaluation model, and obtain the corresponding accuracy information and candidate processing results. Furthermore, in the case that the accuracy information obtained by the current accuracy evaluation model meets the accuracy condition, the candidate processing result determined by the accuracy evaluation model is output as the processing result of the task to be processed. In the case that the accuracy information obtained by the current accuracy evaluation model does not meet the accuracy condition, the next candidate model N+1 is determined as the new accuracy evaluation model according to the preset order, and the accuracy information and candidate processing results are re-determined.
[0096] Based on the above technical features, the disclosed embodiment can reduce the unnecessary reasoning overhead generated by the model when performing task reasoning through at least one scheduling strategy when multiple models with different parameter amounts are deployed on the end device, while improving the accuracy of the reasoning results. Among them, one scheduling strategy can select a model with matching parameter amounts for task processing according to the processing difficulty of the task to be processed. This method coordinates multiple large models with different parameter amounts to call models with appropriate parameter scales for reasoning for tasks of different difficulties, thereby improving the accuracy of the processing results while reducing unnecessary reasoning overhead, thereby improving the overall comprehensive processing efficiency of the tasks to be processed. Another scheduling strategy sorts the model parameters in order from small to large, and processes the tasks in sequence according to the sorting results to obtain reliable processing results. Compared with directly using a model with a larger model parameter amount for reasoning, this scheduling strategy effectively reduces the reasoning overhead, thereby improving the accuracy of the reasoning results while further saving the overall reasoning overhead.
[0097] It can be understood that the above-mentioned various method embodiments mentioned in the present disclosure can be combined with each other to form a combined embodiment without violating the principle logic. Due to space limitations, the present disclosure will not repeat them. It can be understood by those skilled in the art that in the above-mentioned method of the specific implementation method, the specific execution order of each step should be determined according to its function and possible internal logic.
[0098] In addition, the present disclosure also provides a task processing device, an electronic device, and a computer-readable storage medium, all of which can be used to implement any task processing method provided by the present disclosure. The corresponding technical solutions and descriptions are referred to the corresponding records in the method part and will not be repeated here.
[0099] Figure 7 A block diagram of a task processing device provided in an embodiment of the present disclosure.
[0100] Reference Figure 7 , an embodiment of the present disclosure provides a task processing device, the task processing device comprising:
[0101] An information determination module 70, configured to determine evaluation information of the task to be processed in response to receiving the task to be processed;
[0102] A model matching module 71 is used to determine a matching target model from multiple candidate models according to the evaluation information, where different candidate models have different model parameter amounts, and the target model is a model with the smallest model parameter amount among the candidate models that can process the task to be processed;
[0103] The task processing module 72 is used to call the target model to process the task to be processed and obtain the processing result of the task to be processed.
[0104] In a possible implementation, the evaluation information includes processing difficulty information, and the information determination module 70 is further configured to:
[0105] Determine a difficulty determination model from multiple candidate models, where the difficulty determination model is a model with the smallest number of model parameters among the multiple candidate models;
[0106] The task to be processed is analyzed and processed through the difficulty determination model to obtain processing difficulty information.
[0107] In a possible implementation, the information determination module 70 is further configured to:
[0108] The task to be processed and the first prompt word are input into the difficulty determination model together, and the corresponding processing difficulty information is output. The first prompt word is used to guide the difficulty determination model to analyze and output the processing difficulty information of the task to be processed.
[0109] In a possible implementation, the information determination module 70 is further configured to:
[0110] Input the task to be processed, the first prompt word and the second prompt word into the difficulty determination model together, and output the corresponding processing difficulty information and task analysis information for the task to be processed, wherein the first prompt word is used to guide the difficulty determination model to analyze and output the processing difficulty information of the task to be processed, and the second prompt word is used to guide the difficulty determination model to analyze and output the task analysis information of the task to be processed, and the task analysis information is used as prompt information for the target model to process the task to be processed;
[0111] The task processing module 72 is further used to:
[0112] The tasks to be processed and task analysis information are input into the target model, and the processing results of the tasks to be processed are output.
[0113] In a possible implementation, the evaluation information includes processing difficulty information, and the information determination module 70 is further configured to:
[0114] Input the task to be processed into the pre-trained difficulty judgment model, and output the processing difficulty information of the task to be processed;
[0115] Among them, the difficulty judgment model is trained by the following method:
[0116] Determine a benchmark training set, which includes multiple sample tasks and corresponding sample processing results;
[0117] Determine a difficulty training set according to multiple candidate models and a benchmark training set, where the difficulty training set includes multiple sample tasks and corresponding difficulty labels;
[0118] The difficulty judgment model is trained based on the difficulty training set.
[0119] In a possible implementation, the second training set determination module is further configured to:
[0120] Input the sample tasks into each candidate model respectively to obtain the sample prediction results of each candidate model;
[0121] Determine the difficulty label of the sample task based on the sample processing results and the sample prediction results of multiple candidate models;
[0122] The difficulty of the training set is determined based on multiple sample tasks and corresponding difficulty labels.
[0123] In a possible implementation, the second training set determination module is further configured to:
[0124] When there is at least one sample prediction result matching the sample processing result in the sample prediction results of the sample task, determining a matching candidate model, where the matching candidate model is a candidate model with the smallest model parameter amount among the candidate models corresponding to the matching sample prediction results;
[0125] Determine the difficulty label of the sample task according to the model parameter quantity of the matching candidate model;
[0126] When there is no sample prediction result matching the sample processing result in the sample prediction results of the sample task, the difficulty label is determined to be a difficulty label representing a preset maximum difficulty value.
[0127] In a possible implementation, the evaluation information includes accuracy information of the processing result of the task to be processed, and the information determination module 70 is further used to:
[0128] Select an accuracy evaluation model from multiple candidate models according to a preset order, where the preset order is the order of model parameter quantity from small to large; process the task to be processed through the accuracy evaluation model to obtain corresponding accuracy information and candidate processing results;
[0129] The device further comprises:
[0130] A processing result output module, used to output the candidate processing result determined by the accuracy evaluation model as the processing result of the task to be processed when the accuracy information obtained by the current accuracy evaluation model meets the accuracy condition;
[0131] The model updating module is used to determine the next candidate model as a new accuracy evaluation model according to a preset order and redetermine the accuracy information when the accuracy information obtained by the current accuracy evaluation model does not meet the accuracy condition.
[0132] In a possible implementation, the model parameter quantity of the Nth candidate model in a preset order is greater than the sum of the model parameter quantities of the 1st candidate model to the N-1th candidate model, where N is an integer greater than 1.
[0133] In a possible implementation, the task to be processed includes any one of an image processing task, a speech processing task, a text processing task, and a video processing task.
[0134] Figure 8 A block diagram of an electronic device provided by an embodiment of the present disclosure. Figure 8 An embodiment of the present disclosure provides an electronic device, which includes: at least one processor 501; at least one memory 502, and one or more I / O interfaces 503, connected between the processor 501 and the memory 502; wherein the memory 502 stores one or more computer programs that can be executed by the at least one processor 501, and the one or more computer programs are executed by the at least one processor 501 so that the at least one processor 501 can perform the above-mentioned task processing method.
[0135] The present disclosure also provides a computer-readable storage medium on which a computer program is stored, wherein the computer program implements the above-mentioned task processing method when executed by a processor / processing core. The computer-readable storage medium may be a volatile or non-volatile computer-readable storage medium.
[0136] The embodiments of the present disclosure also provide a computer program product, including a computer-readable code, or a non-volatile computer-readable storage medium carrying the computer-readable code. When the computer-readable code runs in a processor of an electronic device, the processor in the electronic device executes the above-mentioned task processing method.
[0137] It will be appreciated by those skilled in the art that all or some of the steps, systems, and functional modules / units in the methods disclosed above may be implemented as software, firmware, hardware, and appropriate combinations thereof. In a hardware implementation, the division between the functional modules / units mentioned in the above description does not necessarily correspond to the division of physical components; for example, a physical component may have multiple functions, or a function or step may be performed by several physical components in cooperation. Some or all physical components may be implemented as software executed by a processor, such as a central processing unit, a digital signal processor, or a microprocessor, or may be implemented as hardware, or may be implemented as an integrated circuit, such as an application-specific integrated circuit. Such software may be distributed on a computer-readable storage medium, which may include a computer storage medium (or a non-transitory medium) and a communication medium (or a temporary medium).
[0138] As is known to those of ordinary skill in the art, the term computer storage media includes volatile and nonvolatile, removable and non-removable media implemented in any method or technology for storing information (such as computer-readable program instructions, data structures, program modules or other data). Computer storage media include, but are not limited to, random access memory (RAM), read-only memory (ROM), erasable programmable read-only memory (EPROM), static random access memory (SRAM), flash memory or other memory technology, portable compact disk read-only memory (CD-ROM), digital versatile disk (DVD) or other optical disk storage, magnetic cassettes, magnetic tapes, magnetic disk storage or other magnetic storage devices, or any other medium that can be used to store desired information and can be accessed by a computer. In addition, it is known to those of ordinary skill in the art that communication media typically contain computer-readable program instructions, data structures, program modules or other data in a modulated data signal such as a carrier wave or other transmission mechanism, and may include any information delivery medium.
[0139] The computer-readable program instructions described herein can be downloaded from a computer-readable storage medium to each computing / processing device, or downloaded to an external computer or external storage device via a network, such as the Internet, a local area network, a wide area network, and / or a wireless network. The network can include copper transmission cables, optical fiber transmissions, wireless transmissions, routers, firewalls, switches, gateway computers, and / or edge servers. The network adapter card or network interface in each computing / processing device receives the computer-readable program instructions from the network and forwards the computer-readable program instructions for storage in the computer-readable storage medium in each computing / processing device.
[0140] The computer program instructions for performing the operation of the present disclosure may be assembly instructions, instruction set architecture (ISA) instructions, machine instructions, machine-related instructions, microcode, firmware instructions, state setting data, or source code or object code written in any combination of one or more programming languages, including object-oriented programming languages, such as Smalltalk, C++, etc., and conventional procedural programming languages, such as "C" language or similar programming languages. Computer-readable program instructions may be executed entirely on a user's computer, partially on a user's computer, as an independent software package, partially on a user's computer, partially on a remote computer, or completely on a remote computer or server. In the case of a remote computer, the remote computer may be connected to the user's computer via any type of network, including a local area network (LAN) or a wide area network (WAN), or may be connected to an external computer (e.g., using an Internet service provider to connect via the Internet). In some embodiments, an electronic circuit, such as a programmable logic circuit, a field programmable gate array (FPGA), or a programmable logic array (PLA), may be customized by utilizing the state information of the computer-readable program instructions, and the electronic circuit may execute the computer-readable program instructions, thereby realizing various aspects of the present disclosure.
[0141] The computer program product described herein may be implemented in hardware, software, or a combination thereof. In one optional embodiment, the computer program product is embodied as a computer storage medium, and in another optional embodiment, the computer program product is embodied as a software product, such as a software development kit (SDK), etc.
[0142] Various aspects of the present disclosure are described herein with reference to the flowcharts and / or block diagrams of the methods, devices (systems) and computer program products according to the embodiments of the present disclosure. It should be understood that each box in the flowchart and / or block diagram and the combination of each box in the flowchart and / or block diagram can be implemented by computer-readable program instructions.
[0143] These computer-readable program instructions can be provided to a processor of a general-purpose computer, a special-purpose computer, or other programmable data processing device, thereby producing a machine, so that when these instructions are executed by the processor of the computer or other programmable data processing device, a device that implements the functions / actions specified in one or more boxes in the flowchart and / or block diagram is generated. These computer-readable program instructions can also be stored in a computer-readable storage medium, and these instructions cause the computer, programmable data processing device, and / or other equipment to work in a specific manner, so that the computer-readable medium storing the instructions includes a manufactured product, which includes instructions for implementing various aspects of the functions / actions specified in one or more boxes in the flowchart and / or block diagram.
[0144] Computer-readable program instructions may also be loaded onto a computer, other programmable data processing apparatus, or other device so that a series of operating steps are performed on the computer, other programmable data processing apparatus, or other device to produce a computer-implemented process, thereby causing the instructions executed on the computer, other programmable data processing apparatus, or other device to implement the functions / actions specified in one or more boxes in the flowchart and / or block diagram.
[0145] The flow chart and block diagram in the accompanying drawings show the possible architecture, function and operation of the system, method and computer program product according to multiple embodiments of the present disclosure. In this regard, each square box in the flow chart or block diagram can represent a part of a module, program segment or instruction, and a part of a module, program segment or instruction includes one or more executable instructions for realizing the specified logical function. In some alternative implementations, the function marked in the square box can also occur in a sequence different from that marked in the accompanying drawings. For example, two continuous square boxes can actually be executed substantially in parallel, and they can sometimes be executed in the opposite order, depending on the functions involved. It should also be noted that each square box in the block diagram and / or flow chart, and the combination of the square boxes in the block diagram and / or flow chart can be implemented with a dedicated hardware-based system that performs the specified function or action, or can be implemented with a combination of special hardware and computer instructions.
[0146] Example embodiments have been disclosed herein, and although specific terms are employed, they are used and should be interpreted only in a general illustrative sense and not for limiting purposes. In some instances, it will be apparent to those skilled in the art that, unless otherwise expressly noted, features, characteristics, and / or elements described in conjunction with a particular embodiment may be used alone or in combination with features, characteristics, and / or elements described in conjunction with other embodiments. Therefore, those skilled in the art will appreciate that various changes in form and detail may be made without departing from the scope of the present disclosure as set forth in the appended claims.
Claims
1. A task processing method, characterized in that: include: In response to receiving a task to be processed, determining evaluation information of the task to be processed; Determine a matching target model from a plurality of candidate models according to the evaluation information, wherein different candidate models have different model parameter amounts, and the target model is a model with the smallest model parameter amount among the candidate models that can process the task to be processed; The target model is called to process the task to be processed, and a processing result of the task to be processed is obtained.
2. The method according to claim 1, characterized in that The evaluation information includes processing difficulty information, and the evaluation information of the task to be processed is determined, including: Determine a difficulty determination model from the plurality of candidate models, the difficulty determination model being a model with the smallest model parameter amount among the plurality of candidate models; The task to be processed is analyzed and processed by the difficulty determination model to obtain processing difficulty information.
3. The method according to claim 2, characterized in that The step of analyzing and processing the task to be processed by using the difficulty determination model to obtain processing difficulty information includes: The task to be processed and the first prompt word are input into the difficulty determination model together, and the corresponding processing difficulty information is output. The first prompt word is used to guide the difficulty determination model to analyze and output the processing difficulty information of the task to be processed.
4. The method according to claim 2, characterized in that: The step of analyzing and processing the task to be processed by using the difficulty determination model to obtain processing difficulty information includes: Input the task to be processed, the first prompt word and the second prompt word into the difficulty determination model together, and output corresponding processing difficulty information and task analysis information for the task to be processed, wherein the first prompt word is used to guide the difficulty determination model to analyze and output the processing difficulty information of the task to be processed, and the second prompt word is used to guide the difficulty determination model to analyze and output the task analysis information of the task to be processed, and the task analysis information is used as prompt information for the target model to process the task to be processed; The calling of the target model to process the task to be processed and obtaining the processing result of the task to be processed includes: The task to be processed and the task analysis information are input into the target model, and the processing result of the task to be processed is output.
5. The method according to claim 1, characterized in that The evaluation information includes processing difficulty information, and the evaluation information of the task to be processed is determined, including: Inputting the task to be processed into a pre-trained difficulty judgment model, and outputting processing difficulty information of the task to be processed; The difficulty judgment model is trained by the following method: determining a benchmark training set, wherein the benchmark training set includes a plurality of sample tasks and corresponding sample processing results; Determine a difficulty training set according to the plurality of candidate models and the benchmark training set, wherein the difficulty training set includes a plurality of sample tasks and corresponding difficulty labels; The difficulty judgment model is trained according to the difficulty training set.
6. The method according to claim 5, characterized in that The step of determining a difficult training set according to the plurality of candidate models and the benchmark training set comprises: Input the sample tasks into each of the candidate models respectively to obtain sample prediction results of each of the candidate models; Determining a difficulty label of the sample task according to the sample processing result and the sample prediction results of the plurality of candidate models; A difficulty training set is determined according to the plurality of sample tasks and corresponding difficulty labels.
7. The method according to claim 6, characterized in that The step of determining the difficulty label of the sample task according to the sample processing result and the sample prediction results of the plurality of candidate models comprises: In the case where there is at least one sample prediction result matching the sample processing result in the sample prediction results of the sample task, determining a matching candidate model, wherein the matching candidate model is a candidate model having the smallest model parameter amount among the candidate models corresponding to the matching sample prediction results; Determining a difficulty label of the sample task according to the model parameter quantity of the matching candidate model; In a case where there is no sample prediction result matching the sample processing result in the sample prediction results of the sample task, the difficulty label is determined to be a difficulty label representing a preset maximum difficulty value.
8. The method according to claim 1, characterized in that: The evaluation information includes accuracy information of the processing result of the task to be processed, and the evaluation information of the task to be processed is determined including: Selecting an accuracy evaluation model from the plurality of candidate models according to a preset order, wherein the preset order is an order from small to large model parameter amount; Processing the task to be processed by the accuracy evaluation model to obtain corresponding accuracy information and candidate processing results; Wherein, the method further comprises: When the accuracy information obtained by the current accuracy evaluation model satisfies the accuracy condition, outputting the candidate processing result determined by the accuracy evaluation model as the processing result of the task to be processed; When the accuracy information obtained by the current accuracy evaluation model does not meet the accuracy condition, the next candidate model is determined as a new accuracy evaluation model according to the preset order, and the accuracy information is re-determined.
9. The method according to claim 8, characterized in that The model parameter quantity of the Nth candidate model in the preset order is greater than the sum of the model parameter quantities of the 1st candidate model to the N-1th candidate model, and N is an integer greater than 1.
10. The method according to any one of claims 1 to 9, characterized in that: The task to be processed includes any one of an image processing task, a voice processing task, a text processing task, and a video processing task.
11. A task processing device, characterized in that: include: An information determination module, configured to determine evaluation information of the task to be processed in response to receiving the task to be processed; A model matching module, used to determine a matching target model from a plurality of candidate models according to the evaluation information, wherein different candidate models have different model parameter amounts, and the target model is a model with the smallest model parameter amount among the candidate models that can process the task to be processed; The task processing module is used to call the target model to process the task to be processed and obtain the processing result of the task to be processed.
12. An electronic device, characterized in that: include: at least one processor; as well as a memory communicatively connected to the at least one processor; wherein, The memory stores one or more computer programs that can be executed by the at least one processor, and the one or more computer programs are executed by the at least one processor to enable the at least one processor to perform the task processing method according to any one of claims 1 to 10.
13. A computer-readable storage medium having a computer program stored thereon, characterized in that: When the computer program is executed by a processor, the computer program implements the task processing method according to any one of claims 1 to 10.
Citation Information
Cited By
Intelligent question answering method and device based on large model, medium, equipment and product
CN120386850A
Model task classification method and device, model selection method and electronic equipment
CN121093185A
Action plan generation method and related product
CN121278404A
Task processing method and device, all-in-one machine equipment, storage medium and program product
CN121787398A