initial commit of generic refactor