type annotations, cache sorted observations