Skip to main content
Glama

Jean — Molecular Biology & Genomics

classify_droplets

Read-only

ddPCR droplet amplitudes to populations. For TWO targets, a four-way classification — NN, NP, PN, PP — under any of THREE published methods that answer different questions and none of which is a fallback for another.

Input Schema

NameRequiredDescriptionDefault
kNofor `knn`: how many nearest labelled neighbours vote. Only applies when method is knn.
probNofor `knn`: the smallest winning share of the vote that counts as a call. Below it the droplet is `Rain`. 0 disables the floor. At k = 5 a bare 3-2 majority is 0.6, so any floor at or below 0.5 accepts every droplet the vote decided at all. Only applies when method is knn.
_filesNoThe project: record references shaped like _subject. Their records become library documents a tool names in sequences/parts/document; a trace or alignment is found by file name.
ch1_nnNogrid: Ch1 below this and Ch2 below `ch2_nn` is NN. Only applies when method is grid.
ch1_npNogrid: Ch1 below this and Ch2 above `ch2_np` is NP. Only applies when method is grid.
ch1_pnNogrid: Ch1 above this and Ch2 below `ch2_pn` is PN. Only applies when method is grid.
ch1_ppNogrid: Ch1 above this and Ch2 above `ch2_pp` is PP. Only applies when method is grid.
ch2_nnNogrid: the Ch2 half of the NN box. Only applies when method is grid.
ch2_npNogrid: the Ch2 half of the NP box. Only applies when method is grid.
ch2_pnNogrid: the Ch2 half of the PN box. Only applies when method is grid.
ch2_ppNogrid: the Ch2 half of the PP box. Only applies when method is grid.
methodNowhich classifier. `grid` needs its eight thresholds to suit your assay; `kmeans` needs nothing and cannot abstain; `knn` needs `training` and is the only one that can leave a droplet unassigned; `density`, `samspectral`, `flowpeaks` and `ensemble` (ddPCRclust) are for one to four targets and name populations by marker number (`1`, `1+2`, ...); `ensemble` runs the other three and is the slowest.kmeans
markersNofor `density`: the well's four marker slots, comma-separated, as in ddPCRclust's run template. A name is a target the reaction carries; an EMPTY slot is one it does not, so `a,,c,d` is a three-target well whose cluster 2 is missing. The number of names is the number of targets. Only applies when method is density or samspectral or flowpeaks or ensemble.M1,M2,M3,M4
_subjectNoThe record to act on: exactly one of sequence, accession (+source), sample (an id from list_samples) or file ({name, text} or {name, base64}); record_index picks one record of several.
dropletsYesthe well to classify: two amplitude columns, `Ch1` then `Ch2`, one row per droplet. A header line is optional. This is the whole well, not a summary. For the ddPCRclust methods it may instead be a PLATE: each export as `# <file name>` then its CSV, separated by a line of `---`, the well id read from the file name (`..._B01_Amplitude.csv`).
sam_seedNofor `samspectral` and `ensemble`: R's `set.seed` before the run. SamSPECTRAL keeps the best of 1000 k-means starts drawn from it, and on a plate one stream runs through the wells in order, as `ddPCRclust()` does. Only applies when method is samspectral or ensemble.
templateNofor a PLATE under the ddPCRclust methods: ddPCRclust's run template (a `>name, channel1=..., channel2=..., description` line, then `Well,Sample type,# of markers,Marker 1..Marker 4`). Each well then takes its own row's markers instead of `markers`. Only applies when method is density or samspectral or flowpeaks or ensemble.
trainingNofor `knn` only: an already-labelled well, as `Ch1,Ch2,class` with class one of NN, NP, PN, PP or Rain. Rain IS a class here and not a rejection — a droplet can be assigned to it on the strength of its neighbours, separately from the probability floor below. Only applies when method is knn.
random_seedNofor `knn`: ties among equidistant neighbours, and among tied winning classes, are broken from this stream. On a well-separated plate it changes nothing; where droplets sit exactly between populations it does, and a deterministic tie-break would be stable and wrong. Only applies when method is knn.
sensitivityNofor `density`: how finely the initial cluster search resolves density peaks (its step is 0.02 / sensitivity³). Higher divides the data into more clusters, lower merges more. Only applies when method is density or samspectral or flowpeaks or ensemble.
distance_paramNofor `density`: the share of the path between two clusters within which rain goes to the LOWER one; the rest goes to the higher one. Only applies when method is density or samspectral or flowpeaks or ensemble.
constant_controlNofor a PLATE under the ddPCRclust methods: the marker that should read the same in every well. Every well's copies per droplet are multiplied by the control's highest value on the plate over its own, as `calculateCPDs(constantControl =)` does. Empty: no normalisation. Only applies when method is density or samspectral or flowpeaks or ensemble.

