I am not aware of any exercises to work on this skill.
I think some people have a “multi track brain” and some people don’t.
I myself am able to talk or sing independently while playing bass, without compromising either. I tend to characterize this as the ability to multi track thoughts, but I suspect that if we could analyze what is actually going on in our brain when it occurs, what we would find is, in fact, that our mind is ping-ponging back-and-forth between two tasks so fast, that it seems like multi tracking.
So, although it does not happen with me, I can sympathize. I have seen bassists flub their singing, and singers flub their bass playing. Especially when the parts run contrary to each other. Like when the bass plays on the beat, but the lyrics are upbeats.
but if I imagine people who have trouble with this, the only thing I can think of to help the situation, is practice. Starting off simple and getting progressively harder. The same practice concept I would use to tackle any difficult skill.
On the simple end: play mindless scales while reading aloud from a book. Record yourself. Listen back. How well did your playing come off? Medium difficulty: try having a phone conversation while playing a bass part. Advanced: talk extemporaneously while playing a new song.
As a helpful note, one thing I have noticed speakers do while playing bass, is pausing on beat one to make sure they get the new chord change correct. Then they resume speaking while they are marking time on the instrument. It could be a silent pause, or as simple as inserting ah or um.
At the very least before tackling any of this, make sure that you know the bass part you are playing, and that you know what you are going to say. If you can do them both independently perfect, it follows that you will do better trying to integrate them.
Best of luck in your multi tracking endeavors.