refactored specification system