Search for a command to run...
Context . Stellar streams offer one of the most sensitive probes of the Milky Way’s gravitational potential, as their phase-space morphology encodes both the tidal field of the host galaxy and the internal structure of their progenitors. In this work, we introduce a framework that leverages flow matching and simulation-based inference (SBI) to jointly infer the parameters of the GD-1 progenitor and the global properties of the Milky Way potential. Aims . Our aim is to move beyond traditional techniques (e.g., orbit-fitting and action-angle methods) by constructing a fully Bayesian likelihood-free posterior over host galaxy parameters and progenitor properties, thereby capturing the intrinsic coupling between tidal stripping dynamics and the underlying potential. Methods . To achieve this, we generated a large suite of mock GD-1-like streams using our differentiable N -body code O DISSEO , sampling self-consistent initial conditions from a Plummer sphere and evolving them in a flexible Milky Way potential model. We then applied conditional flow matching to learn the vector field that transports a base Gaussian distribution into the posterior p ( θ | d ), enabling efficient amortized inference directly from stream phase-space data. Results . We demonstrate that our method successfully recovers the true parameters of a fiducial GD-1 simulation, producing well-calibrated posteriors and accurately reproducing parameter degeneracies arising from progenitor-host interactions. Our results highlight the power of modern generative models for dynamical inference and provide a scalable pathway toward jointly constraining Galactic structure and the origins of stellar streams. Conclusions . Flow matching provides a powerful, flexible framework for Galactic archaeology. Our approach enables joint inference on progenitor and Galactic parameters, capturing complex dependencies that are difficult to model with classical likelihood-based methods. This work paves the way for fully simulation-driven dynamical inference using Gaia and upcoming surveys.