mcpbeat Sign in

Lammps Deepmd Agent Skill

> A tool and knowledge base for running molecular dynamics (MD) simulations in LAMMPS with the DeePMD-kit plugin. It handles input script preparation, ensemble selection (NVE/NVT/NPT), and job execution via `uv` or offline binaries. USE WHEN you need to set up, write, explain, or execute a LAMMPS molecular dynamics simulation using a DeePMD machine learning potential (e.g., `graph.pb`).

3k tokens
context cost
the whole folder, loaded on every use
3
files
instructions only
0
copies elsewhere
how many repositories repackaged it
118
stars on the repo
on the repository, not the skill itself

Install

one command, takes just this skill from the repository
npx skills add https://github.com/jinzhezenggroup/computational-chemistry-agent-skills --skill lammps-deepmd

What comes with it

2 673 bytes besides the instruction
assets/input.nvt.lammps
references/commands-and-workflow.md

The instruction itself

18 sections, as written by the author

LAMMPS + DeePMD-kit

Use this skill when the user wants to run molecular dynamics in LAMMPS with a DeePMD-kit potential, prepare or explain an input.lammps file, or switch between common ensembles such as NVE, NVT, and NPT.

Agent responsibilities

  • Confirm the available execution mode:
  • Online mode: if internet access is available and uv is installed, prefer

uvx --from lammps --with deepmd-kit[gpu,torch,lmp] lmp ...

  • Offline mode: do not guess the executable. Ask the user which LAMMPS command, module, or container should be used.
  • Confirm the minimum simulation inputs:
  • structure/data file (for example data.system)
  • DeePMD model file (for example graph.pb or compressed model)
  • atom type to element mapping, including required per-type masses if the data file does not define them
  • target ensemble (NVE, NVT, NPT, or another explicitly requested setup)
  • temperature, pressure if applicable, timestep, and total number of steps
  • Write the LAMMPS input script yourself instead of asking the user to hand-write it.
  • Keep the example readable and fully explained. If you include an example input script, explain what every command does.
  • When possible, validate command availability against the LAMMPS docs or local lmp -h output before execution.
  • Report clearly which command was run, which files were used, and where outputs were written.

Decide the execution mode

Online mode (preferred when internet access is available)

Use:

uvx --from lammps --with deepmd-kit[gpu,torch,lmp] lmp -in input.lammps

If you need to inspect the local command-line help:

uvx --from lammps --with deepmd-kit[gpu,torch,lmp] lmp -h | tee /dev/tty

Notes:

  • This is the preferred path because it can provision LAMMPS and DeePMD-kit on demand.
  • The gpu,torch,lmp extras match the requested runtime pattern from the user.
  • If the environment is slow or the packages are large, warn the user that the first run may take time.

Offline mode

If internet access is unavailable or the user explicitly wants a site-installed binary, ask a concrete question such as:

  • "Which LAMMPS executable should I use, for example lmp, lmp_mpi, mpirun -np 8 lmp, or an HPC module command?"
  • "Do you already have a DeePMD-enabled LAMMPS build on this machine or cluster?"

Do not invent a binary name or module name.

Minimal information to collect

Ask only for what is missing:

  • DeePMD model path
  • LAMMPS data file path
  • ensemble
  • target temperature
  • target pressure if using NPT
  • timestep
  • run length in steps
  • whether velocities should be generated from scratch
  • preferred execution command if offline
  • Inspect available files in the working directory.
  • Draft input.lammps.
  • Explain the script to the user if they asked for an explanation or if the script is nontrivial.
  • Run a short smoke test first when reasonable.
  • Run the full simulation.
  • Summarize outputs such as log.lammps, dump trajectories, restart files, and thermodynamic data.

Example: annotated NVT input

The following example is adapted from the user-provided tutorial pattern and slightly generalized. See also assets/input.nvt.lammps.

variable        NSTEPS          equal 1000000
variable        THERMO_FREQ     equal 1000
variable        DUMP_FREQ       equal 1000
variable        TEMP            equal 300.0
variable        TAU_T           equal 0.1

units           metal
boundary        p p p
atom_style      atomic

neighbor        1.0 bin

read_data       data.system
mass            1 28.0855
mass            2 15.999
pair_style      deepmd graph_compressed.pb
pair_coeff      * *

thermo_style    custom step temp pe ke etotal press vol lx ly lz xy xz yz
thermo          ${THERMO_FREQ}
dump            1 all custom ${DUMP_FREQ} traj.lammpstrj id type x y z

velocity        all create ${TEMP} 743574
fix             1 all nvt temp ${TEMP} ${TEMP} ${TAU_T}

timestep        0.0005
run             ${NSTEPS}

