Guide

Agents

Every tool over local or remote MCP and Pi and OMP and the AI SDK. What they take and what the model reads back

Same tools, every host

The MCP server, the Pi and OMP extensions and @agntn/curves/ai all call the same executors. Same arguments, same checks, same text back. This site runs them too, so every full response on it is exactly what a model reads.

ToolDoesArguments
curves_computeArithmetic on y² = x³ + ax + b over a prime you giveoperation, a, b, p, point, other, scalar, order, limit
curves_secp256k1_computePoint math on secp256k1 with SEC1 hex, ECDSA sign, verify and recoveroperation, point, other, scalar, secret, x, signature, digest, hash, recovery, lowS, compressed
curves_bip340_computeBIP340 Schnorr keys and signatures with x-only keysoperation, secret, random, publicKey, message, signature
curves_p256_computePoint math on P-256 with SEC1 hex, ECDSA sign, verify and recoveroperation, point, other, scalar, secret, x, signature, digest, hash, recovery, lowS, compressed
curves_p384_computePoint math on P-384 with SEC1 hex, ECDSA sign, verify and recoveroperation, point, other, scalar, secret, x, signature, digest, hash, recovery, lowS, compressed
curves_p521_computePoint math on P-521 with SEC1 hex, ECDSA sign, verify and recoveroperation, point, other, scalar, secret, x, signature, digest, hash, recovery, lowS, compressed
curves_brainpoolp256r1_computePoint math on brainpoolP256r1 with SEC1 hex, ECDSA sign, verify and recoveroperation, point, other, scalar, secret, x, signature, digest, hash, recovery, lowS, compressed
curves_brainpoolp384r1_computePoint math on brainpoolP384r1 with SEC1 hex, ECDSA sign, verify and recoveroperation, point, other, scalar, secret, x, signature, digest, hash, recovery, lowS, compressed
curves_brainpoolp512r1_computePoint math on brainpoolP512r1 with SEC1 hex, ECDSA sign, verify and recoveroperation, point, other, scalar, secret, x, signature, digest, hash, recovery, lowS, compressed
curves_sr25519_computePolkadot keys, signatures and HDKD on sr25519operation, seed, secret, publicKey, message, encoding, signature, context, chainCode, hard, random
curves_ed25519_computeEd25519 keys and signatures, verified with ZIP 215 or strict rulesoperation, secret, publicKey, message, signature, zip215
curves_ed448_computeEd448 signatures, verified under their contextoperation, publicKey, message, signature, context

Install

shell
pi install npm:@agntn/curves
omp install @agntn/curves

Any other MCP client takes the stdio server:

json
{
  "mcpServers": {
    "curves": { "command": "npx", "args": ["-y", "@agntn/curves", "mcp"] }
  }
}

No Node at hand? claude mcp add --transport http curves https://curves.agntn.dev/mcp gets the same tools from this site, next to its page tools. The arithmetic runs on a Cloudflare worker then, so the public points you send ride along.

What a model reads

One line of JSON, the same object the harness gets as details:

text
{"operation":"log","order":"19","scalar":"13"}

Why strings for numbers? JSON has no bigint, and a model would round a 77 digit integer without blinking. Integers go in as decimal or 0x hex and come out as decimal. The point at infinity comes out as "infinity".

points says how many there are and whether it stopped short. Infinity is a point of the group too, so a full listing gives it the front seat and total agrees with count:

text
{"operation":"points","total":"19","points":["infinity",{"x":"0","y":"6"},{"x":"0","y":"11"}],"truncated":true}

Ask for one order and infinity turns up only for 1, the one order it has.

What it refuses

  • An argument the operation doesn't take. count with a scalar is an error, not a shrug.
  • A point off the curve, a p that isn't prime, a singular curve.
  • Work past the limits in Orders and logs. The error names the limit.
  • On secp256k1 and P-256, a sum that lands on infinity. SEC1 has no form for it.

A blank optional string counts as missing. OMP fills every field, and a model loves an empty "".

The scalar is in the transcript

curves_secp256k1_compute and curves_p256_compute multiply a point by a scalar. Multiply G by a private key and you get its public key. Fine for a puzzle. But the key is now in the chat log, so pass public tweaks or keys you'd happily burn.

The secp256k1 sign drops the pretense and takes the private key outright. So do keypair and sign on the BIP340 and Ed25519 tools. Same rule, burners only.

curves_sr25519_compute is worse at keeping secrets, by design. keypair and derive hand secrets back, and sign takes one in. A hard child from a seed returns its seed too. Dev accounts and burners only.