Wrap a readable/writable/duplex/transform stream to a thunk