Skip to main content
Glama
Weak Lensing Surveys MCP Server

Weak Lensing Surveys MCP Server

compute_signal_to_noise

Calculate detection significance from published weak-lensing data vectors and their full covariance; combine statistics with cross-covariance and write a CSV summary.

Instructions

S/N = sqrt(d^T C^-1 d) of the published data vector, using its full covariance.

Use for 'how significant is the detection' questions. Statistics listed together are combined with their cross-covariance (they must live in the same file, e.g. xip+xim, or all four DES 3x2pt blocks). No scale cuts are applied (DES files are uncut), so this is the raw measurement S/N. Writes a CSV summary.

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": {
      "datasets": "<datasets>",
      "statistics": "<statistics>",
      "output_dir": "<output_dir>"
    },
    "name": "compute_signal_to_noise"
  }
}

Input Schema

NameRequiredDescriptionDefault
datasetsYesDataset keys.
output_dirYesDirectory where output files are written.
statisticsYesStatistics to combine per dataset, e.g. ['xip','xim'] (joint, with cross-covariance).

Output Schema

NameRequiredDescriptionDefault
filesYes
statusYes
messageYes
metadataYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.2.0

TDQS

A4/5.0
Behavior4/5

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

With no annotations, the description carries the full burden and does disclose meaningful behavior: the full-covariance treatment including cross-covariance, the caveat that no scale cuts are applied so the result is a raw S/N, the same-file constraint that will cause failures, and the side effect of writing a CSV. It does not say where/how the CSV is named or whether it overwrites existing output.

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?

Four short sentences, front-loaded with the defining formula, then usage, then constraints, then side effect — no wasted wording. The mathematical notation is dense but earns its place for a statistics tool.

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 values need no prose, and the description still flags the CSV artifact. For a three-required-parameter computation it covers purpose, preconditions, and caveats; only the valid statistic vocabulary and output naming are left implicit.

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

Parameters4/5

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

Schema coverage is 100%, so baseline is 3, but the description adds genuine semantics beyond the schema: it explains that listed statistics are combined via their cross-covariance and must come from the same file, which constrains what combinations of the free-form 'statistics' array are legal. It does not enumerate valid statistic names, which the schema also leaves open.

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 gives a precise verb-and-resource statement with the actual estimator formula (sqrt(d^T C^-1 d)) and bounds the input to the 'published data vector with its full covariance'. That clearly separates it from plotting or comparison siblings, though it never names an alternative tool to contrast against.

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

Usage Guidelines4/5

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

It states the triggering question class ('how significant is the detection') and adds a real precondition: statistics combined together must live in the same file (xip+xim, or all four DES 3x2pt blocks). It offers no explicit exclusions or named alternatives for the comparison/plot siblings, so it stops short of a 5.

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