Task generation method, system, device and computer program based on large-scale language model
The task generation method using a large-scale language model automates workflow creation by simplifying operations, enhancing efficiency and reducing costs through semantic understanding and automated task execution flowchart display.
Patent Information
- Application Number
- JP2025531012
- Authority / Receiving Office
- JP · JP
- Patent Type
- Applications
- Current Assignee / Owner
- Priority Date
- 2023-05-31
- Filing Date
- 2023-10-27
- Publication Date
- 2025-12-16
AI Technical Summary
Current workflow management systems require complex operations such as problem analysis, process design, code organization, and execution, leading to low efficiency and high costs.
A task generation method using a large-scale language model that includes obtaining task requirement information, performing semantic understanding, generating an executable structure, and displaying a task execution flowchart, with an execution status check link, to automate workflow creation.
Simplifies workflow generation by eliminating complex operations, improving efficiency and reducing costs through automated task creation and status monitoring.
Smart Images

Figure 2025540746000001_ABST
Abstract
Description
[Technical Field]
[0001] CROSS-REFERENCE TO RELATED APPLICATIONS This application claims priority to a Chinese patent application filed on May 31, 2023, bearing application number 2023106458258, and entitled "Task generation method, system, device and storage medium based on large-scale language model," the entire contents of which are incorporated herein by reference.
[0002] The present application relates to the technical field of computer technology, and in particular to a task generation method based on a large-scale language model, a task generation system based on a large-scale language model, a computer device, a storage medium, and a computer program product. [Background technology]
[0003] A workflow is a series of tasks, activities, or steps used to accomplish one or more business processes or projects. These tasks or activities follow specific orders or rules and can be performed automatically or manually. Workflows help organizations and businesses improve efficiency, optimize business processes, reduce costs, and increase productivity and quality. Workflows are typically managed and executed by some kind of workflow engine or software.
[0004] However, currently, users need to use computers to complete workflow tasks, which usually require complex operations such as problem analysis, process design, code organization, execution environment construction, and code execution. These operations are very tedious and suffer from problems such as complex operation, low efficiency, and high cost. Summary of the Invention
[0005] The present application provides a task generation method based on a large-scale language model, which includes: obtaining input task requirement information based on an interactive task generation interface; calling a large-scale language model, inputting task requirement information into the large-scale language model, performing semantic understanding on the task requirement information using the large-scale language model, and outputting an executable structure of a target task that is consistent with the task requirement information; According to the executable structure of the target task, performing graphic rendering on the target task, obtaining a task execution flowchart of the target task, and displaying the task execution flowchart on a task generation interface, wherein the target task is composed of at least one target atomic task; and a step of displaying an execution status check link for the target task in the task creation interface, the execution status check link being used to check the execution status of the target task.
[0006] The present application provides a task generation system based on a large-scale language model, which comprises: an information acquisition module for acquiring task requirement information input based on the interactive task generation interface; a structure acquisition module for calling a large-scale language model, inputting task requirement information into the large-scale language model, performing semantic understanding of the task requirement information using the large-scale language model, and outputting an executable structure of a target task that is consistent with the task requirement information; a task execution flowchart display module for performing graphic rendering on the target task based on the executable structure of the target task, obtaining a task execution flowchart of the target task, and displaying the task execution flowchart on a task generation interface, where the target task is composed of at least one target atomic task; and a link display module for displaying an execution status confirmation link of the target task on the task generation interface, the execution status confirmation link being used to confirm the execution status of the target task.
[0007] The present application provides a computer device comprising a memory and a processor, the memory having computer-readable instructions stored therein, the processor, when executing the computer-readable instructions, realizing the above-described large-scale language model-based task generation method.
[0008] The present application provides a non-volatile computer-readable storage medium having computer-readable instructions stored thereon, which, when executed by a processor, implements the above-described large-scale language model-based task generation method.
[0009] The present application provides a computer program product, which includes computer-readable instructions that, when executed by a processor, implement the large-scale language model-based task generation method described above.
[0010] In order to more clearly describe the technical solutions in the embodiments of the present application or the prior art, the following will briefly introduce the drawings used in the description of the embodiments or the prior art. The drawings in the following description are only embodiments of the present application, and it is obvious that a person skilled in the art can obtain other drawings based on the disclosed drawings without creative work. [Brief explanation of the drawings]
[0011] [Figure 1] FIG. 1 is a diagram illustrating an application environment of a task generation method based on a large-scale language model in an embodiment. [Figure 2] 1 is a flowchart of a task generation method based on a large-scale language model in one embodiment. [Figure 3A] FIG. 1 is a schematic diagram of an interactive task creation interface in one embodiment. [Figure 3B] FIG. 10 is a schematic diagram of an interactive task creation interface in another embodiment. [Figure 3C]FIG. 10 is a schematic diagram of an execution status confirmation interface in one embodiment. [Figure 4] 10 is a flowchart of a step of determining a target atomic task in one embodiment. [Figure 5] FIG. 2 is a schematic diagram of a storage structure for multi-level vectors in one embodiment. [Figure 6] 10 is a flowchart of generating an executable structure for a target task in one embodiment. [Figure 7] FIG. 2 is a schematic diagram of a task instance message queue in one embodiment. [Figure 8] FIG. 10 is a schematic diagram of a subtask instance message queue in one embodiment. [Figure 9] FIG. 10 is a schematic diagram of a global variable table in one embodiment. [Figure 10] 10 is a flowchart of task execution in one embodiment. [Figure 11] 1 is a structural block diagram of a task generation system based on a large-scale language model in one embodiment. [Figure 12] FIG. 2 is a diagram illustrating the internal structure of a computing device according to one embodiment. DETAILED DESCRIPTION OF THE INVENTION
[0012] The technical solutions in the embodiments of the present application will be described below clearly and completely with reference to the drawings in the embodiments of the present application, but it should be clear that the described embodiments are only some of the embodiments of the present application, not all of the embodiments, and all other embodiments that can be obtained by those skilled in the art based on the embodiments of the present application without any creative work fall within the scope of protection of the present application.
[0013] The task generation method based on a large-scale language model according to the embodiment of the present application can be applied to an application environment as shown in Fig. 1. In this, a terminal 102 communicates with a server 104 via a network. A data storage system can store data that the server 104 needs to process. The data storage system can be integrated into the server 104 or can be located in a cloud or another server. The terminal 102 and the server 104 can jointly execute the task generation method based on a large-scale language model, or the terminal 102 and the server 104 can independently execute the task generation method based on a large-scale language model.
[0014] An example will be described in which the terminal 102 and the server 104 jointly execute a task generation method based on a large-scale language model. In some embodiments, the terminal 102 displays an interactive task generation interface and sends task requirement information input into the interactive task generation interface to the server 104, which then acquires the input task requirement information through the interactive task generation interface. The server 104 invokes the large-scale language model, inputs the task requirement information into the large-scale language model, performs semantic understanding on the task requirement information using the large-scale language model, and outputs an executable structure of a target task consistent with the task requirement information. The server 104 performs graphic rendering of the target task based on the executable structure of the target task, acquires a task execution flowchart of the target task, and displays the task execution flowchart in the task generation interface of the terminal 102. The target task is composed of at least one target atomic task. An execution status check link for the target task is displayed in the task generation interface of the terminal 102, and the execution status check link is used to check the execution status of the target task.
[0015] Here, the terminal 102 may be, but is not limited to, various personal computers, laptops, smartphones, tablets, IoT devices, and portable wearable devices. The IoT device may be a smart speaker, a smart TV, a smart air conditioner, a smart in-car device, etc. The portable wearable device may be a smart watch, a smart bracelet, a head-mounted device, etc. The server 104 may be implemented as an independent server or a server cluster consisting of multiple servers.
[0016] In one embodiment, a task generation method based on a large-scale language model is provided, as shown in Fig. 2. This method will be described by taking as an example its application to a computer device (which may be the terminal 102 in Fig. 1 or the computer device 104 in Fig. 1), and includes the following steps:
[0017] Step 202: Obtain task requirement information input based on the interactive task generation interface.
[0018] Here, the task requirement information includes information about the task to be generated. The task requirement information is text information. A task can be understood as a workflow, which is a series of activities or steps used to realize one or more business processes or projects. These activities are performed according to specific orders and rules and can be executed automatically or manually. A workflow may be executed by a workflow execution engine or managed by software. Therefore, in a workflow scenario, the task requirement information is workflow requirement information.
[0019] The interactive task generation interface is an interface that supports human-computer interaction. The interactive task generation interface is used to receive task content input by a user, and the task content may be in text or non-text format. If the task content is in text format, the task content is task requirement information. If the task content is in non-text format, for example, if the task content is audio, image, or image-text information, the task content can be converted into text format to obtain the task requirement information. The task generation interface can be displayed in the form of a webpage, and for example, a computer device can retrieve task content entered in a search box on the webpage. The task generation interface can also be a conversation interface provided by a social application. FIG. 3A is a schematic diagram of a task generation interface in one embodiment. This embodiment is a workflow scenario, and the interactive task generation interface clearly shows an interactive conversation between a user account and a workflow customer service account. FIG. 3A shows audio information related to the workflow generated during the interactive conversation, and the user can send the audio information through the user account. In an embodiment of the present application, the format of information transmitted by a user through a user account in the interactive task generation interface is not limited, and may be audio, text information, image text information, audio / video information, etc. Such information is not particularly limited, and may be converted into corresponding task requirement information and its meaning understood by a large-scale language model. In one example, the task requirement information is text, and its content is "Remind everyone in the group to write a daily work report every day at 6 p.m., and on Fridays, remind everyone to write a weekly work report and a work plan for the following week."
[0020] Optionally, the computing device may present an interactive task creation interface in response to a search operation on the workflow customer service account. Task content submitted via the user account may be presented in the task creation interface. The computing device obtains task requirement information based on the task content, and the computing device also obtains the task requirement information input into the interactive task creation interface. Optionally, the user account may be an administrator account with task creation privileges.
[0021] Illustratively, in an instant messaging application logged in with a user account, in response to a search operation for a workflow customer service account in a search box, an interactive task creation interface is revealed in the instant messaging application.
[0022] The computing device may present audio transmitted via a user account in a task generation interface, or may present text transmitted via a user account, or may present image text information transmitted via a user account, or may present audio-video transmitted via a user account in an interactive task generation interface. The audio may include a target audio signal, and in a workflow scenario, the target audio signal may be "workflow." The text or image text information may include suggested words related to the target task, and in a workflow scenario, the suggested words may be "create" or "target workflow." It should be understood that the embodiments of the present application are not limited to the content or format of the task requirement information, and the user may input any content that can be understood by a natural language model.
[0023] If the input information is in voice format, the computer device recognizes the voice information as text and then uses the text as task requirement information. If text is specified in the interactive task generation interface, the computer device directly acquires the text. If audio / video is specified in the interactive task generation interface, the computer device performs image recognition to acquire the associated text and then uses it as task requirement information. As shown in Figure 3A, this diagram is a diagram of a workflow scenario, and the task requirement information is in voice format. In response to a voice input operation, voice recognition progress display information such as "Voice recognition in progress..." is sent via the workflow customer service account. After the computer device completes voice recognition and acquires the task requirement information, it sends a voice recognition result such as "Voice recognition result: Please create a workflow that reminds group members to write a daily work report every day at 6 p.m., and on Fridays, reminds everyone to write a weekly work report and the next week's work plan." via the workflow customer service account.
[0024] In some examples, obtaining task requirement information input based on the interactive task generation interface includes: defining a task generation interface capable of human-computer interaction; receiving task content input via the interactive task generation interface to obtain the task content; and performing semantic transformation on the task content to obtain the task requirement information.
[0025] Here, human-computer interaction refers to the interaction process between a user and a device. Semantic transformation is used to recognize the meaning of task content and obtain text that is consistent with the meaning.
[0026] Optionally, the computing device provides an interactive task generation interface capable of human-computer interaction, which may be an interface of a web page or an interface of a program application such as an instant messaging application.
[0027] The computer device receives the task requirement speech sent through the user account, acquires the task requirement speech, and displays the task requirement speech in the task generation interface. The computer device invokes a trained semantic recognition mode and performs speech recognition on the workflow requirement speech using a trained speech recognition model to acquire a first recognized text. The computer device acquires task requirement information based on the first recognized text.
[0028] Illustratively, after determining the first recognized text, the computing device performs post-processing on the first recognized text to obtain task requirement information, where the post-processing includes adding punctuation and correcting spelling errors.
[0029] Here, the training procedure for the trained speech recognition model includes a computer device acquiring a sample speech, which is acquired through various speech receiving software and hardware. The computer device preprocesses the sample speech to obtain a preprocessed sample speech. The preprocessing includes at least one of noise removal, speech segmentation, and speech feature extraction. The computer device performs feature extraction on the preprocessed sample speech to obtain a corresponding target signal. The computer device transmits the target signal to the speech recognition model to be trained to train the model and obtain a trained speech recognition model. Feature extraction involves converting the sample speech into a digital signal. The speech model is a statistical model used to describe various features of speech. The trained speech model is used to perform speech recognition on the target signal, i.e., convert the digital signal into text.
[0030] Alternatively, the computer device receives and obtains image text information sent through a user account, displays the image text information in a task generation interface, performs image text recognition on the image text information using a trained image text recognition model, obtains second recognized text, and determines it as task requirement information based on the second recognized text.
[0031] Illustratively, after determining the second recognized text, the computing device performs post-processing on the second recognized text to obtain task requirement information, where the post-processing includes adding punctuation and correcting spelling errors.
[0032] In this embodiment, semantic transformation is performed on the task content input into the task generation interface to obtain task requirement information that can better reflect the task requirements, making it easier for the subsequent large-scale language model to perform accurate semantic understanding and obtain a more accurate executable structure for the target task.
[0033] Step S204: Call the large-scale language model, input the task requirement information into the large-scale language model, perform semantic understanding on the task requirement information using the large-scale language model, and output an executable structure of the target task that is consistent with the task requirement information.
[0034] Large-scale language models are a deep learning-based natural language processing technology that can predict and generate text by training on large corpus data. Large-scale language models typically use recurrent neural networks (RNNs) or variants such as long-term memory networks (LSTMs) and gated recurrent units (GRUs) to capture contextual information from text sequences and perform tasks such as natural language text generation, language model evaluation, text classification, and sentiment analysis. In the field of natural language processing, large-scale language models are widely used in speech recognition, machine translation, automatic summarization, dialogue systems, and intelligent question and answering. Large-scale language models are used to generate target tasks that are consistent with task requirement information. Semantic understanding refers to understanding the meaning of task requirement information and making related inferences and judgments.
[0035] Executable constructs refer to data structures that can perform atomic tasks, for example DSL Json (Data Structures in Data Interchange Format for Domain Specific Languages) constructs.
[0036] Optionally, the computing device performs semantic understanding on the task requirement information by invoking the large-scale language model at least once to obtain an executable structure for the target task that is consistent with the task requirement information.
[0037] In some embodiments, the step of performing semantic understanding on the task requirement information using the large-scale language model and outputting an executable structure for the target task that is consistent with the task requirement information includes the steps of invoking a presentation corpus constructed for the workflow using the large-scale language model, performing semantic understanding on the task requirement information, obtaining an executable structure for the target task that is consistent with the task requirement information, and outputting the executable structure for the target task, wherein the presentation corpus includes presentation information constructed for each atomic task of the workflow, and the presentation information includes the executable structure and operation information for the atomic task.
[0038] Here, an atomic task is a task that can realize a basic function. For example, in a workflow scenario, an atomic task may be an application of the workflow platform, and each application can be understood as an atomic task. For example, Table 1 shows the applications supported by the workflow platform.
[0039] TIFF2025540746000002.tif249170TIFF2025540746000003.tif20170
[0040] The prompt information (i.e., prompt) of each atomic task is used to interpret the application scenario and usage of the atomic task, including the executable structure and operation information of the atomic task. It can be used to interpret how the atomic task is used, the relevant parameters when used, and what the input and output of the atomic task are. The prompt information of each atomic task may include questions and answers. For example, the following is an example of the contents of the prompt information for the atomic task "Initiate API Request" and the atomic task "Send Email". prompt=[ {“action”:“question”,“content”:“How do I access the WEB API interface?”}, {"action":"Answer", "content":"This is achieved by using [Initiate API Request] in a workflow. All you need to do is..."}, {“action”:“question”,“content”:“How do I send an email?”}, {"action":"Answer", "content":"This can be achieved by using the [Send Email] in the workflow. All you need to do is..."}, ]
[0041] In the above example, prompt refers to the prompt information, and WEB API is the network application interface. As can be seen from the above example, the prompt information for each atomic task includes a question and an answer, and the answer contains a complete and detailed executable structure. That is, the answer in the prompt information contains the executable structure and operation information of the atomic task. The operation information includes script code, programming code, parameters, etc. For example, if the atomic task is to execute coding language code, the corresponding prompt information is shown in Table 2 below.
[0042] TIFF2025540746000004.tif95170
[0043] In Table 2, "id" represents the atomic task ID (identity) and is used to uniquely identify an atomic task. This ID field is randomly generated. "type" represents the type field of the atomic task. "python" indicates that the atomic task is [Python script execution]. "code":"print('123')" represents the specific code to be executed. "version":"3.5" indicates that the programming language version used is 3.5. "param" represents the operational parameters used to execute the programming language. "preid" represents the ID of the previous atomic task (previous application). "nextid" represents the ID of the next atomic task to be executed. As a result, the presentation information for each atomic task not only includes the parameters and executable structure for executing the atomic task, but also indicates the atomic task before and the next atomic task after the atomic task is executed. In other words, the preid and nextid link the entire workflow to form an orderly execution.
[0044] Optionally, the computer device obtains a presentation corpus constructed for the workflow from the corpus, i.e., obtains all presentation information for constructing the workflow, and the presentation information of each atomic task is constructed and stored in advance. Based on the presentation corpus, the computer device performs semantic understanding on the task requirement information by invoking the large-scale language model at least once, determines an executable structure of a target task consistent with the task requirement information, and outputs the executable structure of the target task.
[0045] Taking a workflow scenario as an example, before invoking a large-scale language model for the first time, the workflow customer service account sends a notification about the invocation of the large-scale language model, "Identifying large-scale language model...", as shown in FIG. 3A, to remind the user that the large-scale language model is currently being invoked to generate a target task that is consistent with the task requirement information.
[0046] Each atomic task in the workflow platform requires corresponding presentation information, which is pre-created and can be used to construct various workflows. That is, for each task requirement, a pre-created presentation corpus can be directly obtained. Each atomic task has corresponding presentation information. This allows the executable structure of a target task to be generated quickly and accurately based on the presentation information of the corresponding atomic task.
[0047] In this embodiment, a large-scale language model is used to call on a presentation corpus constructed for a workflow to enable accurate language understanding of task requirement information and obtain an executable structure for a target task that is consistent with the task requirement information.
[0048] In some embodiments, using a large-scale language model to perform semantic understanding on the task requirement information based on a presentation corpus constructed for the workflow and to obtain an executable structure for a target task that is consistent with the task requirement information includes using a large-scale language model to perform semantic understanding based on the task requirement information and the presentation corpus to obtain at least one target atomic task that is consistent with the task requirement information; and obtaining an executable structure for the at least one target atomic task from the presentation corpus, and obtaining an executable structure for the target task that is consistent with the task requirement information based on the executable structure of the at least one target atomic task.
[0049] For example, the computer device directly determines that the task requirement information is a target atomic task by calling the large-scale language model once based on the task requirement information and the presentation corpus. At this time, the large-scale language model directly obtains the executable structure of the target atomic task and directly sets the executable structure of the target atomic task as the executable structure of the target task. In this example, the input task requirement information is requirement information corresponding to an application, and at this time, the executable structure of the target task can be obtained by calling the large-scale language model only once.
[0050] For example, the large-scale language model is invoked at least once based on the task requirement information and the presentation corpus to determine multiple target atomic tasks that are consistent with the task requirement information. The large-scale language model is then invoked again based on the multiple target atomic tasks, the task requirement information, and the presentation corpus to obtain executable structures for the multiple target atomic tasks. The computer device determines executable structures for the target tasks that are consistent with the task requirement information based on the executable structures for the multiple target atomic tasks, and outputs the executable structures for the target tasks. In this example, the large-scale language model is invoked at least twice, with the first invocation determining at least two target atomic tasks that correspond to the task requirement information, and then the second invocation determining the executable structures for each target atomic task, thereby determining the executable structures for the target tasks.
[0051] In this embodiment, a large-scale language model performs semantic understanding based on the task requirement information and the presented corpus, thereby automatically decomposing and obtaining at least one target atomic task that is consistent with the task requirement information, and directly obtaining an executable structure for the target task that is consistent with the task requirement information based on the executable structure of the at least one target atomic task. This simplifies the task generation procedure, allowing the user to automatically complete the task by simply providing the task requirement information without performing complex operations, thereby improving the efficiency of task generation.
[0052] Step S206: based on the executable structure of the target task, perform graphic rendering on the target task, obtain the task execution flowchart of the target task, and display the task execution flowchart on the task generation interface, where the target task is composed of at least one target atomic task.
[0053] Here, the task execution flowchart is a graphical representation of the target task, and reflects the execution process of the target task.
[0054] Optionally, after obtaining the executable structure of the target task, the computing device performs graphic rendering on the target task based on the executable structure of the target task, obtains a corresponding task execution flowchart, and displays the task execution flowchart of the target task on the interactive task generation interface.
[0055] For example, after obtaining the executable structure of the target task, the computer device sends presentation information about the workflow's graphical rendering through the workflow customer service account. The presentation information about the workflow's graphical rendering also includes information about the completion of the large-scale language model's response. That is, upon receiving the presentation information about the workflow's graphical rendering, the executable structure of the target task is generated, which simultaneously indicates that the target task is ready for graphical rendering. As shown in FIG. 3A , after obtaining the executable structure of the target task, the presentation information about the workflow's graphical rendering sent through the workflow customer service account (e.g., "The large-scale language model's response has been completed, and the workflow is being graphically rendered") is displayed after the presentation information about the invocation of the large-scale language model in the interactive task generation interface. In this way, once the executable structure of the target task is determined, the graphical rendering allows the user to timely and clearly know that the current target task has been automatically generated, and the task execution flowchart clearly reflects the details of the target task's structure. Then, the computer device analyzes the execution process of the target task based on the executable structure of the target task, performs graphical rendering of the target task based on the execution process, and obtains the task execution flowchart of the target task.
[0056] At this time, when the rendering operation is completed, presentation information about the rendering operation result is sent via the workflow customer service account, such as "Rendering Completed" in Fig. 3A. Of course, to allow the user to be notified of the workflow task execution flowchart in a timely manner, the bubble containing the presentation information about the rendering operation result may be dynamically displayed, the text in the bubble containing the presentation information about the rendering operation result may be flashed, or the color of the text in the bubble containing the presentation information about the rendering operation result may be changed, but this is not particularly limited.
[0057] For example, in a workflow scenario, after submitting the presentation information about the rendering operation result via the workflow customer service account, the task execution flowchart of the target workflow (i.e., the target work task) is directly transmitted. In the workflow task execution flowchart, corresponding shapes are selected and displayed according to the application of different function types. For example, the shapes of atomic tasks for triggering a workflow are represented by circles, and the circular "Trigger at 6 PM" in FIG. 3A represents a manually triggered atomic task of the trigger function type. The shapes of atomic tasks of executable function types are represented by squares, and the squares "Get today's day of the week," "Remind weekly report," and "Remind daily report" in FIG. 3A represent atomic tasks of executable function type. The shapes of atomic tasks of conditional decision function types are represented by diamonds, and the diamond "Conditional decision" in FIG. 3A determines whether today is Friday, and if so, reminds the weekly report, and if not, reminds the daily report.
[0058] In this way, by clearly showing the task execution flowchart of the target task in the interactive task generation interface, the structure of the target task corresponding to the task requirement information can be more intuitively reflected.When the execution status of the target task is updated, the execution status of the target task is updated in real time in the task execution flowchart, allowing the user to timely grasp the current execution status, thereby improving the user experience.
[0059] In some embodiments, after displaying the task execution flowchart in the task generation interface, the method further includes executing the target task, and if the execution state of the target task is updated, updating the execution state of the target task in the task execution flowchart.
[0060] Optionally, the computing device executes the target task, and if it is determined that the execution state of the target task has changed from not executed to running, updates the execution state of the target task in the task execution flowchart to a running execution state.
[0061] For example, when the execution state of the target task changes from not yet executed to running, an execution identifier indicating that the task is running is displayed in the task execution flowchart. For example, when the color of the execution identifier changes from a first color to a second color, the computer device determines that the execution identifier is an execution identifier indicating that the task is running, i.e., an execution identifier of the first color indicates that the task is not yet executed, and an execution identifier of the second color indicates that the task is running, the first color and the second color being different. Alternatively, text information indicating that the task is running, such as "Running," is displayed in the task execution flowchart. Alternatively, the execution identifier is made to flash in the task execution flowchart. When the execution identifier is not flashing, it indicates that the task is not yet executed, and when the execution identifier is flashing, it indicates that the task is running.
[0062] When the execution of the target task is completed, the computer device displays an execution identifier indicating the completion of the execution in the task execution flowchart. For example, text information indicating the completion of the execution, such as "Execution Completed," in the task execution flowchart. As can be understood, when the execution of the target task is completed, the target task enters an execution end state and can be considered to be in an unexecuted state. At this time, an execution identifier indicating the unexecuted state is displayed in the task execution flowchart, and correspondingly, the color of the execution identifier can be changed from the second color to the first color. As another example, when the execution of the target task is completed, the computer device does not flash the execution identifier in the task execution flowchart.
[0063] In this embodiment, when the execution of the target task starts, the execution status of the target task needs to be updated. At this time, by updating the execution status of the target task in the task execution flowchart, the user can directly know the current execution status of the target task, and can then choose whether to check the execution status as needed, thereby improving the user experience.
[0064] Step S208: Display an execution status check link of the target task on the task generation interface, and the execution status check link is used to check the execution status of the target task.
[0065] For example, when the execution of the target task starts, an execution status check link for the target task is displayed in the interactive task creation interface. For example, FIG. 3B is a schematic diagram of an interactive task creation interface in another embodiment. As shown in FIG. 3B, in a workflow scenario, when the execution of the target workflow starts, the execution status check link sent through the workflow customer service account in the interactive task creation interface is the workflow address in FIG. 3B: http: / / autoflow.woa.com / workflow / playbook / manage / read / 151458. At this time, the user can click this execution status check link to check the execution status.
[0066] In some embodiments, the method further includes jumping to an execution status confirmation interface in response to a trigger operation on the execution status confirmation link, and clearly indicating the execution status of the target task in the execution status confirmation interface.
[0067] Optionally, when execution of the target task starts, an execution status check link for the target task is displayed in the interactive task generation interface. In response to a trigger operation on the execution status check link, the computer device jumps to the execution status check interface and clearly shows the execution status of the target task in the execution status check interface. Every time the computer device executes an atomic task of the target task, it clearly shows a task execution flowchart of the target task being executed in the execution status check interface and displays a completion mark on a figure corresponding to an atomic task that has been executed.
[0068] 3C is a schematic diagram of an execution status check interface in one embodiment. The completion marks are shown in FIG. 3C, and the currently executed atomic tasks are the trigger atomic task "Trigger at 6 PM" and the executable atomic task "Get today's day of the week." The completion marks are displayed on the images corresponding to these two atomic tasks. For unexecuted atomic tasks such as "Conditional judgment," "Remind weekly report," and "Remind daily report," the corresponding completion marks are not clearly displayed in the execution status check interface.
[0069] In this embodiment, a link to check the execution status of the target task is displayed in the interactive task generation interface, and a trigger operation on the link can be performed to quickly jump to the execution status check interface, thereby displaying the execution status of the target task in real time in the execution status check interface, allowing the user to grasp the current execution status in a timely manner and improving the user experience.
[0070] The above-described task generation method based on a large-scale language model receives task requirement information input through an interactive task generation interface, directly invokes the large-scale language model, inputs the task requirement information into the large-scale language model, performs semantic understanding of the task requirement information using the large-scale language model, and automatically obtains an executable structure for a target task consistent with the task requirement information. Graphic rendering is performed for the target task based on the executable structure of the target task to obtain a task execution flowchart for the target task, and the task execution flowchart is displayed in the task generation interface. The target task is composed of at least one target atomic task, so detailed information about the generated target task can be intuitively displayed. A target task execution status check link is displayed in the task generation interface, which can be used to check the execution status of the target task, allowing timely and intuitive confirmation of the execution status. In other words, a task can be automatically generated by simply providing task requirement information without complex operations by the user, simplifying the task generation procedure and improving task generation efficiency.
[0071] In some embodiments, invoking the large-scale language model includes generating invocation parameters based on the task requirement information and the presentation corpus, constructing a model invocation request based on the invocation parameters, and invoking the large-scale language model based on the model invocation request.
[0072] Optionally, if the invocation of the large-scale language model is a first time, the computing device combines the task requirement information and the presentation corpus to obtain invocation parameters for the first time, and constructs a model invocation request for the first time based on the invocation parameters for the first time, and the computing device invokes the large-scale language model based on the model invocation request for the first time.
[0073] If the invocation of the large-scale language model is not the first time, the computer device obtains the previous output result output in the previous invocation, and combines the task requirement information, the presentation corpus, and the previous output result to obtain invocation parameters for the current invocation (not the first invocation).The computer device constructs a model invocation request for the current invocation based on the invocation parameters of the current invocation.The computer device invokes the large-scale language model based on the model invocation request for the current invocation.
[0074] If the large-scale language model is not being called for the first time, the output result of the previous call is used as the context information for the current call, and the executable structure for the current call is determined in combination with the context information, thereby improving the accuracy and reliability of target task generation.
[0075] The large-scale language model provides an external interface via a Hypertext Transfer Protocol (HTTP) call method, so the model call request is an HTTP request. The model call request is constructed by directly writing the call parameters into the HTTP request body. After understanding and prediction by the large-scale language model, the executable structure of the target task is returned to the computing device via an HTTP response message.
[0076] If the computing device is a terminal, after obtaining the model invocation request, the terminal sends the model invocation request to a server, and invokes the large-scale language model based on the model invocation request through the server.
[0077] In this embodiment, invocation parameters are generated based on the task requirement information and the presentation corpus, and a model invocation request for invoking a large-scale language model based on the invocation parameters is constructed. The large-scale language model is invoked based on the model invocation request, and at least one target atomic task consistent with the task requirement information is obtained. Furthermore, the executable structure of the target task can be automatically obtained based on the executable structure of the at least one target atomic task, thereby simplifying the task generation procedure and allowing the user to automatically complete the task by simply providing the task requirement information, without performing complex operations, thereby improving the efficiency of task generation.
[0078] In some embodiments, performing semantic understanding using a large-scale language model based on the task requirement information and the presentation corpus to obtain at least one target atomic task consistent with the task requirement information includes sequentially determining, using the large-scale language model, at least one target atomic task consistent with the task requirement information based on the task requirement information and the presentation corpus.
[0079] Here, each atomic task has a unique corresponding atomic task identifier.
[0080] Optionally, the computer device sequentially determines at least one target atomic task that is consistent with the task requirement information by invoking the large-scale language model at least once based on the task requirement information and the presentation corpus. If the number of target atomic tasks is one, the computer device automatically defaults the execution order of the target atomic task to the first one, determines an executable structure of the target atomic task from the presentation corpus, and sets the executable structure of the target atomic task as the executable structure of the target task. If the number of target atomic tasks is multiple, the computer device determines the execution order of each target atomic task. Thereafter, the computer device determines the executable structure of the target task according to the execution order of each target atomic task to render the target task, and can also execute the target task according to the execution order of each target atomic task.
[0081] In this embodiment, the large-scale language model is used to sequentially determine at least one target atomic task that is consistent with the task requirement information based on the task requirement information and the presentation corpus, i.e., to determine the order of the at least one target atomic task required to realize the requirements of the workflow, and then combine the executable structures of each target atomic task based on the next atomic task identifier indicated by each executable structure of the target atomic task to obtain an executable structure of the target task that is consistent with the task requirement information. This allows problem analysis and process design of the task requirement information to be automatically performed based on the large-scale language model, and the order of the executable structures of each target atomic task to be determined without the need for coding, thereby significantly improving the efficiency of target task generation.
[0082] In some embodiments, obtaining an executable structure of the target task that is consistent with the task requirement information based on the executable structure of the at least one target atomic task includes combining the executable structures of each target atomic task based on a next atomic task identifier indicated by each executable structure of the target atomic task to obtain an executable structure of the target task that is consistent with the task requirement information.
[0083] Optionally, for each target atomic task, the computer device determines the next target atomic task after the target atomic task in the execution order based on the next atomic task identifier indicated by the structure of the target atomic task, adds the executable structure of the next target atomic task to the currently combined executable structure to obtain the currently combined executable structure, and obtains the combined executable structure when the combination of the executable structures of all target atomic tasks is completed. As can be understood, the combined executable structure includes the executable structures of all target atomic tasks. The computer device sets the combined executable structure as the executable structure of the target task that is consistent with the task requirement information.
[0084] Note that, taking the executable structure of atomic tasks shown in Table 2 above as an example, the executable structure of each atomic task includes the next atomic task identifier (i.e., nextid) of the next atomic task following the atomic task and the previous atomic task identifier (preid) of the previous atomic task preceding the atomic task. Therefore, for each target atomic task related to a target task, the next atomic task identifier indicated by the executable structure of the target atomic task can be understood as the next atomic task identifier of the next target atomic task following the target atomic task. As can be seen, the execution order of each target atomic task can be known by selecting the next target atomic task that follows the target atomic task in the execution order from among the multiple atomic tasks related to the target task based on the next atomic task identifier indicated by the executable structure of each target atomic task.
[0085] For example, after determining m target atomic tasks that match the task requirement information, the computer device determines the execution order of each target atomic task based on the next atomic task identifier indicated by the executable structure of each target atomic task. The execution order is from target atomic task 1 to target atomic task m, where target atomic task 1 is the first atomic task to be executed and target atomic task m is the last atomic task to be executed. As a result, the computer device combines the executable structure of target atomic task 1, the executable structure of target atomic task 2, ..., the executable structure of target atomic task m in this order to obtain the executable structure of the target tasks.
[0086] In this embodiment, the large-scale language model is used to sequentially determine at least one target atomic task that is consistent with the task requirement information based on the task requirement information and the presentation corpus, i.e., to determine the order of the at least one target atomic task required to realize the workflow requirements, and to combine the executable structures of each target atomic task based on the next atomic task identifier indicated by each executable structure of the target atomic task to obtain an executable structure of the target task that is consistent with the task requirement information. In this way, problem analysis and process design of the task requirement information can be automatically performed based on the large-scale language model, and the order of the executable structures of each target atomic task can be determined without the need for coding, thereby greatly improving the efficiency of task generation.
[0087] In some embodiments, the step of sequentially determining, by the large-scale language model, at least one target atomic task that is consistent with the task requirement information based on the task requirement information and the presentation corpus includes: decomposing, by the large-scale language model, the task requirement information into a plurality of sub-requirement information; for each piece of sub-requirement information, sequentially determining, based on the sub-requirement information and the presentation corpus, a target atomic task that is consistent with the sub-requirement information; and determining, based on the target atomic task that is consistent with each piece of sub-requirement information, the at least one target atomic task that is consistent with the task requirement information.
[0088] Here, the task requirement information corresponds to one original task, and the original task generates a target task corresponding to the task requirement information. The large-scale language model can be invoked multiple times, correspondingly decomposing the task requirement information into multiple levels. For example, in the first invocation, the task requirement information is decomposed a first time to obtain the subrequirement information at level 2. In the second invocation, the subrequirement information at level 2 is decomposed a second time to obtain the subrequirement information at level 3, ..., and in the xth invocation, the subrequirement information at level x is decomposed a x time to obtain the subrequirement information at level x+1. 0≦x≦n, x and n are both non-negative integers, and x is 0. The subrequirement information includes the subrequirement information at the corresponding level at each decomposition. For example, the subrequirement information includes the subrequirement information at level 2, ..., and the subrequirement information at level n+1 obtained by the final decomposition can be considered as atomic requirement information, that is, the atomic requirement information is information corresponding to an atomic task. By calling the large-scale language model at least once, task requirement information can be divided into combinations of atomic requirement information, which are the smallest information units.
[0089] Optionally, the computer device decomposes the task requirement information into a plurality of sub-requirement information by invoking the large-scale language model at least once, each of the sub-requirement information having a corresponding execution number. For each of the sub-requirement information, determine a target atomic task corresponding to the sub-requirement information based on the sub-requirement information and the presentation corpus, and determine an execution order of the target atomic tasks based on the execution numbers of the sub-requirement information. The computer device determines at least one target atomic task consistent with the task requirement information based on the target atomic task consistent with each of the sub-requirement information.
[0090] For example, the computer device invokes the large-scale language model n times to decompose the task requirement information into level n+1 subrequirement information, with each level of subrequirement information including at least one subrequirement information of that level. From the level n+1 subrequirement information, for each of the level n+1 subrequirement information, the computer device determines at least one target atomic task for the level n subrequirement information based on the target atomic task that matches the level n+1 subrequirement information. For each of the level n subrequirement information, the computer device determines at least one target atomic task for the level n-1 subrequirement information based on the target atomic task that matches the level n subrequirement information, and similarly obtains target atomic tasks that match each of the level 2 subrequirement information. The computer device determines at least one target atomic task that matches the task requirement information based on each target atomic task that matches the level 2 subrequirement information.
[0091] In this embodiment, a large-scale language model is used to decompose task requirement information into multiple sub-requirement information, i.e., to convert the task requirement information into requirement information with the smallest information unit. For each sub-requirement information, a target atomic task consistent with the sub-requirement information is sequentially determined based on the sub-requirement information and the presented corpus, and the original task corresponding to the task requirement information is subdivided into target atomic tasks with the smallest task unit. In this way, at least one target atomic task consistent with the task requirement information is determined based on the target atomic task consistent with each sub-requirement information, and then the executable structure of the target task can be automatically and accurately output. This simplifies the task generation procedure, allowing users to automatically complete tasks without complex operations by simply providing the task requirement information, thereby improving task generation efficiency.
[0092] In some embodiments, as shown in Figure 4, a flowchart of a target atomic task determination step in one embodiment is shown. The step of decomposing task requirement information into multiple sub-requirement information using a large-scale language model and sequentially determining a target atomic task that is consistent with each sub-requirement information based on the sub-requirement information and a presentation corpus includes the following steps:
[0093] Step S402: Using the large-scale language model, obtain a level 1 prediction result based on the task requirement information and the presented corpus, and perform feasibility verification on the level 1 prediction result to obtain a level 1 verification result.
[0094] Here, the prediction result of level 1 is the prediction result obtained by the first invocation of the large-scale language model. Executable verification is used to verify whether the prediction result is an executable structure. If the executable verification of the prediction result of level i passes, the prediction result of level i includes the prediction result of level i-1, which precedes the prediction result of level i. Since the executable verification of the prediction result of level i-1 does not pass, the prediction result of level i-1 includes a target atomic task that is consistent with the atomic requirement information. In this case, the prediction result of level i also includes an executable structure corresponding to the target atomic task that is consistent with the atomic requirement information. In summary, if the executable verification of the prediction result of level i passes, the prediction result of level i includes a target atomic task that is consistent with the atomic requirement information and an executable structure corresponding to the target atomic task that is consistent with the atomic requirement information.
[0095] Optionally, the computing device outputs a level 1 prediction result based on the task requirement information and the presentation corpus by a first invocation of the large-scale language model. If the computing device verifies that the format of the level 1 prediction result is correct, it performs executable verification on the level 1 prediction result to obtain a level 1 verification result. The level 1 verification result represents a result obtained by performing executable verification on the level 1 prediction result.
[0096] For example, after obtaining a level 1 prediction result, the computer device performs formal verification on the level 1 prediction result. If the corresponding formal verification result indicates a pass, the computer device performs executable verification on the level 1 prediction result and returns to the step of obtaining the level 1 verification result for execution. Formal verification is used to verify whether the prediction result is a structure. If the corresponding formal verification result indicates a pass, it means that the level 1 prediction result is a structure and the format of the structure is valid. If the formal verification result indicates a fail, it means that the level 1 prediction result is not a structure or is an invalid structure. In this case, the computer device does not need to perform executable verification on the level 1 prediction result. The computer device directly decomposes task requirement information into multiple level 2 sub-requirement information.
[0097] Step S404: If the level 1 verification result indicates that the level 1 prediction result does not contain an executable structure, decompose the task requirement information into multiple level 2 sub-requirement information, and for each of the level 2 sub-requirement information, use a large-scale language model to output a level 2 prediction result based on the level 2 sub-requirement information, the presentation corpus, and the level 1 prediction result, perform executable verification on the level 2 prediction result, and obtain a level 2 verification result, and if the level 2 verification result indicates that the level 2 prediction result contains an executable structure, determine that the level 2 prediction result has passed the executable verification, and obtain a target atomic task consistent with the level 2 sub-requirement information based on the level 2 prediction result.
[0098] Optionally, if the level 1 verification result indicates that the level 1 prediction result does not include an executable structure, the computer device decomposes the task requirement information into multiple level 2 sub-requirements information. The computer device invokes the large-scale language model a second time and inputs each level 2 sub-requirements information, the presentation corpus, and the level 1 prediction result into the large-scale language model. For each level 2 sub-requirements information, the computer device outputs a level 2 prediction result based on the level 2 sub-requirements information, the presentation corpus, and the level 1 prediction result using the large-scale language model. If the computer device verifies that the format of the level 2 prediction result is correct, it performs executable verification on the level 2 prediction result to obtain a level 2 verification result. The level 2 verification result represents a result obtained by performing executable verification on the level 2 prediction result. If the level 2 prediction result passes the executable verification, the computer device obtains a target atomic task that is consistent with the level 2 sub-requirements information based on the level 2 prediction result.
[0099] For example, after obtaining a level 2 prediction result, the computer device performs formal verification on the level 2 prediction result. If the corresponding formal verification result indicates a pass, the computer device performs executable verification on the level 2 prediction result and returns to the step of obtaining the level 2 verification result for execution. If the corresponding formal verification result indicates a pass, it means that the level 2 prediction result is a structure and the format of the structure is valid. If the corresponding formal verification result indicates a fail, it means that the level 2 prediction result is not a structure or is an invalid structure. In this case, the computer device does not need to perform executable verification on the level 2 prediction result. The computer device directly decomposes the level 2 sub-requirement information into multiple level 3 sub-requirement information.
[0100] In this embodiment, a large-scale language model outputs a level 1 prediction result based on task requirement information and a presentation corpus, and performs executable verification on the level 1 prediction result to verify whether the level 1 prediction result contains an executable structure for the target atomic task. If the level 1 verification result indicates that the level 1 prediction result does not contain an executable structure, this indicates that the large-scale language model needs to be called again. Before that, the task requirement information needs to be decomposed into multiple level 2 sub-requirements. For each level 2 sub-requirement, the large-scale language model outputs a level 2 prediction result based on the level 2 sub-requirements, the presentation corpus, and the level 1 prediction result. Then, executable verification is performed again on the level 2 prediction result. If the level 2 prediction result passes the executable verification, a target atomic task consistent with the level 2 sub-requirements is obtained based on the level 2 prediction result. This allows the original task corresponding to the task requirement information to be subdivided into target atomic tasks with the smallest task unit, and the executable structure of the target task can be automatically and accurately output. The procedure for task generation is simplified, and the user only needs to provide task requirement information to automatically complete the task without performing any complicated operations, thereby improving the efficiency of task generation.
[0101] In some embodiments, the method further includes, when the level 1 verification result indicates that the level 1 prediction result includes an executable structure, obtaining a target atomic task that is consistent with the task requirement information based on the level 1 prediction result.
[0102] Note that when the level 1 verification result indicates that an executable structure is included in the level 1 prediction result, it means that the task corresponding to the task requirement information is the target atomic task. In this case, as described above, when the level 1 verification result corresponding to the level 1 prediction result indicates a pass, the level 1 prediction result includes a target atomic task that is consistent with the atomic requirement information (in this embodiment, the atomic requirement information is task requirement information) and an executable structure that corresponds to the target atomic task that is consistent with the atomic requirement information.
[0103] In this embodiment, if the verification result of level 1 indicates that the prediction result of level 1 contains an executable structure, a target atomic task that is consistent with the task requirement information is directly obtained based on the prediction result of level 1. That is, at this time, the task corresponding to the task requirement information is the target atomic task, so it is possible to quickly and accurately determine that the executable structure of the target atomic task is the executable structure of the target task without performing complex coding operations, thereby simplifying the process of obtaining the executable structure and improving the efficiency of target task generation.
[0104] In some embodiments, determining at least one target atomic task consistent with the task requirement information based on the target atomic task consistent with each of the sub-requirements information includes: obtaining a target atomic task consistent with each of the level-2 sub-requirements information and obtaining a decomposition order of each of the level-2 sub-requirements information; and concatenating the target atomic tasks consistent with each of the level-2 sub-requirements information according to the decomposition order of each of the level-2 sub-requirements information to obtain at least one target atomic task consistent with the task requirement information.
[0105] Here, for each piece of level 2 sub-requirement information, the order of linking target atomic tasks that are consistent with the level 2 sub-requirement information is the order of decomposition of the level 2 sub-requirement information.
[0106] Optionally, the computer device obtains target atomic tasks consistent with each of the level 2 sub-requirements information, and determines a connection order of the target atomic tasks of each of the level 2 sub-requirements information according to a decomposition order of each of the level 2 sub-requirements information. The computer device sequentially connects, from the target atomic task of the initial connection order, the target atomic tasks of each of the level 2 sub-requirements information according to the connection order of the target atomic tasks of each of the level 2 sub-requirements information, to obtain at least one target atomic task consistent with the task requirement information.
[0107] For example, task requirement information P is decomposed into N pieces of level-2 sub-requirement information in the order of level-2 sub-requirement information P2.1, level-2 sub-requirement information P2.2, ..., level-2 sub-requirement information P2.N. Then, the linking order of level-2 subtasks corresponding to each level-2 sub-requirement information is level-2 subtask F2.1 corresponding to level-2 sub-requirement information P2.1, ..., level-2 subtask F2.N corresponding to level-2 sub-requirement information P2.N. In this case, at least one target atomic task consistent with the task requirement information is level-2 subtask F2.1, ..., level-2 subtask F2.N.
[0108] In this embodiment, by obtaining a target atomic task that matches each of the level 2 sub-requirements information, the target atomic tasks that match each of the level 2 sub-requirements information can be quickly linked according to the decomposition order of each of the level 2 sub-requirements information based on the corresponding decomposition order to obtain at least one target atomic task that matches the task requirement information, and then the executable structure of the target task can be automatically and accurately output. This simplifies the task generation procedure, allowing the user to simply provide the task requirement information and automatically complete the task without performing complex operations, thereby improving the efficiency of task generation.
[0109] In some embodiments, the method further includes, if the level-2 verification result corresponding to the level-2 sub-requirements information does not pass the executable verification, decomposing the level-2 sub-requirements information into multiple level-3 sub-requirements information, and for each of the level-3 sub-requirements information, outputting a level-3 prediction result based on the level-3 sub-requirements information, the presentation corpus, and the level-2 prediction result corresponding to each of the level-2 sub-requirements information using a large-scale language model, performing executable verification on the level-3 prediction result to obtain a level-3 verification result, and if the level-3 verification result indicates that the level-3 prediction result contains an executable structure, determining that the level-3 prediction result passes the executable verification, and obtaining a target atomic task consistent with the level-3 sub-requirements information based on the level-3 prediction result.
[0110] Optionally, if the level-2 prediction result corresponding to the level-2 sub-requirements information does not pass the executable verification, the computer device decomposes the level-2 sub-requirements information into multiple level-3 sub-requirements information. For each of the level-3 sub-requirements information, the computer device invokes the large-scale language model again and inputs the level-3 sub-requirements information, the presentation corpus, and the level-2 prediction result corresponding to each of the level-2 sub-requirements information into the large-scale language model. For each of the level-3 sub-requirements information, the computer device outputs a level-3 prediction result corresponding to the level-3 sub-requirements information based on the level-3 sub-requirements information, the presentation corpus, and the level-2 prediction result corresponding to the level-2 sub-requirements information using the large-scale language model. If the computer device verifies that the format of the level-3 prediction result is correct, it performs executable verification on the level-3 prediction result and obtains a level-3 verification result. If the level-3 verification result indicates that the corresponding level-3 prediction result passes the executable verification, the computer device obtains a target atomic task consistent with the level-3 sub-requirements information based on the level-3 prediction result.
[0111] Each time a large-scale language model is invoked, the prediction result generated in that invocation must be stored in a vector database as context information for the next invocation. For example, as mentioned above, the level 1 prediction result generated in the first invocation serves as context information for the level 2 prediction result generated in the second invocation, and the level 2 prediction result generated in the second invocation serves as context information for the level 3 prediction result generated in the third invocation. As mentioned above, each invocation of a large-scale language model may generate lower-level subtasks (i.e., tasks lower than the subtasks corresponding to the sub-requirements information of the level corresponding to the previous invocation). Therefore, the storage structure for retrieving and recording the context information is in the form of a multi-level vector. FIG. 5 is a schematic diagram of a storage structure of a multi-level vector in one embodiment. The original task is the task corresponding to the task requirement information. After the first invocation of the large-scale language model, if the format of the level 1 prediction result is invalid or the feasibility verification fails, the task requirement information is decomposed into level 2 sub-requirements information P2.1 to P2.N. After the second invocation of the large-scale language model, if the level-2 prediction result is invalid or fails the executable verification, each level-2 subrequirement is decomposed. For example, level-2 subrequirement P2.1 is decomposed into level-3 subrequirement P2.1.1 through level-3 subrequirement P2.1.M, and level-2 subrequirement P2.N is decomposed into level-3 subrequirement P2.N.1 through level-3 subrequirement P2.NK. The multi-level vector storage structure allows for a clear description of the hierarchical analysis and decomposition process of the problem. Subsequently, by simply invoking the context information during repeated invocations of the large-scale language model, the executable structure of the target task can be more accurately obtained.
[0112] Of course, if the predicted result at level 3 has an invalid format or fails to pass the executable verification, it means that the subrequirements information at level 3 is not the smallest information unit. The subrequirements information at level 3 can be continuously decomposed until the predicted result at level i corresponding to the subrequirements information at level i passes the executable verification. At this time, the subrequirements information at level i can be regarded as the smallest information unit, that is, the corresponding task is the target atomic task that is consistent with the subrequirements information at level i.
[0113] For example, if the format of the level 3 prediction result is verified to be invalid, the computer device directly determines that the level 3 prediction result does not contain an executable structure. At this time, the computer device continues to decompose the level 3 subrequirements information to obtain at least one level 4 subrequirements information, and inputs the at least one level 4 subrequirements information, the presentation corpus, and the level 3 prediction result corresponding to the level 3 subrequirements information into a large-scale language model to obtain a corresponding level 4 prediction result. If the format of the level 4 prediction result is verified to be valid, the computer device performs executable verification on the level 4 prediction result to obtain a level 4 verification result. If the level 4 verification result indicates that the corresponding level 3 prediction result passes the executable verification, the computer device obtains a target atomic task consistent with the level 4 subrequirements information based on the level 4 prediction result.
[0114] That is, a prediction result corresponding to the current decomposition is determined by a large-scale language model based on the corresponding sub-requirements information obtained in the current decomposition, the presented corpus, and the verification result obtained in the previous decomposition. If the prediction result corresponding to the current decomposition is valid and includes an executable structure, a target atomic task of the sub-requirements information corresponding to the current decomposition is obtained from the prediction result corresponding to the current decomposition.
[0115] If the prediction result corresponding to the current decomposition is invalid or does not include an executable structure, the corresponding subrequirements information obtained in the current decomposition is continued to be decomposed until the target atomic task is obtained. Referring to the above example, if the current decomposition is the first decomposition, it can be understood that the corresponding subrequirements information obtained in the current decomposition is subrequirements information of level 2, and the prediction result corresponding to the current decomposition is the prediction result of level 2. If the current decomposition is the second decomposition, the corresponding subrequirements information obtained in the current decomposition is subrequirements information of level 3, and the prediction result corresponding to the current decomposition is the prediction result of level 3. If the current decomposition is the third decomposition, the corresponding subrequirements information obtained in the current decomposition is subrequirements information of level 4, and the prediction result corresponding to the current decomposition is the prediction result of level 4.
[0116] In this embodiment, if the level-2 verification result corresponding to the level-2 subrequirements information fails the executable verification, the large-scale language model must be invoked a third time. Before that, the level-2 subrequirements information must be decomposed into multiple level-3 subrequirements information, i.e., the level-2 subrequirements information must be further subdivided. For each level-3 subrequirements information, the large-scale language model outputs a level-3 prediction result based on the level-3 subrequirements information, the presentation corpus, and the level-2 prediction results corresponding to each level-2 subrequirements information. Then, executable verification is performed on the level-3 prediction result. If the level-3 prediction result passes the executable verification, it means that the level-3 subrequirements information has been subdivided into the smallest information units. This allows a target atomic task consistent with the level-3 subrequirements information to be obtained based on the level-3 prediction result. That is, the original task corresponding to the task requirement information is subdivided into target atomic tasks of the smallest task units, thereby automatically and accurately outputting the executable structure of the target task. The procedure for task generation is simplified, and a task can be automatically generated without the user having to perform complex operations by simply providing task requirement information, thereby improving the efficiency of task generation.
[0117] In some embodiments, determining at least one target atomic task consistent with the task requirement information based on the target atomic task consistent with each of the sub-requirements information includes: obtaining a target atomic task consistent with each of the level-3 sub-requirements information, and obtaining a decomposition order of each of the level-3 sub-requirements information and a decomposition order of each of the level-2 sub-requirements information; concatenating the target atomic tasks consistent with each of the level-3 sub-requirements information according to the decomposition order of each of the level-3 sub-requirements information to obtain at least one target atomic task consistent with the level-2 sub-requirements information; and concatenating the target atomic tasks consistent with each of the level-2 sub-requirements information according to the decomposition order of each of the level-2 sub-requirements information to obtain at least one target atomic task consistent with the task requirement information.
[0118] Here, for each piece of level 3 sub-requirement information, the connection order of target atomic tasks that are consistent with the level 3 sub-requirement information is the decomposition order of the level 2 sub-requirement information in the second decomposition. For each piece of level 2 sub-requirement information, the connection order of target atomic tasks that are consistent with the level 2 sub-requirement information is the decomposition order of the level 2 sub-requirement information in the three decompositions.
[0119] Optionally, the computer device determines a connection order of target atomic tasks consistent with each of the level-3 sub-requirement information according to a decomposition order of each of the level-3 sub-requirement information in the second decomposition. For each of the level-2 sub-requirement information, the computer device sequentially connects, starting from the target atomic task in the initial first connection order, the target atomic tasks of each of the level-3 sub-requirement information according to the connection order of each of the target atomic tasks of each of the level-3 sub-requirement information, to obtain at least one target atomic task of the level-2 sub-requirement information. The computer device sequentially connects, starting from the target atomic task in the initial second connection order, the target atomic task of each of the level-2 sub-requirement information according to the connection order of each of the target atomic tasks of each of the level-2 sub-requirement information, to obtain at least one target atomic task consistent with the task requirement information. The first connection order refers to the first connection order of each target atomic task consistent with the level-3 sub-requirement information, and the second connection order refers to the first connection order of each target atomic task consistent with the level-2 sub-requirement information.
[0120] For example, taking FIG. 5 as an example, for level 2 sub-requirement information P2.1, level 3 sub-requirement information P2.1.1 to level 3 sub-requirement information P2.1.M correspond, and the computer device connects each target atomic task that is consistent with the level 3 sub-requirement information according to the connection order, i.e., connects subtask 1.1, ..., subtask 1.n sequentially, to obtain each target atomic task that is consistent with the level 2 sub-requirement information P2.1, i.e., subtask 1.1, ..., subtask 1.n (subtask 1.1, ..., subtask 1.n are respectively target atomic tasks that are consistent with level 3 sub-requirement information P2.1.1, ..., target atomic tasks that are consistent with level 3 sub-requirement information P2.1.M). Similarly, the target atomic tasks of the level 3 sub-requirement information of other level 2 sub-requirement information are concatenated to obtain each target atomic task that matches with the level 2 sub-requirement information P2.N, i.e., subtask n.1, ..., subtask nn, etc. For task requirement information, since level 2 sub-requirement information P2.1 to level 2 requirement information P2.N correspond, each target atomic task that matches with the task requirement information is subtask 1.1, ..., subtask 1.n, ..., subtask n.1, ..., subtask nn.
[0121] In this embodiment, target atomic tasks that match each level-3 subrequirement information item are linked in the corresponding decomposition order to obtain at least one target atomic task that matches the corresponding level-2 subrequirement information item. The result of linking target atomic tasks for multiple level-3 subrequirement information items corresponding to the same level-2 subrequirement information item is used to determine at least one target atomic task for the level-2 subrequirement information item at a higher level. Target atomic tasks that match each level-2 subrequirement information item are linked in the corresponding decomposition order to obtain at least one target atomic task that matches the task requirement information item. That is, the target atomic tasks are linked stepwise, starting with the target atomic task corresponding to the smallest information unit, until all the sequentially linked target atomic tasks are obtained. Then, each target atomic task is executed sequentially in the linkage order of the target atomic tasks, thereby automatically achieving the execution of the target tasks.
[0122] In some embodiments, as shown in FIG. 6, a flowchart of generating an executable structure for a target task in one embodiment is shown. After acquiring task requirement information and a presentation corpus, if the large-scale language model is being invoked for the first time, invocation parameters are generated based on the task requirement information and the presentation corpus, the invocation parameters are input into the large-scale language model, a level 1 prediction result is obtained, and an executable verification is performed on the level 1 prediction result. If the level 1 verification result indicates that the level 1 prediction result does not contain an executable structure, i.e., is unexecutable, or if the format of the level 1 prediction result is invalid, the task requirement information is decomposed into multiple level 2 sub-requirement information, and these are stored in a database in the form of a multi-level vector as context information for the second invocation of the large-scale language model. If the format of the level 1 prediction result is verified to be valid and the level 1 verification result indicates that the level 1 prediction result contains an executable structure, the result is output, i.e., the executable structure for the target task is output.
[0123] If the current call is not the first call of the large-scale language model, the computer device obtains context information of the current call (for example, if the current call is the second call, the context information of the current call is level 2 sub-requirement information, and if the current call is the third call, the context information of the current call is level 3 sub-requirement information), and uses the context information of the current call, the presented corpus, and the level prediction result corresponding to the previous call as the call parameters of the current call (if the current call is the second call, the level prediction result corresponding to the previous call is a level 1 prediction result, and if the current call is the third call, the level prediction result corresponding to the previous call is a level 2 prediction result), and inputs the call parameters of the current call into the large-scale language model to obtain a level prediction result of the current call (if the current call is the second call, the level prediction result of the current call is a level 2 prediction result, and if the current call is the third call, the level prediction result of the current call is a level 3 prediction result, and so on). If the level prediction result of the current call fails to pass both formal verification and executable verification, the context information of the current call is decomposed, the decomposition result of the current call is obtained, and the decomposition result of the current call (e.g., if the current call is the second time, the decomposition result of the current call is the sub-requirement information of level 3) is stored in the database as the context information of the next call in the form of a multi-level vector, and this process is repeated until an executable structure is obtained.
[0124] In this embodiment, task requirement information is input into an interactive task generation interface, and a user can directly input the workflow requirement information into the interactive task generation interface. A presentation corpus constructed for the workflow is acquired. The presentation corpus includes presentation information constructed for each atomic task of the workflow, and the presentation information includes executable structures and operation information of the atomic tasks. A large-scale language model performs semantic understanding based on the task requirement information and the presentation corpus to automatically and accurately obtain at least one target atomic task consistent with the task requirement information. Based on the executable structures of the at least one target atomic task, an executable structure of the target task consistent with the task requirement information can be automatically and accurately output. This simplifies the task generation procedure, allowing users to automatically complete tasks by simply providing task requirement information without performing complex operations, thereby improving task generation efficiency.
[0125] In some embodiments, the method includes, when triggering an execution instruction to execute the target task, creating a task instance for the target task, the task instance including at least one subtask instance, the subtask instance being used to execute a corresponding target atomic task; and sequentially executing each subtask instance, starting from a first subtask instance of the task instance, based on the executable structure of the subtask instance.
[0126] Here, a target task corresponds to one task instance, and a task instance is a specific target task instance. A task instance includes subtask instances corresponding to each target atomic task. Each target atomic task uniquely corresponds to one subtask instance. Because one target atomic task can be executed using various parameters, a subtask instance can be understood as a process of executing the target atomic task using specific parameters. The executable structure of a subtask instance is the executable structure of the corresponding target atomic task. That is, the actual execution process of the target atomic task is performed in conjunction with the corresponding executable structure based on the specific parameters used for the corresponding subtask instance.
[0127] Optionally, after obtaining the executable structure of the target task, the computing device can directly trigger an execution instruction to execute the target task. The computing device creates a task instance for the target task, where the task instance includes at least one subtask instance corresponding to at least one target atomic task required to generate the target task.
[0128] Optionally, after obtaining the executable structure of the target task, the computing device may also store the executable structure of the target task and trigger an execution instruction to execute the target task after a preset time has elapsed. The computing device creates a task instance for the target task.
[0129] Optionally, after obtaining the executable structure of the target task, the computing device triggers an execution instruction to execute the target task in response to a trigger operation on the target task. The computing device creates a task instance for the target task.
[0130] After creating a task instance for the target task as described above, the computing device executes the subtask instances based on the executable structures of the subtask instances, starting from the first subtask instance of the task instance, to complete the target atomic task corresponding to the subtask instance.
[0131] In this embodiment, when an execution command to execute a target task is triggered, a task instance for the target task is first created. This allows the subtask instances of the corresponding target atomic task to be determined. Therefore, starting from the first subtask instance of the task instance, each subtask instance is executed sequentially based on the executable structure of the subtask instance. This allows the target task to be executed in order, ensuring the accuracy of the execution of the target task.
[0132] In some embodiments, after creating a task instance for the target task, the method further includes creating a task instance corresponding to the target task in a task instance table of a database, where the task instance table is used to record a task instance identifier, a process data structure of the task instance, and the process data structure includes subtask instance identifiers and directional relationships between each subtask instance; pushing the task instance identifier of the created task instance onto a task instance message queue; and, after consuming the task instance identifiers from the task instance message queue, executing each subtask instance sequentially based on the executable structure of the subtask instance, starting with the first subtask instance of the task instance.
[0133] Here, the process data structure of a task instance can be understood as the executable structure of the target task. A task instance corresponding to a target task created in the task instance (execution) table of the database includes a task instance identifier, a process data structure of the task instance, and other related information about the task instance, including the target task identifier, the execution state of the task instance, the start and end times of the task instance execution, and the executor who triggered the execution of the task instance. The process data structure of a task instance records the execution process of the task instance, i.e., the directional relationships between each subtask instance. A computing device sequentially loads and executes each subtask instance, i.e., traverses and executes them based on the directional relationships between the subtask instances included in the process data structure. Each subtask instance corresponds to one target atomic task. The execution relationship of subtask instance 2 reflects which subtask instance precedes subtask instance 2 and which subtask instance follows subtask instance 2.
[0134] Illustratively, each task instance in the Task Instances table includes the following fields: id: Task instance identifier workflow_id:Workflow identifier name: name executor: executor status: Task instance execution status start_at:start time end_at:End time apps: the executable structure for task instances Here, the executable structure of a task instance can include the following information: StartAppInstId: Start subtask instance DestAppInstId: The ending subtask instance Apps: An array of subtask instances, where each subtask instance contains the following information: Name: Name or description of the subtask instance Parameters: The parameters of the subtask instance (including the parameter, parameter value, parameter type, and parameter description). Template: The subtask template (e.g., HTTP request or Python script) used for the subtask instance. Position: The coordinate position of the subtask instance on the front-end canvas. InstId: Subtask instance identifier PrevAppInstIds: Identifiers of the previous subtask instance to be pointed to NextAppInstIds: Identifiers of the next subtask instances to target Output: Output result of subtask instance Error: Error message if an error occurs during execution of a subtask instance. Status: Execution status of the subtask instance StartTime: The start time of the subtask instance execution. EndTime: The end time of the subtask instance execution
[0135] It can be seen that a task instance includes multiple subtask instances, and each of the subtask instances has a unique identifier for identifying which subtask instance of the task instance it is.
[0136] Optionally, upon receiving an execution instruction to trigger a target task, the computer device creates a corresponding task instance, including related information such as a task instance identifier, an executor of the task instance, a process data result of the task instance, and a state of the task instance, and persistently stores the created task instance in a task instance table of a database. Then, the computer device pushes the task instance identifier corresponding to the task instance to a task instance message queue. For example, the message format in the queue is RPUSH execution#queue executionId. The distributed execution node consumes the task instance identifier from the task instance message queue, reads the task instance table of the database based on the consumed task instance identifier, obtains the task instance corresponding to the task instance identifier, and reads related information of the task instance before starting execution of the task instance.
[0137] FIG. 7 is a schematic diagram of a task instance message queue in one embodiment. As shown in FIG. 7, in a workflow scenario, each time execution of a workflow is triggered, a corresponding task instance is created in a task instance table of a database, and a task instance identifier corresponding to the created task instance is pushed to a task instance message queue. A computer device monitors the task instance message queue. Optionally, the task instance message queue is monitored based on each container (e.g., Container 1, Container 2, ..., Container N in the figure, which can be understood as each distributed execution node) in an engine consumption cluster of a distributed workflow engine located on the computer device. When a new task instance identifier is added to the message queue, it is consumed sequentially in first-in, first-out order to execute the corresponding task instance.
[0138] When a task instance of the target task is consumed, each subtask instance is executed sequentially starting from the first subtask instance of the task instance based on the executable structure of the subtask instance.
[0139] In this embodiment, a task instance corresponding to the target task is created in the task instance table of the database. The task instance identifier of the created task instance is pushed to the task instance message queue for consumption. After consuming the task instance identifier from the task instance message queue, it means that the currently executed task is the target task. Therefore, starting with the first subtask instance of the task instance, a step of sequentially executing each subtask instance based on the executable structure of the subtask instance is performed. This allows the target task to be executed in order, ensuring the accuracy of the execution of the target task.
[0140] In some examples, executing each subtask instance sequentially based on the executable structure of the subtask instance, starting with the first subtask instance of the task instance, includes pushing a subtask instance identifier corresponding to the first subtask instance onto a subtask instance message queue; consuming the subtask instance identifier from the subtask instance message queue; loading the corresponding subtask instance based on the subtask instance identifier and executing the corresponding subtask instance; after executing the corresponding subtask instance, determining the subtask instance to which the corresponding subtask instance points; and after pushing the subtask instance identifier corresponding to the pointed-to subtask instance onto the subtask instance message queue, continuing execution back to consuming the subtask instance identifier from the subtask instance message queue until all of the subtask instances of the task instance have been executed.
[0141] 8 is a schematic diagram of a subtask instance message queue in one embodiment. In FIG. 8, taking as an example a task instance including p subtask instances, the computer device pushes the corresponding subtask instance identifier 1 from the first subtask instance of the task instance to the subtask instance message queue and retrieves the subtask instance table for the corresponding subtask instance identifier 1. After consumption by the container, the computer device loads the corresponding subtask instance into memory and executes it. Upon completion of execution, the computer device updates the execution status and execution data of the subtask instance, stores the subtask instance in the corresponding subtask instance table in the database, and retrieves the next subtask instance to be directed. Similarly, the computer device pushes the corresponding subtask instance identifier 2 to the subtask instance message queue. After consumption by the container, the computer device loads the corresponding subtask instance into memory and executes it. Upon completion of execution, the computer device retrieves the next subtask instance to be directed. Similarly, the computer device pushes the corresponding subtask instance identifier p to the subtask instance message queue. After consumption by the container, the computer device loads the subtask instance into memory and executes it. Upon completion of execution, the computer device completes execution of the entire task instance. During execution, each container runs a daemon process to monitor the subtask instance message queue, i.e., the command: BLPOP appinst#queue. As new subtask instance identifiers are added to the message queue, they are consumed sequentially in first-in, first-out order, executing the corresponding subtask instance. The first container to consume will execute the new subtask instance.
[0142] In this embodiment, multiple subtask instances corresponding to a task instance corresponding to a target task are loaded and executed sequentially. If multiple subtask instances include time-consuming subtasks that require external communication, the entire task instance is loaded at once and the execution of the time-consuming subtasks is waited for. This prevents the entire task instance from occupying memory for a long time or consuming execution resources, thereby significantly improving resource utilization efficiency.
[0143] After consuming the subtask instance message queue to obtain the subtask instance to be processed, the computer device updates the data state in the database corresponding to the subtask instance during processing and sets the execution start time. The subtask instance is stored in the corresponding subtask instance table. The fields of each subtask instance table are as follows: id: Auto-increment primary key id, i.e., the application ID of the workflow system execution_id: ID of the task instance to be executed app_inst_id: Subtask instance ID name App:Subtask instance name Template App: The type of template used (e.g. HTTP request, Python script, etc.). Different subtask instance templates support different functionality. status: Subtask instance execution status start_at: The start time of the subtask instance execution. end_at: The end time of the subtask instance execution apps: An executable structure for a subtask instance. It records information such as the execution result of the current subtask instance at a given point in time, the previous subtask instance to be pointed to, the next subtask instance to be pointed to, input parameters, and execution data. The apps field was explained in the previous section, so it will not be repeated here.
[0144] In some embodiments, pushing a subtask instance identifier corresponding to the directed subtask instance onto the subtask instance message queue includes, if the corresponding subtask instance points to multiple subtask instances, pushing all subtask instance identifiers for each of the multiple directed subtask instances onto the subtask instance message queue.
[0145] Here, when the current subtask instance points to multiple subtask instances, which are typically independent of one another and capable of executing in parallel, the computing device can push all subtask instance identifiers for each of the multiple subtask instances pointed to onto the subtask instance message queue.
[0146] In this embodiment, when a corresponding subtask instance points to multiple subtask instances, the subtask instance identifiers of the multiple pointed subtask instances are all pushed to the subtask instance message queue, so that the pointed subtask instances can all be executed based on the subtask instance message queue, ensuring the accuracy and effectiveness of task execution.
[0147] In some embodiments, consuming the subtask instance identifiers from the subtask instance message queue includes, by the distributed execution node, consuming the plurality of subtask instance identifiers from the subtask instance message queue and then loading and executing the corresponding plurality of subtask instances in parallel.
[0148] Here, the distributed execution nodes each consume multiple subtask instance identifiers from the message queue, and then load and execute multiple subtask instances in parallel. For example, if subtask instance A points to subtask instances B and C, and the execution of subtask instances B and C is independent of each other, the computing device can push the two subtask instances into the subtask instance message queue, have distributed execution node 1 consume the identifier of subtask instance B from the message queue, and have execution node 2 consume the identifier of subtask instance C from the message queue. Then, the two subtask instances are executed in parallel on different execution nodes, thereby achieving true parallel loading and execution.
[0149] In this embodiment, when an entire task instance is loaded into memory at once and executed by a specific execution node, it can only execute each subtask instance sequentially based on the directional relationship between the subtask instances of the task instance. Naturally, only one subtask instance can be executed at a time on the same node, and true parallel execution cannot be achieved. In this embodiment, multiple subtask instances of a task instance are divided and loaded and executed sequentially. Therefore, if a subtask instance points to multiple subtask instances, they can be loaded and executed by different distributed execution nodes, thereby achieving true parallel execution.
[0150] In one embodiment, after determining the subtask instance to which the current subtask instance points, the computing device persistently stores the pointed-to subtask instance in a subtask instance table in a database. The subtask instance table is used to record the subtask instance identifier, the execution state and execution data of the subtask instance. The execution state of the subtask instance is initialized to pending. After the subtask instance is executed, the execution state of the subtask instance is updated to completed and the execution data of the subtask instance is updated in the subtask instance table.
[0151] In this embodiment, when a subtask instance is executed, the execution state of the subtask instance in the subtask instance table is updated directly, and the execution data of the subtask instance, such as data output by the execution of the subtask instance, is updated in real time.
[0152] In one embodiment, a workflow processing method includes the steps of: parsing a task instance, obtaining global variables of each subtask instance included therein, and forming and storing a global variable table, where the global variables include global input variables and global output variables; after executing a current subtask instance, updating the global output variables in the global variable table based on corresponding execution data; loading the updated global variable table, obtaining input data corresponding to the global input variables of the directed subtask instance, and executing the directed subtask instance based on the input data.
[0153] When sequentially loading and executing subtask instances of an execution instance of a target task, if the input data of a subtask instance is the output data of a preceding subtask instance that precedes the subtask instance, the preceding subtask instance may be the output data of the subtask instance that precedes the subtask instance, or the preceding subtask instance may be the output data of the two subtask instances that precede the subtask instance. However, because multiple subtask instances of a task instance are divided and sequentially loaded and executed, the output data of each subtask instance cannot be directly transmitted.
[0154] Therefore, to smoothly execute each loaded subtask instance, the computer device analyzes the global variables of each subtask instance of the task instance, forms and stores a global variable table, that is, associates and stores the identifier of each subtask instance with the corresponding global variables (including global input variables and global output variables). As can be understood, when a task instance is not being executed, each variable in the global variable table has a default parameter value. Each time a subtask instance is loaded and executed to obtain execution data, the global variable table is updated based on the execution data. Before executing the directed subtask instance, the computer device loads the previously updated global variable table into memory, reads the global variable table based on the identifier of the directed subtask instance, and obtains input data corresponding to the global input variables of the subtask instance, so that the subtask instance can be executed based on the input data.
[0155] 9 is a schematic diagram of a global variable table in one embodiment. As shown in FIG. 9, the global variables of each subtask instance of the currently processed task instance are loaded into memory to form a mapping table between subtask instance identifiers and global variables.
[0156] Illustratively, the global variables of a subtask instance may use constants. Illustratively, the global variables of a subtask instance may also reference output data of any previous subtask instance using a path syntax expression. When a directed subtask instance needs to be executed, the computer device identifies the corresponding global variable in the global variable table based on the identifier of the subtask instance. In the case of a path syntax expression, the path syntax expression is parsed into corresponding data based on the data corresponding to the global variable included in the path syntax expression in the global variable table, and the input data of the directed subtask instance is obtained.
[0157] For example, the data structure for a subtask instance includes a parameter field, which looks like this: <parameter key, parameter value, parameter type, parameter description> Here, parameter types include string, boolean, number, etc. The value of a parameter may use a constant (number or string) or may refer to the output result of any previous subtask instance using a path syntax expression. For example, <SubtaskInstanceId>.data <Subtask instance Id>.parameter.<parameter key value>.
[0158] In this embodiment, the input data and output data of the corresponding subtask instance can be identified based on the subtask instance identifier, and the execution data of each subtask instance is stored in a database. Therefore, the execution data of each subtask instance can be loaded into memory and the global variable table can be updated to analyze the data corresponding to the path syntax expression used in the input parameter of the subtask instance. In this way, if the input data of a subtask instance is the output data of a preceding subtask instance that precedes the subtask instance, the output data of the corresponding preceding subtask instance can be quickly read using the global variable table stored in local memory, improving data reading speed.
[0159] In some embodiments, the method includes the steps of: obtaining a training corpus related to a workflow, the training corpus including a plurality of workflow sample texts and labels corresponding to each workflow sample text; performing semantic understanding based on the training corpus using a semantic understanding model to be trained and obtaining prediction results corresponding to each workflow sample text; performing model training on the semantic understanding model to be trained based on the prediction results and the labels corresponding to each workflow sample text, obtaining a trained semantic understanding model, and configuring the trained semantic understanding model as a large-scale language model.
[0160] Optionally, the computer device acquires a training corpus related to the workflow, the training corpus being a technical corpus related to triggers and execution instances of the workflow. The computer device further acquires a normal natural corpus including natural sample text related to web pages, news, novels, etc. The computer device performs data preprocessing on the training corpus and the natural corpus, respectively, such as cleaning, word segmentation, and stop word removal on each workflow sample text and natural sample text, to obtain processed workflow sample text and processed natural sample text. The computer device statistically counts words appearing in all processed workflow sample texts and processed natural sample texts to create a dictionary, where each word in the dictionary has a unique corresponding number. The computer device inputs the processed workflow sample text and the processed natural sample text into a semantic understanding model to train, and obtains prediction results corresponding to the processed workflow sample text and the processed natural sample text, respectively. The computer device determines a target loss based on the prediction results and labels respectively corresponding to the processed workflow sample texts and the prediction results and labels respectively corresponding to the processed natural sample texts, and aims to minimize the target loss by adjusting model parameters of the trained semantic understanding model to obtain a trained semantic understanding model, which is a large-scale language model. The trained semantic understanding model is constructed by a neural network model.
[0161] Of course, during training, the computer device can also use dropout or batch normalization to enrich the training text for model training, thereby improving the model training effect.
[0162] In this embodiment, a large-scale and abundant workflow-related training corpus and a large amount of computing resources are used to train the semantic understanding ability of the trained semantic understanding model, ensuring that the trained semantic understanding model can be applied to fields such as natural language generation, machine translation, and speech recognition. In this way, the trained semantic understanding model becomes a large-scale language model, which can accurately decompose task requirement information at an atomic level with fine granularity to obtain target atomic tasks, and accurately generate executable structures for target tasks that are consistent with the task requirement information, thereby realizing automatic execution of the target tasks.
[0163] The present application further provides application scenarios in which the above-mentioned task generation method based on a large-scale language model is applied. Optionally, an application example of the application scenario of the task generation method based on a large-scale language model is an instant messaging application scenario in which a manager needs to generate a target task to facilitate management of a business project, i.e., a target workflow related to the business project needs to be generated. Based on task requirement information corresponding to the business project, the manager can automatically generate an executable structure of the target task related to the business project using the task generation method based on a large-scale language model according to an embodiment of the present application. Therefore, the business project can be managed by the executable structure of the target task. Optionally, the method includes: acquiring input task requirement information based on the interactive task generation interface, invoking a large-scale language model, inputting the task requirement information into the large-scale language model, performing semantic understanding on the task requirement information using the large-scale language model, outputting an executable structure of a target task consistent with the task requirement information, performing graphic rendering on the target task based on the executable structure of the target task, obtaining a task execution flowchart of the target task, and displaying the task execution flowchart on the task generation interface, wherein the target task is composed of at least one target atomic task, and displaying an execution status confirmation link for the target task on the task generation interface, the execution status confirmation link being used to check the execution status of the target task. This eliminates the need for additional manual programming of the target task, and enables the consistent executable structure to be generated automatically, thereby improving the efficiency of target task generation.
[0164] Of course, the present invention is not limited to this example, and the task generation method based on a large-scale language model according to the present application can be applied to other application scenarios. For example, the task generation method based on a large-scale language model according to the embodiment of the present application generates an executable structure of a target task in advance and stores it in a database in advance. When a development engineer needs to develop a specific product whose normal operation includes the correct execution of the target task, he or she can directly call and use the executable structure of the target task. This eliminates the need to spend extra time on coding to generate the target task, thereby improving coding efficiency.
[0165] It will be understood that the above application scenarios are merely illustrative examples, and the application of the large-scale language model-based task generation method according to the embodiments of the present application is not limited to the above scenarios.
[0166] In a specific embodiment, a task generation method based on a large-scale language model, which is executed by a computer device, is provided. As shown in Figure 10, a flowchart of workflow execution in one embodiment is provided. Figure 10(a) includes steps S1002a to S1010a.
[0167] Step S1002a: Task requirement information is determined by speech recognition.
[0168] Optionally, the computing device can obtain the audio, text, or image text information of the task requirements input into the interactive task generation interface, and perform semantic conversion processing on the audio, text, or image text information of the task requirements to obtain the task requirement information.
[0169] The following describes an example in which task requirement voice is converted into task requirement information.
[0170] For the specific process of step S1002a, please refer to (b), that is, step S1002b to step S1014b.
[0171] Step S1002b: Obtaining sample audio.
[0172] Here, sample audio is acquired by various audio receiving software and hardware.
[0173] Step S1004b: Audio preprocessing.
[0174] Optionally, the computing device performs audio preprocessing on the sample audio to obtain a preprocessed sample audio, wherein the preprocessing includes at least one of noise removal, audio segmentation, and audio feature extraction.
[0175] Step S1006b: Feature extraction.
[0176] Optionally, the computing device performs feature extraction on the pre-processed sample audio to obtain a corresponding target signal.
[0177] Step S1008b: Training a speech recognition model.
[0178] Optionally, the target signal is sent to a speech recognition model to be trained to perform model training, and a trained speech recognition model is obtained.
[0179] The computing device performs step S1010b after obtaining the workflow requirement voice sent through the user account in the interactive task creation interface.
[0180] Step S1010b: Speech recognition.
[0181] Optionally, the computing device obtains the task requirement speech, and performs speech recognition on the task requirement speech with the trained speech recognition model to obtain a first recognized text.
[0182] Step S1012b: Text processing.
[0183] Optionally, the computing device performs post-processing on the first recognized text to obtain task requirement information, the post-processing including adding punctuation and correcting spelling errors.
[0184] Here, post-processing includes adding punctuation and correcting spelling errors.
[0185] Step S1014b: Output task requirement information.
[0186] Step S1004a: A presentation corpus is obtained.
[0187] Optionally, the computing device can obtain a presentation corpus constructed for the workflow from the workflow corpus, the presentation corpus including presentation information constructed for each atomic task of the workflow, the presentation information including executable structure and operational information of the atomic task.
[0188] Step S1006a: Semantic understanding is performed based on the task requirement information and the presented corpus, and an executable structure for the target task is obtained.
[0189] Step S1006a is a process of calling the large-scale language model each time, and each call will be described as an example. For the specific process, please refer to (c), that is, step S1002c to step S1010c.
[0190] Step S1002c: Determine the invocation parameters for the current invocation based on the task requirement information and the presentation corpus, and if the current invocation is not the first invocation, the context information of the previous invocation.
[0191] Optionally, the computing device sets the previous output result as the context information of the current call (for example, if the current call is the second call, the context information of the current call is level 2 sub-requirement information, and if the current call is the third call, the context information of the current call is level 3 sub-requirement information), and sets the context information of the current call, the presentation corpus, and the level prediction result corresponding to the previous call as the call parameters of the current call (for example, if the current call is the second call, the level prediction result corresponding to the previous call is level 1 prediction result, and if the current call is the third call, the level prediction result corresponding to the previous call is level 2 prediction result).
[0192] Step S1004c: Input the call parameters of the current call into the large-scale language model to obtain the level prediction result of the current call.
[0193] Step S1006c: Determine whether verification is feasible.
[0194] Optionally, if the format of the predicted result of the current call is verified to be valid, the computing device performs executable verification on the level predicted result of the current call. If the executable verification is not passed or the format of the level predicted result of the current call is invalid, execute step S1008c. If the executable verification is passed, execute step S1010c.
[0195] Step S1008c: The decomposition result of the current call is stored in the database in the form of a multi-level vector as the context information of the next call.
[0196] Optionally, the computing device decomposes the context information of the current call, obtains a decomposition result of the current call, and stores the decomposition result of the current call (e.g., if the current call is the second call, the decomposition result of the current call is level 3 sub-requirement information) in the database in the form of a multi-level vector as context information for the next call.
[0197] Step S1010c: The executable structure of the target task is output.
[0198] Optionally, if the computing device verifies that the format of the level prediction result of the current call is valid and the executable verification has passed, it determines an executable structure of the target task based on the level prediction result of the current call and outputs the executable structure of the target task.
[0199] To explain this with an example, the first call of the large-scale language model outputs a level 1 prediction result based on the task requirement information and the presented corpus. After obtaining the level 1 prediction result, formal verification is performed on the level 1 prediction result. If the corresponding formal verification result indicates success, executable verification is performed on the level 1 prediction result to obtain the level 1 verification result. If the formal verification result indicates failure, the level 1 prediction result is not a structure or is an invalid structure. In this case, there is no need to perform executable verification on the level 1 prediction result, and the task requirement information is directly decomposed into multiple level 2 sub-requirement information.
[0200] If the level 1 verification result indicates that the level 1 prediction result contains an executable structure, a target atomic task consistent with the task requirement information is directly obtained based on the level 1 prediction result. If the level 1 verification result indicates that the level 1 prediction result does not contain an executable structure, the computer device decomposes the task requirement information into multiple level 2 sub-requirement information. The large-scale language model is invoked a second time, and each level 2 sub-requirement information, the presentation corpus, and the level 1 prediction result are input to the large-scale language model. For each level 2 sub-requirement information, the large-scale language model outputs a level 2 prediction result based on the level 2 sub-requirement information, the presentation corpus, and the level 1 prediction result. Formal verification is performed on the level 2 prediction result, and if the corresponding formal verification result indicates success, executable verification is performed on the level 2 prediction result, and the process returns to the step of obtaining the level 2 verification result. If the corresponding formal verification result indicates success, it means that the level 2 prediction result is a structure and the format of the structure is valid. A target atomic task consistent with each of the level 2 sub-requirements information is obtained, and the computer device determines a connection order of the target atomic tasks of each of the level 2 sub-requirements information according to a decomposition order of each of the level 2 sub-requirements information. The computer device sequentially connects the target atomic tasks of each of the level 2 sub-requirements information according to the connection order of the target atomic tasks of each of the level 2 sub-requirements information, starting from the target atomic task of the initial connection order, to obtain at least one target atomic task consistent with the task requirement information.
[0201] If the corresponding formal verification result indicates failure, the predicted result at level 2 is not a structure or the predicted result at level 2 is an invalid structure. In this case, there is no need to perform executable verification on the predicted result at level 2, and the level 2 sub-requirement information is directly decomposed into multiple level 3 sub-requirement information.
[0202] For each piece of level-3 subrequirements information, the large-scale language model is invoked again, and the level-3 subrequirements information, the presentation corpus, and the level-2 prediction results corresponding to each piece of level-2 subrequirements information are input into the large-scale language model. For each piece of level-3 subrequirements information, the computer device uses the large-scale language model to output a level-3 prediction result corresponding to the level-3 subrequirements information based on the level-3 subrequirements information, the presentation corpus, and the level-2 prediction results corresponding to the level-2 subrequirements information. If the format of the level-3 prediction result is verified to be correct, executable verification is performed on the level-3 prediction result to obtain a level-3 verification result. If the level-3 verification result indicates that the corresponding level-3 prediction result passes the executable verification, a target atomic task consistent with the level-3 subrequirements information is obtained based on the level-3 prediction result.
[0203] The connection order of the target atomic tasks that are consistent with each of the level-3 subrequirement information is determined according to the decomposition order of each of the level-3 subrequirement information in the second decomposition. For each of the level-2 subrequirement information, starting from the target atomic task in the initial first connection order, the target atomic tasks of each of the level-3 subrequirement information are sequentially connected according to the connection order of each of the target atomic tasks of each of the level-3 subrequirement information to obtain at least one target atomic task of the level-2 subrequirement information. Starting from the target atomic task in the initial second connection order, the target atomic tasks of each of the level-2 subrequirement information are sequentially connected according to the connection order of each of the target atomic tasks of each of the level-2 subrequirement information to obtain at least one target atomic task that is consistent with the task requirement information. The first connection order refers to the first connection order of each target atomic task that is consistent with the level-3 subrequirement information, and the second connection order refers to the first connection order of each target atomic task that is consistent with the level-2 subrequirement information. Determine an executable structure of the target task consistent with the task requirement information based on the executable structure of the at least one target atomic task consistent with the task requirement information, and output the executable structure of the target task.
[0204] Step S1008a: The target task is executed.
[0205] Optionally, a task execution flowchart of the target task is rendered and displayed in the interactive task creation interface. The target task is composed of at least one target atomic task. The computing device executes the target task, and when the execution state of the target task is updated, updates the execution state of the target task in the task execution flowchart.
[0206] For the specific process of executing the target task, please refer to (d), that is, step S1002d to step S1012d.
[0207] Step S1002d: An execution instance corresponding to the task is created.
[0208] Optionally, the computer device directly triggers an execution instruction to execute the target task. Optionally, the computer device can also store an executable structure of the target task and trigger an execution instruction to execute the target task after a preset time has elapsed. Optionally, the computer device can also trigger an execution instruction to execute the target task in response to a trigger operation on the target task. When an execution instruction to execute the target task is triggered, a task instance corresponding to the target task is created in a task instance table of the database.
[0209] Step S1004d: An execution instance is obtained and initialized.
[0210] Optionally, the computing device pushes a task instance identifier corresponding to the created task instance to a task instance message queue and monitors the task instance message queue. Optionally, the computing device monitors the task instance message queue based on each container (which can be understood as each distributed execution node) in a consumption cluster of the distributed workflow engine located on the computing device, and when a new task instance identifier is added to the message queue, it is consumed sequentially in first-in-first-out order to execute the corresponding task instance.
[0211] Step S1006d: The subtask instance table is obtained.
[0212] Optionally, when consuming a task instance of the target task, the computing device pushes a subtask instance identifier corresponding to a first subtask instance onto a subtask instance message queue, consumes the subtask instance identifier from the subtask instance message queue, retrieves a corresponding subtask instance table based on the subtask instance identifier, and loads and executes the current subtask instance. After executing the current subtask instance, it stores the subtask instance in the corresponding subtask instance table in the database and determines the subtask instance to which the current subtask instance is directed. After pushing the subtask instance identifier corresponding to the directed subtask instance onto the subtask instance message queue, it continues execution by returning to the step of consuming subtask instance identifiers from the subtask instance message queue until all of the subtask instances of the task instance have been executed.
[0213] After determining the subtask instance that the current subtask instance points to, the subtask instance table of the executed subtask instance is obtained, and the pointed subtask instance is persistently stored in the subtask instance table of the database. The execution state of the subtask instance is initialized to unprocessed. After the subtask instance is executed, the execution state of the subtask instance is updated to completed in the subtask instance table, and the execution data of the subtask instance is updated. If the current subtask instance points to multiple subtask instances, the subtask instance identifiers of each of the multiple pointed subtask instances are all pushed to a subtask instance message queue, and the distributed execution node consumes the multiple subtask instance identifiers from the subtask instance message queue, after which the corresponding multiple subtask instances are loaded and executed in parallel. The target task processing method includes the steps of analyzing a task instance, obtaining global variables of each subtask instance included therein, and forming and storing a global variable table, where the global variables include global input variables and global output variables; after executing a current subtask instance, updating the global output variables in the global variable table based on corresponding execution data; loading the updated global variable table, obtaining input data corresponding to the global input variables of the directed subtask instance, and executing the directed subtask instance based on the input data.
[0214] Step S1008d: The path syntax expression is analyzed.
[0215] Optionally, when sequentially executing the subtask instances of the execution instance of the target task, if the input data of the subtask instance is the output data of a preceding subtask instance that precedes the subtask instance, the input data of the subtask instance can be obtained by parsing the path syntax expression, i.e., the output data of the preceding subtask instance that precedes the subtask instance. The computer device executes the subtask instance based on the input data of the subtask instance.
[0216] Step S1012d: Determine whether the execution instance has ended.
[0217] Optionally, the output data obtained from the execution is stored in a database, and the execution instance of the target task is determined to be completed, that is, whether all sub-execution instances in the execution instance of the target task have been executed. If the execution states of all sub-execution instances are "executed," the execution instance of the target task is determined to be completed.
[0218] Step S1010a: The execution status confirmation link is displayed.
[0219] Optionally, when execution of the target task starts, an execution status check link for the target task is displayed in the interactive task creation interface. In response to a trigger operation on the execution status check link, a jump is made to the execution status check interface, and the execution status of the target task is clearly displayed in the execution status check interface. Every time the target task executes an application, a task execution flowchart of the running target task is clearly displayed in the execution status check interface, and a completion mark is displayed on a figure corresponding to the executed application in the task execution flowchart of the running target task.
[0220] In this embodiment, task requirement information is input through an interactive task generation interface, and a large-scale language model is directly invoked to input the task requirement information into the large-scale language model. The large-scale language model then performs semantic understanding of the task requirement information, and an executable structure for a target task consistent with the task requirement information is automatically obtained. Graphic rendering is performed for the target task based on the executable structure of the target task to obtain a task execution flowchart for the target task, and the task execution flowchart is displayed in the task generation interface. The target task is composed of at least one target atomic task, so detailed information about the generated target task can be intuitively displayed. A target task execution status check link is displayed in the task generation interface, and the execution status check link can be used to check the execution status of the target task, allowing timely and intuitive confirmation of the execution status. In other words, a task can be automatically generated by simply providing task requirement information without complex operations, simplifying the task generation procedure and improving task generation efficiency. Furthermore, task generation can reuse operating environments, execute different tasks, and execute tasks in parallel, effectively reducing costs. When executing target tasks, the fine-grained execution mechanism of Atomic Task Shockwave realizes parallel execution of applications, and the parallel aggregation of applications makes the execution of the workflow engine closer to the execution characteristics of coding and programming (such as parallel wait control). Furthermore, the low-code design concept of the executable structure DSL Json significantly reduces training and usage costs and greatly improves efficiency.
[0221] It should be understood that although the steps in the flowcharts according to the above-described embodiments are displayed sequentially according to the arrows, these steps are not necessarily executed sequentially in the order shown by the arrows. Unless otherwise specified in this specification, the execution of these steps is not limited to a strict order, and these steps may be executed in other orders. Furthermore, at least some of the steps in the flowcharts according to the above-described embodiments may include multiple steps or multiple stages, and these steps or stages are not necessarily executed and completed at the same time but may be executed at different times. The execution order of these steps or stages is also not necessarily sequential, and they may be executed in order or alternately with other steps or at least some of the steps or stages in other steps.
[0222] Based on the same inventive concept, the embodiments of the present application further provide a large-scale language model-based task generation system for implementing the above-mentioned large-scale language model-based task generation method. The problem-solving implementation means provided by this system are similar to the implementation means described in the above-mentioned method, so the specific limitations of the one or more large-scale language model-based task generation system embodiments provided below can refer to the limitations of the above-mentioned large-scale language model-based task generation method, and will not be described again here.
[0223] In one embodiment, a task generation system 1100 based on a large-scale language model is provided, as shown in Figure 11. The system includes an information acquisition module 1102, a structure acquisition module 1104, a task execution flowchart display module 1106, and a link display module 1108, where: The information acquisition module is used to acquire task requirement information input based on the interactive task generation interface; The structure acquisition module is used to call the large-scale language model, input the task requirement information into the large-scale language model, perform semantic understanding on the task requirement information using the large-scale language model, and output an executable structure of the target task that is consistent with the task requirement information; The task execution flowchart display module is used to perform graphic rendering on the target task according to the executable structure of the target task, obtain a task execution flowchart of the target task, and display the task execution flowchart on the task generation interface, where the target task is composed of at least one target atomic task; The link display module is used to display an execution status check link for the target task in the task creation interface, and the execution status check link is used to check the execution status of the target task.
[0224] In some examples, the information acquisition module 1102 is used to manifest a human-computer interaction-enabled task generation interface, receive task content input via the interactive task generation interface, acquire the task content, perform semantic transformation on the task content, and acquire task requirement information.
[0225] In some embodiments, the information acquisition module 1102 is used to invoke a presentation corpus constructed for the workflow using a large-scale language model, perform semantic understanding on the task requirement information, obtain an executable structure for a target task that is consistent with the task requirement information, and output the executable structure for the target task, where the presentation corpus includes presentation information constructed for each atomic task of the workflow, and the presentation information includes the executable structure and operation information of the atomic task.
[0226] In some embodiments, the structure acquisition module 1104 is used to generate invocation parameters based on the task requirement information and the presentation corpus, construct a model invocation request based on the invocation parameters, and invoke a large-scale language model based on the model invocation request.
[0227] In some embodiments, the structure acquisition module is used to perform semantic understanding based on the task requirement information and the presentation corpus using a large-scale language model, acquire at least one target atomic task consistent with the task requirement information, acquire an executable structure of the at least one target atomic task from the presentation corpus, and acquire an executable structure of the target task consistent with the task requirement information based on the executable structure of the at least one target atomic task.
[0228] In some embodiments, the structure acquisition module is used to sequentially determine at least one target atomic task that is consistent with the task requirement information based on the task requirement information and the presentation corpus using a large-scale language model. The structure acquisition module is used to combine the executable structures of each target atomic task based on a next atomic task identifier indicated by each executable structure of the target atomic task to acquire an executable structure of the target task that is consistent with the task requirement information.
[0229] In some embodiments, the structure acquisition module is used to decompose the task requirement information into multiple sub-requirement information using a large-scale language model, and for each piece of sub-requirement information, sequentially determine a target atomic task that is consistent with the sub-requirement information based on the sub-requirement information and the presentation corpus, and determine at least one target atomic task that is consistent with the task requirement information based on the target atomic task that is consistent with each piece of sub-requirement information.
[0230] In some embodiments, the structure acquisition module is used to obtain a level 1 prediction result based on the task requirement information and the presentation corpus using a large-scale language model, perform executable verification on the level 1 prediction result, obtain a level 1 verification result, and if the level 1 verification result indicates that the level 1 prediction result does not include an executable structure, decompose the task requirement information into multiple level 2 sub-requirements information, and for each of the level 2 sub-requirements information, output a level 2 prediction result based on the level 2 sub-requirements information, the presentation corpus, and the level 1 prediction result using the large-scale language model, perform executable verification on the level 2 prediction result, obtain a level 2 verification result, and if the level 2 verification result indicates that the level 2 prediction result includes an executable structure, determine that the level 2 prediction result passes the executable verification, and acquire a target atomic task that is consistent with the level 2 sub-requirements information based on the level 2 prediction result.
[0231] In some embodiments, the structure acquisition module is further used to acquire a target atomic task that is consistent with the task requirement information based on the level 1 prediction result when the level 1 verification result indicates that the level 1 prediction result includes an executable structure.
[0232] In some embodiments, the structure acquisition module is further used to acquire target atomic tasks consistent with each of the level-2 sub-requirements information, acquire a decomposition order of each of the level-2 sub-requirements information, and concatenate the target atomic tasks consistent with each of the level-2 sub-requirements information according to the decomposition order of each of the level-2 sub-requirements information to acquire at least one target atomic task consistent with the task requirement information.
[0233] In some embodiments, the structure acquisition module is further used to, if the level 2 verification result corresponding to the level 2 sub-requirements information does not pass the executable verification, decompose the level 2 sub-requirements information into multiple level 3 sub-requirements information, and for each of the level 3 sub-requirements information, output a level 3 prediction result based on the level 3 sub-requirements information, the presentation corpus, and the level 2 prediction result corresponding to each of the level 2 sub-requirements information using a large-scale language model, perform executable verification on the level 3 prediction result, obtain a level 3 verification result, and if the level 3 verification result indicates that the level 3 prediction result contains an executable structure, determine that the level 3 prediction result passes the executable verification, and obtain a target atomic task consistent with the level 3 sub-requirements information based on the level 3 prediction result.
[0234] In some embodiments, the structure acquisition module is further used for obtaining a target atomic task consistent with each of the level 3 sub-requirements information, obtaining a decomposition order of each of the level 3 sub-requirements information and a decomposition order of each of the level 2 sub-requirements information, concatenating the target atomic tasks consistent with each of the level 3 sub-requirements information according to the decomposition order of each of the level 3 sub-requirements information, obtaining at least one target atomic task consistent with the level 2 sub-requirements information, concatenating the target atomic tasks consistent with each of the level 2 sub-requirements information according to the decomposition order of each of the level 2 sub-requirements information, and obtaining at least one target atomic task consistent with the task requirement information.
[0235] In some embodiments, the system further includes an update module used to execute the target task and update the execution state of the target task in the task execution flowchart when the execution state of the target task is updated.
[0236] In some embodiments, the update module is further used to jump to an execution status confirmation interface in response to a trigger operation on the execution status confirmation link and to indicate the execution status of the target task in the execution status confirmation interface.
[0237] In some embodiments, when the system triggers an execution instruction to execute the target task, it creates a task instance for the target task, the task instance includes at least one subtask instance, the subtask instance is used to execute a corresponding target atomic task, and includes a task execution module used to execute each subtask instance sequentially based on the executable structure of the subtask instance, starting from the first subtask instance of the task instance.
[0238] In some embodiments, the task execution module further creates a task instance corresponding to the target task in a task instance table of the database, the task instance table being used to record a task instance identifier, a process data structure of the task instance, the process data structure including subtask instance identifiers and directional relationships between each subtask instance, and is used to perform the steps of pushing the task instance identifier to a task instance message queue, and after consuming the task instance identifiers from the task instance message queue, sequentially executing each subtask instance starting from the first subtask instance of the task instance based on the executable structure of the subtask instance.
[0239] In some embodiments, the task execution module is further used to push a subtask instance identifier corresponding to a first subtask instance onto a subtask instance message queue, consume the subtask instance identifier from the subtask instance message queue, load the corresponding subtask instance based on the subtask instance identifier, execute the corresponding subtask instance, determine the subtask instance to which the corresponding subtask instance points after executing the corresponding subtask instance, push the subtask instance identifier corresponding to the pointed-to subtask instance onto the subtask instance message queue, and then continue execution by returning to the step of consuming subtask instance identifiers from the subtask instance message queue until all of the subtask instances of the task instance have been executed.
[0240] In some embodiments, the task execution module is further used to push all subtask instance identifiers of each of the multiple subtask instances to the subtask instance message queue if the corresponding subtask instance is directed to multiple subtask instances. The workflow execution module is further used by the distributed execution node to consume the multiple subtask instance identifiers from the subtask instance message queue, and then load the corresponding multiple subtask instances in parallel and execute the corresponding multiple subtask instances.
[0241] All or part of the modules in the task generation system based on the large-scale language model can be realized by software, hardware, or a combination thereof. Each module may be integrated into a processor in a computer device in a hardware form, or may be independent therefrom, or may be stored in a memory in a computer device in a software form, so that the processor can call and execute operations corresponding to each module.
[0242] In one embodiment, a computer device is provided. This computer device may be a server or a terminal, and its internal structure diagram can be shown in FIG. 12. The computer device includes a processor, a memory, an input / output interface (I / O), and a communication interface. Here, the processor, the memory, and the I / O interface are connected via a system bus, and the communication interface is connected to the system bus via the I / O interface. Here, the processor of the computer device is used to provide calculation functions and control functions. The memory of the computer device includes a non-volatile storage medium and an internal memory. The non-volatile storage medium stores an operating system, computer-readable instructions, and a database. The internal memory provides an environment for the operation of the operating system and the computer-readable instructions in the non-volatile storage medium. The I / O interface of the computer device is used to exchange information between the processor and external devices. The communication interface of the computer device is used to communicate with an external terminal via a network connection. When executed by the processor, the computer-readable instructions realize a task generation method based on a large-scale language model.
[0243] As will be understood by those skilled in the art, the structure shown in FIG. 12 is merely a block diagram of a portion of the structure related to the solution of the present application, and does not limit the computer device to which the solution of the present application can be applied; a specific computer device may include more or fewer components than those shown, may combine some components, or may have a different component arrangement.
[0244] In one embodiment, a computing device is provided that includes a memory and a processor, the memory having computer-readable instructions stored therein, the processor, when executing the computer-readable instructions, performing the steps of each of the method embodiments described above.
[0245] In one embodiment, a computer-readable storage medium is provided having stored thereon computer-readable instructions which, when executed by a processor, implement the steps of each of the method embodiments described above.
[0246] In one embodiment, a computer program product is provided that includes computer readable instructions that, when executed by a processor, implement the steps of each of the method embodiments described above.
[0247] It should be noted that the user information (including, but not limited to, user device information, user personal information, etc.) and data (including, but not limited to, data for analysis, stored data, explicit data, etc.) related to this application are all information and data authorized by the user or fully authorized by each party, and the collection, use and processing of related data must comply with the relevant laws, regulations and standards of the relevant countries and regions.
[0248] As will be understood by those skilled in the art, all or part of the processes in the methods of the above embodiments can be implemented by instructing associated hardware with computer-readable instructions. The computer-readable instructions can be stored in a non-volatile computer-readable storage medium, and when the computer-readable instructions are executed, the processes of the above method embodiments can be implemented. Any references to memory, database, or other medium used in the embodiments of this application may include at least one of non-volatile memory and volatile memory. Non-volatile memory may include read-only memory (ROM), magnetic tape, floppy disk, flash memory, optical memory, high-density embedded non-volatile memory, resistive random access memory (ReRAM), magnetoresistive random access memory (MRAM), ferroelectric random access memory (FRAM), phase change memory (PCM), graphene memory, etc. Volatile memory may include random access memory (RAM), external cache memory, etc. By way of illustration and not limitation, the RAM may be in various forms, such as static random access memory (SRAM) or dynamic random access memory (DRAM). The database in each embodiment of the present application may include at least one of a relational database and a non-relational database. The non-relational database may include, but is not limited to, a distributed database based on blockchain. The processor in each embodiment of the present application may be, but is not limited to, a general-purpose processor, a central processing unit, a graphics processor, a digital signal processor, a programmable logic device, a data processing logic device based on quantum computing, etc.
[0249] The technical features of the above embodiments can be combined in any manner, and for the sake of brevity, not all possible combinations of the technical features in the above embodiments are described, but any combination of these technical features should be considered to be within the scope described herein unless there is a contradiction.
[0250] The above examples only represent some embodiments of the present application, and are described in more detail and specific terms, but should not be understood as limiting the scope of protection of the present application. Those skilled in the art can make various modifications and improvements without departing from the concept of the present application, and all of these modifications and improvements fall within the scope of protection of the present application. Therefore, the scope of protection of the present application should be governed by the appended claims.
Claims
1. 1. A method for task generation based on a large-scale language model, executed by a computing device, comprising: obtaining input task requirement information based on an interactive task generation interface; invoking a large-scale language model, further comprising inputting the task requirement information into the large-scale language model, performing semantic understanding on the task requirement information using the large-scale language model, and outputting an executable structure for a target task that is consistent with the task requirement information; performing graphic rendering on the target task based on the executable structure of the target task, obtaining a task execution flowchart of the target task, and displaying the task execution flowchart on the task generation interface, wherein the target task is composed of at least one target atomic task; a step of displaying an execution status confirmation link of the target task in the task generation interface, the execution status confirmation link being used to confirm the execution status of the target task; A task generation method based on a large-scale language model, including:
2. The step of acquiring task requirement information input based on the interactive task generation interface includes: defining the task creation interface capable of human-computer interaction; receiving task content input via the interactive task creation interface and acquiring the task content; performing semantic transformation on the task content to obtain the task requirement information; The method of claim 1 , comprising:
3. performing semantic understanding of the task requirement information using the large-scale language model and outputting an executable structure of a target task that is consistent with the task requirement information, a step of calling a presentation corpus constructed for a workflow using the large-scale language model, performing semantic understanding on the task requirement information, and obtaining an executable structure of a target task that is consistent with the task requirement information, and outputting the executable structure of the target task, wherein the presentation corpus includes presentation information constructed for each atomic task of a workflow, and the presentation information includes the executable structure and operation information of the atomic task; 3. The method of claim 1 or 2, comprising:
4. Invoking the large-scale language model comprises: generating invocation parameters based on the task requirement information and the presentation corpus; constructing a model invocation request based on the invocation parameters; invoking a large-scale language model based on the model invocation request; The method of claim 3, comprising:
5. The step of calling a presentation corpus constructed for a workflow using the large-scale language model, performing semantic understanding on the task requirement information, and obtaining an executable structure for a target task that is consistent with the task requirement information, includes: performing semantic understanding based on the task requirement information and the presentation corpus using a large-scale language model to obtain at least one target atomic task consistent with the task requirement information; obtaining an executable structure of at least one target atomic task from the presentation corpus, and obtaining an executable structure of a target task that is consistent with the task requirement information based on the executable structure of the at least one target atomic task; 5. The method of claim 3 or 4, comprising:
6. performing semantic understanding based on the task requirement information and the presentation corpus using a large-scale language model to obtain at least one target atomic task consistent with the task requirement information, sequentially determining, based on the task requirement information and the presentation corpus, at least one target atomic task that is consistent with the task requirement information using a large-scale language model; Including, The step of obtaining an executable structure of a target task that is consistent with the task requirement information based on the executable structure of the at least one target atomic task includes: combining the executable structures of each of the target atomic tasks based on a next atomic task identifier indicated by each executable structure of the target atomic tasks to obtain an executable structure of a target task that is consistent with the task requirement information; The method of claim 5 , comprising:
7. sequentially determining, based on the task requirement information and the presentation corpus, at least one target atomic task that is consistent with the task requirement information using a large-scale language model; Decomposing the task requirement information into a plurality of sub-requirement information using a large-scale language model, and for each sub-requirement information, sequentially determining a target atomic task that is consistent with the sub-requirement information based on the sub-requirement information and the presentation corpus; determining at least one target atomic task that is consistent with the task requirement information based on target atomic tasks that are consistent with each of the sub-requirements information; The method of claim 6, comprising:
8. The step of decomposing the task requirement information into a plurality of sub-requirement information by a large-scale language model, and sequentially determining a target atomic task that is consistent with each of the sub-requirement information based on the sub-requirement information and the presentation corpus, obtaining a level 1 prediction result based on the task requirement information and the presentation corpus using the large-scale language model, and performing executable verification on the level 1 prediction result to obtain a level 1 verification result; If the level 1 verification result indicates that the level 1 prediction result does not include an executable structure, Decomposing the task requirement information into a plurality of level 2 sub-requirement information; For each level 2 sub-requirement information, the large-scale language model outputs a level 2 prediction result based on the level 2 sub-requirement information, the presentation corpus, and the level 1 prediction result, and performs executable verification on the level 2 prediction result to obtain a level 2 verification result; If the verification result of the level 2 indicates that the prediction result of the level 2 includes an executable structure, determining that the prediction result of the level 2 has passed executable verification, and obtaining a target atomic task that is consistent with the sub-requirements information of the level 2 based on the prediction result of the level 2; The method of claim 7, comprising:
9. The method comprises: obtaining a target atomic task that is consistent with the task requirement information based on the level 1 prediction result when the level 1 verification result indicates that the level 1 prediction result includes an executable structure; The method of claim 8 further comprising:
10. determining at least one target atomic task that is consistent with the task requirement information based on target atomic tasks that are consistent with each of the sub-requirements information, Obtaining a target atomic task that is consistent with each of the level-2 sub-requirements information, and obtaining a decomposition order for each of the level-2 sub-requirements information; Concatenating target atomic tasks that are consistent with each of the level-2 sub-requirements information according to a decomposition order of each of the level-2 sub-requirements information to obtain at least one target atomic task that is consistent with the task requirement information; The method of claim 8, comprising:
11. The method comprises: If the verification result of level 2 corresponding to the sub-requirements information of level 2 does not pass the executable verification, Decomposing the level 2 sub-requirement information into a plurality of level 3 sub-requirement information; For each piece of level 3 sub-requirement information, using the large-scale language model, output a level 3 prediction result based on the level 3 sub-requirement information, the presentation corpus, and the level 2 prediction result corresponding to each piece of level 2 sub-requirement information, and perform executable verification on the level 3 prediction result to obtain a level 3 verification result; determining that the level 3 prediction result has passed executable verification if the level 3 verification result indicates that the level 3 prediction result includes an executable structure, and obtaining a target atomic task that is consistent with the level 3 sub-requirements information based on the level 3 prediction result; The method of any one of claims 8 to 10, further comprising:
12. determining at least one target atomic task that is consistent with the task requirement information based on target atomic tasks that are consistent with each of the sub-requirements information, Obtaining a target atomic task that is consistent with each of the level-3 sub-requirements information, and obtaining a decomposition order of each of the level-3 sub-requirements information and a decomposition order of each of the level-2 sub-requirements information; Concatenating target atomic tasks that are consistent with each of the level-3 sub-requirements information according to a decomposition order of each of the level-3 sub-requirements information to obtain at least one target atomic task that is consistent with the level-2 sub-requirements information; Concatenating target atomic tasks that are consistent with each of the level-2 sub-requirements information according to a decomposition order of each of the level-2 sub-requirements information to obtain at least one target atomic task that is consistent with the task requirement information; The method of claim 11 , comprising:
13. After displaying the task execution flowchart on the task creation interface, the method includes: executing the target task; When the execution state of the target task is updated, updating the execution state of the target task in the task execution flowchart. The method of any one of claims 1 to 11, further comprising:
14. The method comprises: jumping to an execution status confirmation interface in response to a trigger operation on the execution status confirmation link; indicating the execution status of the target task in the execution status confirmation interface; 14. The method of claim 13, further comprising:
15. The step of executing the target task includes: creating a task instance for the target task when an execution instruction to execute the target task is triggered, the task instance including at least one subtask instance, the subtask instance being used to execute a corresponding target atomic task; starting with a first subtask instance of the task instance, sequentially executing each of the subtask instances based on the executable structure of the subtask instance; 14. The method of claim 13, comprising:
16. After creating a task instance for the target task, the method includes: creating a task instance corresponding to the target task in a task instance table of a database, the task instance table being used to record a task instance identifier, a process data structure of the task instance, the process data structure including subtask instance identifiers and directional relationships between each of the subtask instances; pushing the task instance identifier into a task instance message queue; after consuming task instance identifiers from the task instance message queue, starting with a first subtask instance of said task instance, sequentially executing each subtask instance based on the executable structure of the subtask instance; 16. The method of claim 15, further comprising:
17. starting from a first subtask instance of the task instance, sequentially executing each subtask instance based on the executable structure of the subtask instance, pushing a subtask instance identifier corresponding to the first subtask instance onto a subtask instance message queue; Consuming a subtask instance identifier from the subtask instance message queue; loading a corresponding subtask instance based on the subtask instance identifier and executing the corresponding subtask instance; determining a subtask instance to which the corresponding subtask instance points after executing the corresponding subtask instance; pushing a subtask instance identifier corresponding to the directed subtask instance onto a subtask instance message queue, and then continuing execution by returning to consuming subtask instance identifiers from the subtask instance message queue until all of the subtask instances of the task instance have been executed; 17. The method of claim 16, comprising:
18. Pushing a subtask instance identifier corresponding to the directed subtask instance onto a subtask instance message queue includes: If the corresponding subtask instance points to multiple subtask instances, pushing all subtask instance identifiers of each of the multiple pointed subtask instances onto a subtask instance message queue. Including, Consuming a subtask instance identifier from the subtask instance message queue includes: and a distributed execution node, after consuming the plurality of subtask instance identifiers from the subtask instance message queue, loading the corresponding plurality of subtask instances in parallel and executing the corresponding plurality of subtask instances.
18. The method of claim 17, comprising:
19. A task generation system based on a large-scale language model, comprising: an information acquisition module for acquiring task requirement information input based on the interactive task generation interface; a structure acquisition module for calling a large-scale language model, inputting the task requirement information into the large-scale language model, performing semantic understanding on the task requirement information using the large-scale language model, and outputting an executable structure of a target task that is consistent with the task requirement information; a task execution flowchart display module for performing graphic rendering on the target task based on the executable structure of the target task, obtaining a task execution flowchart of the target task, and displaying the task execution flowchart on the task generation interface, wherein the target task is composed of at least one target atomic task; a link display module for displaying an execution status confirmation link of the target task in the task generation interface, the execution status confirmation link being used to confirm the execution status of the target task; A task generation system based on a large-scale language model, comprising:
20. A computing device comprising a memory and a processor, the memory having computer readable instructions stored therein, the processor, when executing the computer readable instructions, performing the steps of the method of any one of claims 1 to 18.
21. A computer readable storage medium having stored thereon computer readable instructions which, when executed by a processor, perform the steps of the method of any one of claims 1 to 18.
22. A computer program product comprising computer readable instructions which, when executed by a processor, perform the steps of the method of any one of claims 1 to 18.
Citation Information
Patent Citations
Systems, methods, and graphical user interfaces for workflow generation, deployment, and / or execution.
JP2010539599A
Work task management system
JP2023002929A