When you go outside and look at the sky on a clear night, it seems like nothing else could be as serene and peaceful. But many of those seemingly peaceful stars are evidence of a turbulent history - and now we're learning to unlock their secrets.

Using data from the Gaia Milky Way mapping survey, astronomers have discovered a vast stream of stars that they believe are the remnants of a massive dwarf galaxy that got dragged into the galactic disc before being torn apart. They have called the stream Nyx, after the Greek goddess of night.

According to the standard model of the evolution of the Universe, galaxies grow by merging with and absorbing smaller galaxies - the accretion process. There's actually loads of evidence of this occurring in the Milky Way: a number of streams have been identified that have been linked to dwarf galaxies and globular clusters disrupted by the galaxy's tidal forces.

Then the Gaia satellite came along. It was launched in 2013, and has been collecting data ever since to produce the most accurate 3D map yet of the Milky Way. It's carefully studying the proper motions, radial velocities and distances of the stars to determine where everything is, and how it's moving around.

This is revealing in unprecedented detail the history of the Milky Way's altercations with other blobs of stars - such as Antlia 2, the Sagittarius Dwarf Spheroidal Galaxy and, um, the Gaia Sausage. Not to mention the Pisces-Eridanus stellar stream, thought to be what's left of a star cluster.

But these have all been identified by looking for things that move and are built differently. It's a lot harder to identify a shredded galaxy that fits in. Stars that move with the rotation of the galactic disc, and have similar chemical compositions to stars that formed here, might be overlooked.

So theoretical physicist Lina Necib of Caltech and her colleagues applied a neural network to build a catalogue of stars from the second Gaia data release that had been slurped into the galaxy, rather than being born here.

"The network," the researchers explained in their paper, "takes as inputs the five-dimensional kinematics of each star (two angular coordinates, two proper motions and parallax) and then outputs a score associated with the probability that the star is accreted."

When they extracted the stars that the neural network was most certain had been accreted, the team found a group of 232 stars all moving together in a prograde motion - that is, with the rotation of the galaxy - and with similar chemical compositions. This group had not previously been associated with any other stellar stream.

When they simulated the orbits of these stars 1 billion years into the past, the team found that they had orbital properties that were different from the stars in both the Milky Way's thick disc and thin disc.

"Coupling this observation with the fact that Nyx lags behind the disk by ~90kms−1 and has a substantial radial velocity component makes a strong case that it is the result of a satellite merger," the researchers wrote.

Stellar groups that move together can be created by other means, such as resonances generated by perturbation from the galactic bar, or density waves in the spiral arms, but these don't fit Nyx. Simulations of these phenomena couldn't produce Nyx's lag without causing other effects that have not been identified in the data.

The best fit for their data, the team believes, is a dwarf galaxy that, at some point during the Milky Way's long history, got slurped up, then stretched out as the stars began to orbit the centre of the Milky Way.

And when the researchers repeated their study with slightly relaxed certainty, they found another group of stars that almost exactly matched the Nyx stream. The prograde galactic orbit and chemical compositions were the same - but the second group had opposite radial velocity. This is also consistent with the dwarf galaxy model, as simulations showed that the second group could be debris from a separate passage of the same dwarf galaxy.

It's likely that Nyx contains stars that were not identified in this study, because they fell outside the strict parameters fed into the neural network. But future research could help shed light on this event - when it happened, how it happened, and just how massive that dwarf galaxy was.

And, since there's also evidence that populations of accreted stars correlate with clumps of dark matter thought to have been slurped up in the merger along with the stars, Nyx can help us understand how such mergers contribute to a galaxy's dark matter disc.

"If Nyx is indeed the result of such a merger, then it would provide evidence for accreted prograde stars, and potentially, an accompanying dark matter component in a stream or disk," the researchers wrote.

"The presence of such a dark matter component would substantially alter our current understanding of the local dark matter phase-space distribution, and have important ramifications for terrestrial searches for the dark matter particle."

The research has been published in Nature.