Refactored to more easily set up the abstraction of parameters