Longbridge Quant
helsome/folio
Quantitative strategy frameworks: pairs trading/cointegration, volatility regime strategies, seasonality/calendar effects, multi-factor models (IC/IR), factor research and screening, correlation…
Walk-forward validation framework for trading strategies and ML models with time-series-aware splits, overfit detection, and regime-aware validation
$ npx skills add agiprolabs/claude-trading-skills --skill walk-forward-validation -a claude-codeProject install by default; add -g for ~/.claude/skills/.
$ gh skill install agiprolabs/claude-trading-skills walk-forward-validation --agent claude-codeProject scope by default; add --scope user for a personal install. Needs GitHub CLI 2.90.0 or later (public preview).
$ git clone --depth 1 https://github.com/agiprolabs/claude-trading-skills.git skills-src && mkdir -p .claude/skills && cp -r skills-src/skills/walk-forward-validation .claude/skills/walk-forward-validation && rm -rf skills-srcUse ~/.claude/skills/ instead of .claude/skills for a personal install. The folder must contain SKILL.md.
Claude Code skills documentation · loads skills from .claude/skills/
Install the "walk-forward-validation" agent skill from https://github.com/agiprolabs/claude-trading-skills/tree/main/skills/walk-forward-validation into .claude/skills/walk-forward-validation/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "walk-forward-validation", then confirm the skill loads.Claude Code copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$skill-installer install https://github.com/agiprolabs/claude-trading-skills/tree/main/skills/walk-forward-validationType this inside Codex. $skill-installer <name> installs a curated skill from openai/skills. The installer writes to $CODEX_HOME/skills (default ~/.codex/skills). Restart Codex if the skill does not show up.
$ npx skills add agiprolabs/claude-trading-skills --skill walk-forward-validation -a codexProject install goes to .agents/skills/; add -g for ~/.codex/skills/.
$ gh skill install agiprolabs/claude-trading-skills walk-forward-validation --agent codexProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/agiprolabs/claude-trading-skills.git skills-src && mkdir -p .agents/skills && cp -r skills-src/skills/walk-forward-validation .agents/skills/walk-forward-validation && rm -rf skills-srcUse ~/.agents/skills/ instead of .agents/skills for a personal install.
Codex skills documentation · loads skills from .agents/skills/
Install the "walk-forward-validation" agent skill from https://github.com/agiprolabs/claude-trading-skills/tree/main/skills/walk-forward-validation into .agents/skills/walk-forward-validation/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "walk-forward-validation", then confirm the skill loads.Codex copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$ npx skills add agiprolabs/claude-trading-skills --skill walk-forward-validation -a cursorProject install goes to .agents/skills/; add -g for ~/.cursor/skills/.
$ gh skill install agiprolabs/claude-trading-skills walk-forward-validation --agent cursorProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/agiprolabs/claude-trading-skills.git skills-src && mkdir -p .cursor/skills && cp -r skills-src/skills/walk-forward-validation .cursor/skills/walk-forward-validation && rm -rf skills-srcUse ~/.cursor/skills/ instead of .cursor/skills for a personal install.
Cursor skills documentation · loads skills from .cursor/skills/, .agents/skills/, .claude/skills/, .codex/skills/
Install the "walk-forward-validation" agent skill from https://github.com/agiprolabs/claude-trading-skills/tree/main/skills/walk-forward-validation into .cursor/skills/walk-forward-validation/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "walk-forward-validation", then confirm the skill loads.Cursor copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$ gemini skills install https://github.com/agiprolabs/claude-trading-skills.git --path skills/walk-forward-validation--scope user (default) or --scope workspace; --path is the subfolder of the repo that holds the skill; --consent skips the security confirmation prompt.
$ npx skills add agiprolabs/claude-trading-skills --skill walk-forward-validation -a gemini-cliProject install goes to .agents/skills/; add -g for ~/.gemini/skills/.
$ gh skill install agiprolabs/claude-trading-skills walk-forward-validation --agent gemini-cliProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/agiprolabs/claude-trading-skills.git skills-src && mkdir -p .gemini/skills && cp -r skills-src/skills/walk-forward-validation .gemini/skills/walk-forward-validation && rm -rf skills-srcUse ~/.gemini/skills/ instead of .gemini/skills for a personal install, then run /skills reload.
Gemini CLI skills documentation · loads skills from .gemini/skills/, .agents/skills/
Install the "walk-forward-validation" agent skill from https://github.com/agiprolabs/claude-trading-skills/tree/main/skills/walk-forward-validation into .gemini/skills/walk-forward-validation/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "walk-forward-validation", then confirm the skill loads.Gemini CLI copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$ gh skill install agiprolabs/claude-trading-skills walk-forward-validationInstalls for Copilot at project scope by default; add --scope user for a personal install. Preview a skill first with gh skill preview. Needs GitHub CLI 2.90.0 or later (public preview).
$ npx skills add agiprolabs/claude-trading-skills --skill walk-forward-validation -a github-copilotProject install goes to .agents/skills/; add -g for ~/.copilot/skills/.
$ git clone --depth 1 https://github.com/agiprolabs/claude-trading-skills.git skills-src && mkdir -p .github/skills && cp -r skills-src/skills/walk-forward-validation .github/skills/walk-forward-validation && rm -rf skills-srcUse ~/.copilot/skills/ instead of .github/skills for a personal install. Commit .github/skills so cloud agent and code review can use it.
GitHub Copilot skills documentation · loads skills from .github/skills/, .claude/skills/, .agents/skills/
Install the "walk-forward-validation" agent skill from https://github.com/agiprolabs/claude-trading-skills/tree/main/skills/walk-forward-validation into .github/skills/walk-forward-validation/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "walk-forward-validation", then confirm the skill loads.GitHub Copilot copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$ npx skills add agiprolabs/claude-trading-skills --skill walk-forward-validation -a opencodeOpenCode documents no install command of its own. Project install goes to .agents/skills/; add -g for ~/.config/opencode/skills/.
$ gh skill install agiprolabs/claude-trading-skills walk-forward-validation --agent opencodeProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/agiprolabs/claude-trading-skills.git skills-src && mkdir -p .opencode/skills && cp -r skills-src/skills/walk-forward-validation .opencode/skills/walk-forward-validation && rm -rf skills-srcUse ~/.config/opencode/skills/ instead of .opencode/skills for a personal install.
OpenCode skills documentation · loads skills from .opencode/skills/, .claude/skills/, .agents/skills/
Install the "walk-forward-validation" agent skill from https://github.com/agiprolabs/claude-trading-skills/tree/main/skills/walk-forward-validation into .opencode/skills/walk-forward-validation/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "walk-forward-validation", then confirm the skill loads.OpenCode copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
walk-forward-validationWalk-forward validation framework for trading strategies and ML models with time-series-aware splits, overfit detection, and regime-aware validation
Walk Forward Validation is an agent skill from agiprolabs/claude-trading-skills. Walk-forward validation framework for trading strategies and ML models with time-series-aware splits, overfit detection, and regime-aware validation
Its SKILL.md is about 2.2k tokens, which your agent loads only when the skill is triggered. The skill folder holds 7 other files, including scripts and reference files (for example `references/methodology.md`, `references/overfit_detection.md` and `references/practical_guide.md`).
It sits in Data & Analytics, covering Machine learning, Trading and backtesting and Forecasting and time series. The repository describes itself as: 68 trading, DeFi, and quantitative finance Agent Skills. Works with Claude Code, Cursor, Codex, Gemini CLI, and 30+ other tools. The licence is MIT.
4 steps, taken from the first numbered list in SKILL.md.
Read from SKILL.md and the folder at commit 981e1d7. It shows what the files ask for, not the result of running them.
Pre-approves nothing: there is no allowed-tools line, so your agent's usual permission prompts apply.
From allowed-tools in the SKILL.md frontmatter.
Ships 2 files in scripts/ (Python), which the agent can run.
From the folder's file list and the shell code blocks in SKILL.md.
No URLs in SKILL.md.
From URLs in SKILL.md, links to its own repository left out.
Names no API keys, tokens, secrets or passwords.
From names ending in _API_KEY, _TOKEN, _SECRET, _KEY or _PASSWORD in SKILL.md.
Walk Forward Validation loads about 2.2k tokens when it runs, and up to ~7.6k if it reads all its reference files. Until then it costs about 43 tokens; SKILL.md has 802 words of instructions outside code blocks.
Estimates: characters ÷ 4, the usual rule of thumb; real counts depend on the model's tokenizer. Scripts and assets cost tokens only if the agent reads them.
The automated check found no risky patterns in SKILL.md.
Automated static check — not a guarantee. Review scripts before installing. It scans the text of SKILL.md for risky patterns (piping downloads into a shell, reading credential files, hidden Unicode, destructive commands); the scripts in this folder are not scanned.
The full file from agiprolabs/claude-trading-skills at commit 981e1d7, republished under its MIT licence (© agiprolabs). 802 words, ~2,184 tokens.
.claude/skills/walk-forward-validation/SKILL.md (or your agent's skills folder). This skill also uses 5 other files; get the full folder from GitHub.Walk-forward validation framework for trading strategies and ML models. Standard cross-validation (k-fold, random splits) fails catastrophically for financial time series because it introduces lookahead bias and ignores autocorrelation. This skill covers proper time-series validation techniques including rolling and expanding windows, purged cross-validation, combinatorial purged cross-validation (CPCV), and overfit detection metrics.
Standard k-fold CV assumes data points are independent and identically distributed (IID). Financial time series violate both assumptions:
The train window has a fixed size and slides forward in time. This is preferred when you believe older data is less relevant (common in crypto).
Window 1: [===TRAIN===][=TEST=]
Window 2: [===TRAIN===][=TEST=]
Window 3: [===TRAIN===][=TEST=]Parameters:
train_size: Number of bars/days in the training windowtest_size: Number of bars/days in the test windowstep_size: How far to advance between folds (often equals test_size)The train window starts at the beginning and expands forward. This uses all available historical data, which helps when data is scarce.
Window 1: [==TRAIN==][=TEST=]
Window 2: [====TRAIN====][=TEST=]
Window 3: [======TRAIN======][=TEST=]Parameters:
min_train_size: Minimum training samples before first foldtest_size: Fixed test window sizestep_size: How far to advance between folds| Factor | Rolling | Expanding |
|---|---|---|
| Data recency | Prioritizes recent data | Uses all history |
| Regime changes | Better adapts to new regimes | May dilute recent regime |
| Sample size | Fixed, may be small | Grows over time |
| Crypto preference | Preferred for < 6mo horizons | Better for regime-stable models |
Remove training samples whose labels overlap with the test set's time range. If a label is computed as the 24h forward return starting at time t, any training sample where t + 24h extends into the test period must be purged.
def purge_train_indices(
train_idx: list[int],
test_start: int,
label_horizon: int,
timestamps: list[int],
) -> list[int]:
"""Remove train samples whose label windows overlap test period."""
test_start_time = timestamps[test_start]
return [
i for i in train_idx
if timestamps[i] + label_horizon < test_start_time
]Add a buffer gap between the end of training and start of testing to account for serial correlation that purging alone does not eliminate.
[===TRAIN===][--EMBARGO--][=TEST=]Typical embargo sizes:
CPCV (Lopez de Prado, 2018) generates all possible train/test combinations from N groups while maintaining temporal ordering. This produces far more test paths than standard walk-forward, enabling statistical tests for overfitting.
Key properties:
N contiguous groupsk test groups, the remaining N-k groups form the training setC(N, k) backtest paths (e.g., N=6, k=2 gives 15 paths)See references/methodology.md for the full CPCV algorithm and formulas.
The observed Sharpe ratio must be adjusted for:
import numpy as np
from scipy.stats import norm
def deflated_sharpe_ratio(
observed_sr: float,
num_trials: int,
backtest_length: int,
skewness: float = 0.0,
kurtosis: float = 3.0,
) -> float:
"""Compute the probability that observed SR > 0 after deflation.
Args:
observed_sr: Annualized Sharpe ratio of the selected strategy.
num_trials: Number of strategies tested (including discarded ones).
backtest_length: Number of return observations.
skewness: Skewness of returns.
kurtosis: Excess kurtosis of returns.
Returns:
p-value (probability SR is genuinely > 0).
"""
sr_std = np.sqrt(
(1 - skewness * observed_sr + (kurtosis - 1) / 4 * observed_sr**2)
/ (backtest_length - 1)
)
# Expected max SR under null (Euler-Mascheroni approximation)
euler_mascheroni = 0.5772156649
expected_max_sr = norm.ppf(1 - 1 / num_trials) * (
1 - euler_mascheroni
) + euler_mascheroni * norm.ppf(1 - 1 / (num_trials * np.e))
dsr = norm.cdf((observed_sr - expected_max_sr) / sr_std)
return dsrA DSR below 0.95 suggests the observed performance is likely due to overfitting across the trials tested.
PBO uses CPCV to measure the fraction of backtest paths where the in-sample optimal strategy underperforms the median out-of-sample. A PBO above 0.50 indicates more-likely-than-not overfitting.
See references/overfit_detection.md for complete derivations and implementation details.
min_train_size may be necessary.| Strategy Timeframe | Train Window | Test Window | Embargo |
|---|---|---|---|
| Scalping (1-5min) | 3-7 days | 1 day | 2-4 hours |
| Intraday (15min-1h) | 14-30 days | 3-7 days | 12-24 hours |
| Swing (4h-daily) | 30-90 days | 7-14 days | 2-5 days |
| Position (daily-weekly) | 90-180 days | 30 days | 5-10 days |
from walk_forward import WalkForwardValidator, WalkForwardConfig
config = WalkForwardConfig(
train_size=90,
test_size=14,
step_size=14,
window_type="rolling",
embargo_size=3,
purge_horizon=1,
)
validator = WalkForwardValidator(config)
for fold in validator.split(price_data):
model.fit(fold.train_X, fold.train_y)
predictions = model.predict(fold.test_X)
fold.record_performance(predictions, fold.test_y)
results = validator.aggregate_results()
print(f"OOS Sharpe: {results.oos_sharpe:.3f}")
print(f"Train/Test Sharpe ratio: {results.sharpe_ratio_ratio:.2f}")references/methodology.md — Walk-forward theory, window types, purging, embargo, CPCV algorithm with formulasreferences/overfit_detection.md — Deflated Sharpe ratio, probability of backtest overfitting, multiple testing correctionsreferences/practical_guide.md — Window size selection for crypto, regime considerations, common validation mistakesscripts/walk_forward.py — Walk-forward validation engine with rolling and expanding windows; --demo mode with synthetic datascripts/overfit_detector.py — Deflated Sharpe ratio and PBO computation; --demo mode with synthetic backtest results© agiprolabs, MIT. Rendered from Markdown: HTML in the file is shown as text, images as links, and headings moved down two levels. Raw file
SKILL.md and 5 other files (scripts, references) in skills/walk-forward-validation of agiprolabs/claude-trading-skills.
Open the folder on GitHubat commit 981e1d7
Walk Forward Validation next to the 5 skills that share the most tags, products or categories with it. Stars are the repository's; “used in” counts other GitHub owners with a copy.
| Skill | Stars | Used in | Tokens | Auto-check | Licence | Repo updated |
|---|---|---|---|---|---|---|
| Walk Forward Validation this skillagiprolabs/claude-trading-skills | 410 | — | ~2.2k | Automated safety check: Pass | MIT | |
| Longbridge Quanthelsome/folio | 270 | 1 repos | ~1.6k | Automated safety check: Pass | MIT | |
| Forecastingericrisco/rsc-harness | 174 | — | ~2.8k | Automated safety check: Pass | MIT | |
| Options Spread Conviction EngineLeoYeAI/openclaw-master-skills | 2.2k | — | ~5.7k | Automated safety check: Notes | MIT | |
| QuantMind Training Config Generatorqusong0627/QuantMind | 1.7k | — | ~1.5k | Automated safety check: Pass | AGPL-3.0 | |
| Machine Learning Trading StrategyHKUDS/Vibe-Trading | 35k | — | ~3.2k | Automated safety check: Pass | MIT |
helsome/folio
Quantitative strategy frameworks: pairs trading/cointegration, volatility regime strategies, seasonality/calendar effects, multi-factor models (IC/IR), factor research and screening, correlation…
ericrisco/rsc-harness
A skill your agent uses when projecting history forward — sales, demand, units, revenue, signups, traffic — into a defensible number with an error band: method by data shape, rolling-origin…
LeoYeAI/openclaw-master-skills
Multi-regime options spread analysis engine with quantitative rigor.
qusong0627/QuantMind
Turns a plain-language model training request into a validated QuantMind training config file that can be imported from the Model Training page.
HKUDS/Vibe-Trading
Trains scikit-learn models with walk-forward validation on features from OHLCV data to predict return direction and turn the predictions into trading signals.
HKUDS/Vibe-Trading
Guides your agent through unit-root, cointegration, GARCH, bootstrap and regression-diagnostic tests on financial time series, using a tested helper module.
agiprolabs/claude-trading-skills
Event-driven backtesting with bar-by-bar execution, complex order types, multiple analyzers, and custom indicators
agiprolabs/claude-trading-skills
Solana token market data via Birdeye — prices, OHLCV, trades, token metadata, security checks, and trader activity
agiprolabs/claude-trading-skills
Broad crypto market data from CoinGecko covering 13,000+ tokens.
agiprolabs/claude-trading-skills
Cointegration testing for pairs trading using Engle-Granger, Johansen, and rolling stability analysis
agiprolabs/claude-trading-skills
Wallet evaluation, monitoring, and copy-trade strategy design for Solana DEX trading
agiprolabs/claude-trading-skills
Cross-asset correlation analysis including rolling correlation, hierarchical clustering, tail dependence, and regime-dependent correlation
Categories
Walk-forward validation framework for trading strategies and ML models with time-series-aware splits, overfit detection, and regime-aware validation. Walk Forward Validation is an agent skill from agiprolabs/claude-trading-skills.
Walk Forward Validation fits situations like: tasks that involve Machine learning; tasks that involve Trading and backtesting; tasks that involve Forecasting and time series.
Run `npx skills add agiprolabs/claude-trading-skills --skill walk-forward-validation -a claude-code`. Or copy the skill folder (skills/walk-forward-validation in agiprolabs/claude-trading-skills) into .claude/skills/walk-forward-validation in your project. Claude Code loads it when a task matches its description.
Run `npx skills add agiprolabs/claude-trading-skills --skill walk-forward-validation -a codex`. Or copy the skill folder (skills/walk-forward-validation in agiprolabs/claude-trading-skills) into .agents/skills/walk-forward-validation in your project. Codex loads it when a task matches its description.
Cursor, Gemini CLI, GitHub Copilot and OpenCode also load SKILL.md folders. With the skills CLI, run `npx skills add agiprolabs/claude-trading-skills --skill walk-forward-validation -a cursor` (or -a gemini-cli, github-copilot or opencode for the others). To copy it by hand, put the folder in .cursor/skills/walk-forward-validation, .gemini/skills/walk-forward-validation, .github/skills/walk-forward-validation and .opencode/skills/walk-forward-validation in your project.
Going by SKILL.md and its folder, Walk Forward Validation needs Python for the scripts in its folder. Our summary lists: Python 3.
SKILL.md contains no URLs. Any network use would come from the scripts or tools the agent runs. This is read from the text; nothing was executed.
Our automated static check of SKILL.md found no risky patterns, such as piping downloads into a shell, reading credential files or hidden Unicode. It is not a guarantee. The check reads SKILL.md only: the scripts in the folder are not scanned, so read them before running anything.
Walk Forward Validation is published under the MIT licence (the repository's licence). It allows redistribution, so the full SKILL.md is shown on this page.
About 2.2k tokens (SKILL.md is roughly 8.7k characters). Agents keep only the skill's name and description in context until a task matches; then they load SKILL.md in full. Its references folder adds about 5.4k tokens, read only when the agent opens those files.
Skills that share tags, products or a category with Walk Forward Validation: Longbridge Quant (helsome/folio, 270 stars), Forecasting (ericrisco/rsc-harness, 174 stars), Options Spread Conviction Engine (LeoYeAI/openclaw-master-skills, 2.2k stars) and QuantMind Training Config Generator (qusong0627/QuantMind, 1.7k stars). The comparison table on this page puts their stars, adoption, token cost, safety result and licence side by side.
agiprolabs (a GitHub user) maintains it in agiprolabs/claude-trading-skills, which has 410 GitHub stars. The repository holds 68 skills in this directory. The repository was last updated on September 3, 2026.
Source: agiprolabs/claude-trading-skills on GitHub. Facts on this page come from the repository at the commit we read; the author's words are quoted as theirs.