Skip to main content
Glama

ScorpTech x402 Tools

Lah

lah
Read-onlyIdempotent

The unsigned Lah number L(n, k). L(0, 0) is 1, L(n, 0) is 0 for n > 0, and L(n, 1) is n!. L(5, 2) is 240, and L(6, 3) is 1200. n and k run from 0 to 20, and k must not pass n. Past 15 digits the value is a decimal string. Returns JSON with: n, k, value. Price: $0.001 USDC per successful call (x402, Base or Solana). Same tool over HTTPS: POST https://scorptech.it.com/api/x402/v1/lah

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "n": "<n>",
      "k": "<k>"
    },
    "name": "lah"
  }
}

Input Schema

NameRequiredDescriptionDefault
kYes
nYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. Added

TDQS

A4.2/5.0
Behavior4/5

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

Annotations already declare readOnlyHint, idempotentHint, destructiveHint=false and openWorldHint, so the safety profile is covered. The description adds genuinely new behavior: a per-call charge of $0.001 USDC settled through x402 on Base or Solana, values beyond 15 digits returned as a decimal string, and the exact response keys (n, k, value). The only missing piece is failure behavior when payment is declined or arguments are out of range.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The definition is front-loaded with the identity and base cases, then constraints, then output shape and price, so an agent can stop reading as soon as it has what it needs. It is dense rather than padded, though the two worked examples and the duplicated HTTPS endpoint add length that a compact statement could carry.

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

Completeness5/5

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

There is no output schema, and the description compensates by specifying the returned JSON keys and the >15-digit string encoding. With bounds, a validity constraint, pricing, payment rail, and an alternate HTTPS route all present, nothing an agent needs to invoke this correctly is missing.

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

Parameters4/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 carry the meaning, and it does: both parameters are bounded to 0-20 and k must not pass n, which is extra semantics beyond the JSON schema's per-field min/max. It still treats n and k purely as indices to the named function rather than explaining their combinatorial meaning, so it falls just short of full compensation.

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 unsigned Lah number L(n, k)" names the exact mathematical object computed and then pins it down with base cases (L(0,0)=1, L(n,0)=0, L(n,1)=n!) and worked examples (L(5,2)=240, L(6,3)=1200). An agent can tell this evaluates a single (n,k) pair, which distinguishes it from row-style siblings such as lah_row.

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 gives hard domain constraints (n and k from 0 to 20, k must not exceed n) and a payment precondition ($0.001 USDC per successful call via x402), which shape when the call is valid. It never states when to prefer this over alternatives like lah_row or when a different tool would be more appropriate, so selection guidance remains implicit.

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