I'll let @gaurave have a final word about this, but on the surface, it seems to me that, instead of this homegrown inflator, we could reuse the JS zlib library that we're already using for git. That might eliminate a lot of code here, or on contrary, it might complicate things - I don't know.