betaFeedback

Reading v1View latest version

WorksComputer Science

Dual Representation Enhanced Diffusion Policy for Flexible Job Shop Scheduling

Abstract

The Flexible Job-Shop Scheduling Problem (FJSP) is a fundamental and challenging optimization problem in smart manufacturing. Although recent deep reinforcement learning (DRL) approaches can learn effective scheduling policies through interaction with the environment, their performance often degrades as problem scale and processing-time uncertainty increase. In this paper, we propose DredRL, a dual representation enhanced diffusion-policy reinforcement learning scheduler. DredRL first constructs enhanced dual representations of operations and machines through self- and cross-attention mechanisms to capture both intra-entity and inter-entity dependencies. A diffusion model is further employed as the policy network, generating scheduling decisions through iterative denoising conditioned on the encoded state to enhance policy expressiveness and robustness. Extensive experiments on synthetic, public, large-scale, and stochastic FJSP benchmarks demonstrate that DredRL outperforms state-of-the-art learning-based schedulers across most configurations. Compared with SOTA learning-based methods, DredRL reduces makespan by up to 5.44% on synthetic instances. It also achieves the best learning-based performance on three of four public benchmarks and outperforms the stochasticity-aware algorithms on stochastic benchmarks. These results demonstrate that combining enhanced dual representations with diffusion-based policies provides an effective and robust approach for large scale scalable FJSP scheduling in complicated environment.

Introduction

Manuscript received September 22, 2026; revised XXX, 2026; accepted XXX, 2026. This research was supported in part by MTC Individual Research Grants (IRG) (Award M23M6c0113), A*STAR under its MTC Programmatic (Award M23L9b0052), and the National Research Foundation Singapore and DSO National Laboratories under the AI Singapore Programme (AISG Award No: AISG2-GC-2023-006). (Corresponding author: Wei Zhang)

Yunyi Zhao is with both the Information and Communications Technology Cluster, Singapore Institute of Technology, Singapore 138683, and the Department of Electrical and Computer Engineering, National University of Singapore, Singapore 119077 (e-mail: [email protected], [email protected]).

Wei Zhang is with the Information and Communications Technology Cluster, Singapore Institute of Technology, Singapore 138683 (e-mail: [email protected]).

Cheng Xiang is with the School of Information and Communication Engineering, Dalian University of Technology, Dalian, Liaoning Province, China, 116024 (e-mail: [email protected]).

Vadakkepat Prahlad is with the Department of Electrical and Computer Engineering, National University of Singapore, Singapore 119077 (e-mail: [email protected]).

Zuming Liu is with the College of Smart Energy, Shanghai Jiao Tong University, Shanghai, China, 200240 (e-mail: [email protected]).

Smart manufacturing is becoming increasingly critical to the sustainable and resilient development of a nation. Singapore’s manufacturing 2030 aims to grow the sector’s value-add by 50% by leveraging AI, robotics, and IIoT to build a sustainable, high-tech, and less labor-intensive ecosystem [1]. In smart manufacturing, Flexible Job-Shop Scheduling Problem (FJSP) is a fundamental combinatorial optimization problem, where each operation can be processed by one of multiple eligible machines with different processing times. This flexibility substantially enlarges the decision space compared with classical job-shop scheduling, making NP-hard FJSP even more complicated and practically challenging in large-scale, dynamic production environments. In real-world workshops, schedulers must repeatedly decide which operation–machine pair to dispatch under complex constraints such as precedence relations, machine availability, and heterogeneous processing capabilities, while pursuing objectives such as minimizing makespan and improving throughput. Consequently, developing fast and high-quality scheduling approaches that generalize across instance sizes and remain effective under uncertainty is critical for modern intelligent manufacturing systems.

FJSP scheduling has been extensively studied, and existing methods can be broadly divided into two stages. The first stage is dominated by traditional approaches, including exact optimization and heuristic algorithms. Exact methods such as mixed-integer linear programming (MILP) [2] can produce optimal solutions for sufficiently small FJSP instances, while rule-based dispatching strategies such as FIFO [3] and its variants incorporate human expertise into decision making. OR-Tools [4] is also a strong benchmark in this stage, using combinatorial optimization to generate high-quality, near-optimal schedules. However, these methods become increasingly impractical in real-world settings, as computational cost grows exponentially with problem scale and online decision making requirements. Heuristic algorithms, such as genetic algorithms [5], are relatively flexible, but they rely heavily on manual design, parameter tuning, and domain knowledge, and their performance can also degrade as problem size increases. As a result, traditional methods face clear limitations on dynamic large-scale problems.

To overcome these issues, the second stage has shifted toward machine learning, particularly deep reinforcement learning (DRL). DRL is well suited to FJSP, since the problem can be formulated as a Markov decision process (MDP) in which selecting a feasible operation–machine pair corresponds to an action, while minimizing makespan can be directly incorporated into reward optimization. By learning scheduling policies through interaction with the environment, DRL enables fast inference after training and offers stronger adaptability to dynamic conditions and unseen instances [6]. Recent studies further combine DRL with graph neural networks (GNNs) and attention-based architectures to improve state representation. For example, HGNN [7] employs heterogeneous graph embeddings to capture structural relations among operations and machines, while DANIEL [8] achieves state-of-the-art (SOTA) performance through attention-based state representation and PPO-Clip optimization [9]. More recently, SPM-DAN extends learning-based FJSP scheduling to stochastic processing times by introducing a scenario processing module that explicitly encodes multiple processing-time scenarios and their associated uncertainty into the scheduling policy [10]. Such graph- and attention-based representations are particularly effective for FJSP because they capture structural dependencies and operation–machine interactions, thereby improving the state representation and decision quality of DRL agents. Related work has also explored multi-agent reinforcement learning (MARL) to enhance cooperation among agents [11].

While DRL models enable fast scheduling in FJSP, existing schedulers remain limited as states are often overly simplified and the scheduling complexity is not well captured. First, representing the intricate job shop structure remains difficult. The effectiveness of learning-based methods relies heavily on the quality and comprehensiveness of state representations [12]. Operations and machines form a heterogeneous, bipartite dependency system in which both intra-entity dynamics and inter-entity couplings jointly decide the performance. Second, most DRL policies are parameterized by standard discriminative networks that output pointwise action distributions. Such policies cannot be sufficiently expressive for the multimodal decision landscape of FJSP, particularly on larger instances. Third, existing DRL schedulers often struggle with model generalization and transferability. Many DRL methods are trained on a fixed distribution of instances and implicitly assume consistent state/action dimensions and similar feature statistics, which leads to overfitting to the training scale and layout. Even though several works have proposed complex state encoding schemes [7, 8, 13], the resulting representations can still be ambiguous in capturing complex scheduling semantics, and the learned policies often degrade when transferred to unseen tasks or instance distributions. Therefore, additional mechanisms are needed to better couple features across heterogeneous entities and to improve the model’s generalization capability.

In this paper, we propose DredRL, a novel dual representation enhanced diffusion policy reinforcement learning scheduler for FJSP. DredRL combines a dual-representation encoder with a diffusion-based policy to improve scalability, expressiveness, and robustness. The encoder models operations and machines as two coupled streams, using enhanced self-attention to capture intra-entity dependencies and cross-attention to model operation–machine interactions. Based on the encoded state, the diffusion actor generates scheduling decisions through iterative denoising within an actor–critic DRL framework, enabling more expressive modeling of complex decision distributions. Extensive experiments on synthetic, public, large-scale, and stochastic benchmarks show that DredRL outperforms SOTA learning-based schedulers across most configurations. Compared with DANIEL, it reduces makespan by up to 5.44% on small-scale and 3.53% on larger-scale instances without size-specific retraining. It also achieves the best learning-based performance on most public benchmarks and SD3 stochastic settings, demonstrating strong cross-size, cross-distribution, and stochastic generalization.

The main contributions of this work are summarized as follows:

  1. We propose DredRL, a dual-representation-enhanced diffusion-policy DRL framework for FJSP that improves solution quality, scalability, and robustness across deterministic and stochastic scheduling environments.

  1. We design an enhanced dual representation encoder that jointly models operation and machine features, enabling richer inter-entity and intra-entity feature coupling for more effective operation–machine decision making.

  1. We develop a distinct diffusion-based actor formulation that employs a diffusion model as the policy network and generates scheduling decisions through iterative denoising conditioned on the encoded state, improving policy expressiveness and robustness under varying problem scales and processing-time uncertainty.

  1. We conduct extensive experiments covering synthetic, public, large-scale, and stochastic FJSP benchmarks. The results demonstrate consistent improvements over SOTA learning-based baselines, strong cross-size and cross-distribution generalization, and competitive performance under stochastic processing times, including improvements over the stochasticity-aware algorithms and reduced gaps to time-limited OR-Tools references.

Proposed Method

