Skip to main content
Glama

regression_fit

Fits a linear regression (y = mx + b) to x/y data points and returns the slope, intercept, and R-squared value for trend analysis.

Instructions

Fit a linear regression (y = mx + b) to x/y data points, returns slope, intercept, R-squared.

Input Schema

NameRequiredDescriptionDefault
xYesArray of x values (numbers).
yYesArray of y values (numbers).

Schema Changelog

Changes observed during successful MCP inspections.

  1. Addedv0.1.11

TDQS

B3.4/5.0
Behavior3/5

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

With no annotations, the description carries the burden of behavioral disclosure. It states the model and the three returned values, which is useful, but it omits input constraints such as equal-length arrays, minimum data points, or error behavior.

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 front-loaded sentence that states the operation, the model, and the outputs without any wasted words.

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?

For a simple pure-function tool with a rich input schema and no output schema, the description covers the essential purpose and return values. It could mention equal-length array requirements or edge cases, but it is largely sufficient.

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 coverage is 100%, so the input schema already documents both parameters. The description does not add any syntax, format, or constraint details beyond what the schema provides, making 3 the appropriate 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?

States a specific verb and resource ('Fit a linear regression') plus the formula and returned values. It is clear what the tool does, but it does not explicitly differentiate itself from potentially related siblings like slope_intercept or correlation_calc.

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?

The description provides no guidance on when to use this tool versus alternatives, no prerequisites, and no conditions for use. It only describes the operation itself.

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