Security Service director general Sir Ken McCallum said the potential risk from artificial intelligence could not be ignored.