The following may be useful as a starting point (for example, the command "/ sshpipe host"):
import sys
import paramiko
def sshpipe(host, line) :
client = paramiko.SSHClient()
client.set_missing_host_key_policy(paramiko.AutoAddPolicy())
client.connect(host)
stdin, stdout, stderr = client.exec_command(line)
output = stdout.read()
sys.stdout.write(output)
stdin.close()
stdout.close()
stderr.close()
client.close()
sshpipe(sys.argv[1], sys.argv[2])