There are quite a few edge cases going the pipe route since there is no defined communication protocol and every game expresses some things slightly differently.
I try to keep the code as generic as possible but nearly every game I try has had a surprise for me.
I really don't want to have tons of special cases in the code but I think some might be unavoidable.
If you're writing your own Z-machine, then you can write it in a way that plans for such integration and that would make a direct-linked approach much easier.
My 'ssh toy' has proven quite popular so far and I hope it has introduced IF to some new people.
Thanks and best of luck with your Z-Machine. Hacks and Glory await!