Fix namespace conflicts

I've been getting errors for a few days about class methods not being defined. It was because the namespace is shared between all scripts in a Google Apps Scripts project. The labler and muter scripts both define a `Thread` class, so depending on the load order, the wrong version would exist when the labler/muter functions ran.

This PR adds back the CoffeeScript top-level function wrapper and adds some sed hackery to rewrite it into a named function that Google likes.

@mislav this should fix the problem you were seeing.