/fusion:smashfrom fusion
Drives SMASH, a hadronic transport solver for the relativistic Boltzmann equation. Handles heavy-ion collisions, thermal boxes, expanding spheres, and particle-list replay. Produces OSCAR/binary output for multiplicities, spectra, flow, dilepton and photon rates.
Ships in fusion. Installing the plugin adds it to Claude Code.
What the skill costs in Claude's context, stage by stage
Name and description: Claude knows it exists.
SKILL.md joins the conversation and stays.
Read when SKILL.md points to them; scripts run unread.
SMASH solves the relativistic Boltzmann equation for hadrons: it propagates particles, samples their collisions and decays, and writes the resulting particle lists. It is used both as a standalone transport model at low and intermediate beam energies and as the hadronic afterburner behind a hydrodynamic stage at collider energies.
C++17, CMake. Needs GSL, Eigen 3.x, and Pythia exactly 8.316.
-1 every shipped configuration carries: --seed -2 produced two
different runs whose config_used.yaml still read -2. run_smash.sh
refuses every negative seed unless you pass --allow-random-seed. With a pinned seed the output is byte-identical between
two runs of the same build.scripts/check_conservation_smash.py.
They are a limited invariant, not proof that the physics is right.potentials.cc and random.cc seed themselves from std::random_device
and then assert statistical quantities), so verify_smash.sh retries exactly
those two by name, once, and treats every other failure as fatal. Do not
widen that into "allow one failure". Two further files self-seed through
generate_63bit_seed() and have not been seen to flake, so this skill does
not claim the remaining cases are deterministic..tgz; Eigen 5 makes SMASH report "at least version 3.0 is required" when the
problem is that your Eigen is too NEW. Read references/failure-modes.md
before debugging a build by hand.WARN Fpe : Failed to setup trap on pole error. is harmless and appears
on every macOS run. Never grep logs case-insensitively for "error"; match
SMASH's severity field.scripts/install_smash.sh fetches and builds everything, then prints:
SMASH=<executable>
SMASH_ROOT=<repository root>
SMASH_BUILD=<build dir, where ctest runs>
SMASH_EIGEN3_ROOT=<Eigen 3.4 prefix>
SMASH_GSL_PREFIX=<GSL prefix>
SMASH_PYTHIA_PREFIX=<Pythia prefix>
The last three matter beyond the build: the usage_of_SMASH_as_library test
spawns a fresh cmake that inherits no cache variables, so those prefixes must
reach it through the environment. verify_smash.sh does that for you.
First run takes roughly 20 minutes, almost all of it compiling Pythia and SMASH,
and is cached afterwards. Needs git, cmake 3.16+, a C++17 compiler, curl
and python3. Overrides: SMASH_ROOT_DIR, SMASH_PIN, SMASH_JOBS,
SMASH_GSL_PREFIX, SMASH_PYTHIA_URL, SMASH_EIGEN_VERSION.
scripts/run_smash.sh --config <config.yaml> --outdir /tmp/run1 \
--seed 20260723 --nevents 2 --end-time 20.0
Prints RESULT_DIR= and RESULT_OSCAR=. It copies the configuration it actually
used into the output directory, then asserts a zero exit, an OSCAR2013 header,
records with the column count that header declares, a well-formed block grammar
whose completed (event, ensemble) count equals Nevents x Ensembles (a run can
stop early and still exit 0), no non-finite value, and no ERROR-severity log
line. The grammar itself lives in scripts/check_conservation_smash.py, which
run_smash.sh calls with --structure-only; it handles all three Only_Final
shapes, including the in block and the several out blocks that
Only_Final: No writes inside one event.
A configuration that requests only non-OSCAR output (Binary, Root, HepMC,
YODA, ...) is accepted rather than failed for a missing particle_lists.oscar;
the wrapper then states plainly that nothing was structurally validated.
It also stages a shipped example's own particles.txt and decaymodes.txt when
they sit beside the configuration. SMASH does NOT pick those up implicitly, so
without -p/-d the box, multi_particle_box and photons examples run against the
default tables and quietly compute something other than the example you asked
for. input/sphere/ ships no tables at all, and input/stochastic_box/ ships
tables under non-standard names that auto-staging cannot find: see
references/input-format.md for which example ships what.
scripts/verify_smash.sh # test suite + seeded anchor, about 8 min
scripts/verify_smash.sh --tests-only
scripts/selftest_smash.sh # harness only, 103 cases, seconds, no build needed
A clean run ends in VERIFY OK. If the expected test count was overridden with
SMASH_EXPECTED_TESTS, it ends in VERIFY PASSED-NOT-CERTIFIED instead, which
is deliberately not a superstring of VERIFY OK: the run passed, but it did not
certify the pinned SMASH-3.3 release at tier 1. Evidence, measurements and what
two adversarial passes found: references/verification.md.
Field reference taken from the source: references/input-format.md. The shape:
General:
Modus: Collider # or Box, Sphere, List, ListBox
Delta_Time: 0.1
End_Time: 200.0
Randomseed: 20260723 # PIN THIS
Nevents: 1
Output:
Particles:
Format: ["Oscar2013"]
Modi:
Collider:
Projectile: {Particles: {2212: 79, 2112: 118}} # Au197
Target: {Particles: {2212: 79, 2112: 118}}
E_Kin: 1.23 # GeV per nucleon
Nuclei are given as PDG-code counts, so the expected baryon number and charge of the whole run follow directly from them, which is what makes the conservation anchor possible.
references/output-format.md. particle_lists.oscar has twelve columns named on
its first line (parse that line, it changes with the requested content), events
delimited by # event N ensemble E out COUNT and
# event N ensemble E end .... The ensemble field is part of the real grammar;
a pattern written without it matches nothing.
| stage | what | result |
|---|---|---|
| test suite | SMASH's own 104 ctest cases | reproduced; 104/104 first attempt on Linux, with the two self-seeded cases retried once when they flake |
| anchor | seeded Au+Au, 2 events, E_kin 1.23 GeV/nucleon, 20 fm/c | baryon number 788 and charge 316, EXACT per event (394 and 158 each) |
The anchor's multiplicities (450 n, 336 p, 76 pi-, 65 pi0, 57 pi+, plus eta, K0,
Lambda, Sigma-) are recorded in references/verification.md as a same-build
reproducibility check only, never as a cross-platform reference.
references/failure-modes.md, nine of them, starting with the dead Pythia URL
and the Eigen 5 message that says the opposite of the truth.
AGENTS.md (opens in a new tab)examples/README.md (opens in a new tab)references/failure-modes.md (opens in a new tab)references/input-format.md (opens in a new tab)references/output-format.md (opens in a new tab)references/verification.md (opens in a new tab)scripts/check_conservation_smash.py (opens in a new tab)scripts/install_smash.sh (opens in a new tab)scripts/run_smash.sh (opens in a new tab)scripts/selftest_smash.sh (opens in a new tab)scripts/verify_smash.sh (opens in a new tab)What SKILL.md sets; muted values are Claude Code's defaults
Three short reads, in order
npx claudepluginhub jinleiphys/fusion --plugin fusion29 skills in this plugin
/azure2Drive AZURE2, the Notre Dame multichannel R-matrix code of Azuma et al. (Phys. Rev. C 81, 045805 (2010); GPL-3.0). Write, run and verify .azr configuration files for low-energy charged-particle reactions in nuclear astrophysics: radiative capture, elastic scattering, resonance and subthreshold contributions, external (direct) capture normalised by ANCs, S-factor extrapolation to stellar energies, and reaction rates. Use for 跑AZURE2, AZURE2 input, .azr, R-matrix, R矩阵, 天体物理S因子, astrophysical S factor, direct capture, external capture, ANC, 渐近归一化系数, subthreshold state, CNO cycle capture, resonance analysis./bandBayesian uncertainty quantification for nuclear physics with the BAND framework (Bayesian Analysis of Nuclear Dynamics, bandframework v1.0.0): calibrate a model's parameters against data with surmise, build a fast reduced-basis emulator of nucleon-nucleus elastic scattering with rose, and combine several models' predictions with Bayesian model mixing in Taweret; also routes to the other BAND tools (jitr, Bfrescox, OpenBT, parMOO, PUQ, pybmc, LCGP, mooGP, Smooth Emulator). Use for Bayesian calibration, 贝叶斯校准, 参数后验, posterior, MCMC, emulator, 仿真器, surrogate model, Gaussian process emulator, reduced basis, reduced-order model, ROSE, optical potential calibration, 光学势不确定度, uncertainty quantification, UQ, 不确定度量化, model mixing, 模型混合, Bayesian model averaging, BMM, Taweret, surmise, BAND framework, experimental design. For running FRESCO itself use the `fresco` skill; for fitting a FRESCO deck by chi-squared use `sfresco`./ccfullDrive CCFULL, the all-order coupled-channels code for near-barrier heavy-ion fusion (K. Hagino, N. Rowley, A.T. Kruppa, CPC 123 (1999) 143). Write, run, and verify CCFULL input for fusion excitation functions, barrier distributions, and mean angular momenta with vibrational or rotational couplings and pair transfer. Use for 跑ccfull, CCFULL input, heavy-ion fusion, near-barrier fusion, coupled-channels fusion, fusion excitation function, barrier distribution, 熔合截面./cgmfDrive CGMF, the LANL fission-fragment de-excitation Monte Carlo code of Talou, Stetcu, Jaffke, Rising, Lovell and Kawano (Comput. Phys. Commun. 269, 108087 (2021); BSD-3-Clause). Run and analyse event-by-event simulations of prompt fission neutrons and gammas emitted by excited fission fragments, for spontaneous fission (Cf-252/254, Pu-238/240/242/244) and neutron-induced fission (U-233/234/235/238, Np-237, Pu-239/241) from thermal to 20 MeV: average and distributional neutron and gamma multiplicities, spectra, fragment mass/charge/TKE yields, and n-gamma correlations. Use for 跑CGMF, CGMF input, 裂变, fission, prompt fission neutrons, PFNS, prompt fission gammas, nu-bar, 中子多重性, neutron multiplicity, fission fragment yields, Hauser-Feshbach fission, 252Cf spontaneous fission, event-by-event fission./cnokDrive CNOK, the C++ Glauber-model single-nucleon knockout code of Y.Z. Sun and S.T. Wang (Comput. Phys. Commun. 288, 108726 (2023); GPL-3.0, gitee.com/asiarabbit/cnok). Compute single-particle removal cross sections (stripping + diffractive dissociation) and parallel (longitudinal) momentum distributions of the heavy residue (core) in one-nucleon knockout from intermediate-energy (30 MeV/u to 2 GeV/u) stable and radioactive beams on a light composite target, via the eikonal/sudden Glauber model with a t-rho-rho optical potential; supports batch mode over valence configurations (C2S-weighted inclusive cross sections and momentum distributions, spectroscopic-factor / quenching studies). Use for 跑CNOK, CNOK input, Glauber, 敲出, knockout, single-nucleon removal, stripping, diffractive dissociation, 动量分布, momentum distribution, sigma_sp, single-particle cross section, spectroscopic factor, 谱因子, C2S, quenching, eikonal, sudden approximation, t-rho-rho, 16C knockout, exotic nuclei knockout, MOMDIS./colossDrive COLOSS, the complex-scaled optical and Coulomb scattering solver (Liu Junzhe, Lei, Ren; CPC 311, 109568, 2025). Write, run, and verify COLOSS input for two-body elastic scattering with local or Perey-Buck nonlocal optical potentials, computing S-matrices and cross sections by complex scaling. Use for 跑coloss, COLOSS input, complex scaling scattering, 复标度散射, bound-state technique scattering, S-matrix from Lagrange-Laguerre basis.Other plugins' skills for the same job