Add serialize functionality and the skeleton of the AI