Skip to main content
Glama

openreadout_spikes

Read-onlyIdempotent

Detect extracellular spikes per channel in raw electrophysiology recordings: band-pass filter, threshold by MAD noise, and return spike counts, rates, and times.

Instructions

Extracellular spike detection per channel: band-pass, threshold at K x MAD noise, spike counts, rates and times.

Input Schema

NameRequiredDescriptionDefault
fileYesPath to the file or data-set directory.
signNo`neg` (default), `pos` or `both`.
traceNoTrace index (default 0; pick the broadband stream).
strictNoRefuse values the file's assurance does not validate (exit_code 6). Default: the server's.
sweepsNoSweeps/segments (default all).
band_hzNoBand-pass `[low, high]` Hz (default [300, 6000]).
channelsNoChannels (default all).
max_timesNoSpike times per channel returned (default 200).
thresholdNoThreshold in MAD noise units (default 5).
max_secondsNoOnly the first N seconds of each sweep.

Output Schema

NameRequiredDescriptionDefault
pathYesInput path.
notesNoRemarks.
traceYesTrace analysed.
formatYesFormat id.
sweepsYesSweeps analysed.
channelsYesOne entry per channel.
settingsYesSettings used (the high edge after clamping to 0.45 × the sampling rate).
sample_rate_hzYesSampling rate, Hz.
spike_count_totalYesSpikes on all channels.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed20 schema fields changedv0.4.0
    • removedInput schema / properties / channels / default
      Removed value: -[]
    • removedInput schema / properties / channels / items / minimum
      Removed value: -0
    • changedInput schema / properties / file / description
      Previous value: -"Absolute or working-directory-relative path to the instrument file or data-set directory."New value: +"Path to the file or data-set directory."
    • removedInput schema / properties / max_times / minimum
      Removed value: -0
    • changedInput schema / properties / strict / description
      Previous value: -"true: refuse (an error with exit_code 6 and a hint) values this file's assurance does not validate. Default: the server's setting (OPENREADOUT_STRICT; off)."New value: +"Refuse values the file's assurance does not validate (exit_code 6). Default: the server's."
    • removedInput schema / properties / sweeps / items / minimum
      Removed value: -0
    • removedInput schema / properties / trace / default
      Removed value: -0
    • removedInput schema / properties / trace / minimum
      Removed value: -0
    • changedOutput schema / $defs / ChannelSpikes / properties / duration_s / type
      Previous value: -"number"New value: +[
      +  "number",
      +  "null"
      +]
    • changedOutput schema / $defs / ChannelSpikes / properties / noise / type
      Previous value: -"number"New value: +[
      +  "number",
      +  "null"
      +]
    • changedOutput schema / $defs / ChannelSpikes / properties / rate_hz / type
      Previous value: -"number"New value: +[
      +  "number",
      +  "null"
      +]
    • changedOutput schema / $defs / ChannelSpikes / properties / threshold / type
      Previous value: -"number"New value: +[
      +  "number",
      +  "null"
      +]
    • changedOutput schema / $defs / ChannelSpikes / required
      Previous value: -[
      -  "channel",
      -  "name",
      -  "noise",
      -  "threshold",
      -  "spike_count",
      -  "rate_hz",
      -  "duration_s",
      -  "times",
      -  "times_truncated"
      -]New value: +[
      +  "channel",
      +  "name",
      +  "unit",
      +  "noise",
      +  "threshold",
      +  "spike_count",
      +  "rate_hz",
      +  "duration_s",
      +  "times",
      +  "times_truncated"
      +]
    • changedOutput schema / $defs / DetectSettings / properties / exclude_ms / type
      Previous value: -"number"New value: +[
      +  "number",
      +  "null"
      +]
    • changedOutput schema / $defs / DetectSettings / properties / high_hz / type
      Previous value: -"number"New value: +[
      +  "number",
      +  "null"
      +]
    • changedOutput schema / $defs / DetectSettings / properties / low_hz / type
      Previous value: -"number"New value: +[
      +  "number",
      +  "null"
      +]
    • changedOutput schema / $defs / DetectSettings / properties / threshold / type
      Previous value: -"number"New value: +[
      +  "number",
      +  "null"
      +]
    • changedOutput schema / $defs / SpikeTime / properties / amplitude / type
      Previous value: -"number"New value: +[
      +  "number",
      +  "null"
      +]
    • changedOutput schema / $defs / SpikeTime / properties / time_s / type
      Previous value: -"number"New value: +[
      +  "number",
      +  "null"
      +]
    • changedOutput schema / properties / sample_rate_hz / type
      Previous value: -"number"New value: +[
      +  "number",
      +  "null"
      +]
  2. Addedv0.3.0

TDQS

A3.8/5.0
Behavior4/5

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

Annotations already declare readOnly, idempotent and non-destructive behavior, so the bar is low; the description still adds real value by disclosing the processing pipeline (band-pass, K x MAD thresholding) and the outputs produced (counts, rates, times). It does not mention cost, data-size limits, or failure modes.

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?

A single front-loaded sentence that names the domain first and then enumerates the pipeline stages and outputs. No filler, no restatement of the title or name.

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

Completeness4/5

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

With a full output schema and complete annotation set, the description only needs to frame the computation, which it does. The main residual gap is the absence of any statement about prerequisites (e.g. broadband trace selection, assurance/strict validation) that an agent would need before calling it.

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

Parameters3/5

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

Schema description coverage is 100% with 10 well-documented parameters, so the schema already carries parameter meaning. The description echoes band-pass, threshold and time outputs but adds no syntax, units or default information beyond what the schema provides, so the baseline 3 applies.

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

Purpose4/5

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

States a specific verb and resource ('Extracellular spike detection per channel') plus the algorithm used, so an agent knows exactly what computation is performed. It contrasts implicitly with generic siblings like openreadout_peaks by naming the extracellular-spike domain, but never names an alternative explicitly.

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

Usage Guidelines3/5

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

Usage is implied by the domain phrase 'extracellular spike detection per channel' plus the mention of picking a broadband stream, which tells the agent the expected input. There is no explicit when-to-use/when-not guidance and no routing to sibling tools such as openreadout_peaks or openreadout_ephys_features.

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