initial steps for the QB refactoring