Tools for agents: Exact polynomial interpolation

Recover an exact rational polynomial from sample points, with coefficients, residuals and evaluations.

Connect with MCP

{
  "mcpServers": {
    "super-agent-tools": {
      "url": "https://app.getsupers.com/sites/agent-polynomial-interpolation/mcp"
    }
  }
}
Streamable HTTP · No API key · Stateless

Use this URL in any client supporting remote Streamable HTTP MCP. Calls return structured JSON; inputs are processed without persistence.

Call interpolate_polynomial

Coefficients are ordered constant first: c[0] + c[1]*x + c[2]*x^2. The unique interpolating polynomial has degree below the number of distinct input x values. All numbers returned are exact fraction strings. JSON floats and booleans are rejected; quote decimal values. Equivalent duplicate x coordinates are rejected even when their y values agree. The zero polynomial has degree null and coefficients ["0"]. Residuals follow input point order; evaluations follow query order. Extrapolated flags identify queries outside the sample x range. This is exact interpolation, not noisy-data regression or a guarantee of predictive accuracy. Intended for small exact datasets. Arithmetic: https://docs.python.org/3/library/fractions.html

Input and output schemas
{
  "name": "interpolate_polynomial",
  "title": "Exact polynomial interpolation",
  "description": "Interpolate distinct rational (x,y) points; return ascending-power coefficients, exact residuals and evaluations. Integers or quoted rational/decimal strings only.",
  "inputSchema": {
    "properties": {
      "points": {
        "items": {
          "maxItems": 2,
          "minItems": 2,
          "prefixItems": [
            {
              "anyOf": [
                {
                  "type": "integer"
                },
                {
                  "type": "string"
                }
              ]
            },
            {
              "anyOf": [
                {
                  "type": "integer"
                },
                {
                  "type": "string"
                }
              ]
            }
          ],
          "type": "array"
        },
        "title": "Points",
        "type": "array"
      },
      "evaluate_at": {
        "items": {
          "anyOf": [
            {
              "type": "integer"
            },
            {
              "type": "string"
            }
          ]
        },
        "title": "Evaluate At",
        "type": "array"
      }
    },
    "required": [
      "points",
      "evaluate_at"
    ],
    "title": "interpolate_polynomialArguments",
    "type": "object"
  },
  "outputSchema": {
    "additionalProperties": true,
    "title": "interpolate_polynomialDictOutput",
    "type": "object"
  },
  "icons": null,
  "annotations": {
    "title": null,
    "readOnlyHint": true,
    "destructiveHint": false,
    "idempotentHint": true,
    "openWorldHint": false
  },
  "meta": null,
  "execution": null
}

Run the example to see the actual result.

HTTP alternative

POST https://app.getsupers.com/sites/agent-polynomial-interpolation/call
Content-Type: application/json

{
  "points": [
    [
      0,
      1
    ],
    [
      1,
      3
    ],
    [
      2,
      7
    ]
  ],
  "evaluate_at": [
    "1/2",
    3
  ]
}

The HTTP and MCP interfaces execute the same implementation. Validation errors are returned explicitly. See the tool notes above for its supported inputs and behavior.