A decentralized platform for sharing and validating financial market data across a peer-to-peer network.
Still WORK IN PROGRESS
P2P Market Data enables secure, distributed sharing of financial market data between trusted peers. It uses blockchain-inspired consensus mechanisms to validate data integrity and source reputation.
- Decentralized P2P network for data sharing
- Real-time market data validation
- Reputation-based peer scoring
- Data integrity verification
- Configurable data sources
- Dark/light theme support
- Frontend: React + TypeScript + Vite
- Backend: Go
- UI Components: shadcn/ui
- P2P Network: libp2p
- Desktop: Wails
- Database: PostgreSQL
# Clone repository
git clone https://github.com/danielsobrado/p2p_market_data.git
cd p2p_market_data
# Install dependencies
go mod download
cd frontend && npm install
# Build frontend assets (required by Go embed)
cd frontend && npm install && npm run build && cd ..
# Setup database schema (only needed if you are managing Postgres outside the app)
for f in sql/schema/*.sql; do psql -U postgres -d market_data -f "$f"; done# Development
wails dev
# Build
wails build
When the Wails app starts its embedded PostgreSQL instance, it now initializes the required schema automatically.
├── cmd/ # Application entrypoints
│ └── app/ # Main application
├── pkg/ # Core packages
│ ├── config/ # Configuration management
│ ├── data/ # Data models/repository/schema
│ ├── database/ # Database service lifecycle
│ ├── p2p/ # P2P networking (host/voting/authority)
│ ├── scripts/ # Script execution and management
│ └── utils/ # Common utilities
└── frontend/ # React frontend
├── src/ # Frontend source code
│ ├── components/ # React components
│ ├── hooks/ # Custom React hooks
│ └── types/ # TypeScript definitions
└── public/ # Static assets
- External market data sources feed by using scrapping scripts (Can be shared)
- Scheduler orchestrates data collection timing
- Repository handles persistence and retrieval
- P2P network enables decentralized data sharing
- Frontend displays data through Backend API
- Collected data is broadcast to P2P network
- Peers validate data authenticity and accuracy (Voting)
- Consensus mechanism confirms validation
- Peer reputation scores updated based on accuracy
- Validated market data stored in PostgreSQL
- Peer network information persisted in PostgreSQL
- System configuration managed via YAML files
