Skip to main content
Glama

survey_regression

Performs survey-weighted linear or logistic regression with design-based standard errors on NHANES data. Categorical predictors must be dummy-coded first.

Instructions

Survey-weighted linear ('gaussian') or logistic ('binomial') regression with design-based SEs. Categorical predictors must be dummy-coded first with derive_variable.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
domainNo
familyNogaussian
outcomeYes
dataset_idYes
predictorsYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.3.0

TDQS

A3.5/5.0
Behavior3/5

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

With no annotations, the description carries the full burden and does disclose non-obvious behavioral traits: survey weighting, design-based standard errors, and the need for dummy-coded predictors. However, it omits what the tool returns, whether it is read-only, and how missing data or survey design are handled.

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 definition is two sentences with no filler. The first sentence states the core behavior and model families, and the second provides the one essential prerequisite, keeping the information front-loaded and scannable.

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?

The tool has no annotations, no output schema, and 0% parameter description coverage, leaving the description as the only source of guidance. It does not describe the return format, when to select this tool over siblings like survey_cox, or the meaning of the domain parameter, so it is not fully self-sufficient for correct invocation.

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 compensate for the lack of parameter documentation. It usefully explains the 'gaussian'/'binomial' family choices and the dummy-coding requirement for predictors, but it does not clarify outcome, predictors, dataset_id, or domain.

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?

The description clearly states what the tool does: survey-weighted linear or logistic regression with design-based standard errors. It also distinguishes the tool from sibling survey tools like survey_frequency and survey_cox by specifying the model families ('gaussian'/'binomial').

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 provides one explicit prerequisite—dummy-coding categorical predictors with derive_variable—but gives no guidance on when to prefer this tool over alternatives such as survey_estimate, survey_frequency, or survey_cox. Usage context is only implied by the word 'regression'.

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