Refactored how values/rules are taken