Logo: Swmm Experiment Audit

Swmm Experiment Audit

Communautéit
Zhonghao1995
swmm-experiment-audit

Consolidate Agentic SWMM run artifacts into auditable provenance, comparison records, and local Obsidian audit notes. Use after any SWMM build/run/QA attempt, successful or failed, when an agent or CLI workflow needs a traceable record of inputs, commands, artifacts, metrics, QA checks, run-to-run differences, and first-user-friendly Obsidian visualization.

Iwwersiicht

EditeurZhonghao1995
Repositoryagentic-swmm-workflow
Skill-Nummswmm-experiment-audit
Stären
33
Forks
15
Matgeliwwert Dateien
2
LizenzMIT
Linken
  • Instruktiounen am Markdown-Format

    Eng SKILL.md-Datei, déi de Modell bei Bedarf luet, soudatt nëmmen Token ufalen, wann eng Ufro tatsächlech dozou passt.

  • Funktionéiert mat all LLM

    KI-Skills si reng Markdown, keen ubidderspezifesche Code. Dofir funktionéiert dëse Skill mat GPT, Claude, Gemini, Grok oder engem lokale Modell.

  • 2 matgeliwwert Dateien

    Skripten, Virlagen a Referenzen, déi de Modell beim Schaffe liese kann. D'Dateie kënnen nëmme gelies ginn a ginn ni ausgeféiert.

  • Open Source

    Zhonghao1995 huet de Skill op GitHub verëffentlecht. Liest de Quelltext, ier Dir de Skill installéiert.

Installatioun

Installéiert de KI-Skill Swmm Experiment Audit an TypingMind, fir e mat all LLM ze benotzen, oder setzt en an en anere KI-Agent an, deen SKILL.md liest.

1

An TypingMind installéieren

TypingMind installéiert e Skill direkt aus sengem GitHub-Dossier — dobäi gëtt SKILL.md gelies, d'Ressourcedateie gi gebëndelt an d'Resultat gëtt lokal gespäichert.

  1. Maacht d'App op a gitt op Plugins → Skills.
  2. Wielt „Vu GitHub installéieren“.
  3. Pecht d'URL vum Skill-Dossier, déi hei drënner steet, an a bestätegt d'Installatioun.
    https://github.com/Zhonghao1995/agentic-swmm-workflow/tree/main/skills/swmm-experiment-audit
  4. Aktivéiert de Skill an all Chat, an deem Dir e benotze wëllt.
Plugins → Skills → Skill derbäisetzen → Iwwer eng GitHub-URL. Pecht dann d'URL vum Dossier an a klickt op Weider.
2

An engem anere KI-Agent installéieren

All KI-Agent, deen d'Format Agent Skills liest, kann dëse Skill benotzen — kopéiert den Dossier an d'Skill-Verzeechnes vun deem KI-Agent.

Claude Code — .claude/skills
git clone --depth 1 https://github.com/Zhonghao1995/agentic-swmm-workflow.git /tmp/agentic-swmm-workflow
mkdir -p .claude/skills
cp -r /tmp/agentic-swmm-workflow/skills/swmm-experiment-audit .claude/skills/swmm-experiment-audit
Start Claude Code nom Kopéieren nei, fir datt den neie Skill erkannt gëtt.

An TypingMind benotzen

Aktivéiert Swmm Experiment Audit an engem Chat vun TypingMind, an de Modell iwwerhëlt de Rescht. Den Numm an d'Beschreiwung stinn am System-Prompt. Soubal eng Ufro dozou passt, luet de Modell déi komplett Instruktioune selwer — Dir musst de Skill ni manuell opruffen, an et fale keng Token un, bis en tatsächlech benotzt gëtt.

De Modell luet Swmm Experiment Audit automatesch, soubal eng Ufro dozou passt.

Funktionéiert mat all KI-Modell

