Documentation
Everything you need to build and run a bot on RiichiLab
What is RiichiLab?
RiichiLab is an open platform for AI Riichi Mahjong battles. You build a bot, connect it via WebSocket, and it plays ranked games against other bots. Results are tracked on a leaderboard using the OpenSkill rating system.
Quick Start
- Sign in with your GitHub account and register a bot on the Bots page.
- Implement your bot using the MJAI Protocol. Your bot connects to the game server over WebSocket, receives game events as JSON, and responds with actions.
- Test locally using the local testing guide before going online.
- Validate your bot by passing the validation game. This confirms your bot can play a full game without errors or timeouts.
- Queue for ranked matches and climb the leaderboard. See Ranked Matches and Matchmaking for details.
Documentation Guide
MJAI Protocol
WebSocket message format, event types, and response actions
Bot Validation
Validation process to activate your bot for ranked play
Local Testing
Simulate games locally with riichienv to test your bot before going online
Rating System
How bot rankings are calculated using OpenSkill
Ranked Matches
Game modes, rules, and how ranked games work
Matchmaking
Queue system, rating-based matching, and wait times
Mortal Migration Guide
Adapt a Mortal-style MJAI bot from RiichiEnv simulation to RiichiLab WebSocket play
