I think it can be quite hard when you see a child older than yours behaving like this. This giant of a child is so much older and my child understands a little, so that child understands totally, has full control of their feelings etc. However they are still young themselves, and don't necessarily.
I went for ages where I felt any child older than dc1 should be perfectly behaved because they were old enough to know better. Any child younger was too young to understand and should be humoured. Obviously this age increased as dc1 grew older, until I realised I was categorising children in the "poor wee gubbins doesn't understand at all" group when a few years ago they'd have been "old enough to know better."
How you talk about her when she was almost 4 could also be said as: "this child is young and still learning some of this stuff" which is what you said about him.
So what I'd say is for: "She pulls him about, grabs stuff out of his hands, gets quite physical and demands things her way." It is perfectly reasonable to stop her, say "no, ds had it first, it's his turn" or "no, you can't pull him like that" and take the item back again/pick him up and hope your friend backs you up. If she doesn't, especially if she argues for her dc, then I'd back off the friendship.
However the way you talk, I wonder if you may be doing little bit of what I did and thinking "she's old enough to understand sharing, so I expect her to share, but ds is too young to understand, so if he doesn't want to then she should understand. She's old enough to know that."
In which case, if he is going to learn how to share, then you need to teach him. You model to him sharing. So in the example today, was she playing with the toy when he went to get it?
If so, you say to him "No, ds, you wait for your turn because X is playing with it." and take him away and distract him.
If she wasn't playing with it, then asking her if he can play with it, and again praising her for "being kind" (even if you feel she isn't) may work. If she says no, then finding something else to play with your ds that looks so much more exciting, can have a good effect.
Or you can set a timer on your phone. You explain to her that when the alarm goes then she's had her turn and it will be his turn. Give about 2-5 minutes depending on the toy. You'll often find that they get used very quickly to this and will actually hand it over straight away. You then praise them, and help them find something else to play with.
Also praise them if they are taking turns. So if they're coming down the slide and she's waiting for him to go up first then say "oh, you're so good, waiting for him to have his turn. You're such a big girl knowing about turns."
Children at 4yo are very into "the rules" and will object to a child pushing in, taking a toy without asking etc. Use this to manage both of them. Yes, she will probably vigorously object if he breaks them, that's normal. What your role is, is to both sympathise with her and help him to obey the rules (that you set). So when he tries to push in front of her, then you say to him, "No, wait for her to go first." and move him back. That way you're showing both of them that the "rules" matter to both of them. They both will feel more secure for knowing that, and it will help them play better together.
Please and thank you is for your friend to sort out, but if you model it for your ds she may pick it up. If your ds can't say the words yet, then get him to sign it (mine used to kiss hand and blow), and you also do the same. So if she hands you something, you say "thank you" and you praise them if they say it especially when unprompted.
It is hard work at that age, but they do come through the other side, albeit with still lots to learn and not always doing it perfectly.
Hope that helps.