This repository was archived by the owner on Mar 10, 2026. It is now read-only.
Conversation
…ntMode, and EngineConfig
…, PlacementMode, and EngineConfig
…e, and EngineConfig structs
…ts and improving error messages
… ScreamTask enum variants
…for configuration settings
…sk, InteractionAnalysisTask, and ScreamTask
…c for molecular system, forcefield, and placement registry
…State for better structure
…d interaction energy
…on and error handling
…ross multiple modules
…tion and streamline rotamer placement
26 tasks
Contributor
There was a problem hiding this comment.
Pull Request Overview
This PR implements a comprehensive molecular modeling engine and significantly refactors the forcefield system. The engine provides a configurable framework for executing sidechain placement and protein design algorithms with performance optimizations including energy caching and optional parallelism. The forcefield refactoring shifts topology and charge parameterization to pre-processing stages and introduces new DREIDING forcefield versions (0.3 and 0.4) with updated parameter sets.
- Implements core engine framework with configuration builders, state management, and algorithmic tasks
- Refactors forcefield system by removing topology/charge files and simplifying runtime parameterization
- Adds new DREIDING 0.3 and 0.4 forcefield parameter files with comprehensive VDW and hydrogen bonding definitions
Reviewed Changes
Copilot reviewed 37 out of 38 changed files in this pull request and generated no comments.
Show a summary per file
| File | Description |
|---|---|
| data/topology/topology.toml | Removes comprehensive amino acid topology definitions (2425 lines) |
| data/forcefield/dreiding-lennard-jones-12-6.toml | Removes original DREIDING LJ parameters |
| data/forcefield/dreiding-buckingham-exp-6.toml | Removes original DREIDING Buckingham parameters |
| data/forcefield/dreiding-0.4-lj-12-6.toml | Adds DREIDING 0.4 LJ parameters with extensive hydrogen bonding definitions |
| data/forcefield/dreiding-0.4-exp-6.toml | Adds DREIDING 0.4 Buckingham parameters with scale factors |
| data/forcefield/dreiding-0.3-lj-12-6.toml | Adds DREIDING 0.3 LJ parameters with detailed atom type definitions |
| data/forcefield/dreiding-0.3-exp-6.toml | Adds DREIDING 0.3 Buckingham parameters with comprehensive coverage |
| data/charges/qeq.csv | Removes QEq charge parameter database (460 entries) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary:
Introduces the core
enginemodule, a comprehensive framework for executing complex molecular modeling algorithms like sidechain placement and protein design. The engine is built around a configurable, stateful, and observable architecture. It includes a flexible configuration system with fluent builders, a state manager for tracking optimal solutions, task-based execution logic for modularity, and performance optimizations such as an Empty Lattice (EL) energy cache and optional parallelism viarayon. This work also refactors theforcefieldmodule, decoupling topology and charge parameterization from the main runtime flow, as these are now handled during the pre-processing of input structures and rotamer libraries.Changes:
Implemented Core Engine Framework:
config.rs: Introduced configuration structs (PlacementConfig,DesignConfig,AnalyzeConfig) with fluent builders for type-safe and ergonomic setup of computational tasks.state.rs: DevelopedOptimizationStateandSolutionstructs. It uses aBinaryHeapto efficiently manage and track the top N solutions during an optimization run.context.rs: Created aContextstruct to centralize access to the system, configuration, and libraries. It includes a robust residue selection resolver that can handle lists, ligand binding sites (using akiddok-d tree for fast spatial lookups), and exclusions.progress.rs: Implemented a callback-basedProgressReporterto provide feedback on long-running operations.error.rs: Defined a comprehensiveEngineErrorenum for structured error handling across the engine.Developed Algorithmic Tasks (
tasks/):el_energy.rs: Implemented the Empty Lattice (EL) energy calculation task to pre-compute and cache the interaction energy of each rotamer with the static protein backbone and environment.doublet_optimization.rs: Implemented a pairwise rotamer optimization task, which is a key component of many sidechain packing algorithms.clash_detection.rs: Provided a task to identify sterically clashing residue pairs based on a user-defined energy threshold.total_energy.rs: Implemented a task to compute the total energy of a given system state by combining cached EL energies and pairwise interaction energies.Created Rotamer Placement Logic (
placement.rs):place_rotamer_on_system, which uses the Kabsch algorithm (via SVD) to perform a rigid-body alignment of a rotamer onto the backbone anchor atoms of a target residue.Refactored Forcefield Parameterization:
Forcefieldstruct andParameterizerby removing topology and charge assignment logic. This responsibility is now shifted to pre-processing steps (e.g., rotamer library loading), making the runtime parameterization focused on applying delta values and VDW properties.Enhanced Performance and Added Dependencies:
rayonunder aparallelfeature flag to enable parallel execution of computationally intensive tasks like EL energy calculation and clash detection.kiddofor efficient k-d tree based nearest-neighbor searches, used in ligand binding site selection.itertoolsfor more complex iteration patterns.Minor Enhancements:
RotamerLibrary: Addedinclude_system_conformationsto allow including the initial sidechain conformation in the set of rotamers to be sampled.EnergyTerm: Introduced a dedicated struct for energy components (vdw,coulomb,hbond) withAddandAddAssignimplementations for cleaner energy arithmetic.