Skip to main content
Glama
Supernova Cosmology MCP Server

Supernova Cosmology MCP Server

standardize_sn_salt2

Build a standardized Hubble diagram from per-supernova SALT2 fits, fitting stretch, colour, host-mass step, and intrinsic scatter by maximum likelihood and exporting CSV/JSON.

Instructions

Tripp standardisation: build a Hubble diagram from per-SN SALT2 fits (from catalog to Hubble diagram).

Fits alpha (stretch), beta (colour), gamma (host-mass step at 10^10 Msun) and sigma_int
by maximum likelihood: mu = mB - M + alpha*x1 - beta*c ± gamma/2 - biasCor.
Literature: Pantheon+ alpha~0.15, beta~3.0, gamma~0.05; DES-SN5YR alpha=0.161, beta=3.12, gamma=0.038.
The tool compares the resulting mu with the released Hubble diagram (rms_vs_released_mu should be
~few mmag for Pantheon+ and ~20 mmag for DES, since we use a diagonal approximation).
Uses ONLY per-SN light-curve fit parameters; never published posteriors.

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": {
      "output_dir": "<output_dir>"
    },
    "name": "standardize_sn_salt2"
  }
}

Input Schema

NameRequiredDescriptionDefault
OmNoFiducial flat-LCDM Om for the distance prior.
zmaxNoKeep z <= zmax.
zminNoKeep z > zmin (Pantheon+ cosmology cut is 0.01).
datasetNopantheonplus or des5yr.pantheonplus
output_dirYesDirectory for the Hubble diagram CSV + summary JSON.
exclude_calibratorsNoDrop Cepheid-host calibrators (IS_CALIBRATOR=1).

Output Schema

NameRequiredDescriptionDefault
filesYes
statusYes
messageYes
metadataYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

A3.9/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 well: it discloses the fitted quantities, the diagonal-approximation caveat, and concrete validation expectations (rms_vs_released_mu ~few mmag for Pantheon+, ~20 mmag for DES). It omits operational behaviour such as runtime, whether upstream data must be fetched first, and that files are written to output_dir (the latter only implicit in the schema).

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?

The purpose is front-loaded in the first line, followed by method, literature reference values and a validation note; the literature numbers are arguably padding but serve as sanity-check anchors. Slightly dense, but each sentence carries information an agent could use.

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 not be explained, and the description still adds a useful validation target (rms_vs_released_mu). For a six-parameter analysis tool it is nearly complete, missing only prerequisites (data already fetched) and whether the fit is expensive to run.

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 every parameter including Om, zmin/zmax cuts and exclude_calibrators is documented in the schema itself. The description adds no syntax, defaults or per-parameter meaning beyond that, so the baseline 3 applies.

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?

The description states a specific verb and resource ('build a Hubble diagram from per-SN SALT2 fits') and specifies the method (simultaneous max-likelihood fit of alpha, beta, gamma, sigma_int under the Tripp relation). This is clearly distinguishable from neighbours like compute_distance_modulus, bin_hubble_diagram and fit_sn_cosmology.

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?

Scope conditions are stated implicitly: it works only on per-SN light-curve fit parameters and never published posteriors, and it operates on either the pantheonplus or des5yr sample. However, no sibling tool is named and there is no explicit 'use this instead of X when...' routing, so the agent must infer the position of this step in the pipeline.

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