Task process repairing method and device, equipment, medium and product

By leveraging the natural language processing capabilities of the language model in the process engine, errors in the task process are automatically detected and repaired, and errors in the task process are solved, and the problem of insufficient correctness and stability of the task process is achieved efficient automatic repair.

CN120086054AActive Publication Date: 2025-06-03BEIJING FEISHU TECH CO LTD

Patent Information

Application Number
CN202510581835.9
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-05-07
Publication Date
2025-06-03
Estimated Expiration
2045-05-07

AI Technical Summary

Technical Problem

The task process has insufficient correctness and stability in the process engine, resulting in low repair efficiency. The existing technology mainly relies on user manual operations.

Method used

By presenting the task process in the process configuration page and using the natural language processing capabilities of the language model, errors in the task process are automatically detected and repaired, and a fixed task process is generated.

Benefits of technology

It automatically repairs errors in the task process, reduces the workload of manual operations by users, and improves the correctness and stability of the task process.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120086054A_ABST
    Figure CN120086054A_ABST
Patent Text Reader

Abstract

The invention provides a task process repairing method, device and equipment, a medium and a product, and the method can be applied to a process engine, such as a process engine in a low-code platform. The method comprises the steps of presenting a first task flow in a flow configuration page; in response to a test operation for the first task process, presenting a test result of the first task process; and in response to the test result representing that the first process node in the first task process generates an execution error, repairing the first process node in the first task process, and generating a second task process. In the method, the natural language processing capability of the language model is utilized to carry out targeted repair on the process node with the execution error, so that the error existing in the task process is automatically repaired, the correctness and the stability of the task process are improved, and the task process is ensured to normally execute the business task.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the field of computer technology, and in particular, to a method, apparatus, electronic device, computer-readable storage medium, and computer program product for repairing a task process. Background Art

[0002] With the continuous development of computer technology, process engines have emerged. A process engine generally refers to a system used to define, execute, and manage task processes (also known as workflows). For example, a process engine can be deployed in a low-code platform and provided as a functional module in the low-code platform to offer services related to task processes. Users can orchestrate process nodes and the execution order between process nodes in the process engine. In this way, the process engine can process process nodes in sequence according to the execution order of the process nodes and advance the task process.

[0003] However, task processes often have deficiencies in correctness and stability. How to efficiently repair task processes has become an urgent problem to be solved. Summary of the Invention

[0004] This application provides a method for repairing a task process. This method can reduce the workload of manual operations by users and achieve automatic repair of errors existing in the task process. This application also provides a corresponding apparatus, electronic device, computer-readable storage medium, and computer program product for the above method.

[0005] In a first aspect, this application provides a method for repairing a task process, which is applied to a process engine. The method includes: Present a first task process on a process configuration page; In response to a test operation on the first task process, present the test result of the first task process; wherein, the test result is used to indicate whether each process node in the first task process has an execution error, and the error reason of the process node with an execution error; In response to the test result indicating that a first process node in the first task process has an execution error, repair the first process node in the first task process to generate a second task process. The second task process includes a second process node obtained by repairing the first process node. The second process node does not have an execution error, and the second process node is different from the first process node in at least one of the following: node parameters or execution logic; The second task process is generated through the following steps: Generate a first prompt; wherein, the first prompt includes: the first task process described in a domain-specific language, the test result of the first task process, and a prompt message for indicating the repair of the first task process; Send the first prompt word to the first language model and receive a second task process described in a domain-specific language returned by the first language model; Generate the second task process according to the second task process described in the domain-specific language.

[0006] In a second aspect, the present application provides a task process repair device, which includes: A first presentation module, configured to present a first task process on a process configuration page; A second presentation module, configured to present a test result of the first task process in response to a test operation on the first task process; wherein, the test result is used to characterize whether execution errors occur in each process node of the first task process, and the error reasons of the process nodes where execution errors occur; A generation module, configured to repair a first process node in the first task process to generate a second task process in response to the test result indicating that an execution error occurs in the first process node of the first task process, where the second task process includes a second process node obtained by repairing the first process node, and the second process node is different from the first process node in at least one of the following: node parameters or execution logic; Specifically, the generation module is configured to generate a first prompt word; wherein, the first prompt word includes: the first task process described in a domain-specific language, the test result of the first task process, and prompt information for indicating repairing the first task process; send the first prompt word to the first language model, receive a second task process described in the domain-specific language returned by the first language model; and generate the second task process according to the second task process described in the domain-specific language.

[0007] In a third aspect, the present application provides an electronic device, which includes a processor and a memory. The processor and the memory communicate with each other. The processor is configured to execute instructions stored in the memory so that the electronic device executes the task process repair method in the first aspect or any implementation manner of the first aspect.

[0008] In a fourth aspect, the present application provides a computer-readable storage medium, in which instructions are stored, and the instructions instruct an electronic device to execute the task process repair method in the above first aspect or any implementation manner of the first aspect.

[0009] In a fifth aspect, the present application provides a computer program product containing instructions, which, when running on an electronic device, causes the electronic device to execute the task process repair method in the above first aspect or any implementation manner of the first aspect.

[0010] Based on the implementation manners provided in the above aspects of the present application, further combinations can be made to provide more implementation manners.

[0011] As can be seen from the above technical solutions, the present application has the following advantages: The present application provides a method for repairing a task process. The method is applied to a process engine. In a process configuration page, a first task process is presented. In response to a test operation on the first task process, a test result of the first task process is presented. The test result is used to characterize whether execution errors occur in each process node in the first task process, and the error reasons of the process nodes where execution errors occur. In response to the test result indicating that an execution error occurs in a first process node in the first task process, the first process node in the first task process is repaired to generate a second task process. The second task process includes a second process node obtained by repairing the first process node. The second process node is different from the first process node in at least one of the following: node parameters or execution logic. The second task process is generated through the following steps: generating a first prompt word, where the first prompt word includes: the first task process described in a domain-specific language, the test result of the first task process, and a prompt message for indicating repairing the first task process; sending the first prompt word to a first language model; receiving a second task process described in the domain-specific language returned by the first language model; and generating the second task process according to the second task process described in the domain-specific language.

