csml-rpi/ai-cfd-scientist/cfd-cross-analyze
Claude Code and agent skill by csml-rpi/ai-cfd-scientist
- community
Checking that the SKILL.md file is still in the repository.
Cross-experiment quantitative analysis. Author Python scripts (numpy + matplotlib + PyVista + pandas) that load every PROCEED case, compute aggregated metrics, and generate the comparison figures the paper needs (Cf overlays vs reference, RMSE bar charts, parametric trends, Δ-field contours). Then run a vision+text interpretation pass over the generated plots. This is the cross-case Python authoring layer cfd-paper consumes — without it, papers end up with only per-case contours.
Install
npx vskill@latest install csml-rpi/ai-cfd-scientist/cfd-cross-analyzeSKILL.md
cfd-cross-analyze
⚠ HARD STOP — read this before any other step
If <out-dir>/checkpoints/analysis_done.json AND <out-dir>/checkpoints/paper_experiment_plan_done.json do not both exist, STOP. The orchestrator chain enters this skill only after cfd-analyze and cfd-paper Stage 0 have completed. Stage 0 may propose additional cases that this skill compares against; running cross-analysis before Stage 0 produces comparison figures on an incomplete case set. Return to Skill cfd-orchestrator (or Skill cfd-skills/cfd-analyze), then come back.
cfd-paper writes the manuscript; cfd-cross-analyze produces the cross-case quantitative evidence the manuscript discusses. This skill mirrors the LangGraph workflow's analysis_agent.run_cross_experiment_data_processing + _interpret_cross_experiment_outputs. The agent (you) authors Python scripts that read every PROCEED case via PyVista or sampled CSVs, computes cross-case metrics, generates publication-quality plots, and interprets them through a vision-LLM pass.
Step 0 — Preflight gate (HARD; slice 14)
Before reading any case or authoring any script:
If rc != 0, STOP. The script requires analysis_done and paper_experiment_plan_done (Stage 0 of cfd-paper) to be on disk first. The Stage-0 plan tells this skill which cases (existing + newly proposed) are in scope — running cross-analysis before Stage 0 means producing comparison figures on a possibly-incomplete case set, exactly the failure mode that produced an H12 "only 1 figure type" gate trip.
Without this skill running, papers produced by cfd-paper will only contain per-case PyVista contours and a metrics table — no Cf-overlay-vs-reference, no RMSE bar charts, no parametric-trend plots, no Δ-field comparisons. Those are exactly the figures that justify a paper's claims.
When to use
After cfd-experiment (the full set of cases for the study) and cfd-analyze (per-case metrics), and before cfd-paper. Required for routes 1, 2, 6 (any route that produces a paper) when:
- The study compares ≥ 2 cases on a shared QoI (sensitivity studies, code-mod baseline-vs-modified, parametric sweeps, OED candidate ranking).
- Reference data exists (DNS / experiment / correlation) AND the topic asks for comparison against it.
- A primary claim of the topic is quantitative ("model X reduces error by N%", "x_r/h matches DNS within Y%").
If none of these apply (single-case demonstration with no comparison QoI), you can skip — but document the skip in the timeline.
Inputs
out-dir(required) — must containcases/case_*/withrun_result.jsonanddecision.json(each case must be PROCEED), plusanalysis.json.- Optional:
<out-dir>/reference_data_manifest.jsonor<out-dir>/<reference_csv>for any reference dataset to overlay against. - Optional:
<out-dir>/selected_mesh_spec.json(so cross-case plots note which mesh level was used). - Optional:
topic(string) — used to decide which cross-case figures matter for THIS paper. If not passed, read from<out-dir>/state.json#topic.
Outputs
All under <out-dir>/cross_experiment_analysis/:
Recipe (primary, agent-driven)
Step 1 — Build the case inventory + deterministic context
For each PROCEED case under cases/case_*/:
- Read
run_result.json(case_solver,wall_time_s,loop_count). - Read
decision.json(must havestatus: PROCEED; cases withRERUNorREVISEare excluded). - Read
<case_dir>/system/controlDictfor application + endTime + writeInterval. - Read
<case_dir>/constant/momentumTransport(orturbulenceProperties) for the active model + coefficients. - Read
<case_dir>/constant/transportProperties(orphysicalProperties) for nu / rho / EOS info. - Read
<case_dir>/0/U,<case_dir>/0/pfor boundary conditions (just the structure, not full data). - Read
<case_dir>/constant/polyMesh/ownersize for cell count.
Persist everything as cross_experiment_analysis/case_context.json (one entry per case). This is the authoritative metadata source for the script.
Step 2 — Normalize case contexts via LLM
For each case context entry, ask the LLM (using cfd_langgraph model) to produce a normalized summary that flags inconsistencies and resolves any ambiguous values (e.g., U_inf might appear in different forms across cases — pick one canonical form per case, with provenance).
Write to cross_experiment_analysis/case_context_normalized.json. The normalized version is non-authoritative — case_context.json remains source-of-truth; the script must cross-check the two.
Step 3 — Decide cross-experiment objectives
System prompt (mirrored from LangGraph analysis_agent.run_cross_experiment_data_processing planner)
User prompt template
Persist response as cross_experiment_analysis/planner_objectives.json. If needs_processing: false AND the topic is genuinely single-case-with-no-comparison, skip to Step 6 with an empty interpretation. Otherwise continue.
Step 4 — Author the cross-experiment Python script
This is the heart of the skill. The agent writes ONE Python script that loads every case and produces all the figures in objectives[]. Use the embedded prompt below verbatim.
System prompt (verbatim from LangGraph analysis_agent.run_cross_experiment_data_processing script-writer)
import matplotlib matplotlib.use("Agg") import matplotlib.pyplot as plt plt.rcParams.update({ "figure.figsize": (8.0, 5.5), "figure.dpi": 180, "savefig.dpi": 180, "savefig.bbox": "tight", "savefig.pad_inches": 0.15, "font.size": 14, "axes.titlesize": 16, "axes.labelsize": 16, "xtick.labelsize": 13, "ytick.labelsize": 13, "legend.fontsize": 12, "legend.frameon": True, "legend.framealpha": 0.92, "axes.grid": True, "grid.alpha": 0.3, "lines.linewidth": 2.0, "lines.markersize": 7, "axes.spines.top": False, "axes.spines.right": False, })
This is the start of the file. Read the full SKILL.md on GitHub.
Security
- Security scanPassed, 95 of 100Pattern checks on the skill's files.
- Model reviewPassed
Quality evaluation
- Task evaluationNot runNo evaluation yet. Run one in Skill Studio.
Source
- SKILL.md in the repositoryCheckingcfd-skills/cfd-cross-analyze/SKILL.md
Popularity
- Repository stars
- 51
- Repository forks
- 6
- 7-day trend score
- 20
Stars and forks are for the whole GitHub repository, not this skill alone. Not refreshed yet.
Works with
Any agent vskill installs to: 56 targets in all. These 39 have a page on this site.
- Claude Code
- Cursor
- GitHub Copilot
- Windsurf
- Codex
- Gemini CLI
- Cline
- Amp
- Roo Code
- Goose
- Continue
- Kilo Code
- Junie
- Trae
- OpenHands
- Qwen Code
- AI Agent
- Tabnine Chat
- Sourcegraph Cody
- Amazon Q
- Firebase Genkit
- Sweep
- Devin
- Phind
- Mentat
- Claude Desktop
- Aider
- GPT Pilot
- Plandex
- bolt.new
- v0
- Replit Agent
- Anse
- TypingMind
- BetterChatGPT
- LibreChat
- Warp AI
- Pieces
- Fig AI
Embed badge
[](https://verified-skill.com/skills/csml-rpi/ai-cfd-scientist/cfd-cross-analyze)