Clear Signing Helper

Turns a deployed contract into an ERC-7730 descriptor and test file for the clear-signing registry, so wallets show your transactions as readable text instead of hex. It computes everything with one right answer, asks you only what the contract cannot answer, and runs the registry's own checks before you open the pull request.

0.6.0-preview.2MIT GitHub and README ยท npm

Use it

Paste one of these into Claude Code, Cursor or another coding agent. In your Foundry repo:

read https://github.com/portdeveloper/clear-signing-helper and use it to make the contracts in this repo clear-signable

For a deployed contract verified on Sourcify:

read https://github.com/portdeveloper/clear-signing-helper and use it to make my contract clear-signable: <address> on <chain>

The agent checks whether the registry already covers your protocol, runs the tool, asks you the few questions only you can answer, and stops at a reviewed draft. You open the PR.

If you are an AI agent

Follow SKILL.md (also in llms.txt). In short:

  1. Search the registry first. If the protocol is there, add the chain with clear-signing registry add-deployment.
  2. Otherwise run clear-signing init, then decisions, fill the decisions file, and apply. Do not write descriptor JSON by hand.
  3. Ask the user for intent wording, which token an amount is in, and what to hide whenever the hints do not settle it. Do not guess.
  4. Set "author": "llm:<your model>". Put "author": "human" only on the values the user decided.
  5. Run fixture (real transactions with --tx <hash> --rpc-url <url> where they exist), preview, check, and export --registry-runners. Let the user look at the preview before review --accept.
  6. Stop at the exported bundle and show the user the diff and the git commands. Open the PR only if the user explicitly asks, from an account tied to the contract owner.

What it does

It never signs or sends transactions, and never opens the PR. Not yet supported: writing new EIP-712 descriptors, and nested calls.

Why use it

Other tools (erc7730, Ledger's JSON Builder, Cyfrin's clearsig) draft a descriptor. None writes the test file with its expected wallet text, or runs the registry's CI checks before you submit.

A capable agent can get there alone, but with the tool it was faster and cheaper: 7.6 to 8.2 min and about $2.60 per run, against 11.6 to 22.5 min and up to $4.36 without (comparison). On 9 contracts the registry later fixed after an audit, an agent using it avoided 10 of 11 of the auditors' findings (audit replay). Both are small samples.

First submission: registry PR #3003, produced by the tool, green on every registry check, awaiting maintainer review.