Skip to content
Back to skills

Experiment Tracking

ASecurity

"Add, debug, and validate W&B experiment tracking in Python scripts

  • 247 stars
  • 0 votes
  • 0 copies
  • 1 view
  • Added September 9, 2026
testingpythongobashapi

Works with

  • cli
  • api

Security analysis

A100/100

Pro scans all 5 files and shows the line behind each finding

Scanned September 9, 2026

npx -y skills add VectorSpaceLab/AREX-Skill --skill experiment-tracking --agent claude-code

Installs into .claude/skills of the current project.

Are you the author of Experiment Tracking?

Add the live security badge to your README. It updates with every re-scan.

Security grade badge for Experiment Tracking
[![Security: A — Skills Directory](https://www.skillsdirectory.com/api/skills/vectorspacelab-experiment-tracking-1e2e0b92/badge)](https://www.skillsdirectory.com/skills/vectorspacelab-experiment-tracking-1e2e0b92)

More formats (shields.io, HTML) on the badges page. Keep it an A: scan every change in CI with Pro.

Download with Pro
SKILL.md
---
name: experiment-tracking
description: "Add, debug, and validate W&B experiment tracking in Python scripts
  or notebooks using runs, metrics, config, summary, tables/media/plots,
  offline/disabled modes, and framework-routing decisions."
disable-model-invocation: true
metadata:
  disco-role: operating
license: MIT
---

# Experiment Tracking

Use this sub-skill when a task involves instrumenting Python code with `wandb.init()`, `Run.log()`, run config/summary, custom metric axes, tables/media/plots, notebook run lifecycle, or offline-safe tracking. For artifact lineage, model/dataset registries, and `run.log_artifact()`, route to `../artifacts-and-registries/SKILL.md`; for `wandb sync`, `wandb offline`, and local CLI workflows, route to `../cli-and-local-workflows/SKILL.md`; for hyperparameter sweeps or launch queues, route to `../sweeps-and-launch/SKILL.md`.

## Start Here

- Add W&B to scripts with `with wandb.init(project=..., config=...) as run:` and `run.log({...})`; see `references/workflows.md`.
- Use `mode="offline"` for credentials-free local capture and later syncing; use `mode="disabled"` when tracking must become no-op in tests.
- Keep metric steps monotonic. Prefer logging a custom x-axis metric and binding charts with `run.define_metric()` instead of forcing W&B's internal step to equal training step.
- Put hyperparameters and static inputs in `config`; put final scalar outcomes or derived labels in `run.summary`; put time-series values in `run.log()`.
- Use `scripts/offline_tracking_smoke.py` to verify that a Python environment can initialize a local run, log metrics, define custom axes, log a table, and finish without network or credentials.

## Reference Map

- `references/workflows.md`: copyable instrumentation patterns for scripts, notebooks, offline mode, custom axes, config/summary, tables/media/plots, and framework integration routing.
- `references/api-reference.md`: precise signatures, lifecycle semantics, logging rules, settings, data type constraints, and version-specific caveats.
- `references/troubleshooting.md`: diagnosis playbooks for init failures, invalid IDs, unwritable directories, missing API keys, forgotten finish, `reinit`, step/commit misuse, unsupported objects, and optional media dependencies.

## Safe Defaults

```python
import wandb

config = {"epochs": 10, "lr": 3e-4, "batch_size": 32}

with wandb.init(project="my-project", config=config) as run:
    run.define_metric("epoch")
    run.define_metric("train/*", step_metric="epoch")
    for epoch in range(config["epochs"]):
        loss = 1.0 / (epoch + 1)
        run.log({"epoch": epoch, "train/loss": loss})
    run.summary["best_train_loss"] = loss
```

For offline smoke validation:

```bash
python sub-skills/experiment-tracking/scripts/offline_tracking_smoke.py --steps 3
```

Files in this skill

  • SKILL.md2.8 KB
  • references/api-reference.md6.7 KB
  • references/troubleshooting.md4.9 KB
  • references/workflows.md7.3 KB
  • scripts/offline_tracking_smoke.py4.2 KB

Attribution

Is this your skill, or is something wrong with this listing? Request removal or report an issue. Author removals are honored within 72 hours.

Comments

Loading comments…

Newsletter

Get the weekly list of safe new skills, and the ones we pulled.