Business process prediction method based on attribute-aware heterogeneous graph and double time sequence joint coding

CN122887587APending Publication Date: 2026-10-09SHANDONG UNIV OF SCI & TECH
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202611381395.3
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2026-09-08
Publication Date
2026-10-09

AI Technical Summary

Technical Problem

1)活动上下文语义区分不足:现有图方法通常以活动作为主要节点,缺乏对活动执行状态的显式刻画,难以区分同一流程活动在不同执行上下文中的语义差异

Benefits of technology

针对现有业务流程预测方法中图模型无法区分同一活动在不同执行上下文中的语义差异、对事件多维属性利用不足、以及现有方法未能有效结合流程结构信息与时序演化信息的问题,本发明提供一种基于属性感知异构图与双时序联合编码的业务流程预测方法,该方法在传统图建模基础上引入状态节点,将“活动→活动”的直接转移拆解为“活动→状态→活动”的复合路径,使模型能够区分同一活动在不同执行上下文中的语义差异,解决了现有图方法将所有出现等同对待而无法区分上下文语义的根本问题。本发明设计了一种属性融合模块,将事件日志中的多维属性(如执行角色、时间戳、资源等)通过门控机制加权融合后注入状态节点表示,使状态节点能够携带导致活动转移差异的上下文条件,有效提升了模型对事件属性的利用效率。另外,本发明还设计了异构图卷积与双时序编码相结合的并行架构,异构图卷积捕获流程的结构依赖,双LSTM分别编码活动序列与状态序列的时序演化,避免了现有图序列结合方法中串行处理导致序列信息丢失的问题,实现了结构信息与时序信息的联合学习。

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN122887587A_ABST
    Figure CN122887587A_ABST
Patent Text Reader

Abstract

The application belongs to the technical field of loan approval business process prediction, and discloses a business process prediction method based on attribute perception heterogeneous graph and double time sequence joint coding. The method introduces state nodes on the basis of traditional graph modeling, and decomposes the direct transfer of "activity to activity" into a composite path of "activity to state to activity". In addition, the application designs an attribute fusion module, which injects the multi-dimensional attributes in the event log into the state nodes after weighted fusion through a gating mechanism, so that the state nodes can carry the context conditions leading to the difference in activity transfer. In addition, the application also designs a parallel architecture combining heterogeneous graph convolution and double time sequence coding. The heterogeneous graph convolution is used to capture the structural dependence of the process, and the double time sequence coding is used to encode the time sequence evolution of the activity sequence and the state sequence respectively, realizing the joint learning of structural information and time sequence information. The application improves the prediction accuracy of the next activity in the loan approval business process.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention belongs to the field of loan approval business process prediction technology, and relates to a business process prediction method based on attribute-aware heterogeneous graphs and dual-temporal joint coding, which is particularly suitable for the prediction scenario of the next activity in the loan approval business process. Background Technology

[0002] With the advancement of digital transformation, predictive process monitoring (PPM) is gradually being applied to business process analysis. Its main tasks include predicting the next activity, the remaining time of the process, and the prediction of abnormal risks.

[0003] Taking loan approval as an example, a loan application typically involves multiple steps, including application submission, application material completion, application verification, application review, quotation creation and sending, quotation follow-up, and application approval. The presence of branches, iterative loops, and complex dependencies within the process poses a challenge to accurately predicting the next activity. In summary, existing business process prediction methods mainly include sequence-based methods, graph-based methods, and methods combining graphs and sequences.

[0004] Sequence-based methods typically treat process execution as a sequence of activities, using models such as recurrent neural networks to capture temporal dependencies. However, representing a process as a linear sequence makes it difficult to fully describe structural relationships such as branches and loops. Graph-based methods can model structural dependencies between process activities, but they usually treat activities as primary nodes, lacking differentiation of the state of the same activity in different execution contexts. For example, in loan approval, even if the current process activity is the same, different loan amounts may lead to different subsequent process activities. While methods combining graphs and sequences introduce both graph structure and sequence information, they often adopt a sequential approach of first modeling the graph and then encoding the sequence, which can easily weaken the original sequential information of the prefix trajectory.

[0005] In summary, existing methods still have the following problems and shortcomings: 1) Insufficient semantic distinction of activity context: Existing graph methods usually take activities as the main nodes, lack explicit characterization of the execution state of activities, and make it difficult to distinguish the semantic differences of the same process activity in different execution contexts.

[0006] 2) The graph and sequence fusion method is mainly serial: the sequence-based method is difficult to fully model the parallel, cyclic and other structural relationships in the process; while the graph and sequence combination method often adopts a serial architecture of graph first and sequence later, which easily weakens the original sequence information of the prefix trajectory and makes it difficult to achieve effective joint modeling of structural dependency and temporal evolution.

[0007] 3) Insufficient utilization of multidimensional attributes of events: Events usually contain multidimensional attributes such as resources, amount, and time, but existing methods are relatively simple in modeling and integrating attribute information, and fail to give full play to the supporting role of attribute information in prediction.

[0008] In summary, existing business process prediction models struggle to effectively co-model structural dependencies, temporal evolution, activity context states, and multidimensional attributes in event logs, resulting in limited accuracy in predicting the next activity in the loan approval business process.

[0009] The statements in this section are merely background information related to the present invention and do not necessarily constitute prior art. Summary of the Invention

[0010] The purpose of this invention is to propose a business process prediction method based on attribute-aware heterogeneous graphs and dual-temporal joint coding. This method constructs a heterogeneous activity-state graph to decompose the direct transition from "activity → activity" in the loan approval business process into a composite path of "activity → state → activity" to distinguish the semantic context of activities. The method injects multi-dimensional attributes of events into the representation of state nodes through an attribute fusion module to enrich the semantics of the nodes. Finally, it adopts a parallel architecture of heterogeneous graph convolution and dual-temporal coding to achieve unified learning of process structure dependency and temporal evolution, thereby improving the prediction accuracy of the next execution stage in the loan approval business process.

[0011] To achieve the above objectives, the present invention adopts the following technical solution: The business process prediction method based on attribute-aware heterogeneous graphs and dual-temporal joint coding includes the following steps: Step 1. Extract each process instance and its prefix trajectory from the historical event log of the loan approval business process, and obtain the activity sequence, state sequence and multi-dimensional attribute sequence corresponding to each prefix trajectory; Step 2. Construct a heterogeneous activity-state graph containing activity nodes, state nodes, and directed edges using each prefix trajectory and its corresponding state sequence and multidimensional attribute sequence, and collect the attribute sequence of each state node; Step 3. Construct an attribute-aware graph-sequence joint encoding model to encode the activity sequence and state sequence of Step 1 and the heterogeneous activity-state graph of Step 2, and extract temporal evolution features and graph structure features. This graph-sequence joint coding model includes two parallel branches: a sequence modeling branch and a graph modeling branch. The sequence modeling branch takes the activity sequence and the state sequence as input and extracts the features of the activity sequence and the state sequence, respectively. The graph modeling branch takes a heterogeneous activity-state graph as input, encodes and fuses the multidimensional attribute sequences corresponding to each state node, and obtains the initial features of the state node with fused attribute information. Simultaneously, each active node is embedded and encoded to obtain the initial features of the active nodes; Then, the initial features of the state nodes and the initial features of the active nodes are input into the heterogeneous graph convolution module, and the neighbor information is aggregated along different edge types to obtain the state node features and active node features after fusing neighborhood information. The features of state nodes and active nodes are pooled and fused separately to obtain graph structure features; Step 4. Concatenate the activity sequence features, state sequence features, and graph structure features along the feature dimension, and output the probability distribution of the next activity through a fully connected layer and a softmax function. Use the activity with the highest probability as the prediction result.

[0012] Furthermore, based on the business process prediction method based on attribute-aware heterogeneous graphs and dual-temporal joint coding, this invention also proposes a corresponding business process prediction system based on attribute-aware heterogeneous graphs and dual-temporal joint coding.

[0013] A business process prediction system based on attribute-aware heterogeneous graphs and dual-temporal joint coding includes the following modules: The data preprocessing module is used to extract each process instance and the prefix trajectory of each process instance from the historical event log of the loan approval business process, and obtain the activity sequence, state sequence and multi-dimensional attribute sequence corresponding to each prefix trajectory. The heterogeneous graph construction module is used to construct a heterogeneous activity-state graph containing activity nodes, state nodes, and directed edges by utilizing each prefix trajectory and its corresponding state sequence and multidimensional attribute sequence, and to collect the attribute sequence of each state node. The graph-sequence joint coding module is used to build an attribute-aware graph-sequence joint coding model, which encodes the activity sequence and state sequence in step 1 and the heterogeneous activity-state graph in step 2 respectively, and extracts temporal evolution features and graph structure features. This graph-sequence joint coding model includes two parallel branches: a sequence modeling branch and a graph modeling branch. The sequence modeling branch takes the activity sequence and the state sequence as input and extracts the features of the activity sequence and the state sequence, respectively. The graph modeling branch takes a heterogeneous activity-state graph as input, encodes and fuses the multidimensional attribute sequences corresponding to each state node, and obtains the initial features of the state node with fused attribute information. Simultaneously, each active node is embedded and encoded to obtain the initial features of the active nodes; Then, the initial features of the state nodes and the initial features of the active nodes are input into the heterogeneous graph convolution module, and the neighbor information is aggregated along different edge types to obtain the state node features and active node features after fusing neighborhood information. The features of state nodes and active nodes are pooled and fused separately to obtain graph structure features; The system also includes a prediction output module, which concatenates activity sequence features, state sequence features, and graph structure features along the feature dimension, outputs the probability distribution of the next activity through a fully connected layer and a softmax function, and uses the activity with the highest probability as the prediction result.

