Skip to content

feat(polymers): add native and CGSmiles authoring - #83

Open
joelaforet wants to merge 4 commits into
conjugation-engine-refactorfrom
conjugation-engine-refactor-phase-15-cgsmiles-authoring
Open

feat(polymers): add native and CGSmiles authoring#83
joelaforet wants to merge 4 commits into
conjugation-engine-refactorfrom
conjugation-engine-refactor-phase-15-cgsmiles-authoring

Conversation

@joelaforet

Copy link
Copy Markdown
Owner

Summary

  • Add the mBuild -> OpenFF adapter and parity checks for parameterization/chemistry handling.
  • Add native linear methacrylate generation, explicit native fragment assembly, and additive/provided-only charged SDF molecule pools.
  • Add an init-scaffolded 5-cell / 3-edit CGSmiles notebook for offline tree/star/dendrimer authoring, plus docs for using the generated charged SDF/config snippet.
  • Remove the Polymerist/custom .rxn backend path and document migration to native default methacrylate generation, polymers.fragments, the CGSmiles notebook, or polymers.provided_molecules.
  • Expand/pin the build environment for the native polymer authoring stack.

Limitations

  • CGSmiles authoring is limited to tree graphs.
  • Each coarse edge emits one atomistic interfragment record with bond order 1, 1.5, 2, or 3.
  • PIM-style double links and cycles are not supported.

Glycan/protein handoff status

The notebook currently produces a charged SDF and a config snippet. Verified config/API support in this stack covers using that SDF as a free/additive polymer molecule through polymers.provided_molecules / generation_mode: provided. The config-driven conjugation moiety provider still supports attachment.moiety.polymer_recipe and SMILES/residue-name sources, and explicitly rejects attachment.moiety.input_path; therefore automatic glycan attachment from the notebook SDF is not claimed here. Testing the notebook-to-branched-glycan/protein handoff remains the primary manual target for this PR.

Validation

  • Full tests: 2905 passed / 3 skipped.
  • Docs: clean Sphinx build with zero warnings.
  • Notebook/wheel smoke completed.
  • Scientific smoke completed: OpenFF parameters, Packmol, TIP3P, and 1000-step CPU MD.

Fresh-checkout manual test

  1. pixi install -e build
  2. pixi run -e build polyzymd init <project-dir>
  3. pixi run -e build jupyter lab <project-dir>/notebooks/cgsmiles_polymer_scaffold.ipynb
  4. In the notebook, edit the three intended cells for the branched glycan/tree target, generate the charged SDF, and copy the emitted config snippet into the project config for the manual handoff test.

Stacked commits included

  • 976fea5 feat(conjugation): add mBuild OpenFF adapter
  • 15f8337 feat(polymers): add native methacrylate generation
  • aff237c feat(polymers): add native fragments and provided molecules
  • a19e580 feat(polymers): add offline CGSmiles authoring

Add mBuild-to-OpenFF conversion as the canonical chemistry boundary for atomistic polymer fragments, with OpenFF/SDF adapters feeding existing conjugation fragment models.

Add static ACB parity coverage independent of Polymerist runtime, including graph, SMIRNOFF labels, NAGL charges, and OpenMM energy checks.
Preserve unchanged default config routing through bundled native methacrylate generation. Add deterministic random-walk mBuild assembly, OpenFF charging/cache artifacts, and a custom .rxn legacy Polymerist warning.
Add native linear fragment assembly with mBuild Port and force_overlap stitching, plus additive fixed and probabilistic provided charged SDF molecule pools.

Preserve deprecated sdf_directory compatibility with warnings, update templates/docs, and cover behavior with focused tests.
Add the init-scaffolded simple notebook for offline CGSmiles polymer authoring.

Support mBuild/OpenFF export with provided-only mode for generated charged SDFs.

Remove Polymerist-backed generation paths and legacy reaction files.

Pin the authoring stack in the project environments and lockfile.
@review-notebook-app

Copy link
Copy Markdown

Check out this pull request on  ReviewNB

See visual diffs & provide feedback on Jupyter Notebooks.


Powered by ReviewNB

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

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant