SHE’S BAAAACK! Ex-"Cheers" cuckoo SHELLEY LONG – long considered one of Diva Town’s most annoying divas – keeps making "Modern Family" star ED O’NEILL NUTS when she guests on the smash-hit show because she won’t stick to her scripted dialogue.

"It drives Ed crazy," says my source, Onda Settalot. "He’s a real stickler for doing the lines exactly as written."

During one rehearsal, Shelley started ad-libbing and threw Ed off his timing so badly he suddenly bellowed: "That’s not the line, dammit! STOP changing the lines."

Shelley, who plays O’Neill’s ex-wife in a recurring role, was back for her first show of the new season – but it looked more like her last when Ed exploded over her off-the-cuff rewrites. The director quickly called a break after the blowup – and the tension was excruciating when the two stars finally returned.

"Everyone breathed a sigh of relief," said my source, "when Shelley stepped up and recited her lines…exactly as they’d been written." Folks, give that gal three CHEERS