[0012] In this method, in a process engine, such as a process engine in a low-code platform, by testing the original task process, the process nodes with execution errors in the original task process are found, and by using the natural language processing ability of the language model, the process nodes with execution errors are repaired in a targeted manner. By modifying the node parameters or execution logic, a task process without execution errors after repair is obtained, realizing automatic repair of the errors existing in the task process, improving the correctness and stability of the task process, and ensuring that the task process normally executes business tasks. Description of the Drawings

[0013] To more clearly illustrate the technical solutions of the embodiments of the present application, the drawings required for use in the embodiments will be briefly introduced below.

[0014] Figure 1 A flowchart of a method for repairing a task process provided by an embodiment of the present application; Figure 2 A schematic diagram of a first task process provided by an embodiment of the present application; Figures 3A to 3D A schematic diagram of a process configuration page provided by an embodiment of the present application; Figure 4Structural schematic diagram of a task process repair device provided by an embodiment of the present application; Figure 5 Structural schematic diagram of an electronic device provided by an embodiment of the present application. Detailed implementation manners

[0015] The terms "first" and "second" in the embodiments of the present application are only used for descriptive purposes, and cannot be construed as indicating or implying relative importance or implicitly specifying the quantity of the indicated technical features. Thus, features defined with "first" and "second" may explicitly or implicitly include one or more of such features.

[0016] First, some technical terms and application scenarios involved in the embodiments of the present application are introduced.

[0017] A process engine, which can also be called a process orchestration engine or a process orchestration tool, is usually used to define, execute, and manage task processes. The process engine usually supports visual operations. Users (such as process orchestration personnel) can arrange process nodes and generate task processes through operations such as dragging and connecting on the process orchestration page.

[0018] The process engine is usually deployed in an application platform as a service (aPaaS) platform and exists as a service component of the aPaaS platform. Among them, the aPaaS platform, which can also be called a low-code platform, is a cloud service platform that simplifies the deployment and management of application programs by providing extensible application infrastructure services. As part of the aPaaS platform, the process engine enables the aPaaS platform to support complex business process management and automation.

[0019] A task process, which can also be called a workflow or a process template, can be understood as an execution sequence composed of a series of process nodes. The dependency relationship between process nodes can represent the execution order of process nodes. Among them, a process node can be understood as a module used to execute a specific task, thereby implementing a specific function or providing a specific ability.

[0020] Task processes are usually used to execute business tasks. For example, task processes can be used to execute business tasks such as onboarding approval, store inspections, and product requirement status management. With the complexity of business tasks, the number of process nodes and the dependency relationships between process nodes in task processes also become complex. Complex task processes are prone to defects in correctness and stability. In related technologies, repairing defects in task processes is usually manually completed by users (such as process orchestration personnel). Although the above method can improve the correctness of task processes to a certain extent, the repair efficiency is low.

[0021] In view of this, the present application provides a task process repair method, which is applied to a process engine. In a process configuration page, a first task process is presented. In response to a test operation on the first task process, a test result of the first task process is presented. The test result is used to characterize whether execution errors occur in each process node in the first task process, and the error reasons of the process nodes with execution errors. In response to the test result indicating that an execution error occurs in a first process node in the first task process, the first process node in the first task process is repaired to generate a second task process. The second task process includes a second process node obtained by repairing the first process node. The second process node is different from the first process node in at least one of the following: node parameters or execution logic. The second task process is generated through the following steps: generating a first prompt, where the first prompt includes: the first task process described in a domain-specific language, the test result of the first task process, and a prompt message for indicating repairing the first task process; sending the first prompt to a first language model; receiving the second task process described in the domain-specific language returned by the first language model; and generating the second task process according to the second task process described in the domain-specific language.

[0022] In this method, in a process engine, such as the process engine in a low-code platform, by testing the original task process, the process nodes with execution errors in the original task process are found. Utilizing the natural language processing ability of the language model, the process nodes with execution errors are repaired in a targeted manner. By modifying the node parameters or execution logic, a task process without execution errors after repair is obtained, realizing the automatic repair of the errors existing in the task process, improving the correctness and stability of the task process, and ensuring that the task process can normally execute business tasks.

[0023] To facilitate understanding of the technical solutions provided by the embodiments of the present application, the following will be described with reference to the accompanying drawings. Refer to Figure 1 the flowchart of a task process repair method shown in the figure. The method specifically includes the following steps: S101: In a process configuration page, present a first task process.

[0024] The process configuration page, which can also be called a process configuration canvas, can be understood as a page provided by the process engine for configuring the task process. That is to say, a user (such as a process orchestrator) can arrange the process nodes and the execution order between the process nodes in the task process in the process configuration page. In addition, the user can also configure node parameters for each process node in the process configuration page.

[0025] In the embodiments of the present application, the first task process can be understood as a task process with testing or repair requirements. For example, the first task process can be any task process with process execution logic.

[0026] The embodiments of the present application support determining the first task process with testing or repair requirements in different ways. In some embodiments, in response to a selection operation for the first task process on the process configuration page, the first task process is presented. Among them, the selection operation is used to select from the configured task processes.

[0027] That is to say, since the task processes that have been completed with configuration are usually stored in the process engine, a user (such as a process orchestrator) can select the task process that needs to be tested or repaired from the configured task processes, and determine the first task process based on the selection operation triggered by the user.

[0028] In other embodiments, in response to a task process configuration operation triggered on the process configuration page, the first task process is presented. Among them, the task process configuration operation is used to configure the first task process.

[0029] That is to say, a user (such as a process orchestrator) can configure the task process on the process configuration page, such as orchestrating the process nodes and the execution order between the process nodes. Based on the task process configuration operation triggered by the user, the currently configured task process is determined as the first task process.

[0030] In still other embodiments, in response to a task process generation operation triggered on the process configuration page, the first task process is presented. Among them, the task process generation operation is associated with the natural language text used to describe the first task process, and the task process generation operation is used to trigger the first language model to generate the first task process based on the natural language text used to describe the first task process.

[0031] That is to say, a user (such as a process orchestrator) can describe the task process to be configured in the form of inputting natural language text on the process configuration page, such as inputting natural language text describing the business task to be achieved by the task process, etc. Based on the task process generation operation triggered by the user, the first language model is called, and the natural language processing ability of the first language model is used to automatically generate a task process that meets the user's needs, and the task process automatically generated by the first language model is determined as the first task process.

