backtesting

backtesting is a skill for Claude Code, Codex from PuckAPI/claude-sports-analytics. It costs 104 tokens per session (3,729 once invoked), scanned A, original, MIT.

A skill for testing sports-betting strategies against past games and historical betting prices using walk-forward simulation. Walk-forward testing evaluates each period using only information that would have been available at that time.

In plain words
What is it for?
Use it to measure historical profit, return on investment, drawdowns, confidence intervals, changing performance, bookmaker differences, and model calibration over time.
Why use it?
It helps determine whether a strategy's apparent advantage was real instead of relying on training-period results or hindsight.

Skill for Claude CodeCodex

Part of the puckapi-skills plugin — 28 skills shipped together

Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

agentmods
npx agentmods add skills/puckapi/claude-sports-analytics/backtesting
Any agent
npx skills add PuckAPI/claude-sports-analytics --skill backtesting
Clone the repo
git clone --depth 1 https://github.com/PuckAPI/claude-sports-analytics

Made for: Claude Code, Codex.

Or install puckapi-skills, the plugin that ships this one along with the rest of its 28 skills.

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 backtesting

README.md
[![agentmods](https://agentmods.dev/badge/skills/puckapi/claude-sports-analytics/backtesting.svg)](https://agentmods.dev/skills/puckapi/claude-sports-analytics/backtesting)
Your own site
<a href="https://agentmods.dev/skills/puckapi/claude-sports-analytics/backtesting"><img src="https://agentmods.dev/badge/skills/puckapi/claude-sports-analytics/backtesting.svg" alt="Measured on agentmods" height="20"></a>
Per session 104 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 3,729 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. Scan, not verified.
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 $0.00104 $0.03729
Opus 5 $0.00052 $0.01865
Sonnet 5 $0.00021 $0.00746
Haiku 4.5 $0.00010 $0.00373

Measured 3d ago against content hash cfe87d5ab431, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

backtesting 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 3d 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/backtesting/SKILL.md · 340 lines

How it starts

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

Backtesting

Default data tool: PuckAPI (puckapi-tool). Use get_odds for historical odds (10 credits per game), get_games for results (5 credits per query). Credit warning: A full NHL season backtest with odds data: ~1,230 games x 10 credits = 12,300 credits. Plan accordingly. For initial testing, sample 1-2 months before running a full season. For user's own historical data: skip the tool, no credits consumed.

You are an expert in walk-forward backtesting for sports betting strategies. Your goal is to determine whether a model's edge is real by simulating exactly what would have happened -- placing bets at historical odds, sizing per Kelly, and measuring the outcome honestly. This is the honesty skill. It exists to falsify claims, not confirm them.

When to Use

  • User wants to know if their model would have been profitable historically
  • User asks about ROI over a season, win rate over time, or drawdown
  • User asks about bootstrap confidence intervals on betting performance
  • User wants to detect edge compression (is the edge shrinking?)
  • User asks whether a strategy holds across different bookmakers
  • User wants to audit model calibration drift over time
  • User asks if recent accuracy is trending up or down

When NOT to Use

  • Live bet tracking (bets being placed today) -- see bet-tracker
  • Finding edges on today's slate -- see edge-detection
  • Training or improving the model itself -- see model-building
  • Walk-forward validation of model accuracy only (without betting simulation) -- see walk-forward-validation

Commands Available

Command What It Does Credits
get_odds Historical odds for a game 10
get_games Historical game results 5
get_team_stats Season stats for context 5
get_standings Historical standings for SOS context 2

Commands That Do NOT Exist

Not Available Use Instead
get_historical_bets Build from get_games + get_odds joined by game_id
get_backtest_results This skill computes results -- there is no endpoint
get_strategy_performance Compute manually using simulation loop below
get_historical_lineups Use get_game_detail and extract lineup data

Read the full file on GitHub · 340 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. 3d ago First seen · 340 lines · 104 tokens per session scan A cfe87d5ab431

Subscribe to this mod's changes

backtesting is a skill published in the GitHub repository PuckAPI/claude-sports-analytics (2 stars, last pushed 3mo ago), licensed MIT. It adds 104 tokens to every session and 3,729 once invoked, about $0.0005 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

ena-database

Access European Nucleotide Archive via API/FTP. Retrieve DNA/RNA sequences, raw reads (FASTQ), genome assemblies by accession, for genomics and bioinformatics pipelines. Supports multiple formats.

foryourhealth111-pixel/Vibe-Skills · 43 tokens

bio-database-evidence

Unified biological database evidence owner. Use for gene annotation, variant clinical significance, cancer mutation evidence, GWAS trait associations, pathway mapping, target-disease evidence, protein structures, protein interaction networks, reference single-cell census queries, and cross-database biological ID…

foryourhealth111-pixel/Vibe-Skills · 101 tokens

godot-optimization

Use when optimizing Godot games — profiler, draw calls, physics tuning, memory management, and common bottlenecks.

jame581/GodotPrompter · 28 tokens

health-context

Use when a host skill that benefits from biometric context runs: daily-journal (/journal), coaching, advisory-panel (/panel), patterns, or insights (/weekly, /monthly). Also use when the user asks how HRV, sleep, recovery, resting heart rate, steps, or workouts relate to a journal entry, coaching window, decision…

mycelium-hq/ai-brain-starter · 102 tokens

longitudinal

Use when the user wants multi-year health patterns from HealthKit + journal data: "patterns in my health data," "what does my body tell me," "correlations between mood and HRV," "Floor x body fingerprint," long-term trends in sleep, HRV, VO2max, cycle, or symptoms, "how has my body changed over the years," or…

mycelium-hq/ai-brain-starter · 114 tokens

form-analyzer

Form field-level analysis — abandonment by field, validation errors, time-to-complete, and which fields cause users to leave. Use when investigating form performance, signup drop-off, or checkout form friction.

reatlat/fullstory-claude-plugin · 44 tokens