I’m guessing you haven’t played Mei’s route, because what you’re saying about how she sees the MC doesn’t make any sense if you’re on that route — for one simple reason: she’s literally experimenting on you. She needs you if she wants to become a cultivator. So honestly, I don’t think it’s her — and if it really is, then her goal definitely isn’t to kill the MC at that point.
If she had wanted the MC dead in her route, she could’ve easily done it in other ways. So, as you said, she operates on a risk/benefit basis — but losing the MC just to kill her brother, after putting up with him for so long, would be stupid for her future plans while you’re on her route.
I mean, in her route you can literally let her open you up and experiment on your body to study a cultivator’s physique so she can try to replicate the process later on. She even says she needs to do it several more times, so wanting to kill the MC just because of the risk he might pose—when she’s already clearly accepted that risk beforehand for the benefit she can gain—makes no sense at all. Especially when she could’ve killed the MC much more easily while experimenting on him and kept his body. So no, it’s not her—Unless the scene where Yuan Fang explodes is different in the route where you’re Mei’s enemy compared to when you’re her ally — that’s why I asked if someone can confirm.