GRXForm: Molecular Optimization & Form Extraction
- GRXForm is a dual-use term that describes both a graph-transformer method for scaffold-conditioned molecule optimization using GRPO and a pipeline for extracting FRA Form 57 data from news.
- In molecular optimization, it employs a decoder-only transformer with hierarchical action decomposition and scaffold-relative reward normalization to effectively reduce variance.
- In the FRA Form 57 application, GRXForm integrates OCR-free form transcription and grouped QA to reliably convert noisy news into structured incident data.
GRXForm denotes two distinct systems in recent arXiv literature. In molecular optimization, GRXForm abbreviates “Group-Relative XForm”, a conditional graph-transformer policy introduced for amortized molecular optimization via Group Relative Policy Optimization (GRPO), with the explicit goal of generating an optimized molecule from an input scaffold in one forward pass and with no inference-time oracle calls (Javaid et al., 12 Feb 2026). In a separate information-extraction context, GRXForm is also used as the name for a “Form 57-from-News” pipeline that populates Highway-Rail Grade Crossing Incident Data (Form 57) from news articles in real time (Lim et al., 27 Dec 2025). The primary technical meaning of the term is therefore context-dependent, and the two usages are unrelated except for the shared label.
1. Terminological scope and disambiguation
Current usage of GRXForm is not unique across domains. One usage belongs to molecular design, where the term expands to Group-Relative XForm and refers to a scaffold-conditioned policy trained with GRPO. Another usage appears in railway incident information extraction, where the same string names a pipeline for populating FRA Form 57 from news. A closely related but distinct molecular model is GraphXForm, the decoder-only graph transformer that serves as the architectural backbone for the molecular GRXForm system (Javaid et al., 12 Feb 2026).
| Usage | Domain | Source |
|---|---|---|
| GRXForm (“Group-Relative XForm”) | Amortized molecular optimization | (Javaid et al., 12 Feb 2026) |
| GRXForm (“Form 57-from-News”) | Railway incident form population from news | (Lim et al., 27 Dec 2025) |
| GraphXForm | Graph transformer for molecular design | (Pirnay et al., 2024) |
The molecular usage is the one for which the name is intrinsic to the method. The railway usage is an explicit project name attached to a pipeline whose paper title is different. This suggests that GRXForm is not yet a semantically stabilized identifier across subfields.
2. Conditional molecular optimization formulation
In the molecular literature, GRXForm is defined by a specific optimization objective: learn a single conditional policy that maps an input scaffold to an optimized molecule , thereby amortizing the search cost over training rather than restarting optimization for every input structure (Javaid et al., 12 Feb 2026). The motivating contrast is with “Instance Optimizers”, which expend significant compute on each new input structure.
The workflow is stated compactly as:
GRXForm operates over partial molecular graphs. The state at step is a partial graph , and actions are decomposed hierarchically into three levels. Level 0 chooses the operation in . Level 1 chooses a target atom . Level 2 chooses a bond order 0. At each level, a validity mask 1 zeroes out choices that would violate valence constraints. The chemical validity guarantee is therefore tied to masked action selection rather than post hoc repair.
This conditional formulation matters empirically because the paper identifies a specific failure mode in prior model-based approaches: high variance arising from the heterogeneous difficulty of distinct starting structures. GRXForm addresses that variance not by changing the molecular state space, but by changing how rewards are normalized during reinforcement learning.
3. Graph-transformer backbone and relation to GraphXForm
GRXForm adopts the decoder-only Graph Transformer from GraphXForm as its policy backbone (Pirnay et al., 2024). The predecessor model, GraphXForm, represents each molecule as a hydrogen-suppressed undirected graph, uses atom and degree embeddings, omits classical positional encoding to preserve permutation equivariance, and injects bond information through additive attention biases. In the original GraphXForm formulation, node 2 is a virtual atom; in GRXForm, a virtual super-node connects to all atoms for global pooling.
For GRXForm, each atom 3 is embedded as
4
where 5 are one-hot indicators recording whether atom 6 was selected in sub-action level 7. The transformer stacks 8 self-attention layers with 9 heads and no positional encodings. Bond types enter attention through learned scalar biases:
0
where 1 is bond order and 2 is the learned bias.
The connection to GraphXForm is architectural and methodological. GraphXForm generates molecules by sequential graph edits, masks invalid actions before renormalization, and reports 100% validity rate by construction (Pirnay et al., 2024). It was pretrained on 3 k ChEMBL molecules and fine-tuned using a procedure combining the deep cross-entropy method and self-improvement learning. GRXForm keeps the graph-editing policy style but replaces that fine-tuning regime with GRPO, shifts the task to scaffold-conditioned amortized optimization, and pre-trains on 4 M ChEMBL35 molecules via teacher-forcing (Javaid et al., 12 Feb 2026).
4. Group Relative Policy Optimization
The defining algorithmic contribution of GRXForm is Group Relative Policy Optimization (GRPO). Standard REINFORCE with a single global baseline is described as suffering from high variance when scaffold difficulty varies. GRPO addresses this by normalizing rewards per scaffold group rather than across the batch (Javaid et al., 12 Feb 2026).
For a batch of 5 scaffolds 6, the policy generates 7 completions 8 for each scaffold 9, using Stochastic Beam Search. If 0, the scaffold-specific mean baseline is
1
and the relative advantage is
2
The policy-gradient estimator is
3
The paper adopts the “Dr. GRPO” variant: it does not divide by group standard deviation, thereby avoiding difficulty bias, and does not normalize by trajectory length, thereby avoiding length bias. It also uses no PPO clipping and no critic network, with one gradient ascent step per batch. The practical training loop is correspondingly direct: sample scaffolds, generate grouped completions by SBS, compute rewards, compute per-scaffold baselines and advantages, accumulate log-probability gradients, and update 4.
The stated effect is variance reduction under heterogeneous scaffold difficulty. The paper’s advantage-variance plot is described as showing that GRPO yields a stable learning signal versus the volatile global baseline. A plausible implication is that scaffold-relative centering is particularly important when objective landscapes differ strongly across starting subgraphs.
5. Hyperparameters, evaluation, and out-of-distribution behavior
The global network settings used in all GRXForm experiments are: latent dimension 512, 5 transformer blocks, 6 heads, Adam 7, weight_decay 8, grad_clip 9, and max atoms per molecule 0 (Javaid et al., 12 Feb 2026). For scaffold-task fine-tuning on Kinase MPO, the paper uses 1 scaffolds + 1 carbon (for de-novo), 2 completions per scaffold (beam width 3), total trajectories per batch 4, up to 500 epochs (5 K oracle calls), and entropy coeff 6.
The principal benchmark is Kinase Scaffold Decoration. The dataset is constructed from ZINC-250k, decomposed into Murcko scaffolds, then split by Butina clustering (Tanimoto < 0.4) so that 500 test scaffolds are topologically disjoint from train. The reward is
7
with 8, and hard success requires
9
Across three splits, GRXForm (ours) attains 0 objective score and 1 success rate, while GraphXForm (amort.) attains 2 and 3, Mol GA (instance) attains 4 and 5, and GenMol (instance) attains 6 and 7 (Javaid et al., 12 Feb 2026).
Ablations further separate conditioning from optimization. GRXForm-DeNovo (uncond.) reaches 8 objective score and 9 success rate, whereas GRXForm-REINFORCE reaches 0 and 1. The GRPO variant is therefore the best-performing version in the reported study. The paper states explicitly that GRXForm achieves 17.8% success when all other amortized policies fail, and that GRXForm-DeNovo (no scaffold conditioning) achieves near zero success, which is presented as evidence that conditioning on the starting subgraph is essential.
Two additional evaluations broaden the scope. In Prodrug Transfer (Few-Shot), GRPO outperforms the global baseline on all five unseen drugs, with a mean of 10.693 versus 8.652 for GRXForm-REINFORCE. In the PMO Benchmark (De Novo, 10 K calls per task), GRXForm attains cumulative AUC 16.433 (2nd), compared with GenMol 17.540 (1st) and SynGBO 16.426 (3rd). The paper also reports an amortization analysis: GRXForm breaks even with Mol GA after 2 scaffolds and with GenMol after 3 scaffolds. This suggests that its main advantage emerges in multi-scaffold campaigns rather than one-off optimization.
6. Separate GRXForm usage in real-time FRA Form 57 population
A separate paper uses GRXForm as the name for a pipeline that populates Highway-Rail Grade Crossing Incident Data (Form 57) from news in real time (Lim et al., 27 Dec 2025). The task setting is unrelated to molecular optimization. The input is a continuous stream of raw news articles, and the output is a fully populated JSON object whose schema exactly mirrors FRA Form 57.
The pipeline has three stages. Form Interpretation (KIE) converts the blank, visually irregular PDF of Form 57 into a JSON schema plus field grouping using an OCR-free VLM. Information Retrieval (Grouped QA) asks one batch prompt per group of related fields and returns field-level answers or “Unknown.” Postprocessing & Output normalizes numeric units, choice-labels, and dates into final JSON. The paper identifies two core challenges: the form is visually irregular and semantically dense, and news is noisy.
The VLM transcription stage uses sample aggregation. If 4 independent JSON transcriptions 5 are generated, then for each field 6 and subfield 7, the system collects 8 and selects the most frequent non-null entry:
9
A validation step then fills remaining blanks, yielding 0. The schema is human-centric in that fields are decomposed into answer places such as checkbox slots, text boxes, and choice lists, rather than treated as undifferentiated key-value pairs.
The grouped QA stage clusters fields by spatial proximity and semantic similarity, including categories such as time + location, highway user, train equipment, casualties, environment, hazardous materials. The paper defines a group score
1
and if 2, with a small threshold, e.g. 3, the system re-asks the group question or falls back to “Unknown” for all fields in the group. This grouping is motivated by ambiguity reduction: related fields asked together allow the model to exploit intra-group context.
The evaluation dataset is built by aligning scraped news with official FRA records. Starting from the FRA official CSV of 4 events since 2000, the authors search news within 5, use four extraction tools—newspaper3k, trafilatura, readability, goose3—and two crawling modes—direct HTTP vs. headless browser—and score candidate article–record pairs using spatio-temporal and casualty features. After manual filtering, the dataset contains 266 matched pairs. From these, 50 pairs are randomly sampled for annotation, and each field 6 is marked “answerable” or “unanswerable” by two annotators, with Cohen’s 7 on a pilot.
On those 50 manually annotated articles, using Gemini 2.5 Flash as QA backend, GRXForm (Ours) reports 8 accuracy and 9 coverage, compared with Baseline 1: 0.52, 0.91, Baseline 2: 0, 1, and Baseline 3: 2, 3. The paper also states that digit fields remain the hardest (4 accuracy). End-to-end latency for one article plus one form is reported as approximately 20 s on a single A100 GPU + 4-vCPU node, with 5 s for VLM form transcription using 6 samples and 7 s for 6–8 grouped QA prompts.
Taken together, this second usage shows that GRXForm can also designate a layout-aware, grouped-QA information-extraction pipeline. It should therefore not be conflated with the molecular Group-Relative XForm method, even though both systems combine structured representations with model-based inference and explicit fallback mechanisms.