Can Artificial Intelligence Infringe Copyrights?

What happens when Microsoft grabs all GitHub repositories and uses them on their new paid plugin.