FJSP is a classical optimization problem that is known to be NP-hard. The FJSP can be formulated into a decision-making process by adopting an MDP. DredRL combines a dual-representation encoder with a diffusion-based policy as shown in Figure 1. In this section, we will introduce preliminaries of FJSP, our proposed method and system configurations including MDP formulation and a novel dual representation enhanced diffusion policy for FJSP.

Figure 1. Overall system architecture of the proposed DredRL scheduler for FJSP. Raw operation, machine, and operation–machine pairing features are encoded by a dual-representation module to form the state embedding ss. A diffusion-policy RL agent then samples an action distribution πθ(s)\pi_\theta(s) and selects compatible pairs for task assignment. The FJSP environment executes the assignment, computes reward rr, updates status, and feeds back new raw features for the next decision step.

Flexible Job-shop Scheduling Problem

The FJSP usually considers a set of nn jobs and mm machines, which are represented by J={J1,J2,…,Jn}\mathcal{J} = \{\mathcal{J}_1,\mathcal{J}_2,\ldots,\mathcal{J}_n\} and M={M1,M2,…,Mm}\mathcal{M} = \{\mathcal{M}_1,\mathcal{M}_2,\ldots,\mathcal{M}_m\} respectively. Each job Ji\mathcal{J}_i consists of a sequence of nin_i operations noted by Oi={Oi,1,…,Oi,ni}\mathcal{O}_i = \{\mathcal{O}_{i,1},\ldots,\mathcal{O}_{i,n_i}\}. With an assumption that all jobs have arrived at starting time T=0T = 0, each operation Oi,j\mathcal{O}_{i,j} can be processed by a subset of feasible machines Mi,j⊆M\mathcal{M}_{i,j} \subseteq\mathcal{M}. The processing time of operation Oi,j\mathcal{O}_{i,j} on machine Mk∈Mi,j\mathcal{M}_k \in\mathcal{M}_{i,j} can be described as pi,jk>0p_{i,j}^{k} > 0. The optimization of FJSP aims at operation-machine assignments while obeying the precedence constraints of operations and machine availability. The preliminary target of FJSP optimization is to minimize the completion time of all jobs (makespan).

A well-known method to represent FJSP is the disjunctive graph. It is considered a clearer way of formulating FJSP with both operation precedence and machine availability constraints. A disjunctive graph GG is described by a tuple (V,C,D)(\mathcal{V},\mathcal{C},\mathcal{D}). The node set V=O∪{Start,End}\mathcal{V} = \mathcal{O} \cup\{\mathrm{Start},\mathrm{End}\} represents all operation nodes O\mathcal{O} and starting, terminating nodes. The conjunction set C={⟨Oi,j,Oi,j+1⟩}\mathcal{C} = \{\langle\mathcal{O}_{i,j}, \mathcal{O}_{i,j+1}\rangle\} consists of directed edges between operation nodes of each job Ji\mathcal{J}_i, following the precedence constraints of operations. The disjunction set D={D1,…,Dm}\mathcal{D} = \{\mathcal{D}_1,\ldots,\mathcal{D}_m\} comprises mm groups, reflecting that each machine can possibly process a subset of operations. A solution to an FJSP is described by a directed acyclic graph in which each operation Oi,j\mathcal{O}_{i,j} has been scheduled to a specific machine Mk\mathcal{M}_k with remaining disjunctions lined to Oi,j\mathcal{O}_{i,j} deleted.

Dual Representation Network

In complex environments like FJSP, multiple types of relationship exist among different operations and machines. Adopting self-attention models like Graph Attention Networks (GATs) [14] in many existing solutions have been proved to conduce to feature extraction. However, relying entirely on one type of attention mechanism may create blind spots for the DRL agent, neglecting the inner connection between different features. To overcome this issue, we propose a novel dual representation model for DredRL, involving both intra- and inter-entity (dual) representations of complicated features in FJSP environment, as shown in Figure 2. Details will be introduced below. GATs are one of the effective and commonly used GNN architectures with self-attention. A multi-head attention mechanism is applied to both attention blocks to enhance their learning ability [15] and the multi-head attention parameter is denoted as r∈{1,…,H}r \in\{1,\ldots,H\}.

Dual-representation encoder with self- and cross-attention blocks

Figure 2. Dual-representation encoder with self- and cross-attention blocks. Raw operation (Op) and machine (M) features are linearly projected and processed via masked dot-product attention, followed by mean pooling and ELU to derive embeddings.

  1. Self-attention Block.: Self-attention models excel in relating input elements inside the same entity. This step helps the DredRL to learn the intra-entity representation. In some existing FJSP solutions, GATs are applied as self-attention module to update node features by attending over neighbors. In this intra-entity representation learning step, operation features and machine features are processed separately with local self-attention block. The

operation feature block helps find out the significance of queuing operations, while the machine feature block leads to the competition between multiple machines based on their compatibility of operations. By stacking L>1L > 1 graph attention layers, the GAT yields final node embeddings for downstream steps.

Operation Nodes

Let O\mathcal{O} and M\mathcal{M} denote the operation and machine sets at step tt. For both blocks, given input node features H={hi∈RN}i=1N\mathcal{H} = \{h_i \in\mathbb{R}^N\}_{i=1}^N, the GAT finally output a feature embedding h~i′\tilde{h}'_i. For operation Oi,j\mathcal{O}_{i,j}, a neighbor set NOi,j={Oi,j,Oi,j−1,Oi,j+1}\mathcal{N}_{\mathcal{O}_{i,j}} = \{\mathcal{O}_{i,j},\mathcal{O}_{i,j-1},\mathcal{O}_{i,j+1}\} includes neighbor nodes of operation Oi,j\mathcal{O}_{i,j} (including itself). The attention coefficients between the neighbor nodes represent the relationships between operation Oi,j\mathcal{O}_{i,j} itself, its predecessor Oi,j−1\mathcal{O}_{i,j-1} and successor Oi,j+1\mathcal{O}_{i,j+1} if they exist. Each GAL computes attention coefficients for operation node Oi,j\mathcal{O}_{i,j} as,

ei,j1,j2op=LeakyReLU⁡(aˉopT[(WophOi,j1)∥(WophOi,j2)]),j1,j2∈{j−1,j,j+1}.(1)e^{\mathrm{op}}_{i,j_1,j_2} = \operatorname{LeakyReLU}\left(\bar{a}_{\mathrm{op}}^{\mathsf{T}}\left[(W^{\mathrm{op}}h_{\mathcal{O}_{i,j_1}}) \mathbin\Vert(W^{\mathrm{op}}h_{\mathcal{O}_{i,j_2}})\right]\right), \quad j_1,j_2 \in\{j-1,j,j+1\}. \tag*{(1)}

where hOi,j,hOi,j−1,hOi,j+1h_{\mathcal{O}_{i,j}},h_{\mathcal{O}_{i,j-1}},h_{\mathcal{O}_{i,j+1}} are input graph feature vectors after grouping, WopW^{\mathrm{op}} is a linear transformation matrix shared by all operation nodes, the operation [⋅∥⋅][\cdot\mathbin\Vert\cdot] concatenates two vectors to a unified vector, and aˉop\bar{a}_{\mathrm{op}} is the weight vector of a single-layer network with a LeakyReLU(⋅)(\cdot) activation. A dynamic mask on operation node attention coefficients is introduced to block invalid operations at each step. Given an operation-machine compatibility M∈{0,1}Nop×Nm\mathcal{M} \in\{0,1\}^{N_{\mathrm{op}}\times N_{\mathrm{m}}}, we apply masking on logits via,

Γij={0,Mij=1,−∞,Mij=0.(2)\Gamma_{ij} = \begin{cases} 0, & M_{ij}=1,\\ -\infty, & M_{ij}=0. \end{cases} \tag*{(2)}

The attention coefficients are normalized via a softmax function as,

αi,j,k=exp⁡(ei,j,k)∑k′=j−1j+1exp⁡(ei,j,k′).(3)\alpha_{i,j,k} = \frac{\exp(e_{i,j,k})}{\sum_{k'=j-1}^{j+1}\exp(e_{i,j,k'})}. \tag*{(3)}

The weighted sum of transformed neighboring features is computed by,

