Genie knew things could not stay as they were, deep down in her heart. A flood of thoughts came to her, all at once and in a jumble of a mess, all set off by Josephine's presence and current predicament. First and foremost, Genie realized she was in the wrong. Joseph Dell was an honest man, mostly. He told her the truth, and wished to explore a side of himself that he never knew of. She made a mistake, one she would not make again, but at the same time, she should be trying to fix it, not make it worse.
Besides, if she helped free Josephine on her own and without being told, Joseph might change his mind. He might free Genie himself.
So Genie sighed and knelt down to the red clad wishgranter, "Master, I owe you a thousand apologies."
"Master?" Josephine said, "I am not your Master, Mistress. I am a Genie."
"I wish you would remember your old life, Master," Genie said, "and you can stop calling me Mistress."
Josephine's eyes fluttered and she looked down at herself, at the golden manacles on her wrists. She knew who she was and how she got here, but was at a loss for how to get out. But to that end, Genie had a thought.
"Master, when I granted your wish, I made it so that you could change between your identities at will. Alas, you cannot change inside my lamp. But we may only leave this lamp with the call of a Master. However, I can grant my own wishes while inside my lamp Inside my lamp, though I cannot change or affect anything outside it."
"How does that help?" Josephine asked.
"Because this is not your lamp, I don't think the bounds around you are as strong. If I wish it, and you think with all your might to be Joseph again, you may be able to escape and return to your male, non-Genie self. And then I may be able to fix the mistake I made."
Josephine nodded.
Genie exhaled and closed her eyes. "I wish for luck," she said, "and I wish Josephine left my lamp."