The way that I understand it is that one pattern is replaced by another. This is because the conjugated form of the verb-noun BOD changes.
So the formula dw i’n moyn is replaced by the new formula bo’ fi’n moyn Dw i —> bo’ fi
And the formula mae rhaid i fi is replaced by bod rhaid i fi. Mae —> Bod
This change in pattern occurs after certain verbs-nouns, such as to think or to believe. The change is something like using the English word THAT after those verbs:
I think THAT I… etc
To suss out which of those two changes one ought to make, we have to think back to the pattern we learned for the phrase that follows the word that.
For example, say we want to translate into Welsh: I think that I want to improve.
How did we learn to say I want? Dw i’n moyn. And that particular pattern, as noted above, is replaced by bo’ fi’n moyn in this context.
So we would say: Dw i’n meddwl bo’ fi’n moyn gwella.
And if we wanted to say: I think that I need to improve?
We learned Mae eisiau i fi for I need.
As per the pattern above, this would now become BOD eisiau i fi.
Dw i’n meddwl bod eisiau i fi wella.
So if you normally use Dw i / Dw i’n, change it to bo’ fi / bo’ fi’n. If you normally use Mae, change that word to bod.
Dw i’n siarad Cymraeg —> Dw i’n meddwl bo fi’n siarad Cymraeg.
Mae rhaid i fi siarad Cymraeg—> Dw i’n meddwl bod rhaid i fi siarad Cymraeg