Add stream_pack/unpack

This api is experimental implement.