[0014] The present invention has the following advantages: To address the shortcomings of existing business process prediction methods, such as the inability of graph models to distinguish semantic differences of the same activity in different execution contexts, insufficient utilization of multi-dimensional event attributes, and failure of existing methods to effectively combine process structure information with temporal evolution information, this invention provides a business process prediction method based on attribute-aware heterogeneous graphs and dual-temporal joint encoding. This method introduces state nodes on top of traditional graph modeling, decomposing the direct transition from "activity → activity" into a composite path of "activity → state → activity." This enables the model to distinguish semantic differences of the same activity in different execution contexts, solving the fundamental problem of existing graph methods treating all occurrences equally and failing to differentiate contextual semantics. This invention designs an attribute fusion module that weights and fuses multi-dimensional attributes (such as execution role, timestamp, resources, etc.) from event logs through a gating mechanism and injects them into state node representations. This allows state nodes to carry contextual conditions that lead to differences in activity transitions, effectively improving the model's efficiency in utilizing event attributes. In addition, this invention also designs a parallel architecture that combines heterogeneous graph convolution with dual temporal coding. The heterogeneous graph convolution captures the structural dependence of the process, and the dual LSTMs encode the temporal evolution of the activity sequence and the state sequence respectively. This avoids the problem of sequence information loss caused by serial processing in existing graph sequence combination methods, and realizes the joint learning of structural information and temporal information. Attached Figure Description

[0015] Figure 1 This is an overall flowchart of the attribute-aware heterogeneous graph-sequence joint prediction method in this embodiment of the invention; Figure 2 This is a schematic diagram of the heterogeneous activity-state diagram construction process in an embodiment of the present invention; Figure 3 This is a schematic diagram comparing isomorphic and heteromorphic graphs in an embodiment of the present invention; Figure 4 This is a network structure diagram of the attribute-aware graph-sequence encoder in an embodiment of the present invention; Figure 5 This is a schematic diagram of model sensitivity analysis in an embodiment of the present invention; wherein Figure 5(a) in the figure represents the sensitivity analysis of the number of convolutional layers in heterogeneous graphs. Figure 5 (b) in the diagram represents the sensitivity analysis of the hidden layer dimension (hidden_dim). Detailed Implementation

[0016] The present invention will be further described in detail below with reference to the accompanying drawings and specific embodiments: Example 1 like Figure 1 As shown, to address the problems in existing methods for predicting the next activity in loan approval processes—namely, the neglect of process structure information by sequence models, the inability of graph models to distinguish semantic differences of the same activity in different contexts, and the serial processing and insufficient utilization of attributes in graph-sequence combined models—this invention proposes a business process prediction method based on attribute-aware heterogeneous graphs and dual-temporal joint encoding. This method constructs a heterogeneous activity-state graph, fuses multi-dimensional event attributes, and employs heterogeneous graph convolution and dual LSTM parallel encoding to achieve unified learning of structural dependencies and temporal evolution, thereby improving the accuracy of predicting the next activity in complex business processes such as loan approval. Specifically, the method of this invention mainly includes the following four stages: 1) Data preprocessing stage: Extract the activity sequence, state sequence, and multi-dimensional event attributes (such as execution resources, timestamps, processing amounts, etc.) for each process instance from the raw event log. Among them, the state sequence is generated based on the adjacency relationship between activity pairs and is used to characterize the state differences of the same activity in different execution contexts.

[0017] 2) Heterogeneous Activity-State Graph Construction Phase: Activity nodes and state nodes are treated as two types of nodes and connected by two types of directed edges, namely "activity → state" and "state → activity", forming a transformation path of "activity → state → activity". This enables the model to distinguish the semantic differences of the same activity in different contexts and collect the corresponding attribute sequence for each state node.

[0018] 3) Attribute-aware graph-sequence joint encoding stage: Construct an encoding model containing two parallel branches.

[0019] The sequence modeling branch takes the activity sequence and state sequence as input and uses dual LSTMs to encode the temporal evolution information respectively; The graph modeling branch takes the heterogeneous activity-state graph and the attribute sequence of state nodes as input. First, it injects multi-dimensional attributes into the initial representation of state nodes through the attribute fusion module. Then, it uses heterogeneous graph convolution to aggregate neighbor information along the edge type to obtain graph structure features.

[0020] The two branches are executed in parallel, which avoids the problem of loss of sequence information caused by serial processing in existing methods.

[0021] 4) Next Activity Prediction Stage: The activity representation and state representation output by the sequence modeling branch are fused with the graph representation output by the graph modeling branch. The probability distribution of the next activity is output through a fully connected layer and a softmax function, and the activity with the highest probability is used as the prediction result.

[0022] Through the collaborative processing of the above four stages, the semantic differences of the same activity in different execution contexts can be effectively distinguished, the multidimensional attribute information in the event log can be fully utilized, and the next activity can be predicted stably and accurately in complex processes such as loan approval.

[0023] The business process prediction method based on attribute-aware heterogeneous graphs and dual-temporal joint coding includes the following steps: Step 1. Extract each process instance and its prefix trajectory from the historical event log of the loan approval business process, and obtain the activity sequence, state sequence and multi-dimensional attribute sequence corresponding to each prefix trajectory.

[0024] This invention first extracts each process instance from the historical event logs of the loan approval business process and sorts them in ascending order by timestamp to obtain the prefix trajectory of each process instance. The activity name and event attributes of each prefix trajectory are then encoded, and state encoding is performed based on the adjacency relationships between activities. The encoding results are then sequenced in chronological order to obtain the activity sequence, state sequence, and multidimensional attribute sequence corresponding to each prefix trajectory. The activity sequence consists of encoded activity identifiers arranged in chronological order; the state sequence consists of corresponding state identifiers arranged in the same chronological order. Attribute encoding is used to convert the resource, timestamp, and amount fields associated with each event into numerical representations and store them as multidimensional attribute sequences.

[0025] The experimental datasets are the real loan process logs from Dutch financial institutions, BPI Challenge 2012 and BPI Challenge 2017. These datasets record events related to loan applications, quote processing, and manual processing tasks, and can be downloaded from https: / / data.4tu.nl / datasets.

[0026] Step 1 takes the original event log as input and unfolds according to four sub-steps: activity coding, status coding, attribute coding, and sequence construction. It outputs the activity sequence, status sequence, and multi-dimensional attribute sequence for each process instance.

[0027] This invention uses a traditional event log, where each line records one event, and each event belongs to only one process instance (case). As shown in Table 1, each line in the event log represents one event.

[0028] Each event includes fields such as case number, event name, timestamp, resources, and amount. For clarity, Table 1 shows a partial record excerpt from the event log.

[0029] Table 1 Example of an event log

[0030] First, each process instance (grouped by case number) is extracted from the event log and sorted in ascending order by timestamp to obtain the prefix trajectory for each instance. Based on this, the events in each prefix trajectory are sequentially encoded in terms of activity, attribute, and status. The encoding results are then used to construct a sequence in chronological order to obtain the activity sequence, multidimensional attribute sequence, and status sequence corresponding to each prefix trajectory.

[0031] Step 1.1. Activity coding and attribute coding.

[0032] First, extract each process instance from the event log and sort it in ascending order by timestamp to obtain the prefix trajectory of each process instance; for each event in the prefix trajectory, extract the activity name and attribute fields respectively, and perform numerical mapping independently.

[0033] Activity coding maps activity names in the event log to numeric indices.

[0034] Let the set of activities be The size of the activity set is Map different activity names to 1 to | | consecutive integers, for any activity Its activity code is represented as .

[0035] in, This represents the numerical index corresponding to the activity, used to identify different activities.

[0036] For example, in Table 1, the activity "Application" is mapped to 1, "Submission" is mapped to 2, "Rejection" is mapped to 3, and so on.

[0037] Attribute encoding involves discretizing and encoding the resource, timestamp, and amount fields associated with each event.

[0038] Among them, the resource field is a discrete category and is encoded with an integer index; the amount field is a continuous value and is discretized using an equal-frequency binning strategy, which divides the value distribution evenly into several intervals and maps them to integer indices.

[0039] The timestamp field is split into multiple time features such as year, month, day, hour, time period, weekday, whether it is a weekend, and event duration, and each feature is discretized and encoded to obtain the corresponding attribute encoding results.

[0040] Simultaneously, location features are introduced, using the position number of the event in its prefix trajectory to obtain the corresponding location code.

