LinkedIn is facing a lawsuit in the US which accuses the platform of sharing users’ private messages with third parties to train AI models.