h~Oi,j(s−op)′=σ(∑k=j−1j+1αi,j,kWophOi,k),(4)\tilde{h}^{(\mathrm{s-op})'}_{\mathcal{O}_{i,j}} = \sigma\left(\sum_{k=j-1}^{j+1}\alpha_{i,j,k}W^{\mathrm{op}}h_{\mathcal{O}_{i,k}}\right), \tag*{(4)}

where σ\sigma is a nonlinear activation, typically ELU(⋅)(\cdot) function. We combine multi-heads by concatenation:

h~Oi,js−op=Concat⁡(h~Oi,js−op,(1),…,h~Oi,js−op,(H)).(5)\tilde{h}^{\mathrm{s-op}}_{\mathcal{O}_{i,j}} = \operatorname{Concat}\left(\tilde{h}^{\mathrm{s-op},(1)}_{\mathcal{O}_{i,j}},\ldots,\tilde{h}^{\mathrm{s-op},(H)}_{\mathcal{O}_{i,j}}\right). \tag*{(5)}

Machine Nodes

In machine self-attention block, the calculation is focused to extract machine feature relationship between machine nodes. For machine node Mi\mathcal{M}_i, a neighbor set of NMi={j∣∀Ci,j≠∅}\mathcal{N}_{\mathcal{M}_i} = \{j\mid\forall C_{i,j} \ne\varnothing\} denotes neighbor nodes, where Ci,jC_{i,j} represents an operation set competed by machine Mi\mathcal{M}_i and Mj\mathcal{M}_j. In this way, self-attention mechanism in machine entity allows multiple machines competing over their commonly compatible operations.

The attention coefficients between nodes Mi\mathcal{M}_i and Mj\mathcal{M}_j are given by,

ei,jm=LeakyReLU⁡(aˉmT[(WmhMi)∥(WmhMj)]),(6)e^{\mathrm{m}}_{i,j}=\operatorname{LeakyReLU}\left(\bar{\mathbf{a}}_{\mathrm{m}}^{\mathsf{T}}\left[\left(\mathbf{W}^{\mathrm{m}}h_{\mathcal{M}_i}\right)\mathbin\Vert\left(\mathbf{W}^{\mathrm{m}}h_{\mathcal{M}_j}\right)\right]\right), \tag*{(6)}

where Wm\mathbf{W}^{\mathrm{m}} is a linear transformation matrix between machine nodes, and aˉm\bar{\mathbf{a}}_{\mathrm{m}} is the weight vector of a single-layer network for machine self-attention block. Similar softmax activation, combination steps are then introduced to derive output embeddings as,

h~Mi(s−m)′=σ(∑k∈NMiαi,kWmhMk).(7)\tilde{h}_{\mathcal{M}_i}^{(\mathrm{s-m})'}=\sigma\left(\sum_{k\in\mathcal{N}_{\mathcal{M}_i}}\alpha_{i,k}\mathbf{W}^{\mathrm{m}}h_{\mathcal{M}_k}\right). \tag*{(7)}

Cross-attention Block

Cross-attention models are beneficial for correlating features from different entities, which conduce to the learning of inter-entity representation. We focus on capturing the operation-machine relationship by using cross-attention block. Although there are operation-machine pairing features to address the connection, each operation and its compatible machines, the inter-entity relationship between operation and machine features should be further represented in a more expressive way. Therefore, we developed cross-attention block to capture the in-depth connections between operations and machines. Specifically we use the following process for cross-attention calculation.

Operation-Machine Block

We denote node input features of operation Oi,j\mathcal{O}_{i,j} as {hOi,j}\{h_{\mathcal{O}_{i,j}}\} and machine Mk\mathcal{M}_k as {hMk}\{h_{\mathcal{M}_k}\}. We denote A(t)⊆O×M\mathcal{A}(t)\subseteq\mathcal{O}\times\mathcal{M} as the compatibility edge set, and Ni,j={k∣(Oi,j,Mk)∈A(t)}\mathcal{N}_{i,j}=\{k\mid(\mathcal{O}_{i,j},\mathcal{M}_k)\in\mathcal{A}(t)\} the compatible machines for operation Oi,j\mathcal{O}_{i,j}. The multi-head attention parameter is r∈{1,…,H}r\in\{1,\ldots,H\} with output dimension dhd_h. For each compatible pair (Oi,j,Mk)∈A(t)(\mathcal{O}_{i,j},\mathcal{M}_k)\in\mathcal{A}(t),

ei,j,k(M→O)=LeakyReLU⁡(a(M→O)T[ZophOi,j∥ZmhMk]),(8)e^{(\mathrm{M}\to\mathrm{O})}_{i,j,k}=\operatorname{LeakyReLU}\left(\mathbf{a}^{\mathsf{T}}_{(\mathrm{M}\to\mathrm{O})}\left[\mathbf{Z}^{\mathrm{op}}h_{\mathcal{O}_{i,j}}\mathbin\Vert\mathbf{Z}^{\mathrm{m}}h_{\mathcal{M}_k}\right]\right), \tag*{(8)}

where a(M→O)∈R2dh\mathbf{a}_{(\mathrm{M}\to\mathrm{O})}\in\mathbb{R}^{2d_h} and ∥\Vert denotes concatenation. After applying mask as Eq. (2), we normalize over the neighborhood Ni,j\mathcal{N}_{i,j} as,

αi,j,k=exp⁡(ei,j,k)∑k′∈Ni,jexp⁡(ei,j,k′).(9)\alpha_{i,j,k}=\frac{\exp(e_{i,j,k})}{\sum_{k'\in\mathcal{N}_{i,j}}\exp(e_{i,j,k'})}. \tag*{(9)}

The cross-attended representation of each compatible pair (Oi,j,Mk)∈A(t)(\mathcal{O}_{i,j},\mathcal{M}_k)\in\mathcal{A}(t) for each head is,

h~Oi,j(c−op)′=σ(∑k∈Ni,jαi,j,kWhOi,j).(10)\tilde{h}_{\mathcal{O}_{i,j}}^{(\mathrm{c-op})'}=\sigma\left(\sum_{k\in\mathcal{N}_{i,j}}\alpha_{i,j,k}\mathbf{W}h_{\mathcal{O}_{i,j}}\right). \tag*{(10)}

Multi-heads are concatenated as Eq. (5).

Machine-Operation Block

Similarly as attention block, for machine node Mk\mathcal{M}_k, a neighbor set of NMk={q∣∀Ck,q≠∅}\mathcal{N}_{\mathcal{M}_k}=\{q\mid\forall C_{k,q}\ne\varnothing\} denotes neighbor nodes, where Ck,qC_{k,q} represents an operation set competed by machine Mk\mathcal{M}_k and Mq\mathcal{M}_q. And Nk={(i,j)∣(Oi,j,Mk)∈A(t)}\mathcal{N}_k=\{(i,j)\mid(\mathcal{O}_{i,j},\mathcal{M}_k)\in\mathcal{A}(t)\} the compatible operations for selected machine Mk\mathcal{M}_k. With reference to [8] we introduce ckq=∑Oi,j∈Ckq∩JchOi,jc_{kq}=\sum_{\mathcal{O}_{i,j}\in C_{kq}\cap\mathcal{J}_c}h_{\mathcal{O}_{i,j}} to measure the competition intensity between Mk\mathcal{M}_k and Mq\mathcal{M}_q. A filter is applied to extract ckqc_{kq} from input operation features. For each compatible pair (Oi,j,Mk)∈A(t)(\mathcal{O}_{i,j},\mathcal{M}_k)\in\mathcal{A}(t) with neighbors NMk\mathcal{N}_{\mathcal{M}_k}, the cross-attention coefficients are calculated as,

ei,j,k,q(O→M)=LeakyReLU⁡(a(O→M)T[ZophOi,j∥ZmhMk∥Z0ck,q]),(11)e^{(\mathrm{O}\to\mathrm{M})}_{i,j,k,q}=\operatorname{LeakyReLU}\left(\mathbf{a}^{\mathsf{T}}_{(\mathrm{O}\to\mathrm{M})}\left[\mathbf{Z}^{\mathrm{op}}h_{\mathcal{O}_{i,j}}\mathbin\Vert\mathbf{Z}^{\mathrm{m}}h_{\mathcal{M}_k}\mathbin\Vert\mathbf{Z}^{0}c_{k,q}\right]\right), \tag*{(11)}

where Z0\mathbf{Z}^{0} stands for an additional weight matrix for ckqc_{kq}. After softmax, another machine-operation cross-attended representation of each compatible pair (Oi,j,Mk)∈A(t)(\mathcal{O}_{i,j},\mathcal{M}_k)\in\mathcal{A}(t) is,

h~Mk(c−m)′=σ(∑(i,j)∈Nk,q∈NMkαi,j,k,qWhMk).(12)\tilde{h}_{\mathcal{M}_k}^{(\mathrm{c-m})'}=\sigma\left(\sum_{(i,j)\in\mathcal{N}_k,q\in\mathcal{N}_{\mathcal{M}_k}}\alpha_{i,j,k,q}\mathbf{W}h_{\mathcal{M}_k}\right). \tag*{(12)}

Combination of Dual Representation

We denote that after LL GAT layers, the features are processed from h(0)h^{(0)} to h(L)h^{(L)}. We first apply average pooling to operation and machine embeddings as

hop(L)=Mean⁡(hOi,j(s−op,L),hOi,j(c−op,L)),(13)h_{\mathrm{op}}^{(L)}=\operatorname{Mean}\left(h_{\mathcal{O}_{i,j}}^{(\mathrm{s-op},L)},h_{\mathcal{O}_{i,j}}^{(\mathrm{c-op},L)}\right), \tag*{(13)}
hm(L)=Mean⁡(hMk(s−m,L),hMk(c−m,L)),(14)h_{\mathrm{m}}^{(L)}=\operatorname{Mean}\left(h_{\mathcal{M}_k}^{(\mathrm{s-m},L)},h_{\mathcal{M}_k}^{(\mathrm{c-m},L)}\right), \tag*{(14)}
hG(L)=[(1∣Ou∣∑Oi,j∈OuhOi,j(L))∥(1∣Mu∣∑Mk∈MuhMk(L))],(15)h_{\mathcal{G}}^{(L)}=\left[\left(\frac{1}{\lvert\mathcal{O}_u\rvert}\sum_{\mathcal{O}_{i,j}\in\mathcal{O}_u}h_{\mathcal{O}_{i,j}}^{(L)}\right)\mathbin\Vert\left(\frac{1}{\lvert\mathcal{M}_u\rvert}\sum_{\mathcal{M}_k\in\mathcal{M}_u}h_{\mathcal{M}_k}^{(L)}\right)\right], \tag*{(15)}

where hop(L)h_{\mathrm{op}}^{(L)} stands for combined operation embeddings at layer LL, hm(L)h_{\mathrm{m}}^{(L)} means combined machine embeddings at layer LL, and hG(L)h_{\mathcal{G}}^{(L)} represents concatenated global FJSP features at layer LL.

Deep Reinforcement Learning

As our target is to dynamically schedule operations to compatible and available machines and update the disjunctive graph G\mathcal{G} step by step, an MDP is formulated to enable recursive interaction between scheduling agent and the FJSP environment. At each time step tt, the scheduling agent receives a state sts_t from the FJSP environment and chooses an action ata_t to assign the operation to a compatible machine for processing. The FJSP environment processes the action ata_t and returns a reward rtr_t accordingly. By repeating this process, the disjunctive graph will be updated step by step and eventually becomes the solution map. The MDP is defined as follows.

State

At step tt, we only keep relevant operations and machines for decision-making: completed operations and machines that cannot process any remaining operation are ignored. Let Ou(t)\mathcal{O}_u(t) and Mu(t)\mathcal{M}_u(t) denote the relevant operation and machine sets, and A(t)\mathcal{A}(t) denotes the compatible operation-machine pairs. The state is a set of feature vectors hOi,j∈Rh_{\mathcal{O}_{i,j}}\in\mathbb{R} (Oi,j∈Ou(t))(\mathcal{O}_{i,j}\in\mathcal{O}_u(t)), hMk∈Rh_{\mathcal{M}_k}\in\mathbb{R} (Mk∈Mu(t))(\mathcal{M}_k\in\mathcal{M}_u(t)), and h(Oi,j,Mk)∈Rh_{(\mathcal{O}_{i,j},\mathcal{M}_k)}\in\mathbb{R} ((Oi,j,Mk)∈A(t))((\mathcal{O}_{i,j},\mathcal{M}_k)\in\mathcal{A}(t)). As scheduling progresses, the state set shrinks accordingly. We align with existing solutions to derive operation, machine, and operation-machine pair features. We follow the state construction of [8].

b) Action: The action space is A(t)\mathcal{A}(t), comprised of all compatible operation-machine pairs (Oi,j,Mk)(O_{i,j}, M_k) defined at step tt. All operations in A(t)\mathcal{A}(t) are selected from the candidate set Jc(t)\mathcal{J}_c(t).

c) State transition: Executing ata_t starts processing an operation on a machine, updates the environment, and yields the next state st+1s_{t+1} by updating Ou(t)\mathcal{O}_u(t), Mu(t)\mathcal{M}_u(t), A(t)\mathcal{A}(t) and computing features.

d) Reward: We choose the negative value of the estimated makespan as a reward rtr_t at each step tt. Let C(Oi,j,st)C(O_{i,j},s_t) be a completion time lower bound at step tt, with