[0041] It should be noted here that the position field represents the position number of the current event in the trajectory (incrementing from 0). Since the subsequent model can handle continuous input, it is retained as a continuous value and is not discretized.

[0042] For example, using the timestamp "2012-02-29 23:28:55": The date is Wednesday, and 11 PM is evening. If this event is the first event in the process instance, its duration is recorded as 0, and the corresponding time characteristic can be represented as: (2012,2,29,23,2,3,0,0).

[0043] The time characteristics mentioned above are, in order: year, month, date, hour, time period, weekday, whether it is a weekend, and duration of the event.

[0044] Among them, time period code 2 indicates evening, weekday code 3 indicates Wednesday, whether it is a weekend code 0 indicates that the date is not a weekend, and event duration 0 indicates that the event is the first event in the process instance.

[0045] Step 1.2. State coding.

[0046] To distinguish the differences in subsequent behaviors of the same activity in different contexts, state encoding is performed.

[0047] Based on the activity set in the historical event log, any two activities are combined in an ordered manner to obtain all ordered activity pairs. A global state mapping table is pre-built based on all ordered activity pairs, and a unique state identifier is assigned to each ordered activity pair.

[0048] Let A be the set of activities. Then any ordered pair of activities... Each corresponds to a status identifier, which is calculated as follows: ; in To ensure orderly activities The corresponding status identifier; and For the event and exist The index in.

[0049] Based on this, state encoding is performed on the ordered activity pairs in each prefix trajectory. The specific process is as follows: For any adjacent events in each prefix trajectory and Extract their corresponding activities respectively and Its status code is determined by the current activity. With the next event A joint decision.

[0050] Finding Ordered Activity Pairs The corresponding state identifier in the global state mapping table is used as the state code for the current position, i.e.: .

[0051] in Indicates the first The status code corresponding to each position. This represents the state identifier in the global state map table.

[0052] For the last activity of the prefix trajectory, since its subsequent activities are unknown and cannot form a complete ordered activity pair, its state code is set to the end identifier, and its value is set to |A|² + 1.

[0053] For example, if |A|=10, and the activity indices are 1 and 2 respectively, then the state identifier corresponding to the activity pair (1,2) is (1-1)×10+2=2.

[0054] For the prefix trajectory [application, submission, rejection], the status codes at each position are as follows: position 1 takes the status identifier of the activity pair (application, submission), position 2 takes the status identifier of the activity pair (submission, rejection), and position 3 takes the end identifier.

[0055] Step 1.3. After completing the activity encoding, attribute encoding, and state encoding in steps 1.1 and 1.2, assemble the encoding results into a sequence in chronological order (i.e., sequence construction) as input for the subsequent model.

[0056] For including Prefix trajectory of events , of which The activity corresponding to each event is For ease of representation, the following will use... This indicates the activity corresponding to each event in the prefix trajectory.

[0057] Its activity sequence, state sequence, and multidimensional attribute sequence are represented as follows: Activity sequence This involves arranging the activity codes corresponding to each event in chronological order; among which... , , , Indicates the activity in the prefix trajectory; This indicates the corresponding activity code.

[0058] State sequence S That is, the state codes corresponding to each position are arranged in chronological order according to the prefix trajectory, where This is the end identifier.

[0059] Multidimensional attribute sequence .in , , Indicates an event, These represent the multidimensional attribute vectors of the event.

[0060] Ultimately, the lengths of both the activity sequence and the state sequence obtained in step 1 are... Together, they are fed into the subsequent sequence modeling branch; the multidimensional attribute sequence obtained in step 1 is used to inject attribute information into the state nodes when constructing the heterogeneous graph in step 2.

[0061] Step 2. Utilize the multidimensional attribute sequences of each process instance and combine them with prefix trajectory information to construct a heterogeneous activity-state diagram, which is used to explicitly depict the topological structure of the loan approval business process and the transition relationship of the same activity in different execution contexts.

[0062] The heterogeneous activity-state graph contains two types of nodes: activity nodes and state nodes, as well as two types of directed edges: activity-to-state and state-to-activity. These two types of edges are alternately connected to form a composite transition path of "activity → state → activity," which is used to explicitly depict the topology of the loan approval business process and the transition relationship of the same activity in different execution contexts. The graph also collects the corresponding attribute sequence for each state node.

[0063] Heterogeneous graphs are graph structures that contain multiple types of nodes and edges, and can characterize complex semantic relationships between different entities.

[0064] The heterogeneous activity-state diagram constructed by this invention contains two types of nodes: one type is activity nodes, which represent specific steps in the business process, such as "application", "review" and "rejection" in loan approval; the other type is state nodes, which represent intermediate states between adjacent activity pairs, such as the transition from "review" to "rejection" being abstracted as a state node.

[0065] The two types of nodes are connected by two types of directed edges. One type is activity → state edges, which indicate that after an activity is executed, the node enters the corresponding intermediate state; the other type is state → activity edges, which indicate that the intermediate state leads to subsequent activities.

[0066] The two types of edges are connected alternately to form a composite transition path of "activity → state → activity".

[0067] Compared to traditional isomorphic graphs that directly connect activities, the core improvement of this design lies in the introduction of state nodes. Conditions that affect the subsequent development of the same activity (such as resources, amount, etc.) are recorded on the state nodes in the form of attribute sequences, which is used to distinguish the behavioral differences of the same activity in different contexts.

[0068] The multidimensional attribute sequence provides data support for this purpose. After the attributes such as resources, timestamps, and amounts associated with each event in step 1 are stored, they are aggregated by state nodes in this step to form the attribute sequence of each state node.

[0069] These attribute sequences contain implicit conditions that influence the direction of transition, such as different reviewers and application amounts, which need to be learned during subsequent model training. By binding attributes to state nodes in a structured manner, the model can distinguish under what conditions the same activity will proceed to which subsequent path.

[0070] The heterogeneous activity-state graph is constructed through three steps: node construction, edge construction, and state node attribute collection.

[0071] Step 2.1. Node construction.

[0072] From the activity sequence and state sequence corresponding to the prefix trajectory obtained in step 1, extract the activity nodes and state nodes respectively, as follows: extract the activity nodes and state nodes according to the element in the activity sequence. and state sequence The order in which they appear is used to traverse the list.

[0073] When an element appears for the first time, it is added to the corresponding node set. If the same element appears again, it will not be added again, thus extracting the unique element in the activity sequence and state sequence.

[0074] Construct activity node set and state node set .

[0075] Node set Each activity node represents an activity type (such as "application"), and each status node represents an activity pair type (such as the status corresponding to the transition from "application" to "approval").

[0076] Extracting unique elements is to ensure that each node represents a type rather than a specific occurrence.

[0077] For example, the word "application" may appear multiple times in the trajectory, but only one "application" activity node is retained in the graph; only one node of the same state type is also retained. The position of this type is different each time it appears, and its information is reflected through the connection relationship of the edges.

[0078] Each occurrence generates an edge from the active node to the state node or from the state node to the active node. These edges collectively record all transitions involved in that type. The resulting complete set of nodes forms the basis for subsequent edge construction.

[0079] Step 2.2. Edge construction.

[0080] Once the nodes are determined, edges need to be added between them based on the adjacency relationships in the prefix trajectory. The logic for edge construction is to extract two transition relationships from the trajectory: "activity → state" and "state → activity".

[0081] Based on the activities corresponding to adjacent events in the prefix trajectory, ordered activity pairs are obtained. Connection edges are constructed between activity nodes and state nodes, with state nodes representing the transition relationships between activities. Specifically: For a prefix trajectory containing k events, let To ensure orderly activities The corresponding state nodes, among which .

[0082] For each position in the prefix trajectory At the activity node With state nodes Add an edge between "activity → state" to indicate that after the activity is executed, it enters a state sequence of ordered activities. The corresponding intermediate state. In the state node. With the next activity node Add an edge between "state → activity" to indicate that the intermediate state leads to the subsequent activity.

[0083] The two types of edges are connected alternately to form a heterogeneous path of "activity → state → activity → state → ... → activity → end state".

[0084] For the last event in the prefix trajectory, only add the active node corresponding to that event. To the state node corresponding to the end identifier The "activity → state" edge is not added. The edge set E is written as: .

[0085] From an implementation perspective, the input structure required by a graph model uses an array of starting nodes and an array of target nodes to represent edges. Since this invention constructs a heterogeneous graph containing two edge types, four sets of arrays are needed, with each pair of arrays corresponding to one edge type.

[0086] From the prefix trajectory activity sequence and state sequence Set off: For the "Activity → State" edge, the starting node array is: The corresponding target node array is ; For the "State → Activity" edge, the starting node array is: The corresponding target node array is The two types of edges mentioned above together constitute a complete edge set.

[0087] This edge construction method can generate all directed edges in batches, which facilitates the establishment of graph edge indexes. At the same time, it preserves the original sequence information of events in the trajectory, enabling subsequent graph neural networks to simultaneously perceive the structural topology and temporal evolution of the process.

[0088] Step 2.3. Collect the attributes of the state nodes.

[0089] State nodes are identified by their activity number only; they do not contain contextual information that causes differences in activity transitions.

