Skip to main content
Glama

Start Protocol Assignment

protocol.start_assignment

Enroll a subject and prepare their neurofeedback deploy session (confirm-gated — a session runs on a human). Creates the assignment (yoked sham arms REQUIRE yoked_donor_upload_id: a recorded simulated session's upload — mint one by running an active-arm session and data.upload-ing its recording), then persists the protocol graph as a deployable execution. Requires a Pro plan for LIVE hardware sessions; simulated-source sessions (the default template) are free.

Graph source: execution_id reuses THAT run's stored graph (it must contain a protocol_session node; no device is pre-connected — the deploy session's data source stays yours). Without execution_id the built-in template graph is cloned — simulated source → bandpass → bandpower_indicator → protocol_session stamped with the protocol refs — and a simulated device is connected to the returned session id.

The session starts when a client opens {statusUrl} (the deploy WS), sends init_deployment with modelExecutionId={executionId}, then start; the Studio app shows the feedback panel automatically. Poll protocol.session_status; stop with protocol.stop (the recording's block annotations + assignment progression are written on stop).

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": {
      "protocol_id": "<protocol_id>",
      "protocol_version": "<protocol_version>",
      "subject_label": "<subject_label>",
      "arm": "<arm>"
    },
    "name": "protocol.start_assignment"
  }
}

Input Schema

NameRequiredDescriptionDefault
armYesactive | sham.
confirmNoMUST be true — explicit go-ahead for a session on a human.
protocol_idYesSaved protocol id (protocol.save).
execution_idNoOptional completed execution whose stored graph carries a protocol_session node; default clones the template.
subject_labelYesSubject identifier (e.g. "S01").
protocol_versionYesImmutable version the assignment pins.
yoked_donor_upload_idNoDonor recording upload (required when the arm's blocks resolve to yoked — the backend validates coverage).

Output Schema

NameRequiredDescriptionDefault

No arguments

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changed
    • removedInput schema / properties / name
      Removed value: -{
      -  "anyOf": [
      -    {
      -      "type": "string"
      -    },
      -    {
      -      "type": "null"
      -    }
      -  ],
      -  "default": null,
      -  "description": "Optional display name for the prepared run."
      -}
  2. Added

TDQS

A4.8/5.0
Behavior5/5

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

Annotations only say it is a non-idempotent, open-world, non-destructive write; the description adds the confirm gate, plan gating, the yoked-donor validation the backend performs, and what side effects occur on stop (block annotations and assignment progression are written). It also discloses that a simulated device is auto-connected only in the template path and that no device is pre-connected when reusing an execution graph — none of which is in the annotations.

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 intent is front-loaded in the first sentence and every paragraph carries real information, but the parenthetical nesting is heavy and the deploy-WS handshake paragraph reads more like runbook steps than tool contract. Slightly denser than needed for a single tool, though not padded.

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 7-parameter, gated, stateful tool this covers requirements, the two graph-source paths, the arm/donor interaction, and the post-call session lifecycle. An output schema exists, so the description is not obliged to explain return values, and it still tells the agent to poll protocol.session_status and stop via protocol.stop.

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 baseline is 3, but the description adds genuinely non-obvious meaning: how to mint a yoked_donor_upload_id (run an active-arm session and data.upload its recording), what execution_id must structurally contain (a protocol_session node), and that confirm is a mandatory safety gate rather than a flag. Only protocol_version and subject_label are left to the schema alone.

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?

"Enroll a subject and prepare their neurofeedback deploy session" gives a specific verb and resource, and the description ties it to the surrounding workflow (protocol.save for the protocol, protocol.session_status to poll, protocol.stop to end). An agent can distinguish this from execution.run or protocol.save without opening any 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?

Usage conditions are spelled out in detail: confirm must be true because a session runs on a human, LIVE hardware needs a Pro plan while simulated-source sessions are free, yoked arms require a donor upload id, and execution_id vs. template graph is an explicit either/or. It also states the two lifecycle prerequisites (client opens statusUrl, sends init_deployment then start) that must hold for the assignment to actually run.

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

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.