Skip to main content
Glama
vikranthviki

Causal Decision Agent

by vikranthviki

did_summary_plot

Read-only

Visualize difference-in-differences estimates across methods in a forest plot to assess robustness and compare confidence intervals against a reference value.

Instructions

Forest plot of DID method-robustness summary.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
axNoExisting axes to draw on. If ``None`` a new figure is created.
colorNoColor for point estimates and CIs.#2C3E50
titleNoPlot title. Defaults to ``"DID Method-Robustness Summary"``.
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
resultYesOutput of :func:`did_summary`. Must have a ``detail`` DataFrame with columns ``estimate``, ``ci_low``, ``ci_high``, and either ``method`` or ``estimator``.
figsizeNoFigure size when creating a new figure.
sort_byNoIf ``'estimate'``, sort methods by point estimate ascending. Otherwise keep the order in ``result.detail``.
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_pathNoAbsolute 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://.
referenceNoHorizontal reference value (e.g. 0 for 'no effect'). Defaults to ``0``.
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.
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.
highlight_colorNoColor for the cross-method mean line.#C0392B

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

B3.4/5.0
Behavior3/5

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

The readOnlyHint and openWorldHint annotations already signal a safe read-only operation, and the description does not contradict them. The phrase 'of DID method-robustness summary' adds a little consumption context, but the description does not mention behaviors such as as_handle server-side caching or figure persistence; the annotations lower the burden.

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?

The description is a single, direct sentence with no filler or repetition of the tool name. It front-loads the plot type and the input scope, which is ideal for a simple visualization tool.

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?

The 100% schema coverage, output schema, and read-only annotations make the one-sentence description sufficient for invoking the tool correctly. It still lacks explicit sibling differentiation and chaining advice, so it is not 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 100%, and the result parameter itself is well documented as the output of did_summary with the required detail DataFrame columns. The high-level description adds no parameter-level detail, so it is at the baseline.

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?

The description states a specific deliverable—a forest plot—and scopes it to a DID method-robustness summary, matching the result parameter's did_summary origin. This is clear enough to separate it from generic plotting tools, though it never names a sibling alternative.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines2/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

There is no guidance on when to invoke this tool rather than did_plot, forest_diagnostics, or enhanced_event_study_plot, and no exclusions or chaining notes. The intended use is only implied by the name and the result parameter schema.

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