More than a fourth of law firm M&A transactions are driven by artificial intelligence startups, with Latham & Watkins reaping the most benefits.