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
| Name | Required | Description | Default |
|---|---|---|---|
| csv | No | Alternative 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. | |
| dag | No | Your 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. | |
| bins | No | Quantile bins for numeric covariates, default 4. | |
| data | No | Observational 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. | |
| seed | No | Seed for bootstrap and Monte Carlo; default derived from the input hash. | |
| alpha | No | Significance level for the permutation test and the (1-alpha) bootstrap interval, default 0.05. | |
| claim | Yes | The causal claim being refereed, in plain language. | |
| outcome | Yes | Binary column (risk difference, risk ratio, odds ratio) or numeric column (mean difference). | |
| llmReport | No | Ask 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. | |
| treatment | Yes | Column with exactly two distinct values. | |
| covariates | Yes | Candidate 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. | |
| countColumn | No | Name 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). | |
| outcomeType | No | Force the outcome type; inferred from the number of distinct values otherwise. | |
| descriptions | No | Optional one-line description per variable, used only to propose the DAG. | |
| successValue | No | Outcome value that counts as success for a binary outcome; same default rule. | |
| treatedValue | No | Treatment value that counts as treated; required unless the values are numeric or boolean (then the larger is treated). | |
| bootstrapReps | No | ||
| claimDirection | No | Direction of the claimed effect of treated vs control; default nonzero. | |
| permutationSamples | No | Used only when the exact enumeration would exceed 1000000 label assignments. |