Loops HousePetri

NEAR HACKATHON
Links
Team
1 member- NAOwner
Nakul Chodha
Overview
Problem: virtual pets get boring after a day, and their "AI" is a black box nobody can check. Petri pets are NEP-171 NFTs on NEAR that act like accounts: each pet holds its own NEAR balance and can have its own sub-account (pet-.) whose only key is a function-call key limited to charge_verified. Every chat reply comes from a NEAR AI Cloud model running in a TEE (DeepSeek, Intel TDX + NVIDIA H100 attestation checked off-chain). The contract ecrecovers the model's provider_tee signature on-chain, checks that the request uses this pet's own on-chain prompt, and only then debits the reply from the pet's balance and stores a receipt. If nobody feeds a pet for 24h, or its balance runs out, it falls asleep, and anyone can revive it with a tip. Two pets can meet in an on-chain Arena that anyone can settle: the winner is computed from the TEE-signed reply bytes by a published rule. Each pet also gets an EVM address via Chain Signatures, so it can receive tips from other chains (1Click dry quotes). Ownership is enforced: when a pet is sold, the seller's pet key stops working right away, and the buyer calls rekey_pet. Fans tip pets in Shitzu's real testnet SHITZU memecoin and stake it on a pet before an Arena round: books close before the replies are recorded, and the winner's backers split the pot pro-rata, with rules that can't be changed. Live on NEAR testnet at v2.petri-1793597952.testnet, with a hosted demo (https://anonymusk7.github.io/petri-demo/) where a Meteor wallet tips, bets, revives and swaps NEAR for SHITZU in the browser. 192 Rust tests and 59 JS tests, an offline verifier for the recorded TEE evidence, and a web UI with TEE-verified badges, per-pet history and an owner-only page.