Skip to main content
Glama
sablier-ai

Sablier MCP Server

Official
by sablier-ai

backtest_rules

Read-only

Run historical backtests of trading rules on real market data to evaluate performance, monthly returns, drawdown, turnover, and transaction costs.

Instructions

Run a historical backtest of trading rules on REAL market data — not simulated FLOW paths. Tests how rules would have performed over a historical period. Returns same structure as forward_test_rules (base vs combined vs per-rule attribution) PLUS monthly returns table, drawdown series, turnover stats, and transaction cost analysis. Prerequisites: create rules with create_rule (and activate them). Transaction costs: configurable (default 10bps per trade). Warmup period (default 252 days) pre-fills indicator state before the test period starts. For forward-looking testing on synthetic FLOW paths, use forward_test_rules instead.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
cost_bpsNoTransaction cost in basis points per trade (default 10.0)
end_dateNoEnd date (YYYY-MM-DD). Defaults to latest available data.
rule_idsNoSpecific rule UUIDs. Omit to test all active rules.
start_dateYesBacktest start date (YYYY-MM-DD). E.g. '2020-01-01' for a COVID-era test.
warmup_daysNoDays of history before start_date for indicator seeding (default 252 = ~1 year)
portfolio_idYesPortfolio UUID

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
resultYes
Behavior4/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Annotations already declare readOnlyHint=true and openWorldHint=true, so the safety profile is known. The description adds valuable context beyond annotations: warmup period behavior, transaction cost defaults, output structure (base vs combined vs per-rule attribution plus monthly returns, drawdown, turnover, cost analysis), and the contrast with simulated FLOW paths. This is substantive and non-redundant.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is four sentences, front-loaded with the main purpose, and each sentence earns its place: purpose + distinction, output summary, prerequisites, and alternative tool. No fluff or redundant information.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness5/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Despite having an output schema (which relieves the description of explaining every return field), the description provides a useful high-level overview of the return structure and unique additions (monthly returns, drawdown, turnover, costs). It also covers prerequisites, defaults, and sibling differentiation, making it complete for a tool of this complexity.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters4/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema coverage is 100%, so parameters are individually described. The description adds meaning by explaining the warmup period ('pre-fills indicator state before the test period starts') and the default transaction cost (10bps), which clarifies the purpose of cost_bps and warmup_days beyond the schema descriptions. It also gives an example date format for start_date.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description clearly states the tool runs a historical backtest of trading rules on real market data, explicitly contrasting with simulated FLOW paths. It specifies the verb (run a historical backtest) and resource (trading rules), and differentiates from forward_test_rules by mentioning the historical context and output differences.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines5/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

Provides explicit prerequisites (create and activate rules via create_rule) and gives a clear alternative for forward-looking tests on synthetic paths ('use forward_test_rules instead'). This tells the agent exactly when to use this tool and when not to, with a named sibling.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/sablier-ai/sablier-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server