You're discussing two different things!
The Pegasus replicators (which are organic and not artificial, like the Milky Way replis) were designed to kill the Wraith. The Milky Way replies were created by Reese, an android built by the ancients. So, in the end the Milky Way replicators were built by the Ancients too, but not as a weapon, but as a toy.