By 7 years old, most (but by no means all) children notice other people's emotions and empathize with their perspective. This is necessary to get along with other people, but it is also a basic emotional skill to keep ourselves safe, because people who go through life correcting, challenging and arguing make enemies.
It sounds to me as if something is getting in the way of your daughter's kind and loving heart. In other words, she needs so badly to be "right" that she argues, challenges authority and corrects people, even when they send signals that her behavior is being perceived as an attack and is making them angry.
Why does she do this?
1. Innate competitiveness - Some people just seem to be born more competitive than others. They like to win. Bright children who have been told they're smart often develop this unpleasant trait because their sense of "ok-ness" depends on showing that they are smarter than others. To avoid this, never evaluate a child's intelligence. Comment on how hard they are working on something, rather than how smart they are. (Here's an article on why praise sabotages your child: http://www.ahaparenting.com/_blog/Parenting_Blog/post/What_To_Say_Instead_of_Praising/)
2. Developmental age - 6 and 7 year olds are VERY conscious of the rules. They want to master the rules, and they want to obey. And if they have to obey, everyone else had better obey also! We often see kids this age acting as "enforcers" to keep others in line. I suspect this is caused by the natural urge toward mastery, as well as by their fears, given that a 7 year old is aware of how little and powerless she is in the larger scheme of things. (See #3 below.)
3. Fear - All humans try to control their surroundings when they feel fear. What could be causing her fear?
* It could be just innate, given that humans seem to have a natural range of anxiety, from little to extreme. Maybe she's a more anxious person?
* Oldest children are generally more anxious; I believe we transmit to them the full weight of our anxieties as we learn our new role as parents.
* It is developmentally appropriate for a 7 year old to be more controlling because she is so aware of her limited mastery of the world, as mentioned above.
* There could be something specific making her anxious: School? Peer relations? Family tension?
I'm betting that everything I've mentioned here is operating for your daughter in some combination. So what can you do?
1. Address the fear and anxiety that are driving her behavior. Does your daughter have a chance to "vent" her anxieties on a regular basis? Sometimes kids need to cry and shake to release their fear, so if she does tantrum in that way it is a good thing. But most 7 year olds are more likely to release through physical play that lets them giggle. For your daughter, I would particularly recommend that you invent games that revolve around rules and being right. Such as:
"Let's play the game "Don't break the Rule!" I'll start. Whatever you do, stay on the couch and don't put your foot on the floor...No, don't!...Oh, no, you put your foot on the floor!.. That means I have to tackle you and kiss you six times.....Here you go!... Because you broke the rule.....(Kissing and hopefully lots of giggling)...Ok, now it's your turn....Tell me a rule I can't break...." As long as she's giggling, you're on the right track.
"I LOVE to be right. I am ALWAYS right. For instance, I know that the moon is made of green cheese. No? You don't think so? Of course it is. I NEED to be right. I hate being wrong. How come you always know? How come you are always right? Poor me...But I do know something else that is definitely true. The sun spins around the earth. No? Are you sure? I HATE being wrong. How come you always get to be right?" She should be laughing as you ham it up and pretend to be so upset. The goal is to be totally goofy and show her how ridiculous it is to need to be right all the time. But the goal is also to fill her deep need to be right. She has a big pit of need here that doesn't get filled in the course of daily life. In fact, her anxiety about needing to be right is keeping her from feeling her okness even when she is wrong. That's the anxiety you are looking to let out by helping her giggle about this. Just be goofy and wrong and let her feel superior for being right and knowing more. Don't worry, she gets plenty of chance to be wrong in the world. This is one of her few chances to be completely right, and at the expense of someone who is usually much more powerful! This should be a very healing game for her.
Once you start playing these games with her on a regular basis, you will think of many variations that address the same issue. Just follow the giggles.
2. Minimize competition. Instead, encourage teamwork.
3. Ask questions to help your daughter become aware of her need to be right. "How important is it to to be right? Is it worth fighting over with someone? Why or why not? Under what kinds of circumstances would the fight be worth it? Does it matter if people have different opinions -- can they still be friends? What happens if someone is wrong? Does that make them not an ok person? How would you feel if you found out later that you were wrong about something you said?" The goal is not to pass judgment, but to explore what is actually a complex moral issue about integrity and connection. How can we be true to ourselves and remain connected to others? Listen to her. Reflect back what she says. Ask more questions. Share your own views.
Given your daughter's need to challenge authority, you will probably want to have a discussion like this about authority. This is also a complex moral issue. You WANT her to be able to challenge authority. But you also want her to do it wisely, when her ethical integrity is at stake, not just so she can feel smarter.
And you will want to have discussions like this about being smart. Is it what really matters in life? Might there be things that matter more?
4. Never praise her for being smart or right. Instead, notice when she is able to pick up emotional cues from others and comment on it. "I saw that you and Amber were arguing and you both wanted to be right. But then it looked like you decided it was more important to be friends. I was so impressed with your maturity. That must have been hard. Were you happy with that decision?"
5. Consider your discipline strategy. If you have been imposing punishment, including "consequences," that make your daughter feel "wrong" you will want to rethink this. Kids who need to be right benefit from guidance that includes empathic limits. Discipline that makes them "wrong" in any way will exacerbate their fierce need to be right. You may already be beyond discipline, but if not, here is an article to get you started: http://www.ahaparenting.com/parenting-tools/discipline
6. Read books about emotion. There's a whole page of recommendations here: http://www.ahaparenting.com/parenting-tools/raise-great-kids/emotionally-intelligent-child/books-develop-emotional-intelligence
7. Parent for emotional intelligence. Since your younger child doesn't have any issues in this area, you are probably already doing this. But the Aha! Parenting website has many articles about how to do this that might be useful for you to read. For instance:
The good news is that you clearly see your daughters loving heart. That means you can hold the vision for her of operating from her heart, rather than from her fear. Your unconditional love and appreciation are what she most needs, so she can learn a new strategy for feeling safe in the world. Find ways to reframe her need to be right so that you see the good parts -- she is protecting her own integrity -- and you will find her more open to relaxing her need to protect herself.
Enjoy your daughter, and best wishes.