[0032] Among them, the first language model can be understood as a natural language processing model based on deep learning technology. The language model usually has the ability to understand, process and generate natural language, and can process different types of natural language tasks.

[0033] The embodiments of the present application do not limit the way for a user to input a natural language text for describing a first task process. For example, the user can directly input a natural language text for describing the first task process in a text input manner. Or, for another example, the user can also input a voice for describing the first task process in a voice input manner, and through voice recognition and text conversion, obtain a natural language text for describing the first task process.

[0034] In some possible implementation manners, a digital assistant is deployed in the process engine, and the user inputs a natural language text by interacting with the digital assistant. Among them, the digital assistant can be understood as a module for providing human-computer dialogue services. That is to say, the user inputs a natural language text for describing the first task process through the digital assistant, and the digital assistant invokes a first language model to enable the first language model to generate the first task process, realizing the automatic generation of the task process.

[0035] The embodiments of the present application do not limit the presentation manner of presenting the first task process. For example, in a process configuration page, the first task process is presented in the form of a topology diagram. In other words, the process nodes of the first task process form the respective nodes of the topology diagram, and the execution order between the process nodes of the first task process indicates the connection relationship between the respective nodes in the topology diagram.

[0036] S102: Present the test result of the first task process in response to a test operation on the first task process.

[0037] Among them, the test operation on the first task process can be understood as an operation for triggering the test of the executability of the first task process. In other words, when the user has a need to test or repair the first task process, by triggering the test operation on the first task process, the process of testing the first task process and repairing the first task process is started.

[0038] The embodiments of the present application support the user to trigger the test operation on the first task process in different ways. In some embodiments, the test result of the first task process is presented in response to a trigger operation on a test control. Among them, the test control is used to trigger the test of the first task process.

[0039] That is to say, the process configuration page provides a test control. By the user triggering the test control, such as clicking the test control, the process of testing the first task process and repairing the first task process is started, realizing fast and convenient repair of the task process.

[0040] In some other embodiments, the test result of the first task process is presented in response to an interaction operation with the digital assistant. Among them, the interaction operation with the digital assistant is associated with a prompt message for testing the first task process.

[0041] That is to say, the process engine deploys a digital assistant. The user inputs natural language text for testing the first task process by interacting with the digital assistant. For example, the user inputs "Please help me test this task process". In this way, through the conversation between the user and the digital assistant, the process of testing the first task process and fixing the first task process is automatically started.

[0042] In some possible implementation manners, in response to a triggering operation on the digital assistant, a digital assistant interaction interface is presented. In response to receiving a triggering operation for testing the first task process in the digital assistant interaction interface, according to the triggering operation, a prompt message for testing the first task process is generated, and the test result of the first task process is presented on the process configuration page.

[0043] Among them, the digital assistant interaction interface can be understood as an interface for human-computer conversation. In other words, the user can interact with the digital assistant through the digital assistant interaction interface, and both the user's input text and the digital assistant's generated text can be presented in the digital assistant interaction interface. The digital assistant interaction interface can have different display forms. For example, the digital assistant interaction interface can be a floating window of the digital assistant.

[0044] The triggering operation on the digital assistant can be understood as an operation for starting the interaction with the digital assistant. For example, the triggering operation on the digital assistant can be an operation for invoking the digital assistant interaction interface. Through the triggering operation on the digital assistant, the digital assistant interaction interface is presented so that the user can interact with the digital assistant.

[0045] The triggering operation for testing the first task process can be understood as an operation for testing the first task process through the interaction with the digital assistant. For example, the triggering operation for testing the first task process can be that the user sends natural language text for testing the first task process in the digital assistant interaction interface. Similarly, the embodiments of the present application do not limit the manner in which the user inputs natural language text for testing the first task process. For example, the user can directly input natural language text for testing the first task process in the digital assistant interaction interface by means of text input. Another example is that the user can also input voice for testing the first task process in the digital assistant interaction interface by means of voice input, and through voice recognition and text conversion, obtain natural language text for testing the first task process.

[0046] Through the digital assistant interaction interface provided by the digital assistant, during the process of the user using the process engine, the user can describe the requirements related to the task process in the digital assistant interaction interface at any time by inputting natural language content, and use the digital assistant to assist the user in using the process engine conveniently and quickly.

[0047] The test result of the first task process can be understood as the result obtained after testing the first task process. The test result can be used to characterize whether execution errors occur at each process node in the first task process, and the error reasons of the process nodes where execution errors occur.

[0048] In other words, by testing the first task process, it is judged whether the first task process can correctly execute the business task. If the first task process can correctly execute the business task, no execution error occurs at each process node in the first task process. If the first task process cannot correctly execute the business task, the process node where the execution error occurs is located in the first task process, and the error reason for the execution error is analyzed.

[0049] In the embodiments of the present application, the first task process is tested using test cases. In some embodiments, the test cases can be manually configured by the user. In other embodiments, the test cases can also be automatically generated by a language model.

[0050] The process of automatically generating test cases by the language model and then testing the first task process will be described below.

[0051] Specifically, when implemented, the first test cases are generated by the first language model. The first language model implements the above process of generating test cases based on prompt engineering technology. Among them, a prompt (prompt) can be used to guide the language model to perform a specific output in a generative task (such as a text generation task, a question-and-answer task, a dialogue task). By configuring the prompt, the language model is helped to understand the background and requirements of the task, so that the language model can handle different types of natural language processing tasks without retraining the language model, increasing the scalability and flexibility of the language model.

[0052] Specifically, a second prompt is generated, the second prompt is sent to the first language model, and the first test cases returned by the first language model are received. Among them, the second prompt includes: the first task process described in a domain-specific language (DSL) and prompt information for instructing the generation of test cases.

[0053] DSL is a computer programming language used to solve problems in a specific domain. In the embodiments of the present application, by describing the task process in task process DSL, the syntax and semantics are closer to the concepts and requirements of the task process domain.

[0054] In some embodiments, in order for the first language model to have the ability to analyze the first task flow described in DSL, the second prompt may further include the grammar knowledge of DSL. In this way, based on the prompting ability of the second prompt, the first language model understands the grammar of DSL, and then analyzes the first task flow based on the grammar of DSL in order to generate test cases for testing the first task flow.

