agentleFS
topprismdatatopprismdata/cultivating-ml-agent/skills/examples/code-competition-artifact-pipeline/SKILL.md

code-competition-artifact-pipeline

Skill5 starsChanged 35 days agoMITView on GitHub

Use when: (1) Entering a Kaggle Code Competition that requires notebooks with no internet access, (2) Need to fork a public baseline that depends on external artifact datasets (pre-trained models, feature matrices, wheels), (3) Your fork fails with "module not found" or "file not found" errors, (4) Need to identify and attach the correct Kaggle datasets as notebook inputs. Key lessons: search kaggle datasets list for artifact bundles, check kernel-metadata.json dataset_sources field, the notebook's find_artifacts() function reveals expected paths. Validated on ROGII (7159→Pipeline A), Biohub (LB810 fork), NeuroGolf (7228 fork).

The file

We split this skill into the rules it gives an agent

2 rules. About 0 are common, 2 are distinctive, and 0 are very specific to this project.

  • ≈0

    Common · estimate

    Many files like this have a rule of this kind.

  • ≈2

    Distinctive · estimate

    This author's own choices. Worth a look.

  • 0

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  1. Distinctive:

    Look for high-download datasets (500+ downloads = canonical bundle).

    line 54
  2. Distinctive:

    If the notebook has multiple pipelines (A/B) and one crashes:

    line 78

≈ “Common” is an estimate: at least 1 in 5 of the 350,495 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
SKILL.md

Code Competition Artifact Pipeline

Problem

Kaggle Code Competitions (no internet, notebook-only submission) often have community baselines that depend on external artifact datasets:

  • Pre-trained model weights (pickle/onnx)
  • Feature matrices (CSV/numpy)
  • Custom library wheels (.whl)

Forking these baselines fails unless you identify and attach ALL required datasets. The error messages are often cryptic ("file not found", "module not found").

Solution

Step 1: Read the Notebook's find_artifacts() Function

Most community baselines have a find_artifacts() or similar function that searches /kaggle/input/ for specific directory structures:

def find_artifacts():
    candidates = [
        "/kaggle/input/datasets/author/artifact-name",
        "/kaggle/input/artifact-name",
    ]
    # ... searches for repo/, weights/, wheels/, data/train.csv

This reveals: exact dataset names, expected file structure, and required Python packages.

Step 2: Search for Artifact Datasets

kaggle datasets list --search "competition-name artifacts"
kaggle datasets list --search "author-name"

Look for high-download datasets (500+ downloads = canonical bundle).

Step 3: Attach ALL Required Datasets

In kernel-metadata.json:

{
  "dataset_sources": [
    "author/competition-artifacts",
    "author/library-wheel"
  ]
}

Common missing datasets (from real failures):

CompetitionMissing DatasetError
ROGIIravaghi/wellbore-geology-prediction-artifacts"data/train.csv not found"
ROGIIphongnguyn23021656/koolbox-offline"No module named 'koolbox'"
Biohubthibautgoldsborough/cellmot-baseline-artifacts"repo/ not found"
NeuroGolf(embedded in notebook, no external needed)—

Step 4: Pipeline-Trim for Crashing Components

If the notebook has multiple pipelines (A/B) and one crashes:

  • Pipeline A succeeds but Pipeline B errors → kernel ERROR → no submission scored
  • Fix: delete Pipeline B cells, keep only Pipeline A + final submission write
  • Alternative: wrap Pipeline B in try/except

ROGII case study: Pipeline A (OOF RMSE 10.38) succeeded but Pipeline B (lik-PF) crashed. Trimming Pipeline B cells made the kernel COMPLETE, allowing the submission to be scored.

Step 5: CPU vs GPU Mode

  • CPU kernels: no GPU quota cost, but slower (inference-only mode for some notebooks)
  • GPU kernels: faster, but 30h/week quota limit shared across all competitions
  • Some notebooks REQUIRE GPU (e.g., Biohub UNet, ARC-AGI Duck harness)

Anti-Patterns

Anti-PatternFix
Fork without reading find_artifacts()Read the function to find dataset names
Attach only 1 dataset when 2+ neededCheck ALL import/glob patterns
Submit ERROR kernel expecting partial scoreCode competitions don't score ERRORs
Keep crashing Pipeline B cellsDelete them or wrap in try/except

Download now (ZIP)

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

No reviews yet

People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.

  • It worked
  • Partly
  • It didn't
What did you use it for? e.g. Reviewing pull requests in a Rails app

Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.