some refactor notes