Refactoring assembly creation (now broken)