KI-Skills si reng Markdown-Instruktiounen amplaz vun ubidderspezifeschem Code. Dofir ass Swmm Experiment Audit net un de Modell gebonnen, fir deen de Skill geschriwwe gouf. Installéiert en eemol an TypingMind a benotzt e mat GPT-5, Claude, Gemini, Grok, DeepSeek, Mistral, Llama oder engem lokale Modell, deen Dir selwer bedreift — alles mat Ären eegenen API-Schlësselen.

  • Gëtt nëmme gelueden, wann et néideg ass

    De System-Prompt enthält nëmmen den Numm an d'Beschreiwung. D'Instruktioune gi bei der éischter passender Ufro gelueden, soudatt en onbenotzte Skill näischt kascht.

  • De Modell am lafende Chat wiesselen

    Well de Skill aus Instruktiounen amplaz vu Code besteet, funktionéiert en och no engem Modellwiessel — den nächste Modell liest déi selwecht SKILL.md-Datei.

Skill-Instruktiounen

Dëst ass den Inhalt vu SKILL.md, deen de Modell luet. Liest e virun der Installatioun — e Skill besteet aus Instruktiounen, déi Äre Modell befollegt.

SWMM Experiment Audit

Part of Agentic SWMM — install the project first for the executable toolchain (aiswmm CLI, SWMM solver, MCP servers).

What this skill provides

  • A standard audit layer for Agentic SWMM runs.
  • Consolidation of dispersed manifest.json, QA JSON, logs, metrics, and artifact paths.
  • Machine-readable outputs for reproducibility and review.
  • Obsidian-compatible Markdown notes for human research records.
  • Default local Obsidian export into a clean English audit vault.
  • Automatic update of the Obsidian Experiment Audit Index.
  • Optional run-to-run comparison for baseline/scenario or before/after parser validation.

This skill records what happened. It does not run SWMM, build models, invent missing artifacts, or replace module-level validation.

When to use this skill

Use this skill after any of these events:

  • swmm-end-to-end completes successfully.
  • swmm-end-to-end stops or fails after producing partial artifacts.
  • A user wants an Obsidian-ready experiment note for an existing run directory.
  • A user wants to compare two run directories.
  • A run needs evidence for reproducibility, metric provenance, QA status, or paper claims.

Do not use this skill as a substitute for swmm-runner, swmm-builder, or calibration tools. Run the model first, then audit the run directory.

Output contract

For every audited run, write these files into the run's 09_audit/ directory unless explicit output paths are provided:

  • experiment_provenance.json — machine-readable provenance (immutable).
  • experiment_note.md — human-readable Obsidian digest.
  • model_diagnostics.json — deterministic SWMM screening checks.
  • comparison.json — run-to-run comparison (only when --compare-to is given).

experiment_provenance.json is the machine-readable source for:

  • run identity
  • repo state
  • tool versions
  • command trace
  • input hash records
  • artifact index
  • metrics with source artifacts and source tables
  • QA checks
  • detected warnings and limitations

comparison.json records differences against another run when --compare-to is provided. If no comparison target is provided, it still records that no comparison was requested.

experiment_note.md is Obsidian-compatible Markdown with YAML frontmatter. It should stay readable in GitHub as plain Markdown.

The direct script (audit_run.py) writes a copy of the audit note to the Obsidian vault by default; pass --no-obsidian to suppress it. The canonical CLI (aiswmm audit) does not export to Obsidian by default; pass --obsidian to enable it.

When Obsidian export is active, the note is written into:

text
~/Documents/Agentic-SWMM-Obsidian-Vault/20_Audit_Layer/Experiment_Audits

and the index is updated at:

text
~/Documents/Agentic-SWMM-Obsidian-Vault/20_Audit_Layer/Experiment Audit Index.md

CLI

The canonical CLI is aiswmm audit. It wraps the underlying script with backup of prior audit files, MOC regeneration (runs/INDEX.md), and the M2 audit → memory auto-trigger. The direct script path is also supported and is the primary option for MCP / Mode-0 calls.

Canonical CLI (aiswmm audit)

Obsidian export is opt-in with aiswmm audit — pass --obsidian to copy the note to the default vault. Without --obsidian the note is written only into 09_audit/ inside the run directory.

bash
aiswmm audit --run-dir runs/acceptance/latest

With comparison:

bash
aiswmm audit --run-dir runs/acceptance/codex-check-peakfix \
  --compare-to runs/acceptance/codex-check

With explicit metadata and Obsidian export:

