phase: Skill for Claude Code

.claude/skills/add-card-data-pipeline/SKILL.md

add-card-data-pipeline is a skill for Claude Code from phase-rs/phase. It costs 53 tokens per session (3,902 once invoked), scanned A, original, Apache-2.0.

A guide for changing the pipeline that converts raw Magic: The Gathering card data into typed data used by the game's WebAssembly frontend.

In plain words
What is it for?
Use it when adding exported card fields, changing Oracle text parsing, updating card loading, modifying coverage reports, adding synthesis functions, or investigating incorrect card data at runtime.
Why use it?
It helps prevent card rules from being represented incorrectly and requires tests for parser patterns and generated behavior. Magic: The Gathering is a rules-heavy card game.

Skill for Claude Code

Written for Claude Code: installed under .claude/. Also seen: mentions CLAUDE.md.

This is phase-rs/phase's own configuration. It tells Claude Code how to work on phase itself, so it is not a mod to install elsewhere. Copy it as a starting point and replace the rules that are about this project. Everything phase configures →

Reuse

Borrowing it

Nothing to install: this file belongs to phase-rs/phase. Take a copy, put it at the same path in your own repository, and replace the rules that are about this project with yours.

Copy the file
curl -O https://raw.githubusercontent.com/phase-rs/phase/main/.claude/skills/add-card-data-pipeline/SKILL.md
Clone the repo
git clone --depth 1 https://github.com/phase-rs/phase

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 add-card-data-pipeline

README.md
[![agentmods](https://agentmods.dev/badge/skills/phase-rs/phase/add-card-data-pipeline/github.svg)](https://agentmods.dev/skills/phase-rs/phase/add-card-data-pipeline)
Your own site
<a href="https://agentmods.dev/skills/phase-rs/phase/add-card-data-pipeline"><img src="https://agentmods.dev/badge/skills/phase-rs/phase/add-card-data-pipeline/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for add-card-data-pipeline

Your own site · 80×15
<a href="https://agentmods.dev/skills/phase-rs/phase/add-card-data-pipeline"><img src="https://agentmods.dev/badge/skills/phase-rs/phase/add-card-data-pipeline.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 53 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 3,902 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. Third-party audits
  • NVIDIA SkillSpector warn 7 Sept 2026
SkillSpector: 1 finding, up to high

These are SkillSpector’s own severities. On a checked sample its high-severity flags on skills were ~96% false positives — a documented command, a public API, a “never do X” rule — so we show them as a caution to read, not a verdict. Why →

  • high Rogue Agent · line 311
    Skill modifies its own code, configuration, or behavior at runtime. Self-modification enables an agent to escalate privileges, disable safety constraints, or install persistent backdoors.
    Fix: Prevent the skill from modifying its own code, SKILL.md, or configuration files. Treat skill files as read-only at runtime.
How audits are shown
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.00053 $0.03902
Opus 5.5 $0.00021 $0.01561
Sonnet 5.5 $0.00011 $0.00780
Haiku 4.5 $0.00005 $0.00390

Measured 2mo ago against content hash f26ccdf91194, method: parsed. Prices are Anthropic first-party input rates as of 2026-10-07, from the pricing page.

Security

Grade A, and why

add-card-data-pipeline 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 2mo 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/add-card-data-pipeline/SKILL.md · 313 lines

How it starts

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

Card Data Pipeline

Hard rules — all pipeline work must respect these (see CLAUDE.md § Design Principles):

  1. CR-correctness is non-negotiable. The pipeline is the bridge between Oracle text and engine types. Parser output must faithfully represent the Comprehensive Rules semantics of each card. If a synthesis function or parser pattern produces an incorrect typed representation, the engine will enforce wrong rules. Verify every new pattern against the relevant CR section and annotate the code.
  2. Build for the class, not the card. Every parser pattern, synthesis function, and export field must handle a category of cards. A synthesis function that works for one card but mishandles the next card with the same keyword pattern is a defect. Test with multiple representative cards from the class.
  3. Test the building block. Every new parser pattern needs a unit test. Every new synthesis function needs a test verifying its output. Run cargo coverage after changes to verify coverage improvements. Run cargo insta review if snapshot tests are affected.

The card data pipeline converts raw MTGJSON card data into the typed card-data.json consumed by the WASM frontend and multiplayer server. Understanding this pipeline is essential when adding new ability types, fields, or synthesis steps — a change to the export format must propagate through all loading paths.

Before you start: Run the pipeline end-to-end once to see what it produces: cargo run --release --bin oracle-gen -- data --stats > /tmp/test-export.json 2>/tmp/stats.txt && head -1 /tmp/stats.txt

CR Verification Rule: Every CR number in annotations MUST be verified by grepping docs/MagicCompRules.txt before writing. Do NOT rely on memory — 701.x and 702.x numbers are arbitrary sequential assignments that LLMs consistently hallucinate. Run grep -n "^701.21" docs/MagicCompRules.txt (etc.) for every number. If you cannot find it, do not write the annotation.


Pipeline Flow

Read the full file on GitHub · 313 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. 2mo ago First seen · 313 lines · 53 tokens per session scan A f26ccdf91194

Subscribe to this mod's changes

add-card-data-pipeline is a skill published in the GitHub repository phase-rs/phase (312 stars, last pushed today), licensed Apache-2.0. It adds 53 tokens to every session and 3,902 once invoked, about $0.0002 per session on Opus 5.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

testing-rules

Testing standards — frameworks, the testable-logic trigger, golden/snapshot rules, mocking rules, and the test-author → testing-reviewer pipeline. Load for /add-tests and any change that touches testable logic.

saeedkolivand/ai-job-hunter-app · 48 tokens

author-contract

Shared write-side contract every domain AUTHOR imports — smallest-diff implementation, ground-first, validation gates, tests-are-blocking, and never-approve-your-own-work. The write-side mirror of token-efficiency. Load at the start of any implementation task.

saeedkolivand/ai-job-hunter-app · 55 tokens

performance-checklist

Performance review checklist — hot paths, async-runtime discipline, streaming, query-client tuning, layout pre-measurement, token/cost. Load when reviewing perf-sensitive changes.

saeedkolivand/ai-job-hunter-app · 38 tokens

coding-standards

General repo rules enforced by ESLint/TypeScript/CI — PRs-only, never bypass lint, import ordering, type imports, path privacy, commit format. Load for any code change.

saeedkolivand/ai-job-hunter-app · 44 tokens

systematic-debugging

4-phase systematic debugging methodology with root cause analysis and evidence-based verification. Use when debugging complex issues.

DDS-Solutions/AI-TadPole-OS · 25 tokens

verify-changes

Prove code works by running it, not just checking it exists. Verification through execution rather than inspection. Use after writing or modifying code to ensure it actually functions correctly.

DDS-Solutions/AI-TadPole-OS · 38 tokens