Skip to main content
Glama

UK Data: Maths and statistics

linear_regression_prediction

Read-onlyIdempotent

Predicts the y-value for a given x-value using simple linear regression (least squares method) fitted to the provided data points. (cost: 1 credit)

Input Schema

NameRequiredDescriptionDefault
target_xNonumber, required, the x-value for which to predict y
x_valuesNoarray of numbers, required, the x-coordinates of data points
y_valuesNoarray of numbers, required, the y-coordinates of data points (same length as x_values)

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A3.8/5.0
Behavior3/5

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

The annotations already establish that this is a read-only, idempotent, non-destructive operation. The description adds useful context in the form of the least-squares method and a one-credit cost, but it does not describe error behavior, data-length requirements, or the exact return shape.

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 and method, followed by a compact cost note. There is no redundant or wasted wording.

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 stateless calculation tool with full input-schema coverage and complete safety annotations, the definition is nearly complete. The missing detail is mainly what the prediction returns and any minimum-data or error constraints, but the core behavior is clear.

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 target_x, x_values, and y_values are already well documented in the schema. The description refers to x-values, y-values, and fitted data points but does not add syntax or validation meaning beyond what the schema provides.

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 names a specific verb and output: it predicts a y-value for a given x-value. It also identifies the exact method, simple linear regression via least squares, fitted to the provided data points, which makes it distinguishable from generic calculator or average tools.

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?

Usage is implied by the description: use this when you need a simple linear regression prediction from supplied x/y data points. However, it gives no explicit when-to-use conditions, prerequisites such as minimum data-point requirements, or named alternatives.

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

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.

Resources