Beside retire, add a tab called "Heirloom". This tab would tell you if you have any heirloom points to spend. It would then have two buttons: "Use heirloom point(s)" and "Sell heirloom point(s)". When the user clicks on "Use heirloom point(s)" , they are brought to a page that resembles the retire page in terms of what gear they would like to heirloom. This could also be cleaned up a bit with a button on the side that states "Basic View" and "Advanced View". In "Basic View" the user would have a drop down menu to select which gear to upgrade. After they select an item it would show the changes below the drop down menu so the user may see the change. In "Advanced View" the user would see the existing Retire tab (Except for the text at the bottom). Regardless of the view, there would be a button that would say "Heirloom this Gear" or something similar.
As for how it would work on the market place, create a legitimate item called "Heirloom Point" which has 5 slots: Therefore not usable by the player in any circumstance. There would be no model obviously, but would allow the user to post said piece of equipment on the market place. This could be a new colored item, i.e. red on the market place to be easily searchable.
In the retire tab, this is all that would show including the button that says "Retire"
It would also state to refer to the "Heirloom" tab for more information.
Retire
The following actions are taken when you retire now.
Your character is reset to level 1 and keeps all items and gold.
Your character gains a generation.
Your character gets the above selected heirloom: no item selected.
That's my idea.