You could combine the above ideas from Kunimatyu and Arcane Runes Press and have the eldritch machine designed to make Xoriat coterminous with a large portion of Karrnath in order to drive the Karrnathis into madness. Its true purpose, however, is to weaken a sealed gate to Xoriat located in Karrnath, allowing the daelkyr and their minions to invade once more. The machine's construction was a joint Breland/Cyre venture as you stated, but secretly organized/inspired by a group of mind flayers and other servants of the daelkyr (the daelkyr themselves don't seem to care too much about re-opening the gates to Xoriat (or at least their methods are too inscrutable)). For extra bonus fun, have a group of Gatekeeper druids aware of the machines true purpose, and working to either rescue or kill the gnome wizard and destroy the eldritch machine at the same time the PCs are trying to rescue him, or have them actively trying to stop the PCs while/after they rescue the wizard.