optimize file structure, also less repetition.