An ice-cream order arrived as a tomato. Sanad Yaghi’s response became a retail software company, then a bet on AI checkout.