Overview
Vault Infrastructure Overview
The PiggyBank vault infrastructure is a strategy-agnostic system for managing RWA assets on Solana. It allows vault creation with any underlying asset and provides liquid positions through tokenized shares.
Key Features
The infrastructure supports both Legacy and Token 2022 standards. Each vault operates independently with its own epoch lifecycle. Positions are represented by liquid tokens that maintain the same standard and decimals as the underlying asset.
Design Principles
The system separates vault infrastructure from strategy implementation. This allows:
Any admin to create vaults for their specific strategy
Users to maintain liquid positions they can transfer or trade
Strategies to evolve without infrastructure changes
Token Standards
The program compiles into two versions using compilation flags:
Legacy version for standard SPL tokens
Token 2022 version for RWAs requiring extensions
Token 2022 vaults support:
Scaled UI Amount for stock splits and distributions
Transfer Hook for compliance and access control
Lifecycle Management
Each vault has three state accounts tracking:
Vault configuration and totals
Epoch-specific data
Individual redemption records
The epoch system ensures orderly processing of deposits and redemptions while the admin manages the underlying assets according to their strategy.
Last updated