We give the construction of an integrable system as zizag loops on graph embedded on torus introduced by Kenyon and Goncharov in 2013. The generators of this integrable system are loops with weights inherited from edge weights of the embedded graph. The zigzag loops are in bijection with the Newton polygons, which encode different phases in the limit of the model.