Route2vec: Embedding Wafer Process Trajectories
- Route2vec is a representation mapping within Partial Trajectory Regression that converts variable-length wafer processing steps into a fixed-dimensional vector for counterfactual attribution.
- It employs a constrained recurrent architecture with a linear additive update modulated by logarithmic temporal scaling to ensure numerical stability and interpretability.
- Empirical evaluations demonstrate that route2vec enhances defect prediction accuracy and attribution precision, outperforming baseline methods in semiconductor manufacturing.
route2vec is a representation-learning mapping introduced within the Partial Trajectory Regression (PTR) framework for wafer defect root cause analysis. Its purpose is to encode a wafer’s variable-length sequence of heterogeneous process steps into a fixed-dimensional vector that summarizes the entire upstream processing history while preserving information needed for prefix-based counterfactual analysis. In the formulation reported for wafer history data from the NY CREATES fab in Albany, route2vec operates on sequences of proc2vec embeddings paired with timestamps, uses a constrained recurrent structure with a linear additive cell, and supports both defect-density prediction and additive attribution of individual process steps (Miyaguchi et al., 27 Jul 2025).
1. Definition and role in wafer process trajectory modeling
Within PTR, route2vec is defined as a function that maps an arbitrary-length sequence of proc2vec embeddings,
to a single -dimensional vector
where is the proc2vec embedding of the -th physical process step and is its timestamp (Miyaguchi et al., 27 Jul 2025).
The stated objective is twofold. First, route2vec enables trajectory regression models to operate on fixed-dimensional inputs despite variable route lengths. Second, it preserves causal and sequential information so that partial trajectories, specifically prefixes of , also admit meaningful embeddings for counterfactual attribution. This second objective is central to PTR, because attribution is defined not only on full routes but on successive partial histories.
The need for such a mapping arises from the setting addressed by PTR: wafer process flows exhibit combinatorial variability, including rework operations and random process waiting times, and therefore cannot be handled cleanly by conventional vector-based regression models when route length and process composition vary across wafers. Route2vec is the component that converts this irregular temporal-sequential object into a form suitable for regression and attribution.
2. Relationship to proc2vec and the route representation
Route2vec does not begin from raw symbolic process labels. Its input is a sequence of proc2vec embeddings, and the paper makes the dependence explicit by describing route2vec as a mapping over “a sequence of proc2vec embeddings” (Miyaguchi et al., 27 Jul 2025). The upstream tokenization is based on high-level process tokens such as “eqp⨁recipe⨁tool_type⨁…”, which are embedded using kernel MDS on a custom string kernel.
Let denote the vocabulary size of distinct tokens and let
be the precomputed substring kernel matrix with eigenpairs 0, 1. The 2-dimensional proc2vec embedding of token 3 is then defined as
4
This construction fixes the semantic substrate on which route2vec operates. Route2vec therefore aggregates a temporally ordered series of token embeddings that already encode similarity structure among heterogeneous process steps. A plausible implication is that route2vec separates two modeling burdens: proc2vec captures token-level similarity, while route2vec captures route-level accumulation over time. That interpretation is consistent with the architecture as reported, although the paper’s concrete claim is simply that proc2vec and route2vec jointly enable the comparison of counterfactual outcomes derived from partial process trajectories (Miyaguchi et al., 27 Jul 2025).
3. Constrained recurrent architecture and temporal weighting
The route2vec architecture is described as a constrained recurrent structure, or C-RNN. Although it may be viewed conceptually as an RNN or gated cell, the implementation uses a linear additive cell in order to enhance numerical stability under small sample sizes (Miyaguchi et al., 27 Jul 2025). The recurrence is initialized with
5
and updated for 6 by
7
The concrete cell is
8
where the temporal scaling function is fixed as
9
Thus, each step contributes its proc2vec embedding scaled by the log-transformed waiting time
0
after which the contribution is added to the running summary. The final full-route embedding is
1
In practice, the paper sets 2, while noting that the notation 3 leaves open the possibility of projection to a different dimension. The reported formulation emphasizes simplicity and interpretability: the route embedding is an additive accumulation of time-modulated step embeddings rather than the hidden state of a nonlinear gated architecture. This is important for PTR because the prefix embeddings 4 must support stable regression and stepwise differences. A common misconception would be to treat route2vec as an unrestricted sequence model; in the reported formulation it is deliberately constrained and linear in its recurrence (Miyaguchi et al., 27 Jul 2025).
4. Regression interface and optimization objective
The route embedding of any prefix is fed into a simple projection layer to predict defect density. The predictor is an MLP with zero hidden layers,
5
where 6 and 7 are learnable (Miyaguchi et al., 27 Jul 2025).
The training loss augments supervision over all prefixes for numerical stability:
8
with 9 the 0-regularization strength.
Several details of this optimization setup are explicit. The data preparation uses 1 wafers, from which each wafer’s route 2 and scalar defect density 3 are extracted. Each prefix embedding 4 is treated as an input-output pair to augment the dataset. The reported hyperparameters include embedding dimension 5 with an example value of 6, regularization 7 selected by cross-validation, and fixed temporal scaling 8. Optimization minimizes the loss by batch gradient descent with Adam using learning rate 9, batch size 0 wafer-prefix embeddings, and 1 epochs, with early stopping on a held-out 2 validation split (Miyaguchi et al., 27 Jul 2025).
The paper also notes that both the route2vec cell and the proc2vec embedding are kept frozen in the reported experiments, although back-propagation through them is possible in principle. This distinction is methodologically important: the learned component in the reported pipeline is the linear projection layer, whereas the sequence representation itself is predefined by the proc2vec embedding and the additive temporal recurrence.
5. Integration with Partial Trajectory Regression and attribution
The integration of route2vec into PTR is explicit and operational. Once route2vec produces prefix embeddings 3, PTR defines the attribution score of the 4-th process step in route 5 as
6
This quantity measures the marginal effect of including step 7 relative to the preceding partial trajectory (Miyaguchi et al., 27 Jul 2025).
The cumulative form is equally central:
8
The paper states that this ensures an additive explanation consistent with Rubin’s potential outcome framework. Because route2vec provides embeddings for every prefix rather than only the full route, the regression model can compare two counterfactual partial trajectories that differ by one included step. In that sense, route2vec is not merely a compression device; it is the mechanism that makes the prefix-wise counterfactual construction feasible.
This additive attribution structure also clarifies why the recurrence is simple. Since the attribution score is defined as a difference between predictions on successive prefix embeddings, interpretability benefits from a route representation whose update from 9 to 0 is transparent. A plausible implication is that the architecture was selected not only for numerical stability under small sample sizes but also for compatibility with incremental attribution.
6. Empirical evaluation and reported performance
The empirical evaluation reported for route2vec covers embedding quality, downstream regression, and attribution behavior on held-out high-defect wafers (Miyaguchi et al., 27 Jul 2025). The comparison on correlation with final wafer defect density involved three alternatives: a constant baseline, one-hot embeddings, and kernel-MDS proc2vec embeddings plugged into route2vec.
| Setting | Reported correlation |
|---|---|
| Constant baseline | 1 |
| One-hot embeddings | 2 |
| Kernel-MDS proc2vec + route2vec | 3 |
The paper also reports that a t-SNE visualization of proc2vec tokens showed clear clustering by tool type. For downstream regression, using the linear projection 4 over route2vec embeddings with prefix-augmented training improved test correlation to 5. For attribution accuracy, the PTR cumulative attribution plot,
6
highlighted two processing steps, described as long waits at specific tools, with large positive jumps; domain experts confirmed these as likely root causes (Miyaguchi et al., 27 Jul 2025).
These results support two distinct claims. First, the proc2vec-plus-route2vec representation is more predictive than the two baselines listed for the correlation criterion reported. Second, prefix augmentation materially improves the regression model used downstream of route2vec. The attribution result further indicates that the representation is not only predictive but operationally useful for isolating candidate upstream causes in high-defect wafers.
7. Scope, design constraints, and interpretive significance
The reported summary characterizes route2vec as “a simple yet effective means” of transforming variable-length, heterogeneous process routes into fixed-size vectors, enabling both accurate defect prediction and principled counterfactual attribution within PTR (Miyaguchi et al., 27 Jul 2025). The simplicity is not incidental. The architecture uses a linear additive update, a fixed logarithmic temporal scaling, and a linear projection head. These choices constrain expressivity relative to generic deep sequence models, but they align with the paper’s stated concerns about small sample sizes, numerical stability, and the need for meaningful prefix embeddings.
Several boundaries of the reported method are explicit. Route2vec, as evaluated, depends on proc2vec embeddings computed from a custom string-kernel and kernel-MDS procedure; the route2vec cell itself is frozen during experiments; and the downstream predictor is linear with 7 regularization. The method is therefore best understood as a structured representation-and-regression pipeline rather than an end-to-end sequence learner. A common misconception would be to read route2vec as a generic embedding model applicable without this surrounding scaffold. In the reported formulation, its meaning is tightly coupled to PTR, proc2vec, prefix augmentation, and counterfactual attribution.
Within that scope, route2vec addresses a specific technical problem: representing wafer processing histories whose lengths vary and whose semantics depend jointly on process identity and elapsed waiting time. The paper’s formulation suggests that the principal contribution of route2vec is not architectural novelty in the broad RNN literature, but the construction of a route-level representation that remains compatible with additive causal attribution over partial trajectories in semiconductor manufacturing data (Miyaguchi et al., 27 Jul 2025).