Americans spend a remarkable amount of time shopping—more than on education, volunteering or even talking on the phone. But the way they shop is shifting dramatically, as major platforms and retailers are racing to automate commercial decision-making.