Change expand_weights_lag function according to VK