Periodic stalling on a ZX3

I just picked up a 2000 ZX3, 233M, which occasionally will die soon after starting and sometimes while running will have a short lapse in fuel delivery. It’ll start fine, revs up to 2M and then the bottom falls out. Sometimes I can nurse it along keeping the revs up till it sorts itself out. Only seems to happen with cold engine. Sometimes will not start, sometimes will sort itself out and be fine for days or weeks. Otherwise it runs fine. ???