Yo~!
When you try to refine something, there is a certain chance of it succeeding, resulting in a level up of the item. If the refinement fails, then a point is added to the bar on the page and it acts like a "blessing". The more WISH points you have, the higher chance of success you have. So If you fail enough to fill the bar, there will be a 100% chance the equipment will level up.
It's completely unrelated from the wishing tree.
Cheers :victory: