make the query to get sentences and translations for a given document much faster