Build. Backtest. Automate.
with your agent
Turn trading ideas into structured strategies, backtest multi-asset portfolios in seconds, and run the same strategy live on Hyperliquid. Keel MCP gives your agent the same workflow.
Give the agent one URL and let it bootstrap the right workflow.
AGENTS.md is the compact, machine-readable entrypoint. It tells agents how to install Keel, register the right command, authenticate, and stay inside the safe backtest-first workflow.
Agent Self-Registration
MCP
Read https://usekeel.io/AGENTS.md and follow the instructionsRead https://usekeel.io/AGENTS.md, install Keel if needed,
connect through MCP, then backtest a funding-carry strategy
and return the Keel app URL.The same instructions are also published at /.well-known/agents.md for clients that discover agent manifests from well-known paths.
One Python package. One Keel command.
Claude Code and Codex are the fastest starting points. Cursor, Windsurf, and other MCP clients use the same Keel command under their own config format.
Claude Code
Install Keel, register it with Claude Code, then ask Claude to connect.
pipx install keel-trade
claude mcp add keel -- keel mcp serve
Prompt: Connect to Keel.Codex
Install Keel, register the server with Codex, then run Codex in your project.
pipx install keel-trade
codex mcp add keel -- keel mcp serve
Prompt: Read AGENTS.md and connect to Keel.Cursor
Add the command to your project or user-level Cursor MCP config.
pipx install keel-trade
// .cursor/mcp.json
{
"mcpServers": {
"keel": {
"command": "keel",
"args": ["mcp", "serve"]
}
}
}Windsurf and generic MCP clients
Use the same command and args wherever your MCP host accepts a local Keel server.
pipx install keel-trade
command: keel
args: ["mcp", "serve"]The strategy operating system
Agents can build and backtest through MCP, but the Keel app is where you review the strategy, inspect results, and control live automation.
Build your strategy, block by block
Drag and drop components to design your strategy — data sources, indicators, risk controls, execution. Configure parameters, rearrange blocks, and see the full pipeline at a glance.
AI that works inside your strategy
Describe what you want to trade and AI creates the strategy — same blocks, same builder. Edit what it made, ask it to adjust, or have it backtest and walk you through the results. Full context, always.
Test before you trade
Backtest multi-asset portfolios with real fees, slippage, and funding rates. What you test is what goes live — the same strategy runs in backtest and production.
Go live on Hyperliquid
Deploy with one click. 24/7 execution with real-time P&L, position tracking, and trade logs. Non-custodial — your keys never leave your wallet. Pause anytime.
The right feedback loop for agents: read, compose, backtest, return the app URL.
Keel is not an agent that picks trades. It is the strategy engine your agent can drive while staying inside typed schemas, deterministic evidence, and explicit live safety gates.
Read Keel instructions
Start from AGENTS.md so the client understands setup, safe toolsets, strict schemas, and the backtest-first workflow.
AGENTS.mdkeel_statuskeel_auth_login
Discover valid components
Search the typed component catalog and fetch exact schemas before composing. The agent should not invent indicators, slots, or parameters.
keel_components_searchkeel_components_detail_batch
Compose and validate
Generate a strategy through the Keel DSL, dry-run it, save the strategy, and preserve diffs so humans can review the changes.
keel_strategy_composekeel_strategy_diffkeel_strategy_get
Run the evidence
Kick off the backtest, wait for completion with the watch helper, summarize the result, and return the Keel app URL.
keel_backtest_runkeel_backtest_watchkeel_backtest_summarize
Review in the app
Open the result in Keel, inspect trades and exposures, compare versions, and create a public share link only when explicitly requested.
Keel app URLresult resourcekeel_share_create
Most trading MCPs expose an API. Keel exposes a research workflow.
The useful agent surface is not raw order placement. It is typed strategy composition, deterministic evidence, app review, and explicit live safety.
They expose market data and order endpoints. The agent can fetch funding or place an order, but it still has no strategy proof, portfolio simulator, or app-level audit trail.
Keel gives agents a strategy-building workflow: typed composition, validation, backtests, and a full Keel result view before anything moves toward live execution.
They keep the model in the trade loop. That makes every prompt, tool call, and context mistake part of execution risk.
With Keel, the agent helps build and test the strategy. Keel runs the approved strategy, and live automation requires explicit user permission.
A one-off script can look convincing while missing funding accrual, fee schedules, slippage, version history, and backtest-to-live parity.
Keel keeps the agent inside the same typed component system the web app uses, so research, review, and live handoff share one engine.
Under the hood
Structured strategy engine
Strategies are composable pipelines of typed components. The system validates every connection at edit time — errors caught before you backtest, not after you deploy.
AI built on the same system
AI doesn’t generate code — it composes from the same components you use. It understands valid connections, constraints, and trade-offs. Every strategy it builds is structurally valid.
Detailed backtest reports
Sharpe, Sortino, max drawdown, win rate, trade-by-trade logs. Compare runs side by side. Real fee and slippage modeling.
Version control for strategies
Every edit creates a new version. Compare any two versions side by side. Tag releases, restore previous versions, fork strategies. Your full history, always recoverable.
Auditable execution logs
Every live run is logged — what the strategy calculated, what orders executed, what filled. Full transparency.
Non-custodial by design
Your keys never touch our servers. Keel uses Hyperliquid’s native delegation. Sign once, revoke anytime.
Agents should return evidence you can inspect.
A good run ends with a Keel app URL, not a wall of unverifiable numbers. Open the result, inspect funding attribution, exposure, trades, and versions, and only share publicly when you ask for a share link.
Funding-carry on Hyperliquid perps
A funding-carry strategy composed through Keel, run against real Hyperliquid funding and price history, then returned as an app result. Period: 2024-08-15 - 2026-04-30 (20 months).
Verified Keel backtest. Past performance is not indicative of future returns.
Strict tools and resources, grouped around the research workflow.
Agents should use tools/list and the generated schema as source of truth. The public docs mirror the implementation, but active schemas always win inside the client.
Status and auth
Start sessions, confirm auth, and diagnose local setup.
keel_statuskeel_auth_loginkeel_doctorkeel_help
Components
Ground the agent in the current typed component catalog.
keel_components_searchkeel_components_detail_batchkeel_components_compose_help
Strategy lifecycle
Compose, fork, diff, inspect, version, and synchronize strategies.
keel_strategy_composekeel_strategy_forkkeel_strategy_diffkeel_strategy_getkeel_strategy_searchkeel_strategy_push
Backtest and audit
Run deterministic evidence, wait for completion, and summarize results.
keel_backtest_runkeel_backtest_watchkeel_backtest_summarizekeel_audit_list_last
Read and share
Inspect accounts, monitor live state read-only, and create public links on request.
keel_accounts_listkeel_live_monitorkeel_share_create
Live write, opt-in
Deploy or control a compiled strategy only after explicit permission gates.
keel_live_deploykeel_live_control
keel://components/catalogCurrent component registry with types, slots, and parameter schemas.
keel://components/{name}/schemaExact schema and examples for one component.
keel://strategy/{strategy_id}/sourceStrategy source for app and CLI parity.
keel://strategy/{strategy_id}/lockfileCompiled lockfile for the saved strategy.
keel://backtest/{backtest_id}/resultsCompleted backtest payload for agent summaries.
keel://backtest/latestLatest org backtest pointer with status and app URL.
What agents and humans need to know
What is the Keel MCP, exactly?
Keel MCP is the keel mcp serve command in the keel-trade Python package. Agent hosts launch it as a local stdio child process and call Keel tools for component search, strategy composition, backtesting, app handoff, sharing, account reads, and gated live operations.
Does stdio mean I need to start a local service?
No. Stdio MCP means Claude Code, Codex, Cursor, Windsurf, or another host starts keel mcp serve when it needs tools and communicates over stdin/stdout. There is no port to expose, no daemon to keep alive, and no separate local web service to manage.
Is there a hosted or remote MCP endpoint?
No. The supported MCP surface today is local stdio. That keeps tool calls close to the user workspace, local files, project context, and cached CLI auth. The Keel web app is still where humans review strategy state, backtests, and live execution.
Which agent clients should I use first?
Claude Code and Codex are the primary quick-start paths because they work cleanly with local stdio MCP. Cursor, Windsurf, and generic MCP clients use the same keel mcp serve command with their own config formats.
Does the agent trade my account?
No. The agent composes a strategy and runs research workflows. Live trading is performed by the compiled Keel strategy, not by the LLM. The agent is not in the execution loop.
What live access is available over MCP?
The default tool surface includes read-only live monitoring with keel_live_monitor. Live mutation tools such as keel_live_deploy and keel_live_control require opting into the live-write toolset, OAuth live scope, local arming for the account, a preview call, and then an explicit deploy or control call.
Why does the MCP page send me into the Keel app?
Agents are good at setup, component search, composition, and iteration. Humans still need the app for visual review: the equity curve, exposure, funding attribution, trades, versions, share links, and live status.