Skip to main content
Glama

chi2_test

Run chi-square goodness-of-fit or independence tests on observed data to assess statistical significance.

Instructions

Run a chi-square goodness-of-fit test (1-D) or independence test (2-D table).

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
expectedNo
observedYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

B3/5.0
Behavior2/5

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

No annotations are provided, so the description carries the full behavioral burden. It states only what the test does; it does not disclose assumptions (e.g. expected frequency requirements), default handling of the optional expected parameter, or what the test returns.

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?

A single, front-loaded sentence with no wasted words. It efficiently communicates the tool's scope and the two main variants.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness2/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

For a statistical test with no annotations, no output schema, and 0% schema description coverage, the description is too sparse. It omits parameter meaning, assumptions, and result interpretation, leaving an agent with insufficient context to call it correctly beyond the basic test name.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters2/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 0%, so the description must explain the parameters. It hints at data dimensionality for observed but says nothing about the expected parameter, its optional/null default, or the distinction between observed and expected arrays.

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?

States a specific verb ('Run') and resource ('chi-square goodness-of-fit test' or 'independence test'), and clarifies the two data-shape variants (1-D vs 2-D table). It does not explicitly differentiate from sibling statistical tests, but the test name itself is clear.

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?

The description implies when each variant applies by noting 1-D for goodness-of-fit and 2-D table for independence. However, it gives no explicit when-to-use versus alternatives and no exclusions, so the guidance is only implicit.

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