Output Schema

NameRequiredDescriptionDefault
totalYesdroplets classified — the denominator the counts sum to
wellsYesfor a PLATE: every well's counts, copies per droplet, confidence and members, or the reason no member could partition it. `classes`, `counts` and `total` are empty for a plate
countsYesdroplets per class, which is what a copy-number read consumes next. Rain is reported separately and is never folded into a population
methodYeswhich classifier produced this. A classification without its method is not comparable with another, because the three disagree on the droplets between populations
paramsYesevery parameter the run used, defaults included: the thresholds, k and the floor each move the answer
centresYesfor `kmeans`: the final cluster centres with the name geometry gave each one; for `density`: the primary cluster centres, named by marker. Empty for the other methods, which have no centres
classesYesone label per droplet, in the order given: NN, NP, PN, PP, or Rain where the method abstained
membersYesfor the ddPCRclust methods: each first clustering that ran, with its population counts or the error that left it out of the consensus. `ensemble` is only as good as the members that agreed
confidenceYesfor the ddPCRclust methods: the mean corrected Rand index between the member partitions (1 when one member answered). Low means the three first clusterings disagree about this well
normalisedYesfor a PLATE with `constant_control`: every well's copies per droplet after scaling to the control's highest value on the plate, with each well's factor. Null without a control
copies_per_dropletYesfor the ddPCRclust methods on one well: each named marker's positive droplets (every population carrying it) and its copies per droplet, -ln(1 - positives / total). Empty for the two-target methods

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

C2.7/5.0
Behavior3/5

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

Annotations already establish readOnlyHint=true, openWorldHint=false, and destructiveHint=false, so the safety profile is covered. The description adds that the methods answer different questions rather than acting as fallbacks, but it says nothing about runtime cost, plate processing, abstention behavior, or output shape beyond the bare classification labels. With annotations present, this is adequate but not rich.

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

Conciseness3/5

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

The definition is short and front-loads the core action. The second sentence is convoluted and its 'THREE published methods' claim is vague and inconsistent with the schema, so the brevity sacrifices usable detail rather than achieving clean precision.

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

Completeness2/5

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

This is a high-complexity tool with 22 parameters, nested objects, and an output schema. The description omits the ddPCRclust methods entirely, never explains plate input, markers, templates, or the one-to-four-target support, and misstates the method count. The rich schema mitigates this, but an agent cannot understand the tool's full scope from the description alone.

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%, so all parameters are documented in the schema itself. The description contributes the population labels and the idea of multiple methods, but it does not clarify any parameter semantics or reconcile the seven-method enum with its 'THREE published methods' claim. Baseline 3 is appropriate when the schema carries nearly all parameter meaning.

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

Purpose3/5

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

The description names the resource and action: ddPCR droplet amplitudes classified into populations, with NN, NP, PN, PP labels. However, it says 'For TWO targets' and 'THREE published methods' while the schema exposes seven methods and method descriptions covering one to four targets. The core purpose is recognizable, but the stated scope is materially inaccurate.

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

Usage Guidelines2/5

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

It hints that methods 'answer different questions and none of which is a fallback for another,' which signals that method choice matters. It does not name the methods, explain when to use grid versus kmeans versus knn versus ddPCRclust methods, or point to any alternative sibling tool. For a 22-parameter classifier, this is very thin guidance.

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.

Resources