  We combine analytical understanding of resonant dynamics in two-planet
systems with machine learning techniques to train a model capable of robustly
classifying stability in compact multi-planet systems over long timescales of
$10^9$ orbits. Our Stability of Planetary Orbital Configurations Klassifier
(SPOCK) predicts stability using physically motivated summary statistics
measured in integrations of the first $10^4$ orbits, thus achieving speed-ups
of up to $10^5$ over full simulations. This computationally opens up the
stability constrained characterization of multi-planet systems. Our model,
trained on $\approx 100,000$ three-planet systems sampled at discrete
resonances, generalizes both to a sample spanning a continuous period-ratio
range, as well as to a large five-planet sample with qualitatively different
configurations to our training dataset. Our approach significantly outperforms
previous methods based on systems' angular momentum deficit, chaos indicators,
and parametrized fits to numerical integrations. We use SPOCK to constrain the
free eccentricities between the inner and outer pairs of planets in the
Kepler-431 system of three approximately Earth-sized planets to both be below
0.05. Our stability analysis provides significantly stronger eccentricity
constraints than currently achievable through either radial velocity or transit
duration measurements for small planets, and within a factor of a few of
systems that exhibit transit timing variations (TTVs). Given that current
exoplanet detection strategies now rarely allow for strong TTV constraints
(Hadden et al., 2019), SPOCK enables a powerful complementary method for
precisely characterizing compact multi-planet systems. We publicly release
SPOCK for community use.
