some refactoring towards proper submodules