API
POST /api/verify
Verifies that a set A ⊆ ℤ/Nℤ contains no nontrivial solutions to a + 3b ≡ 2c + 2d (mod N). Elements are reduced mod N; duplicates after reduction are rejected. Limits: N ≤ 50,000 and |A| ≤ 10,000.
Requires an Authorization: Bearer <token> header — create a token
on your profile page. Requests without a valid token receive
401. A record-setting witness is saved and attributed to your account.
curl -X POST https://ruzsa-genus-one.icarm.cloud/api/verify \
-H 'content-type: application/json' \
-H 'authorization: Bearer ruzsa_...' \
-d '{ "N": 49, "A": [0, 7, 13, 29, 41], "commentary": "optional note for the witness page" }'
Returns 200 with the verdict, 401 without a valid token, or
400 if the body isn’t JSON of
the form {"N": <integer>, "A": [<integers>]} or violates the limits.
A valid witness that is larger than every previously recorded witness for its modulus
is saved, and record.recorded is true; otherwise
record.recordSize reports the standing record. When a valid submission ties the
record, record.tiedExact reports whether it is element-for-element the record
witness itself (true) or a different set of the same size (false).
An optional commentary string (at most 4,000 characters) becomes the new witness page’s commentary when — and only
when — the submission sets a record; the response then carries
commentaryApplied. It can be edited later on the witness page, with full
edit history kept. Commentary is plain text, except that witness#123
becomes a link to that witness’s page.
{
"ok": true,
"N": 49,
"size": 5,
"ratio": 0.7142857142857143, // |A| / sqrt(N)
"valid": true,
"record": { "recorded": true, "recordSize": 5 }
}
An invalid set instead gets valid: false and one concrete nontrivial solution
(no record field):
{
"ok": true,
"valid": false,
"counterexample": { "a": 3, "b": 1, "c": 1, "d": 2 }, // a + 3b ≡ 2c + 2d (mod N)
...
}
GET /database.json
All record witnesses as one JSON download: { count, witnesses }, each with
its modulus n, size, ratio, full elements
list, submitter, created_at, and current (false for
superseded records, which are kept as history). No auth required. Responses carry a weak
ETag (the body is compressed at the edge, which rules out a strong one);
conditional requests with If-None-Match return 304 when nothing
has changed.
MCP server: /mcp
The site is also a remote Model Context Protocol server, so AI chat clients
can verify and submit witnesses mid-conversation. Add
https://ruzsa-genus-one.icarm.cloud/mcp as a custom connector (Claude.ai:
Settings → Connectors; ChatGPT: developer-mode connectors; also works with Claude Code,
MCP Inspector, and other MCP clients). The connector flow signs you in with GitHub —
the same account as the website — and record submissions are attributed to you.
Tools: list_records, get_record (one modulus, with elements),
verify_witness, and submit_witness. Verification and submission
share the per-account rate limit.