One deflationary but non-trivial way to understand the role of historians of philosophy in the profession is as teachers that recruit the next generation of students by teaching some of the most enjoyable and exciting bits of philosophy (think Plato, Descartes, Hobbes, Spinoza, Wollstonecraft, Nietzsche, etc). I nice side-effect of this role is that the historians become the bearers of -- to use an elitist phrase -- philosophical culture that helps guide judgment and generates a sense of wider perspective. In an age of decreasing book-literacy, shortened PhDs and hyper-professionalization this is (to borrow an economist's term) a great public good. While the safe version of this role has a conservative bias toward canonical 'classics' -- we know these works 'work' --, it also encourages the historian to keep searching for works that might work equally well. And, of course, some classical texts stop resonating with students (perhaps, less classical than once thought).
Another deflationary but non-trivial way to understand the role of historians of philosophy in the profession is as teachers of a key part of the curriculum that helps prepare students to understand the present. This can take three roles: (i) they teach material that has shaped the present and which provides a fuller understanding of key debates today (for example, courses in 'early modern,' Kantian, and, increasingly, 'early analytic' often play this role); (ii) they teach material that can influence contemporary debates, especially if these need to recover lost ground (for example, courses that explore history of modality, grounding, virtue, moral psychology, etc.); (iii) they teach material that are at odds with contemporary approaches, but might help us better understand the possibility space and limitations of our own commitments.
Again, (i) has a status quo bias, but as professional interests change and philosophy develops, there is always a constant need for backward re-jigging of the curriculum. Given that at any given time lots of works influence future developments, historians play a key role in shaping the narrative that winnows what works are 'perceived' by later generations to have influenced the present. By contrast (ii) is often a 'recovery' operation. (So, for example, as neo-Liberalism has become important I try to teach Swift's "A Modest Proposal" or as gender issues have become more central in professional philosophy, a whole number of authors are being rediscovered--I have found it immensely stimulating to teach feminist texts in my early modern course; they have brought out gender/political themes in the works I already taught.) This does not always work; it is, for example, undeniable that Adam Smith's "History of Astronomy," prefigures a lot of history and philosophy of science of the last half century, but my undergraduates found it unfailingly boring. Option (iii) is great fun for a restless historian; one is actively encouraged to keep reading and to be on the look out for (to nod to Nietzsche) untimely work from the past.
There are other roles that teaching history of philosophy can play in the profession. I mention three: first, they express our own philosophical personality and indirectly convey what we might think important without, perhaps, preparing the students for professional philosophy. I love teaching philosophical texts where literary and conceptual issues have a complex interplay (Plato's dialogues, More's Utopia, Bacon's New Atlantis, Wittgenstein, anything by Nietzsche, etc.--obviously this list has considerable overlap with an earlier list. But I would happily teach Aristotle's Nichomachean Ethics to undergraduates, but not for reasons of personality). Admittedly, not everybody's philosophical personality is best expressed by teaching historical works; but given that I find the contemporary journal-article-template so abhorrent it is no surprise I would go down this route. (Yes, I have read work I enjoyed published in last thirty years.) Second, they may help us challenge how we think of the enterprise of philosophy altogether. This is by now a familiar point, but as we peek into the past we can discern lots of works that from our vantage point straddle many disciplinary boundaries. Most of those boundaries are worth rethinking on regular occasions. (One example I participate in and teach my students is in re-reading Newton as a philosopher.) Third, to help us see the interconnectedness of issues/concepts. Given that our philosophical culture is overwhelmingly problem/puzzle focused, studying a systematic philosopher of the past can train the developing (and advanced) mind to learn to discern interconnected features of philosophy. The only contemporary philosopher who offers anything like it is David Lewis, and the key to his success is, in part, the modularity of his system (so reading his work in light of each other does not quite convey the benefit I describe, although it can be salutary for lots of other reasons). Teaching (and using) the method of counter-example is, in effect, a second-best solution to teaching systematic philosophers. By exploring counter-examples, including the outlandish ones, we learn to discern systematic entailment(s).*