[0090] In order for the state nodes to reflect "why the same activity leads to different subsequent activities", the multidimensional attributes encoded in step 1 need to be aggregated according to the state nodes as the attribute sequence of each state node.

[0091] The multidimensional attribute sequence from step 1 is aggregated according to the state nodes to form the attribute sequence corresponding to each state node; for each position in the prefix trajectory , the event Multidimensional attribute vector Associated with the corresponding state node middle.

[0092] If multiple positions correspond to the same state node, then only one node representation is retained for that state node, and the multidimensional attribute vectors of the corresponding events are aggregated according to the order of appearance of the events in the prefix trajectory to form the attribute sequence of that state node.

[0093] In the attribute sequence, each attribute dimension is stored according to the order in which its corresponding event occurs, in order to preserve the attribute change information of the events associated with the state node. Let the state node... The set of all location indices appearing in the trajectory is: ,but The attribute sequence is defined as: ;in, Elements in the array are indexed by position Ascending order; This is the multidimensional attribute vector encoded in step 1.

[0094] Each This is the multidimensional attribute vector encoded in step 1, containing fields such as resource, timestamp components, and amount.

[0095] For each trajectory, after collecting the attribute sequences of all state nodes, organize them according to the order of the deduplicated state nodes. If a state node does not appear in the current trajectory, its attribute sequence is an empty sequence.

[0096] This method allows the attribute information carried by the same state node to be preserved when it appears on different trajectories or in different locations.

[0097] Subsequent models can capture the attribute evolution of the same state node at different times by using sequence coding modules (such as GRU), thereby learning decision knowledge on "which path to take under what attribute conditions".

[0098] Figure 2 The process of constructing the heterogeneous activity-state diagram described above is illustrated.

[0099] The above section shows the activity sequence and state sequence extracted from the prefix trajectory of case-214370 in Table 1.

[0100] The prefix track contains 11 events, with the corresponding activity sequence being [Application, Submission, Rejection, Processing Clues, Application, Submission, Approval, Supplementary Materials, Review, Application Confirmation, Selected Solution], and the status sequence being [2, 12, 22, 28, 2, 14, 42, 52, 62, 82].

[0101] The state sequence is calculated from adjacent activity pairs, and the end identifier is contained in the last position of the state sequence (i.e., 82 corresponds to the last activity pair or the final state). The arrow pointing downwards indicates that these two sequences are transformed into a heterogeneous graph through node and edge construction. Activity nodes (such as "Application") and state nodes (such as 12) are alternately connected in the graph, forming a composite path of "Activity → State → Activity → State → ... → Final State". It should be noted that... Figure 2 This mainly shows the topological connections of the graph structure. The attribute sequences of state nodes are not drawn in the graph, and their collection method has been explained separately in the "State Node Attribute Collection" section.

[0102] Figure 3 The motivation of the present invention is illustrated by the comparison between isomorphic and heteromorphic diagrams.

[0103] In the isomorphic graph on the left, activity A is directly connected to activities B and C. The two edges cannot distinguish the conditions under which A→B and A→C occur, meaning that the two transitions are treated equally in the graph.

[0104] In the heterogeneous diagram on the right, this invention introduces state nodes s1 and s2, decomposes A→B into A→s1→B, decomposes A→C into A→s2→C, and records the attribute information such as the amount corresponding to each transfer on state nodes s1 and s2.

[0105] For example in Figure 3 In the diagram, the amount next to state node s1 is 5000, and the amount next to state node s2 is 20000, indicating that when the amount is 5000, the path is A→C, and when the amount is 20000, the path is A→B.

[0106] Thus, the trajectory of the same activity A under different monetary conditions is explicitly distinguished, and the model learns the judgment criteria of "how the amount affects the process trajectory", solving the problem that the same activity is treated equally in different contexts in traditional methods.

[0107] Thus, we have obtained a set containing active nodes. State Node Set Edge set E and attribute sequences of each state node The heterogeneous activity-state diagram preserves the execution trajectory topology of the loan approval business process while distinguishing the transition differences of the same activity in different execution contexts through state nodes and their attribute sequences.

[0108] The active nodes and state nodes currently only have type identifiers and do not yet contain learnable feature representations. They will be assigned initial feature vectors in step 3 through independent embedding matrices.

[0109] The heterogeneous activity-state graph structure of this invention is novel. This invention introduces state nodes into process prediction for the first time, and explicitly describes the transformation semantics of activities in different execution contexts with a composite edge structure of "activity → state → activity", which solves the problem that traditional isomorphic graphs cannot distinguish the semantic differences of the same activity in different trajectories.

[0110] Step 3. Build an attribute-aware graph-sequence joint encoding model to encode the activity sequence and state sequence generated in Step 1 and the heterogeneous activity-state graph constructed in Step 2, and extract temporal evolution features and graph structure features respectively.

[0111] This graph-sequence joint coding model can provide fused feature inputs for subsequent predictions.

[0112] Step 3 uses the activity sequence output in Step 1. State sequence The heterogeneous activity-state graph output from step 2 is used as input, and feature encoding is performed through two parallel branches: sequence modeling and graph modeling.

[0113] Heterogeneous activity-state graph contains a set of activity nodes State Node Set And the attribute sequence of each state node .

[0114] The sequence modeling branch uses dual LSTMs to capture the temporal evolution information at the activity level and the state level, respectively.

[0115] The graph modeling branch first injects multi-dimensional attributes into the state nodes through the attribute fusion module, then aggregates neighbor information along the edge type using heterogeneous graph convolution, and finally obtains graph structure features through pooling.

[0116] like Figure 4 As shown, the graph-sequence joint coding model includes a sequence modeling branch (upper branch) and a graph modeling branch (lower branch). The outputs of the two branches are activity sequence features, state sequence features, and graph structure features, respectively.

[0117] The three feature vectors above all have a dimension of d, and will be used as input for fusion prediction in step 4.

[0118] I. Sequence modeling branch section.

[0119] The input to this branch is the activity sequence generated in step 1. and state sequence .

[0120] Activity sequence and state sequence They have the same length (both are k), but different semantics, as detailed below: Activity sequences record the order of event types, reflecting the macro-level execution path of the business process; state sequences record the transition relationships between adjacent activity pairs, reflecting the micro-level state transitions.

[0121] The activity sequence and the state sequence are encoded using separate LSTMs for two reasons: First, the execution of the process has a natural temporal order, and LSTM can effectively capture long-term dependencies (such as the impact of previous activities on the current decision). Second, the evolution between states also has temporal order (such as s1→s2→s3), and modeling them separately can capture the dynamic characteristics of the transition path, and the two branches do not interfere with each other.

[0122] Specifically, the activity sequence is embedded through independent activity embedding layers and state embedding layers respectively. and state sequence The discrete numerical indexes in the vector are mapped to continuous vectors, resulting in the activity embedding sequence and the state embedding sequence.

[0123] Let the activity embedding matrix be The state embedding matrix is Where |A| is the total number of activities, |A|² corresponds to all possible activity pairs, plus 1 corresponds to the end identifier, and d is the embedding dimension; In this embodiment, the embedding dimension d is set to 256, for example.

[0124] According to the activity sequence The activity encoding in the activity embedding matrix Obtain the corresponding embedding vector from the data to obtain the active embedding sequence. According to the state sequence State encoding in the state embedding matrix Obtain the corresponding embedding vector to get the state embedding sequence. .

[0125] Embedding activities into sequences and state embedding sequence The activity sequence and state sequence are encoded separately using independent LSTM and LSTM methods, and the hidden state at the last time step is taken as the activity sequence feature vector and state sequence feature vector of the corresponding prefix trajectory. ; .

[0126] in This represents the feature vector of the activity sequence corresponding to the prefix trajectory. This represents the feature vector of the state sequence corresponding to the prefix trajectory. The two outputs of the sequence modeling branch. , The temporal evolution at the activity level and the transition evolution at the state level were captured respectively, both with dimension d, and were subsequently concatenated with graph structure features.

[0127] Dual LSTM modeling based on state sequences constructs additional state sequences and encodes them independently, in addition to the regular activity sequences. This enables the model to simultaneously perceive the execution order of activities and the state transition path, enhancing its ability to model complex processes.

[0128] II. Graph modeling of branches.

[0129] The input to this graph modeling branch is the heterogeneous activity-state graph constructed in step 2. Graph convolution can utilize the graph structure to pass information between nodes, allowing activity nodes and state nodes to update features with each other, thereby reflecting the structural dependencies between activities (such as parallel branches and loop backoffs), and making up for the lack of ability of sequence modeling to model structural information.

[0130] The graph modeling branch is processed in the following order: first, the nodes are initialized; then, multi-dimensional attributes are injected into the state nodes through the attribute fusion module; then, neighbor aggregation is performed through multi-layer heterogeneous graph convolution; and finally, graph structure features are obtained through pooling.

