Skip to main content
Glama

compute_lcdm_theory_spectrum

Computes lensed LCDM TT/TE/EE/BB and lensing-potential spectra to CSV for CMB fitting, plotting, and residual checks; uses supplied camb parameters or a Planck 2018 fallback.

Instructions

Compute a lensed LCDM TT/TE/EE/BB + lensing-potential theory spectrum to CSV.

Model computation: with camb and YOUR parameters this is your own model for
fitting the bandpowers. Uses camb (optional dependency, lazily imported; or a facility
node via set_dispatch). Without camb and without params it falls back to the bundled
Planck 2018 published best-fit theory file (ell<=2508) - that is a published result
(comparison only), flagged in metadata.model_source; say so when reporting. Pass the CSV as theory_file to
plot_cmb_spectra / compute_cmb_residuals / plot_lensing_spectrum.

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": "compute_lcdm_theory_spectrum"
  }
}

Input Schema

NameRequiredDescriptionDefault
lmaxNoMaximum multipole (ACT needs ~6500).
paramsNoLCDM parameters: ombh2, omch2, cosmomc_theta (or H0), tau, logA (or As), ns, mnu. Missing -> Planck 2018 best fit. Requires camb.
output_dirYesDirectory for the theory CSV.

Output Schema

NameRequiredDescriptionDefault
filesYes
statusYes
messageYes
metadataYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

A4.3/5.0
Behavior5/5

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

With no annotations supplied, the description carries the full burden and does so: camb is an optional, lazily imported dependency, a facility node can be used via set_dispatch, and without it the tool silently falls back to a published Planck 2018 file capped at ell<=2508. It also discloses the metadata.model_source flag and instructs the agent to report the fallback as a published comparison result rather than a fit, which is exactly the kind of non-obvious behavioral detail that cannot be inferred elsewhere.

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 is front-loaded in the first line, followed by dependency and fallback context and then the downstream hand-off, with no filler sentences. The line breaks inside sentences make it slightly denser to parse than necessary, but every clause earns its place.

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?

For a tool with an optional heavy dependency, a silent fallback path, and an output schema, this description covers what an agent needs to call it and interpret the result. Minor gaps remain, such as the output file name/location behavior within output_dir and error behavior when camb is missing but params are supplied, but nothing critical is missing.

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 coverage is 100%, with the schema already documenting lmax, params (including 'Requires camb' and the Planck best-fit default), and output_dir, so the baseline is 3. The description reinforces the params/dependency link ('with camb and YOUR parameters this is your own model') but adds no syntax, units, or constraints beyond the schema.

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 opening sentence names a specific verb (Compute) and resource (lensed LCDM TT/TE/EE/BB + lensing-potential theory spectrum) plus the output format (CSV). It goes further by distinguishing model computation from the bundled-file fallback, so an agent can tell what kind of spectrum this produces relative to data-fetching siblings.

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?

The description gives a clear when-branch (camb + your parameters -> your own model for fitting bandpowers) and when-not (no camb and no params -> falls back to the bundled Planck best-fit file), plus explicit next-step consumers (plot_cmb_spectra, compute_cmb_residuals, plot_lensing_spectrum). It stops short of contrasting with sibling data-retrieval tools such as fetch_cmb_spectrum.

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