What every command means

  • variable NSTEPS equal 1000000
  • Defines a numeric variable called NSTEPS with value 1000000.
  • Used later by run ${NSTEPS} so the run length is easy to modify in one place.
  • variable THERMO_FREQ equal 1000
  • Defines how often LAMMPS prints thermodynamic information.
  • Used by thermo ${THERMO_FREQ}.
  • variable DUMP_FREQ equal 1000
  • Defines how often coordinates are written to the trajectory dump.
  • variable TEMP equal 300.0
  • Sets the target temperature in the current unit system.
  • Because units metal is used below, this temperature is interpreted in kelvin.
  • variable TAU_T equal 0.1
  • Sets the thermostat damping parameter used by the NVT fix.
  • In metal units this is in picoseconds.
  • units metal
  • Selects the LAMMPS metal unit system.
  • This determines the physical meaning of timestep, temperature, pressure, energy, distance, and time.
  • In this unit system, distances are in angstrom, time is in picoseconds, and the timestep should be chosen accordingly.
  • boundary p p p
  • Applies periodic boundary conditions in x, y, and z.
  • Suitable for bulk condensed-phase simulations.
  • atom_style atomic
  • Uses the atomic atom style, appropriate when atoms have no explicit bonds, angles, or molecular topology in the force field description.
  • Common for DeePMD simulations of condensed phases when the structure is provided as atoms in a box.
  • neighbor 1.0 bin
  • Sets the neighbor-list skin distance to 1.0 in the current distance unit.
  • Uses the bin neighbor-building method.
  • Neighbor lists help LAMMPS efficiently find nearby atoms for force evaluation.
  • read_data data.system
  • Reads the initial atomic structure, atom types, simulation box, and related information from the LAMMPS data file data.system.
  • Replace this filename with the actual user file.
  • mass 1 28.0855, mass 2 15.999
  • Defines per-type atomic masses when the data file does not contain a Masses section.
  • These example values correspond to a two-type Si/O mapping; adjust them to the actual atom type to element mapping. LAMMPS velocity creation and thermostats require masses; without them, runs can fail with Not all per-type masses are set.
  • pair_style deepmd graph_compressed.pb
  • Selects the DeePMD pair style.
  • Loads the DeePMD model from graph_compressed.pb.
  • Replace the model filename with the actual model path, for example graph.pb, graph-compress.pb, or another supported exported model.
  • pair_coeff * *
  • Activates the previously selected pair style for all atom types.
  • For DeePMD this often takes the simple form * * because the mapping is embedded in the model workflow rather than through conventional pairwise parameters.
  • thermo_style custom step temp pe ke etotal press vol lx ly lz xy xz yz
  • Chooses exactly which thermodynamic quantities to print.
  • step: timestep index.
  • temp: instantaneous temperature.
  • pe: potential energy.
  • ke: kinetic energy.
  • etotal: total energy.
  • press: pressure.
  • vol: box volume.
  • lx ly lz: box lengths.
  • xy xz yz: triclinic tilt factors, which are harmless to print even for an orthogonal box.
  • thermo ${THERMO_FREQ}
  • Prints the thermo block every THERMO_FREQ timesteps.
  • dump 1 all custom ${DUMP_FREQ} traj.lammpstrj id type x y z
  • Creates dump ID 1.
  • Dumps atoms from group all.
  • Uses the custom dump format.
  • Writes every DUMP_FREQ steps.
  • Saves to traj.lammpstrj.
  • Outputs per-atom columns id type x y z.
  • velocity all create ${TEMP} 743574
  • Assigns random initial velocities to all atoms.
  • The target temperature is TEMP.
  • 743574 is the random seed.
  • Use this when starting a fresh MD trajectory. If restarting from a previous equilibrated state, this command may be unnecessary.
  • fix 1 all nvt temp ${TEMP} ${TEMP} ${TAU_T}
  • Creates fix ID 1 on group all.
  • Applies the Nose-Hoover NVT thermostat.
  • The target temperature is ramped from ${TEMP} to ${TEMP}, meaning constant temperature here.
  • ${TAU_T} is the thermostat damping constant.
  • timestep 0.0005
  • Sets the MD timestep.
  • In metal units, 0.0005 means 0.0005 ps = 0.5 fs.
  • The safe choice depends on the system and model quality.
  • run ${NSTEPS}
  • Runs molecular dynamics for NSTEPS timesteps.

Common ensemble modifications

NVE

Replace the NVT thermostat line with:

fix 1 all nve

Meaning:

  • integrates Newton's equations in the microcanonical ensemble
  • no thermostat or barostat is applied
  • useful for short stability checks or production runs after equilibration

NPT

A typical isotropic NPT alternative is:

variable        PRESS           equal 1.0
variable        TAU_P           equal 1.0
fix             1 all npt temp ${TEMP} ${TEMP} ${TAU_T} iso ${PRESS} ${PRESS} ${TAU_P}

Meaning:

  • PRESS is the target pressure
  • TAU_P is the barostat damping constant
  • iso applies isotropic pressure control to the simulation box
  • this simultaneously thermostats and barostats the system

When using NPT, it is often useful to keep vol, lx, ly, and lz in the thermo output.

