Well, it's not quite fantasy, but the Laundry Files novels by Charles Stross merge the concept of "math/algorithms is magic" with lovecraftian horror and satire.
There is something similar in Daemon (or maybe in the sequel Freedom™) in which
extremely minor spoiler
they enchant an invisibility ring, and the ritual is a sequence of steps involving a physical object. In the end, the ring is "tracked" by the AI so that who wears it is automatically removed from surveillance videos