Task execution method and electronic equipment
By generating target execution plans from historical cases and knowledge, the problem of low modeling efficiency in time series forecasting is solved, achieving high-precision, interpretable task execution results and automated decision-making processes, and optimizing model selection and training schemes.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- LENOVO (BEIJING) LTD
- Filing Date
- 2026-01-30
- Publication Date
- 2026-05-12
AI Technical Summary
In the field of time series forecasting, building high-performance and robust forecasting models is characterized by low modeling efficiency and high cost, especially in the data preprocessing, feature engineering, and model selection and parameter tuning stages, which are highly dependent on professional knowledge.
By identifying target reference information from multiple historical cases and historical knowledge, a target execution plan is generated and executed to obtain task execution results. A large model is used to generate structured execution plans and results, and multi-dimensional retrieval is performed by combining data anomaly information and statistical features to optimize model selection and training scheme.
It improves the accuracy and reliability of task execution, reduces trial and error, makes the decision-making process more transparent and explainable, reduces the cost of manual intervention, and improves the automation and intelligence of task execution.
Smart Images

Figure CN122022431A_ABST
Abstract
Description
Technical Field
[0001] This application relates to, but is not limited to, the field of computer technology, and in particular to a task execution method and an electronic device. Background Technology
[0002] In the field of time series forecasting (e.g., retail demand forecasting, energy load forecasting, and financial indicator forecasting), building high-performance and robust forecasting models is a complex and experience-intensive task. This task typically involves multiple stages such as data preprocessing, feature engineering, model selection and parameter tuning, resulting in a large decision space, strong reliance on professional knowledge, and consequently low modeling efficiency and high cost. Summary of the Invention
[0003] In view of this, this application provides at least one task execution method and electronic device.
[0004] The technical solution of this application is implemented as follows: On the one hand, this application provides a task execution method, the method comprising: Based on the target task information input by the user, target reference information is determined from multiple historical cases and multiple historical knowledge sources; the target task information includes instruction information and time-series data to be processed; historical cases represent task execution instances of historical tasks related to historical time-series data; historical knowledge represents task execution experience related to historical time-series data; the target reference information includes at least one of the target historical cases and target historical knowledge. Generate a target execution plan based on instruction information, pending timing data, and target reference information; Execute the target execution plan to obtain the task execution results corresponding to the target task information.
[0005] In some implementations, target reference information is determined from multiple historical cases and multiple historical knowledge sources based on the target task information input by the user, including: Based on the instruction information, determine the target metadata and text description; Based on the target metadata and text description, determine at least one of the first historical case and the target historical knowledge from multiple historical cases and multiple historical knowledge; Once the first historical case is identified, the target historical case is determined from the first historical case based on the time series data to be processed.
[0006] In some implementations, the target historical case is determined from the first historical case based on the time-series data to be processed, including: Determine the target time series features corresponding to the time series data to be processed; Based on the target time series characteristics and the historical time series characteristics corresponding to the historical time series data in each first historical case, the target historical cases are determined from the first historical cases.
[0007] In some implementations, the method further includes: Based on the time series data to be processed, determine the data anomaly information and statistical characteristic information; Based on the target metadata and text description, determine at least one of the first historical case and the target historical knowledge from multiple historical cases and multiple pieces of historical knowledge, including: Based on data anomaly information, statistical feature information, target metadata, and text description, determine at least one of the first historical case and the target historical knowledge from multiple historical cases and multiple historical knowledge.
[0008] In some implementations, the target execution plan represents a linear execution scheme consisting of at least a model selection scheme and a model training scheme; Execute the target execution plan to obtain the task execution results corresponding to the target task information, including: Based on the model selection scheme, the first model is determined; According to the model training scheme, the first model is trained using the time series data to be processed, and the second model is obtained. Based on the target task information, the second model is used to generate the task execution results corresponding to the target task information.
[0009] In some implementations, a target execution plan is generated based on instruction information, timing data to be processed, and target reference information, including: Based on the instruction information, the timing data to be processed, and the target reference information, generate target prompt information; Based on the target information, a target execution plan is generated using the third model; the third model includes at least the main model.
[0010] In some implementations, the method further includes: Based on the target task information, the execution process of the target execution plan, and the task execution results, determine the target cases corresponding to the target task information; Store the target case in the case database; the case database contains multiple historical cases.
[0011] In some implementations, the case database includes second historical cases that belong to the same context type as the target case; the context type is obtained by clustering the cases in the case database. The method also includes: Based on the target case and the second historical case, the fourth model is used to generate the first knowledge. Validate the utility of first knowledge; In response to the first knowledge being validated for utility, the first knowledge is updated in the knowledge database; the knowledge database stores multiple pieces of historical knowledge.
[0012] In some implementations, updating the knowledge database with the first knowledge includes: In cases where there is a semantic conflict between the first knowledge and the second knowledge among multiple historical knowledge sources, the first knowledge and the second knowledge are input into the fourth model to generate the third knowledge. Validate the utility of third-party knowledge; In response to the utility verification of the third knowledge, the third knowledge is updated to the knowledge database.
[0013] On the other hand, this application also provides an electronic device, which includes: a memory and at least one processor; wherein, The memory stores computer programs that can be run on the processor; when the processor executes the program, it is used for: Based on the target task information input by the user, target reference information is determined from multiple historical cases and multiple historical knowledge sources; the target task information includes instruction information and time-series data to be processed; historical cases represent task execution instances of historical tasks related to historical time-series data; historical knowledge represents task execution experience related to historical time-series data; the target reference information includes at least one of the target historical cases and target historical knowledge. Generate a target execution plan based on instruction information, pending timing data, and target reference information; Execute the target execution plan to obtain the task execution results corresponding to the target task information.
[0014] It should be understood that the above general description and the following detailed description are merely exemplary and explanatory, and are not intended to limit the technical solutions of this application. Attached Figure Description
[0015] The accompanying drawings, which are incorporated in and constitute a part of this specification, illustrate embodiments consistent with this application and, together with the specification, serve to explain the technical solutions of this application.
[0016] Figure 1 A schematic diagram illustrating the implementation process of a task execution method provided in this application; Figure 2 A schematic diagram illustrating the implementation process of one embodiment provided in this application; Figure 3 A schematic diagram illustrating the implementation process of another embodiment provided in this application; Figure 4 This is a schematic diagram of the hardware entity of an electronic device provided in this application. Detailed Implementation
[0017] To make the objectives, technical solutions, and advantages of this application clearer, the technical solutions of this application are further described in detail below with reference to the accompanying drawings and embodiments. The described embodiments should not be regarded as limitations on this application. All other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of this application.
[0018] In the following description, references are made to “some embodiments,” which describe a subset of all possible embodiments. However, it is understood that “some embodiments” may be the same subset or different subsets of all possible embodiments and may be combined with each other without conflict.
[0019] The terms “first / second / third” are used merely to distinguish similar objects and do not represent a specific ordering of objects. It is understood that “first / second / third” may be interchanged in a specific order or sequence where permitted, so that the embodiments of this application described herein can be implemented in an order other than that illustrated or described herein.
[0020] Unless otherwise defined, all technical and scientific terms used herein have the same meaning as commonly understood by one of ordinary skill in the art to which this application pertains. The terminology used herein is for descriptive purposes only and is not intended to limit the scope of this application.
[0021] This application provides a task execution method that can be executed by an electronic device. The electronic device can be various types of terminals such as laptops, tablets, desktop computers, set-top boxes, and mobile devices (e.g., mobile phones, portable music players, personal digital assistants, dedicated messaging devices, portable gaming devices), or it can be implemented as a server. The server can be a standalone physical server, a server cluster or distributed system composed of multiple physical servers, or a cloud server providing basic cloud computing services such as cloud services, cloud databases, cloud computing, cloud functions, cloud storage, network services, cloud communication, middleware services, domain name services, security services, content delivery networks (CDNs), and big data and artificial intelligence platforms.
[0022] The technical solution provided in this application will now be described clearly and completely with reference to the accompanying drawings.
[0023] Figure 1 A schematic diagram illustrating the implementation flow of a task execution method provided in this application is shown below. Figure 1 As shown, the method includes the following steps S11 to S13: Step S11: Based on the target task information input by the user, determine target reference information from multiple historical cases and multiple historical knowledge; the target task information includes instruction information and time-series data to be processed; historical cases represent task execution instances of historical tasks related to historical time-series data; historical knowledge represents task execution experience related to historical time-series data; the target reference information includes at least one of target historical cases and target historical knowledge. Step S12: Generate a target execution plan based on the instruction information, the timing data to be processed, and the target reference information; Step S13: Execute the target execution plan to obtain the task execution results corresponding to the target task information.
[0024] Target task information refers to the query information entered by the user, including the user's request or question.
[0025] The target task information includes instruction information and time-series data to be processed. Among them: Command information refers to descriptive data from a user regarding a specific request or question. In some implementations, this command information can be text information, voice information, or multimodal information, etc. Time-series data refers to a series of data points recorded in chronological order (e.g., at equal time intervals). Examples include stock price data, exchange rate data, and trading volume data recorded at minute or day intervals. Other examples include temperature data, rainfall data, and humidity data recorded at day or year intervals.
[0026] The time-series data to be processed refers to the raw time-series data input by the user in response to the request or question described in the instruction information. For example, in the case of the instruction information being "predict sales revenue for the next 7 days," the time-series data to be processed could be product sales data recorded at daily intervals over the past year, 6 months, or 3 months. In some implementations, the time-series data to be processed also includes at least one covariate data related to the main variable data; wherein, the main variable is the target variable that the request or question described in the instruction information requires to be solved or predicted; and the covariate is an auxiliary variable that affects the main variable. For example, in the example of "predicting sales revenue for the next 7 days" above, the main variable is "sales revenue," and the covariate could be unit price, date, whether it is a holiday, etc.
[0027] Historical cases represent instances of task execution related to historical time-series data. In some implementations, these historical cases can be cases obtained in production practice, or cases obtained from a specified database or public network resources.
[0028] In some implementations, historical cases are cases obtained by summarizing the task execution process of historical tasks. For example, historical cases may include at least one of the following: data preprocessing schemes, feature engineering schemes, model selection schemes, hyperparameter setting schemes, and model evaluation schemes for historical time series data.
[0029] In some implementations, historical cases may also include experiential information corresponding to historical tasks. For example, after executing a historical task, the execution process of the historical task is reviewed to obtain the case experience corresponding to that historical case.
[0030] Historical knowledge represents experiential information related to historical time-series data. For example, historical knowledge can be patterns (i.e., useful or effective experience) and / or anti-patterns (i.e., invalid or harmful experience) related to the processing of historical time-series data.
[0031] In some implementations, historical knowledge can be empirical conclusions drawn by experts in the relevant field. For example, for time series data with strong weekly seasonality, Fourier term modeling is preferred.
[0032] In some implementations, historical knowledge can be general suggestions obtained through automated learning. For example, historical knowledge can be derived by summarizing experiences from multiple historical cases using a large language model.
[0033] In this way, after obtaining the target task information input by the user, multiple historical cases and multiple historical knowledge are retrieved to determine the target reference information related to the target task information.
[0034] The target reference information refers to target historical cases and / or target historical knowledge related to the target task information; wherein, a target historical case may include at least one historical case; and target historical knowledge may include at least one piece of historical knowledge. In some implementations, the number of target historical cases and the number of target historical knowledge can be preset.
[0035] In some implementations, mapping relationships can be established between target task information and multiple historical cases and multiple pieces of historical knowledge, respectively, so as to determine target reference information based on the mapping relationships. For example, mapping relationships between multiple task types and multiple historical cases, and between multiple task types and multiple pieces of historical knowledge can be established in advance, so as to determine target reference information according to the task type corresponding to the target task information and the pre-established mapping relationships.
[0036] In some implementations, keyword searches can be performed on multiple historical cases and multiple pieces of historical knowledge based on keywords in the target task information to determine the target reference information.
[0037] In some implementations, when multiple historical cases and multiple pieces of historical knowledge are stored as vector data, the multiple historical cases and multiple pieces of historical knowledge can be retrieved based on the vector data corresponding to the target task information to obtain the target reference information.
[0038] In some implementations, target reference information can be determined by retrieving multiple historical cases and multiple pieces of historical knowledge based on at least one of the instruction information in the target task information and the time-series data to be processed. For example, in the example of "predicting sales revenue for the next 7 days" mentioned above, multiple historical cases and multiple pieces of historical knowledge can be retrieved based solely on the instruction information of this text type to determine target reference information related to the "prediction task" and / or the "sales revenue prediction task". As another example, in the example of "predicting sales revenue for the next 7 days" mentioned above, multiple historical cases and multiple pieces of historical knowledge can be retrieved based solely on the corresponding time-series data to be processed to determine target reference information with the same or similar time-series characteristics as the time-series data to be processed. Yet another example, in the example of "predicting sales revenue for the next 7 days" mentioned above, multiple historical cases and multiple pieces of historical knowledge can be retrieved based on the instruction information of this text type and the corresponding time-series data to be processed to determine target reference information related to both the instruction information and the time-series data to be processed.
[0039] In some implementations, based on the target task information input by the user, multiple historical cases and pieces of historical knowledge can be retrieved using any retrieval method to determine the target reference information. For example, keyword retrieval, natural language retrieval, and structured retrieval using specific syntax or query languages can be employed. Other examples include Boolean retrieval strategies, vector retrieval algorithms, hierarchical filtering strategies, sparse retrieval strategies, and dense retrieval strategies. In some implementations, a hybrid retrieval strategy can be used. For instance, a hybrid retrieval strategy combining sparse and dense retrieval strategies can be employed.
[0040] In this way, after determining the target reference information related to the target task information, a target execution plan is generated based on the instruction information, the timing data to be processed, and the target reference information in the target task information to execute the request or problem described in the instruction information.
[0041] In some implementations, the target execution plan is a pipeline plan consisting of multiple execution schemes. For example, the target execution plan is a pipeline plan consisting of a model selection scheme and a model training scheme. In this way, by executing the target execution plan, a trained model can be obtained, and then the trained model can be used to execute the user task corresponding to the target task information.
[0042] In some implementations, the target execution plan includes multiple execution plans; wherein, the multiple plans include a primary plan with high recommendation and at least one candidate plan with lower recommendation. Thus, if the primary plan fails to execute, a candidate plan can be activated to improve the success rate of the user task.
[0043] In some implementations, when the target reference information includes at least one historical case, a target execution plan can be generated based on the task execution scheme or task review results involved in the at least one historical case. For example, if the historical cases in the target reference information include model selection schemes and hyperparameter range setting schemes, the model selection scheme and hyperparameter range setting scheme in the target execution plan can be determined by referring to the historical cases.
[0044] In some implementations, if the target reference information includes at least one piece of historical knowledge, the target execution plan can be generated based on that historical knowledge. For example, if the historical knowledge in the target reference information includes "on daily retail sequences during strong weekly seasons, the recommended historical window length for a Patch TimeSeries Transformer (PatchTST) time series forecasting model based on a Transformer architecture is a grid search over the past 224 to 384 time points; too short a window will attenuate seasonal and event patterns, while too long a window will introduce irrelevant noise," then the model hyperparameter range setting scheme in the target execution plan can be determined by referring to this historical knowledge.
[0045] In some implementations, at least one execution step or scheme in the target execution plan has a corresponding reference information index; wherein, the reference information index is used to identify the corresponding historical cases or historical knowledge. For example, if the reference information index corresponding to a scheme in the target execution plan is "Reference Case C001", it means that the scheme was generated from a historical case with reference identification information C001. As another example, if the reference information index corresponding to a scheme in the target execution plan is "Drawn from Knowledge K008", it means that the step was generated from historical knowledge with reference identification information K008. Thus, by including a detailed reference information index in the target execution plan, the decision-making process can be made transparent, allowing users to clearly understand "why this model is recommended" or "what risks need to be guarded against," facilitating manual intervention and risk assessment.
[0046] In this way, after determining the target execution plan, the plan is executed to obtain the task execution results corresponding to the target task information. For example, the task execution results can be data prediction results, anomaly analysis results, information retrieval results, etc.
[0047] In the embodiments provided in this application, firstly, target reference information is determined from multiple historical cases and multiple pieces of historical knowledge based on the target task information input by the user. The target task information includes instruction information and time-series data to be processed. Historical cases represent task execution instances of historical tasks related to the historical time-series data, and historical knowledge represents task execution experience related to the historical time-series data. The target reference information includes at least one of target historical cases and target historical knowledge. Then, a target execution plan is generated based on the instruction information, the time-series data to be processed, and the target reference information. Finally, the target execution plan is executed to obtain the task execution result corresponding to the target task information. Thus, on the one hand, generating a target execution plan based on target reference information automatically determined from high-quality historical cases and historical knowledge that has been tested in practice can reduce a large amount of trial-and-error work and generate customized solutions for the form of the time-series data to be processed, thereby improving the execution accuracy of the user task corresponding to the target task information. On the other hand, by adding a reference information index to the target execution plan, the decision-making process can be made transparent, and detailed reference information support can be provided for the target execution plan and the task execution result generated based on the target execution plan, thereby improving the credibility and interpretability of the task execution result.
[0048] In some implementations, target reference information is determined from multiple historical cases and multiple historical knowledge sources based on the target task information input by the user. That is, step S11 above can be implemented as the following steps S111 to S113: Step S111: Determine the target metadata and text description based on the instruction information.
[0049] Here, target metadata is used to describe the task characteristics of the user task corresponding to the target task information.
[0050] In some implementations, the target metadata may include task type data describing the user task, such as a sales forecasting task, a data analysis task, or a data retrieval task. This allows for semantic analysis of the instruction information to determine the task type of the user task corresponding to that instruction information, and the determined task type is then used as the target metadata.
[0051] In some implementations, the target metadata may refer to at least one keyword extracted from the instruction information. Here, any suitable keyword extraction algorithm can be used to extract keywords from the instruction information to obtain at least one keyword. For example, the Term Frequency–Inverse Document Frequency (TF-IDF) algorithm, deep learning models, generative models, etc., can be used to extract keywords from the instruction information.
[0052] Text description refers to the task description of the user task corresponding to the target task information. In some implementations, the text description information includes information such as the task name, task type, task objective, input data, output requirements or constraints of the user task.
[0053] In some implementations, the text description can be generated through the following steps: First, the instruction information is initially parsed to obtain the parsing result, which includes at least the user's intent and the entities and relationships in the instruction information; then, based on the specified prompt word template and the parsing result, a structured preliminary task description is generated using a Large Language Model (LLM); subsequently, in cases of complex tasks or insufficient task information, the user is interacted with based on the preliminary task description to determine the task details; finally, based on the determined task details, the preliminary task description is regenerated to obtain the final task description, i.e., the text description.
[0054] Step S112: Based on the target metadata and text description, determine at least one of the first historical case and the target historical knowledge from multiple historical cases and multiple pieces of historical knowledge.
[0055] Here, multiple historical cases are retrieved based on the target metadata and text description to identify historical cases related to the target metadata and text description. If a historical case related to the target metadata and text description exists, it is taken as the first historical case; otherwise, the search result is determined to be empty.
[0056] For example, when retrieving multiple historical cases based on task feature information in the target metadata, the first historical case with the same or similar task features is identified from among the multiple historical cases. As another example, when retrieving multiple historical cases based on task name, task objective, task type, input data, output requirements, or constraints in the text description, the first historical case with the same or similar task name, task objective, task type, input data, output requirements, or constraints is identified from among the multiple historical cases.
[0057] Accordingly, multiple pieces of historical knowledge are retrieved based on the target metadata and text description to determine the historical knowledge related to the target metadata and text description from the multiple pieces of historical knowledge; if there is historical knowledge related to the target metadata and text description, then the related historical knowledge is taken as the target historical knowledge; if not, then the retrieval result is determined to be empty.
[0058] For example, when retrieving multiple pieces of historical knowledge based on task feature information in the target metadata, the target historical knowledge with the same or similar task features is identified from among the multiple pieces of historical knowledge. As another example, when retrieving multiple pieces of historical knowledge based on task name, task objective, task type, input data, output requirements, or constraints in the text description, the target historical knowledge with the same or similar task name, task objective, task type, input data, output requirements, or constraints is identified from among the multiple pieces of historical knowledge.
[0059] Step S113: Given the first historical case, determine the target historical case from the first historical case based on the time series data to be processed.
[0060] Here, if there is a first historical case related to the target metadata and text description among multiple historical cases, the first historical case is further searched based on the unprocessed time series data in the target task information in order to determine the target historical case from the first historical case.
[0061] In some implementations, the first historical case can be retrieved based on the data characteristics corresponding to the time series data to be processed, so as to determine the target historical case.
[0062] In some implementations, since each historical case includes historical time-series data, a retrieval can be performed on the first historical case based on the data characteristics of the time-series data to be processed and the data characteristics of the historical time-series data in the first historical case to determine the target historical case.
[0063] In some implementations, target historical cases can be determined from first historical cases through the following steps: First, determine the first similarity between each first historical case and the target metadata and text description, and determine the second similarity between each first historical case and the time series data to be processed; then, for each first historical case, calculate the weighted sum of the first similarity and the second similarity to obtain the third similarity corresponding to the first historical case; finally, based on the ranking result of the third similarity corresponding to at least one first historical case, select a specified number of first historical cases as target historical cases.
[0064] In the embodiments provided in this application, target historical knowledge is determined based on target metadata and text description, so that the target historical knowledge is related to the task features corresponding to the target task information, thereby improving the effectiveness of the target historical knowledge. At the same time, a first historical case is determined based on target metadata and text description, and a target historical case is further determined based on the time series data to be processed, so that the target historical case is not only related to the task features corresponding to the target task information, but also fits the features of the time series data to be processed, thereby improving the relevance and effectiveness of the target historical case.
[0065] In some implementations, the target historical case is determined from the first historical case based on the time-series data to be processed. That is, step S113 above can be implemented as steps S1131 to S1132: Step S1131: Determine the target time series features corresponding to the time series data to be processed.
[0066] The target time series feature refers to the feature data obtained after performing feature extraction on the time series data to be processed.
[0067] In some implementations, the target time-series features include statistical features and deep learning features corresponding to the time-series data to be processed.
[0068] In some implementations, a pre-trained time series base model or embedding model can be used to extract features from the time series data to be processed, thereby obtaining the corresponding high-dimensional abstract features, i.e., the target time series features.
[0069] Since the target time series feature integrates the statistical features and deep learning features of the time series data to be processed, it can accurately characterize the shape of the time series data to be processed. Therefore, the target time series feature can be used as the time series fingerprint corresponding to the time series data to be processed.
[0070] Step S1132: Determine the target historical case from the first historical cases based on the target time series characteristics and the historical time series characteristics corresponding to the historical time series data in each first historical case.
[0071] Here, the historical time series features corresponding to the historical time series data refer to the feature data obtained after performing feature extraction on the historical time series data.
[0072] In some implementations, historical time series features corresponding to historical time series data can be extracted using methods that are the same as or different from those used to extract the target time series features.
[0073] In some implementations, historical time-series features corresponding to historical time-series data can be predetermined, and these features can be associated with and stored in relation to the corresponding historical time-series data. In some implementations, after determining a first historical case from multiple historical cases, the historical time-series features corresponding to the historical time-series data in each determined first historical case can be determined.
[0074] Thus, after determining the first historical case, firstly, the fourth similarity between the target time series feature and the historical time series feature corresponding to the historical time series data in each first historical case is calculated; then, based on at least one calculated fourth similarity, a specified number of first historical cases are determined as target historical cases.
[0075] In some implementations, the fourth similarity between the target time-series feature and each historical time-series feature can be determined by calculating the Euclidean distance or cosine similarity between the target time-series feature and each historical time-series feature.
[0076] In the embodiments provided in this application, by introducing target time-series features, intelligent retrieval based on time-series patterns can be achieved, thereby improving the correlation between target historical cases and target task information, and thus optimizing task execution effect and decision credibility.
[0077] In some implementations, the task execution method further includes the following step S114: Step S114: Determine data anomaly information and statistical characteristic information based on the time series data to be processed.
[0078] Here, data anomaly information refers to errors or information that does not conform to the specified data format requirements contained in the time series data to be processed. For example, data anomaly information may include missing value information, outlier information, etc. in the time series data to be processed.
[0079] In some implementations, anomalies in the time series data to be processed can be determined by any suitable method. In some implementations, statistical models, predictive models, or large language models can be used to determine anomalies in the time series data to be processed. In some implementations, anomalies in the sequence data to be processed can be determined based on specified rules and thresholds.
[0080] Statistical characteristic information refers to numerical values or attributes extracted through statistical methods to describe the inherent patterns, distribution patterns, and / or sequence correlations of time-series data to be processed. For example, statistical characteristic information may include seasonality information, periodicity information, autocorrelation information, and stationarity information.
[0081] In some implementations, the statistical characteristics of the time series data to be processed can be determined using any suitable method. In some implementations, basic statistical rules can be used to determine the basic statistical characteristics of the time series data. For example, the mean, variance or standard deviation, maximum or minimum value, skewness, kurtosis, or percentiles of the time series data can be calculated. In some implementations, a sliding window or global calculation can be used to determine the time-domain characteristics of the time series data. For example, a linear regression method can be used to calculate the trend slope of the time series data within the sliding window to reflect a growth or decay trend. In some implementations, Fourier transform or wavelet transform can be used to convert the time series data to be processed into a frequency domain signal, thereby extracting frequency domain features.
[0082] In some implementations, the target metadata corresponding to the target task information may include data anomaly information and statistical feature information corresponding to the time-series data to be processed.
[0083] Thus, based on the target metadata and text description, at least one of the first historical case and the target historical knowledge is determined from multiple historical cases and multiple historical knowledge. That is, the above step S112 can be implemented as the following step S1121: Step S1121: Based on data anomaly information, statistical feature information, target metadata and text description, determine at least one of the first historical case and the target historical knowledge from multiple historical cases and multiple pieces of historical knowledge.
[0084] In this way, after identifying data anomaly information and statistical feature information from the time series data to be processed, based on the target metadata and text description, and in combination with the data anomaly information and statistical feature information, at least one of the first historical case and the target historical knowledge is determined from multiple historical cases and multiple historical knowledge.
[0085] For example, when retrieving multiple historical cases and multiple pieces of historical knowledge based on missing value information and / or outlier information in the data anomaly information, the first historical case with the same or similar missing value problem and / or outlier problem is identified from the multiple historical cases; and / or the target history for handling the missing value problem and / or outlier problem is identified from the multiple pieces of historical knowledge.
[0086] For example, when retrieving multiple historical cases and multiple pieces of historical knowledge based on seasonality, periodicity, autorelated information, and stationarity information in statistical feature information, the first historical case with the same or similar seasonality, periodicity, autorelated information, and stationarity information is identified from the multiple historical cases; and / or, the target historical knowledge with the same or similar seasonality, periodicity, autorelated information, and stationarity information is identified from the multiple pieces of historical knowledge.
[0087] In the embodiments provided in this application, by introducing data anomaly information and statistical feature information of the time series data to be processed, a multi-dimensional retrieval mechanism combining data anomaly information, statistical feature information, target metadata and text description is constructed, so that the retrieved target historical cases and / or target historical knowledge are highly relevant to the target task information at both the problem and data levels.
[0088] In some implementations, the target execution plan represents a linear execution scheme consisting of at least a model selection scheme and a model training scheme.
[0089] Here, the target execution plan is a linear execution plan consisting of multiple task execution schemes, and these multiple task execution schemes include at least a model selection scheme and a model training scheme.
[0090] The model selection scheme refers to the choice of which model to use to perform the task. For example, in the model selection scheme, the Transformer model can be recommended to perform the user task.
[0091] A model training scheme refers to the model training plan for the selected model, such as the hyperparameter range setting scheme, weight and hyperparameter adjustment scheme, loss function selection scheme, convergence conditions, etc.
[0092] In some implementations, the target execution plan may also include a data preprocessing scheme for the time-series data to be processed. For example, the data preprocessing scheme may include a scheme for handling missing values and / or outliers in the time-series data to be processed.
[0093] In some implementations, the target execution plan may also include a feature engineering scheme for the time series data to be processed. For example, the feature engineering scheme may be a scheme for calculating lag terms, rolling statistical features, and / or calendar features corresponding to the time series data to be processed.
[0094] In some implementations, the target execution plan may also include a validation scheme. For example, the validation scheme may include a rolling origin cross-validation scheme, such as a 5-fold cross-validation scheme.
[0095] In some implementations, the target execution plan may also include model evaluation metrics. For example, the model evaluation metrics may be Symmetric Mean Absolute Percentage Error (sMAPE), 90th percentile loss (P90 Pinball Loss), etc.
[0096] Thus, by executing the target execution plan and obtaining the task execution result corresponding to the task information, that is, step S13 above can be implemented as the following steps S131 to S133: Step S131: Select the first model based on the model selection scheme.
[0097] Here, based on the model selection scheme in the target execution plan, the first model specified in that scheme is determined. For example, the first model could be a GlobalTransformer model, an Autoregressive Integrated Moving Average (ARIMA) model, or something similar.
[0098] Step S132: According to the model training scheme, train the first model using the time series data to be processed to obtain the second model.
[0099] Here, the time series data to be processed is used as sample data. Based on the model training scheme specified in the target execution plan, such as the hyperparameter range setting scheme, weight and hyperparameter adjustment scheme, the first model is trained to obtain the second model. In some implementations, after the model training satisfies the convergence condition specified in the target execution plan, the model obtained from the last update is used as the second model.
[0100] In some implementations, the generalization ability of the first model is evaluated and the hyperparameter configuration of the first model is adjusted using a validation scheme in the target execution plan before training the first model with sample data.
[0101] In some implementations, before training the first model using sample data, data processing is performed on the time series data to be processed using a data preprocessing scheme and a feature engineering scheme to obtain sample data.
[0102] Step S133: Based on the target task information, use the second model to generate the task execution result corresponding to the target task information.
[0103] Here, after determining the second model, the target task information (i.e., instruction information and time sequence data to be processed) input by the user is input into the second model as prompt information, so as to use the second model to generate the task execution result corresponding to the target task information.
[0104] In some implementations, before inputting the time series data to be processed as a prompt message into the second model, the data preprocessing scheme and / or feature engineering scheme provided in the target execution plan can be used to perform data processing on the time series data to be processed, and the processed time series data to be processed can be input into the second model as a prompt message.
[0105] In the embodiments provided in this application, the task execution result is determined by executing an automatically generated target execution plan, which can improve the degree of automation of task execution. At the same time, since the target execution plan is determined based on target reference information related to the target task information, it has clear and reliable case and knowledge basis, thus making the task execution result more reliable, interpretable and accurate.
[0106] In some implementations, a target execution plan is generated based on the instruction information, the timing data to be processed, and the target reference information. That is, step S12 above can be implemented as steps S121 to S122: Step S121: Generate target prompt information based on instruction information, timing data to be processed, and target reference information; Step S122: Based on the target prompt information, use the third model to generate a target execution plan; the third model includes at least the large model.
[0107] Here, based on the instruction information, the timing data to be processed, and the target reference information, a target prompt message is generated using a specified prompt message template. This prompt message template is used at least to prompt the third model to generate structured output data.
[0108] The third model includes at least large models, such as large language models, large visual models, and large multimodal models.
[0109] In this way, after the target prompt information is input into the third model, the third model can combine the target reference information to generate the target execution plan corresponding to the instruction information and the time sequence data to be processed.
[0110] In some implementations, after the target prompt information is input into the third model, the third model can also generate a diagnostic summary corresponding to the target task information. The diagnostic summary describes the task characteristics corresponding to the target task information, such as the task type information of the user task, statistical characteristic information and / or abnormal data information in the time-series data to be processed, and summary information generated based on the target reference information.
[0111] In the embodiments provided in this application, by converting the target task information and target reference information into structured target prompt information, and using the target prompt information to guide the third model to generate a target execution plan, the automatic conversion from user input to a specific execution plan can be realized, thereby improving the automation level and task execution efficiency of the task execution method and reducing the cost of manual intervention.
[0112] In some embodiments, the task execution method further includes the following steps S14 to S15: Step S14: Based on the target task information, the execution process of the target execution plan, and the task execution results, determine the target case corresponding to the target task information; Step S15: Store the target case in the case database; the case database stores multiple historical cases.
[0113] Here, regarding the target task information, the target task information, task execution process, and task execution result can be recorded and summarized during the execution of the user task corresponding to the target task information and / or after the task execution result is determined, so as to determine the target case corresponding to the target task information.
[0114] In some implementations, the target case may include at least one of the following: data anomaly information and / or statistical feature information of the time series data to be processed, data preprocessing scheme for the time series data to be processed, feature engineering scheme, model selection scheme, model training scheme, validation scheme and / or hyperparameter search experience, model evaluation scheme, etc.
[0115] In some implementations, after determining the task execution result, the large model can be used to summarize the experience of the user's task execution process, and the obtained experience information can be used as the review information corresponding to the user's task.
[0116] After identifying the target case, it is stored in the case database. This way, when executing new user tasks later, the target case can be used as a historical case for reference.
[0117] Here, the case database is a database used to store multiple historical cases. In some implementations, the case database can be a document database or a vector database, etc. In some implementations, the case database is a vector database that supports a Retrieval-Augmented Generation (RAG) architecture.
[0118] In the embodiments provided in this application, by generating target cases, this application can systematically save the process and experience of task execution, thereby building a continuously growing case database containing multiple historical cases, and thus providing high-quality case references for subsequent task execution, improving the intelligence level and decision reliability of the task execution process.
[0119] In some implementations, the case database includes second historical cases that belong to the same context type as the target case; the context type is obtained by clustering the cases in the case database.
[0120] Here, the context type is the case type obtained by performing clustering processing on multiple historical cases in the case database and the target cases stored in the case database. In some implementations, the context type may include sales forecast type, logistics forecast type, or seasonal forecast type, etc.
[0121] In some implementations, clustering can be performed on multiple historical cases and target cases using the following steps: First, based on the metadata in each historical case and the target metadata in the target case, a first round of clustering is performed to obtain the first round of clustering results; wherein, the first round of clustering results includes at least one first cluster; each first cluster includes at least one historical case and / or target case; Then, for each first cluster, a second round of clustering is performed based on the historical time-series data of historical cases in the first cluster and / or the unprocessed time-series data of the target cases to obtain the second round of clustering results; wherein, the second round of clustering results includes at least one second cluster; each second cluster includes at least one historical case and / or target case.
[0122] In this way, at least one historical case and / or target case in each second cluster is considered as a case belonging to the same situation type.
[0123] A second historical case can refer to any historical case that belongs to the same context type as the target case (e.g., belongs to the same second cluster). In some implementations, a second historical case may include one historical case or multiple historical cases.
[0124] Thus, the task execution method further includes the following steps S16 to S18: Step S16: Generate first knowledge using the fourth model based on the target case and the second historical case.
[0125] The fourth model refers to a model with abstraction and reasoning capabilities. In some implementations, the fourth model can be a large model, such as a large language model, a visual language model, or a multimodal model.
[0126] In this way, after inputting the target case and the second historical case into the fourth model, the abstraction and reasoning capabilities of the fourth model can be used to summarize the experience of the target case and the second historical case, so as to generate deeper and more contextual knowledge hypotheses, that is, first knowledge.
[0127] In some implementations, a first prompt message is generated based on the target case, the second historical case, and a prohibited knowledge list. This first prompt message is then input into a fourth model, guiding it to generate first knowledge. The prohibited knowledge list refers to a list of knowledge or prohibited knowledge derived from summarizing past failures within the scenario types corresponding to the target case and the second historical case. For example, one piece of knowledge in this prohibited knowledge list might be, "Please note that the previously generated knowledge 'Use the ARIMA model whenever the sequence is seasonal' has been verified as invalid. Please avoid proposing similar broad and unrefined knowledge." Thus, during the generation of the first knowledge, the fourth model will refer to this knowledge to avoid generating broad and unrefined knowledge.
[0128] In some implementations, a second prompt is generated based on the target case, a second historical case, and output format requirements. This second prompt is then input into a fourth model, which generates first knowledge under the guidance of the second prompt. The output format requirements specify the format of the first knowledge output by the fourth model. For example, the output format requirements could be "output multiple candidate knowledge items in strict JavaScript Object Notation (JSON) format, each containing a specific recommendation and a rationale."
[0129] Step S17: Perform utility verification on the first knowledge.
[0130] Performing utility verification on first knowledge refers to verifying whether the first knowledge is effective and / or valuable in practical applications.
[0131] In some implementations, a third historical case belonging to the same context type as the target case can be used to perform utility verification on the first knowledge in order to determine whether the first knowledge is effective and / or valuable in the same context.
[0132] In some implementations, a fourth historical case belonging to a different context type than the target case can be used to perform utility verification on the first knowledge in order to determine whether the first knowledge is effective and / or valuable in other contexts, that is, to determine the robustness of the first knowledge.
[0133] In some implementations, the utility of the first knowledge can be verified using any method. For example, counterfactual estimation, scenario-based testing, and other methods can be used to verify the utility of the first knowledge.
[0134] In some implementations, the process of using counterfactual estimation to verify the utility of first knowledge is as follows: First, identify the fact group cases and the counterfact group cases. The fact group cases refer to the case group that uses first knowledge to perform the task, while the counterfact group cases refer to the case group that does not use first knowledge to perform the task. Furthermore, the cases in both the fact group cases and the counterfact group cases are either historical cases belonging to the same situational type as the target case, or historical cases belonging to a different situational type than the target case. Then, run the fact group case and the counterfact group case respectively, and obtain the utility metrics corresponding to the fact group case and the counterfact group case; where the utility metric can be sMAPE; Next, the conditional average treatment effect U on the utility index of the fact group cases and the counterfact group cases is calculated; wherein, in some embodiments, the conditional average treatment effect U refers to the difference between the average value of the utility index corresponding to the counterfact group cases and the average value of the utility index corresponding to the fact group cases. Finally, based on the conditional average treatment effect U, it is determined whether the first knowledge passes the utility verification; wherein, if the value of the conditional average treatment effect U is positive and greater than a specified threshold, the first knowledge is determined to pass the utility verification; conversely, if the value of the conditional average treatment effect U is negative or not greater than the specified threshold, the first knowledge is determined to fail the utility verification.
[0135] Step S18: In response to the first knowledge passing utility verification, the first knowledge is updated to the knowledge database; the knowledge database stores multiple historical knowledge entries.
[0136] Here, if the first knowledge passes the utility verification, the first knowledge is updated to the knowledge database; conversely, if the first knowledge fails the utility verification, the verification failure information is fed back to the fourth model so that the first knowledge can be regenerated using the fourth model.
[0137] The knowledge database is a database used to store multiple historical knowledge items. In some implementations, the knowledge database can be a document database or a vector database, etc. In some implementations, the knowledge database is a vector database that supports the RAG architecture.
[0138] In the embodiments provided in this application, on the one hand, the target case and the second historical case belonging to the same situation type are summarized and abstracted to obtain the first knowledge, and the first knowledge is stored in the knowledge database, realizing the dynamic updating of the knowledge database and improving the availability and intelligence of the knowledge database; on the other hand, the utility verification of the first knowledge can ensure that only effective and / or valuable knowledge can be stored in the knowledge database, thus improving the reliability of the knowledge database; furthermore, from the task execution process corresponding to the target task information, the summary of the target case, the generation of the first knowledge, to the storage of the first knowledge, a continuous learning and knowledge distillation closed loop is formed, so that the task execution process for the target task information can bring knowledge increments, providing support for subsequent task execution.
[0139] In some implementations, updating the first knowledge to the knowledge database, i.e., step S18 above, can be implemented as steps S181 to S183: In step S181, if there is a semantic conflict between the first knowledge and the second knowledge in multiple historical knowledge, the first knowledge and the second knowledge are input into the fourth model to generate the third knowledge.
[0140] Here, when storing the first knowledge in the knowledge database, the knowledge database checks the first knowledge against multiple stored historical knowledge entries to determine whether there is any second knowledge that semantically conflicts with the first knowledge.
[0141] Semantic conflict refers to a situation where the first piece of knowledge and the second piece of knowledge have the same or similar premises, but offer semantically opposite suggestions. For example, if the first piece of knowledge is "use the ARIMA model to process highly seasonal time-series data" and the second piece of knowledge is "use the GlobalTransformer model to process highly seasonal time-series data," it is clear that the premises of the first and second pieces of knowledge are similar (i.e., both are "processing highly seasonal time-series data"), but the suggestions they give are completely different.
[0142] In this case, the first and second knowledge are input into the fourth model to fuse the first and second knowledge and generate the third knowledge. For example, in the example above, the fourth model can be used to fuse the knowledge content of the first and second knowledge and resolve conflicts to obtain the following third knowledge: "Use a hybrid model of ARIMA model and GlobalTransformer model to process time series data with strong seasonality".
[0143] Step S182: Perform utility verification on the third knowledge.
[0144] Here, utility verification is performed on the generated third knowledge to determine whether the third knowledge is effective and / or valuable in practical applications.
[0145] In some implementations, the utility verification method, which may be the same as or different from that of the first knowledge, may be used to verify the utility of the third knowledge.
[0146] Step S183: In response to the utility verification of the third knowledge, update the third knowledge to the knowledge database.
[0147] Here, if the third knowledge passes utility verification, the third knowledge is updated in the knowledge database. In some implementations, if the third knowledge is updated in the knowledge database, the second knowledge is deleted.
[0148] As can be seen from the above, in the embodiments provided by this application, when there is a semantic conflict between the first knowledge and the stored second knowledge, the third knowledge can be obtained by fusing the first knowledge and the second knowledge. This can avoid the existence of contradictory knowledge in the knowledge database, thereby improving the consistency and reliability of the knowledge stored in the knowledge database during the continuous expansion of the knowledge database.
[0149] Below, in conjunction with Figure 2 The implementation process of one embodiment provided in this application will be described; wherein, a target intelligent agent is used to execute the task execution method described in this embodiment. Figure 2 As shown, this embodiment includes the following steps S21 to S25: Step S21: Obtain the query information input by the user; then, proceed to step S22. Here, the query information entered by the user includes text data and raw time-series data.
[0150] Step S22: Perform data analysis on the text data and raw time-series data in the query information to obtain metadata and task description; then, execute step S23. Here, firstly, data analysis is performed on the original time-series data to identify missing values, outliers, and statistical characteristics. Then, data analysis is performed on the text data to identify the task type, task objective, and text data. Afterward, the statistical characteristics, task type, task objective, and text data are used as metadata, and a task description is generated based on the identified metadata and query information.
[0151] Step S23: Based on metadata, task description, and raw time-series data, retrieve the case database and knowledge database to determine at least one target retrieval result; then, proceed to step S24. Here, firstly, a broad search is performed on the case database and the knowledge database using metadata and task descriptions to obtain at least one of at least one fifth historical case and at least one fourth historical knowledge. If at least one fourth historical knowledge is obtained using the broad search, the first number of fourth historical knowledge with high similarity among the at least one fourth historical knowledge is taken as the target search results. Then, if at least one fifth historical case is obtained using the broad search, a fine-ranking search is performed on the at least one fifth historical case based on the temporal characteristics corresponding to the original temporal data to determine the second number of target search results with high similarity among the at least one fifth historical case.
[0152] Step S24: Input metadata, task description, raw time-series data and at least one target retrieval result into the large language model to generate a diagnostic summary and at least one executable plan using the large language model; then, execute step S25. Here, at least one executable plan includes a primary plan and at least one candidate plan; each executable plan includes multiple linear execution schemes, and at least one linear execution scheme has a corresponding reference information index.
[0153] Step S25: Execute the primary plan from at least one executable plan to obtain the task execution result.
[0154] Here, for the main plan, the Reasoning + Acting (ReAct) mode and the Plan & Execute mode can be combined to generate code using a large language model and execute it to obtain the task execution result.
[0155] Below, in conjunction with Figure 3 Another embodiment provided in this application will be described; wherein, a target intelligent agent is used to execute the task execution method described in this embodiment. Figure 3 As shown, this embodiment includes steps S31 to S38: Step S31: Perform clustering on historical cases in the case database to obtain at least one cluster; then, proceed to step S32. Here, clustering is performed based on the metadata and historical time-series data corresponding to each historical case in the case database to obtain at least one cluster; wherein each cluster contains at least one historical case; and each cluster has a corresponding scenario type.
[0156] Step S32: For the specified cluster, generate candidate knowledge corresponding to the cluster using the large language model; then, execute step S33. Step S33: Perform utility verification on candidate knowledge using counterfactual estimation; then, proceed to step S34. Step S34: Determine whether the candidate knowledge passes the utility verification; if yes, proceed to step S35; otherwise, proceed to step S36. Step S35: Based on the utility verification failure information and the specified clusters, generate updated candidate knowledge using the large language model; then, execute step S33. Step S36: Determine whether there is a semantic conflict between the candidate knowledge and multiple historical knowledge entries in the knowledge database; if yes, proceed to step S37; if no, proceed to step S38. Step S37: Based on the candidate knowledge and historical knowledge that semantically conflicts with the candidate knowledge, generate updated candidate knowledge using a large language model; then, execute step S33. Step S38: Store the candidate knowledge in the knowledge database; As can be seen from the above embodiments, this application provides a task execution method. On the one hand, by constructing a case database and a knowledge database, historical cases, expert experience, and tacit knowledge are structurally preserved, allowing the target intelligent agent to refer to the case database and knowledge database to execute the current task. On the other hand, by using metadata, task description, and raw time-series data to retrieve the case database and knowledge database, at least one target retrieval result is obtained, making the at least one target retrieval result highly relevant to the query information at both the task and data levels. Furthermore, during task execution, the target intelligent agent not only outputs the task execution result but also outputs at least one executable plan containing reference information indexes, making the executable plan and the task execution result generated based on the executable plan interpretable and credible. Moreover, the task execution process corresponding to the query information and the online performance of the obtained model are automatically recorded as new cases and stored in the case database. By periodically summarizing and abstracting multiple cases belonging to the same scenario type to generate new knowledge, a closed loop of continuous learning and knowledge distillation is formed, making the knowledge database increasingly diversified and intelligent.
[0157] Based on the foregoing embodiments, this application also provides an electronic device. For example... Figure 4 As shown, the electronic device 400 includes: a memory 410 and at least one processor 420; wherein, The memory 410 stores a computer program that can run on the processor 420; when the processor 420 executes the program, it is used for: Based on the target task information input by the user, target reference information is determined from multiple historical cases and multiple historical knowledge sources; the target task information includes instruction information and time-series data to be processed; historical cases represent task execution instances of historical tasks related to historical time-series data; historical knowledge represents task execution experience related to historical time-series data; the target reference information includes at least one of the target historical cases and target historical knowledge. Generate a target execution plan based on instruction information, pending timing data, and target reference information; Execute the target execution plan to obtain the task execution results corresponding to the target task information.
[0158] In some implementations, processor 420 is used for: Based on the instruction information, determine the target metadata and text description; Based on the target metadata and text description, determine at least one of the first historical case and the target historical knowledge from multiple historical cases and multiple historical knowledge; Once the first historical case is identified, the target historical case is determined from the first historical case based on the time series data to be processed.
[0159] In some implementations, processor 420 is used for: Determine the target time series features corresponding to the time series data to be processed; Based on the target time series characteristics and the historical time series characteristics corresponding to the historical time series data in each first historical case, the target historical cases are determined from the first historical cases.
[0160] In some implementations, processor 420 is used for: Based on the time series data to be processed, determine the data anomaly information and statistical characteristic information; Based on the target metadata and text description, determine at least one of the first historical case and the target historical knowledge from multiple historical cases and multiple pieces of historical knowledge, including: Based on data anomaly information, statistical feature information, target metadata, and text description, determine at least one of the first historical case and the target historical knowledge from multiple historical cases and multiple historical knowledge.
[0161] In some implementations, the target execution plan represents a linear execution scheme consisting of at least a model selection scheme and a model training scheme; Processor 420 is also used for: Based on the model selection scheme, the first model is determined; According to the model training scheme, the first model is trained using the time series data to be processed, and the second model is obtained. Based on the target task information, the second model is used to generate the task execution results corresponding to the target task information.
[0162] In some implementations, processor 420 is used for: Based on the instruction information, the timing data to be processed, and the target reference information, generate target prompt information; Based on the target information, a target execution plan is generated using the third model; the third model includes at least the main model.
[0163] In some implementations, the processor 420 is also used for: Based on the target task information, the execution process of the target execution plan, and the task execution results, determine the target cases corresponding to the target task information; Store the target case in the case database; the case database contains multiple historical cases.
[0164] In some implementations, the case database includes second historical cases that belong to the same context type as the target case; the context type is obtained by clustering the cases in the case database. Thus, the processor 420 is also used for Based on the target case and the second historical case, the fourth model is used to generate the first knowledge. Validate the utility of first knowledge; In response to the first knowledge being validated for utility, the first knowledge is updated in the knowledge database; the knowledge database stores multiple pieces of historical knowledge.
[0165] In some implementations, processor 420 is used for: In cases where there is a semantic conflict between the first knowledge and the second knowledge among multiple historical knowledge sources, the first knowledge and the second knowledge are input into the fourth model to generate the third knowledge. Validate the utility of third-party knowledge; In response to the utility verification of the third knowledge, the third knowledge is updated to the knowledge database.
[0166] It should be noted that the descriptions of the above device embodiments are similar to those of the above method embodiments, and have similar beneficial effects. In some embodiments, the functions or components of the device provided in this application can be used to perform the methods described in the above method embodiments. For technical details not disclosed in the device embodiments of this application, please refer to the descriptions of the method embodiments of this application for understanding.
[0167] The above are merely embodiments of this application, but the scope of protection of this application is not limited thereto. Any variations or substitutions that can be easily conceived by those skilled in the art within the scope of the technology disclosed in this application should be included within the scope of protection of this application.
Claims
1. A task execution method, comprising: Based on the target task information input by the user, target reference information is determined from multiple historical cases and multiple historical knowledge. The target task information includes instruction information and time-series data to be processed; the historical cases represent task execution instances of historical tasks related to the historical time-series data; the historical knowledge represents task execution experience related to the historical time-series data; the target reference information includes at least one of target historical cases and target historical knowledge. A target execution plan is generated based on the instruction information, the timing data to be processed, and the target reference information. Execute the target execution plan to obtain the task execution result corresponding to the target task information.
2. The method according to claim 1, wherein determining the target reference information from multiple historical cases and multiple historical knowledge based on the target task information input by the user includes: Based on the instruction information, determine the target metadata and text description; Based on the target metadata and the text description, at least one of the first historical case and the target historical knowledge is determined from the plurality of historical cases and the plurality of historical knowledge; If the first historical case is determined, the target historical case is determined from the first historical case based on the time series data to be processed.
3. The method according to claim 2, wherein determining the target historical case from the first historical case based on the time-series data to be processed includes: Determine the target time series features corresponding to the time series data to be processed; Based on the target time series characteristics and the historical time series characteristics corresponding to the historical time series data in each first historical case, the target historical case is determined from the first historical case.
4. The method according to claim 2, further comprising: Based on the time-series data to be processed, determine the data anomaly information and statistical characteristic information; The step of determining at least one of the first historical case and the target historical knowledge from the plurality of historical cases and the plurality of historical knowledge based on the target metadata and the text description includes: Based on the data anomaly information, the statistical feature information, the target metadata, and the text description, at least one of the first historical case and the target historical knowledge is determined from the multiple historical cases and the multiple historical knowledge.
5. The method according to any one of claims 1 to 3, wherein the target execution plan represents a linear execution scheme consisting of at least a model selection scheme and a model training scheme; The execution of the target execution plan to obtain the task execution result corresponding to the target task information includes the following: Based on the model selection scheme, the first model is determined; According to the model training scheme, the first model is trained using the time series data to be processed to obtain the second model; Based on the target task information, the second model is used to generate the task execution result corresponding to the target task information.
6. The method according to any one of claims 1 to 5, wherein generating a target execution plan based on the instruction information, the timing data to be processed, and the target reference information comprises: Based on the instruction information, the timing data to be processed, and the target reference information, generate target prompt information; Based on the target prompt information, the third model is used to generate the target execution plan; The third model includes at least the large model.
7. The method according to any one of claims 1 to 6, further comprising: Based on the target task information, the execution process of the target execution plan, and the task execution results, the target case corresponding to the target task information is determined; The target cases are stored in the case database; The case database stores the aforementioned historical cases.
8. The method according to claim 7, wherein the case database includes second historical cases belonging to the same context type as the target case; the context type is obtained by clustering the cases in the case database; The method further includes: Based on the target case and the second historical case, the fourth model is used to generate first knowledge; Perform utility verification on the first piece of knowledge; In response to the first knowledge passing the utility verification, the first knowledge is updated to the knowledge database; the knowledge database stores the multiple pieces of historical knowledge.
9. The method according to claim 8, wherein updating the first knowledge to the knowledge database comprises: If there is a semantic conflict between the first knowledge and the second knowledge in the multiple historical knowledge, the first knowledge and the second knowledge are input into the fourth model to generate the third knowledge; Perform utility verification on the aforementioned third knowledge; In response to the third knowledge passing the utility verification, the third knowledge is updated to the knowledge database.
10. An electronic device, comprising: Memory and at least one processor; wherein, The memory stores a computer program that can run on a processor; when the processor executes the program, it is used to: Based on the target task information input by the user, target reference information is determined from multiple historical cases and multiple historical knowledge sources; the target task information includes instruction information and time-series data to be processed; the historical cases represent task execution instances of historical tasks related to the historical time-series data; the historical knowledge represents task execution experience related to the historical time-series data; the target reference information includes at least one of target historical cases and target historical knowledge. A target execution plan is generated based on the instruction information, the timing data to be processed, and the target reference information. Execute the target execution plan to obtain the task execution result corresponding to the target task information.