C(Oi,j,st)=C(Oi,j−1,st)+min⁡k∈Mijpijk,C(Oi,0)=0.(16)C(O_{i,j},s_t)=C(O_{i,j-1},s_t)+\min_{k\in\mathcal{M}_{ij}}p_{ij}^{k},\qquad C(O_{i,0})=0. \tag*{(16)}

Then we represent the step-wise reward as the difference of

rt=max⁡Oi,j∈OC(Oi,j,st)−max⁡Oi,j∈OC(Oi,j,st+1).(17)r_t=\max_{O_{i,j}\in\mathcal{O}}C(O_{i,j},s_t)-\max_{O_{i,j}\in\mathcal{O}}C(O_{i,j},s_{t+1}). \tag*{(17)}

With γ=1\gamma=1, maximizing the return ∑trt\sum_t r_t is equivalent to minimizing the makespan Cmax⁡C_{\max}.

e) Policy: We apply an actor-critic framework, specifically with a diffusion model-based policy π(at∣st)\pi(a_t\mid s_t) over at∈A(t)a_t\in\mathcal{A}(t). The details will be introduced in the following section.

Basics of Diffusion Models

The actor network of DredRL is based on a novel design and built upon a diffusion model that generates actions by iteratively denoising Gaussian noise conditioned on the processed state embeddings, enabling expressive action distributions under uncertainty [16]. Below we summarize the forward noising and reverse denoising processes in denoising diffusion probabilistic model (DDPM).

  1. Forward Process: The forward diffusion process gradually adds Gaussian noise to x0x_0, producing x1,…,xKx_1,\ldots,x_K:

q(xk∣xk−1)=N(xk∣1−βkxk−1,βkI),(18)q(x_k\mid x_{k-1})=\mathcal{N}\left(x_k\mid\sqrt{1-\beta_k}x_{k-1},\beta_k I\right), \tag*{(18)}

where βk\beta_k is scheduled for k=1,…,Kk=1,\ldots,K. Following [17], we use the variational posterior scheduler,

βk=1−e−βmin⁡K−2k−12K2(βmax⁡−βmin⁡),(19)\beta_k=1-e^{-\frac{\beta_{\min}}{K}-\frac{2k-1}{2K^2}(\beta_{\max}-\beta_{\min})}, \tag*{(19)}

with hyper-parameters βmin⁡\beta_{\min} and βmax⁡\beta_{\max}. The reverse conditional posterior (given x0x_0) is,

q(xk−1∣xk,x0)=N(xk−1;μ~(xk,k),β~kI),(20)q(x_{k-1}\mid x_k,x_0)=\mathcal{N}\left(x_{k-1};\widetilde{\mu}(x_k,k),\widetilde{\beta}_k I\right), \tag*{(20)}

where αk=1−βk\alpha_k=1-\beta_k and αˉk=∏i=1kαi\bar{\alpha}_k=\prod_{i=1}^{k}\alpha_i, and,

μ~(xk,k)=αk(1−αˉk−1)1−αˉkxk+αˉk−1βk1−αˉkx0,(21)\widetilde{\mu}(x_k,k)=\frac{\sqrt{\alpha_k}(1-\bar{\alpha}_{k-1})}{1-\bar{\alpha}_k}x_k+\frac{\sqrt{\bar{\alpha}_{k-1}}\beta_k}{1-\bar{\alpha}_k}x_0, \tag*{(21)}
β~k=1−αˉk−11−αˉk⋅βk.(22)\widetilde{\beta}_k=\frac{1-\bar{\alpha}_{k-1}}{1-\bar{\alpha}_k}\cdot\beta_k. \tag*{(22)}

Basics of Diffusion Models

Reverse Process

The reverse process starts from pure noise xK∼N(0,I)x_K\sim\mathcal{N}(0,I) and iteratively denoises to obtain x0x_0. Since p(xk−1∣xk)p(x_{k-1}\mid x_k) is intractable, we approximate it by,

pθ(xk−1∣xk)=N(xk−1;μθ(xk,k,s),Σθ(xk,k,s)),(23)p_\theta(x_{k-1}\mid x_k)=\mathcal{N}\left(x_{k-1};\mu_\theta(x_k,k,s),\Sigma_\theta(x_k,k,s)\right), \tag*{(23)}

where ss is the state embeddings, including operation, machine and operation-machine pairing features after dual representation. With the scheduler, we set Σθ(xk,k,s)=β~kI\Sigma_\theta(x_k,k,s)=\widetilde{\beta}_k I. We parameterize denoising via a noise-prediction network ϵθ(xk,k,s)\epsilon_\theta(x_k,k,s) and reconstruct,

x0=1αˉkxk+1αˉk−1⋅tanh⁡(ϵθ(xk,k,s)),(24)x_0=\frac{1}{\sqrt{\bar{\alpha}_k}}x_k+\sqrt{\frac{1}{\bar{\alpha}_k}-1}\cdot\tanh(\epsilon_\theta(x_k,k,s)), \tag*{(24)}

which yields the corresponding mean estimate,

