Towards a Code of Ethics for Artificial Intelligence