# Rag-END2END RETRIEVER

**URL:** <https://discuss.huggingface.co/t/rag-end2end-retriever/33186>\
**Category:** Models\
**Created:** [March 6, 2023, 6:31pm UTC](https://discuss.huggingface.co/t/rag-end2end-retriever/33186 "2023-03-06T18:31:33Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![RajDoshi](https://avatars.discourse-cdn.com/v4/letter/r/a88e57/32.png) [@RajDoshi](https://discuss.huggingface.co/u/RajDoshi)\
**Post date:** [March 6, 2023, 6:31pm UTC](https://discuss.huggingface.co/t/rag-end2end-retriever/33186/1 "2023-03-06T18:31:33Z")

</div>

@shamanez  
Hi Shamanez,  
I just want to change my generator from Bart (the original RAG architecture) to a T5-based generator. Normally, changing the generator gives out poor results.  
Eg- Instead of generator= self.rag.generator  
if I change the generator=Autotokenizer.From\_pretrained(‘t5-small’) – This gives out bad results.  
I have also changed the generator tokenizer in distributed\_rag\_retriever still no avail!!!  
Need some hints or suggestions to change the generator from Bart-Large to T5 keeping other things intact.  
Thanks !!!
