new main.pl to slice the data more piece, adding the ui in the index.html