[0055] For example, the grammar knowledge of DSL may be partially as follows: "Use DSL in yaml format to describe the workflow. In DSL, the nodes in the workflow are described through the nodes array, and the edge relationships between nodes are described through the edges array. The id field of the node serves as the identifier of the node, the name field of the node serves as the name of the node, and the type field of the node indicates the type of the node. The definition field of the node contains the following fields: inputs, outputs, info, blocks, code field, language field, condition, data field. In each edge relationship, there must be sourceNodeID and targetNodeID, indicating the starting node and the pointing node of the edge. The definition.inputs parameter of the downstream node can reference the definition.outputs variable of the upstream node, and the reference relationship is defined through the data field" The first task flow described in DSL may be partially as follows: "edges: - sourceNodeID: start1 targetNodeID: llm1 - sourceNodeID: llm1 targetNodeID: end1 nodes: - definition: info: description: Receive the text input by the user outputs: - name: query required: true type: string id: start1 name: Start type: start - data: modelType: "123456" modleName: Tool Call prompt: ref(start1.outputs.query) systemPrompt: xxxxxx definition: info: description: Generate 5 relevant queries based on the text of the start node inputs: - description: User prompt for generating content name: prompt type: string - description: System prompt for guiding content generation name: systemPrompt type: string - description: Type id of the model used name: modelType outputs: - name: output type: string” In this way, by configuring the above information in the second prompt, the first language model can intuitively understand the first task process based on the prompting ability of the second prompt, accurately analyze the first task process, and generate the first test case for testing the first task process.

[0056] In the embodiment of the present application, the first test case includes: the input parameters of the start node and the correct output result of the end node in the first task process. That is to say, the first language model generates the initial input of the first task process (i.e., the input parameters of the start node) by analyzing the overall structure and execution logic of the first task process, and generates the expected output of the first task process (i.e., the correct output result of the end node) when the input parameters of the start node are input into the first task process.

[0057] Next, execute the first task process using the first test case to obtain the test result of the first task process. For example, by calling the execution interface of the process engine, execute the first task process with the input parameters of the start node in the first test case, and combine the execution situation of the first task process and the correct output result of the end node in the first test case to determine whether there are execution errors in each process node of the first task process, and for the process nodes with execution errors, determine the error cause of the execution error, and then determine the test result of the first task process.

[0058] In some embodiments, the test result of the first task process can be manually analyzed by the user, and in other embodiments, the test result of the first task process can also be automatically generated by the language model.

[0059] The process of automatically generating the test result of the first task process by the language model will be described below.

[0060] First, execute the first task process using the first test case to obtain the execution data of the first task process. Among them, the execution data includes at least one of the following: the execution path of the first task process, the execution status of each process node in the first task process, and the output result of the first task process.

[0061] The execution path of the first task process can be understood as the path composed of the process nodes executed during the execution of the first task process. For example, when there are branch nodes in the first task process, only one process branch can be executed in one execution process of the first task process. In this case, the execution path of the first task process can include the process nodes in the executed process branch. The execution status of each process node in the first task process can be used to represent whether each process node is successfully executed during the execution of the first task process. For example, when there is a defect (bug) in a certain process node in the first task process, an error will be reported when the process node is executed. In this case, the execution status of this process node can represent execution failure. The output result of the first task process can be understood as the final output after the first task process is executed, for example, the output result of the end node of the first task process.

[0062] Next, generate a third prompt, send the third prompt to the first language model, and receive the test result of the first task process returned by the first language model. Among them, the third prompt includes: the first task process described in DSL, the first test case, the execution data of the first task process, and the prompt information for indicating to determine the test result based on the execution data of the first task process.

[0063] Since the above information is included in the third prompt, the first language model can, based on the prompting ability of the third prompt and in combination with the overall structure of the first task process, determine which process nodes in the first task process generate execution errors in the execution data of the first task process on the premise that the input parameters of the start node in the first test case execute the first task process, locate the process nodes where the execution errors occur, analyze the error causes of the execution errors, and generate test cases for the first task process.

[0064] In some possible implementation manners, the error causes of the process nodes where execution errors occur may include at least one of the following: there are syntax errors in the node parameters of the process nodes where execution errors occur, there are runtime errors in the node parameters of the process nodes where execution errors occur, or there are execution logic errors in the process nodes where execution errors occur.

[0065] Among them, a syntax error in the node parameters can be understood as a configuration error in the node parameters that can be identified without executing the process node. For example, the syntax error can be that a reference parameter does not exist, an expression error, a dependency error, a node naming error, a duplicate node naming, etc. A runtime error in the node parameters can be understood as a configuration error in the node parameters that occurs during the execution of the process node. For example, the runtime error can be an array subscript error, the data is empty, the data does not exist, etc. An execution logic error means that due to a defect in the execution logic of the process node, the corresponding process node function fails to be correctly executed. For example, for a process node used for addition, when the input parameters of the process node are 1 and 1, the process node should output 2, but actually outputs 3. In this case, the process node has an execution logic error.

[0066] In this way, in the test result of the first task process, analyzing the specific error causes of the process nodes where execution errors occur facilitates subsequent targeted repair of the first task process.

[0067] S103: In response to the test result indicating that an execution error occurs in the first process node in the first task process, repair the first process node in the first task process to generate a second task process.

[0068] In the embodiments of the present application, the second task process can be understood as the task process obtained after repairing the first task process. The second task process includes a second process node obtained by repairing the first process node. That is, the second task process is the task process after updating the first process node in the first task process to the second process node. The second process node and the first process node are different in at least one of the following: node parameters or execution logic.

[0069] That is to say, due to the execution error in the first process node of the first task process, the first process node is repaired by modifying the node parameters or execution logic of the first process node, and the first process node with the execution error is repaired into the second process node without the execution error. Furthermore, the repaired second task process is formed.

[0070] In the embodiment of the present application, the first task process is repaired by using the first language model to generate the second task process. Specifically, when implementing, a first prompt word is generated, the first prompt word is sent to the first language model, the second task process described in DSL returned by the first language model is received, and the second task process is generated according to the second task process described in DSL.

