Deptho

io.deptho由 deptho.io 发布v0.1.0更新于 Nov 7, 2026

Replay a crypto backtest's orders against trades and write tearsheets, locally.

已验证STDIO仅桌面金融数据与分析

概览

AI 生成的概览

本地 MCP 服务器,用逐笔成交数据回放加密货币永续合约回测的订单,并生成把收益拆分为手续费、资金费和滑点的 HTML 报告。

可以做什么
  • 用 Binance aggTrades 或 Tardis.dev 成交文件回放订单 CSV,返回成交明细与滑点统计(均值、中位数、p90、p99 bps)
  • 根据含 time、price、position 的 bars CSV 生成自包含的 HTML 报告,返回文件路径与关键指标
  • 检查本机是否已安装并授权 Deptho Pro
  • 使用 Deptho Pro 时,把 Binance USD-M 每日成交文件下载为本地内存映射数据集,并对其回放订单
适用场景
适合让助手在逐笔层面核查加密货币永续合约回测:评估市价单的真实滑点,或在采信结果前把收益拆分为手续费、资金费和滑点。
运行要求
以 PyPI 包形式在本地通过 stdio 运行(pip install deptho-mcp),需要 Python,并让助手指向已安装的 deptho-mcp 可执行文件。输入为本地 CSV 与成交文件。Pro 工具需在同一环境中安装 Deptho Pro 并提供许可证密钥,pro_sync 还需访问 Binance 公共存档的网络。
安装前请注意
成交仅按逐笔成交价建模,不考虑订单簿深度与排队位置,滑点估计只是近似值。Pro 工具需要许可证密钥,pro_sync 会从 Binance 公共存档下载数据;其余操作均只处理本地文件。该服务与 Binance、Tardis.dev 无关联。

安装

在 SourceWeft 中

  1. 打开 控制台中的 Deptho,将其添加到工作区。
  2. 为需要使用其工具的对话启用该服务。

Desktop only,通过 STDIO。 STDIO 服务会启动本地进程,因此需要 SourceWeft 桌面宿主。

其他 MCP 客户端

参照 仓库 中的启动说明。

README

deptho-mcp

An MCP server that gives coding assistants (Claude Code, Claude Desktop, Cursor and others) Deptho's backtest checks: replay a backtest's market orders against the trades that followed them, and write a tearsheet that splits returns into fees, funding and slippage. It runs on your machine over stdio, reads and writes local files, and sends nothing anywhere.

Tools

tooldoes
replay_ordersorders CSV + trades file → fills CSV and a slippage summary (mean, median, p90, p99 bps)
tearsheetbars CSV (time, price, position) → self-contained HTML report, its path and headline numbers
pro_statuswhether Deptho Pro is installed and licensed here
pro_syncDeptho Pro: download Binance USD-M days from the public archive into a local memory-mapped dataset
pro_replayDeptho Pro: replay an orders CSV against that dataset

Orders CSV: time (ISO 8601 or epoch), side (+1/-1 or buy/sell), qty (base units, e.g. BTC). Trades file: a Binance archive aggTrades file (.zip or .csv) or a Tardis.dev trades file (.csv or .csv.gz) covering the orders' period.

Fills are modeled from trade prints: each order fills at the VWAP of the same-side trades after it until its size is covered. Order book depth and queue position are not modeled.

Install

bash
pip install deptho-mcp

Use a virtual environment if you like; then point your assistant at that environment's deptho-mcp (which deptho-mcp prints the full path). For the Pro tools, install Deptho Pro into the same environment with your license key.

Claude Code

bash
claude mcp add deptho -- deptho-mcp

Claude Desktop

Settings → Developer → Edit Config, then add to claude_desktop_config.json:

json
{  "mcpServers": {    "deptho": { "command": "/full/path/to/deptho-mcp" }  }}

Cursor

Add to ~/.cursor/mcp.json (or .cursor/mcp.json in a project):

json
{  "mcpServers": {    "deptho": { "command": "/full/path/to/deptho-mcp" }  }}

Then ask, for example: "Replay orders.csv against BTCUSDT-aggTrades-2026-09-30.zip and tell me the p90 slippage."

Privacy

Every tool works on local files. Nothing is sent to Deptho. The only download is pro_sync, which fetches Binance's public archive (data.binance.vision) when you ask it to.

Links

License: Apache-2.0. Market data comes from Binance's public archive or from files you supply; Deptho is not affiliated with Binance or Tardis.dev.

来源:README.md,提交 c1a3475

工具

5

replay_orders

Replay a backtest's market orders against the trades that followed them. orders_csv: CSV with columns time (ISO or epoch), side (+1/-1 or buy/sell), qty (base units). trades_file: Binance archive aggTrades file (.zip or .csv) or Tardis.dev trades file (.csv or .csv.gz) covering the orders' period. Writes one row per filled order (side, qty, price, ref_price, slippage_bps) to fills_csv (default: next to the orders, <name>.fills.csv) and returns a summary. Slippage is in bps against the last trade before each order; positive = cost.

输入参数fills_csvorders_csv必填trades_file必填

tearsheet

Write Deptho's HTML tearsheet for a strategy and return its path and headline numbers. bars_csv: CSV with columns time, price (mark/close) and position (exposure as a fraction of equity, 1.0 = 1x long, decided at each bar's close; it earns from the next bar). funding_csv (optional): time and funding_rate (positive = longs pay). fee_bps and slippage_bps: per unit of turnover; use the slippage measured with replay_orders rather than a guess. Writes one self-contained HTML file (default: next to bars_csv, <name>.report.html).

输入参数titlefee_bpsbars_csv必填funding_csvreport_htmlslippage_bps

pro_status

Whether Deptho Pro is installed and licensed here. pro_sync and pro_replay need it.

无需输入参数。

pro_sync

(Deptho Pro) Download Binance USD-M daily trade files from Binance's public archive for start..end (YYYY-MM-DD, inclusive) and append them to one local memory-mapped dataset, "<SYMBOL>-aggTrades". Days already on disk aren't downloaded again. Returns the dataset name and size.

输入参数end必填start必填symbol必填

pro_replay

(Deptho Pro) Replay an orders CSV (time, side, qty) against a dataset made by pro_sync (the name it returned, e.g. "BTCUSDT-aggTrades"), straight off the memory-mapped columns. Same output as replay_orders.

输入参数dataset必填fills_csvorders_csv必填

版本历史

1
  1. v0.1.0最新Nov 5, 2026

评分

已满足适用检查项的 90%

该评分衡量此收录条目的完整程度,依据注册中心条目、端点与公开来源计算得出。它不是对服务器本身的评价,也不表示服务器安全或当前可用:可连通性是带日期的检查结果,评分也不包含安装量或用户评价。

  • 近 30 天内可连通25 分
  • 已声明认证方式10 分

    请在注册中心条目中声明凭据请求头,或保持端点能够响应探测,以便判定其认证方式。

  • 已列出工具必需15 分
  • 描述必需15 分
  • 图标10 分
  • 文档15 分
  • 许可证10 分