In this paper, we present a method for using rational expectations in a stochastic linear-quadratic optimization framework in which the unknown parameters are updated through a learning scheme. We use the QZ decomposition as suggested by Sims (Ref. 1) to solve the rational expectations part of the model. The parameter updating is done with the Kalman filter and the optimal control is calculated using the covariance matrix of the uncertain parameter.
Amman, H. M., & Kendrick, D. A. (2000). Stochastic policy design in a learning environment with rational expectations. Journal of Optimization Theory and Applications, 105(3), 509-520. https://doi.org/10.1023/A:1004620021587