Magnet controller can take a curve controller as source of magnetic effect. Instead of picking magnet node assign a curve controller to the Reference Controller channel and set the curve controller output to closest point.
Learn how to apply multiple magnets on one array.
You can access the operands inside the Compound objects such as Boolean objects. Watch this video to see how you can control the location of cutout by a magnet controller.