adding model loop