Execution templates

Online run

uvx --from lammps --with deepmd-kit[gpu,torch,lmp] lmp -in input.lammps

Online help

uvx --from lammps --with deepmd-kit[gpu,torch,lmp] lmp -h | tee /dev/tty

Offline run

Only after the user specifies the executable, use a command such as one of these exact patterns:

lmp -in input.lammps
mpirun -np 8 lmp_mpi -in input.lammps
srun lmp -in input.lammps

The agent must not choose one of these on its own without user guidance in offline mode.

Output checklist

After a run, report at least:

  • executed command
  • input script path
  • data file path
  • model path
  • main log path
  • trajectory path if any
  • whether the run completed successfully
  • any obvious warnings or errors from the log

References

  • LAMMPS command categories: https://docs.lammps.org/Commands_category.html
  • LAMMPS command index: https://docs.lammps.org/Commands_all.html
  • DeePMD-kit: https://github.com/deepmodeling/deepmd-kit
  • User-provided tutorial reference: https://github.com/tongzhugroup/Chapter13-tutorial/blob/master/input.lammps
  • Detailed notes: references/commands-and-workflow.md

Other skills for the same job

different authors, same section of the catalogue
DOCX
by anthropics
vendor ×16

Comprehensive document creation, editing, and analysis with support for tracked changes, comments, formatting preservation, and text extraction. When Claude needs to work with professional documents (.docx files) for: (1) Creating new documents, (2) Modifying or editing content, (3) Working with tracked changes, (4) Adding comments, or any other document tasks

7k tokens
PDF
by anthropics
vendor ×16

Comprehensive PDF manipulation toolkit for extracting text and tables, creating new PDFs, merging/splitting documents, and handling forms. When Claude needs to fill in a PDF form or programmatically process, generate, or analyze PDF documents at scale.

13k tokens scripts
PPTX
by JayZeeDesign
×15

Presentation creation, editing, and analysis. When Claude needs to work with presentations (.pptx files) for: (1) Creating new presentations, (2) Modifying or editing content, (3) Working with layouts, (4) Adding comments or speaker notes, or any other presentation tasks

308k tokens scripts
Canvas Design
by anthropics
vendor ×13

Create beautiful visual art in .png and .pdf documents using design philosophy. You should use this skill when the user asks to create a poster, piece of art, design, or other static piece. Create original visual designs, never copying existing artists' work to avoid copyright violations.

1388k tokens
PDF
by anthropics
vendor ×10

Use this skill whenever the user wants to do anything with PDF files. This includes reading or extracting text/tables from PDFs, combining or merging multiple PDFs into one, splitting PDFs apart, rotating pages, adding watermarks, creating new PDFs, filling PDF forms, encrypting/decrypting PDFs, extracting images, and OCR on scanned PDFs to make them searchable. If the user mentions a .pdf file or asks to produce one, use this skill.

15k tokens scripts
DOCX
by w95
×6

Use this skill whenever the user wants to create, read, edit, or manipulate Word documents (.docx files). Triggers include: any mention of 'Word doc', 'word document', '.docx', or requests to produce professional documents with formatting like tables of contents, headings, page numbers, or letterheads. Also use when extracting or reorganizing content from .docx files, inserting or replacing images in documents, performing find-and-replace in Word files, working with tracked changes or comments, or converting content into a polished Word document. If the user asks for a 'report', 'memo', 'letter', 'template', or similar deliverable as a Word or .docx file, use this skill. Do NOT use for PDFs, spreadsheets, Google Docs, or general coding tasks unrelated to document generation.

5k tokens
PPTX
by w95
×4

Use this skill any time a .pptx file is involved in any way — as input, output, or both. This includes: creating slide decks, pitch decks, or presentations; reading, parsing, or extracting text from any .pptx file (even if the extracted content will be used elsewhere, like in an email or summary); editing, modifying, or updating existing presentations; combining or splitting slide files; working with templates, layouts, speaker notes, or comments. Trigger whenever the user mentions \"deck,\" \"slides,\" \"presentation,\" or references a .pptx filename, regardless of what they plan to do with the content afterward. If a .pptx file needs to be opened, created, or touched, use this skill.

2k tokens
Obsidian Markdown
by ZhanlinCui
×3

Create and edit Obsidian Flavored Markdown with wikilinks, embeds, callouts, properties, and other Obsidian-specific syntax. Use when working with .md files in Obsidian, or when the user mentions wikilinks, callouts, frontmatter, tags, embeds, or Obsidian notes.

3k tokens

How to use it

Copy the folder

Take jinzhezenggroup/lammps-deepmd from the repository into ~/.claude/skills for personal use, or into .claude/skills inside a project.

Check the name does not clash

The agent identifies a skill by the name field in its header. Two skills with the same name cannot sit side by side — one of them will be ignored.

Install what it needs

The instructions reference uvx. Without those the skill loads but fails at the first command.