μ~(xk,k,s)=1αk(xk−βktanh⁡(ϵθ(xk,k,s))1−αˉk).(25)\widetilde{\mu}(x_k,k,s)=\frac{1}{\sqrt{\alpha_k}}\left(x_k-\frac{\beta_k\tanh(\epsilon_\theta(x_k,k,s))}{\sqrt{1-\bar{\alpha}_k}}\right). \tag*{(25)}

Overall, the generation distribution is,

pθ(x0)=p(xK)∏k=1Kpθ(xk−1∣xk),(26)p_\theta(x_0)=p(x_K)\prod_{k=1}^{K}p_\theta(x_{k-1}\mid x_k), \tag*{(26)}

with p(xK)=N(0,I)p(x_K)=\mathcal{N}(0,I).

Decision Making Process

We hereby design the decision making process based on a actor-critic framework, where two Multi-Layer Perceptrons (MLPs) parameterized by θ\theta and ϕ\phi are used as actor and critic respectively. Specifically, MLP⁡θ\operatorname{MLP}_\theta is designed for DDPM. We denote a state embeddings after LL GAT layers as ss,

s=hop(L)∥hm(L)∥hG(L)∥h(Oi,j,Mk),(27)s=h_{\mathrm{op}}^{(L)}\mathbin\Vert h_{\mathrm{m}}^{(L)}\mathbin\Vert h_{\mathrm{G}}^{(L)}\mathbin\Vert h_{(O_{i,j},M_k)}, \tag*{(27)}

where h(Oi,j,Mk)h_{(O_{i,j},M_k)} is the operation-machine pairing features. The denoising process is repeatedly calculated through Eq. (25) and we may derive a scalar,

μ(at∣st)=DDPM⁡θ(st).(28)\mu(a_t\mid s_t)=\operatorname{DDPM}_\theta(s_t). \tag*{(28)}

After applying a softmax function, a policy is further derived as,

πθ(at∣st)=exp⁡(μ(at∣st))∑bt∈A(t)exp⁡(μ(bt∣st)).(29)\pi_\theta(a_t\mid s_t)=\frac{\exp(\mu(a_t\mid s_t))}{\sum_{b_t\in\mathcal{A}(t)}\exp(\mu(b_t\mid s_t))}. \tag*{(29)}

The critic network MLP⁡ϕ\operatorname{MLP}_\phi is an estimator which takes the global features hG(L)h_{\mathrm{G}}^{(L)} as input to produce a scalar vϕ(st)v_\phi(s_t) as an approximation of the state value.

Training

We use an encoder fψf_\psi, a diffusion actor πθ\pi_\theta and a critic model VϕV_\phi, initialized by parameters Θ={ψ,θ,ϕ}\Theta=\{\psi,\theta,\phi\}. The training target is to minimize the loss function regarding the parameters Θ\Theta. After computing advantages A^t\hat{A}_t, returns R^t\hat{R}_t by GAE(γ,λ)(\gamma,\lambda), and log⁡πθ(at∣st)\log\pi_\theta(a_t\mid s_t) is thereby calculated using the diffusion actor with mask Γ(t)\Gamma(t). And the probability ratio between old and updated policies will be denoted as,

rt(θ)=exp⁡(log⁡πθ(at∣st)−log⁡πθold(at∣st)).(30)r_t(\theta)=\exp\left(\log\pi_\theta(a_t\mid s_t)-\log\pi_{\theta_{\mathrm{old}}}(a_t\mid s_t)\right). \tag*{(30)}

A loss function in PPO-clip format is applied to train the proposed DredRL, with following components,

Ltclip(θ)=min⁡(rt(θ)A^t,clip⁡(rt(θ),1−ϵ,1+ϵ)A^t),(31)\mathcal{L}^{\mathrm{clip}}_t(\theta)=\min\left(r_t(\theta)\hat{A}_t,\operatorname{clip}\left(r_t(\theta),1-\epsilon,1+\epsilon\right)\hat{A}_t\right), \tag*{(31)}
Ltv(ϕ)=(Vϕ(st)−R^t)2,(32)\mathcal{L}^{\mathrm{v}}_t(\phi)=\left(V_\phi(s_t)-\hat{R}_t\right)^2, \tag*{(32)}
Ltent(θ)=H(πθ(⋅∣st)),(33)\mathcal{L}^{\mathrm{ent}}_t(\theta)=H\left(\pi_\theta(\cdot\mid s_t)\right), \tag*{(33)}

where ϵ\epsilon is a PPO-clip parameter. And the combined loss function will be described as Lt(Θ)\mathcal{L}_t(\Theta),

Lt(Θ)=Ltclip(θ)−cvLtv(ϕ)+centLtent(θ),(34)\mathcal{L}_t(\Theta)=\mathcal{L}^{\mathrm{clip}}_t(\theta)-c_{\mathrm{v}}\mathcal{L}^{\mathrm{v}}_t(\phi)+c_{\mathrm{ent}}\mathcal{L}^{\mathrm{ent}}_t(\theta), \tag*{(34)}

where cv,centc_{\mathrm{v}},c_{\mathrm{ent}} are value coefficient and entropy coefficient. Overall, the algorithm of DredRL can be described as Algorithm 1. The complexity analysis of it is included in the Appendix.

Algorithm 1: Training DredRL with PPO-Clip

Input: Environment E\mathcal{E}; dual-representation encoder fψf_\psi with cross-attention; per-candidate diffusion actor πθ\pi_\theta with KK reverse steps and prior scale s0s_0; critic VϕV_\phi; episodes EE, horizon TT, clip ϵ\epsilon, PPO epochs KepK_{\mathrm{ep}}, GAE (γ,λ)(\gamma,\lambda).

Output: ψ∗,θ∗,ϕ∗\psi^*,\theta^*,\phi^*

  1. Initialize Θ={ψ,θ,ϕ}\Theta=\{\psi,\theta,\phi\}; Θold←Θ\Theta_{\mathrm{old}}\leftarrow\Theta;

  2. for ep=1\mathrm{ep}=1 to EE do

  3. if ep mod Erst=0\mathrm{ep}\bmod E_{\mathrm{rst}}=0 then draw a fresh batch of training instances;

  4. Reset E\mathcal{E}; observe raw features H0\mathcal{H}_0;

  5. for t=0t=0 to T−1T-1 do

  6. Form candidate set AtA_t and mask Γt\Gamma_t from Ht\mathcal{H}_t;

  7. (Htop,Htm,hˉtop,hˉtm)←fψold(Ht,At)(\mathcal{H}^{\mathrm{op}}_t,\mathcal{H}^{\mathrm{m}}_t,\bar{h}^{\mathrm{op}}_t,\bar{h}^{\mathrm{m}}_t)\leftarrow f_{\psi_{\mathrm{old}}}(\mathcal{H}_t,A_t);

  8. Build per-candidate states {st,c}c∈At\{s_{t,c}\}_{c\in A_t} by (24);

  9. for c∈Atc\in A_t (in parallel) do

  10. xKc∼N(0,s02I)x^c_K\sim\mathcal{N}(0,s_0^2I);

  11. x0c←Reverse⁡θolddet(xKc,st,c)x^c_0\leftarrow\operatorname{Reverse}^{\mathrm{det}}_{\theta_{\mathrm{old}}}(x^c_K,s_{t,c}) by (21);

  12. end

  13. πθold(⋅∣st)←softmax⁡(gθold(x0c)+Γt)\pi_{\theta_{\mathrm{old}}}(\cdot\mid s_t)\leftarrow\operatorname{softmax}(g_{\theta_{\mathrm{old}}}(x^c_0)+\Gamma_t);

  14. Sample at∼πθold(⋅∣st)a_t\sim\pi_{\theta_{\mathrm{old}}}(\cdot\mid s_t); store (st,at,rt,Vϕold(st),log⁡πθold,Γt)(s_t,a_t,r_t,V_{\phi_{\mathrm{old}}}(s_t),\log\pi_{\theta_{\mathrm{old}}},\Gamma_t);

  15. Step E\mathcal{E} to obtain rt,Ht+1r_t,\mathcal{H}_{t+1};

  16. end

  17. Compute A^t,R^t\hat{A}_t,\hat{R}_t by GAE(γ,λ)(\gamma,\lambda);

  18. for u=1u=1 to KepK_{\mathrm{ep}} do

  19. for minibatch BB do

  20. rt(θ)←exp⁡(log⁡πθ(at∣st)−log⁡πθold(at∣st))r_t(\theta)\leftarrow\exp(\log\pi_\theta(a_t\mid s_t)-\log\pi_{\theta_{\mathrm{old}}}(a_t\mid s_t));

  21. Update Θ\Theta by ascending L(Θ)\mathcal{L}(\Theta) in (29);

  22. end

  23. end

  24. Θold←Θ\Theta_{\mathrm{old}}\leftarrow\Theta;

  25. if ep mod Eval=0\mathrm{ep}\bmod E_{\mathrm{val}}=0 then validate on Eval\mathcal{E}_{\mathrm{val}};

  26. end

  27. return ψ∗,θ∗,ϕ∗\psi^*,\theta^*,\phi^*

