Refactoring and prototyping