fhevm-skill AGENTS.md

Project instructions for coding agents working on Zama FHEVM v0.11, a toolkit for building smart contracts that process encrypted data on Ethereum-compatible networks.

In plain words
What is it for?
Use them when editing Solidity contracts or applications that import FHEVM packages, use encrypted value types, or integrate Zama’s SDKs.
Why use it?
They tell the agent when the project uses FHEVM and which architecture and setup assumptions to follow, reducing incompatible code changes.

Instructions file for CodexOpenCode

Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

agentmods
npx agentmods add instructions/zunmax/fhevm-skill/agents-md
Clone the repo
git clone --depth 1 https://github.com/zunmax/fhevm-skill

Made for: Codex, OpenCode.

Per session 3,675 This file is loaded in full into every session.
When invoked 3,675 The same file — it is already loaded in full.
Security scan A 0 findings. Scan, not verified.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5 $0.03675 $0.03675
Opus 5 $0.01837 $0.01837
Sonnet 5 $0.00735 $0.00735
Haiku 4.5 $0.00367 $0.00367

Measured 2d ago against content hash f1dc14bf14ad, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

fhevm-skill AGENTS.md scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 2d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

AGENTS.md · 140 lines

How it starts

The opening of the file, as written. The whole thing — 140 lines — stays where its author put it; the contents beside it link to each section on GitHub.

AGENTS.md - FHEVM project guidance

This file is the project guidance loaded by AGENTS.md-aware coding agents (Codex CLI, Aider, Cline, Continue, Zed, Jules, etc.). It activates only when the project touches Zama FHEVM v0.11. If the project has no FHEVM imports, encrypted types, or FHEVM error strings, ignore this file.

Activation

Apply this file whenever you edit code that touches Zama FHEVM v0.11. Trigger conditions:

  • Imports @fhevm/solidity, @fhevm/hardhat-plugin, @fhevm/mock-utils, @zama-fhe/relayer-sdk (legacy primitives), @zama-fhe/sdk (new high-level SDK v3+), @zama-fhe/react-sdk (new React hooks v3+), or @openzeppelin/confidential-contracts. Sub-paths count: @zama-fhe/sdk/node, @zama-fhe/sdk/viem, @zama-fhe/sdk/ethers, @zama-fhe/sdk/cleartext, @zama-fhe/sdk/query, @zama-fhe/react-sdk/wagmi, plus the legacy @zama-fhe/relayer-sdk/web|bundle|node.
  • Declares or uses euint8-euint256, ebool, eaddress, externalEuint*.
  • Contract inherits ZamaEthereumConfig (the only current Solidity base), or any legacy SepoliaConfig / MainnetConfig Solidity base from a pre-v0.9 codebase that needs migrating. (MainnetConfig and SepoliaConfig do exist as TS exports in @zama-fhe/relayer-sdk/web and @zama-fhe/sdk for frontend SDK config - those are unrelated to Solidity inheritance.)
  • Code uses any new-SDK identifier: ZamaSDK, ZamaProvider, RelayerWeb, RelayerNode, RelayerCleartext, ViemSigner, EthersSigner, WagmiSigner, GenericSigner, Token, ReadonlyToken, WrappersRegistry, IndexedDBStorage, MemoryStorage, ChromeSessionStorage, matchZamaError, zamaQueryKeys, TOKEN_TOPICS, ACL_TOPICS; or any of the 59 React hooks (useShield, useUnshield, useUnshieldAll, useResumeUnshield, useConfidentialBalance, useConfidentialBalances, useConfidentialTransfer, useConfidentialTransferFrom, useConfidentialApprove, useConfidentialIsApproved, useAllow, useIsAllowed, useRevoke, useRevokeSession, useEncrypt, useUserDecrypt, usePublicDecrypt, useGenerateKeypair, useDelegateDecryption, useRevokeDelegation, useDelegationStatus, useDecryptBalanceAs, useBatchDecryptBalancesAs, useActivityFeed, useToken, useReadonlyToken, useMetadata, useUnderlyingAllowance, useWrapperDiscovery, useWrappersRegistryAddress, useListPairs, useTokenPair*, useConfidentialTokenAddress, useTokenAddress, useIsConfidentialTokenValid, useUnwrap, useUnwrapAll, useFinalizeUnwrap).
  • User mentions FHEVM, Zama, TFHE, confidential contracts, encrypted balances, homomorphic computation, confidential dApp, ERC-7984, shielding / unshielding tokens, confidential transfers, the Zama Protocol, the wrappers registry, or the relayer SDK.
  • Errors mention any FHEVM custom error: ACL (SenderNotAllowed, ACLNotAllowed, SenderNotAllowedToUseHandle), input verification (InvalidInputHandle, EmptyInputProof, DeserializingInputProofFail), KMS decrypt (InvalidKMSSignatures, KMSInvalidSigner, EmptyDecryptionProof), runtime (DivisionByZero, NotPowerOfTwo, ZamaProtocolUnsupported), or HCU (HCUTransactionLimitExceeded, HCUTransactionDepthLimitExceeded); or WASM / COOP / COEP issues in an FHEVM project.

Read the full file on GitHub · 140 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 2d ago First seen · 140 lines · 3,675 tokens per session scan A f1dc14bf14ad

Subscribe to this mod's changes

fhevm-skill AGENTS.md is an instructions file published in the GitHub repository zunmax/fhevm-skill (2 stars, last pushed 2mo ago), licensed MIT. It adds 3,675 tokens to every session, about $0.0184 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-31.