Results

Experimental Setup

We present the experimental setup in the following aspects. Our experiments were conducted by a machine with an NVIDIA GeForce RTX 4090 GPU with 24GB memory and an Intel Core Ultra 7 265KF 20-Core CPU and 64GB of DDR5 RAM. The operating system is Ubuntu 24.04.2 LTS with CUDA V12.2 toolkit. Besides, our experiments are organized with the following details.

  1. Datasets: For each FJSP configuration with nn jobs and mm machines, we generate 100 random instances for evaluation. Following existing works, we consider three types of synthetic datasets. The first dataset, denoted as SD1, follows [7], where each job contains a varying number of sequential operations. For each operation Oi,jO_{i,j} in an n×mn\times m instance, the number of compatible machines ∣Mi,j∣\lvert M_{i,j}\rvert and the corresponding processing time pi,jkp^k_{i,j} on machine MkM_k are sampled from U(1,m)U(1,m) and U(1,20)U(1,20), respectively. SD2 follows the same generation procedure but increases the processing-time range to U(1,99)U(1,99). To further evaluate robustness under processing-time uncertainty, we additionally adopt SD3 following SPM-DAN [10]. SD3 retains the instance structure of SD2 while introducing correlated processing times across compatible machines. Specifically, a base processing time pi,j∼U(1,99)p_{i,j}\sim U(1,99) is first generated for each operation, after which the machine-specific processing time is sampled as pi,jk∼U(0.85pi,j,1.15pi,j)p^k_{i,j}\sim U(0.85p_{i,j},1.15p_{i,j}). To construct stochastic instances, each deterministic processing time is treated as the median, and a coefficient of variation CVi,jk∼U(0.1,0.5)CV^k_{i,j}\sim U(0.1,0.5) is sampled for each operation–machine pair, with σi,jk=CVi,jkpi,jk\sigma^k_{i,j}=CV^k_{i,j}p^k_{i,j}. Following [10], log-normal processing-time distributions are used to represent stochastic realizations. For comprehensive evaluation, the deterministic SD1 and SD2 datasets are divided into two groups. The general-size group contains 10×510\times5, 20×520\times5, 15×1015\times10, and 20×1020\times10 instances, while the large-size group contains 30×1030\times10, 40×1040\times10, 100×10100\times10, and 200×10200\times10 instances. Models are trained and tested on the general-size datasets, whereas the large-size instances are used only for testing to evaluate cross-size generalization without size-specific retraining. For stochastic evaluation on SD3, we consider 10×510\times5, 20×520\times5, 15×1015\times10, and 20×1020\times10 instances and compare DredRL with deterministic and stochastic scheduling baselines under the same uncertainty setting.

  1. Hyperparameters: The actor and critic networks are optimized using learning rates α=3×10−4\alpha=3\times10^{-4}. We set the discount factor to γ=1\gamma=1 to optimize the undiscounted episodic objective to ensure the optimization of total makespan. The graph-attention encoder employs L=2L=2 graph attention layers (GALs) with H=4H=4 attention heads per layer. For the diffusion-based policy network, the DDPM denoiser runs for K=10K=10 denoising steps. Training is conducted for at most E=1000E=1000 episodes, and the policy is validated every Eval=10E_{\mathrm{val}}=10 episodes. The PPO-style loss uses coefficients cp=1c_{\mathrm{p}}=1 for the policy term and cv=0.5c_{\mathrm{v}}=0.5 for the value term, and an entropy regularization coefficient cent=0.01c_{\mathrm{ent}}=0.01 is applied to

encourage exploration. Generalized advantage estimation (GAE) parameters λ=0.98\lambda= 0.98 for SD1 and SD2 are applied to stabilize the training process. Finally, the hidden layers in actor and critic MLPs are parameterized as MLPa=[64,64]\mathrm{MLP}_{a} = [64, 64] and MLPc=[64,64]\mathrm{MLP}_{c} = [64, 64] respectively, representing two hidden layers with the specified numbers of neurons in each MLP. The PPO update epoch per batch is Kep=4K_{\mathrm{ep}} = 4 and minibatch size is B=1024\mathcal{B} = 1024. For the stochastic SD3 experiments, additional parameters are introduced to characterize processing-time uncertainty. The base processing time is sampled from [pmin⁡,pmax⁡]=[1,99][p_{\min},p_{\max}] = [1, 99], and the processing time on each compatible machine is generated by applying a multiplicative perturbation δ∼U(0.85,1.15)\delta\sim U(0.85, 1.15) to the corresponding base processing time. The coefficient of variation for each operation–machine pair is sampled as CV∼U(0.1,0.5)CV \sim U(0.1, 0.5) to represent heterogeneous processing-time uncertainty. For stochastic decision evaluation, the Value-at-Risk confidence level is set to αVaR=0.95\alpha_{\mathrm{VaR}} = 0.95. Unless otherwise stated, the remaining network architecture and DRL training settings are kept consistent with those used for SD1 and SD2. Details are further included in Appendix.

3) Comparison Baselines: We evaluate DredRL against representative SOTA baselines and an optimization-based reference solver, OR-Tools, which can produce optimal or near-optimal schedules via combinatorial optimization. However, since FJSP is NP-hard, OR-Tools may require prohibitive runtime to certify optimality, particularly for large-scale instances. Following common practice, we therefore treat OR-Tools solutions as strong references rather than true optima, and impose a 30-minute time limit. We further compare with three recent learning-based SOTA methods, HGNN [7], DANIEL [8] and SPM-DAN [10]. HGNN formulates FJSP as a heterogeneous graph and leverages GNN message passing to capture relationships among scheduling entities, while DANIEL employs attention-based GAT for decision making. SPM-DAN further extends DANIEL to stochastic FJSP by introducing an attention-based scenario processing module that explicitly encodes sampled processing-time scenarios, enabling the policy to account for uncertainty during scheduling. For fairness, we report results from the original papers whenever available under their recommended settings; otherwise, we re-implement the methods to obtain missing results. Each result has been averaged from 10 independent runs due to the stochastic nature of algorithms.

Deterministic Results

1) Small and Large Size Instances: We first evaluate DredRL on small FJSP instances from SD1 and SD2 under both greedy and sampling decoding, as reported in Table I. Overall, DredRL consistently outperforms HGNN and remains competitive with or improves upon the SOTA learning-based baseline DANIEL. Considering the better decoding result of each method, DredRL achieves a lower makespan than DANIEL in 5 out of the 8 small-scale configurations, with an average makespan reduction of 1.46% across these settings. The improvement is more

SizeHGNN [7]DANIEL [8]DredRL (Ours)OR-Tools
GreedySamplingGreedySamplingGreedySampling
SD110 × 5Makespan111.67105.59106.71101.67106.2499.7996.32
Gap15.94%9.62%10.79%5.55%10.30%3.60%
20 × 5Makespan201.42207.53197.56192.78197.86193.45188.15
Gap12.26%10.3%5.01%2.46%5.16%2.82%
15 × 10Makespan166.92161.28160.86153.22160.54152.86143.53
Gap16.30%12.37%12.07%6.75%11.85%6.50%
20 × 10Makespan215.78214.81198.50193.91199.82195.30195.95
Gap10.10%9.61%1.29%-1.06%1.97%-0.35%
30 × 10Makespan314.71308.55288.61286.77292.07285.07274.67
Gap14.58%12.33%5.08%4.41%6.33%3.79%
40 × 10Makespan417.87410.76379.28379.71384.20378.14365.96
Gap14.18%12.24%3.64%3.76%4.98%3.33%
100 × 10Makespan1035.01023.6946.0985.3930.5918.1944.2
Gap9.62%8.41%0.19%4.35%-1.45%-2.76%
200 × 5Makespan2055.12042.01901.12018.21903.051833.91884.7
Gap9.04%8.35%0.87%7.08%0.97%-2.69%
SD210 × 5Makespan553.61483.39408.4366.74411.11361.26326.24
Gap69.69%48.33%25.18%12.41%26.01%10.73%
20 × 5Makespan1059.04962.90671.03629.94666.82630.88602.04
Gap75.91%59.94%11.46%4.63%10.76%4.79%
15 × 10Makespan944.09756.07591.21521.83580.55493.42377.17
Gap114.09%100.46%56.75%38.35%53.92%30.82%
20 × 10Makespan1452.82990.37610.16535.64602.43531.39464.16
Gap126.12%113.37%31.45%19.06%29.79%14.48%
30 × 10Makespan1564.571486.56794.62757.48785.19749.53692.26
Gap126.01%114.74%14.79%9.42%13.42%8.27%
40 × 10Makespan2048.961976.25983.37951.21973.98943.43998.39
Gap105.23%97.94%-1.50%-4.73%-2.44%-5.50%
100 × 10Makespan5046.94844.72233.42253.22223.92236.52114.5
Gap138.68%129.12%5.62%6.56%5.17%5.77%
200 × 5Makespan9985.49674.75923.87093.45915.16069.15876.3
Gap69.93%64.64%0.81%20.71%0.66%3.28%

