If AI replaces many jobs, then AI companies must compensate for such losses by taxing them for using robots/AI. That's one way to fix it. Just deposit that money into the person who lost their job to AI every month so that they can have, you know, simple luxuries like:
a) Getting 8 hours of sleep without stress
b) Paying bills without panic
c) Owning a home and paying for food and medicine
d) Feeling safe doing nothing
But we all know these companies won't agree to this and that is the problem