Skip to content
Agentmart
Submit a tool

mat-lammps-md

Build and run LAMMPS molecular dynamics with isolated MLIP-specific binaries (MACE, MatGL/CHGNet, FairChem) to avoid Python and Torch stack conflicts.

Skill by learningmatter-mit

IndexedMIT★ 183
Write a review

Chalk Labs

Need help deploying mat-lammps-md?

Chalk Labs sets up agents like this inside real teams: connected to your tools, tested on your data, with a human in the loop where it matters.

Book a call

Install

Works with Claude Code, Claude apps, Codex, Cursor, Gemini CLI, GitHub Copilot, VS Code, OpenCode, Goose, Windsurf. Read the repository before you give any tool access to your data.

npx agentmarket install skill/learningmatter-mit-mat-lammps-md

Asks which of your tools to add it to (Claude Code, Codex, Cursor, VS Code, Windsurf, Gemini CLI, Claude Desktop) and shows the change first. See https://agentmart.dev/cli.

Get the weekly diff

The weekly diff: one email a week with new agent tools, notable updates and grade changes, plus security alerts for tools you follow. Double opt-in, one-click unsubscribe.

We use your email only for this newsletter. Privacy

About

Build and run LAMMPS molecular dynamics with isolated MLIP-specific binaries (MACE, MatGL/CHGNet, FairChem) to avoid Python and Torch stack conflicts.

No reviews yet. Installed it? Reviews come from verified installers only. How reviews work

Permissions

What this skill can do and what it asks for, from its SKILL.md and code. Checked Oct 25, 2026.

Tools
No tools found
Secrets
None asked for
Install scripts
None found
Runs as
Python package

Network hosts it talks to 2

  • codeload.github.com · found in install command
  • github.com · found in code

Files it touches

  • ~/.claude/skills/mat-lammps-md

What's inside

Skill name
mat-lammps-md
Description
Build and run LAMMPS molecular dynamics with isolated MLIP-specific binaries (MACE, MatGL/CHGNet, FairChem) to avoid Python and Torch stack conflicts.
License
MIT
Instructions
89 lines in SKILL.md · view on GitHub

Before installing

  • Ships executable scripts

Files (14)

  • SKILL.md
  • README.md · examples/fairchem/
  • in.relax_adsorption_fairchem · examples/fairchem/
  • run_fairchem_co_cu111_adsorption.sh · examples/fairchem/
  • README.md · examples/mace/
  • generate_na2si3o7_structure.py · examples/mace/
  • in.na2si3o7_quench_mace · examples/mace/
  • run_mace_na2si3o7_quench.sh · examples/mace/
  • README.md · examples/matgl/
  • in.cu_phase_transition_matgl · examples/matgl/
  • run_matgl_cu_phase_transition.sh · examples/matgl/
  • build_lammps_mace.sh · scripts/
  • build_lammps_matgl.sh · scripts/
  • README.md · scripts/three-backends-build-check/

SKILL.md (first lines)

# LAMMPS Molecular Dynamics with MLIPs

## Goal
Run GPU-accelerated LAMMPS molecular dynamics with MLIP backends using three isolated binaries (MACE, MatGL/CHGNet, FairChem) so Python embedding through `ML-IAP`/`mliappy` remains stable and reproducible.

## Instructions

1. **Select the MLIP backend and model family first** using the foundation-potential guide:
   - [ml-foundation-potentials](../ml-foundation-potentials/SKILL.md)
   - This determines which environment (`mlip` for MACE and MatGL, `fairchem` for FairChem) and which LAMMPS binary you must use.

2. **Check system prerequisites**.
```bash
nvidia-smi
nvcc --version
g++ --version
cmake --version
mpicxx --version
```

3. **Identify GPU compute capability and set Kokkos arch flag**.
```bash
nvidia-smi --query-gpu=name,compute_cap --format=csv,noheader
```
- Example mapping:
  - `8.0` -> `Kokkos_ARCH_AMPERE80`
  - `8.6` -> `Kokkos_ARCH_AMPERE86`
  - `8.9` -> `Kokkos_ARCH_ADA89`
  - `9.0` -> `Kokkos_ARCH_HOPPER90`
  - `10.0` -> `Kokkos_ARCH_BLACKWELL100`
  - `12.0`, `12.1` (e.g. GB10 / DGX Spark) -> `Kokkos_ARCH_BLACKWELL120` (Kokkos 4.6 has no 12.1 target; it runs, with a performance warning)

4. **Build the environment-matched LAMMPS binary** (choose one of the three paths below). Builds go to `$LAMMPS_ROOT` (default `~/.cache/atomisticskills/lammps`) and need the environment to run natively on the host.

   **Path A: MACE** (ACEsuit's LAMMPS fork with `ML-MACE`, linked against the `mlip` environment's libtorch)
