This repository was a project for our Introduction to AI course. The objective of the project was to create an agent to play a game of Kalah with other classmates and compete in a tournament. We decided that this challenge was a great opportunity to practice machine learning. We decided to create an agent that would use a simple heuristic at first while learning from its mistakes and the success of the winner to make better decisions in the future as opposed to mapping the potential outcomes of the game in a large decision tree. The project also provided an opportunity for us to use other concepts we were learning at the time. From our Programming Languages and Compilers course we applied Regex to speed up the search time of the "previous_experience" text file. From Software Quality we decided to practice Xtreeme programming and coding pairs to reduce coding mistakes while also reducing the amount of time spent coding.
Kalah is a game that falls under the Mancala family invented in 1940. The game itself goes by many different names. It is also known as Kalaha, Warri, or Awari. For more information about the rules of Kalah, see the wikipedia article here: https://en.wikipedia.org/wiki/Kalah
Our team performed well in the tournament. After losing the first couple matches, our agent then later went on to win most of its later games. The first couple matches provided our agent with enough experience to learn from its mistakes and defeat most of our other opponents.
Overall our agent placed first in our class, with a close lead of 1 game.