  Latency in the control loop of adaptive optics (AO) systems can severely
limit performance. Under the frozen flow hypothesis linear predictive control
techniques can overcome this, however identification and tracking of relevant
turbulent parameters (such as wind speeds) is required for such parametric
techniques. This can complicate practical implementations and introduce
stability issues when encountering variable conditions. Here we present a
nonlinear wavefront predictor using a Long Short-Term Memory (LSTM) artificial
neural network (ANN) that assumes no prior knowledge of the atmosphere and thus
requires no user input. The ANN is designed to predict the open-loop wavefront
slope measurements of a Shack-Hartmann wavefront sensor (SH-WFS) one frame in
advance to compensate for a single-frame delay in a simulated $7\times7$
single-conjugate adaptive optics (SCAO) system operating at 150 Hz. We describe
how the training regime of the LSTM ANN affects prediction performance and show
how the performance of the predictor varies under various guide star
magnitudes. We show that the prediction remains stable when both wind speed and
direction are varying. We then extend our approach to a more realistic
two-frame latency system. AO system performance when using the LSTM predictor
is enhanced for all simulated conditions with prediction errors within 19.9 to
40.0 nm RMS of a latency-free system operating under the same conditions
compared to a bandwidth error of $78.3\pm4.4$ nm RMS.
