I'm not sure if having this be an exported function is the best approach for extensibility in the future, but I am thinking on it some more.