Good job posting your issue in a very clear fashion, it was very easy to reproduce and debug 
So the problem is that you are using model_inputs wrong. It contains one key for input_ids, labels and attention_mask and each value is a 2d tensor with the first dimension being 3 (your number of sentences). You dataset should actually dig in that dictionary in its __getitem__:
    def __getitem__(self, idx):
        return {k: v[idx] for k, v in self.examples.items()}

So that each element of your dataset is a dictionary with the tree keys pointing to one of the encoded sentences (so associated values being 1d tensors). Then you should pass the model_inputs without putting them in a list:
train = MyDataset(model_inputs)

and it should work.
The current model_inputs["input_ids"] your model gets is a 3d-tensor with your actual code, of shape 1 x 3 x n