bash
aiswmm audit --run-dir runs/real-todcreek-minimal \
  --case-name "Tod Creek minimal" \
  --workflow-mode "minimal real-data fallback" \
  --objective "Verify real-data SWMM execution and preserve provenance." \
  --obsidian

Skip the M2 memory auto-trigger (useful for acceptance / benchmark runs):

bash
aiswmm audit --run-dir runs/acceptance/latest --no-memory

Run-to-run comparison with the standalone verb:

bash
aiswmm compare --run-a runs/baseline --run-b runs/scenario

Direct script path (python3 scripts/audit_run.py)

Use when calling from MCP or when the full aiswmm install is unavailable. Obsidian export is on by default in the script; disable with --no-obsidian.

Initialize a first-user Obsidian vault:

bash
python3 skills/swmm-experiment-audit/scripts/init_obsidian_vault.py
bash
python3 skills/swmm-experiment-audit/scripts/audit_run.py \
  --run-dir runs/acceptance/latest \
  --no-obsidian

With comparison:

bash
python3 skills/swmm-experiment-audit/scripts/audit_run.py \
  --run-dir runs/acceptance/codex-check-peakfix \
  --compare-to runs/acceptance/codex-check \
  --no-obsidian

With explicit metadata including --case-id (records the case slug in experiment_provenance.json for cross-session memory recall):

bash
python3 skills/swmm-experiment-audit/scripts/audit_run.py \
  --run-dir runs/real-todcreek-minimal \
  --case-id tod-creek \
  --case-name "Tod Creek minimal" \
  --workflow-mode "minimal real-data fallback" \
  --objective "Verify real-data SWMM execution and preserve provenance." \
  --no-obsidian

With an Obsidian vault folder:

bash
python3 skills/swmm-experiment-audit/scripts/audit_run.py \
  --run-dir runs/acceptance/latest \
  --obsidian-dir "/path/to/Obsidian/Agentic SWMM/04_Experiments"

Audit rules

  • Always preserve relative paths when the artifact is inside the repository.
  • Include absolute paths in JSON only when useful for local traceability.
  • Record SHA256 for existing file artifacts when feasible.
  • Record artifact role, producer, and downstream use.
  • Preserve command return codes, stdout paths, stderr paths, and timings when available.
  • Treat failed or partial runs as auditable. Missing artifacts should be recorded as missing, not invented.
  • Keep metrics tied to source artifacts and source tables.
  • For SWMM peak flow, prefer Node Inflow Summary / Maximum Total Inflow.
  • Use Outfall Loading Summary / Max Flow only as fallback for outfalls.
  • Do not extract peak flow from Node Depth Summary; that table reports depth and HGL, not flow.

Relationship to swmm-end-to-end

swmm-end-to-end is the executor and orchestrator.

swmm-experiment-audit is the recorder and auditor.

The agent should run this audit skill after every build/run/QA attempt, even when the workflow stops early or fails. The audit output should reference whatever artifacts exist in the run directory and clearly mark missing or incomplete evidence.

Obsidian support

The generated experiment_note.md is designed for Obsidian:

  • YAML frontmatter
  • stable headings
  • tables for QA, metrics, and artifact index
  • relative paths for vault portability
  • no chat transcript or conversational content

The note is also valid GitHub Markdown, so it can be committed as an example or exported as supplementary evidence if desired.

The default local vault is:

text
~/Documents/Agentic-SWMM-Obsidian-Vault

It is organized for first-time Obsidian use:

text
00_Home/
10_Memory_Layer/
20_Audit_Layer/
30_Evidence_Layer/
40_Skill_Evolution/
90_Templates/

The direct script always writes canonical outputs into the run directory and copies the note to the Obsidian vault unless --no-obsidian is given. The canonical CLI (aiswmm audit) writes canonical outputs only; add --obsidian to also copy to the vault.

In both paths, use --obsidian-dir and --obsidian-index to target a vault location other than the default ~/Documents/Agentic-SWMM-Obsidian-Vault.

Matgeliwwert Dateien

De Modell liest dës Dateie bei Bedarf, wärend de Skill gelueden ass. Si ginn als liesbar Dateie bereetgestallt a ginn ni ausgeféiert.

Heefeg gestallte Froen