[0131] II.1. Node initialization; The active nodes in the active node set and the state nodes in the state node set each obtain initial features using independent embedding matrices, as detailed below: Active nodes use an embedding matrix Obtain the initial features of the active node State nodes use embedding matrices Obtain the original embedding features of the state nodes ; Activity nodes directly As the initial features of the active node, and the corresponding state node, its original embedded features. The initial features of the state nodes also need to be formed by fusing attribute information.

[0132] II.2. Then proceed to the attribute fusion module.

[0133] The attribute fusion module is used to extract and fuse features from the multidimensional attribute sequences corresponding to state nodes.

[0134] Specifically, the attribute fusion module first independently encodes different types of attributes to obtain the temporal features corresponding to each attribute; then, it calculates attribute weights based on the contribution of different attributes to the representation of state nodes, and uses these attribute weights to adaptively fuse the attribute features to obtain fused attribute features. The specific process is as follows: Steps 1 and 2 extract multidimensional attributes (resources, timestamp components, amount, etc.) for each event. These attributes are aggregated into an attribute sequence by state node. .

[0135] The attribute sequence of each state node records the attribute vector of the event corresponding to each occurrence of that state node, and the sequence length is equal to the number of times that state node appears in the trajectory.

[0136] The attribute values ​​of the same state node may differ when it appears in different locations.

[0137] For example, if state node s corresponds to activity pair (application, submission), the first occurrence may be in the early morning and the second in the morning, with different time attributes. These differences may lead to different subsequent activities for the same state.

[0138] Therefore, the attribute fusion module performs temporal encoding on the attribute sequence corresponding to each state node to capture the dynamic changes in attribute information during trajectory execution. Each attribute is mapped to a continuous vector through an independent embedding layer or linear layer. The continuous vector sequences corresponding to different attributes are input into independent gated recurrent units (GRUs) for encoding, and the hidden state of the last step of each GRU is used as the corresponding attribute feature vector.

[0139] Let the number of attribute types be m, and let the feature vector of each attribute be denoted as m. .

[0140] The contribution weight of each attribute feature vector is determined using an attribute weighting calculation mechanism, as shown in the following formula: .

[0141] in, This represents vector concatenation. This indicates the contribution weight corresponding to each attribute. and These represent the weight matrix and bias vector of the attribute weight calculation layer, respectively.

[0142] Weighted fusion is performed based on the contribution weight of each attribute: .

[0143] Fuse attribute feature vectors Projected onto d-dimensional planes via linear layers to obtain Then, combined with the original embedded features of the state node Add them together to form the initial features of the state node: .

[0144] The attribute fusion module of this invention injects the multi-dimensional attributes of an event (time, resources, numerical fields, etc.) into the state node representation after weighted fusion through a gating mechanism, so that the state node can carry the context conditions that lead to differences in activity transition.

[0145] II.3. After completing attribute fusion, the initialized node features are fed into the heterogeneous graph convolution module.

[0146] After initialization, use the initial characteristics of the active node. As the input of the active node at level 0, that is: ; Initial features of state nodes after fusing attribute information As the input of the state node at level 0.

[0147] This implementation's heterogeneous graph convolution module contains L=3 layers of heterogeneous graph convolution, with each layer aggregating neighbor information for two edge types: "activity to state" and "state to activity".

[0148] The reason for using multi-layer convolution is that single-layer convolution can only aggregate the features of direct neighbors, while multi-layer convolution can gradually aggregate the information of non-directly connected nodes, thereby perceiving a wider range of process structures.

[0149] In the In the heterogeneous graph convolution, the "activity-to-state" edge `actTostate` transmits information from the active node `a` to the state node `s` and updates the state node's features; conversely, the "state-to-activity" edge `stateToact` transmits information from the state node `s` to the active node `a` and updates the active node's features. For state node `s`, the th... The features of a layer are represented as follows: .

[0150] in AGG uses mean pooling to define the set of active nodes that point to state node s via "activity-to-state" edges. Indicates the first The weight matrix used in the layer to transform the features of active neighbor nodes; This represents the weight matrix used to transform the characteristics of the state node itself.

[0151] For activity nodes , its first Layer features are represented as: .

[0152] in, This indicates that the "state to activity" edge points to the activity node. A set of state nodes.

[0153] Indicates the first The weight matrix in the layer used to transform the features of neighboring nodes in the state; This represents the weight matrix used to transform the features of the active node itself. All weight matrices mentioned above are parameters learned during model training.

[0154] After each layer of heterogeneous graph convolution, non-linear activation and random deactivation (dropout, set to 0.3 in this example) are applied to the features of active nodes and state nodes respectively to alleviate overfitting. The final features of the active nodes are obtained after three layers of heterogeneous graph convolution. and final features of state nodes .

[0155] Subsequently, the final features of the activity nodes were analyzed respectively. and final features of state nodes Perform global mean pooling to obtain graph-level feature vectors for active nodes and graph-level feature vectors for state nodes: .

[0156] ; in This represents the graph-level feature vector of active nodes obtained by aggregating the features of all active nodes. This represents the graph-level feature vector of state nodes obtained by aggregating the features of all state nodes.

[0157] The two pooling results are concatenated and then compressed through a fully connected layer to obtain the graph structure features: .

[0158] in This represents a vector concatenation operation. and These represent the weight matrix and bias vector of the graph feature fusion layer, respectively.

[0159] At this point, step 3 completes the feature encoding, outputting three feature vectors: the activity sequence features of the sequence modeling branch. State sequence features And the graph structure features of graph modeling branches All dimensions are d.

[0160] Unlike existing methods that sequentially stack graph convolution and sequence models, this invention employs a dual-branch parallel architecture. Graph convolution extracts structural dependencies, and dual LSTMs encode the temporal evolution of activity sequences and state sequences respectively, achieving joint learning of structural and temporal information. The three feature vectors described above characterize the current prefix trajectory from the perspectives of activity temporal evolution, state transition path, and topological structural dependencies, and will be used as input for fusion and prediction in step 4.

[0161] Step 4. Feature fusion and prediction output.

[0162] After obtaining the three feature vectors, fusion and prediction are required in step 4.

[0163] The activity sequence features output in step 3 State sequence features Sum graph structural features By concatenating along the feature dimensions, a comprehensive feature vector is obtained. : .

[0164] The three features characterize the current prefix trajectory from different perspectives: the activity sequence feature focuses on the order of event types, the state sequence feature focuses on the dynamics of the transition path, and the graph structure feature focuses on structural dependencies.

[0165] The splicing dimension is 3d (in this embodiment, d=256, so it is 768). Direct splicing is the simplest fusion method, which does not introduce additional parameters and allows subsequent fully connected layers to learn the weight combination of each part on their own.

[0166] The comprehensive feature vector z is input into a fully connected layer, and the output dimension is |A| (number of activity categories). Then, the probability distribution of the next activity is obtained by passing the softmax function. The formula is as follows: .

[0167] in and These are learnable parameters.

[0168] Take the activity with the highest probability as the prediction result: .

[0169] The core of this invention lies in constructing a heterogeneous activity-state graph. By introducing state nodes, the direct transition from "activity → activity" is decomposed into a composite path of "activity → state → activity." Furthermore, the semantic differences of the same activity in different execution contexts are distinguished by the attribute sequences attached to the state nodes. Based on this, an architecture employing parallel encoding of sequence modeling branches and graph modeling branches is adopted. This allows the model to simultaneously capture the structural dependencies of the process, the temporal characteristics of the event sequence, and attribute-driven contextual changes, thereby improving the accuracy and robustness of predicting the next activity in the loan approval business process.

[0170] The model training is not limited to cross-entropy loss; mean squared error loss or contrastive learning loss can also be used as the objective function. In addition to Adam, optimizers such as SGD or RMSProp can be used to improve convergence speed and stability.

[0171] The hyperparameters used in this embodiment (learning rate 0.00025, batch size 128, training epochs 50) can be adjusted according to the specific dataset size, and the optimal value of the weight decay coefficient can also be determined through grid search.

[0172] After model training, actual deployment is carried out, and the specific reasoning process is as follows: The collected loan approval business process event logs are first transformed into activity sequences, state sequences, and multi-dimensional attribute sequences through step 1. Then, a heterogeneous activity-state graph is constructed through step 2, and attribute sequences are collected for each state node. At this point, the resulting heterogeneous activity-state graph contains a set of activity nodes, a set of state nodes, an edge set consisting of two types of directed edges: "activity → state" and "state → activity," and the attribute sequences of each state node. Step 3 builds an attribute-aware graph-sequence joint encoding model to encode the above information. The sequence modeling branch extracts the temporal evolution features of the activity sequence and state sequence, while the graph modeling branch extracts structural features through attribute fusion and heterogeneous graph convolution. Step 4 fuses the three features and outputs the probability distribution of the next activity.

[0173] In actual deployment, when a new process prefix (i.e., a sequence of completed events) is received, the system converts the prefix into a heterogeneous activity-state diagram and attribute sequence according to the processing methods in steps 1 and 2. Then, steps 3 and 4 calculate the probability of each candidate next activity and output the activity with the highest probability as the prediction result. This prediction result can be used in scenarios such as real-time process monitoring, dynamic resource allocation, and abnormal behavior early warning, without the need for manual annotation or offline comparison.