```bash
bash ${CLAUDE_SKILL_DIR}/scripts/build_lammps_mace.sh
```
   - Binary: `~/.cache/atomisticskills/lammps/mace/lmp`
   - Runtime env: `mlip+lammps`
   - Needs a CUDA toolkit (`CUDA_HOME`) at least as new as the environment's torch build (12.6 for cu126, 13.0 for cu130); PyTorch's CMake config refuses an older one.

   **Path B: MatGL/CHGNet** (Kokkos with CUDA, ML-IAP with the Python coupling, embedding the `mlip` environment's Python)
```bash
KOKKOS_ARCH_FLAG=Kokkos_ARCH_AMPERE80 \
bash ${CLAUDE_SKILL_DIR}/scripts/build_lammps_matgl.sh
```
   - Binary: `~/.cache/atomisticskills/lammps/matgl/lmp`
   - Runtime env: `mlip+lammps`
   - `LAMMPS_REF` defaults to `stable_22Jul2025_update4`, whose Kokkos knows current GPU architectures.

   **Path C: FairChem** (no build: the `lammps` extra installs the LAMMPS wheel and `fairchem-lammps`)
```bash
${CLAUDE_SKILL_DIR}/../../venv/run fairchem+lammps lmp_fc --help
```
   - Binaries: `lmp` and `lmp_fc` in the `fairchem+lammps` environment

5. **Run the selected binary in its matching environment**.
```bash
# (example; switch environment/binary pair as needed)
${CLAUDE_SKILL_DIR}/../../venv/run mlip+lammps ~/.cache/atomisticskills/lammps/mace/lmp -h
```

6. **Launch MD with the same binary-environment pair used during build**; do not cross-run binaries between MLIP stacks.

## Examples

See [scripts/three-backends-build-check/README.md](scripts/three-backends-build-check/README.md) for a minimal build/verification matrix across MACE, MatGL, and FairChem.
See the respective README.md files under [examples/mace/](examples/mace/), [examples/matgl/](examples/matgl/), and [examples/fairchem/](examples/fairchem/) for model-specific run scripts.

## Constraints
- **Strict binary-env pairing**: each LAMMPS binary must run only in the environment it was built against (`venv/run mlip+lammps` or `venv/run fairchem+lammps`).
- **No stack mixing**: never run the MACE or MatGL binary in the `fairchem` environment, or `lmp_fc` in `mlip`.
- **GPU arch alignment**: choose `KOKKOS_ARCH_*` from actual `compute_cap` output.
- **Python-coupled mode**: this workflow targets `ML-IAP`/`mliappy` usage.

## References
- Thompson et al., "LAMMPS - A flexible simulation tool for particle-based materials modeling at the atomic, meso, and continuum scales", *Computer Physics Communications*, 2022. [DOI](https://doi.org/10.1016/j.cpc.2021.108171)
- LAMMPS Manual, ML-IAP package documentation. [Link](https://docs.lammps.org/Packages_details.html#pkg-ml-iap)
- Batatia et al., "MACE: Higher Order Equivariant Message Passing Neural Networks for Fast and Accurate Force Fields". [arXiv](https://arxiv.org/abs/2206.07697)
- Deng et al., "CHGNet as a pretrained universal neural network potential for charge-informed atomistic modelling". [arXiv](https://arxiv.org/abs/2302.14231)
- FairChem documentation and model zoo. [Link](https://fair-chem.github.io/)

---

**Author:** Jurģis Ruža
**Contact:** [GitHub @JurgisR](https://github.com/JurgisR)

From learningmatter-mit/AtomisticSkills, MIT.

More from learningmatter-mit/AtomisticSkills

Signals

Stars
183
Forks
31
Open issues
0
Last commit (this folder)
Oct 10, 2026 (20 days ago)
Last release
Oct 6, 2026 (24 days ago)

From GitHub (fetched Oct 24, 2026).

Details

License
MIT
First seen
Oct 24, 2026
Last checked
Oct 24, 2026

More from learningmatter-mit

Done for you

Rather not set it up yourself?

Chalk Labs scopes, builds and runs agents for your team: the task audit, the eval harness, the integrations and the weekly ops report. Fixed scope, priced before we start.

See how we build AI agents →Read the case studies

Chalk Labs is a two-founder AI and growth studio. We build AI agents, CRMs and MVPs for Web3 and AI companies, and have shipped 50+ product and token launches.

launches shipped
50+
launches shipped
media placements
500+
media placements
founders on every account
2
founders on every account

Press we've placed: Forbes · CoinDesk · Decrypt · Cointelegraph · The Block

Rahil Jain, Co-founder, Chalk Labs. Ex-Goldman Sachs engineer. You talk to the person who builds it.

Get mat-lammps-md running in your business

Tell us what you want to automate. A founder replies within one working day with a plan, not a pitch deck.

Goes to the Chalk Labs founders, not the newsletter. Privacy

Need help deploying mat-lammps-md?

CallGet help
Cite this page

mat-lammps-md skill. Agent Mart. https://agentmart.dev/skills/learningmatter-mit-mat-lammps-md (last updated 2026-10-24)