exported clear_history function, so that users can easily clear history in the unlikely event that it gets too big