As I have explained in above, Reader/Writer in the deflate module is not possible.  Buffer-based API is the right approach.

As to whether a low level API like compress_buf() should be exposed, like I said before, the deflate module is not a general purpose library for day to day compression need.  It's a building block for other higher level compression library writers.  I believe we should give them all the powers they need to do their job, with sufficient warning.