Bitcoin mining companies invested billions of dollars in AI in the first half of the year, capital expenditure more than 15 times revenue