[0174] Compared with existing methods, the present invention has significant advantages in at least the following aspects: (1) Contextual semantic discrimination ability: This invention introduces state nodes to decompose the direct transition from "activity → activity" into a composite path of "activity → state → activity". This enables the model to distinguish the semantic differences of the same activity in different execution contexts, solving the problem in traditional graph methods where the same activity is treated equally in different trajectories and subsequent behaviors cannot be distinguished.

[0175] (2) Attribute-aware state representation: This invention designs an attribute fusion module that dynamically learns the importance weights of each attribute (resource, time component, amount, etc.) to state transitions through a gating mechanism. Multidimensional attributes are injected into the initial representation of state nodes in a residual manner, enabling state nodes to carry contextual conditions that lead to transition differences, which significantly improves the model's efficiency in utilizing attribute information in event logs.

[0176] (3) Graph-sequence parallel coding mechanism: This invention employs heterogeneous graph convolution to capture the structural dependence of the process and dual LSTMs to capture the temporal evolution of the activity sequence and the state sequence respectively. This avoids the problem of feature loss or weakening of temporal information caused by serial processing of graphs and sequences in existing methods, and realizes joint learning of structural information and temporal information.

[0177] (4) Full-coverage state-space generalization capability: This invention employs a full-coverage state space construction strategy based on the Cartesian product of activity sets, which can handle the transformation of activity pairs that have not appeared in training. In actual deployment, there is no need to rebuild the graph structure or retrain the model due to the appearance of new activity pairs.

[0178] (5) Robustness and stability: The method of this invention is insensitive to changes in hyperparameters, and its performance remains stable when the number of convolutional layers and the dimension of hidden layers in heterogeneous graphs vary within a certain range. This makes it easy to determine near-optimal parameter configurations through conventional grid search in practical applications.

[0179] In addition, to verify the effectiveness of the method of the present invention, experiments were conducted on nine publicly available real business process event logs.

[0180] This embodiment uses three sub-datasets from the publicly available business process event log datasets BPI Challenge 2012 and BPIChallenge 2017: bpi17_Exi, bpi17_Hom, and bpi17_Oth. bpi12_all_complete contains complete loan approval process logs; BPI Challenge 2017 is divided into three sub-datasets based on case type, corresponding to Exi, Hom, and Oth loan application businesses, respectively, to verify the predictive ability of the method of this invention in different business scenarios. All datasets can be obtained from authoritative public sources such as the 4TU Center for Research Data.

[0181] The basic information for each dataset is shown in Table 2. The table provides the number of cases, events, activity types, trajectory variants, all possible states, actual states, number of attribute fields, variant diversity, and state coverage for each dataset.

[0182] Among them, the number of trajectory variants represents the number of different complete activity sequences in the dataset; the total number of possible states is the square of the number of activity types, representing the number of all possible ordered activity pairs in the activity set; the actual number of states represents the number of different ordered activity pairs that actually appear in the dataset; variant diversity is used to reflect the degree of distribution of different trajectory variants relative to all process instances; and state coverage is used to reflect the proportion of actual state types in all possible state types.

[0183] The above metrics are used to characterize the size, process behavior diversity, attribute information, and state space characteristics of each dataset. These metrics comprehensively reflect the size, complexity, and state space density of each dataset.

[0184] Table 2 Statistical information of the experimental dataset

[0185] All experiments were conducted using Python 3.8 and PyTorch 2.1.0. Three-fold cross-validation was used to evaluate model performance. In each fold, the dataset was divided into training and test sets at 80% and 20% respectively, with the remaining 20% ​​from the training set used as the validation set.

[0186] To determine the key hyperparameter configurations of the model, a parameter sensitivity analysis was first performed on the number of heterogeneous graph convolutional layers (num_layers) and the hidden layer dimension (hidden_dim) using the controlled variable method. Other hyperparameters were fixed based on the results of preliminary experiments. According to the parameter sensitivity analysis, the hidden layer dimension was ultimately set to 256, and the number of heterogeneous graph convolutional layers was set to 3. Other hyperparameter settings are as follows: learning rate of 0.00025, batch size of 128, dropout rate of 0.30, and number of training epochs of 50.

[0187] The dimensions of activity embedding, state embedding, and attribute embedding are all set to be consistent with the hidden layer dimensions. The sequence encoding module uses a single-layer LSTM with the same hidden and embedding dimensions. Heterogeneous graph convolution uses a combination of HeteroConv and SAGEConv, with mean pooling as the aggregation method. The optimizer is Adam. To evaluate prediction performance, this invention uses accuracy and macro F1 score as the main evaluation metrics. Accuracy measures the proportion of correct predictions overall, while macro F1 score is calculated for each activity category and then averaged to reflect the overall performance under uneven category distribution.

[0188] ; .

[0189] Where N is the total number of test samples. and These are predicted activities and actual activities, respectively. For indicator functions; and Precision and recall are respectively for activity a. To determine reasonable values ​​for key hyperparameters and analyze the model's sensitivity to parameter changes, the controlled variable method was used to examine the impact of the number of heterogeneous graph convolutional layers (num_layers) and the hidden layer dimension (hidden_dim) on the model's predictive performance. When analyzing num_layers, hidden_dim=256 and other hyperparameters remained unchanged; when analyzing hidden_dim, num_layers=3 and other hyperparameters remained unchanged.

[0190] Since parameter sensitivity analysis is mainly used to determine parameter configurations, the experiment is based on the best accuracy on the first fold validation set of each dataset, and the average precision is calculated as the average accuracy of the four datasets to comprehensively evaluate the performance of different parameter configurations. Figure 5 (a) and Figure 5 (b) shows the results of the parameter sensitivity analysis for num_layers and hidden_dim, respectively, where Average represents the average accuracy of the four datasets.

[0191] Depend on Figure 5 As shown in (a), the average accuracy of the model reaches its highest level when the number of convolutional layers increases from 2 to 3; when it continues to increase to 4, the average accuracy decreases slightly, indicating that appropriately increasing the number of graph convolutional layers helps to improve model performance, while excessively deep networks may introduce oversmoothing. Therefore, this invention sets num_layers to 3.

[0192] Depend on Figure 5 As shown in (b), the overall model performance gradually improves as hidden_dim increases from 64 to 256; however, when hidden_dim continues to increase to 512, the average accuracy decreases, indicating that an excessively large hidden layer dimension fails to further improve model performance. Therefore, this invention sets hidden_dim to 256 and adopts this parameter configuration in subsequent experiments.

[0193] To verify the effectiveness of the method of this invention, it was compared with three representative next activity prediction methods: MiTFM, which is based on sequence information modeling, and HiGPP and SGAP, which combine flowchart structure and sequence information. MiTFM uses multi-view information fusion and a Transformer network to model the process execution sequence; HiGPP uses historical process information to construct a graph structure and extracts process structure features through a graph neural network; SGAP predicts the next activity by constructing a sequence graph and fusing trajectory information. These methods cover next activity prediction methods based on sequence information and those fusing graph structure and sequence information, and can be used to verify the prediction performance of the method of this invention. Table 3 shows the accuracy and macro-average F1 score of each method on all datasets.

[0194] Table 3 Performance comparison of various methods on loan approval datasets

[0195] Experimental results show that the method of this invention achieves the best value in 7 out of 8 evaluation results across 4 datasets. On the BPI 2012, BPI 2017 Existing Loan Takeover, and BPI 2017 Home Improvement datasets, the accuracy and F1 score of the method of this invention are higher than the three comparative methods. On the BPI 2017 Other dataset, the accuracy of the method of this invention is slightly lower than MiTFM, but its F1 score still achieves the best result. Overall, the method of this invention demonstrates good predictive performance and stability on different loan application process datasets.

[0196] Furthermore, to verify the applicability of the proposed method under different process structures and business scenarios, comparative experiments were conducted using eight publicly available business process event log datasets. The selected datasets cover business domains such as IT service management, administrative management, and financial reimbursement. Specifically, the IT service management domain includes the Helpdesk and BPI 2013 series datasets, the administrative management domain includes the Receipt and BPI 2019 Marketing datasets, and the financial reimbursement domain includes the BPI 2020 series datasets. The performance comparison results of each method on the above datasets are shown in Table 4. The experimental results demonstrate that the proposed method achieves competitive prediction performance on most datasets, exhibiting good cross-dataset generalization ability.

[0197] Table 4 Performance comparison of various methods on other domain datasets

[0198] Experiments show that the present invention achieves better prediction performance than existing methods on financial loan approval datasets, verifying the effectiveness of the present method in the loan approval business process; at the same time, experimental results on public datasets in multiple different business fields further demonstrate that the present method has good cross-domain generalization ability.

[0199] Example 2 This embodiment 2 describes an attribute-aware heterogeneous graph-sequence joint prediction system, which is based on the same inventive concept as the business process prediction method based on attribute-aware heterogeneous graph and dual-temporal joint coding in the above embodiment 1.

