x402agent/SolanaOS / skills/solana-formal-verification
qedgen
FlaggedFormally verify programs by writing Lean 4 proofs. Trigger this skill whenever the user wants to formally verify code, generate Lean 4 proofs, prove properties about algorithms or smart contracts, verify invariants, convert program logic into formal specifications, or anything involving Lean 4 and formal verification. Also trigger when the user mentions "qedgen", "lean proof", "formal proof", "verify my code", "prove correctness", "formal verification", or wants mathematical guarantees about their implementation.
crates/qedgen/lean_support/QEDGen/Solana/Token.lean
View on GitHubimport QEDGen.Solana.Account
namespace QEDGen.Solana.Token
open QEDGen.Solana.Account
/- ============================================================================
Token API - Legacy Module
DEPRECATED: This module is kept for backwards compatibility only.
For new proofs, use QEDGen.Solana.Cpi instead.
NEW APPROACH: We verify CPI parameter correctness, not balance preservation.
See QEDGen.Solana.Cpi for the modern verification approach.
============================================================================ -/
structure Mint where
id : Nat := 0
deriving Repr, DecidableEq, BEq
structure Program where
id : Nat := 0
deriving Repr, DecidableEq, BEq
abbrev TokenAccount := Account
def trackedTotal (accounts : List Account) : Nat :=
accounts.foldl (fun acc account => acc + account.balance) 0
theorem trackedTotal_nil : trackedTotal [] = 0 := by
rfl
-- NOTE: The following axioms are DEPRECATED and will be removed in a future version.
-- Use QEDGen.Solana.Cpi for new proofs instead.
end QEDGen.Solana.Token
namespace QEDGen.Solana
-- Legacy exports (deprecated - use QEDGen.Solana.Cpi instead)
abbrev TokenAccount := QEDGen.Solana.Token.TokenAccount
abbrev Mint := QEDGen.Solana.Token.Mint
abbrev Program := QEDGen.Solana.Token.Program
abbrev trackedTotal := QEDGen.Solana.Token.trackedTotal
abbrev trackedTotal_nil := QEDGen.Solana.Token.trackedTotal_nil
end QEDGen.Solana
Related skills
| Skill | Stars | Updated | Works with | Status | Install |
|---|---|---|---|---|---|
| reverse-engineer-anythingmorluto/reaReverse engineer native, managed, Electron/JavaScript, packaged, firmware, and browser targets with REA, and build agent environments (AgentEnv bundles) of web applications from a live instance or a capture, and of Linux desktop apps with a task from a request. Use shipped-artifact or requested runtime evidence to explain features, compare versions, decompile code, or guide a reconstruction. Skip REA for ordinary source-repository architecture analysis. | Stars: 472k | Updated | Claude CodeCodex | Verified | Install |
| diagnosing-superpowersobra/superpowersUse when a superpowers session went wrong and your human partner wants to know why — repeated work, ignored plans, stumbles, poor results, a skill that didn't fire, "it took too long", "why is it so expensive", "what is it doing" — or wants to build a bug report for the superpowers maintainers, for the current session or a past one identified by id or path, on any harness. | Stars: 323k | Updated | Claude CodeCodex | Verified | Install |
| dispatching-parallel-agentsobra/superpowersUse when facing 2+ independent tasks that can be worked on without shared state or sequential dependencies | Stars: 323k | Updated | Claude CodeCodex | Verified | Install |
| executing-plansobra/superpowersUse when executing an implementation plan in the current session as the implementer yourself — your human partner chose inline execution, or no subagent tool is available | Stars: 323k | Updated | Claude CodeCodex | Verified | Install |