ptcg-bc-large-model-submission

ptcg-bc-large-model-submission is a skill for Claude Code, Codex from topprismdata/cultivating-ml-agent. It costs 207 tokens per session (1,630 once invoked), scanned A, original, MIT.

A validated workflow for submitting a behavioral-cloning Transformer agent to a Pokémon Trading Card Game AI competition. Behavioral cloning trains an agent to copy actions from recorded games, while a checkpoint is a saved version of the trained model.

In plain words
What is it for?
Use it to download Pokémon TCG competition episodes, create training examples, train the BC Large model, select the best checkpoint, and prepare the required submission file.
Why use it?
It addresses the common mistake of submitting an outdated or smaller saved model after training a better one. It also covers downloading daily game datasets and extracting large amounts of training data without using excessive memory.

Skill for Claude CodeCodex

Written for no agent in particular: nothing here depends on one.

Needs its repository: it reads a path above its own folder, which exists only inside the repository. The line is tar -czf ../submission_bc_v7.tar.gz ..

Good fit Use it to download Pokémon TCG competition episodes, create training examples, train the BC Large model, select the best checkpoint, and prepare the required submission file.

Compare 6 skills from other repositories ↓
Install

Getting it into your agent

It runs from inside its repository, so the clone comes first — what it calls does not travel with the file alone.

Clone the repo
git clone --depth 1 https://github.com/topprismdata/cultivating-ml-agent
agentmods
npx agentmods add skills/topprismdata/cultivating-ml-agent/ptcg-bc-large-model-submission

Made for: Claude Code, Codex.

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 ptcg-bc-large-model-submission

README.md
[![agentmods](https://agentmods.dev/badge/skills/topprismdata/cultivating-ml-agent/ptcg-bc-large-model-submission/github.svg)](https://agentmods.dev/skills/topprismdata/cultivating-ml-agent/ptcg-bc-large-model-submission)
Your own site
<a href="https://agentmods.dev/skills/topprismdata/cultivating-ml-agent/ptcg-bc-large-model-submission"><img src="https://agentmods.dev/badge/skills/topprismdata/cultivating-ml-agent/ptcg-bc-large-model-submission/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 ptcg-bc-large-model-submission

Your own site · 80×15
<a href="https://agentmods.dev/skills/topprismdata/cultivating-ml-agent/ptcg-bc-large-model-submission"><img src="https://agentmods.dev/badge/skills/topprismdata/cultivating-ml-agent/ptcg-bc-large-model-submission.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 207 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 1,630 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.
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.00207 $0.01630
Opus 5 $0.00103 $0.00815
Sonnet 5 $0.00041 $0.00326
Haiku 4.5 $0.00021 $0.00163

Measured 12d ago against content hash 9841e32e8a63, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-12, from the pricing page.

Security

Grade A, and why

ptcg-bc-large-model-submission 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 12d 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.

skills/examples/ptcg-bc-large-model-submission/SKILL.md · 138 lines

How it starts

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

Pokémon TCG — BC Large Model Submission Pipeline

The Core Lesson (validated)

The single biggest jump (165 → 600) came from using the right checkpoint. Training produces checkpoints_bc_large/best.pth (66 MB, 16.6M params). Submissions require model_bc.pth (v6 path). Forgetting to copy best.pthsubmission/model_bc.pth is the #1 reason scores stay low after training.

Submission Source LB
v6 stale small-model checkpoint 165.6
v7 checkpoints_bc_large/best.pth 600.0

Pipeline (validated end-to-end)

Step 1: Scale BC data via Kaggle dataset snapshots

Episodes are published daily as kaggle/pokemon-tcg-ai-battle-episodes-YYYY-MM-DD. Each snapshot is ~5000 games (not 200 — that was the pitfall of per-file downloading). Use whole-snapshot download (one zip per day), not per-file:

for date in 2026-06-20 2026-06-22 ...; do
  kaggle datasets download kaggle/pokemon-tcg-ai-battle-episodes-$date -p bc_zips
  unzip bc_zips/...zip -d bc_data/$date
done
# Total: 80K+ games → ~6.4M (state, action) pairs

Step 2: Stream extract to part files (avoids OOM)

extract_bc_data.py must NOT accumulate the full sample list in memory before saving. With 6.4M samples at ~10KB each = 64 GB → instant OOM. Write part files every 50K samples, then del part_data after each:

PART_SIZE = 50_000
for i, rf in enumerate(replay_files):
    samples = extract_from_replay(rf)
    batch.extend(samples)
    if len(batch) >= PART_SIZE:
        torch.save(batch, f"bc_dataset_part_{part_idx}.pt")
        part_idx += 1; batch = []
torch.save({"n_parts": part_idx, "total": total_samples}, "bc_dataset_meta.pt")

Step 3: Stream-sampling training (avoids OOM at load)

train_bc_large.py loading 129 part files → extend() into one list = OOM. Sample per-part to quota (50K / 129 ≈ 400 per part), del part_data after each:

per_part_quota = MAX_SAMPLES // len(part_files)
for pf in part_files:
    part_data = torch.load(pf, weights_only=False)
    if len(part_data) > per_part_quota:
        idx = np.random.choice(len(part_data), per_part_quota, replace=False)
        samples.extend([part_data[j] for j in idx])
    else:
        samples.extend(part_data)
    del part_data  # critical: release memory

Read the full file on GitHub · 138 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. 12d ago First seen · 138 lines · 207 tokens per session scan A 9841e32e8a63

Subscribe to this mod's changes

ptcg-bc-large-model-submission is a skill published in the GitHub repository topprismdata/cultivating-ml-agent (5 stars, last pushed 15d ago), licensed MIT. It adds 207 tokens to every session and 1,630 once invoked, about $0.0010 per session on Opus 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-31.

Related

Other skills, from other repositories

huggingface-hub

Hugging Face Hub CLI (hf) — search, download, and upload models and datasets, manage repos, query datasets with SQL, deploy inference endpoints, manage Spaces and buckets.

braxtonROSE4/zorro-agent · 43 tokens

tensorboard

Visualize training metrics, debug models with histograms, compare experiments, visualize model graphs, and profile performance with TensorBoard - Google's ML visualization toolkit.

davila7/claude-code-templates · 32 tokens

mlflow

Track ML experiments, manage model registry with versioning, deploy models to production, and reproduce experiments with MLflow - framework-agnostic ML lifecycle platform.

davila7/claude-code-templates · 33 tokens

datachain-knowledge

Use whenever datasets, cloud storage buckets, or data pipelines are mentioned — creating, saving, querying, listing, exploring, deleting, or processing data in S3, GCS, Azure Blob, or local storage. Also use when running any script that may create datasets as a side effect. Maintains a knowledge base at dc-knowledge/…

datachain-ai/datachain · 104 tokens

install-openviking-memory

Install and configure the OpenViking long-term memory plugin for OpenClaw via natural conversation. Once installed, the plugin automatically captures facts from chats and recalls relevant context before each reply (auto-capture + auto-recall, cross-session). Covers prerequisites, install through OpenClaw's plugin…

volcengine/OpenViking · 191 tokens

pufferlib

Version-aware guidance for PufferLib reinforcement-learning environments, vectorization, policies, PuffeRL training, evaluation, and safe checkpoint review. Use when adapting Gymnasium/PettingZoo environments to published PufferLib 3.0.0 or working with the redesigned native 4.0 source line.

K-Dense-AI/scientific-agent-skills · 65 tokens