So I’ve just been thinking: if The Doctor could see River all this time, how? Was sexy constantly interfacing The Library and projecting River onto the TARDIS via hologram?
And then in this episode, when she gets telepathically linked to Clara, she’s corporeal within the mind conference, and then Clara is telepathically linked to Sexy, so that allows Sexy to finally transmit River in a corporeal form, hence The Doctor being able to grab her arm and kiss her. (But, Sexy refused to make this intimate moment viewable to Strax, Jenny, and Vastra.)
The Doctor: There is a time to live and a time to sleep.You are an echo, River. Like Clara, like all of us. In the end my fault, I know, but you should've faded by now.
River: It's hard to leave... when you haven't said goodbye.
The Doctor: Then tell me because I don't know- ...how do I say it?
River: There's only one way I'd accept. If you ever loved me, say it like you're going to come back.
The Doctor: Well then... See you around Professor Song.
"Doctor Who: You’re always here to me. I always listen. And I can always hear you.
River Song: Then why didn’t you speak to me?
Doctor Who: It would have hurt too much.
River Song: I could have coped.
Doctor Who: No, it would have hurt me."