정보
이 스킬은 강력한 금융 머신러닝을 위한 핵심 검증 방법을 제공하며, 퍼지드 크로스 밸리데이션, 트리플 배리어 라벨링, 멀티플 테스팅 보정 등을 포함합니다. 이는 통계적 타당성을 보장하기 위해 모델의 백테스트, 피처 또는 라벨을 설계하거나 평가할 때 사용해야 하며, 실행이나 마이크로스트럭처 작업에는 사용되지 않습니다. 그 목적은 퀀트 연구자들이 요구되는 통계적 불변성을 실제 구현 단계로 전환하는 데 있습니다.
빠른 설치
Claude Code
추천npx skills add avelikiy/great_cto -a claude-code/plugin add https://github.com/avelikiy/great_ctogit clone https://github.com/avelikiy/great_cto.git ~/.claude/skills/quant-validationClaude Code에서 이 명령을 복사하여 붙여넣어 스킬을 설치하세요
문서
Validating a financial model — the five ways the number lies
A backtest that looks excellent and loses money live is not usually a bad strategy. It is a good measurement of the wrong thing. Each section below is one mechanism by which a number becomes convincing without becoming true.
On sourcing. The methods here are standard and attributable — most of them to Marcos López de Prado's Advances in Financial Machine Learning, with the information-ratio framing from Grinold & Kahn. This file states the MECHANISM and what to check, and deliberately does not restate formulas from memory. Where an implementation needs an exact expression — the deflated Sharpe ratio in particular — verify it against the primary source before shipping a number that depends on it. A formula recalled approximately is worse here than no formula: it produces a specific, wrong, confident figure.
1. Purged cross-validation with an embargo
The leak. In a normal k-fold split, training and test rows are disjoint. In a financial series they are not independent: a label at time t is computed from data spanning t to t+h. A training observation inside that window has seen the future the test observation is being asked to predict.
Purging. Drop from the training set every observation whose label window overlaps the label window of any test observation. Not the observation's timestamp — its label window. This is the step people skip, because a plain timestamp split looks like it already separates them.
The embargo. Purging is not enough when features are serially correlated: a training row immediately AFTER the test set still carries information about it. Drop a further band after each test fold. The band is a fraction of the total sample; there is no universal value, so state the one used and why.
Combinatorial purged CV. A single train/test split yields one backtest path and one Sharpe. Splitting combinatorially yields many paths and therefore a distribution, which is what you actually want: a strategy whose single path looks good and whose distribution straddles zero has told you something a point estimate hid.
What to check: is the split purged, is there an embargo, is its size stated, and is the reported figure a distribution or a single draw.
2. Triple-barrier labelling
The problem with fixed-horizon returns. Labelling "the return over the next five days" assumes you would have held for five days. You would not: a stop-loss would have taken you out on day two. The model is trained on an outcome that could not have happened.
The method. Three barriers per observation — a profit-take level, a stop-loss level, and a time limit. The label is which barrier was touched first. Levels are usually set from a volatility estimate rather than fixed, because a 2% move means different things in different regimes.
What to check: are the barriers volatility-scaled, is the time limit stated, and does the label record which barrier ended the observation rather than only the sign.
3. Sample uniqueness under overlapping labels
The problem. Overlapping label windows mean two rows can describe largely the same outcome. Standard learning assumes independent draws; here they are not, so the effective sample is far smaller than the row count and every confidence interval computed from that count is too narrow.
Two responses: weight each observation by its average uniqueness (how much of its label window it does not share), or draw with a sequential bootstrap that prefers observations overlapping little with those already drawn.
What to check: is a uniqueness weighting or effective sample size reported. A row count offered as a sample size is a wrong number, not a rough one.
4. Fractional differentiation
The dilemma. Price levels are non-stationary; a model fitted to them learns a level that will not recur. The reflex is a first difference — returns — which is stationary and has thrown away the memory the signal lived in.
The method. Difference by the smallest order d, generally fractional, at
which the series passes a stationarity test while retaining maximum correlation
with the undifferenced series. d is a result, not a setting: it is searched for,
and it is reported.
What to check: is d reported at all, was it searched rather than assumed,
and was correlation with the original series measured — not just the stationarity
test passed. Passing the test is the constraint; keeping the memory is the
objective.
5. Meta-labelling
What it is. Two models rather than one. The primary decides the SIDE — long, short, flat. The secondary decides only whether to ACT on that call, as a binary: take this bet or pass.
Why it helps. The two tasks have different error costs. A side model tuned for accuracy tends to trade too often; a secondary model can raise precision — fewer, better-founded bets — without touching the side logic. It also gives a natural place to size a bet by confidence, which a single model conflates with direction.
What to check: if a model both picks the side and decides whether to trade, say whether those were separated. If not, the reported precision is measuring two decisions at once.
6. The multiple-testing problem
The mechanism. Try enough configurations and one will look excellent by chance. The reported Sharpe of the best of N trials is not an estimate of that strategy's Sharpe — it is the maximum of N draws, and its expectation rises with N even when every strategy is worthless.
The minimum honest response: report N. How many feature sets, parameter values, and universes were tried to reach the reported one. A Sharpe without a trials count cannot be interpreted, and the count is usually much larger than people remember — every abandoned variant counts.
The correction: the deflated Sharpe ratio adjusts for the number of trials and for the non-normality of returns. Its exact expression is not restated here (see the sourcing note above); implement it from the primary source.
What to check: is N reported, and if a correction is claimed, does the implementation cite where the expression came from.
What this pack does not cover
Execution, order routing, market microstructure, and portfolio construction. The installed quant command set covers those well — measured: order-book, VWAP/TWAP and implementation-shortfall material across eighteen files, and nothing on any method above. This pack exists to fill exactly that hole, not to duplicate what is already there.
GitHub 저장소
자주 묻는 질문
quant-validation Skill이란 무엇인가요?
quant-validation은(는) avelikiy이(가) 만든 Claude Skill입니다. Skill은 Claude가 필요할 때 불러오는 지침과 리소스를 묶어 추가 프롬프트 없이 quant-validation 관련 작업을 수행할 수 있게 합니다.
quant-validation은(는) 어떻게 설치하나요?
이 페이지의 설치 명령을 사용하세요. quant-validation을(를) Claude Code 플러그인으로 추가하거나 저장소를 skills 디렉터리에 복제한 다음 Claude를 다시 시작해 Skill을 불러옵니다.
quant-validation은(는) 어떤 카테고리에 속하나요?
quant-validation은(는) 테스팅 카테고리에 속합니다.
quant-validation은(는) 무료로 사용할 수 있나요?
네. quant-validation은(는) AIMCP에 등록되어 있으며 무료로 설치할 수 있습니다.
연관 스킬
이 Claude Skill은 MMLU, GSM8K를 포함한 60개 이상의 표준화된 학술 과제에서 LLM 성능을 벤치마크하기 위해 lm-evaluation-harness를 실행합니다. 개발자들이 모델 품질을 비교하고, 학습 진행 상황을 추적하거나 학술 결과를 보고할 수 있도록 설계되었습니다. 이 도구는 HuggingFace와 vLLM 모델을 포함한 다양한 백엔드를 지원합니다.
이 스킬은 cron 표현식을 사용하여 Worker를 스케줄링하기 위한 Cloudflare Cron Triggers 구현에 관한 포괄적인 지식을 제공합니다. 주기적 작업, 유지보수 작업, 자동화된 워크플로우 설정 방법을 다루며, 잘못된 cron 표현식이나 시간대 문제 같은 일반적인 이슈들을 해결하는 방법을 포함합니다. 개발자들은 이를 통해 스케줄된 핸들러 구성, cron 트리거 테스트, Workflows 및 Green Compute와의 연동 작업을 수행할 수 있습니다.
이 Claude Skill은 Python 스크립트를 통해 로컬 웹 애플리케이션을 테스트하기 위한 Playwright 기반 툴킷을 제공합니다. 프론트엔드 검증, UI 디버깅, 스크린샷 캡처, 로그 확인 기능을 지원하며 서버 라이프사이클을 관리합니다. 브라우저 자동화 작업에 사용하되 컨텍스트 오염을 방지하기 위해 소스 코드를 읽지 않고 스크립트를 직접 실행하세요.
이 스킬은 테스트 통과를 확인한 후 체계적인 통합 옵션을 제시하여 개발자가 완성된 작업을 마무리하도록 돕습니다. 구현이 완료된 후 머지, PR 생성, 브랜치 정리와 같은 워크플로우를 안내합니다. 코드가 준비되고 테스트가 완료되었을 때 개발 프로세스를 체계적으로 마무리하기 위해 사용하세요.
