Refactoring to externalise the dictionary.