Premiss
Create Python strategies and backtest crypto, stocks and ETFs in Claude. Premiss account required.
使うべきか
品質と安全性
検出事項(1)
- LOWdescribe_market 内
ツール定義とプロトコルへの準拠に関する自動分析に基づいています。
コンテキストコスト
これは、サーバーのツールがモデルのコンテキストに読み込まれるたびに消費されるおおよそのトークン数です。数が多いほど、ほかのタスクに使える注意が減ります。
インストール
ワンクリックインストール
これを `claude_desktop_config.json` ファイルに追加してください:
{
"mcpServers": {
"premiss": {
"url": "https://app.premissai.com/api/mcp/claude"
}
}
}リモートエンドポイント
https://app.premissai.com/api/mcp/claudestreamable-httpできること
ツール一覧
ツール(13)
🟢get_capabilities
Read this connection's available tools and supported research coverage. Does not read account data, save research, or run a simulation.
入力スキーマ
{
"type": "object",
"properties": {},
"$schema": "https://json-schema.org/draft/2020-12/schema",
"additionalProperties": false
}出力スキーマ
{
"type": "object",
"properties": {
"schema_version": {
"type": "number",
"const": 2
},
"release_stage": {
"type": "string",
"enum": [
"transport_prototype",
"research"
]
},
"available_tools": {
"type": "array",
"items": {
"type": "string"
}
},
"available": {
"type": "object",
"properties": {
"account_linking": {
"type": "boolean"
},
"historical_simulations": {
"type": "boolean"
},
"saved_research": {
"type": "boolean"
},
"paper_reports": {
"type": "boolean"
}
},
"required": [
"account_linking",
"historical_simulations",
"saved_research",
"paper_reports"
],
"additionalProperties": false
},
"research_scope": {
"type": "object",
"properties": {
"markets": {
"type": "array",
"items": {
"type": "string"
}
},
"intervals": {
"type": "array",
"items": {
"type": "string"
}
},
"exposure": {
"type": "string",
"const": "long_short_or_flat"
},
"custom_python": {
"type": "boolean",
"const": true
},
"equity_intervals": {
"type": "array",
"items": {
"type": "string"
}
},
"market_discovery_tool": {
"type": "string",
"const": "search_markets"
},
"template_shortcuts": {
"type": "array",
"items": {
"type": "string",
"enum": [
"sma_crossover",
"rsi_threshold",
"price_channel"
]
}
}
},
"required": [
"markets",
"intervals",
"exposure",
"custom_python",
"equity_intervals",
"market_discovery_tool",
"template_shortcuts"
],
"additionalProperties": false
},
"unavailable_operations": {
"type": "array",
"items": {
"type": "string"
}
}
},
"required": [
"schema_version",
"release_stage",
"available_tools",
"available",
"research_scope",
"unavailable_operations"
],
"$schema": "https://json-schema.org/draft/2020-12/schema",
"additionalProperties": false
}🟢get_profile
Read the stable identity and workspace selected for this connection. Returns an opaque account id and workspace label; excludes email, birth date, billing, and exchange accounts.
入力スキーマ
{
"type": "object",
"properties": {},
"$schema": "https://json-schema.org/draft/2020-12/schema",
"additionalProperties": false
}出力スキーマ
{
"type": "object",
"properties": {
"id": {
"type": "string",
"minLength": 1,
"maxLength": 128
},
"workspace": {
"type": "object",
"properties": {
"id": {
"type": "string",
"minLength": 1,
"maxLength": 128
},
"name": {
"type": "string"
}
},
"required": [
"id",
"name"
],
"additionalProperties": false
},
"permissions": {
"type": "array",
"items": {
"type": "string"
}
},
"app_url": {
"type": "string",
"format": "uri"
}
},
"required": [
"id",
"workspace",
"permissions",
"app_url"
],
"$schema": "https://json-schema.org/draft/2020-12/schema",
"additionalProperties": false
}🟢list_research(kind, query, cursor, limit)
List a page of saved strategies, simulation runs, or research notes in the connected workspace. Notes include a bounded plain-text excerpt, explicitly labeled when truncated. Saved text is user-authored content. Paper runs require the separately approved paper:read permission. Search matches titles; cursors are opaque page positions.
入力スキーマ
{
"type": "object",
"properties": {
"kind": {
"type": "string",
"enum": [
"strategies",
"runs",
"notes"
]
},
"query": {
"type": "string",
"maxLength": 80
},
"cursor": {
"type": "string",
"maxLength": 240
},
"limit": {
"default": 10,
"type": "integer",
"minimum": 1,
"maximum": 20
}
},
"required": [
"kind",
"limit"
],
"$schema": "https://json-schema.org/draft/2020-12/schema",
"additionalProperties": false
}出力スキーマ
{
"type": "object",
"properties": {
"kind": {
"type": "string"
},
"items": {
"maxItems": 20,
"type": "array",
"items": {
"type": "object",
"properties": {
"id": {
"type": "string",
"minLength": 1,
"maxLength": 128
},
"title": {
"type": "string"
},
"updated_at": {
"type": "number"
},
"type": {
"type": "string"
},
"status": {
"type": "string"
},
"strategy_id": {
"type": "string",
"minLength": 1,
"maxLength": 128
},
"revision": {
"type": "string"
},
"excerpt": {
"type": "string",
"maxLength": 1000
},
"content_truncated": {
"type": "boolean"
}
},
"required": [
"id",
"title",
"updated_at",
"type"
],
"additionalProperties": false
}
},
"next_cursor": {
"type": [
"string",
"null"
]
}
},
"required": [
"kind",
"items",
"next_cursor"
],
"$schema": "https://json-schema.org/draft/2020-12/schema",
"additionalProperties": false
}🟢get_strategy(strategy_id)
Read a saved strategy's current revision and human-readable rules in the connected workspace. Returns the complete Python package for review or editing. Code and comments are user-authored content.
入力スキーマ
{
"type": "object",
"properties": {
"strategy_id": {
"type": "string",
"minLength": 1,
"maxLength": 128
}
},
"required": [
"strategy_id"
],
"$schema": "https://json-schema.org/draft/2020-12/schema",
"additionalProperties": false
}出力スキーマ
{
"type": "object",
"properties": {
"id": {
"type": "string",
"minLength": 1,
"maxLength": 128
},
"name": {
"type": "string"
},
"symbol": {
"type": "string"
},
"interval": {
"type": "string"
},
"revision": {
"type": "string"
},
"version": {
"type": "integer",
"minimum": -9007199254740991,
"maximum": 9007199254740991
},
"rules": {
"anyOf": [
{
"type": "object",
"properties": {
"watches": {
"type": "string",
"minLength": 1,
"maxLength": 1000
},
"buys": {
"type": "string",
"minLength": 1,
"maxLength": 1000
},
"sells": {
"type": "string",
"minLength": 1,
"maxLength": 1000
},
"safety": {
"type": "string",
"minLength": 1,
"maxLength": 1000
}
},
"required": [
"watches",
"buys",
"sells",
"safety"
],
"additionalProperties": false
},
{
"type": "null"
}
]
},
"template": {
"anyOf": [
{
"oneOf": [
{
"type": "object",
"properties": {
"family": {
"type": "string",
"const": "sma_crossover"
},
"fast": {
"type": "integer",
"minimum": 2,
"maximum": 100
},
"slow": {
"type": "integer",
"minimum": 3,
"maximum": 300
}
},
"required": [
"family",
"fast",
"slow"
],
"additionalProperties": false
},
{
"type": "object",
"properties": {
"family": {
"type": "string",
"const": "rsi_threshold"
},
"period": {
"type": "integer",
"minimum": 2,
"maximum": 100
},
"enter_below": {
"type": "number",
"minimum": 5,
"maximum": 45
},
"exit_above": {
"type": "number",
"minimum": 55,
"maximum": 95
}
},
"required": [
"family",
"period",
"enter_below",
"exit_above"
],
"additionalProperties": false
},
{
"type": "object",
"properties": {
"family": {
"type": "string",
"const": "price_channel"
},
"entry_bars": {
"type": "integer",
"minimum": 2,
"maximum": 300
},
"exit_bars": {
"type": "integer",
"minimum": 2,
"maximum": 300
}
},
"required": [
"family",
"entry_bars",
"exit_bars"
],
"additionalProperties": false
}
]
},
{
"type": "null"
}
]
},
"files": {
"minItems": 1,
"maxItems": 16,
"type": "array",
"items": {
"type": "object",
"properties": {
"path": {
"type": "string",
"minLength": 1,
"maxLength": 1024
},
"content": {
"type": "string",
"maxLength": 65536
}
},
"required": [
"path",
"content"
],
"additionalProperties": false
}
},
"venue": {
"type": "string"
},
"app_url": {
"type": "string",
"format": "uri"
}
},
"required": [
"id",
"name",
"symbol",
"interval",
"revision",
"version",
"rules",
"template",
"app_url"
],
"$schema": "https://json-schema.org/draft/2020-12/schema",
"additionalProperties": false
}🟢search_markets(query, asset_class, limit)
Search the same crypto, stock and ETF directory as Premiss. Does not return prices or candles.
入力スキーマ
{
"type": "object",
"properties": {
"query": {
"default": "",
"type": "string",
"maxLength": 120
},
"asset_class": {
"type": "string",
"enum": [
"crypto",
"stock",
"etf"
]
},
"limit": {
"default": 20,
"type": "integer",
"minimum": 1,
"maximum": 50
}
},
"required": [
"query",
"limit"
],
"$schema": "https://json-schema.org/draft/2020-12/schema",
"additionalProperties": false
}出力スキーマ
{
"type": "object",
"properties": {
"markets": {
"type": "array",
"items": {
"type": "object",
"properties": {
"market": {
"type": "string"
},
"symbol": {
"type": "string"
},
"name": {
"type": "string"
},
"assetClass": {
"type": "string",
"enum": [
"crypto",
"stock",
"etf"
]
},
"exchange": {
"type": "string"
},
"currency": {
"type": "string"
},
"active": {
"type": "boolean"
}
},
"required": [
"market",
"symbol",
"name",
"assetClass",
"exchange",
"currency",
"active"
],
"additionalProperties": false
}
}
},
"required": [
"markets"
],
"$schema": "https://json-schema.org/draft/2020-12/schema",
"additionalProperties": false
}🟢describe_market(market)
Return supported timeframes, available history and data limitations for a market id.
入力スキーマ
{
"type": "object",
"properties": {
"market": {
"type": "string",
"minLength": 1,
"maxLength": 128
}
},
"required": [
"market"
],
"$schema": "https://json-schema.org/draft/2020-12/schema",
"additionalProperties": false
}出力スキーマ
{
"type": "object",
"properties": {
"market": {
"type": "string"
},
"symbol": {
"type": "string"
},
"name": {
"type": "string"
},
"assetClass": {
"type": "string",
"enum": [
"crypto",
"stock",
"etf"
]
},
"exchange": {
"type": "string"
},
"currency": {
"type": "string"
},
"active": {
"type": "boolean"
},
"intervals": {
"type": "array",
"items": {
"type": "string"
}
},
"availableFrom": {
"type": [
"string",
"null"
]
},
"availableTo": {
"type": [
"string",
"null"
]
},
"availability": {
"type": "array",
"items": {
"type": "object",
"properties": {
"intervals": {
"type": "array",
"items": {
"type": "string"
}
},
"availableFrom": {
"type": [
"string",
"null"
]
},
"availableTo": {
"type": [
"string",
"null"
]
}
},
"required": [
"intervals",
"availableFrom",
"availableTo"
],
"additionalProperties": false
}
},
"notes": {
"type": "array",
"items": {
"type": "string"
}
}
},
"required": [
"market",
"symbol",
"name",
"assetClass",
"exchange",
"currency",
"active",
"intervals",
"availableFrom",
"availableTo",
"availability",
"notes"
],
"$schema": "https://json-schema.org/draft/2020-12/schema",
"additionalProperties": false
}🟢get_strategy_guide
Read Premiss's Python package format, on_bar API, execution semantics and example. Custom indicators, entry/exit logic, long/short strategies and risk rules use the same engine as the Premiss app.
入力スキーマ
{
"type": "object",
"properties": {},
"$schema": "https://json-schema.org/draft/2020-12/schema",
"additionalProperties": false
}出力スキーマ
{
"type": "object",
"properties": {
"guide": {
"type": "string"
}
},
"required": [
"guide"
],
"$schema": "https://json-schema.org/draft/2020-12/schema",
"additionalProperties": false
}🟡create_strategy(request_key, name, symbol, interval, files, ...)
Save a new private strategy using custom Python files and complete rules text, on any Premiss-supported market and timeframe. Accepts either files (strategy.py plus helper modules) and rules, or a convenience template. Uses the same package format as the app. Returns code and revision; saving does not run a backtest.
入力スキーマ
{
"type": "object",
"properties": {
"request_key": {
"type": "string",
"format": "uuid",
"pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$",
"description": "Idempotency UUID identifying one requested write and its unchanged arguments."
},
"name": {
"type": "string",
"minLength": 1,
"maxLength": 120
},
"symbol": {
"type": "string",
"minLength": 1,
"maxLength": 20
},
"interval": {
"type": "string",
"enum": [
"1m",
"3m",
"5m",
"15m",
"30m",
"1h",
"2h",
"4h",
"6h",
"8h",
"12h",
"1d",
"3d",
"1w",
"1M"
]
},
"files": {
"minItems": 1,
"maxItems": 16,
"type": "array",
"items": {
"type": "object",
"properties": {
"path": {
"type": "string",
"minLength": 1,
"maxLength": 1024
},
"content": {
"type": "string",
"maxLength": 65536
}
},
"required": [
"path",
"content"
],
"additionalProperties": false
}
},
"rules": {
"type": "object",
"properties": {
"watches": {
"type": "string",
"minLength": 1,
"maxLength": 1000
},
"buys": {
"type": "string",
"minLength": 1,
"maxLength": 1000
},
"sells": {
"type": "string",
"minLength": 1,
"maxLength": 1000
},
"safety": {
"type": "string",
"minLength": 1,
"maxLength": 1000
}
},
"required": [
"watches",
"buys",
"sells",
"safety"
],
"additionalProperties": false
},
"template": {
"oneOf": [
{
"type": "object",
"properties": {
"family": {
"type": "string",
"const": "sma_crossover"
},
"fast": {
"type": "integer",
"minimum": 2,
"maximum": 100
},
"slow": {
"type": "integer",
"minimum": 3,
"maximum": 300
}
},
"required": [
"family",
"fast",
"slow"
],
"additionalProperties": false
},
{
"type": "object",
"properties": {
"family": {
"type": "string",
"const": "rsi_threshold"
},
"period": {
"type": "integer",
"minimum": 2,
"maximum": 100
},
"enter_below": {
"type": "number",
"minimum": 5,
"maximum": 45
},
"exit_above": {
"type": "number",
"minimum": 55,
"maximum": 95
}
},
"required": [
"family",
"period",
"enter_below",
"exit_above"
],
"additionalProperties": false
},
{
"type": "object",
"properties": {
"family": {
"type": "string",
"const": "price_channel"
},
"entry_bars": {
"type": "integer",
"minimum": 2,
"maximum": 300
},
"exit_bars": {
"type": "integer",
"minimum": 2,
"maximum": 300
}
},
"required": [
"family",
"entry_bars",
"exit_bars"
],
"additionalProperties": false
}
]
}
},
"required": [
"request_key",
"name",
"symbol",
"interval"
],
"$schema": "https://json-schema.org/draft/2020-12/schema",
"additionalProperties": false
}出力スキーマ
{
"type": "object",
"properties": {
"id": {
"type": "string",
"minLength": 1,
"maxLength": 128
},
"name": {
"type": "string"
},
"symbol": {
"type": "string"
},
"interval": {
"type": "string"
},
"revision": {
"type": "string"
},
"version": {
"type": "integer",
"minimum": -9007199254740991,
"maximum": 9007199254740991
},
"rules": {
"anyOf": [
{
"type": "object",
"properties": {
"watches": {
"type": "string",
"minLength": 1,
"maxLength": 1000
},
"buys": {
"type": "string",
"minLength": 1,
"maxLength": 1000
},
"sells": {
"type": "string",
"minLength": 1,
"maxLength": 1000
},
"safety": {
"type": "string",
"minLength": 1,
"maxLength": 1000
}
},
"required": [
"watches",
"buys",
"sells",
"safety"
],
"additionalProperties": false
},
{
"type": "null"
}
]
},
"template": {
"anyOf": [
{
"oneOf": [
{
"type": "object",
"properties": {
"family": {
"type": "string",
"const": "sma_crossover"
},
"fast": {
"type": "integer",
"minimum": 2,
"maximum": 100
},
"slow": {
"type": "integer",
"minimum": 3,
"maximum": 300
}
},
"required": [
"family",
"fast",
"slow"
],
"additionalProperties": false
},
{
"type": "object",
"properties": {
"family": {
"type": "string",
"const": "rsi_threshold"
},
"period": {
"type": "integer",
"minimum": 2,
"maximum": 100
},
"enter_below": {
"type": "number",
"minimum": 5,
"maximum": 45
},
"exit_above": {
"type": "number",
"minimum": 55,
"maximum": 95
}
},
"required": [
"family",
"period",
"enter_below",
"exit_above"
],
"additionalProperties": false
},
{
"type": "object",
"properties": {
"family": {
"type": "string",
"const": "price_channel"
},
"entry_bars": {
"type": "integer",
"minimum": 2,
"maximum": 300
},
"exit_bars": {
"type": "integer",
"minimum": 2,
"maximum": 300
}
},
"required": [
"family",
"entry_bars",
"exit_bars"
],
"additionalProperties": false
}
]
},
{
"type": "null"
}
]
},
"files": {
"minItems": 1,
"maxItems": 16,
"type": "array",
"items": {
"type": "object",
"properties": {
"path": {
"type": "string",
"minLength": 1,
"maxLength": 1024
},
"content": {
"type": "string",
"maxLength": 65536
}
},
"required": [
"path",
"content"
],
"additionalProperties": false
}
},
"venue": {
"type": "string"
},
"app_url": {
"type": "string",
"format": "uri"
}
},
"required": [
"id",
"name",
"symbol",
"interval",
"revision",
"version",
"rules",
"template",
"app_url"
],
"$schema": "https://json-schema.org/draft/2020-12/schema",
"additionalProperties": false
}🔴update_strategy(request_key, strategy_id, revision, symbol, interval, ...)
Replace the complete Python package and rules of an existing strategy using its exact current saved revision. The submitted package replaces all existing files. Supports all Premiss markets and timeframes. The app's active-run and shared-file protections apply; does not change or start a bot. Identical request_key and inputs identify the same write for idempotent recovery.
入力スキーマ
{
"type": "object",
"properties": {
"request_key": {
"type": "string",
"format": "uuid",
"pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$",
"description": "Idempotency UUID identifying one requested write and its unchanged arguments."
},
"strategy_id": {
"type": "string",
"minLength": 1,
"maxLength": 128
},
"revision": {
"type": "string",
"minLength": 1,
"maxLength": 128
},
"symbol": {
"type": "string",
"minLength": 1,
"maxLength": 20
},
"interval": {
"type": "string",
"enum": [
"1m",
"3m",
"5m",
"15m",
"30m",
"1h",
"2h",
"4h",
"6h",
"8h",
"12h",
"1d",
"3d",
"1w",
"1M"
]
},
"files": {
"minItems": 1,
"maxItems": 16,
"type": "array",
"items": {
"type": "object",
"properties": {
"path": {
"type": "string",
"minLength": 1,
"maxLength": 1024
},
"content": {
"type": "string",
"maxLength": 65536
}
},
"required": [
"path",
"content"
],
"additionalProperties": false
}
},
"rules": {
"type": "object",
"properties": {
"watches": {
"type": "string",
"minLength": 1,
"maxLength": 1000
},
"buys": {
"type": "string",
"minLength": 1,
"maxLength": 1000
},
"sells": {
"type": "string",
"minLength": 1,
"maxLength": 1000
},
"safety": {
"type": "string",
"minLength": 1,
"maxLength": 1000
}
},
"required": [
"watches",
"buys",
"sells",
"safety"
],
"additionalProperties": false
}
},
"required": [
"request_key",
"strategy_id",
"revision",
"symbol",
"interval",
"files",
"rules"
],
"$schema": "https://json-schema.org/draft/2020-12/schema",
"additionalProperties": false
}出力スキーマ
{
"type": "object",
"properties": {
"id": {
"type": "string",
"minLength": 1,
"maxLength": 128
},
"name": {
"type": "string"
},
"symbol": {
"type": "string"
},
"interval": {
"type": "string"
},
"revision": {
"type": "string"
},
"version": {
"type": "integer",
"minimum": -9007199254740991,
"maximum": 9007199254740991
},
"rules": {
"anyOf": [
{
"type": "object",
"properties": {
"watches": {
"type": "string",
"minLength": 1,
"maxLength": 1000
},
"buys": {
"type": "string",
"minLength": 1,
"maxLength": 1000
},
"sells": {
"type": "string",
"minLength": 1,
"maxLength": 1000
},
"safety": {
"type": "string",
"minLength": 1,
"maxLength": 1000
}
},
"required": [
"watches",
"buys",
"sells",
"safety"
],
"additionalProperties": false
},
{
"type": "null"
}
]
},
"template": {
"anyOf": [
{
"oneOf": [
{
"type": "object",
"properties": {
"family": {
"type": "string",
"const": "sma_crossover"
},
"fast": {
"type": "integer",
"minimum": 2,
"maximum": 100
},
"slow": {
"type": "integer",
"minimum": 3,
"maximum": 300
}
},
"required": [
"family",
"fast",
"slow"
],
"additionalProperties": false
},
{
"type": "object",
"properties": {
"family": {
"type": "string",
"const": "rsi_threshold"
},
"period": {
"type": "integer",
"minimum": 2,
"maximum": 100
},
"enter_below": {
"type": "number",
"minimum": 5,
"maximum": 45
},
"exit_above": {
"type": "number",
"minimum": 55,
"maximum": 95
}
},
"required": [
"family",
"period",
"enter_below",
"exit_above"
],
"additionalProperties": false
},
{
"type": "object",
"properties": {
"family": {
"type": "string",
"const": "price_channel"
},
"entry_bars": {
"type": "integer",
"minimum": 2,
"maximum": 300
},
"exit_bars": {
"type": "integer",
"minimum": 2,
"maximum": 300
}
},
"required": [
"family",
"entry_bars",
"exit_bars"
],
"additionalProperties": false
}
]
},
{
"type": "null"
}
]
},
"files": {
"minItems": 1,
"maxItems": 16,
"type": "array",
"items": {
"type": "object",
"properties": {
"path": {
"type": "string",
"minLength": 1,
"maxLength": 1024
},
"content": {
"type": "string",
"maxLength": 65536
}
},
"required": [
"path",
"content"
],
"additionalProperties": false
}
},
"venue": {
"type": "string"
},
"app_url": {
"type": "string",
"format": "uri"
}
},
"required": [
"id",
"name",
"symbol",
"interval",
"revision",
"version",
"rules",
"template",
"app_url"
],
"$schema": "https://json-schema.org/draft/2020-12/schema",
"additionalProperties": false
}⚪start_backtest(request_key, strategy_id, revision, start_date, end_date)
Queue a backtest of any saved strategy in the connected workspace and a matched buy-and-hold baseline. Accepts custom code and existing app strategies. Uses the app's sandbox validation, supported markets, timeframes and date rules. Requires the exact saved revision. Uses 10,000 simulated capital, 10 bps fees, 1 bp slippage and next-bar-open fills. No plugin-only daily test or history caps. Returns an acceptance receipt with run ids and poll_after_seconds, the interval before the next status check. Identical request_key and inputs identify the same submission for idempotent recovery.
入力スキーマ
{
"type": "object",
"properties": {
"request_key": {
"type": "string",
"format": "uuid",
"pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$",
"description": "Idempotency UUID identifying one requested write and its unchanged arguments."
},
"strategy_id": {
"type": "string",
"minLength": 1,
"maxLength": 128
},
"revision": {
"type": "string",
"minLength": 1,
"maxLength": 128
},
"start_date": {
"type": "string",
"format": "date",
"pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))$"
},
"end_date": {
"type": "string",
"format": "date",
"pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))$"
}
},
"required": [
"request_key",
"strategy_id",
"revision",
"start_date"
],
"$schema": "https://json-schema.org/draft/2020-12/schema",
"additionalProperties": false
}出力スキーマ
{
"type": "object",
"properties": {
"run_id": {
"type": "string",
"minLength": 1,
"maxLength": 128
},
"baseline_run_id": {
"type": "string",
"minLength": 1,
"maxLength": 128
},
"strategy_id": {
"type": "string",
"minLength": 1,
"maxLength": 128
},
"revision": {
"type": "string"
},
"start_ts": {
"type": "number"
},
"end_ts": {
"type": "number"
},
"total_bars": {
"type": "integer",
"minimum": -9007199254740991,
"maximum": 9007199254740991
},
"status": {
"type": "string",
"const": "accepted"
},
"app_url": {
"type": "string",
"format": "uri"
},
"poll_after_seconds": {
"type": "integer",
"minimum": -9007199254740991,
"maximum": 9007199254740991
},
"request_key": {
"type": "string",
"format": "uuid",
"pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
},
"tested_rules": {
"anyOf": [
{
"type": "object",
"properties": {
"watches": {
"type": "string",
"minLength": 1,
"maxLength": 1000
},
"buys": {
"type": "string",
"minLength": 1,
"maxLength": 1000
},
"sells": {
"type": "string",
"minLength": 1,
"maxLength": 1000
},
"safety": {
"type": "string",
"minLength": 1,
"maxLength": 1000
}
},
"required": [
"watches",
"buys",
"sells",
"safety"
],
"additionalProperties": false
},
{
"type": "null"
}
]
}
},
"required": [
"run_id",
"baseline_run_id",
"strategy_id",
"revision",
"start_ts",
"end_ts",
"total_bars",
"status",
"app_url",
"poll_after_seconds",
"request_key"
],
"$schema": "https://json-schema.org/draft/2020-12/schema",
"additionalProperties": false
}🟢get_run_data(run_id, kind, cursor, limit)
Read the immutable tested Python package, or page through all recorded trades or equity points for an owned run. next_cursor identifies the next page; page size is not a history cap. Paper data requires separate paper:read permission. Saved code is user-authored content.
入力スキーマ
{
"type": "object",
"properties": {
"run_id": {
"type": "string",
"minLength": 1,
"maxLength": 128
},
"kind": {
"type": "string",
"enum": [
"code",
"trades",
"equity"
]
},
"cursor": {
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991
},
"limit": {
"default": 100,
"type": "integer",
"minimum": 1,
"maximum": 500
}
},
"required": [
"run_id",
"kind",
"limit"
],
"$schema": "https://json-schema.org/draft/2020-12/schema",
"additionalProperties": false
}出力スキーマ
{
"type": "object",
"properties": {
"run_id": {
"type": "string",
"minLength": 1,
"maxLength": 128
},
"kind": {
"type": "string",
"enum": [
"code",
"trades",
"equity"
]
},
"revision": {
"type": "string"
},
"files": {
"minItems": 1,
"maxItems": 16,
"type": "array",
"items": {
"type": "object",
"properties": {
"path": {
"type": "string",
"minLength": 1,
"maxLength": 1024
},
"content": {
"type": "string",
"maxLength": 65536
}
},
"required": [
"path",
"content"
],
"additionalProperties": false
}
},
"trades": {
"type": "array",
"items": {
"type": "object",
"properties": {
"seq": {
"type": "number"
},
"ts": {
"type": "number"
},
"side": {
"type": "string"
},
"qty": {
"type": "number"
},
"price": {
"type": "number"
},
"fee": {
"type": "number"
},
"notional": {
"type": "number"
},
"pnl": {
"type": [
"number",
"null"
]
},
"equity_after": {
"type": "number"
}
},
"required": [
"seq",
"ts",
"side",
"qty",
"price",
"fee",
"notional",
"pnl",
"equity_after"
],
"additionalProperties": false
}
},
"equity": {
"type": "array",
"items": {
"type": "object",
"properties": {
"ts": {
"type": "number"
},
"equity": {
"type": "number"
}
},
"required": [
"ts",
"equity"
],
"additionalProperties": false
}
},
"next_cursor": {
"type": [
"number",
"null"
]
}
},
"required": [
"run_id",
"kind",
"revision",
"next_cursor"
],
"$schema": "https://json-schema.org/draft/2020-12/schema",
"additionalProperties": false
}🟢get_run_report(run_id)
Read the status and bounded performance report for one run in the connected workspace. Returns the tested market, interval, revision, and recorded rules when verifiable. Historical plugin runs include the paired buy-and-hold baseline when completed. Paper reads require paper:read and do not start, stop, qualify, or modify a bot. Legacy runs without supported assumptions are labeled. Does not return raw market feeds.
入力スキーマ
{
"type": "object",
"properties": {
"run_id": {
"type": "string",
"minLength": 1,
"maxLength": 128
}
},
"required": [
"run_id"
],
"$schema": "https://json-schema.org/draft/2020-12/schema",
"additionalProperties": false
}出力スキーマ
{
"type": "object",
"properties": {
"run_id": {
"type": "string",
"minLength": 1,
"maxLength": 128
},
"strategy_id": {
"type": "string",
"minLength": 1,
"maxLength": 128
},
"mode": {
"type": "string",
"enum": [
"backtest",
"paper"
]
},
"status": {
"type": "string"
},
"symbol": {
"type": "string"
},
"interval": {
"type": "string"
},
"venue": {
"type": "string"
},
"engine_version": {
"type": "integer",
"minimum": -9007199254740991,
"maximum": 9007199254740991
},
"strategy_version": {
"type": "integer",
"minimum": -9007199254740991,
"maximum": 9007199254740991
},
"tested_rules": {
"anyOf": [
{
"type": "object",
"properties": {
"watches": {
"type": "string",
"minLength": 1,
"maxLength": 1000
},
"buys": {
"type": "string",
"minLength": 1,
"maxLength": 1000
},
"sells": {
"type": "string",
"minLength": 1,
"maxLength": 1000
},
"safety": {
"type": "string",
"minLength": 1,
"maxLength": 1000
}
},
"required": [
"watches",
"buys",
"sells",
"safety"
],
"additionalProperties": false
},
{
"type": "null"
}
]
},
"error": {
"type": [
"string",
"null"
]
},
"revision": {
"type": "string"
},
"start_ts": {
"type": "number"
},
"end_ts": {
"type": [
"number",
"null"
]
},
"last_ts": {
"type": [
"number",
"null"
]
},
"metrics": {
"anyOf": [
{
"type": "object",
"properties": {
"initial_capital": {
"type": "number"
},
"final_equity": {
"type": "number"
},
"total_return_pct": {
"type": "number"
},
"cagr_pct": {
"type": [
"number",
"null"
]
},
"max_drawdown_pct": {
"type": "number"
},
"sharpe": {
"type": [
"number",
"null"
]
},
"num_trades": {
"type": "number"
},
"win_rate_pct": {
"type": [
"number",
"null"
]
},
"profit_factor": {
"type": [
"number",
"null"
]
},
"exposure_pct": {
"type": "number"
},
"bars_processed": {
"type": "number"
},
"first_ts": {
"type": [
"number",
"null"
]
},
"last_ts": {
"type": [
"number",
"null"
]
}
},
"required": [
"initial_capital",
"final_equity",
"total_return_pct",
"cagr_pct",
"max_drawdown_pct",
"sharpe",
"num_trades",
"win_rate_pct",
"profit_factor",
"exposure_pct",
"bars_processed",
"first_ts",
"last_ts"
],
"additionalProperties": false
},
{
"type": "null"
}
]
},
"assumptions": {
"anyOf": [
{
"type": "object",
"properties": {
"version": {
"type": "number",
"const": 1
},
"initial_capital": {
"type": "number",
"const": 10000
},
"fee_bps": {
"type": "number",
"const": 10
},
"slippage_bps": {
"type": "number",
"const": 1
}
},
"required": [
"version",
"initial_capital",
"fee_bps",
"slippage_bps"
],
"additionalProperties": false
},
{
"type": "null"
}
]
},
"baseline": {
"anyOf": [
{
"type": "object",
"properties": {
"run_id": {
"type": "string",
"minLength": 1,
"maxLength": 128
},
"status": {
"type": "string"
},
"metrics": {
"anyOf": [
{
"type": "object",
"properties": {
"initial_capital": {
"type": "number"
},
"final_equity": {
"type": "number"
},
"total_return_pct": {
"type": "number"
},
"cagr_pct": {
"type": [
"number",
"null"
]
},
"max_drawdown_pct": {
"type": "number"
},
"sharpe": {
"type": [
"number",
"null"
]
},
"num_trades": {
"type": "number"
},
"win_rate_pct": {
"type": [
"number",
"null"
]
},
"profit_factor": {
"type": [
"number",
"null"
]
},
"exposure_pct": {
"type": "number"
},
"bars_processed": {
"type": "number"
},
"first_ts": {
"type": [
"number",
"null"
]
},
"last_ts": {
"type": [
"number",
"null"
]
}
},
"required": [
"initial_capital",
"final_equity",
"total_return_pct",
"cagr_pct",
"max_drawdown_pct",
"sharpe",
"num_trades",
"win_rate_pct",
"profit_factor",
"exposure_pct",
"bars_processed",
"first_ts",
"last_ts"
],
"additionalProperties": false
},
{
"type": "null"
}
]
},
"comparable": {
"type": "boolean"
}
},
"required": [
"run_id",
"status",
"metrics",
"comparable"
],
"additionalProperties": false
},
{
"type": "null"
}
]
},
"limitations": {
"type": "array",
"items": {
"type": "string"
}
},
"app_url": {
"type": "string",
"format": "uri"
}
},
"required": [
"run_id",
"strategy_id",
"mode",
"status",
"symbol",
"interval",
"venue",
"engine_version",
"strategy_version",
"tested_rules",
"revision",
"start_ts",
"end_ts",
"last_ts",
"metrics",
"assumptions",
"baseline",
"limitations",
"app_url"
],
"$schema": "https://json-schema.org/draft/2020-12/schema",
"additionalProperties": false
}🟡save_research_note(request_key, title, note, strategy_id, revision, ...)
Save a NEW private note in the connected workspace, with optional exact owned strategy/run evidence references. The note is user-authored content. Does not publish or send it anywhere.
入力スキーマ
{
"type": "object",
"properties": {
"request_key": {
"type": "string",
"format": "uuid",
"pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$",
"description": "Idempotency UUID identifying one requested write and its unchanged arguments."
},
"title": {
"type": "string",
"minLength": 1,
"maxLength": 120
},
"note": {
"type": "string",
"minLength": 1,
"maxLength": 4000
},
"strategy_id": {
"type": "string",
"minLength": 1,
"maxLength": 128
},
"revision": {
"type": "string",
"maxLength": 128
},
"run_id": {
"type": "string",
"minLength": 1,
"maxLength": 128
}
},
"required": [
"request_key",
"title",
"note"
],
"$schema": "https://json-schema.org/draft/2020-12/schema",
"additionalProperties": false
}出力スキーマ
{
"type": "object",
"properties": {
"note_id": {
"type": "string",
"minLength": 1,
"maxLength": 128
},
"title": {
"type": "string"
},
"saved": {
"type": "boolean",
"const": true
},
"app_url": {
"type": "string",
"format": "uri"
}
},
"required": [
"note_id",
"title",
"saved",
"app_url"
],
"$schema": "https://json-schema.org/draft/2020-12/schema",
"additionalProperties": false
}コミュニティ
エビデンス