This is where Ancelotti greatness lies, he is not in a hurry to step on the gas, he lets his players find a comfortable point first to create balance. When the time comes, they just stay and prove to be leading the top of the standings with a margin that can be said to be safe for a while. In fact, if you look back at the beginning of the season, Real Madrid was doubted, Barcelona led with full confidence but because they stepped on the gas too much while their young players were not yet fully consistent, their performance slowly declined and that's where Real Madrid overtook.
Starting the season with less consistency made Real Madrid lag behind Barcelona's points, but they began to rediscover their best form when the team's balance began to be rebuilt so that currently Real Madrid has managed to occupy first place in the standings. Barcelona started the season quite consistently and even won quite promisingly, but after experiencing several bad results, Barcelona fell further behind Real Madrid. That is why the consistency of the club can sometimes change so quickly because several important players are injured, which affects the team's performance in collecting points in each match and that happened to Barcelona.
I agree with you that consistency is key for a club in facing the title competition. Real Madrid has shown an impressive revival after a bad start to the season, slowly they can show their best performance, in contrast to Barcelona who seem to have difficulty maintaining the level of play due to injuries to several key players even though the squad owned by Barcelona is not as great as that of Real Madrid and Atletico Madrid because Barcelona cannot recruit good players due to financial problems.