Abnormal positioning method and device for workflow
Through the workflow exception positioning method, the problem of error diagnosis in traditional systems is solved, and the automation and efficiency of document processing is achieved, ensuring the stability and continuous improvement of workflow.
Patent Information
- Application Number
- CN202411161083.2
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-08-22
- Publication Date
- 2024-12-13
AI Technical Summary
Traditional automated document processing systems lack effective error diagnosis and correction mechanisms, which makes it difficult for users to quickly locate the problem, affecting processing efficiency and effectiveness.
Through the workflow exception positioning method, we obtain control collection and connection relationships, monitor workflow submission instructions, generate initial workflow, determine dependencies and execution paths, obtain text processing logs, extract exception-related parameters, generate optimization strategies and optimize workflows, Position and fix exceptions.
It realizes a high degree of automation of the document processing process, reduces labor and time costs, allows users to flexibly adjust the processing process, quickly process documents, and quickly locate problems through detailed log analysis to ensure the stable operation of the workflow.
Smart Images

Figure CN119130099A_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the fields of data processing and computer technology, and in particular to a method and device for locating anomalies in a workflow. Background Art
[0002] With the rapid development of information technology, document processing has become an indispensable part of the daily work of enterprises and individuals. Traditional document processing methods mainly rely on manual operations, which is not only inefficient but also prone to errors, especially when dealing with large-scale data sets or complex document content. In order to solve the above problems, automated document processing technology has emerged. This technology can realize the automatic organization, editing and processing of documents by using advanced computer algorithms and software tools, greatly improving work efficiency and document quality.
[0003] However, traditional automated document processing technology systems often lack effective error diagnosis and correction mechanisms, making it difficult for users to quickly locate problems, thus affecting overall processing efficiency and effectiveness. Summary of the invention
[0004] The present disclosure provides a workflow exception location method and device thereof, so as to at least solve the problem in the related art that the traditional automated workflow system often lacks an effective error diagnosis and correction mechanism, making it difficult for users to quickly locate the problem.
[0005] The first aspect of the present application provides a method for locating an exception in a workflow, comprising: obtaining a control set selected from a candidate control library, the control set including one or more target controls, and obtaining control configuration parameters of the target controls and connection relationships between the target controls; monitoring a workflow submission instruction, and in response to monitoring the workflow submission instruction, creating an initial workflow based on the target controls, the control configuration parameters of the target controls, and the connection relationships; determining the dependency relationship between the work nodes in the initial workflow, generating an execution path of the initial workflow based on the dependency relationship, performing text processing on a to-be-processed text according to the execution path, and obtaining a workflow execution log generated during the text processing process; in response to an execution exception in the to-be-processed text, obtaining a preset exception keyword, extracting a first exception-related parameter from the workflow execution log based on the exception keyword, and determining an exception locating result of the initial workflow according to the first exception-related parameter, wherein the first exception-related parameter at least includes a first exception type, an abnormal text position, and an abnormal work node.
[0006] According to an embodiment of the present application, the workflow anomaly locating method further includes: generating a first optimization strategy corresponding to the initial workflow based on the first anomaly related parameter; optimizing the initial workflow based on the first optimization strategy, and obtaining a target workflow generated after the optimization.
[0007] According to one embodiment of the present application, a first optimization strategy corresponding to the initial workflow is generated based on the first exception-related parameters, including: determining the target control corresponding to the abnormal working node, and obtaining the node configuration parameters of the abnormal working node according to the control configuration parameters of the target control corresponding to the abnormal working node; obtaining the text-related parameters of the abnormal text position; comparing and analyzing the node configuration parameters and the text-related parameters, and generating the first optimization strategy corresponding to the initial workflow in combination with the first exception type.
[0008] According to one embodiment of the present application, a comparative analysis is performed on the node configuration parameters and the text-related parameters, and in combination with the first exception type, a first optimization strategy corresponding to the initial workflow is generated, including: in response to the first exception type being a data format mismatch, obtaining a first data format corresponding to the abnormal working node according to the node configuration parameters; determining a second data format corresponding to the abnormal text position according to the text-related parameters; obtaining format difference information between the first data format and the second data format; and determining the first optimization strategy corresponding to the initial workflow based on the format difference information.
[0009] According to one embodiment of the present application, a comparative analysis is performed on the node configuration parameters and the text-related parameters, and in combination with the first exception type, a first optimization strategy corresponding to the initial workflow is generated, including: in response to the first exception type being missing data, obtaining the input text type corresponding to the abnormal working node according to the node configuration parameters; determining the missing text type corresponding to the abnormal text position according to the text-related parameters; and generating the first optimization strategy corresponding to the initial workflow according to the input text type and the missing text type.
[0010] According to one embodiment of the present application, the workflow exception locating method also includes: obtaining the creation result of the initial workflow; in response to the creation result indicating that the initial workflow creation failed, obtaining the workflow creation log generated during the creation process; analyzing the workflow creation log to obtain second exception-related parameters, the second exception-related parameters at least including at least one of a second exception type and an exception control; generating a second optimization strategy corresponding to the initial workflow based on the second exception-related parameters; optimizing the initial workflow based on the second optimization strategy, and obtaining the optimized initial workflow.
[0011] According to an embodiment of the present application, the workflow anomaly location method further includes: obtaining adjustment parameters for any optimization strategy among the first optimization strategy and the second optimization strategy; and adjusting any optimization strategy based on the adjustment parameters to obtain the optimization strategy generated after the adjustment.
[0012] According to one embodiment of the present application, the control configuration parameters of the target control are obtained, including: in response to monitoring a user's selection operation on any target control, obtaining a set of control properties corresponding to the target control; obtaining the target control properties selected by the user, and calling a text processing algorithm corresponding to the target control properties; replacing the original text processing algorithm corresponding to the selected target control with the text processing algorithm corresponding to the target control properties, to generate the target control.
[0013] The second aspect of the present application provides a workflow exception location device, including: an acquisition module, used to acquire a control set selected from a candidate control library, the control set including one or more target controls, and acquire the control configuration parameters of the target controls and the connection relationship between the target controls; a creation module, used to monitor the workflow submission instruction, and in response to monitoring the workflow submission instruction, create an initial workflow based on the target control, the control configuration parameters of the target control and the connection relationship; an execution module, used to determine the dependency relationship between each work node in the initial workflow, generate an execution path of the initial workflow based on the dependency relationship, perform text processing on the text to be processed according to the execution path, and acquire the workflow execution log generated during the text processing; a positioning module, used to respond to the execution exception of the text to be processed, acquire preset exception keywords, extract first exception-related parameters from the workflow execution log based on the exception keywords, and determine the exception location result of the initial workflow according to the first exception-related parameters, wherein the first exception-related parameters at least include a first exception type, an abnormal text position and an abnormal work node.
[0014] According to one embodiment of the present application, the workflow anomaly locating device also includes: a generation module, which is used to generate a first optimization strategy corresponding to the initial workflow based on the first anomaly related parameters; an optimization module, which is used to optimize the initial workflow based on the first optimization strategy to obtain the optimized initial workflow.
[0015] According to one embodiment of the present application, the generation module is also used to: determine the target control corresponding to the abnormal working node, and obtain the node configuration parameters of the abnormal working node according to the control configuration parameters of the target control corresponding to the abnormal working node; obtain the text-related parameters of the abnormal text position; compare and analyze the node configuration parameters and the text-related parameters, and generate a first optimization strategy corresponding to the initial workflow in combination with the first exception type.
[0016] According to one embodiment of the present application, the generation module is also used to: in response to the first exception type being a data format mismatch, obtain a first data format corresponding to the abnormal working node according to the node configuration parameters; determine a second data format corresponding to the abnormal text position according to text-related parameters; obtain format difference information between the first data format and the second data format; and determine a first optimization strategy corresponding to the initial workflow based on the format difference information.
[0017] According to one embodiment of the present application, the generation module is also used to: in response to the first exception type being missing data, obtain the input text type corresponding to the abnormal working node according to the node configuration parameters; determine the missing text type corresponding to the abnormal text position according to the text-related parameters; and generate a first optimization strategy corresponding to the initial workflow according to the input text type and the missing text type.
[0018] According to one embodiment of the present application, in a workflow exception locating device: a creation module is also used to obtain a creation result of an initial workflow; a locating module is also used to obtain a workflow creation log generated during the creation process in response to a creation result indicating that the initial workflow creation failed, analyze the workflow creation log, and obtain a second exception-related parameter, the second exception-related parameter at least including at least one of a second exception type and an exception control; a generation module is also used to generate a second optimization strategy corresponding to the initial workflow based on the second exception-related parameters; and an optimization module is also used to optimize the initial workflow based on the second optimization strategy to obtain a target workflow generated after the optimization.
[0019] According to one embodiment of the present application, the optimization module is further used to: for any optimization strategy among the first optimization strategy and the second optimization strategy, obtain adjustment parameters for the optimization strategy, and adjust any optimization strategy based on the adjustment parameters to obtain the optimization strategy generated after the adjustment.
[0020] According to one embodiment of the present application, the acquisition module is also used to: in response to monitoring a user's selection operation on any target control, obtain a set of control properties corresponding to the target control; obtain the target control properties selected by the user, and call up a text processing algorithm corresponding to the target control properties; replace the original text processing algorithm corresponding to the selected target control with the text processing algorithm corresponding to the target control properties to generate a target control.
[0021] The third aspect embodiment of the present application proposes an electronic device, comprising: at least one processor; and a memory communicatively connected to the at least one processor; wherein the memory stores instructions executable by the at least one processor, and the instructions are executed by the at least one processor to implement the workflow anomaly locating method as described in the first aspect embodiment of the present application.
[0022] The fourth aspect embodiment of the present application proposes a non-transitory computer-readable storage medium storing computer instructions, wherein the computer instructions are used to implement the workflow anomaly locating method as described in the first aspect embodiment of the present application.
[0023] The fifth aspect of the present application provides a computer program product, including a computer program, which, when executed by a processor, implements the workflow exception location method as described in the first aspect of the present application.
[0024] The technical solution provided by the embodiments of the present disclosure brings at least the following beneficial effects: the present application achieves a high degree of automation of the document processing process by adopting workflow technology, reducing labor costs and time costs; and allows users to flexibly adjust the document processing process and parameter settings according to specific application scenarios and business needs, which can meet the personalized needs of different users and improve the overall user experience; it can process documents quickly and accurately, and can automatically generate detailed workflow execution logs. Through in-depth analysis of the logs, the problem can be quickly located, so as to facilitate the subsequent adoption of corresponding measures for repair, thereby ensuring the stable operation and continuous improvement of the workflow.
[0025] It is to be understood that the foregoing general description and the following detailed description are exemplary and explanatory only and are not restrictive of the present disclosure. BRIEF DESCRIPTION OF THE DRAWINGS
[0026] The above and / or additional aspects and advantages of the present application will become apparent and easily understood from the following description of the embodiments in conjunction with the accompanying drawings, in which:
[0027] Figure 1 It is a schematic diagram of an exemplary implementation of a workflow anomaly locating method shown in an embodiment of the present application.
[0028] Figure 2 It is a schematic diagram of creating an initial workflow on a canvas, shown in one embodiment of the present application.
[0029] Figure 3 It is a schematic diagram of an exemplary implementation of a workflow anomaly locating method shown in an embodiment of the present application.
[0030] Figure 4 It is a schematic diagram of an exemplary implementation of a workflow anomaly locating method shown in an embodiment of the present application.
[0031] Figure 5 It is a schematic diagram of a workflow anomaly locating device shown in an embodiment of the present application.
[0032] Figure 6 It is a schematic diagram of an electronic device shown in one embodiment of the present application. DETAILED DESCRIPTION
[0033] Embodiments of the present application are described in detail below, and examples of the embodiments are shown in the accompanying drawings, wherein the same or similar reference numerals throughout represent the same or similar elements or elements having the same or similar functions. The embodiments described below with reference to the accompanying drawings are exemplary and are intended to be used to explain the present application, and should not be construed as limiting the present application.
[0034] It should be noted that the acquisition, transmission, storage, use, and processing of data in the technical solution of this application are in compliance with the relevant provisions of national laws and regulations.
[0035] It should be noted that in the embodiments of the present application, certain software, components, models and other existing solutions in the industry may be mentioned, and they should be regarded as exemplary. Their purpose is only to illustrate the feasibility of implementing the technical solution of the present application, but it does not mean that the applicant has or will necessarily use the solution.
[0036] The following is an introduction to the terms involved in this application:
[0037] Workflow: A workflow is a series of tasks or activities organized in a specific order. These tasks or activities are related to each other in a specific way to achieve a certain expected result.
[0038] Activiti: Activiti is an open source Java-based workflow and business process management platform. It provides a rich workflow engine and application programming interface (API) that can be used to design, deploy and manage various complex workflows and business processes.
[0039] Figure 1 is a schematic diagram of an exemplary implementation of a workflow anomaly location method shown in the present application, such as Figure 1 As shown, the abnormal location method of the workflow includes the following steps:
[0040] S101, obtaining a control set selected from a candidate control library, the control set including one or more target controls, and obtaining control configuration parameters of the target controls and connection relationships between the target controls.
[0041] Figure 2 is a schematic diagram of creating an initial workflow on a canvas shown in this application, such as Figure 2 As shown, on the visual operation interface, a candidate control library interface and a canvas interface are provided. The user can, as needed, click the Add button in the left canvas, select the target control in the candidate control library interface and drag it to the canvas to add the corresponding target control to the canvas, thereby realizing a custom configuration of the initial workflow.
[0042] Among them, the candidate control library may include multiple candidate controls, such as file reading control, large language model (LLM) cutting control, title cutting control, symbol cutting control, word count cutting control, Json data processing control, large language model control, merge text control, branch control, call other model control, and generate document control.
[0043] Among them, the file reading control supports uploading word, excel, pdf or compressed packages. The uploaded data will be used as the basic input, and the source data will be processed later.
[0044] Among them, the LLM cutting control supports users to configure prompt words, temperature and other content. When executed, the program will call the basic large language model and perform operations such as segmentation or summarization of the text according to the prompt words. By feeding a large amount of data to the model and adjusting the model according to the results, a model that better meets user needs can be obtained, which can provide better data processing in the subsequent use process.
[0045] Among them, the title cutting control supports cutting the input text with the first-level title and the second-level title as the cutting points, and finally outputs multiple paragraphs of text.
[0046] Among them, the symbol cutting control supports cutting the input text according to symbols such as line breaks, commas, periods, etc., and finally outputs multiple paragraphs of text.
[0047] Among them, the word count cutting control supports cutting text according to a certain number of words, and finally outputs multiple paragraphs of text.
[0048] Among them, the Json data processing control supports Json merging, record filtering, field extraction and other functions. Json merging is to merge two Json strings into one according to the specified primary key; record filtering is to filter the Json data that meets the conditions according to the filter key; field extraction is to extract the specified field data of the Json string.
[0049] Among them, the large language model control is similar to the LLM cutting control, and users can select the appropriate model according to their needs.
[0050] Among them, the merge text control can merge multiple texts into one according to the set method.
[0051] Among them, the branch control diverts the data that meets the conditions and performs different operations on them.
[0052] Among them, calling other model controls can call a configured process and process it in combination with the data of the existing process.
[0053] Among them, the document generation control supports the generation of document files such as word and excel.
[0054] Among them, the control configuration parameters of the target control may include prompt words, output variables, model names, model required accuracy, etc.
[0055] S102, monitoring a workflow submission instruction, and in response to monitoring the workflow submission instruction, creating an initial workflow based on a target control, control configuration parameters of the target control, and a connection relationship.
[0056] The server monitors the workflow submission instruction. If a workflow submission instruction is detected, it is converted into an activiti executable node based on the target control, the control configuration parameters of the target control and the connection relationship to create the initial workflow.
[0057] The creation of the generated initial workflow also supports the user to customize the parameter configuration of the work nodes included in the initial workflow.
[0058] S103, determining the dependency relationship between the working nodes in the initial workflow, generating an execution path of the initial workflow based on the dependency relationship, performing text processing on the text to be processed according to the execution path, and obtaining a workflow execution log generated during the text processing.
[0059] The text to be processed includes but is not limited to Word documents, Excel tables, PDF documents, etc.
[0060] Users can upload the documents to be processed on the interface, adjust the prompt words and other contents set in the original work node configuration, and then start the process. Activiti will automatically read the corresponding parameter configuration, then pull up the process instance and start processing according to the set process.
[0061] The workflow execution logs may be correspondingly stored in the database, so that when the user needs, the relevant workflow execution logs can be quickly found according to the classification, sorting and search functions of the workflow execution logs.
[0062] S104, in response to an execution exception of the text to be processed, obtain preset exception keywords, and extract first exception-related parameters from the workflow execution log based on the exception keywords, and determine the exception location result of the initial workflow according to the first exception-related parameters, wherein the first exception-related parameters at least include a first exception type, an exception text position, and an exception work node.
[0063] If the initial workflow successfully processes the text to be processed, corresponding Word, Excel and other documents will be generated for download.
[0064] If the initial workflow performs text processing on the processed text abnormally, an exception location analysis is required. When performing an exception location analysis, you first need to obtain the preset exception keyword, for example, you can set the exception keyword to "ERROR", and extract the exception-related parameters from the workflow execution log based on the exception keyword as the first exception-related parameters, and determine the exception location result of the initial workflow based on the first exception-related parameters. Among them, the first exception-related parameters include at least the first exception type, the abnormal text position, and the abnormal work node.
[0065] The first exception type may be format error, missing data, calculation error, etc.
[0066] The abnormal text location may be a specific line or field in a file.
[0067] Among them, the abnormal working node is the working node that performs abnormally in the initial workflow.
[0068] In addition to the above, the first anomaly related parameters may also include anomaly occurrence time, anomaly snapshot, anomaly description and other parameters.
[0069] The exception occurrence time is used to record the specific timestamp when the exception occurs.
[0070] The exception snapshot is used to provide data samples or data context when the exception occurs.
[0071] The exception description is a specific description of the exception, including possible causes and impacts of the exception.
[0072] The embodiment of the present application proposes a method for locating an exception in a workflow, comprising: obtaining a control set selected from a candidate control library, the control set including one or more target controls, and obtaining control configuration parameters of the target controls and connection relationships between the target controls; monitoring a workflow submission instruction, and in response to monitoring the workflow submission instruction, creating an initial workflow based on the target controls, the control configuration parameters of the target controls and the connection relationships; determining the dependency relationship between the working nodes in the initial workflow, generating an execution path of the initial workflow based on the dependency relationship, performing text processing on a to-be-processed text according to the execution path, and obtaining a workflow execution log generated during the text processing process; in response to an execution exception in the to-be-processed text, obtaining a preset exception keyword, extracting a first exception-related parameter from the workflow execution log based on the exception keyword, and determining an exception locating result of the initial workflow according to the first exception-related parameter, wherein the first exception-related parameter at least includes a first exception type, an abnormal text position and an abnormal working node. This application achieves a high degree of automation in the document processing process by adopting workflow technology, reducing labor costs and time costs; and allows users to flexibly adjust the document processing process and parameter settings according to specific application scenarios and business needs, which can meet the personalized needs of different users and improve the overall user experience; it can process documents quickly and accurately, and can automatically generate detailed workflow execution logs. Through in-depth analysis of the logs, the problem can be quickly located, so as to facilitate the subsequent adoption of corresponding measures to repair it, thereby ensuring the stable operation and continuous improvement of the workflow.
[0073] Among them, when obtaining the control configuration parameters of the target control, if the user's selection operation on any target control is monitored, the control attribute set corresponding to the target control is obtained, for example, the control attribute set generated by the selected text processing algorithm supported by the target control is displayed on the user screen for the user to select, and the target control attribute selected by the user is obtained, and the text processing algorithm corresponding to the target control attribute is called; the original text processing algorithm corresponding to the selected target control is replaced with the text processing algorithm corresponding to the target control attribute to generate the target control. In this way, the user is allowed to flexibly adjust the document processing process and target control parameter settings according to specific application scenarios and business needs, and select an algorithm that is more suitable for the application scenario, which can meet the personalized needs of different users and improve the overall user experience.
[0074] Figure 3 is a schematic diagram of an exemplary implementation of a workflow anomaly location method shown in the present application, such as Figure 3 As shown, the abnormal location method of the workflow includes the following steps:
[0075] S301, obtaining a control set selected from a candidate control library, the control set including one or more target controls, and obtaining control configuration parameters of the target controls and connection relationships between the target controls.
[0076] S302, monitoring a workflow submission instruction, and in response to monitoring the workflow submission instruction, creating an initial workflow based on a target control, control configuration parameters of the target control, and a connection relationship.
[0077] S303, determining the dependency relationship between the working nodes in the initial workflow, generating an execution path of the initial workflow based on the dependency relationship, performing text processing on the text to be processed according to the execution path, and obtaining a workflow execution log generated during the text processing.
[0078] S304, in response to an execution exception of the text to be processed, obtain preset exception keywords, and extract first exception-related parameters from the workflow execution log based on the exception keywords, and determine the exception location result of the initial workflow according to the first exception-related parameters, wherein the first exception-related parameters at least include a first exception type, an exception text position, and an exception work node.
[0079] Regarding the specific implementation of steps S301 to S304, reference may be made to the specific introduction of the relevant parts in the above embodiments, which will not be elaborated here.
[0080] S305: Generate a first optimization strategy corresponding to the initial workflow based on the first exception-related parameter.
[0081] Optionally, the user can click the "Generate Optimization Strategy" button in the log viewing interface to trigger the process of generating a first optimization strategy corresponding to the initial workflow based on the first exception-related parameters.
[0082] In the specific implementation of generating the first optimization strategy corresponding to the initial workflow based on the first exception-related parameters, the target control corresponding to the abnormal working node can be first determined, and the node configuration parameters of the abnormal working node can be obtained according to the control configuration parameters of the target control corresponding to the abnormal working node; the text-related parameters of the abnormal text position can be obtained; the node configuration parameters and the text-related parameters can be compared and analyzed, and the first optimization strategy corresponding to the initial workflow can be generated in combination with the first exception type. And a specific first optimization strategy can be further provided to the user. By generating the first optimization strategy corresponding to the initial workflow for the abnormal working node, it is intended to help users optimize processing rules or data formats, etc., to reduce the error rate.
[0083] Exemplarily, the first optimization strategy may be a suggestion to modify certain data processing rules, add data verification steps, or adjust the processing order.
[0084] Exemplarily, the first optimization strategy may be to suggest modifying the format or structure of the input data to meet the rule requirements.
[0085] Exemplarily, the first optimization strategy may be to suggest adding data cleaning or preprocessing steps in the processing flow to reduce the error rate.
[0086] Exemplarily, the first optimization strategy may be to suggest adjusting the default settings or permission allocation of the initial workflow to optimize the workflow execution.
[0087] As an implementable method, if the first exception type is data format mismatch, the first data format corresponding to the abnormal working node is obtained according to the node configuration parameters; the second data format corresponding to the abnormal text position is determined according to the text-related parameters; the format difference information between the first data format and the second data format is obtained; and the first optimization strategy corresponding to the initial workflow is determined based on the format difference information.
[0088] Optionally, if the format difference can be resolved by modifying the node configuration parameters of the abnormal working node, a first optimization strategy can be generated to modify the relevant configuration parameters of the abnormal working node; if modifying the node configuration parameters of the abnormal working node cannot resolve the format difference, a first optimization strategy can be generated to add a data preprocessing node before the abnormal working node to resolve the format difference problem.
[0089] As another achievable method, in response to the first exception type being missing data, the input text type corresponding to the abnormal working node is obtained according to the node configuration parameters; the missing text type corresponding to the abnormal text position is determined according to the text-related parameters; and the first optimization strategy corresponding to the initial workflow is generated according to the input text type and the missing text type.
[0090] Optionally, a first optimization strategy may be generated to add a data verification node before the abnormal working node for data verification. If the data verification fails, it may be sent back to the relevant department for text re-editing.
[0091] Specific analysis is performed on specific exception types to generate the first optimization strategy, allowing users to quickly optimize workflows and improve the efficiency and accuracy of data processing.
[0092] S306: Optimize the initial workflow based on the first optimization strategy, and obtain a target workflow generated after the optimization.
[0093] As an implementable manner, after the first optimization strategy is generated, the initial workflow may be optimized directly based on the first optimization strategy to obtain a target workflow generated after the optimization.
[0094] As another feasible manner, after the first optimization strategy is generated as mentioned above, the first optimization strategy can be displayed on the user's screen for the user to read and know, and the user's adjustment operation on the first optimization strategy can be monitored. If the user adjusts the strategy based on the first optimization strategy, the adjustment parameters of the first optimization strategy are obtained, and the first optimization strategy is adjusted based on the adjustment parameters to obtain the first optimization strategy generated after the adjustment and execute it to obtain the target workflow generated after the optimization. In this way, interaction with the user in the process of optimizing the workflow can be achieved. Not only can the first optimization strategy be generated based on the server, but the user's optimization ideas can also be integrated to enhance the user experience.
[0095] Furthermore, after obtaining the target workflow generated after optimization, a user's instruction to reprocess the processing text with exceptions may be received, and the processing text with exceptions may be reprocessed based on the target workflow generated after optimization according to the first optimization strategy.
[0096] The embodiments of the present application achieve a high degree of automation of the document processing process by adopting workflow technology, reducing labor costs and time costs; and allow users to flexibly adjust the document processing process and parameter settings according to specific application scenarios and business needs, which can meet the personalized needs of different users and improve the overall user experience; it can process documents quickly and accurately, and can automatically generate detailed workflow execution logs. Through in-depth analysis of the logs, problems can be quickly located; through timely feedback and automatic generation of the first optimization strategy for workflow optimization, the risk of processing failure caused by rule configuration errors or data format mismatches can be reduced, thereby ensuring the stable operation and continuous improvement of the workflow.
[0097] Figure 4 is a schematic diagram of an exemplary implementation of a workflow anomaly location method shown in the present application, such as Figure 3 As shown, the abnormal location method of the workflow includes the following steps:
[0098] S401, obtaining a control set selected from a candidate control library, the control set including one or more target controls, and obtaining control configuration parameters of the target controls and connection relationships between the target controls.
[0099] S402, monitoring a workflow submission instruction, and in response to monitoring the workflow submission instruction, creating an initial workflow based on a target control, control configuration parameters of the target control, and a connection relationship.
[0100] S403, obtaining the creation result of the initial workflow. If the creation result indicates that the creation of the initial workflow fails, obtaining the workflow creation log generated during the creation process.
[0101] S404: Analyze the workflow creation log to obtain second exception related parameters, where the second exception related parameters include at least one of a second exception type and an exception control.
[0102] The second exception type may include logic errors (for example, the conditional branch does not completely cover all possible situations), connectivity errors (for example, the output port is not correctly connected to the input port of another control), and the like.
[0103] Among them, the abnormal control refers to the control that causes the failure of workflow creation due to an exception during the process of creating the initial workflow.
[0104] S405: Generate a second optimization strategy corresponding to the initial workflow based on the second exception-related parameters.
[0105] The second abnormality related parameters obtained above are analyzed to generate an optimization strategy as a second optimization strategy corresponding to the initial workflow.
[0106] For example, if the second exception type is a connectivity error and the abnormal control is the target control 2, then the second optimization strategy that can be generated is: correctly connect the output port of the target control 2 to the input port of another control.
[0107] S406: Optimize the initial workflow based on the second optimization strategy to obtain the optimized initial workflow.
[0108] As a feasible method, after the second optimization strategy is generated as mentioned above, the second optimization strategy can be displayed on the user's screen for the user to read and know, and the user's adjustment operation on the second optimization strategy can be monitored. If the user adjusts the strategy based on the second optimization strategy, the adjustment parameters of the second optimization strategy are obtained, and the second optimization strategy is adjusted based on the adjustment parameters to obtain the second optimization strategy generated after the adjustment and execute it to obtain the initial workflow after optimization. In this way, interaction with the user in the process of optimizing the workflow can be achieved. Not only can the second optimization strategy be generated based on the server, but it can also be integrated into the user's optimization ideas, thereby enhancing the user experience.
[0109] S407, in response to the creation result indicating that the initial workflow was successfully created, or although the initial workflow failed to be created but the failed workflow has been optimized and the optimized initial workflow has been obtained, then, determine the dependency relationship between the work nodes in the current initial workflow, generate an execution path of the initial workflow based on the dependency relationship, perform text processing on the text to be processed according to the execution path, and obtain the workflow execution log generated during the text processing process.
[0110] S408, in response to an execution exception of the text to be processed, obtain preset exception keywords, and extract first exception-related parameters from the workflow execution log based on the exception keywords, and determine the exception location result of the initial workflow according to the first exception-related parameters, wherein the first exception-related parameters at least include a first exception type, an exception text position, and an exception work node.
[0111] S409: Generate a first optimization strategy corresponding to the initial workflow based on the first exception-related parameter.
[0112] S410, optimizing the initial workflow based on the first optimization strategy, and obtaining a target workflow generated after the optimization.
[0113] The workflow exception locating method proposed in the embodiment of the present application can generate a workflow creation log when the workflow creation fails, and through in-depth analysis of the workflow creation log, it can quickly locate the problem in the workflow creation process and generate an optimization strategy; and after the initial workflow is successfully created or optimized, the text to be processed is processed and analyzed based on the initial workflow, and the workflow execution log is obtained. If the text to be processed is executed abnormally, through in-depth analysis of the workflow execution log, it can quickly locate the problem in the workflow execution process and generate an optimization strategy, which can help users quickly optimize workflows and reduce the risk of processing failures caused by rule configuration errors or data format mismatches, thereby ensuring the stable operation and continuous improvement of workflows.
[0114] Figure 5 is a schematic diagram of an abnormality locating device of a workflow shown in the present application, such as Figure 5 As shown, the workflow anomaly locating device 500 includes an acquisition module 501, a creation module 502, an execution module 503 and a locating module 504, wherein:
[0115] The acquisition module 501 is used to acquire a control set selected from a candidate control library, the control set including one or more target controls, and acquire control configuration parameters of the target controls and connection relationships between the target controls.
[0116] The creation module 502 is used to monitor the workflow submission instruction, and in response to monitoring the workflow submission instruction, create an initial workflow based on the target control, the control configuration parameters of the target control and the connection relationship.
[0117] The execution module 503 is used to determine the dependency relationship between the working nodes in the initial workflow, generate the execution path of the initial workflow based on the dependency relationship, perform text processing on the text to be processed according to the execution path, and obtain the workflow execution log generated during the text processing.
[0118] The positioning module 504 is used to respond to the execution exception of the text to be processed, obtain preset exception keywords, and extract the first exception related parameters from the workflow execution log based on the exception keywords, and determine the exception positioning result of the initial workflow according to the first exception related parameters, wherein the first exception related parameters at least include the first exception type, the abnormal text position and the abnormal work node.
[0119] By adopting workflow technology, this device achieves a high degree of automation in the document processing process, reducing labor costs and time costs; and allows users to flexibly adjust the document processing process and parameter settings according to specific application scenarios and business needs, which can meet the personalized needs of different users and improve the overall user experience; it can process documents quickly and accurately, and can automatically generate detailed workflow execution logs. Through in-depth analysis of the logs, the problem can be quickly located, so as to facilitate the subsequent adoption of corresponding measures for repair, thereby ensuring the stable operation and continuous improvement of the workflow.
[0120] According to one embodiment of the present application, the workflow anomaly locating device 500 also includes: a generation module, which is used to generate a first optimization strategy corresponding to the initial workflow based on the first anomaly related parameters; an optimization module, which is used to optimize the initial workflow based on the first optimization strategy to obtain the optimized initial workflow.
[0121] According to one embodiment of the present application, the generation module is also used to: determine the target control corresponding to the abnormal working node, and obtain the node configuration parameters of the abnormal working node according to the control configuration parameters of the target control corresponding to the abnormal working node; obtain the text-related parameters of the abnormal text position; compare and analyze the node configuration parameters and the text-related parameters, and generate a first optimization strategy corresponding to the initial workflow in combination with the first exception type.
[0122] According to one embodiment of the present application, the generation module is also used to: in response to the first exception type being a data format mismatch, obtain a first data format corresponding to the abnormal working node according to the node configuration parameters; determine a second data format corresponding to the abnormal text position according to text-related parameters; obtain format difference information between the first data format and the second data format; and determine a first optimization strategy corresponding to the initial workflow based on the format difference information.
[0123] According to one embodiment of the present application, the generation module is also used to: in response to the first exception type being missing data, obtain the input text type corresponding to the abnormal working node according to the node configuration parameters; determine the missing text type corresponding to the abnormal text position according to the text-related parameters; and generate a first optimization strategy corresponding to the initial workflow according to the input text type and the missing text type.
[0124] According to one embodiment of the present application, in a workflow exception locating device 500: a creation module 502 is also used to obtain a creation result of an initial workflow; a locating module 504 is also used to obtain a workflow creation log generated during the creation process in response to a creation result indicating that the initial workflow creation failed, analyze the workflow creation log, and obtain a second exception-related parameter, the second exception-related parameter at least including at least one of a second exception type and an exception control; a generation module is also used to generate a second optimization strategy corresponding to the initial workflow based on the second exception-related parameters; and an optimization module is also used to optimize the initial workflow based on the second optimization strategy to obtain a target workflow generated after the optimization.
[0125] According to one embodiment of the present application, the optimization module is further used to: for any optimization strategy among the first optimization strategy and the second optimization strategy, obtain adjustment parameters for the optimization strategy, and adjust any optimization strategy based on the adjustment parameters to obtain the optimization strategy generated after the adjustment.
[0126] According to one embodiment of the present application, the acquisition module 501 is also used to: in response to monitoring a user's selection operation on any target control, obtain a set of control properties corresponding to the target control; obtain the target control properties selected by the user, and call up a text processing algorithm corresponding to the target control properties; replace the original text processing algorithm corresponding to the selected target control with the text processing algorithm corresponding to the target control properties to generate a target control.
[0127] In order to implement the above embodiment, the present application embodiment also proposes an electronic device 600, such as Figure 6 As shown, the electronic device 600 includes: a processor 601 and a memory 602 communicatively connected to the processor, the memory 602 stores instructions that can be executed by at least one processor, and the instructions are executed by at least one processor 601 to implement the workflow anomaly locating method as shown in the above embodiment.
[0128] In order to implement the above embodiment, the embodiment of the present application also proposes a non-transitory computer-readable storage medium storing computer instructions, wherein the computer instructions are used to enable a computer to implement the workflow anomaly locating method as shown in the above embodiment.
[0129] In order to implement the above embodiment, the embodiment of the present application also proposes a computer program product, including a computer program, which implements the workflow exception location method shown in the above embodiment when executed by a processor.
[0130] In the description of the present application, it should be understood that the terms "center", "longitudinal", "lateral", "length", "width", "thickness", "up", "down", "front", "back", "left", "right", "vertical", "horizontal", "top", "bottom", "inside", "outside", "clockwise", "counterclockwise", "axial", "radial", "circumferential" and the like indicate orientations or positional relationships based on the orientations or positional relationships shown in the accompanying drawings, and are only for the convenience of describing the present application and simplifying the description, and do not indicate or imply that the referred device or element must have a specific orientation, be constructed and operated in a specific orientation, and therefore should not be understood as a limitation on the present application.
[0131] In addition, the terms "first" and "second" are used for descriptive purposes only and should not be understood as indicating or implying relative importance or implicitly indicating the number of the indicated technical features. Thus, a feature defined as "first" or "second" may explicitly or implicitly include one or more of the features. In the description of this application, the meaning of "plurality" is two or more, unless otherwise clearly and specifically defined.
[0132] In the description of this specification, the description with reference to the terms "one embodiment", "some embodiments", "example", "specific example", or "some examples" etc. means that the specific features, structures, materials or characteristics described in conjunction with the embodiment or example are included in at least one embodiment or example of the present application. In this specification, the schematic representations of the above terms do not necessarily refer to the same embodiment or example. Moreover, the specific features, structures, materials or characteristics described may be combined in any one or more embodiments or examples in a suitable manner. In addition, those skilled in the art may combine and combine the different embodiments or examples described in this specification and the features of the different embodiments or examples, without contradiction.
[0133] It should be noted that in the embodiments of the present application, certain software, components, models and other existing solutions in the industry may be mentioned, and they should be regarded as exemplary. Their purpose is only to illustrate the feasibility of implementing the technical solution of the present application, but it does not mean that the applicant has or will necessarily use the solution.
[0134] Although the embodiments of the present application have been shown and described above, it can be understood that the above embodiments are exemplary and cannot be understood as limitations on the present application. Ordinary technicians in this field can change, modify, replace and modify the above embodiments within the scope of the present application.
Claims
1. A workflow exception location method, It is characterized in that include: Acquire a control set selected from a candidate control library, the control set including one or more target controls, and acquire control configuration parameters of the target controls and connection relationships between the target controls; Monitoring a workflow submission instruction, and in response to monitoring the workflow submission instruction, creating an initial workflow based on the target control, the control configuration parameters of the target control, and the connection relationship; Determine the dependency relationship between the working nodes in the initial workflow, generate an execution path of the initial workflow based on the dependency relationship, perform text processing on the text to be processed according to the execution path, and obtain the workflow execution log generated during the text processing; In response to the execution exception of the text to be processed, a preset exception keyword is obtained, and a first exception-related parameter is extracted from the workflow execution log based on the exception keyword, and the exception location result of the initial workflow is determined according to the first exception-related parameter, wherein the first exception-related parameter includes at least a first exception type, an abnormal text position and an abnormal working node.
2. The method according to claim 1, It is characterized in that The method further comprises: generating a first optimization strategy corresponding to the initial workflow based on the first exception-related parameter; The initial workflow is optimized based on the first optimization strategy to obtain a target workflow generated after the optimization.
3. The method according to claim 2, It is characterized in that The generating a first optimization strategy corresponding to the initial workflow based on the first exception-related parameter includes: Determine the target control corresponding to the abnormal working node, and obtain the node configuration parameters of the abnormal working node according to the control configuration parameters of the target control corresponding to the abnormal working node; Obtain text-related parameters of the abnormal text position; The node configuration parameters and the text-related parameters are compared and analyzed, and combined with the first exception type, a first optimization strategy corresponding to the initial workflow is generated.
4. The method according to claim 3, It is characterized in that The comparing and analyzing the node configuration parameters and the text-related parameters, and generating a first optimization strategy corresponding to the initial workflow in combination with the first exception type, includes: In response to the first abnormality type being data format mismatch, acquiring a first data format corresponding to the abnormal working node according to the node configuration parameter; Determine a second data format corresponding to the abnormal text position according to the text-related parameters; Acquire format difference information between the first data format and the second data format; A first optimization strategy corresponding to the initial workflow is determined based on the format difference information.
5. The method according to claim 4, It is characterized in that The comparing and analyzing the node configuration parameters and the text-related parameters, and generating a first optimization strategy corresponding to the initial workflow in combination with the first exception type, includes: In response to the first abnormality type being data missing, acquiring an input text type corresponding to the abnormal working node according to the node configuration parameter; Determine the missing text type corresponding to the abnormal text position according to the text-related parameters; A first optimization strategy corresponding to the initial workflow is generated according to the input text type and the missing text type.
6. The method according to claim 1, It is characterized in that The method further comprises: Obtaining the creation result of the initial workflow; In response to the creation result indicating that the initial workflow creation fails, obtaining a workflow creation log generated during the creation process; Analyze the workflow creation log to obtain second exception related parameters, where the second exception related parameters include at least one of a second exception type and an exception control; generating a second optimization strategy corresponding to the initial workflow based on the second exception-related parameter; The initial workflow is optimized based on the second optimization strategy to obtain an optimized initial workflow.
7. The method according to claim 2 or 6, It is characterized in that The method further comprises: For any optimization strategy of the first optimization strategy and the second optimization strategy, obtaining adjustment parameters for the optimization strategy; The any one of the optimization strategies is adjusted based on the adjustment parameter to obtain an optimization strategy generated after the adjustment.
8. The method according to any one of claims 1 to 5, It is characterized in that The obtaining of the control configuration parameters of the target control includes: In response to detecting a user's selection operation on any of the target controls, obtaining a control attribute set corresponding to the target control; Obtain the target control attribute selected by the user, and call the text processing algorithm corresponding to the target control attribute; The original text processing algorithm corresponding to the selected target control is replaced with the text processing algorithm corresponding to the target control property to generate the target control.
9. A workflow anomaly location device, It is characterized in that include: An acquisition module, used to acquire a control set selected from a candidate control library, the control set including one or more target controls, and acquire control configuration parameters of the target controls and connection relationships between the target controls; A creation module, configured to monitor a workflow submission instruction, and in response to monitoring the workflow submission instruction, create an initial workflow based on the target control, the control configuration parameters of the target control, and the connection relationship; An execution module, used to determine the dependency relationship between the working nodes in the initial workflow, generate an execution path of the initial workflow based on the dependency relationship, perform text processing on the text to be processed according to the execution path, and obtain a workflow execution log generated during the text processing; A positioning module is used to obtain preset exception keywords in response to the execution exception of the text to be processed, and extract first exception-related parameters from the workflow execution log based on the exception keywords, and determine the exception positioning result of the initial workflow according to the first exception-related parameters, wherein the first exception-related parameters at least include a first exception type, an abnormal text position and an abnormal working node.
10. The device according to claim 9, It is characterized in that The device further comprises: A generating module, configured to generate a first optimization strategy corresponding to the initial workflow based on the first abnormality-related parameter; The optimization module is used to optimize the initial workflow based on the first optimization strategy and obtain a target workflow generated after the optimization.
11. The device according to claim 10, It is characterized in that The generating module is further used for: Determine the target control corresponding to the abnormal working node, and obtain the node configuration parameters of the abnormal working node according to the control configuration parameters of the target control corresponding to the abnormal working node; Obtain text-related parameters of the abnormal text position; The node configuration parameters and the text-related parameters are compared and analyzed, and combined with the first exception type, a first optimization strategy corresponding to the initial workflow is generated.
12. The device according to claim 11, It is characterized in that The generating module is further used for: In response to the first abnormality type being data format mismatch, acquiring a first data format corresponding to the abnormal working node according to the node configuration parameter; Determine a second data format corresponding to the abnormal text position according to the text-related parameters; Acquire format difference information between the first data format and the second data format; A first optimization strategy corresponding to the initial workflow is determined based on the format difference information.
13. The device according to claim 11, It is characterized in that The generating module is further used for: In response to the first abnormality type being data missing, acquiring an input text type corresponding to the abnormal working node according to the node configuration parameter; Determine the missing text type corresponding to the abnormal text position according to the text-related parameters; A first optimization strategy corresponding to the initial workflow is generated according to the input text type and the missing text type.
14. The device according to claim 9, It is characterized in that In the device: The creation module is also used to obtain the creation result of the initial workflow; The positioning module is further configured to obtain a workflow creation log generated during the creation process in response to the creation result indicating that the initial workflow creation failed, analyze the workflow creation log, and obtain a second exception-related parameter, wherein the second exception-related parameter includes at least one of a second exception type and an exception control; A generating module, further configured to generate a second optimization strategy corresponding to the initial workflow based on the second abnormality related parameter; The optimization module is further used to optimize the initial workflow based on the second optimization strategy to obtain the optimized initial workflow.
15. The device according to claim 10 or 14, It is characterized in that The optimization module is also used for: For any one of the first optimization strategy and the second optimization strategy, an adjustment parameter for the optimization strategy is obtained, and any one of the optimization strategies is adjusted based on the adjustment parameter to obtain an optimization strategy generated after the adjustment.
16. The device according to any one of claims 9 to 13, It is characterized in that The acquisition module is further used for: In response to detecting a user's selection operation on any of the target controls, obtaining a control attribute set corresponding to the target control; Obtain the target control attribute selected by the user, and call the text processing algorithm corresponding to the target control attribute; The original text processing algorithm corresponding to the selected target control is replaced with the text processing algorithm corresponding to the target control property to generate the target control.
17. An electronic device, include: at least one processor; as well as, a memory communicatively connected to the at least one processor; wherein, The memory stores instructions that can be executed by the at least one processor, and the instructions are executed by the at least one processor to enable the at least one processor to perform the method according to any one of claims 1 to 8.
18. A non-transitory computer-readable storage medium storing computer instructions, in, The computer instructions are used to cause the computer to execute the method according to any one of claims 1-8.
19. A computer program product comprising a computer program, which, when executed by a processor, implements the steps of the method according to any one of claims 1 to 8.
