A decentralized prediction markets platform powered by AI oracles on the Sui blockchain.
Live Demo: aletheia-app.vercel.app
Aletheia (Greek for "truth") is a next-generation prediction market platform that leverages AI-powered oracles and blockchain technology to create trustless markets for forecasting real-world events. Built on the Sui blockchain, it enables users to trade on the outcome of events with automated market making and AI-driven resolution.
- Framework: Next.js 14 with TypeScript
- Styling: Tailwind CSS
- Charts: Chart.js, Recharts
- Web3: Sui dApp Kit
- Runtime: Node.js with Express
- Database: MongoDB with Mongoose
- Real-time: Socket.io
- Platform: Sui
- Language: Move
- Features: Automated Market Making (LMSR), SEAL encryption
- AI Models: Multiple LLM providers for consensus
- Resolution: Automated market resolution with multi-model validation
- Multi-outcome markets: Support for 2-10 possible outcomes
- Automated Market Making: LMSR (Logarithmic Market Scoring Rule) algorithm
- Real-time odds: Live probability updates based on trading activity
- Liquidity provision: Users can add liquidity to markets
- Privacy: SEAL encryption for private markets
- Time-locked: Markets can be sealed until a specific date
- Premium features: Encrypted comments and exclusive access
- Multi-model consensus: Uses multiple AI models for resolution
- Automated resolution: Markets resolve automatically based on real-world outcomes
- Nautilus integration: External data verification
- Live probability charts: Visualize market sentiment over time
- Portfolio tracking: Track your positions and P&L
- Market history: Historical data and trends
Aletheia/
├── backend/ # Express.js API server
│ ├── src/
│ ├── package.json
│ └── ...
├── frontend/ # Next.js frontend
│ ├── src/
│ ├── package.json
│ └── ...
├── oracle/ # AI oracle service
│ ├── src/
│ ├── package.json
│ └── ...
├── contracts/ # Sui Move smart contracts
│ └── sources/
├── e2e/ # End-to-end tests
│ ├── package.json
│ └── ...
└── package.json # Root workspace config
npm run devs # Build all and run all dev servers
npm run build:all # Build backend, oracle, and frontend
npm run dev:all # Run all services in parallel
npm run dev:backend # Run backend on port 3001
npm run dev:oracle # Run oracle service
npm run dev:frontend # Run frontend on port 3000
npm run test # Run E2E tests- Node.js 18+
- MongoDB instance
- Sui wallet with testnet/mainnet SUI
- API keys for AI providers
# Install all dependencies
npm install
# Or install individually
cd backend && npm install
cd frontend && npm install
cd oracle && npm installCreate .env files in each directory (see .env.example files for reference).
# Run all services in development mode
npm run devs
# Or run individually
npm run dev:backend # Backend on port 3001
npm run dev:oracle # Oracle service
npm run dev:frontend # Frontend on port 3000
# Build all services
npm run build:all
# Run E2E tests
npm test- Market Creation: Anyone can create a prediction market with multiple outcomes
- Trading: Users buy shares in outcomes they believe will occur
- Price Discovery: LMSR algorithm adjusts prices based on demand
- Resolution: AI oracles determine the outcome after market close
- Settlement: Winners receive payouts proportional to their shares
The platform uses several Move modules:
prediction_market: Core market functionalityamm: Automated market makingoracle: Oracle integrationseal: Encryption for sealed markets
- Mainnet deployment
- Mobile app
- Advanced charting
- Social features (following, profiles)
- Token incentives
- Cross-chain markets
Preyam - GitHub
MIT