[0071] Among them, the first prompt word includes: the first task process described in DSL, the test result of the first task process, and the prompt information for indicating the repair of the first task process.

[0072] Similarly, in order to enable the first language model to have the ability to analyze the first task process described in DSL, the first prompt word may further include the grammar knowledge of DSL.

[0073] In this way, by configuring the above information in the first prompt word, the first language model can, based on the prompting ability of the first prompt word, combine the overall structure of the first task process and the error cause of the execution error, modify the first process node representing the execution error in the test result, repair the running defect existing in the first task process, and generate the repaired second task process, realizing the automatic repair of the first task process.

[0074] In some embodiments, the first task process includes multiple process branches, and the first test case includes multiple test cases. Among the execution data corresponding to the multiple test cases, the set of execution paths of the first task process covers multiple process branches of the first task process.

[0075] That is to say, considering that there may be branch nodes in the first task process, if the first task process is executed using the generated test cases, and the execution paths in the execution data can only cover some process branches, then the remaining process branches cannot be tested, and a comprehensive test result of the first task process cannot be obtained. Therefore, in the embodiment of the present application, during the process of testing the first task process by generating multiple test cases, the set of execution paths corresponding to the multiple test cases can cover all the process branches of the first task process, improving the coverage rate of the test cases and realizing comprehensive testing.

[0076] In some possible implementation manners, adding a new test case can be implemented as follows: The first task process has a first process branch and a second process branch, and the execution path of the first task process corresponding to the first test case includes the first process branch and does not include the second process branch. In this case, a fourth prompt is generated, the fourth prompt is sent to the first language model, and a second test case returned by the first language model is received. The fourth prompt includes: the first task process described in DSL and prompt information for indicating generating a test case passing through the second process branch.

[0077] See Figure 2 As shown in the schematic diagram of a first task process, the first task process includes two process branches. The first process branch consists of process nodes A, B, C1, C2, C3, and E, and the second process branch consists of process nodes A, B, D1, D2, and E. After executing the first task process using the first test case, the execution path is the first process branch. In this case, to improve the coverage rate, by configuring in the fourth prompt the prompt information for indicating generating a test case passing through the second process branch, the first language model is enabled to generate a second test case that can cover the second process branch.

[0078] In some possible implementation manners, to enable the first language model to efficiently generate the second test case, the prompt information for indicating generating a test case passing through the second process branch in the fourth prompt may include: prompt information for indicating generating a test case passing through the second process branch in a backtracking manner. In this way, the first language model can start from the process node after the branch node in the second process branch (i.e., the first process node where the first process branch and the second process branch are different), backtrack to the start node of the first task process, and redesign the input parameters of the start node, so that the second test case can pass through the second process node, enrich the test cases, and make the test results more comprehensively cover the first task process.

[0079] In some embodiments, confirmation can also be made to the user before presenting the second task process. Specifically, the first prompt further includes: prompt information for indicating generating a repair solution for the first task process, and the first language model also returns a repair solution for the first task process. In response to the test result indicating an execution error occurs at the first process node in the first task process, the repair solution for the first task process is presented. In response to the confirmation operation for the repair solution for the first task process, the first process node in the first task process is repaired according to the repair solution for the first task process, and the second task process is generated.

[0080] Among them, the repair solution for the first task process includes at least one of the following described in natural language: the error reason of the first process node and the repair method of repairing the first process node to the second process node.

[0081] For example, when the user triggers a test operation for the first task process through an interaction operation with the digital assistant, the repair solution for the first task process can be presented in the digital assistant interaction interface, and a control for providing feedback on the repair solution for the first task process is provided. The user can trigger a confirmation operation for the repair solution for the first task process by triggering the control.

[0082] That is to say, by configuring prompt information for indicating the generation of the repair solution for the first task process in the first prompt word, the first language model can generate a repair solution for repairing the first task process to the second task process described in natural language. In this way, by presenting the repair solution, it is confirmed with the user whether to repair the first task process according to the repair solution. After the user confirms the repair solution, the first task process is then repaired to the second task process, avoiding the repair of the first task process not conforming to the user's needs.

[0083] In this method, in the process engine, such as the process engine in a low-code platform, by testing the original task process, the process nodes with execution errors in the original task process are found. Using the natural language processing ability of the language model, the process nodes with execution errors are repaired in a targeted manner. By modifying the node parameters or execution logic, a task process without execution errors after repair is obtained, realizing the automatic repair of the errors existing in the task process, improving the correctness and stability of the task process, and ensuring that the task process normally executes business tasks.

[0084] The above has introduced the task process repair method provided in this application. The following will be described in combination with specific page diagrams.

[0085] See Figures 3A to 3D A schematic diagram of a process configuration page provided, in Figure 3A In it, the process configuration page 30 presents the first task process 32. At the same time, the process configuration page 30 also presents a test control 31 and a control 33 for triggering the digital assistant. The user can trigger a test operation for the first task process by triggering the test control 31, or the user can also trigger a test operation for the first task process by interacting with the digital assistant.

[0086] In Figure 3BIn response to a triggering operation on the control 33 for triggering the digital assistant, a digital assistant interaction interface 34 is presented. The digital assistant interaction interface 34 provides an input box, and the user can input natural language text for testing the first task process in the input box provided by the digital assistant interaction interface 34. After the user sends the natural language text for testing the first task process, the digital assistant interaction interface 34 presents the natural language text 341 for testing the first task process, such as "testing the task process".

[0087] In Figure 3C the digital assistant calls the first language model to generate the first test case, executes the first task process using the first test case, generates the test result of the first task process, and presents the test result 35 of the first task process on the process configuration page 30, such as "the node parameters of the node 'process node B' are incomplete".

[0088] In Figure 3D the digital assistant interaction interface presents a repair solution 342 for the first task process, such as "a task process execution error is detected, parameter A of 'process node B' is missing, do you want to complete it for you?". At the same time, a control 343 for providing feedback on the repair solution for the first task process is also presented in the digital assistant interaction interface, such as an adoption control and a rejection control. The user can trigger the confirmation operation for the repair solution of the first task process by triggering the adoption control, and then update the first task process to the second task process. In this way, through the interaction with the digital assistant, the automatic testing and repair of the task process are realized.

