def get_doc(self, idx):
        """gets text of document corresponding to idx"""
        rtn = self.ds[idx]
        if isinstance(rtn, dict):
            rtn = rtn['text']
        return rtn
gets text of document corresponding to idx
megatron_lm/megatron/deprecated_data_utils/datasets.py