restructure to separated module