Listen to the pool
An afterSwap or afterAddLiquidity callback detects real activity and decides whether to mint.
Unicats
Uniswap V4 hook object
A simple on-chain cat collection: clean shapes, deterministic seeds, and lightweight metadata so the hook can mint at scale without losing personality.
Mint flow
The concept: each valid pool event produces a seed, the seed selects simple traits, and the contract mints the NFT to the user who triggered the action.
Unicats collection
Hook V4
An afterSwap or afterAddLiquidity callback detects real activity and decides whether to mint.
Pool, trader, tick, block, and nonce produce a hash; traits and rarity come from that seed.
The contract records the Unicat, stores seed/metadata, and delivers the ERC-721 to the receiver.
afterSwap(pool, sender, delta) {
if (delta.volume > mintThreshold) {
seed = keccak256(pool, sender, block.number, nextId);
_mintUnicat(sender, nextId, seed);
}
}
Mass generator
This folder includes a local generator that produces SVGs and JSON metadata. Change the count and move from a small sample to a full collection.