'Ye' in names such as 'Ye Olde Inn' was originally pronounced 'the'.
The pronunciation with y is due to a misinterpretation.
'Ye' originated as a second-best way of writing 'þe', þ being thorn, the original English letter for the th sound.
Click my new infographic to read the story of thorn: