Feature/refactoring

WIP