Skip to main content
Glama

WritersLogic research agents

causalReferee

Causal Claim Referee — Referees a causal claim against an observational table (JSON rows, CSV text, or a published contingency table with counts) and leads with a verdict, confidence, whether the claim holds, the crude and adjusted effects with bootstrap intervals, and a concrete next step. Underneath: crude and stratified effects, Mantel-Haenszel pooling, Simpson's-paradox detection, d-separation and backdoor/front-doo

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": {
      "treatment": "<treatment>",
      "outcome": "<outcome>",
      "covariates": "<covariates>",
      "claim": "<claim>"
    },
    "name": "causalReferee"
  }
}

Input Schema

NameRequiredDescriptionDefault
csvNoAlternative to data: CSV text with a header line (comma, semicolon or tab separated; quoted fields allowed; at most 20000 data rows). Numeric cells become numbers.
dagNoYour causal DAG (formal input: no LLM is called to build the graph or, by default, the report). Omit to have one proposed by two independent model samples, which is then an assumption.
binsNoQuantile bins for numeric covariates, default 4.
dataNoObservational table as an array of row objects (at most 20000 rows). Cells are string, number, boolean or null; rows missing a used variable are dropped. Provide this or csv.
seedNoSeed for bootstrap and Monte Carlo; default derived from the input hash.
alphaNoSignificance level for the permutation test and the (1-alpha) bootstrap interval, default 0.05.
claimYesThe causal claim being refereed, in plain language.
outcomeYesBinary column (risk difference, risk ratio, odds ratio) or numeric column (mean difference).
llmReportNoAsk a model to write the executive report in prose (numbers verified in code, template fallback). Default false: the report is a deterministic template over the computed results.
treatmentYesColumn with exactly two distinct values.
covariatesYesCandidate adjustment variables (at most 12). Numeric ones with more than `bins` distinct values are cut at deterministic quantile edges; others must have at most 20 levels.
countColumnNoName of a column holding how many times each row repeats, so a published contingency table can be sent as a few aggregate rows (counts must be non-negative integers; the expanded table is capped at the row limit).
outcomeTypeNoForce the outcome type; inferred from the number of distinct values otherwise.
descriptionsNoOptional one-line description per variable, used only to propose the DAG.
successValueNoOutcome value that counts as success for a binary outcome; same default rule.
treatedValueNoTreatment value that counts as treated; required unless the values are numeric or boolean (then the larger is treated).
bootstrapRepsNo
claimDirectionNoDirection of the claimed effect of treated vs control; default nonzero.
permutationSamplesNoUsed only when the exact enumeration would exceed 1000000 label assignments.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A3.6/5.0
Behavior3/5

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

No annotations are supplied, so the description carries the full burden. It discloses a good deal of analytical behavior — bootstrap intervals, Mantel-Haenszel pooling, backdoor/front-door, permutation testing — and the 'Referee' framing implies a read-only evaluation with no mutation. However it does not state determinism, failure modes for malformed tables, or that the DAG is treated as an assumption when omitted is only covered in the schema, not the description body.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness3/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Purpose is front-loaded in the first clause, which is good, but the body is a run-on 'Underneath:' fragment and the text cuts off mid-word at 'backdoor/front-doo', leaving an incomplete trailing clause. There is little wasted abstraction, but the structure and truncation blunt readability.

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 19-parameter, nested-schema tool with no output schema, the description does the essential work: it states the headline return shape (verdict, confidence, effects with intervals, next step) and the statistical machinery behind it. What is missing is guidance on combining the data/csv/countColumn alternatives and the DAG-omitted case, which would raise this to a 5.

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 95%, so the schema already documents nearly all 19 parameters including enums, bounds and defaults. The description adds only loose framing around the three input modalities (rows / CSV / contingency-table counts), which is useful but does not extend parameter meaning beyond what the schema states.

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?

Names a specific verb and resource — it referees a causal claim against an observational table — and immediately enumerates the outputs (verdict, confidence, whether the claim holds, crude/adjusted effects, next step), so an agent knows exactly what it produces. It also lists the accepted input shapes (JSON rows, CSV text, contingency table), distinguishing it from a pure stats or data-loading tool.

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 multi-format input phrasing and by analysis verbs like 'Simpson's-paradox detection' and 'd-separation', so an agent can infer this is for adjudicating causal effect questions. But there is no explicit when-to-use vs when-not, no stated prerequisites, and no alternative named (e.g. when a plain regression would do instead).

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

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.

Resources