refactor into namespaced package