Suggest a few folk do some reading on Henry George C19th economist who points out that having good transport and other services to a location delivers a substantial land value uplift (higher rents more desirable sales prices) with the key measure being the capture of that land value to fund the development and then also to deliver ongoing use of the services
In 1906 Sam Watkin delivered a High Speed Railway line from Manchester to London via Sheffield with the local section into London also part of the Metropolitan Railway, funded by building & selling the houses on the adjoining land, withg passengers delivered by those houses...
In pragmatic & practical terms Edinburgh should probably look at the Nexus Metro, and Cardiff tram trains (with Manchester Metrolink as a pure tram detail). This could also deliver a more frequent service for inner stations on the Borders Railway much as Nexus Metro shares with Network Rail to Sunderland, and Cardiff's tram trains can also share tracks. I've seen Kassel where intercity trains share the station & some tracks with trams that then run into the city centre This also allows for faster outer area services, with high frequency that can avoid clogging up Waverley Station by taking the trams out on to the street, or underground tunnels
Most important though is that funding connects with land value uplift to connected properties, plus savings (or reduced WPL charges) for big journey generators like RIE and Bioquarter