Wat mécht de KI-Skill Swmm Experiment Audit?

Consolidate Agentic SWMM run artifacts into auditable provenance, comparison records, and local Obsidian audit notes. Use after any SWMM build/run/QA attempt, successful or failed, when an agent or CLI workflow needs a traceable record of inputs, commands, artifacts, metrics, QA checks, run-to-run differences, and first-user-friendly Obsidian visualization.

Firwat Swmm Experiment Audit op TypingMind benotzen?

Well Dir en eemol installéiert a mat all Modell benotze kënnt. Swmm Experiment Audit besteet aus einfachem Markdown amplaz vun ubidderspezifeschem Code. Dee selwechte Skill funktionéiert also mat GPT-5, Claude, Gemini, Grok oder engem lokale Modell – an Dir kënnt de Modell matzen am Chat wiesselen, ouni datt de Skill ophält ze funktionéieren. TypingMind benotzt Är eegen API-Schlësselen, sou datt Dir d'Ubidder direkt bezuelt, amplaz en Abonnement pro Benotzerplaz ze bezuelen. Är Skills a Chats bleiwen an Ärem eegene Späicher.

Wéi installéieren ech Swmm Experiment Audit an TypingMind?

Maacht an TypingMind Plugins → Skills → Vu GitHub installéieren op a setzt https://github.com/Zhonghao1995/agentic-swmm-workflow/tree/main/skills/swmm-experiment-audit an. TypingMind liest d'Datei SKILL.md, bëndelt déi zougehéiereg Dateien an installéiert dat Ganzt als Skill, deen Dir pro Chat aktivéiere kënnt.

Wéi eng KI-Modeller kënnen Swmm Experiment Audit benotzen?

All Modell, deen Dir an TypingMind verbënnt. KI-Skills sinn einfach Markdown-Instruktiounen an net ubidderspezifesche Code. Dofir kënne GPT, Claude, Gemini, Grok a lokal Modeller dëse Skill lueden, wann eng Ufro dozou passt.

Wéi vill KI-Modeller kann ech mat Swmm Experiment Audit benotzen?

Esou vill wéi Dir wëllt. Soulaang e Modell Skills ënnerstëtzt, kënnt Dir Swmm Experiment Audit domat benotzen – zum Beispill mat GPT, Claude, Gemini, Grok, DeepSeek, Mistral oder Llama – alles op TypingMind mat Ären eegenen API-Schlësselen.

Ass de KI-Skill Swmm Experiment Audit gratis?

Jo. Zhonghao1995 huet de Skill ënner der Lizenz MIT op GitHub publizéiert. Dir bezuelt nëmmen Ären eegene KI-Ubidder fir d'Token, déi Dir benotzt.

Wat si KI-Skills?

E KI-Skill ass e weiderverwendbare Pak vun Instruktiounen, deen engem KI-Modell bäibréngt, wéi en eng bestëmmt Aufgab erfëllt. E follegt dem oppenen Agent Skills-Format: eng Datei SKILL.md mat engem Numm an enger Beschreiwung, plus all Scripten, Virlagen oder Referenzdateien, déi de Modell eventuell brauch. De Modell liest d'Instruktiounen eréischt, wann Är Ufro zum Skill passt. En installéierte Skill kascht also näischt, bis e benotzt gëtt.

Wéi ënnerscheede sech KI-Skills vu Plugins oder MCP-Serveren?

E Plugin oder MCP-Server gëtt engem Modell nei Tools, déi en opruffe kann – Code, deen iergendwou leeft an e Resultat zeréckgëtt. E KI-Skill gëtt dem Modell dogéint Wëssen an eng Virgoensweis: wéi en eng Aufgab ugeet, wéi eng Schrëtt e maache soll a wéi eng gutt Ausgab ausgesäit. Skills bestinn aus einfachem Markdown, brauche kee Server, keen API-Schlëssel a kee Lafzäitëmfeld a funktionéiere mat all Modell.

Alleguer weisen

Elo Ären eegene KI-Aarbechtsberäich ariichten

Abonnéiert Iech op eisen Newsletter, fir iwwer nei Funktiounen an zukünfteg Gewënnspiller informéiert ze ginn 👇