ephys-mcp
Server Configuration
Describes the environment variables required to run the server.
| Name | Required | Description | Default |
|---|---|---|---|
| EPHYS_MCP_OUTPUT_DIR | No | Override the directory where plot tools save PNG files. Defaults to ~/.cache/ephys-mcp/plots. |
Instructions
Guidance the server publishes about itself, which clients place ahead of the tool catalog so the model reads it before choosing anything.
This server publishes no instructions, or was last inspected before Glama recorded them.
Capabilities
Features and capabilities supported by this server
Protocol revision2025-11-25
| Capability | Details |
|---|---|
| tools | {
"listChanged": false
} |
| prompts | {
"listChanged": false
} |
| resources | {
"subscribe": false,
"listChanged": false
} |
| experimental | {} |
Tools
Functions exposed to the LLM to take actions
| Name | Description |
|---|---|
| list_sourcesA | List the data source types this server can open, with their parameters and status. |
| open_sessionB | Open a recording session and return its session_id and metadata. |
| close_sessionC | Close a session and drop any decoder fitted on it. |
| get_session_infoB | Metadata for a session: duration, channels, sampling rates, behaviour signals, licence, citation. |
| get_signal_qualityB | Noise level, SNR and dead/noisy channels from a broadband snippet (max 10 s). |
| detect_spikesC | Threshold-crossing spike detection on a broadband snippet (max 10 s). Where the session has ground-truth spikes, precision and recall are reported. |
| set_probe_geometryA | Tell the server where the recording's contacts are, for sessions whose file does not say. |
| get_probeB | Contact geometry and brain-area labels per channel, where known. Use the |
| plot_probeB | Figure: the array map, each contact coloured by its firing rate over a window, with area labels and sorted units marked when a sort has been run. Needs geometry from the file or set_probe_geometry. |
| sort_spikesA | Spike-sort a broadband window (needs the sort extra). Afterwards the session's spike times are the sorted units, restricted to that window, so rates, PSTHs, rasters and decoders use them. |
| get_firing_ratesC | Population firing-rate summary over a time range (defaults to the whole session). |
| fit_decoderA | Fit a decoder from spike counts to a behaviour signal and score it on held-out data. |
| evaluate_cross_sessionA | Fit a decoder on one session and score it, unchanged, on other sessions: the question benchmarks such as FALCON ask (does a decoder survive to a later day?). |
| decode_windowC | Decode a window with the fitted decoder; returns a downsampled decoded-vs-true preview. |
| get_psthA | Peri-stimulus time histogram: firing aligned to a trial event and averaged over trials. |
| fit_latent_factorsA | Fit low-dimensional latent factors to trial-aligned population activity. |
| plot_latent_factorsA | Figure: the top three latent factors over time (single trials thin, group means bold), the trajectory in the plane of the first two factors, and variance explained per factor. Requires fit_latent_factors first. |
| plot_psthB | Figure: population PSTH per group (mean ± SEM over trials) above a unit-by-time heatmap of change from baseline. Same arguments as get_psth. Returns the PNG path and the image. |
| plot_rasterC | Figure: spike raster for a time window (max 60 s), with unrecorded spans shaded. |
| plot_decodingA | Figure: decoded against actual behaviour for a window (max 60 s), one panel per dimension. Requires fit_decoder first. Pick a window in the test split for an honest picture. |
| list_lsl_streamsB | Lab Streaming Layer streams visible on the local network (needs the lsl extra). |
| get_stream_statusB | For a live session: how much signal is buffered, whether data is still arriving, and drops. |
| search_datasetsA | Search the DANDI Archive for datasets. An empty query returns a short curated list of intracortical datasets that work well with this server. |
| list_dataset_filesC | Licence, citation and NWB files of a DANDI dataset. Pass a file's path to open_session(source='dandi'). |
Prompts
Interactive templates invoked by user choice
| Name | Description |
|---|---|
| analyze_session | Walk through a standard first-pass analysis of a session. |
| falcon_evaluate | Run a FALCON-style cross-session evaluation on a FALCON dataset from DANDI. |
Resources
Contextual data attached and managed by the client
| Name | Description |
|---|---|
| sessions_resource | Currently open sessions. |
TDQS
Scored across 24 tools
Most tools have clearly distinct purposes, and the descriptions separate similar operations well. Minor overlap exists between open_session/get_session_info (both return metadata) and detect_spikes/sort_spikes (both derive spike times from broadband data), but the descriptions clarify the different workflows.
Tool names follow a consistent snake_case verb_noun pattern: open_session, close_session, get_session_info, set_probe_geometry, list_sources, fit_decoder, sort_spikes, plot_raster. The naming convention is uniform and predictable across all 24 tools.
At 24 tools, the server is on the heavy end of the borderline range and covers a broad electrophysiology workflow. While each tool seems to have a legitimate role, the sheer number may make tool selection more difficult than necessary.
The tool set covers the main ephys lifecycle: dataset discovery, session open/close, metadata, signal quality, spike detection/sorting, decoding, latent factor analysis, and plotting. Minor gaps exist, such as no explicit list of currently open sessions or raw signal extraction, but these are workable around and do not block the core workflow.