Those 4th gens are probably still useful as missile trucks and Bombing Trucks once Air dominance is achieved by the 5th and 4.5th gens. They can also act as point defense against enemy drone and cruise missiles attacks in deep interior of China.
So, I still see uses for them in the near term until the 5th gens can be produced in large numbers. But as you said, depends on whether China wants to expand its air force or not.
So, my view is that if the PLAAF does not choose to greatly expand its fighter force, then assuming 200-250 fighters total produced per year from 2026 onwards (combination of J-20A, J-20S, J-35A, J-35, and J-16D, J-15T, J-15DT, of which J-20A, J-20S, J-35A and J-16D are for the PLAAF), then by 2028, the "old" 4th gens will be up for replacement, and thus a little bit "ahead" of their airframe lives in theory.
If they do not choose to greatly expand its fighter force count, then it would be a terrible, catastrophic idea to retain their "old" 4th gens rather than to replace them (directly or indirectly) with new build 5th gens.
That's because whether the "old" 4th gens are useful or not in specific scenarios is not the challenge they face -- instead the challenge for the old 4th gens is the
opportunity cost of using personnel, pilots, air bases to operate old 4th gens versus having them operate 5th gens instead.
- In terms of personnel cost you are paying them regardless of whether they're flying and maintaining old 4th gens or if they're flying and maintaining 5th gens
- In terms of availability and spare parts, chances are the old 4th gens will be somewhat short of circulating spare parts and logistics by the late 2020s because they would have been out of production for a decade and a half by that point, while there would be a burgeoning huge and active supply chain for J-20A/S and J-35A
- There will of course be a degree of upfront capital cost to buy the jets and upgrade the bases to adequately handle 5th gen jets and provide additional training for pilots and personnel, but that was always going to happen at some point eventually... and the cost would be more than worth the major capability upgrade.
In essence -- most of the operating and personnel costs will be the same regardless of whether it's an old 4th gen or 5th gen that a unit operates, so if the industry capacity is there and if the upfront procurement funding is there, it makes no sense to
not retire those old 4th gens early to replace them with 5th gens.
The most justifiable reason to not do that, is if they want to expand the fighter fleet size.
My thesis is that China will expand its air force, Just cause China has the capacity in terms of GDP, population and also has the strategic need due to the fact that most of China's enemies are so close by and are indeed a big threat, China still needs to field huge land based air power to firmly achieve air dominance against US and its allies and 2000 fighters will not cut it. They need to expand to 3000+ for the Air force alone and if they keep producing carriers then augment that with 1000 fighter jet fleet of Naval Air force. Only then China can firmly achieve overwhelming dominance against Japan, Taiwan and US PACOM.
If they want to expand the fighter fleet size, then yes it would make sense to keep the old 4th gens around to keep the units, personnel billets, bases etc active, until such a point that PLA procurement of 5th gens allows for the old 4th gens to be replaced in the same way that the old 3rd gens were kept around.