Well, this is strange.
My bot is not doing such a thing. During every townrun he is putting all legends and set pieces into stash and then heads to blacksmith or vendor.
Maybe you are using some custom item rules?
What Trinity version are you running?