[0089] As described above in conjunction with Figure 1 FIG. 3, the task process repair method provided by the embodiments of the present application has been introduced in detail. Next, the devices and equipment provided by the embodiments of the present application will be introduced in conjunction with the accompanying drawings.

[0090] See Figure 4 the structural schematic diagram of the task process repair device shown, which is deployed in the process engine. The device 40 includes: A first presentation module 401 for presenting the first task process on the process configuration page; A second presentation module 402 for presenting the test result of the first task process in response to a test operation on the first task process; wherein, the test result is used to characterize whether execution errors occur in each process node of the first task process, and the error reasons of the process nodes where execution errors occur; A generation module 403, configured to, in response to the test result indicating an execution error occurred at a first process node in the first task process, repair the first process node in the first task process to generate a second task process, where the second task process includes a second process node obtained by repairing the first process node, and the second process node is different from the first process node in at least one of the following: node parameters or execution logic; Specifically, the generation module 403 is configured to generate a first prompt word, where the first prompt word includes: the first task process described in a domain-specific language, the test result of the first task process, and a prompt message for indicating repairing the first task process; send the first prompt word to a first language model, and receive a second task process described in the domain-specific language returned by the first language model; and generate the second task process according to the second task process described in the domain-specific language.

[0091] In some possible implementation manners, the first presentation module 401 is specifically configured to: In response to a selection operation on the first task process in a process configuration page, present the first task process, where the selection operation is used to select from the configured task processes; or, In response to a task process configuration operation triggered in the process configuration page, present the first task process, where the task process configuration operation is used to configure the first task process; or, In response to a task process generation operation triggered in the process configuration page, present the first task process, where the task process generation operation is associated with a natural language text for describing the first task process, and the task process generation operation is used to trigger the first language model to generate the first task process based on the natural language text for describing the first task process.

[0092] In some possible implementation manners, the second presentation module 402 is specifically configured to: In response to a trigger operation on a test control, present the test result of the first task process, where the test control is used to trigger testing of the first task process; or, In response to an interaction operation with a digital assistant, present the test result of the first task process, where the interaction operation with the digital assistant is associated with a prompt message for testing the first task process.

[0093] In some possible implementation manners, the second presentation module 402 is specifically configured to: In response to a trigger operation on the digital assistant, present a digital assistant interaction interface; In response to receiving a trigger operation for testing the first task process in the digital assistant interaction interface, according to the trigger operation, generate a prompt message for testing the first task process, and present the test result of the first task process in the process configuration page.

[0094] In some possible implementation manners, the first prompt word further includes: a prompt message for instructing to generate a repair solution for the first task process, and the first language model also returns the repair solution for the first task process; specifically, the generating module 403 is configured to: In response to the test result indicating that an execution error occurs in the first process node of the first task process, present the repair solution for the first task process; wherein, the repair solution for the first task process includes at least one of the following described in natural language: the error reason of the first process node and the repair method for repairing the first process node to the second process node; In response to a confirmation operation for the repair solution of the first task process, repair the first process node in the first task process according to the repair solution of the first task process, and generate the second task process.

[0095] In some possible implementation manners, the generating module 403 is further configured to: Generate a second prompt word; wherein, the second prompt word includes: the first task process described in a domain-specific language and a prompt message for instructing to generate test cases; Send the second prompt word to the first language model, and receive a first test case returned by the first language model; wherein, the first test case includes: the input parameters of the start node in the first task process and the correct output result of the end node; Execute the first task process by using the first test case, and obtain the test result of the first task process.

[0096] In some possible implementation manners, the generating module 403 is specifically configured to: Execute the first task process by using the first test case, and obtain the execution data of the first task process; wherein, the execution data includes at least one of the following: the execution path of the first task process, the execution status of each process node in the first task process, and the output result of the first task process; Generate a third prompt word; wherein, the third prompt word includes: the first task process described in a domain-specific language, the first test case, the execution data of the first task process, and a prompt message for instructing to determine the test result based on the execution data of the first task process; Send the third prompt word to the first language model, and receive the test result of the first task process returned by the first language model.

[0097] In some possible implementation manners, the first task process includes multiple process branches, and the first test case includes multiple test cases; among the execution data corresponding to the multiple test cases, the set of execution paths of the first task process covers the multiple process branches of the first task process.

[0098] In some possible implementation manners, the error reasons for the process node that generates an execution error include at least one of the following: there is a syntax error in the node parameters of the process node that generates an execution error, there is a running error in the node parameters of the process node that generates an execution error, or there is an execution logic error in the process node that generates an execution error.

[0099] The task process repair device 40 according to the embodiment of the present application can correspond to executing the method described in the embodiment of the present application, and the above and other operations and / or functions of each module / unit of the task process repair device 40 are respectively for implementing Figure 1 the corresponding processes of the various methods in the illustrated embodiments, and for the sake of brevity, they will not be described in detail here.

[0100] The embodiment of the present application further provides an electronic device. This electronic device is specifically used to implement the functions of the task process repair device 40 in the Figure 4 illustrated embodiment.

[0101] Figure 5 A schematic structural diagram of an electronic device 500 is provided, as shown in Figure 5 the figure. The electronic device 500 includes a bus 501, a processor 502, a communication interface 503, and a memory 504. The processor 502, the memory 504, and the communication interface 503 communicate with each other through the bus 501.

[0102] The bus 501 may be a peripheral component interconnect (PCI) bus or an extended industry standard architecture (EISA) bus, etc. The bus can be divided into an address bus, a data bus, a control bus, etc. For the sake of convenience of representation, Figure 5 only a thick line is shown in the figure, but it does not mean that there is only one bus or one type of bus.

[0103] The processor 502 can be any one or more of processors such as a central processing unit (CPU), a graphics processing unit (GPU), a microprocessor (MP), or a digital signal processor (DSP).

[0104] The communication interface 503 is used for external communication. For example, the communication interface 503 can be used for communication with a terminal.

[0105] The memory 504 can include a volatile memory, such as a random access memory (RAM). The memory 504 can also include a non-volatile memory, such as a read-only memory (ROM), a flash memory, a hard disk drive (HDD), or a solid state drive (SSD).

[0106] Executable code is stored in the memory 504, and the processor 502 executes the executable code to perform the foregoing task flow repair method.

