csml-rpi/ai-cfd-scientist/cfd-paper
Claude Code and agent skill by csml-rpi/ai-cfd-scientist
- community
Checking that the SKILL.md file is still in the repository.
Full paper writing in skill mode. ONE skill that walks the agent through a strict numbered protocol: Stage 0 experiment planner, then a planner-viz-writer-compile-reviewer-revise cycle that iterates until the reviewer returns pass=true or the cap is hit. Each phase is one concrete agent action with the LLM prompt embedded verbatim and an immediate schema-validation gate. No script delegation. The agent itself is the planner, the viz author, the vision QA, the writer, the compile-fixer, the reviewer, and the reviser — same as every other skill-based AI scientist.
Install
npx vskill@latest install csml-rpi/ai-cfd-scientist/cfd-paperSKILL.md
cfd-paper
⚠ HARD STOP — read this before any other step
For routes 1, 2, 6: if <out-dir>/checkpoints/analysis_done.json does not exist, STOP. Return to Skill cfd-orchestrator. For route 5 (paper-only): <out-dir>/analysis.json must exist before entry.
How this skill works
This skill is a strict numbered protocol. You walk it step by step. Each step is ONE concrete agent action — either an LLM call (where your next response IS the prompted output), a bash invocation, or a validation gate. Each step ends with a literal GOTO Step N instruction. The cycle loops by GOTO-ing back to an earlier step.
You ARE every LLM in this pipeline. When a step says "your next response must be the planner JSON", that means: read the embedded system prompt, treat it as your operating instructions for that single response, fill in the user-message placeholders from disk, then your literal next message is the planner's JSON output. No meta-commentary. No "I will now run the planner." Just the output.
Forbidden behaviors that triggered past failures (do not repeat any of these):
- Do not write `paper/main.tex` by hand without going through Step 5 (the writer prompt). A hand-written .tex with sections "Objective", "Audit Trail", "Implementation Location" instead of "Introduction / Related Work / Methods / Results / Discussion / Conclusion" is the failure mode this skill exists to prevent.
- Do not write `review.json` with your own schema (e.g.
{pages, min_pages, findings}). The reviewer LLM (which is you, in role) returns a specific schema withrecommendations[],formatting_ok,figures_ok, etc. Without those keys, downstream gates reject it as fabricated. - Do not write `paper_unified_plan.json` with your own schema (e.g.
{title, sections, figures}). The planner (which is you, in role) returns{figure_jobs[], unified_viz_brief, case_order_for_paper, case_display_labels, omit_case_ids, analysis_narrative_hints, topic_paragraph_for_intro}. - Do not write `audit_passed.json` yourself. Only
scripts/stage_gate_audit.pywrites that file. The orchestrator runs the audit at Step 5 of its own protocol. - Do not skip the per-image vision QA in Step 3. You ARE the vision LLM. Open each PNG and judge it.
- Do not skip pdflatex (Step 6). PDF generation is real; the agent doesn't get to declare "compiled".
Library availability
You can import pyvista, matplotlib, numpy, pandas, anything in the conda env. PyVista renders contour fields, slices, streamlines, profiles directly from OpenFOAM case directories — that's what Steps 2 and 3 do. You can write and run Python scripts via Bash; you can read PNGs as images with your native multimodal capability for Step 3's vision QA.
Stage 0 — Paper experiment planner
ONE LLM call. Decides whether the paper needs additional experiments before figure work begins. Run this once, immediately on skill entry.
Step 0.0 — Literature precheck (HARD; H18 enforcement)
The OED + BFS smoke runs both produced unciteable papers because literature retrieval was silently skipped at some point in the chain and the paper stage didn't notice. This step is the gate. Do not proceed past it.
If this check fails, stop the paper stage and re-invoke Skill cfd-skills/cfd-literature first. The audit's H18 / H19 / H10 gates will reject any paper authored on an empty lit.json — there is no value in proceeding.
Step 0.1 — Build the Stage-0 input
Concatenate into one string (≤ 60,000 chars):
If <out-dir>/manifest.json doesn't exist, build it now from cases/case_*/run_result.json + decision.json:
Step 0.2 — Run the Stage-0 LLM call
Your next response after reading this step MUST be the planner JSON output. Use this system prompt as your operating instructions for that single response, fill the user-message placeholders from Step 0.1's input, then emit the JSON.
System prompt (you are the Stage-0 planner)
User message
The string built in Step 0.1.
Step 0.3 — Validate and persist
Write the JSON response to <out-dir>/paper_experiment_plan.json. Then:
If validation fails: redo Step 0.2 (re-emit the JSON with the correct schema). If it passes, write <out-dir>/checkpoints/paper_experiment_plan_done.json with {"stage": "paper_experiment_plan", "ts": "...", "needs_additional_experiments": <bool>} and continue.
Step 0.4 — Branch on Stage 0 verdict
paper_experiment_plan.json#needs_additional_experiments | Next action | |
|---|---|---|
true | For each additional_cases[i], append to requirements.json and invoke Skill cfd-skills/cfd-experiment (chain: experiment → viz → interpret per case). When all proposed cases have decision.json with PROCEED, invoke Skill cfd-skills/cfd-cross-analyze. After cross-analyze returns, GOTO Phase A below. | |
false | Invoke Skill cfd-skills/cfd-cross-analyze. After cross-analyze returns, GOTO Phase A below. |
The cycle — Phases A through F
After Stage 0 + (any additional experiments) + cfd-cross-analyze have produced cross_experiment_analysis/ with comparison figures and cross_experiment_interpretation.md, the paper writing cycle begins. You will execute up to max_review_loops = 10 iterations of the following six-phase cycle:
Initialize the cycle state file before Phase A:
Append {"stage": "paper_review", "event": "cycle_started", "ts": "<iso>"} to <out-dir>/timeline.json.
GOTO Phase A.
Phase A — Planner (one LLM call; iteration 0 only)
Only runs once. If paper_unified_plan.json already exists and passes schema validation, skip Phase A and GOTO Phase B.
A.1 — Build the planner input string
Concatenate (≤ 120,000 chars; trim lowest-citation lit entries first if larger):
A.2 — Run the planner LLM call
Your next response MUST be the planner's JSON output. Nothing else.
System prompt (you are the planner)
This is the start of the file. Read the full SKILL.md on GitHub.
Security
- Security scanPassed, 100 of 100Pattern checks on the skill's files.
- Model reviewNot runA model review is scheduled for the next rescan.
Quality evaluation
- Task evaluationNot runNo evaluation yet. Run one in Skill Studio.
Source
- SKILL.md in the repositoryCheckingcfd-skills/cfd-paper/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-paper)