Electricity storage capacities are still negligible compared to the demand. Therefore, it is fundamental to maintain the equilibrium between consumption and production, and to that end, we need load forecasting. This talk aims to propose adaptive methods for time series forecasting. We focus on state-space models, where the environment is represented by a hidden state on which the demand depends. So, we'll try to estimate that state based on our observations analyzing the link between optimization and state-space estimation. Indeed, we see our methods as second-order stochastic gradient descent algorithms, and we treat a particular case to detail that link. Then we estimate the variances, the parameters on which the models’ dynamics depend. Finally, we apply this methodology to electricity load forecasting during the coronavirus crisis. Based on a work in collaboration with J. de Vilmarest (Viking Conseil)