Ama
Puyo Puyo Tsu AI
Install / Use
/learn @citrus610/AmaREADME
Overview
Ama is an AI created to play Puyo Puyo Tsu 1P and PVP. This project aims to become the strongest Puyo Puyo entity. Currently, Ama can run on Puyo Puyo Champions Steam version.
Features
- Field representation
- Bitfield
- SIMD for fast chain simulation
- Search
- Best first search
- Beam search
- Parallelized search
- Monte Carlo inspired sampling method with predetermined queues
- Highest expected chain score selection policy
- Quiescence search
- Transposition table
- Value-preferred with aging replacement scheme
- Evaluation
- Pattern matching
- GTR
- Sullen GTR
- Fron
- Chain detection
- Chain extension
- Trigger height
- Field shape
- Avoid tearing
- Avoid wasting resources
- Pattern matching
- Enemy reading
- State machine
- Build action
- Big chain (78% of chains >= 100,000)
- Fast second chain
- All Clear battle
- Imbalance resources
- Countering
- Harassment
- Attack action
- Negamax inspired search that can look 3 moves ahead
- Crush
- Combo
- Kill
- Defense action
- Negamax inspired search that can look 2 moves ahead
- Correspondence return
- Synchronized attack
- Accepting/Countering
- Desparate return
How to build
For now, this projects can only be compiled using g++ that supports c++ 20. Make sure that your cpu support sse4 and pext.
- Clone and
cdto the repository. - Run
make PEXT=true puyopto build the puyop client. - Get the binary in
bin.
NOTE: The source code for the Puyo Puyo Champions Steam isn't available to prevent cheating
Acknowledgement
- Thanks K. Ikeda, D. Tomizawa, S. Viennot and Y. Tanaka for their paper
Playing PuyoPuyo: Two search algorithms for constructing chain and tactical heuristics. Ama's early search algorithm was heavily influenced by their work. - Thanks puyoai for the fast implementation of bitfield and the inspiration for the evaluation function.
- Thanks takapt for their beam search idea, Ama's new improved beam search was based on their implemntation.
- Thanks nlohmann for the c++ json library.
- Thanks nicoshev for their
rapidhashhash function.
License
This project is licensed under MIT LICENSE.
Related Skills
node-connect
342.0kDiagnose OpenClaw node connection and pairing failures for Android, iOS, and macOS companion apps
frontend-design
84.7kCreate distinctive, production-grade frontend interfaces with high design quality. Use this skill when the user asks to build web components, pages, or applications. Generates creative, polished code that avoids generic AI aesthetics.
openai-whisper-api
342.0kTranscribe audio via OpenAI Audio Transcriptions API (Whisper).
commit-push-pr
84.7kCommit, push, and open a PR
