Skip to main content
Glama

Compare Proteins Topologically (TDA Fingerprint Distance)

compare_proteins_topologically
Read-onlyIdempotent

Compares 2–10 proteins via a TDA fingerprint distance metric and returns a pairwise distance matrix showing how divergent their fingerprints are.

Instructions

Compare multiple proteins using a TDA-fingerprint distance.

Computes a pairwise distance matrix between the TDA fingerprints of the provided proteins. Distance metric: L2 distance between length-normalised 64-slot fingerprint vectors (see _fingerprint_distance). Distance = 0 means identical fingerprints; larger values mean more divergent fingerprints. This is not a Wasserstein distance between persistence diagrams.

The vectors hold at most 16 statistics (see compute_topology_fingerprint). With GUDHI (the optional [tda] extra), a model longer than 500 residues is compared on 500 evenly spaced Cα atoms. Without GUDHI the fallback uses every residue of every model, with no subsampling, and builds each model's full pairwise distance matrix, so its cost grows with the square of the model length. protein_metadata reports n_residues_used and subsampled for each model. In an internal audit of 23 AlphaFold models run with GUDHI, nearly all of each normalised vector lay in its two total-persistence components, so the distance mostly tracks one ratio: total H1 over total H0 persistence. It has no validated threshold for fold similarity and is not a functional, sequence-similarity or binding-site measure (LIMITATIONS.md L12).

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": {
      "params": "<params>"
    },
    "name": "compare_proteins_topologically"
  }
}

Input Schema

NameRequiredDescriptionDefault
paramsYes

Output Schema

NameRequiredDescriptionDefault

No arguments

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv1.1.8

TDQS

A3.9/5.0
Behavior4/5

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

Annotations only declare readOnly/openWorld/idempotent, yet the description adds substantial behavior: L2 distance over length-normalised 64-slot vectors, the 500-residue subsampling with GUDHI vs the full-pairwise fallback whose cost grows with the square of model length, and what protein_metadata reports. It also discloses that the distance is dominated by the H1/H0 total-persistence ratio and has no validated fold-similarity threshold — genuinely useful caveats beyond 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?

Purpose and metric are front-loaded, and the GUDHI/no-GUDHI cost contrast earns its space. Some internal references (``_fingerprint_distance``, ``compute_topology_fingerprint``, LIMITATIONS.md L12) and the audit anecdote are implementation detail that an agent cannot act on.

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?

An output schema exists, so return format need not be spelled out, and the description covers cost, subsampling disclosure, and interpretive limits well. It stops short of stating failure modes (invalid accessions, mixed-length models) or how the matrix is ordered, which matters for a minimally-parameterised but computationally heavy tool.

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?

The single nested parameter (uniprot_ids, 2–10 accessions) is largely described by the schema itself; the description only adds that the comparison is over all supplied proteins and that fingerprint length must be consistent. No added detail on accession format, error behaviour for invalid IDs, or ordering of the output matrix.

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?

States a specific verb and resource: computes a pairwise distance matrix between TDA fingerprints of the provided proteins. It explicitly disambiguates from a sibling ("see compute_topology_fingerprint") and from a related concept ("not a Wasserstein distance between persistence diagrams").

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 pairwise-matrix framing and the pointer to compute_topology_fingerprint for the underlying vectors, and the limitations sentence warns against functional or sequence-similarity use. However, there is no explicit when-to-use/when-not instruction naming which sibling to pick for a single fingerprint versus a multi-protein comparison.

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