A decentralized platform for creating and acknowledging expressions of peace, with verifiable proof stored on the blockchain.
Proof of Peacemaking is a Web3 platform that enables users to:
- Create expressions of peace on the blockchain
- Acknowledge and support peaceful resolutions
- Generate verifiable proof of agreements
- Earn soulbound NFTs for meaningful contributions
- Wallet Integration: Secure authentication with MetaMask
- Expression Creation: Share and document peaceful resolutions
- Acknowledgements: Support and verify expressions of peace
- Activity Feed: Real-time updates of community activity
- User Dashboard: Track personal contributions and stats
- Proof NFTs: Earn soulbound tokens for verified agreements
-
Nick Mudge for his initiative, Diamond Pattern (EIP-2535)
-
The Ethereum community for blockchain infrastructure
-
Protocol Labs for IPFS and Filecoin
-
The Golang and Fiber communities for excellent tooling
-
All contributors who have helped shape this project
- Language: Go 1.21+
- Framework: Fiber (high-performance web framework)
- Database: MongoDB (for user data and sessions)
- Authentication: Ethereum wallet-based (MetaMask)
- Core: HTML5, CSS3, JavaScript
- Web3: ethers.js for blockchain interaction
- Styling: Custom CSS with responsive design
- Blockchain: Ethereum (Sepolia testnet)
- Smart Contracts: Solidity with Diamond Pattern
- Storage: IPFS for decentralized content
proof-of-peacemaking/
├── cmd/ # Application entrypoints
├── internal/ # Internal packages
│ ├── core/ # Core business logic
│ │ ├── domain/ # Domain models
│ │ ├── ports/ # Interfaces
│ │ └── services/ # Business logic implementation
│ ├── handlers/ # HTTP handlers
│ ├── middleware/ # HTTP middleware
│ └── repositories/ # Data access layer
├── web/ # Web assets
│ ├── static/ # Static files (JS, CSS)
│ └── templates/ # HTML templates
├── contracts/ # Smart contracts
└── docs/ # Documentation
The project uses the Diamond Pattern for upgradeable and modular smart contracts:
contracts/
├── Diamond.sol # Main diamond contract
├── facets/
│ ├── DiamondCutFacet.sol # Handles upgrades
│ ├── DiamondLoupeFacet.sol # Contract inspection
│ ├── ExpressionFacet.sol # Expression functionality
│ ├── AcknowledgementFacet.sol # Acknowledgement functionality
│ ├── POPNFTFacet.sol # NFT minting functionality
│ └── PermissionsFacet.sol # Permission management
├── libraries/
│ ├── LibDiamond.sol # Diamond storage & core functions
│ ├── LibStorage.sol # Shared storage structure
│ └── LibPermissions.sol # Permission & subsidy logic
└── interfaces/
├── IDiamondCut.sol # Diamond upgrade interface
└── IDiamondLoupe.sol # Diamond inspection interface
The Diamond Pattern provides several key advantages for our smart contract architecture:
-
Storage Management
- Solves the contract size limitation (24KB)
- Enables shared storage between facets
- Provides structured storage patterns
-
Modularity
- Separates concerns into focused facets
- Enables independent testing and auditing
- Simplifies maintenance and updates
-
Upgradeability
- Allows adding new functionality
- Enables bug fixes without redeployment
- Preserves contract state during upgrades
-
Gas Efficiency
- Optimizes function selector handling
- Reduces deployment costs through reuse
- Enables gas-optimized storage patterns
-
Security
- Immutable core functionality
- Granular access control
- Transparent upgrade process
sequenceDiagram
participant User1 as Expression Creator
participant User2 as Acknowledger
participant D as Diamond Proxy
participant EF as Expression Facet
participant AF as Acknowledgement Facet
participant NF as NFT Facet
participant IPFS
Note over User1,IPFS: 1. Expression Creation
User1->>IPFS: Upload content
IPFS-->>User1: Return IPFS hash
User1->>D: createExpression()
D->>EF: delegate call
Note right of EF: Check subsidization
EF-->>User1: ExpressionCreated event
Note over User2,IPFS: 2. Acknowledgment
User2->>IPFS: Upload content
IPFS-->>User2: Return IPFS hash
User2->>D: createAcknowledgement()
D->>AF: delegate call
Note right of AF: Check subsidization
AF-->>User2: AcknowledgementCreated event
Note over User1,User2: 3. NFT Minting
User1->>D: Sign for NFT
User2->>D: Sign for NFT
D->>NF: mintProofs()
NF-->>User1: Mint NFT
NF-->>User2: Mint NFT
-
ExpressionFacet
- Creates and stores expressions
- Manages expression metadata
- Emits events for frontend tracking
-
AcknowledgementFacet
- Links acknowledgments to expressions
- Prevents duplicate acknowledgments
- Maintains acknowledgment history
-
POPNFTFacet
- Creates soulbound NFTs
- Manages dual-signature minting
- Stores comprehensive metadata
-
PermissionsFacet
- Manages operator permissions
- Controls gas subsidization
- Handles access control
classDiagram
User "1" -- "*" Expression
User "1" -- "*" Acknowledgement
User "1" -- "*" Notification
User "1" -- "*" Session
Expression "1" -- "*" Acknowledgement
Expression "1" -- "1" ProofNFT
User "1" -- "*" ProofNFT
Notification "1" -- "*" UserNotification
User "1" -- "*" UserNotification
class User {
+ID ObjectID
+Address string
+Email string
+Nonce int
+CreatedAt time
+UpdatedAt time
}
class Expression {
+ID ObjectID
+Content string
+CreatorAddress string
+AcknowledgementCount int
+CreatedAt time
}
class Acknowledgement {
+ID ObjectID
+ExpressionID ObjectID
+CreatorAddress string
+Content string
+CreatedAt time
}
class ProofNFT {
+ID ObjectID
+TokenID string
+ExpressionID ObjectID
+OwnerAddress string
+Approved bool
+CreatedAt time
}
class Session {
+ID ObjectID
+UserID ObjectID
+Token string
+Address string
+ExpiresAt time
+CreatedAt time
+UpdatedAt time
}
class Notification {
+ID ObjectID
+Type string
+Title string
+Content string
+CreatedAt time
}
class UserNotification {
+ID ObjectID
+UserID ObjectID
+NotificationID ObjectID
+Read bool
+CreatedAt time
+UpdatedAt time
}
✅ Completed
- Basic authentication with MetaMask
- Session management
- User profile system
- Basic frontend structure
- Smart contract architecture (Diamond Pattern)
🚧 In Progress
- Expression creation and management
- Acknowledgement system
- Activity feed implementation
- User dashboard
- IPFS integration for content storage
- Expression creation and management
- Multimedia support (text, images, audio)
- Content moderation system
- Expression categorization
- Acknowledgement system
- Dual-signature verification
- Acknowledgement types and categories
- Reputation system
- Deploy Diamond proxy contract
- Implement and test facets:
- Expression management
- Acknowledgement handling
- NFT minting
- Permission management
- Implement gas subsidization system
- Develop operator management
- Create sponsorship program
- Apply for ecosystem grants:
- Ethereum Foundation
- Protocol Labs
- Web3 Foundation
- Community building
- Ambassador program
- Educational content
- Community events
- Partnership development
- Peace organizations
- Academic institutions
- Web3 projects
- Soulbound NFT implementation
- Proof of peacemaking tokens
- Achievement badges
- Reputation tokens
- Advanced analytics
- Peace impact metrics
- Community engagement stats
- Network effect analysis
- Grant applications
- Sponsorship programs
- Ecosystem fund
- Sustainable revenue model
- Governance system
- Community voting
- Proposal system
- Treasury management
- Integration possibilities
- Cross-chain support
- Layer 2 solutions
- Other peace initiatives
To make the platform accessible to all users, we're implementing a comprehensive gas subsidization strategy:
-
Target Groups
- Peace organizations
- Academic institutions
- Non-profit entities
- Individual peacemakers
- Developing region users
-
Funding Sources
- Ecosystem grants
- Corporate sponsorships
- Foundation partnerships
- Community treasury
-
Implementation
- Smart contract operator system
- Gas cost estimation
- Usage limits and caps
- Transparent reporting
-
Sustainability
- Long-term partnerships
- Renewable funding sources
- Community governance
- Impact metrics
We're actively seeking:
- Contributors (technical and non-technical)
- Partners and sponsors
- Grant opportunities
- Community ambassadors
For collaboration opportunities, please:
- Check our Contributing Guidelines
- Join our discord
- Contact us at [email protected]
- Go 1.21+
- MongoDB 6.0+
- Node.js 18+ (for contract development)
- MetaMask wallet
- Clone the repository
git clone https://github.com/stateful-art/proof-of-peacemaking.git
cd proof-of-peacemaking
- Set up environment variables
cp .env.example .env
# Edit .env with your configuration
- Install dependencies
go mod download
- Run the application
go run cmd/server/main.go
The application will be available at http://localhost:3003
go test ./...
cd contracts
npm install
npx hardhat test
This project is licensed under the GNU General Public License v3.0.