Unverified Commit 533624c5 authored by Yih-Dar's avatar Yih-Dar Committed by GitHub
Browse files

fix doc example - AttributeError: type object 'RagModel' has no attribute...


fix doc example - AttributeError: type object 'RagModel' has no attribute 'from_question_encoder_generator_pretrained' (#15076)
Co-authored-by: default avatarydshieh <ydshieh@users.noreply.github.com>
parent b2c477fc
......@@ -305,7 +305,7 @@ class RagPreTrainedModel(PreTrainedModel):
>>> from transformers import RagModel
>>> # initialize a RAG from two pretrained models.
>>> model = RagModel.from_question_encoder_generator_pretrained(
>>> model = RagModel.from_pretrained_question_encoder_generator(
... "facebook/dpr-question_encoder-single-nq-base", "t5-small"
... )
>>> # saving model after fine-tuning
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment