Decentralized Peer-Learning & Micro-Funding powered by Solana and AI.
peerchain/
├── anchor/ # Solana Smart Contracts (Rust/Anchor)
│ ├── programs/
│ │ └── peerchain/ # Core logic for Reputation & Funding
│ │ └── src/
│ │ ├── lib.rs # Program instructions
│ │ └── state.rs # Account definitions
│ ├── Anchor.toml # Anchor configuration
│ └── DEPLOYMENT.md # Deployment guide
├── app/ # Next.js Frontend (Generated via v0 by Vercel)
│ ├── components/ # Reusable UI elements
│ │ ├── dashboard/ # Dashboard components
│ │ ├── shared/ # Wallet, Sidebar, Layout
│ │ └── ui/ # Shadcn UI primitives
│ ├── api/ # API routes (Backend logic)
│ │ ├── sessions/ # Session logging
│ │ ├── funding/ # Funding requests
│ │ ├── reputation/ # Reputation system
│ │ └── tts/ # ElevenLabs TTS
│ ├── lib/ # Utilities & Providers
│ │ ├── solana-provider.tsx
│ │ └── wallet-context.tsx
│ └── hooks/ # Custom React hooks
├── shared/ # Shared types and interfaces
│ └── types/
├── docs/ # Project documentation
├── scripts/ # Setup and deployment scripts
└── README.md # This file
- Blockchain: Solana (Anchor Framework, Rust)
- Frontend: Next.js 15, React 19, Tailwind CSS, Shadcn UI
- Wallet: Solana Wallet Adapter (Phantom, Solflare)
- AI: ElevenLabs (Text-to-Speech)
- Deployment: Vercel (Frontend), Solana Devnet (Contracts)
git clone <repo-url>
cd peerchain
npm installcp .env.example .env.local
# Edit .env.local with your keys:
# - ELEVENLABS_API_KEY (get from elevenlabs.ai)
# - NEXT_PUBLIC_PROGRAM_ID (after deploying the Solana program)cd anchor
# Install Solana CLI and Anchor first (see anchor/DEPLOYMENT.md)
anchor build
anchor deploy
# Copy the program ID to .env.localnpm run dev- Connect Phantom Wallet - Use the "Connect Wallet" button
- Create Profile - Initialize on-chain profile (via program)
- Join Mentorship Session - Log learning sessions
- Build Reputation - Earn reputation points
- Request Funding - Submit micro-funding requests
- Voice Integration - Generate audio briefs with ElevenLabs
- Real wallet integration (Phantom)
- On-chain program (Anchor)
- Transaction history visible on Explorer
- PDA-based account structure
- Polished UI components
- Responsive dashboard
- Smooth onboarding flow
- Clean component architecture
- Text-to-speech integration
- Audio briefs for funding pitches
- Accessible audio content
- Educational accessibility
- Transparent funding system
- Measurable trust/reputation system
GET/POST /api/sessions- Session managementGET/POST /api/funding- Funding requestsGET/POST /api/reputation- Reputation trackingGET/POST /api/tts- ElevenLabs audio generation
- Uses Solana Devnet (free transactions)
- Program ID needs to be updated after deployment
- ElevenLabs API key required for audio features
- Wallet must be connected to use blockchain features
Wallet not connecting?
- Ensure Phantom is installed
- Switch to Devnet in Phantom settings
- Check browser console for errors
Audio not generating?
- Verify ELEVENLABS_API_KEY in .env.local
- Check API key has sufficient credits
Program deployment failing?
- See
anchor/DEPLOYMENT.mdfor detailed guide - Ensure Solana CLI is configured for devnet
**Solana program ID is still the System Program placeholder (
Fg6PaFpoGXkYsidMpWTK6W2BeZ7FEfcYkg476zPFsLnS). You must:
- Install Solana CLI and Anchor
- Run
anchor build && anchor deploy - Copy the new program ID to
anchor/programs/peerchain/src/lib.rsand.env.local