Skip to main content
Glama
vikranthviki

Causal Decision Agent

by vikranthviki

negative_control_exposure

Read-only

Detect residual confounding by regressing the outcome on a negative-control exposure. A significant coefficient signals confounding bias, guiding covariate adjustment or sensitivity analysis.

Instructions

Regress outcome on a negative-control exposure. Assumptions: The negative-control exposure has no causal effect on the outcome by design (Lipsitch et al. 2010); It shares the same confounding structure as the real exposure. Pre-conditions: data has the outcome and a negative-control exposure column. Failure modes: Significant coefficient on the negative-control exposure signals residual confounding, not an effect -> Treat a non-zero coefficient as a confounding alarm; add covariates or run a sensitivity analysis. Alternatives: sp.negative_control_outcome, sp.sensemakr, sp.evalue. Typical minimum N: 100.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
yYesOutcome variable column name or outcome array.
nceYesnce parameter (str).
alphaNoSignificance level for confidence intervals and tests.
detailNoPayload depth: 'minimal' (~150 tokens) for sub-step calls where only the point estimate is needed; 'standard' (~1K tokens) for diagnostics + coefficient table; 'agent' (~2K tokens, default) adds violations / next_steps / suggested_functions so the LLM can plan its next call without another round-trip.agent
as_handleNoIf true, cache the fitted result on the server and return result_id + result_uri alongside the JSON payload so a subsequent tools/call can chain without re-running.
data_pathYesAbsolute path or URL to a data file. Supported: .csv / .tsv / .txt (delimited), .parquet / .pq, .feather / .arrow, .xlsx / .xls, .dta (Stata), .json / .jsonl. Schemes: file://, s3://, gs://, https://.
result_idNoOptional handle to a previously-fitted result (returned by an earlier call when as_handle=true). Tools that operate on a fitted object accept this in place of re-supplying data_path + columns.
covariatesNoCovariate matrix, DataFrame, or column names.
data_columnsNoOptional column projection. Parquet/Feather/Stata loaders honour this for fast partial reads.
data_sample_nNoOptional uniform random subsample size (seed=0, deterministic) — useful on huge panels.

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

A4/5.0
Behavior4/5

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

Annotations already mark this as read-only, and the description adds valuable behavioral context beyond that: a significant coefficient on the negative-control exposure should be treated as a confounding alarm, not a causal effect. Documenting the Lipsitch et al. assumption and minimum N further helps the agent interpret results. No contradiction with the readOnlyHint annotation.

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

Conciseness5/5

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

Compact and front-loaded: the core action appears in the first sentence, and every following block—assumptions, pre-conditions, failure modes, alternatives, and minimum N—earns its place. There is no filler or redundant restatement.

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?

Given the rich input schema, output schema, and readOnly annotations, the description covers what an agent needs: model assumptions, interpretation of results, failure behavior, and useful alternatives. The only notable gap is that the exact regression specification (e.g., whether covariates are required) is not stated explicitly, but the schema and output schema compensate.

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 the baseline is 3 even without parameter details in the description. The description usefully reinforces that nce is the negative-control exposure and y is the outcome, but it adds no formatting, column-type, or usage details beyond what the schema already provides.

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?

Opens with a specific verb and object: 'Regress outcome on a *negative-control exposure*.' This makes the core function immediately clear. It names alternatives but does not explain how negative_control_exposure differs from negative_control_outcome, so sibling differentiation is only partial.

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?

Provides explicit pre-conditions and assumptions: the data must have outcome and negative-control exposure columns, and the negative control must share confounding structure. It also gives a failure-mode rule and lists relevant alternatives. However, it does not give explicit selection criteria for choosing among the named alternatives, stopping 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.

Deploy Server

Other Tools