01 · A
Problem
A whole-layout output changes dimension with bridge length and pier count. The project reformulates layout as a finite sequence of next-span decisions while removing impossible actions before they reach a solver.
Constrained sequential decisions
A shared bridge-layout model with interpretable cost terms, classical baselines and masked reinforcement-learning solvers for varying bridge lengths.
TL;DR

01 · A
A whole-layout output changes dimension with bridge length and pier count. The project reformulates layout as a finite sequence of next-span decisions while removing impossible actions before they reach a solver.
01 · B
The same domain model is used by Random, cost-aware Greedy, bounded Beam-DP, tabular control and DQN, with offline training paths for HPC/Slurm.
Bridge layout mixes hard exclusion zones with competing, history-dependent costs. Shared constraints and interpretable baselines reveal invalid proposals and make learned policies comparable; they do not certify a bridge design.
Bridge type, length, span catalogue and spatial resolution change the search space.
Rivers, roads and other regions can become absolute exclusions or graded costs.
The full objective is history-dependent, so beam-pruned DP is not a general exact optimum.
Illegal actions must be masked in exploration and Bellman targets.
Problem reformulation
The sequential formulation keeps one stable action vocabulary: choose the next legal span or end the episode.
Output size changes with piers and length
Long fine-grained decision chains
Stable discrete span catalogue
Episode horizon changes, output contract does not
System path
Encode bridge problem, zones, legal spans and decomposed cost
Run Random, Greedy and bounded Beam-DP through one solver contract
Train tabular control and DQN with replay, target network and masks
Load versioned policies and compare on held-out problem directories
Masked decision step
The mask is derived from the current position, remaining length, span catalogue and exclusion zones, and is reused in exploration and Bellman targets.
Problem, current position and full span history
Discrete next spans plus end
Remove exclusions and impossible remainder
Greedy, Beam-DP, tabular RL or DQN
Append span and decompose cost
Key trade-offs
Choosing the next span keeps the action vocabulary stable while bridge length changes only the episode horizon.
Bounded Beam-DP provides an interpretable strong reference; RL explores amortized inference under the same model.
Illegal actions are removed before selection and bootstrap instead of punished after execution.
04 · A
04 · B
01A learned policy is meaningful only against exactly the same constraint and cost definition.
02Fast inference is a trade-off, not evidence of a better or safer bridge layout.
What I can share
I implemented a shared model, solver families, masks, a DQN replay/target-network path and versioned artifacts. The current solver uses DQN rather than Double DQN; I leave out earlier benchmark numbers because their evaluation setup is incomplete.
Public sources