CoffeeScript AnnotationStream transformation function