Skip to main content
Glama
janorium-mcp

janorium-mcp

Official

Finalize: the one holdout run

campaign_finalize
Destructive

Spend a campaign's holdout once to obtain final holdout metrics and the Deflated Sharpe ratio; finalization is blocked until required robustness checks have run.

Instructions

Spends the holdout, once. The candidate (a saved strategy version) must already be in the ledger and — unless the server runs with --no-robustness-gate — have a START_DATE_SHIFT batch, a randomizedEntry dry-run and a backtest_monte_carlo on this exact config (ROBUSTNESS_MISSING otherwise); no attempt may still be running (TRIALS_PENDING). Runs the holdout backtest over [holdoutFrom, to] on symbols × timeframes and an in-sample dry-run for the DSR inputs, then returns the holdout metrics and the Deflated Sharpe over the campaign's trial count. A second call answers 409 CAMPAIGN_FINALIZED. If the runs outlast timeoutSec the answer says RUNNING and campaign_status completes it.

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "strategyId": "<strategyId>"
    },
    "name": "campaign_finalize"
  }
}

Input Schema

NameRequiredDescriptionDefault
campaignIdNo
strategyIdYes
timeoutSecNo
strategyVersionNoDefault: the current version.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

A4.8/5.0
Behavior5/5

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

Annotations already declare destructive=true and idempotent=false, and the description reinforces this with "Spends the holdout, once" and the 409 on a repeat call, so the one-shot irreversible nature is explicit. Beyond that it discloses the gate bypass flag (--no-robustness-gate), the async timeout behaviour (RUNNING after timeoutSec), and what the run actually computes (holdout backtest plus in-sample dry-run for DSR inputs).

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

Conciseness4/5

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

The core action is front-loaded in five words, followed by preconditions, execution, and failure modes in a logical order. The dense parenthetical of gate requirements and the all-caps error tokens make it heavy to read, but nearly every clause carries decision-relevant 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?

For a destructive, non-idempotent, potentially long-running tool with no output schema, the definition covers prerequisites, what is returned (holdout metrics and Deflated Sharpe over the campaign trial count), the async fallback, and the repeat-call rejection. Nothing an agent needs to invoke it safely is missing.

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?

With only 25% schema description coverage the description must carry weight, and it does: strategyVersion is characterized as "the candidate (a saved strategy version)" that must exist in the ledger, and timeoutSec semantics (RUNNING when the runs outlast it) are stated. campaignId is left unexplained, which is the main remaining gap.

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?

"Spends the holdout, once" names a specific, unambiguous action and resource, and the description distinguishes it from campaign_status (which completes an unfinished run) and from the prerequisite backtest tools it enumerates. An agent can tell exactly what this tool does without opening the schema.

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?

It gives explicit preconditions (candidate in ledger, plus START_DATE_SHIFT batch, randomizedEntry dry-run and backtest_monte_carlo on this exact config) and names the failure codes when unmet (ROBUSTNESS_MISSING, TRIALS_PENDING). It also routes the agent to campaign_status when the answer is RUNNING, and states that a second call yields 409 CAMPAIGN_FINALIZED.

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