jinzhezenggroup/lammps-deepmd
> 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`).
npx skills add https://github.com/jinzhezenggroup/computational-chemistry-agent-skills --skill lammps-deepmd
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.
uv is installed, preferuvx --from lammps --with deepmd-kit[gpu,torch,lmp] lmp ...
data.system)graph.pb or compressed model)lmp -h output before execution.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:
gpu,torch,lmp extras match the requested runtime pattern from the user.If internet access is unavailable or the user explicitly wants a site-installed binary, ask a concrete question such as:
lmp, lmp_mpi, mpirun -np 8 lmp, or an HPC module command?"Do not invent a binary name or module name.
Ask only for what is missing:
input.lammps.log.lammps, dump trajectories, restart files, and thermodynamic data.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}
variable NSTEPS equal 1000000NSTEPS with value 1000000.run ${NSTEPS} so the run length is easy to modify in one place.variable THERMO_FREQ equal 1000thermo ${THERMO_FREQ}.variable DUMP_FREQ equal 1000variable TEMP equal 300.0units metal is used below, this temperature is interpreted in kelvin.variable TAU_T equal 0.1metal units this is in picoseconds.units metalmetal unit system.boundary p p patom_style atomicatomic atom style, appropriate when atoms have no explicit bonds, angles, or molecular topology in the force field description.neighbor 1.0 bin1.0 in the current distance unit.bin neighbor-building method.read_data data.systemdata.system.mass 1 28.0855, mass 2 15.999Masses section.Not all per-type masses are set.pair_style deepmd graph_compressed.pbgraph_compressed.pb.graph.pb, graph-compress.pb, or another supported exported model.pair_coeff * ** * 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 yzstep: 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}THERMO_FREQ timesteps.dump 1 all custom ${DUMP_FREQ} traj.lammpstrj id type x y z1.all.custom dump format.DUMP_FREQ steps.traj.lammpstrj.id type x y z.velocity all create ${TEMP} 743574TEMP.743574 is the random seed.fix 1 all nvt temp ${TEMP} ${TEMP} ${TAU_T}1 on group all.${TEMP} to ${TEMP}, meaning constant temperature here.${TAU_T} is the thermostat damping constant.timestep 0.0005metal units, 0.0005 means 0.0005 ps = 0.5 fs.run ${NSTEPS}NSTEPS timesteps.Replace the NVT thermostat line with:
fix 1 all nve
Meaning:
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 pressureTAU_P is the barostat damping constantiso applies isotropic pressure control to the simulation boxWhen using NPT, it is often useful to keep vol, lx, ly, and lz in the thermo output.
uvx --from lammps --with deepmd-kit[gpu,torch,lmp] lmp -in input.lammps
uvx --from lammps --with deepmd-kit[gpu,torch,lmp] lmp -h | tee /dev/tty
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.
After a run, report at least:
references/commands-and-workflow.mdTake jinzhezenggroup/lammps-deepmd from the repository into ~/.claude/skills for personal
use, or into .claude/skills inside a project.
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.
The instructions reference uvx.
Without those the skill loads but fails at the first command.