i think in that scenario where basically all tasks are automated (which i think is much further than people think fwiw) our form of capitalism breaks down entirely and 'diversifying in the stock market' is null.
optimistically in that world where all tasks are automated cheaply even a small ubi would provide everyone with a higher standard of living
I know people keep talking about UBI, but at least in the society where most of this is happening (the US) I don't think that's a realistic fix.
Beyond the obvious problem - rich special boy tech billionaires don't think people deserve the money and thus won't pay it - UBI, if it does happen, is likely to become tech feudalism. You would have humans thinking, "I feed, house, doctor, and clothe you. Isn't that enough?" like the lord of the manor used to think when the peasantry wanted to do things like "get educated" and "vote".
The nobles found a rationale for being where they were in the hierarchy: the divine right of kings. If you were the nobility, it was because God put you there, and if you were a serf dying of consumption, that was because God put you there. Any desire to change that on behalf of the serfs was not just annoying to the nobility; it was, quite literally, an abomination unto the natural order as defined by the master of the universe. It was sin. You would burn in Hell for eternity if you challenged it. You don't want that, so you thresh more wheat while coughing up blood so that the lord of the manor doesn't punish you.
I don't see the current batch of nobles using religion to enforce their order, but capitalism. It will be meaningless for the rest of us because we won't be able to produce value in the same way they can, but it will mean everything for them. Who are we, as people who only made a few million dollars of value in a lifetime of work, to question those who made billions or trillions? The market will be the new God. If you were meant by fate to do anything more than scrape by on UBI, you'd have been smart enough to make Claude or the Boston Dynamics robots or what have you and have the equity in those things, like the lord of the manor had equity in the fertile land. Your station in the universe would be backed by math, and only the insane try to argue with literal math.
If it turns out that way, it'll be terrifying to see how it goes down in a country where there's more firearms than people and at least some sense that individuals should have some control over their own fates.