Automating all the other stuff that's left on the table.
The only reason why they haven't already been replaced is because humans can be exceptionally cheap. Much easier to hire somebody to sit at a desk for $10/hour doing repetitive tasks than spend millions implementing systems across the board to do what they do (for now).
So perhaps in the medium future humans will be "stuck" doing only physical tasks, while AIs take over everything that can be done virtually.
I will say though, that for a lot of those jobs human-replicating robotics isn't even necessary. We exaggerate the difficulty required because we're still assuming that the exact current system should stay in place. However, sticking within food preparation example, look at those elaborate cake vending machines found primarily in asian countries. There really isn't a reason why McDonalds can't do the same for some of their offerings, after all most of their stuff is frozen anyways.
Inferior to machines at almost everything? Most jobs are safe, look at the 25 most common jobs in the US - cashier, food preparation worker, stocking associate, laborer, janitor, construction worker, bookkeeper, server, medical assistant, bartender, administrative assistant, marketing specialist, police officer, electrician, mechanic, etc.
In theory, if all developers are replaced, they should be able to find a different job. The problem is that the different job may have lower pay and status.
There's really no need for UBI.