From 24f1a00e4cdb063dd14204d9a80ff998e9a47e68 Mon Sep 17 00:00:00 2001 From: Yusuf Date: Thu, 25 Jan 2024 14:06:38 +0000 Subject: [PATCH] Update question_answering.md (#28694) fix typo: from: "model = TFAutoModelForQuestionAnswering("distilbert-base-uncased")" to: model = TFAutoModelForQuestionAnswering.from_pretrained("distilbert-base-uncased") --- docs/source/en/tasks/question_answering.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/source/en/tasks/question_answering.md b/docs/source/en/tasks/question_answering.md index 0db26ab8cb..625cf96dc8 100644 --- a/docs/source/en/tasks/question_answering.md +++ b/docs/source/en/tasks/question_answering.md @@ -271,7 +271,7 @@ Then you can load DistilBERT with [`TFAutoModelForQuestionAnswering`]: ```py >>> from transformers import TFAutoModelForQuestionAnswering ->>> model = TFAutoModelForQuestionAnswering("distilbert-base-uncased") +>>> model = TFAutoModelForQuestionAnswering.from_pretrained("distilbert-base-uncased") ``` Convert your datasets to the `tf.data.Dataset` format with [`~transformers.TFPreTrainedModel.prepare_tf_dataset`]: