What determines how much damage a blue fly does?
I've had trips into the basement where blue flies seemed to do almost cosmetic damage, and trips into the dungeon where the blue flies were a murderous death swarm. What items or statistics make blue flies stronger or weaker?
Since I don't have any hard evidence to back it up, only my experience, I can only speculate that there is a link between your damage stat and the lethality of flies (From my experience, flies always do less damage the earlier you get them, when you yourself usually have lower damage).
What I can say for certain, though, is that flies become much deadlier the more of them you manage to spawn. Certain item configurations have you spawning large amounts of flies, which significantly bolster your damage output.
The Mulligan is the most useful item where spawning flies is concerned, and it becomes more effective as your fire rate increases (which in turn increases the rate at which you damage enemies).
Additionally, as the item's Wikia page states:
Familiars also contribute to the addition of attack flies. This can lead to a significant amount of flies on the screen
And it also lists a couple of synergies:
Mutant Spider - Will spawn many more flies.
Technology 2 - Has a much higher chance of spawning flies, due to Techonology 2's high fire rate.
According to http://platinumgod.co.uk/, and the prominent BoI Youtuber Bisnap, blue flies deal twice the player's damage.