Refactoring demo files