You can try the game at http://hearts.yjyao.com/
The Ai.js class can use various Brains to make decision.
Brain.js: Base class for all brainsAsyncBrain.js: A wrapper to call the more time-consuming brains via web-workerSimpleBrain.js: Simple greedy heuristicsMcBrain.js: One-step look-ahead with sample generation and deterministic rollouts based on the assumption that all players use the simple greedy strategyPomDPBrain.js: assuming all other players to be playing using the greedy strategy, the game can then be formulated as a POMDP and can thus be solved with the POMCP Algorithm. Thisbrainimplements the POMCP algorithm.
- Port
McBrainandPomDPBraintoC++, which can be compiled toasm.jsfor better performance - Multi-player support