Table I. Performance comparison of different algorithms on synthetic datasets SD1 and SD2 with different instance sizes. Results are included with makespan and corresponding relative gap (%) to OR-Tools.

pronounced on SD2, where DredRL achieves an average reduction of 2.66% over DANIEL, compared with 0.25% on SD1. This trend indicates a stronger advantage under the higher processing-time variability of SD2, where scheduling decisions become more challenging. In particular, on SD2 15×10, DredRL reduces the best DANIEL makespan from 521.83 to 493.42, corresponding to a 5.44% reduction, while decreasing the relative gap to OR-Tools from 38.35% to 30.82%. A similar improvement is observed on SD2 20×10, where the makespan decreases from 552.64 to 531.39 and the corresponding gap is reduced from 19.06% to 14.48%. Although DANIEL remains slightly better on SD1 20×5, SD1 20×10, and SD2 20×5, the differences are small, whereas DredRL provides more substantial gains on the more difficult SD2 cases. In addition, sampling generally improves the quality of the learned schedules: sampling produces a lower makespan than greedy decoding for DredRL in 14 of the 16 configurations in Table I. Several cases also yield negative gaps relative to OR-Tools, indicating that the learned policies can occasionally discover schedules with smaller makespan than those returned by the time-limited solver. Since OR-Tools is executed under a fixed computational budget of up to 1800 seconds and may terminate before reaching proven optimality, these negative gaps indicate that the learned policies can discover higher-quality schedules within only a few seconds of inference. This further indicates their computational efficiency for time-sensitive scheduling applications.

We further investigate the scalability and cross-size generalization of DredRL on the larger 30×10, 40×10, 100×10, and 200×5 instances. The model trained on small instances is directly transferred to these larger configurations without size-specific retraining. Notably, DredRL achieves the best learning-based makespan in all 8 large-scale settings when compared with the better of greedy and sampling decoding for DANIEL and HGNN. Relative to the best DANIEL result for each configuration, DredRL obtains an average makespan reduction of 1.23%, with improvements observed consistently across both SD1 and SD2. The gains are particularly evident on the largest SD1 instances. On SD1 100×10, DredRL reduces the makespan from 946.0 to 918.1, corresponding to a 2.95% improvement over DANIEL, while changing the OR-Tools-relative gap from 0.19% to −2.76%. An even larger improvement is obtained on SD1 200×5, where DredRL reduces the best DANIEL makespan from 1901.1 to 1833.9, a 3.53% reduction, and achieves a gap of −2.69% relative to OR-Tools. On SD2, DredRL also maintains consistent advantages as the problem scale increases. For example, on SD2 30×10, it reduces the makespan from 757.48 to 749.53 and the corresponding gap from 9.42% to 8.27%. On SD2 40×10, DredRL further improves the best DANIEL makespan from 951.21 to 943.43, yielding the lowest gap of −5.50% among all compared methods. Even on the largest SD2 cases, the advantage is preserved: DredRL reduces the makespan from 2233.4 to 2223.9 on 100×10 and from 5923.8 to 5915.1 on 200×5. Interestingly, greedy decoding becomes preferable to sampling for DredRL on these two largest SD2 instances, suggesting that the relative benefit of stochastic decoding may depend on the problem scale. Overall, across all 16 configurations in Table I, DredRL outperforms the best DANIEL decoding in 13 cases and achieves an average makespan reduction of 1.34%. More importantly, its consistent advantage across all evaluated larger-scale instances demonstrates stronger cross-size generalization and scalability, suggesting that the learned operation–machine representations remain effective as the scheduling problem expands substantially beyond the training scale.

Public Benchmarks

To verify the performance in solving real-world problems, we also evaluate DredRL based on a few commonly used public datasets mk and la, while la includes rdata, edata, vdata. All of the models are trained on the synthetic dataset which includes small 10×5 instances and tested on four public data benchmarks. Table II reports results on four public benchmarks and shows that DredRL achieves consistently strong performance against HGNN and DANIEL under both greedy and sampling decoding. As reported in Table II, on mk, DredRL reduces the makespan from 180.8 with DANIEL to 178.1, decreasing the relative gap to OR-Tools from 3.79% to 2.24%. A similar advantage is observed on edata, where DredRL achieves a makespan of 1106.7, compared with 1122.6 for DANIEL, reducing the corresponding gap from 9.10% to 7.56%. On vdata, DredRL further obtains the lowest learning-based makespan of 924.41 and a gap of only 0.52%, slightly improving upon DANIEL at 925.4 and 0.63%, respectively. The only exception is rdata, where DANIEL sampling achieves a marginally lower makespan of 978.28 than DredRL’s 979.9, corresponding to gaps of 4.54% and 4.71%, respectively. Overall, DredRL achieves an average gap of 3.76% to the time-limited OR-Tools reference across the four public benchmarks, compared with 4.52% for DANIEL and 6.11% for HGNN under their respective sampling modes. This corresponds to a 0.76 percentage-point reduction in the average gap over DANIEL. These results demonstrate that DredRL learns transferable scheduling representations that generalize effectively beyond the training distribution.

Public BenchmarksHGNN [7]DANIEL [8]DredRL (Ours)OR-Tools
GreedySamplingGreedySamplingGreedySampling
mkMakespan201.4190.3185.7180.8182.8178.1174.2
Gap15.61%9.41%6.60%3.79%4.94%2.24%
lardataMakespan1030.83985.31031.63978.281026.6979.9935.8
Gap10.15%5.29%10.24%4.54%9.70%4.71%
edataMakespan1187.481116.681194.981122.61164.81106.71028.9
Gap15.41%8.53%16.14%9.10%13.21%7.56%
vdataMakespan955.9930.80944.85925.4941.7924.41919.6
Gap3.95%1.22%2.75%0.63%2.40%0.52%

Table II. Performance comparison of different algorithms on public benchmarks.

Stochastic Research

To further evaluate DredRL under stochastic processing times, we conduct experiments on the SD3 dataset following the generation protocol in [10]. SD3 preserves the instance structure of SD2 but introduces stronger correlation among the processing times of an operation across-compatible machines. Specifically, a base processing time pijp_{ij} is first sampled from U(1,99)\mathcal{U}(1,99) for each operation OijO_{ij}, and its machine-dependent processing time is then generated as pijk∼U(0.85pij,1.15pij)p_{ij}^{k} \sim\mathcal{U}(0.85p_{ij},1.15p_{ij}). To construct stochastic instances, the deterministic processing time is treated as the median, while the coefficient of variation is sampled from U(0.1,0.5)\mathcal{U}(0.1,0.5) to determine the uncertainty level of each operation–machine pair. Following the evaluation setting in [10], we consider four instance sizes, 10×5, 20×5, 15×10, and 20×10, and compare DredRL with DANIEL, SPM-DAN, and the OR-Tools’ CP-SAT solver and CP-Stoch algorithm [10] baselines. Both greedy and sampling inference are reported for the learning-based methods to provide a consistent comparison under stochastic scheduling conditions.

As shown in Table III, DredRL demonstrates strong performance on SD3, particularly under sampling inference. Compared with DANIEL, DredRL achieves a lower sampling makespan on all four instance sizes, with reductions of 1.74%, 2.81%, 2.53%, and 3.06% for 10×5, 20×5, 15×10, and 20×10, respectively. More importantly, DredRL achieves the best learning-based results on three of the four configurations, outperforming the stochasticity-aware SPM-DAN on 10×5, 20×5, and 15×10. Its gaps to the deterministic OR-Tools reference are consistently negative under sampling, ranging from −1.39% to −4.11%, indicating that DredRL obtains better schedules than the time-limited OR-Tools reference on all settings. It also outperforms CP-Stoch on three of the four problem sizes, with only a marginal difference on 10×510 \times5. Although SPM-DAN achieves the best result on 20×1020 \times10, the consistently competitive performance of DredRL across different problem sizes demonstrates its ability to capture processing-time uncertainty without relying on a dedicated scenario-processing architecture. This highlights the robustness and adaptability of the representation and diffusion mechanism.

SizeDANIEL [8]SPM-DAN [10]DredRL (Ours)OR-Tools
GreedySamplingGreedySamplingGreedySamplingCP-SATCP-Stoch [10]
10 × 5Makespan722.77688.74710.63677.24712.30676.74688.10676.19
Gap5.04%0.09%3.27%-1.58%3.52%-1.65%--1.73%
20 × 5Makespan1307.481272.081279.701243.751276.491236.301253.671271.71
Gap4.29%1.47%2.08%-0.79%1.82%-1.39%-1.44%
15 × 10Makespan1111.551066.601090.921039.731091.031039.591074.881105.90
Gap3.41%-0.77%1.49%-3.27%1.50%-3.28%-2.89%
20 × 10Makespan1376.181336.971289.771261.801302.801296.061351.581406.68
Gap1.82%-1.08%-4.57%-6.64%-3.61%-4.11%-4.08%

