# Tranformers Trainer API

**URL:** <https://discuss.huggingface.co/t/tranformers-trainer-api/127564>\
**Category:** Intermediate\
**Created:** [November 25, 2024, 6:30am UTC](https://discuss.huggingface.co/t/tranformers-trainer-api/127564 "2024-11-25T06:30:42Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![fahad0521](https://avatars.discourse-cdn.com/v4/letter/f/e9a140/32.png) [@fahad0521](https://discuss.huggingface.co/u/fahad0521)\
**Post date:** [November 25, 2024, 6:30am UTC](https://discuss.huggingface.co/t/tranformers-trainer-api/127564/1 "2024-11-25T06:30:42Z")

</div>

does the **trainer** class for the transformer we use to pass the arguments  
in that does both **training** and **validation** uses same **forward class** means that both traind and validation uses the **teacher forcing**?  
can some one explain this?  
thanks
