Purpose
Keel is a quantitative crypto trading platform built around Hyperliquid, covering strategy development, backtesting, live execution, and portfolio management. keel-trade is the platform's public Python package mirror and also its research entry point for AI agents: it provides both a CLI and a stdio MCP server, letting users build and backtest Hyperliquid perpetual contract strategies in the terminal or in any MCP-compatible agent. The platform itself also includes a web application for composing strategies, running backtests, and deploying live trading, a deterministic backtesting engine, a reproducible strategy library, and a suite of screening and calculation tools at usekeel.io/lab (funding rate leaderboard, momentum, overfitting checks, walk-forward visualization, etc.).
Main capabilities
- Typed strategy composition: strategies are graphs made up of versioned components, and compilation errors surface at authoring time rather than in production.
- Deterministic backtesting: based on real Hyperliquid historical data, including real funding rates, prices, and slippage.
- Bit-for-bit identical live execution: the same compiled strategy artifact runs in backtests and on Hyperliquid, with no second implementation that could introduce drift.
- Agents compose, the engine executes: Claude / Cursor / Codex help build strategies but do not enter the trading loop.
- MCP toolset: the default local toolset includes always, read-only, backtest, share, and live-read, covering status, authentication, components, strategy lifecycle, backtesting, auditing, accounts, sharing, and read-only live monitoring.
- CLI mirror: every MCP result tool has a corresponding CLI command, making it convenient for terminals, SSH, CI, scripts, or agents that prefer subprocess calls.
Usage
Hosted MCP (no installation required)
Hosted endpoint URL:https://mcp.usekeel.io/mcp — one endpoint, 29 research/backtest/read tools, no installation required. Authentication uses the MCP client's own OAuth flow rather than tool calls. The first request returns a 401 with OAuth 2.1 metadata, and a compliant client can discover the login steps on its own.
Configuration for each client:
- Claude: Customize → Connectors → Add custom connector, paste https://mcp.usekeel.io/mcp and select Connect.
- ChatGPT: Settings → Security and login → enable Developer mode (requires a paid ChatGPT plan; Business/Enterprise requires administrator approval). Open chatgpt.com/plugins, select +, enter a name and description, and use https://mcp.usekeel.io/mcp as the MCP server URL (including the /mcp path).
- Claude Code:
claude mcp add --transport http keel https://mcp.usekeel.io/mcp. Inside Claude Code, run/mcpand select Authenticate. - Cursor: Add the server to .cursor/mcp.json (project) or ~/.cursor/mcp.json (global):
{"mcpServers": {"keel": {"url": "https://mcp.usekeel.io/mcp"}}}. Cursor requires login on first use. - Codex:
codex mcp add keel --url https://mcp.usekeel.io/mcp, thencodex mcp login keel. Codex opens a browser for login. - Windsurf: Add the server to Windsurf's mcp_config.json:
{"mcpServers": {"keel": {"serverUrl": "https://mcp.usekeel.io/mcp"}}}. Windsurf requires login on first use. - VS Code: Add the server to .vscode/mcp.json, or open the installation link:
{"servers": {"keel": {"type": "http", "url": "https://mcp.usekeel.io/mcp"}}}. VS Code requires login on first use. - Other: Use the client's built-in add remote / HTTP MCP server flow, with the address https://mcp.usekeel.io/mcp。
CLI + local MCP (this package)
Install:uv tool install keel-trade Or install via pipx, requires Python 3.11+. Then register the stdio MCP command with the agent host. For Cursor, Windsurf, and general MCP clients, refer to usekeel.io/keel-mcp#install or the agent setup guide.
Claude Desktop one-click install (MCPB)
Download keel-trade-<version>.mcpb from the latest release and drag it into Claude Desktop. A single cross-platform package, supporting macOS, Windows, and Linux. Requires system Python 3.11+. The first launch takes about 10-30 seconds; the package pip-installs runtime dependencies into ~/.keel/mcpb-lib/py3.X/, after which launches complete instantly. The package runs a local MCP server: the assistant can compose and validate strategies, backtest on real Hyperliquid history, browse the strategy library, compare runs, and share results. Log in once with keel_auth_login. By default it cannot place orders or transfer funds.
First conversation
After installation, log in once through the agent (no terminal commands needed):
User: "Connect to Keel." Agent: calls keel_auth_login. The browser opens app.usekeel.io, click Allow, and the token is written to ~/.keel/config.yaml. Authentication is valid for 30 days and can be refreshed transparently.
Then describe what you need:
User: "Find me momentum signals for Hyperliquid top-30 perps and compose a backtest from 2024-08-15 to today." Agent: calls keel_components_search → keel_components_get_many → keel_strategy_compose → keel_backtest_run, returning a share URL with a full tearsheet (equity curve, Sharpe, maximum drawdown, per-asset attribution).
Specific example given in the documentation: a funding rate arbitrage backtest produced through the above workflow, on real Hyperliquid data from 2024-08-15 to 2026-04-30, had a Sharpe of 2.17.
Live write tools
Live write tools (keel_live_deploy, keel_live_control, keel_live_update) are disabled by default and must be enabled via the KEEL_TOOLSETS selection. Even when enabled, going live is a handoff: keel_live_deploy does not place orders, but instead returns a link to the Keel Web app, where the user selects an account, reviews position sizing, and launches the strategy. Performing operations on a live account from the local machine (keel_live_control or operator-only direct deployment) also requires local authorization (keel arm live set). The hosted connector mcp.usekeel.io does not include live write tools at all.
Use cases
- Use AI agents to research and develop perpetual contract strategies on Hyperliquid.
- Deterministic backtesting on real historical data (including funding rates and slippage).
- Browse, compare, and share reproducible strategies.
- Invoke the same capabilities via CLI in the terminal, SSH sessions, CI, or scripts.
Limitations and notes
- Currently in Alpha; the CLI and MCP surface are stable and regularly published to PyPI, while the underlying engine and component library are still under active development.
- The local MCP cannot place orders or transfer funds by default; live operations take place in the Keel Web app.
- Both the MCPB package and the terminal installation path require system Python 3.11+.
- Keel is only used to measure strategies designed by users, does not constitute investment advice, and backtest results do not represent future returns.
- License: MIT.
Related links
- Website/product page: usekeel.io/keel-mcp
- Documentation: usekeel.io/docs/getting-started
- Agent setup (by host): usekeel.io/docs/agents/setup
- CLI reference: usekeel.io/docs/sdk/cli-reference
- MCP tool reference: usekeel.io/docs/sdk/tool-reference
- REST API reference: usekeel.io/docs/api-reference
- Agent instructions (machine-readable): AGENTS.md
- Contributing/reporting bugs: see CONTRIBUTING.md; for security issues, email team@usekeel.io (do not open a public issue)