[0200] A business process prediction system based on attribute-aware heterogeneous graphs and dual-temporal joint coding includes the following modules: The data preprocessing module is used to extract each process instance and the prefix trajectory of each process instance from the historical event log of the loan approval business process, and obtain the activity sequence, state sequence and multi-dimensional attribute sequence corresponding to each prefix trajectory; The heterogeneous graph construction module is used to construct a heterogeneous activity-state graph containing activity nodes, state nodes, and directed edges by utilizing each prefix trajectory and its corresponding state sequence and multidimensional attribute sequence, and to collect the attribute sequence of each state node. The graph-sequence joint coding module is used to build an attribute-aware graph-sequence joint coding model, which encodes the activity sequence and state sequence in step 1 and the heterogeneous activity-state graph in step 2 respectively, and extracts temporal evolution features and graph structure features. This graph-sequence joint coding model includes two parallel branches: a sequence modeling branch and a graph modeling branch. The sequence modeling branch takes the activity sequence and the state sequence as input and extracts the features of the activity sequence and the state sequence, respectively. The graph modeling branch takes a heterogeneous activity-state graph as input, encodes and fuses the multidimensional attribute sequences corresponding to each state node, and obtains the initial features of the state node with fused attribute information. Simultaneously, each active node is embedded and encoded to obtain the initial features of the active nodes; Then, the initial features of the state nodes and the initial features of the active nodes are input into the heterogeneous graph convolution module, and the neighbor information is aggregated along different edge types to obtain the state node features and active node features after fusing neighborhood information. The features of state nodes and active nodes are pooled and fused separately to obtain graph structure features; The system also includes a prediction output module, which concatenates activity sequence features, state sequence features, and graph structure features along the feature dimension, outputs the probability distribution of the next activity through a fully connected layer and a softmax function, and uses the activity with the highest probability as the prediction result.

[0201] It should be noted that the implementation process of the functions and roles of each module in the system described in this embodiment 2 is detailed in the implementation process of the corresponding steps of the method in the above embodiment 1, and will not be repeated here.

[0202] Example 3 This embodiment 3 describes a computer device including a memory and one or more processors. The memory stores executable code. When the processor executes the executable code, it implements the steps of the business process prediction method based on attribute-aware heterogeneous graphs and dual-temporal co-coding described in embodiment 1 above.

[0203] In this embodiment, the computer device can be any device or apparatus with data processing capabilities, and will not be described in detail here.

[0204] Example 4 This embodiment 4 describes a computer-readable storage medium storing a program that, when executed by a processor, is used to implement the steps of the business process prediction method based on attribute-aware heterogeneous graphs and dual-temporal joint coding described in embodiment 1 above.

[0205] The computer-readable storage medium can be an internal storage unit of any device or apparatus with data processing capabilities, such as a hard disk or memory, or any external storage device with data processing capabilities, such as a plug-in hard disk, smart media card (SMC), SD card, flash card, etc.

[0206] Of course, the above description is only a preferred embodiment of the present invention. The present invention is not limited to the above-described embodiments. It should be noted that any equivalent substitutions or obvious modifications made by those skilled in the art under the guidance of this specification fall within the scope of this specification and should be protected by the present invention.

Claims

1. A business process prediction method based on attribute-aware heterogeneous graphs and dual-temporal joint coding, characterized in that, Includes the following steps: Step 1. Extract each process instance and its prefix trajectory from the historical event log of the loan approval business process, and obtain the activity sequence, state sequence and multi-dimensional attribute sequence corresponding to each prefix trajectory; Step 2. Construct a heterogeneous activity-state graph containing activity nodes, state nodes, and directed edges using each prefix trajectory and its corresponding state sequence and multidimensional attribute sequence, and collect the attribute sequence of each state node; Step 3. Construct an attribute-aware graph-sequence joint encoding model to encode the activity sequence and state sequence of Step 1 and the heterogeneous activity-state graph of Step 2, and extract temporal evolution features and graph structure features. This graph-sequence joint coding model includes two parallel branches: a sequence modeling branch and a graph modeling branch. The sequence modeling branch takes the activity sequence and the state sequence as input and extracts the features of the activity sequence and the state sequence, respectively. The graph modeling branch takes a heterogeneous activity-state graph as input. First, it uses the attribute fusion module to encode and fuse the multi-dimensional attribute sequences corresponding to each state node to obtain the initial features of the state node with fused attribute information. Simultaneously, each active node is embedded and encoded to obtain the initial features of the active nodes; Then, the initial features of the state nodes and the initial features of the active nodes are input into the heterogeneous graph convolution module, and the neighbor information is aggregated along different edge types to obtain the state node features and active node features after fusing neighborhood information. The features of state nodes and active nodes are pooled and fused separately to obtain graph structure features; Step 4. Concatenate the activity sequence features, state sequence features, and graph structure features along the feature dimension, and output the probability distribution of the next activity through a fully connected layer and a softmax function. Use the activity with the highest probability as the prediction result.

2. The business process prediction method based on attribute-aware heterogeneous graphs and dual-temporal joint coding according to claim 1, characterized in that, In step 1, each process instance is extracted from the historical event log of the loan approval business process and sorted in ascending order by timestamp to obtain the prefix trajectory of each process instance; the activity name and event attributes of each prefix trajectory are encoded, and state encoding is performed based on the adjacency relationship between activities; the encoding results are constructed into a sequence in chronological order to obtain the activity sequence, state sequence, and multi-dimensional attribute sequence corresponding to each prefix trajectory. The specific process is as follows: First, extract each process instance from the event log and sort it in ascending order by timestamp to obtain the prefix trajectory of each process instance; for each event in the prefix trajectory, extract the activity name and attribute fields respectively, and perform numerical mapping on each independently; Let the set of activities be The size of the activity set is Map different activity names to 1 to | | consecutive integers, for any activity Its activity code is represented as ; Attribute encoding involves discretizing and encoding the resource, timestamp, and amount fields associated with each event. Resource fields are discrete categories and are encoded using integer indexes; The amount field is a continuous numerical value. It is discretized using an equal-frequency binning strategy, which divides the value distribution evenly into several intervals and maps them to integer indices. The timestamp field is split into multiple time features, including year, month, day, hour, time period, weekday, whether it is a weekend, and event duration, and each feature is discretized and encoded to obtain the corresponding attribute encoding results. Simultaneously, location features are introduced, using the position number of the event in its prefix trajectory to obtain the corresponding location code; After processing in step 1.1, each event Corresponding to a set of encoded multidimensional attribute vectors : ; in, Indicates an event Resource attribute encoding; Indicates an event The monetary attribute encoding; Indicates an event Time attribute encoding; Indicates an event Position encoding within the associated prefix trajectory; Based on the activity set in the historical event log, any two activities are combined in an ordered manner to obtain all ordered activity pairs. A global state mapping table is pre-built based on all ordered activity pairs, and a unique state identifier is assigned to each ordered activity pair. Let A be the set of activities. Then any ordered pair of activities... Each corresponds to a status identifier, which is calculated as follows: ; in To ensure orderly activities The corresponding status identifier; and For the event and exist Index in; Based on this, state encoding is performed on the ordered activity pairs in each prefix trajectory. The specific process is as follows: For any adjacent events in each prefix trajectory and Extract their corresponding activities respectively and Its status code is determined by the current activity. With the next event Joint decision-making; identifying orderly activities The corresponding state identifier in the global state mapping table is used as the state code for the current position. ; in Indicates the first The status code corresponding to each position. Represents the state identifier in the global state map table; For the last activity of the prefix trajectory, since its subsequent activities are unknown and cannot form a complete ordered activity pair, its state code is set to the end identifier, and its value is set to |A|² + 1.

3. The business process prediction method based on attribute-aware heterogeneous graphs and dual-temporal joint coding according to claim 2, characterized in that, In step 1, the encoding results of events in each prefix trajectory are sequenced in chronological order to obtain the corresponding activity sequence, state sequence, and multidimensional attribute sequence. The process is as follows: For including Prefix trajectory of events Among them, the first The activity corresponding to each event is ; For ease of representation, the following will use... This indicates the activity corresponding to each event in the prefix trajectory; Its activity sequence, state sequence, and multidimensional attribute sequence are represented as follows: Activity sequence This involves arranging the activity codes corresponding to each event in chronological order; among which... , , , Indicates the activity in the prefix trajectory; Indicates the corresponding activity code; State sequence S That is, the state codes corresponding to each position are arranged in chronological order according to the prefix trajectory, where This is the end identifier; Multidimensional attribute sequence ; in , , Indicates an event, These represent the multidimensional attribute vectors of the event.

4. The business process prediction method based on attribute-aware heterogeneous graphs and dual-temporal joint coding according to claim 1, characterized in that, In step 2, the directed edges include two types: activity → state and state → activity. The construction process of the heterogeneous activity-state graph includes node construction, edge construction, and attribute collection of state nodes; The node construction process is as follows: From the activity sequence and state sequence corresponding to the obtained prefix trajectory, activity nodes and state nodes are extracted respectively, as follows: Extract the activity sequence respectively. and state sequence The only element in; Construct activity node set and state node set ; complete set of nodes Each activity node represents an activity type, and each status node represents an activity pair type.

