There's some NPC interaction you can set up that leads the NPC to turn towards the front door to break up the fight. Talk to the other two guards to set it up, but be warned, you can only do it once. I presume that with enough sneaking, you can use this (very small time wise) window to enter sneak, cast unlock magic and open the door without being detected. I tried without sneak but the auto-anti-theft dialogue triggered.