canli-mcp / Factor backtests

Combinatorial purged cross-validation

Combinatorial purged cross-validation of a search: choose the best trial on training days, score it on held-out blocks, with purge and embargo at the edges, for every choice of blocks, stitched into whole paths. Returns the spread of out-of-sample Sharpes against the in-sample one. Splits can run as shards on other machines and merge back. Paths share days and data, so their spread is not a confidence interval and they are not independent tests.

The tool is cpcv in canli-mcp 0.22.0, free and MIT-licensed, with no account and no API key. It comes from canli-backtest-mcp, which canli-mcp includes, and it is also its own server.

Arguments

As the server declares them
ArgumentRequiredType
returns_filenostring
groupsnointeger
test_groupsnointeger
purge_daysnointeger
embargo_daysnointeger
periods_per_yearnonumber
shardno{index,of}
out_filenostring
merge_filesnostring[]

How a model reaches it

Ask in plain words. The model finds cpcv with canli-mcp's find_tool, reads its arguments with describe_tool if it needs to, and runs it with run_tool. The call has this shape, with your values in place of the angle brackets:

{
  "name": "cpcv",
  "arguments": {}
}

More

Nothing here is investment advice.