Table III. Performance comparison of different algorithms on synthetic datasets SD3 with different instance sizes.

Ablation Study on Representation and Diffusion

To investigate whether the performance gain comes from the proposed DredRL representation, the diffusion-based decision model, or their combination, we organize a controlled comparison with four configurations: DANIEL, DredRL-MLP, proposed DredRL (we note as DredRL-Diffusion below), and DANIEL-Diffusion, all using greedy method. This design allows us to separately examine the effect of replacing the original representation with DredRL, introducing diffusion into different model architectures, and the interaction between the two components.

We evaluate all configurations on six SD2 problem sizes. For each setting, we report the mean and standard deviation of makespan over five training seeds to assess both solution quality and training stability. We then compare the relative gap to the OR-Tools reference across test instances, where proven optimal solutions are used when available and the time-limited OR-Tools solutions are used as references otherwise.

The results in Figure 3 demonstrate the advantage of incorporating diffusion into DredRL. Among the four methods, DredRL-Diffusion achieves the best mean makespan on four of the six problem sizes (15×1015 \times10, 20×520 \times5, 30×1030 \times10, and 40×1040 \times10), while DredRL-MLP performs best on the remaining two. In terms of solution quality relative to OR-Tools, DredRL-Diffusion also obtains the lowest average gap of 23.36% across all problem sizes, compared with 23.56% for DredRL-MLP and 24.00% for DANIEL. Notably, it achieves increasingly competitive results on larger instances, including gaps of 13.48% and −0.44% on 30×1030 \times10 and 40×1040 \times10, respectively. In addition to solution quality, DredRL-Diffusion exhibits competitive stability and robustness across the five random seeds, with an average makespan standard deviation of 4.04, compared with 4.08 for DredRL-MLP and 4.73 for DANIEL. In contrast, directly combining diffusion with DANIEL results in substantially higher training variance, with an average standard deviation of 14.74. Even on the larger 30×1030 \times10 and 40×1040 \times10 instances, where the variance of DredRL-Diffusion increases to 7.31 and 7.34, it remains substantially below the 20.24 and 22.81 observed for DANIEL-Diffusion. These results suggest that DredRL-Diffusion provides the strongest overall trade-off between solution quality, scalability, and training stability, and is therefore adopted as the final configuration.

Figure 3. Comparison of relative makespan gaps to the OR-Tools reference on SD2 across different problem sizes.

Conclusion

This paper presented DredRL, a dual-representation-enhanced diffusion-policy reinforcement learning framework for FJSP. By coupling operation and machine representations through enhanced self-attention and cross-attention, DredRL captures both intra-entity dependencies and inter-entity compatibility more effectively than prior DRL schedulers. In addition, a diffusion model is employed as the policy network to improve the expressiveness and robustness of scheduling decisions. Extensive experiments on synthetic, public, large-scale, and stochastic FJSP benchmarks demonstrate that DredRL consistently outperforms SOTA learning-based methods across most configurations. Compared with DANIEL, it reduces makespan by up to 5.44% on small-scale instances and 3.53% on larger-scale instances without size-specific retraining. It also achieves the best learning-based performance on most public benchmarks and outperforms the stochasticity-aware SPM-DAN on three of four SD3 configurations. These results demonstrate strong cross-size and cross-distribution generalization, and robustness to processing-time uncertainty, showing the effectiveness of combining enhanced dual representations with diffusion-based policies for scalable FJSP scheduling.

Future work will extend DredRL to multi-objective optimization and complex dynamic environments, including machine breakdowns and new job arrivals. We will also investigate more efficient diffusion-policy inference, such as reducing denoising steps and policy distillation, to further improve computational efficiency and facilitate industrial deployment.

References

  1. [1]National Research Foundation Singapore, “Research, innovation and enterprise 2030 (rie2030) factsheet,” https://file.go.gov.sg/rie2030factsheet.pdf, 2025, accessed: 2026-03-13.
  2. [2]C. Özgüven, L. Özbakır, and Y. Yavuz, “Mathematical models for job-shop scheduling problems without routing and process plan flexibility,” Applied mathematical modelling, vol. 34, no. 6, pp. 1539–1548, 2010.
  3. [3]N. B. Ho and J. C. Tay, “Evolving dispatching rules for solving the flexible job-shop problem,” in 2005 IEEE congress on evolutionary computation, vol. 3. IEEE, 2005, pp. 2848–2855.DOI
  4. [4]L. Perron and V. Furnon, “OR-Tools,” https://developers.google.com/optimization/, google. Accessed: 2026-03-14.
  5. [5]D. Rooyani and F. M. Defersha, “An efficient two-stage genetic algorithm for flexible job-shop scheduling,” Ifac-PapersOnline, vol. 52, no. 13, pp. 2519–2524, 2019.DOI
  6. [6]F. Ni, J. Hao, J. Lu, X. Tong, M. Yuan, J. Duan, Y. Ma, and K. He, “A multi-graph attributed reinforcement learning based optimization algorithm for large-scale hybrid flow shop scheduling problem,” in Proceedings of the 27th ACM SIGKDD conference on knowledge discovery & data mining, 2021, pp. 3441–3451.DOI
  7. [7]W. Song, X. Chen, Q. Li, and Z. Cao, “Flexible job-shop scheduling via graph neural network and deep reinforcement learning,” IEEE Transactions on Industrial Informatics, vol. 19, no. 2, pp. 1600–1610, 2022.DOI
  8. [8]R. Wang, G. Wang, J. Sun, F. Deng, and J. Chen, “Flexible job shop scheduling via dual attention network-based reinforcement learning,” IEEE Transactions on Neural Networks and Learning Systems, vol. 35, no. 3, pp. 3091–3102, 2023.arxiv.org/abs/2305.05119
  9. [9]N.-C. Huang, P.-C. Hsieh, K.-H. Ho, and I.-C. Wu, “Ppo-clip attains global optimality: Towards deeper understandings of clipping,” in Proceedings of the AAAI Conference on Artificial Intelligence, vol. 38, no. 11, 2024, pp. 12600–12607.arxiv.org/abs/2312.12065
  10. [10]I. G. Smit, Y. Wu, P. Troubil, Y. Zhang, and W. P. Nuijten, “Neural combinatorial optimization for stochastic flexible job shop scheduling problems,” in Proceedings of the AAAI Conference on Artificial Intelligence, vol. 39, no. 25, 2025, pp. 26 678–26 687.arxiv.org/abs/2412.14052
  11. [11]J.-D. Zhang, Z. He, W.-H. Chan, and C.-Y. Chow, “Deepmag: Deep reinforcement learning with multi-agent graphs for flexible job shop scheduling,” Knowledge-Based Systems, vol. 259, p. 110083, 2023.DOI
  12. [12]Y. Xiao, D. Wang, R. Cao, X. Wu, B. Li, and Y. Zhou, “Geld: A unified neural model for efficiently solving traveling salesman problems across different scales,” Pattern Recognition, p. 112865, 2025.arxiv.org/abs/2506.06634
  13. [13]K. Lei, P. Guo, W. Zhao, Y. Wang, L. Qian, X. Meng, and L. Tang, “A multi-action deep reinforcement learning framework for flexible job-shop scheduling problem,” Expert Systems with Applications, vol. 205, p. 117796, 2022.DOI
  14. [14]P. Veličković, G. Cucurull, A. Casanova, A. Romero, P. Liò, and Y. Bengio, “Graph attention networks,” 2018. [Online]. Available: https://arxiv.org/abs/1710.10903
  15. [15]A. Vaswani, N. Shazeer, N. Parmar, J. Uszkoreit, L. Jones, A. N. Gomez, L. Kaiser, and I. Polosukhin, “Attention is all you need,” 2023. [Online]. Available: https://arxiv.org/abs/1706.03762
  16. [16]Y. Zhao, W. Zhang, C. Xiang, H. Du, D. Niyato, and S. Gao, “Diffusion-modeled representation learning for carbon and risk-aware microgrid optimization,” in International Conference on Pattern Recognition. Springer, 2026, pp. 1–16.arxiv.org/abs/2507.16867
  17. [17]J. Ho, A. Jain, and P. Abbeel, “Denoising diffusion probabilistic models,” Advances in neural information processing systems, vol. 33, pp. 6840–6851, 2020.arxiv.org/abs/2006.11239

Paper details

vlnc:W_j3ua3hzv
Published
Fresh — added to the Hub within the last 30 days
Added
License
CC BY 4.0
Usage

views · 12

downloads · 1

A view counts once per browser per day, a download each time the PDF is requested.

  • Computer Science

Not recorded for this paper

View statement
Looking for related papers…
Contents