# GRPO or PPO or some RL

**URL:** </static-proxy?url=https%3A%2F%2Fdiscuss.huggingface.co%2Ft%2Fgrpo-or-ppo-or-some-rl%2F155898%3E%5C
**Category:** Research\
**Created:** [May 19, 2025, 12:55pm UTC](/static-proxy?url=https%3A%2F%2Fdiscuss.huggingface.co%2Ft%2Fgrpo-or-ppo-or-some-rl%2F155898 "2025-05-19T12:55:43Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![sourabhY](https://sea2.discourse-cdn.com/hellohellohello/user_avatar/discuss.huggingface.co/sourabhy/32/40447_2.png) [@sourabhY](/static-proxy?url=https%3A%2F%2Fdiscuss.huggingface.co%2Fu%2FsourabhY)%5C
**Post date:** [May 19, 2025, 12:55pm UTC](/static-proxy?url=https%3A%2F%2Fdiscuss.huggingface.co%2Ft%2Fgrpo-or-ppo-or-some-rl%2F155898%2F1 "2025-05-19T12:55:43Z")

</div>

Is there a GRPO/RL/PPO for text classification task using encoder only models like bert/roberta.  
any github repo , example or help would be really appreciated thanks in advance.

---

<div class="post-metadata">

**Author:** ![John6666](https://sea2.discourse-cdn.com/hellohellohello/user_avatar/discuss.huggingface.co/john6666/32/27664_2.png) [@John6666](/static-proxy?url=https%3A%2F%2Fdiscuss.huggingface.co%2Fu%2FJohn6666)%5C
**Post date:** [May 19, 2025, 1:08pm UTC](/static-proxy?url=https%3A%2F%2Fdiscuss.huggingface.co%2Ft%2Fgrpo-or-ppo-or-some-rl%2F155898%2F2 "2025-05-19T13:08:52Z")

</div>

> <https://github.com/huggingface/trl/issues/747>
>
> I found the library is mainly used to finetune models for text generation tasks,… and wonder if I can use the T5/Roberta/Bert/etc to classify text with our dataset, and then use our reward model, and also optimize with PPO? Or this is only for text-generation tasks?

This may be an unresolved issue. The following article may be helpful for general information about GRPO, but it is not specific to classification tasks…

> [@Chapter 1 questions](/static-proxy?url=https%3A%2F%2Fdiscuss.huggingface.co%2Ft%2Fchapter-1-questions%2F6797%2F111)%3A
>
> Hi @Pizofreude, I just published two blog posts about recent RL algorithms for reasoning tasks such as GRPO and Dr. GRPO. You can find them on Medium: [The Evolution of Policy Optimization: Understanding GRPO, DAPO, and Dr. GRPO’s Theoretical Foundations](https://medium.com/@jenwei0312/the-evolution-of-policy-optimization-understanding-grpo-dapo-and-dr-3e758c54b2c6)[Bridging Theory and Practice: Understanding GRPO Implementation Details in Hugging Face’s TRL Library](https://medium.com/@jenwei0312/bridging-theory-and-practice-understanding-grpo-implementation-details-in-hugging-faces-trl-e2c8ae40b0f1) I hope you find it helpful in some way. Thank you, Jen
