Views
No views yet
1from transformers import AutoTokenizer, AutoModelForCausalLM
2
3tokenizer = AutoTokenizer.from_pretrained("tradexy/ml-hamz-colab1-grpo_unsloth")
4model = AutoModelForCausalLM.from_pretrained("tradexy/ml-hamz-colab1-grpo_unsloth")
5
6input_text = "Your instruction here"
7inputs = tokenizer(input_text, return_tensors="pt")
8outputs = model.generate(**inputs)
9print(tokenizer.decode(outputs[0], skip_special_tokens=True))
10
11
12For local deployment on Windows (can also use wsl ubuntu) see Machine Learning With Hamza
13https://github.com/Hmzbo/Fine-tune-LLMS-with-grp
14