[0107] Specifically, in the case of implementing Figure 4 the illustrated embodiment, and Figure 4 when each module or unit of the task flow repair device 40 described in the embodiment is implemented by software, the software or program code required to execute the functions of each module / unit in Figure 4 can be partially or entirely stored in the memory 504. The processor 502 executes the program code corresponding to each unit stored in the memory 504 to perform the foregoing task flow repair method.

[0108] An embodiment of the present application also provides a computer-readable storage medium. The computer-readable storage medium can be any available medium that can be stored by a computing device or a data storage device such as a data center including one or more available media. The available medium can be a magnetic medium (such as a floppy disk, a hard disk, a magnetic tape), an optical medium (such as a DVD), or a semiconductor medium (such as a solid state drive), etc. The computer-readable storage medium includes instructions that instruct a computing device to execute the foregoing task flow repair method applied to the task flow repair device 40.

[0109] The embodiment of the present application further provides a computer program product, which includes one or more computer instructions. When the computer instructions are loaded and executed on a computing device, the process or function described in the embodiment of the present application is generated in whole or in part.

[0110] The computer instructions may be stored in a computer-readable storage medium or transmitted from one computer-readable storage medium to another computer-readable storage medium. For example, the computer instructions may be transmitted from one website, computer or data center to another website, computer or data center via wired (e.g., coaxial cable, optical fiber, digital subscriber line (DSL)) or wireless (e.g., infrared, wireless, microwave, etc.) means.

[0111] When the computer program product is executed by a computer, the computer executes any of the aforementioned task flow repair methods. The computer program product may be a software installation package, and when any of the aforementioned task flow repair methods is needed, the computer program product may be downloaded and executed on a computer.

[0112] The flow chart and block diagram in the accompanying drawings illustrate the possible architecture, function and operation of the system, method and computer program product according to each embodiment of the present application. In this regard, each square box in the flow chart or block diagram can represent a module, a program segment or a part of a code, and the module, the program segment or a part of the code contains one or more executable instructions for realizing the specified logical function. It should also be noted that in some implementations as replacements, the functions marked in the square box can also occur in a sequence different from that marked in the accompanying drawings. For example, two square boxes represented in succession 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 a specified function or operation, or can be implemented with a combination of dedicated hardware and computer instructions.

[0113] The units involved in the embodiments described in this application may be implemented by software or hardware, wherein the name of the unit / module does not, in some cases, constitute a limitation on the unit itself.

[0114] The functions described above in this document can be performed, at least in part, by one or more hardware logic components. By way of example, and without limitation, the types of hardware logic components that may be used include: Field Programmable Gate Arrays (FPGAs), Application Specific Integrated Circuits (ASICs), Application Specific Standard Products (ASSPs), Systems on Chip (SOCs), Complex Programmable Logic Devices (CPLDs), and the like.

[0115] In the context of the embodiments of this application, a machine-readable medium may be a tangible medium that can contain or store a program for use by or in connection with an instruction execution system, apparatus, or device. A machine-readable medium may be a machine-readable signal medium or a machine-readable storage medium. A machine-readable medium may include, but is not limited to, electronic, magnetic, optical, electromagnetic, infrared, or semiconductor systems, apparatus, or devices, or any suitable combination of the foregoing. More specific examples of a machine-readable storage medium would include an electrical connection based on one or more wires, a portable computer diskette, a hard disk, a Random Access Memory (RAM), a Read-Only Memory (ROM), an Erasable Programmable Read-Only Memory (EPROM or Flash Memory), an optical fiber, a portable Compact Disc Read-Only Memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the foregoing.

[0116] It should be noted that the various embodiments in this specification are described in a progressive manner, with each embodiment focusing on the differences from other embodiments. The same or similar parts among the various embodiments may be referred to each other. For the systems or apparatuses disclosed in the embodiments, since they correspond to the methods disclosed in the embodiments, the descriptions are relatively simple, and the relevant parts may be referred to the descriptions in the method section.

[0117] It should be understood that in this application, "at least one (item)" means one or more, and "a plurality" means two or more. "And / or" is used to describe the association relationship of associated objects and indicates that three relationships may exist. For example, "A and / or B" may mean: only A exists, only B exists, and both A and B exist simultaneously. Here, A and B may be singular or plural. The character " / " generally indicates that the associated objects before and after are in an "or" relationship. "At least one (one)" or similar expressions below refer to any combination of these items, including any combination of single items (ones) or plural items (ones). For example, at least one (one) of a, b, or c may mean: a, b, c, "a and b", "a and c", "b and c", or "a and b and c", where a, b, and c may be single or multiple.

[0118] It should also be noted that in this text, relational terms such as first and second are only used to distinguish one entity or operation from another entity or operation, and do not necessarily require or imply any actual relationship or order between these entities or operations. Moreover, the terms "comprising", "including" or any other variant thereof are intended to cover non-exclusive inclusion, such that a process, method, article or device comprising a series of elements includes not only those elements but also other elements not expressly listed, or elements inherent to such process, method, article or device. Without further limitation, an element defined by the statement "comprising an..." does not exclude the presence of additional identical elements in the process, method, article or device comprising the element.

[0119] The steps of the methods or algorithms described in connection with the embodiments disclosed herein may be implemented directly in hardware, in a software module executed by a processor, or in a combination thereof. The software module may be placed in a random access memory (RAM), memory, read-only memory (ROM), electrically programmable ROM, electrically erasable programmable ROM, registers, hard disk, removable disk, CD-ROM, or any other form of storage medium known in the art.

[0120] The foregoing description of the disclosed embodiments enables those skilled in the art to make or use the present application. Various modifications to these embodiments will be readily apparent to those skilled in the art, and the general principles defined herein may be implemented in other embodiments without departing from the spirit or scope of the present application. Thus, the present application is not intended to be limited to the embodiments shown herein but is to be accorded the widest scope consistent with the principles and novel features disclosed herein.

Claims

