Skip to main content
Glama

compute_clusters

Computes live connected-component vector clusters for Molecules or FunctionalGroups across chemical classes without altering the database, enabling similarity grouping and catalog coverage.

Instructions

Compute live connected-components vector clusters for Molecules or FunctionalGroups across chemical classes without modifying the database.

Tool call template

This tool declares no required parameters. Add optional parameters from the input schema as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {},
    "name": "compute_clusters"
  }
}

Input Schema

NameRequiredDescriptionDefault
forceNoBypass Rails memory cache and recalculate adjacency graph
levelNoSimilarity granularity level from 1 (tight structural twins, <= 0.16 cosine dist) to 15 (full catalog coverage absorption, <= 0.30)
target_typeNoTarget entity class to cluster: Molecule or FunctionalGroupMolecule
full_coverageNoForces 100% catalog assignment / zero singletons via nearest-cluster absorption

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv1.0.0

TDQS

B3.4/5.0
Behavior3/5

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

With no annotations, the description carries the full burden, and it does usefully disclose the non-mutating nature ('without modifying the database'). It omits other important traits: that results are ephemeral and not persisted (so a snapshot tool is needed to save them), and that computation may be expensive unless 'force' is false and the Rails memory cache is used.

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?

A single front-loaded sentence with no filler; every phrase (live, connected-components, vector clusters, target types, non-mutating) carries information. It is dense but well ordered, with the read-only guarantee placed at the end where it is easy to find.

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

Completeness3/5

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

For a 4-parameter computation tool with no output schema and no annotations, the definition leaves two gaps an agent would care about: what it returns (cluster groupings/assignments) and that the output is not persisted. Without that, the relationship to the snapshot and cluster-group listing siblings stays ambiguous.

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 detailed per-parameter text including level semantics and cache behavior, so the schema already does the heavy lifting. The description adds only the echo of the two target types ('Molecules or FunctionalGroups') and no extra meaning about level, force, or full_coverage.

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?

The description names a specific verb ('Compute'), a specific resource ('live connected-components vector clusters'), and its target entities (Molecules, FunctionalGroups). That is enough to separate it from CRUD siblings like create_cluster_snapshot or list_cluster_groups, though it never explicitly states which sibling to prefer.

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 context is only implied: the word 'live' combined with 'without modifying the database' hints this is an on-demand computation rather than a persisted artifact, but no sentence tells the agent when to choose this over list_cluster_groups, get_cluster_group, or create_cluster_snapshot. There are no exclusions or prerequisites either.

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