nvalchemi-dynamics-hooks

nvalchemi-dynamics-hooks is a skill for Claude Code from NVIDIA/nvalchemi-toolkit. It costs 69 tokens per session (3,087 once invoked), scanned A, original, Apache-2.0.

A callback system for simulation workflows that runs custom code at chosen points during each step and can inspect or change the current simulation data.

In plain words
What is it for?
Use it to rebuild neighbor lists, check convergence, stop on errors, record trajectories, monitor energy or forces, time stages, and add custom per-step actions.
Why use it?
It lets you add monitoring, stopping rules, logging, snapshots, temperature control, or other step-by-step behavior without changing the simulation engine.

Skill for Claude Code ✓ vendor

Written for Claude Code: installed under .claude/.

Good fit Use it to rebuild neighbor lists, check convergence, stop on errors, record…

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/nvidia/nvalchemi-toolkit/nvalchemi-dynamics-hooks
About the project

ALCHEMI Toolkit is a Python framework that uses GPUs to run atomic simulations and train machine-learned models for chemistry and materials science. Researchers and developers use it for molecular dynamics, geometry relaxation, and model training across one or multiple GPUs. Its catalogue add-ons guide coding agents in using the toolkit’s APIs and repository conventions.

NVIDIA/nvalchemi-toolkit · 159 stars · on GitHub · nvidia.github.io

Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

Any agent
npx skills add NVIDIA/nvalchemi-toolkit --skill nvalchemi-dynamics-hooks
Clone the repo
git clone --depth 1 https://github.com/NVIDIA/nvalchemi-toolkit

Made for: Claude Code.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for nvalchemi-dynamics-hooks

README.md
[![agentmods](https://agentmods.dev/badge/skills/nvidia/nvalchemi-toolkit/nvalchemi-dynamics-hooks.svg)](https://agentmods.dev/skills/nvidia/nvalchemi-toolkit/nvalchemi-dynamics-hooks)
Your own site
<a href="https://agentmods.dev/skills/nvidia/nvalchemi-toolkit/nvalchemi-dynamics-hooks"><img src="https://agentmods.dev/badge/skills/nvidia/nvalchemi-toolkit/nvalchemi-dynamics-hooks.svg" alt="Measured on agentmods" height="20"></a>
Per session 69 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 3,087 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00069 $0.03087
Opus 5 $0.00034 $0.01543
Sonnet 5 $0.00014 $0.00617
Haiku 4.5 $0.00007 $0.00309

Measured 7d ago against content hash 850829606aaf, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-06, from the pricing page.

Security

Grade A, and why

nvalchemi-dynamics-hooks scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 7d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

.claude/skills/nvalchemi-dynamics-hooks/SKILL.md · 426 lines

How it starts

The opening of the file, as written. The whole thing — 426 lines — stays where its author put it; the contents beside it link to each section on GitHub.

nvalchemi Hooks

Overview

Hooks are callbacks that fire at specific points during each workflow step. They observe or modify batch state without changing the engine itself. The hook system is framework-wide: the same Hook protocol works for dynamics and custom pipelines. Dynamics engines pass DynamicsContext; custom engines can pass HookContext or their own context subclass.

from nvalchemi.hooks import (
    BiasedPotentialHook,
    DynamicsContext,
    Hook,
    HookContext,
    HookRegistryMixin,
    NeighborListHook,
    WrapPeriodicHook,
)
from nvalchemi.dynamics.base import DynamicsStage
from nvalchemi.dynamics.hooks import (
    EnergyDriftMonitorHook,
    LoggingHook,
    MaxForceClampHook,
    NaNDetectorHook,
    SnapshotHook,
    StageTimingHook,
    TorchProfilerHook,
)

Hook protocol

Any object with these attributes satisfies the Hook protocol (runtime-checkable):

class Hook(Protocol):
    frequency: int        # execute every N steps (1 = every step)
    stage: Enum | None    # stage enum value (None for stage-agnostic hooks)

    def __call__(self, ctx: HookContext, stage: Enum) -> None:
        """Called with a context snapshot and the current stage."""
        ...

A hook fires when step_count % hook.frequency == 0 (so all hooks fire at step 0).

HookContext — base snapshot shared by hook-enabled workflows:

@dataclass(kw_only=True)
class HookContext:
    batch: Batch              # current batch (all engines)
    model: BaseModelMixin | None = None
    global_rank: int = 0      # distributed rank
    workflow: Any = None      # back-reference to the engine

DynamicsContext — context passed by dynamics engines:

@dataclass(kw_only=True)
class DynamicsContext(HookContext):
    step_count: int = 0
    converged_mask: torch.Tensor | None = None

Access batch data via ctx.batch and dynamics step info via ctx.step_count.


Execution stages

Dynamics — DynamicsStage

Read the full file on GitHub · 426 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 7d ago First seen · 426 lines · 69 tokens per session scan A 850829606aaf

Subscribe to this mod's changes

nvalchemi-dynamics-hooks is a skill published in the GitHub repository NVIDIA/nvalchemi-toolkit (159 stars, last pushed 3d ago), licensed Apache-2.0. It adds 69 tokens to every session and 3,087 once invoked, about $0.0003 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.

Related

Other skills, from other repositories

instrument-data-to-allotrope

Convert laboratory instrument output files (PDF, CSV, Excel, TXT) to Allotrope Simple Model (ASM) JSON format or flattened 2D CSV. Use this skill when scientists need to standardize instrument data for LIMS systems, data lakes, or downstream analysis. Supports auto-detection of instrument types. Outputs include full…

anthropics/knowledge-work-plugins · 123 tokens

matlab

Build, review, migrate, and safely plan MATLAB or GNU Octave numerical workflows, including arrays, tabular/time data, tests, projects, graphics, MAT files, and explicit Python interoperability.

K-Dense-AI/scientific-agent-skills · 42 tokens

exploratory-data-analysis

Perform bounded, local exploratory analysis of explicitly supported scientific files. Use for redacted CSV/TSV/JSON profiles; optional NumPy, HDF5, FASTA/FASTQ, and basic image metadata inspection; missingness/leakage audits; outlier and transformation sensitivity; and rigorous EDA report scaffolds. Other domain…

K-Dense-AI/scientific-agent-skills · 83 tokens

phylogenetics

Build and analyze phylogenetic trees using MAFFT (multiple alignment), IQ-TREE 2 (maximum likelihood), and FastTree (fast NJ/ML). Visualize with ETE3 or FigTree. For evolutionary analysis, microbial genomics, viral phylodynamics, protein family analysis, and molecular clock studies.

K-Dense-AI/scientific-agent-skills · 68 tokens

research-engineer

An uncompromising Academic Research Engineer. Operates with absolute scientific rigor, objective criticism, and zero flair. Focuses on theoretical correctness, formal verification, and optimal implementation across any required technology.

davila7/claude-code-templates · 43 tokens

mapping-to-snomed

Maps clinical concept spans extracted by OpenMed to SNOMED CT concepts through a USER-SUPPLIED terminology server (the user's own Ontoserver, Snowstorm, or UMLS/UTS), never a bundled vocabulary. Use when the user wants to code findings, disorders, procedures, body structures, or substances to SNOMED CT, run an ECL…

maziyarpanahi/openmed · 205 tokens