restructure the codebase for better management