5. The business process prediction method based on attribute-aware heterogeneous graphs and dual-temporal joint coding according to claim 4, characterized in that, In step 2, the edge construction process is as follows: Based on the activities corresponding to adjacent events in the prefix trajectory, ordered activity pairs are obtained, and connection edges are constructed between activity nodes and state nodes. The state nodes represent the transition relationships between activities; specifically as follows: For a prefix trajectory containing k events, let To ensure orderly activities The corresponding state nodes, among which ; For each position in the prefix trajectory At the event node With state nodes Add an edge between "Activity → State" to indicate that after the activity is executed, it enters a state ordered by activity pair. The corresponding intermediate state; in the state node With the next activity node Add an edge between "state → activity" to indicate that the intermediate state leads to the subsequent activity; The two types of edges are connected alternately to form a heterogeneous path of "activity → state → activity → state → ... → activity → end state"; For the last event in the prefix trajectory, only add the active node corresponding to that event. To the state node corresponding to the end identifier The "activity → state" edge is not added; the edge set E is written as: ; The specific implementation is as follows: From the prefix trajectory activity sequence and state sequence Set off: For the "Activity → State" edge, the starting node array is: The corresponding target node array is For the "state → activity" edge, the starting node array is: The corresponding target node array is .

6. The business process prediction method based on attribute-aware heterogeneous graphs and dual-temporal joint coding according to claim 5, characterized in that, In step 2, the attribute collection process for the state node is as follows: The multidimensional attribute sequence in step 1 is aggregated according to the state nodes to form the attribute sequence corresponding to each state node. For each position in the prefix trajectory , the event Multidimensional attribute vector Associated with the corresponding state node middle; If multiple positions correspond to the same state node, then only one node representation is retained for that state node, and the multidimensional attribute vectors of the corresponding events are aggregated according to the order of appearance of the events in the prefix trajectory to form the attribute sequence of that state node; Set state nodes The set of all location indices appearing in the trajectory is: ; but Attribute sequence Defined as: ;in, Elements in the array are indexed by position Ascending order; This is the multidimensional attribute vector encoded in step 1.

7. The business process prediction method based on attribute-aware heterogeneous graphs and dual-temporal joint coding according to claim 6, characterized in that, In step 3, the processing flow of the sequence modeling branch is as follows: Activity sequence and state sequence Each encoding is performed using a separate LSTM; The activity sequence is embedded through separate activity embedding layers and state embedding layers. and state sequence The discrete numerical indexes in the vector are mapped to continuous vectors, resulting in the activity embedding sequence and the state embedding sequence. Let the activity embedding matrix be The state embedding matrix is ; Where |A| is the total number of activities, |A|² corresponds to all possible activity pairs, plus 1 corresponds to the end identifier, and d is the embedding dimension; According to the activity sequence The activity encoding in the activity embedding matrix Obtain the corresponding embedding vector to get the active embedding sequence. According to the state sequence State encoding in the state embedding matrix Obtain the corresponding embedding vector from the state to obtain the state embedding sequence. ; Embedding activities into sequences and state embedding sequence The activity sequence and state sequence are encoded separately using independent LSTM and LSTM, respectively. The hidden state at the last time step of each sequence is then used as the activity sequence feature vector of the corresponding prefix trajectory. and state sequence feature vector .

8. The business process prediction method based on attribute-aware heterogeneous graphs and dual-temporal joint coding according to claim 7, characterized in that, In step 3, the processing flow for graph modeling branches is as follows: II.

1. Node initialization; Activity Node Set Active nodes and state node sets For each state node, an initial feature of the active node is obtained using an independent embedding matrix. and the original embedding features of state nodes ; II.

2. Attribute Fusion; To capture the changes in attribute sequences over time, an attribute fusion module is used to perform temporal encoding on the different attribute sequences corresponding to each state node. The processing flow of the attribute fusion module is as follows: Each attribute is mapped to a continuous vector through an independent embedding layer or linear layer. The continuous vector sequences corresponding to different attributes are input into independent gated recurrent units (GRUs) for encoding, and the hidden state at the last step of each GRU is used as the corresponding attribute feature vector. Let the number of attribute types be m, and the feature vectors of each attribute be denoted as... ; The contribution weight of each attribute feature vector is determined using an attribute weighting calculation mechanism, as shown in the following formula: ; in, This represents vector concatenation. This represents the contribution weight corresponding to each attribute. and These represent the weight matrix and bias vector of the attribute weight calculation layer, respectively; Weighted fusion is performed based on the contribution weight of each attribute: ; Fuse attribute feature vectors Projected onto d-dimensional planes via linear layers to obtain Then, combined with the original embedded features of the state node Add them together to form the initial features of the state node: ; II.

3. Feed the initialized node features into the heterogeneous graph convolution module; The heterogeneous graph convolution module contains L=3 layers of heterogeneous graph convolutions. Each layer aggregates neighbor information for two edge types: "activity to state" and "state to activity". After initialization, it uses the initial features of active nodes. As the input of the active node at level 0, that is: ; Initial features of state nodes after fusing attribute information As the input of the state node at level 0; in the... In the heterogeneous graph convolution, the "activity-to-state" edge `actTostate` transmits information from the active node `a` to the state node `s` and updates the state node's features; the "state-to-activity" edge `stateToact` transmits information from the state node `s` to the active node `a` and updates the active node's features; for state node `s`, the th... The features of a layer are represented as follows: ; in This is the set of active nodes that point to state node s via "activity-to-state" edges; Use mean pooling; Indicates the first The weight matrix used in the layer to transform the features of active neighbor nodes; This represents the weight matrix used to transform the characteristics of the state node itself; For activity nodes , its first Layer features are represented as: ; in, This indicates that the "state to activity" edge points to the activity node. A set of state nodes; Indicates the first The weight matrix in the layer used to transform the features of neighboring nodes in the state; This represents the weight matrix used to transform the features of the active node itself; After each layer of heterogeneous graph convolution, non-linear activation and random deactivation are applied to the features of active nodes and state nodes respectively; the final features of active nodes are obtained after three layers of heterogeneous graph convolution. and final features of state nodes ; Subsequently, the final features of the activity nodes were analyzed respectively. and final features of state nodes Perform global mean pooling to obtain graph-level feature vectors for active nodes and graph-level feature vectors for state nodes: ; ; in This represents the graph-level feature vector of active nodes obtained by aggregating the features of all active nodes. This represents the graph-level feature vector of state nodes obtained by aggregating the features of all state nodes; The two pooling results are concatenated and then compressed through a fully connected layer to obtain the graph structure features. : ; in This represents a vector concatenation operation. and These represent the weight matrix and bias vector of the graph feature fusion layer, respectively.

9. The business process prediction method based on attribute-aware heterogeneous graphs and dual-temporal joint coding according to claim 1, characterized in that, Step 4 specifically involves: The activity sequence features output in step 3 State sequence features Sum graph structural features By concatenating along the feature dimensions, a comprehensive feature vector is obtained. : ; The comprehensive feature vector z is input into a fully connected layer, the output dimension is |A|, and then the probability distribution of the next activity is obtained by passing it through a softmax function. The formula is as follows: ; in and A is a learnable parameter; |A| represents the number of activity categories; Take the activity with the highest probability as the prediction result: .

10. A business process prediction system based on attribute-aware heterogeneous graphs and dual-temporal joint coding, characterized in that, Includes the following modules: The data preprocessing module is used to extract each process instance and the prefix trajectory of each process instance from the historical event log of the loan approval business process, and obtain the activity sequence, state sequence and multi-dimensional attribute sequence corresponding to each prefix trajectory. The heterogeneous graph construction module is used to construct a heterogeneous activity-state graph containing activity nodes, state nodes, and directed edges by utilizing each prefix trajectory and its corresponding state sequence and multidimensional attribute sequence, and to collect the attribute sequence of each state node. The graph-sequence joint coding module is used to build an attribute-aware graph-sequence joint coding model, which encodes the activity sequence and state sequence in step 1 and the heterogeneous activity-state graph in step 2 respectively, and extracts temporal evolution features and graph structure features. This graph-sequence joint coding model includes two parallel branches: a sequence modeling branch and a graph modeling branch. The sequence modeling branch takes the activity sequence and the state sequence as input and extracts the features of the activity sequence and the state sequence, respectively. The graph modeling branch takes a heterogeneous activity-state graph as input, encodes and fuses the multidimensional attribute sequences corresponding to each state node, and obtains the initial features of the state node with fused attribute information. Simultaneously, each active node is embedded and encoded to obtain the initial features of the active nodes; Then, the initial features of the state nodes and the initial features of the active nodes are input into the heterogeneous graph convolution module, and the neighbor information is aggregated along different edge types to obtain the state node features and active node features after fusing neighborhood information. The features of state nodes and active nodes are pooled and fused separately to obtain graph structure features; The system also includes a prediction output module, which concatenates activity sequence features, state sequence features, and graph structure features along the feature dimension, outputs the probability distribution of the next activity through a fully connected layer and a softmax function, and uses the activity with the highest probability as the prediction result.