1. A task flow repair method, characterized in that: Applied to a process engine, the method comprises: On the process configuration page, the first task process is presented; In response to the test operation for the first task flow, presenting the test result of the first task flow; wherein the test result is used to indicate whether each process node in the first task flow generates an execution error, and the error cause of the process node generating the execution error; In response to the test result indicating that an execution error occurs in a first process node in the first task flow, the first process node in the first task flow is repaired to generate a second task flow, the second task flow includes a second process node repaired from the first process node, and the second process node is different from the first process node in at least one of the following: a node parameter or an execution logic; The second task flow is generated by the following steps: Generate a first prompt word; wherein the first prompt word includes: the first task flow described in a domain-specific language, a test result of the first task flow, and prompt information for instructing to repair the first task flow; Sending the first prompt word to a first language model, and receiving a second task flow described in a domain-specific language returned by the first language model; The second task flow is generated according to the second task flow described in the domain specific language.

2. The method according to claim 1, characterized in that In the process configuration page, the first task process is presented, including: In response to a selection operation on a first task flow in a flow configuration page, presenting the first task flow, wherein the selection operation is used to select a configured task flow; or, In response to a task flow configuration operation triggered in the flow configuration page, presenting the first task flow, wherein the task flow configuration operation is used to configure the first task flow; or, In response to a task process generation operation triggered in a process configuration page, the first task process is presented, the task process generation operation is associated with a natural language text used to describe the first task process, and the task process generation operation is used to trigger the first language model to generate the first task process based on the natural language text used to describe the first task process.

3. The method according to claim 1, characterized in that The presenting the test result of the first task flow in response to the test operation on the first task flow includes: In response to a trigger operation on a test control, presenting a test result of the first task flow, wherein the test control is used to trigger a test on the first task flow; or, In response to an interactive operation with a digital assistant, a test result of the first task flow is presented, and the interactive operation with the digital assistant is associated with prompt information for testing the first task flow.

4. The method according to claim 3, characterized in that The presenting, in response to the interactive operation with the digital assistant, a test result of the first task flow, comprises: In response to a trigger operation on the digital assistant, presenting a digital assistant interaction interface; In response to receiving a trigger operation for testing the first task process in the digital assistant interaction interface, prompt information for testing the first task process is generated according to the trigger operation, and the test result of the first task process is presented in the process configuration page.

5. The method according to claim 1, characterized in that The first prompt word further includes: prompt information for instructing to generate a repair solution for the first task flow, and the first language model further returns the repair solution for the first task flow; In response to the test result indicating that an execution error occurs at a first process node in the first task flow, repairing the first process node in the first task flow to generate a second task flow includes: In response to the test result indicating that an execution error occurs at a first process node in the first task process, a repair plan for the first task process is presented; wherein the repair plan for the first task process includes at least one of the following items described in natural language: a cause of the error at the first process node and a repair method for repairing the first process node to the second process node; In response to a confirmation operation on the repair solution for the first task flow, the first process node in the first task flow is repaired according to the repair solution for the first task flow to generate the second task flow.

6. The method according to claim 1, characterized in that The test results are generated by the following steps: Generate a second prompt word; wherein the second prompt word includes: the first task flow described in a domain-specific language and prompt information for indicating the generation of a test case; Sending the second prompt word to the first language model, and receiving a first test case returned by the first language model; wherein the first test case includes: input parameters of the start node and the correct output result of the end node in the first task flow; The first task flow is executed using the first test case to obtain a test result of the first task flow.

7. The method according to claim 6, characterized in that The using the first test case to execute the first task flow to obtain a test result of the first task flow includes: Executing the first task flow using the first test case to obtain execution data of the first task flow; wherein the execution data includes at least one of the following: an execution path of the first task flow, an execution status of each process node in the first task flow, and an output result of the first task flow; Generate a third prompt word; wherein the third prompt word includes: the first task flow, the first test case, the execution data of the first task flow described in a domain-specific language, and prompt information for indicating that a test result is determined based on the execution data of the first task flow; The third prompt word is sent to the first language model, and a test result of the first task flow returned by the first language model is received.

8. The method according to claim 7, characterized in that The first task flow includes multiple flow branches, and the first test case includes multiple test cases; in the execution data corresponding to the multiple test cases, the set of execution paths of the first task flow covers the multiple flow branches of the first task flow.

9. The method according to any one of claims 1 to 8, characterized in that: The error cause of the process node that generates the execution error includes at least one of the following: a syntax error exists in the node parameters of the process node that generates the execution error, a runtime error exists in the node parameters of the process node that generates the execution error, or an execution logic error exists in the process node that generates the execution error.

10. A task flow repair device, characterized in that: Deployed in the process engine, the device includes: A first presentation module, used to present a first task process in a process configuration page; A second presentation module, for presenting a test result of the first task flow in response to a test operation on the first task flow; wherein the test result is used to indicate whether each process node in the first task flow generates an execution error, and the error cause of the process node generating the execution error; A generating module, configured to repair the first process node in the first task flow in response to the test result indicating that an execution error occurs in the first process node in the first task flow, and generate a second task flow, wherein the second task flow includes a second process node repaired from the first process node, and the second process node is different from the first process node in at least one of the following: a node parameter or an execution logic; The generation module is specifically used to generate a first prompt word; wherein the first prompt word includes: the first task flow described in a domain-specific language, the test result of the first task flow and prompt information for indicating to repair the first task flow; send the first prompt word to a first language model, receive a second task flow described in a domain-specific language returned by the first language model; generate the second task flow according to the second task flow described in the domain-specific language.

11. An electronic device, characterized in that: The electronic device comprises a processor and a memory; The processor is configured to execute instructions stored in the memory, so that the electronic device performs the method according to any one of claims 1 to 9.

12. A computer-readable storage medium, characterized in that: The method comprises instructions, wherein the instructions instruct an electronic device to execute the method as claimed in any one of claims 1 to 9.

13. A computer program product, characterized in that The computer program product comprises computer readable instructions for implementing the method according to any one of claims 1 to 9.

Citation Information

Patent Citations

  • Process-based visualization test and visualization analogue simulation test system and method

    CN115794639A

  • Multi-mode program automatic repair method, system and equipment and storage medium

    CN116302998A

  • Application error repair method and device, equipment and medium

    CN117034255A

  • High-quality micro-benchmark performance test automatic generation method and device based on large language model

    CN119440992A

  • Pre-positioning algorithm for abnormal fault of data interface program based on AI

    CN119621581A

Cited By

  • Business processing method and device for large language model, medium and electronic equipment

    CN121542408A