Skip to content

Multi-round synthesis connectivity crashes when mol_index leaves spectator atoms #15

Description

@njzjz-bot

Summary

Synthesis target construction explicitly supports mol_index that covers only a subset of the system, but multi-round connectivity handling crashes when an unselected spectator is close enough to a selected atom.

Reproduction

A three-hydrogen system with mol_index=((0,), (1,)), atom 2 as a nearby spectator, and Para(max_step=0) fails during initial connectivity construction:

KeyError: 2

detect_intermolecular_bonds() iterates over all atoms and can create a bond containing the spectator. _build_connectivity() creates its union-find parent map only from atoms listed in mol_index, then attempts to union the spectator index.

Relevant code is in rtipmd/jax/src/rtip_jax/workflows/md.py around lines 591-630.

Impact

A supported synthesis subset with environment or spectator atoms can crash before the first MD round.

Expected behavior

Either limit inter-molecular bond detection to selected atoms or explicitly model spectators in the connectivity graph. Add a regression test with a non-selected nearby atom.

Coding agent: Codex
Codex version: codex-cli 0.149.0
Model: gpt-5.6-sol
Reasoning effort: xhigh

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions