The shadow creature was an entity that the Ancients captured for research on Ascension. The entity fed off various forms of energy including Naquadah generators, the energy of the Stargates, and even people. The shadow would also emit an electric charge within itself. The Lanteans captured the creature to by using a Containment vessel that held it in subspace. The creature was left behind when the Ancients abandoned Atlantis. After the Atlantis expedition arrived, Jinto accidentally released it.
The Athosians initially mistook it for one of the shadows that the Wraith produced. Teyla Emmagan came up with the idea to send it to another planet by luring it through the Stargate by activating a Naquadah generator and sending it to M4X-337. The creature managed to get the MALP it was in before it was sent through, though Dr. Rodney McKay, using a personal shield he found, went inside the creature and threw the generator through the gate. The creature soon followed through. (SGA: "Hide and Seek")