Basically, A.I.D.A messed up something in the programming of the framework. She was trying to make Fitz's feeling for Jemma about her, but she accidentally flipped their roles. So when Jemma get's plugged into the framework, she takes Ophelia's place, and A.I.D.A takes Jemma's place. Jemma doesn't remember the outside world once she's inside the framework, so only Daisy is self aware.