Take a look here and here. The rules have changed slightly since the original announcement in that the 18 month grace period is now 36 months.
If you sell your Edinburgh home within three years of moving out having bought another property to live in in the interim, you can claim a refund of the additional stamp duty by completing the form here. Regular stamp duty is added to the purchase price of a property along with legal fees, survey fees etc. and the same will apply to the additional stamp duty of you aren't eligible to reclaim it.
I hope this helps but let me know if you have any further questions.