Added new function to determine the hash prefix to use and updated the lib to use it.