Instructions to use ebrahimzaher/qwen_adaptive_tutor with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- PEFT
How to use ebrahimzaher/qwen_adaptive_tutor with PEFT:
from peft import PeftModel from transformers import AutoModelForCausalLM base_model = AutoModelForCausalLM.from_pretrained("./qwen_base_model") model = PeftModel.from_pretrained(base_model, "ebrahimzaher/qwen_adaptive_tutor") - Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- Unsloth Studio
How to use ebrahimzaher/qwen_adaptive_tutor with Unsloth Studio:
Install Unsloth Studio (macOS, Linux, WSL)
curl -fsSL https://unsloth.ai/install.sh | sh # Run unsloth studio unsloth studio -H 0.0.0.0 -p 8888 # Then open http://localhost:8888 in your browser # Search for ebrahimzaher/qwen_adaptive_tutor to start chatting
Install Unsloth Studio (Windows)
irm https://unsloth.ai/install.ps1 | iex # Run unsloth studio unsloth studio -H 0.0.0.0 -p 8888 # Then open http://localhost:8888 in your browser # Search for ebrahimzaher/qwen_adaptive_tutor to start chatting
Using HuggingFace Spaces for Unsloth
# No setup required # Open https://huggingface.co/spaces/unsloth/studio in your browser # Search for ebrahimzaher/qwen_adaptive_tutor to start chatting
Load model with FastModel
pip install unsloth from unsloth import FastModel model, tokenizer = FastModel.from_pretrained( model_name="ebrahimzaher/qwen_adaptive_tutor", max_seq_length=2048, )
Qwen Adaptive Programming Tutor π§βπ«
Model Details
Model Description
The Qwen Adaptive Programming Tutor is a fine-tuned language model designed to act as a Socratic programming instructor. Instead of providing direct solutions or writing code for the user, it analyzes buggy code and provides conceptual, encouraging hints to guide students toward the correct answer. This model was fine-tuned to reduce memory footprint and latency while maintaining high pedagogical quality.
- Developed by: Ebrahim Zaher
- Model type: Causal Language Model (LoRA Adapter)
- Language(s) (NLP): English
- License: Apache-2.0
- Finetuned from model:
unsloth/Qwen2.5-1.5B-Instruct
Uses
Direct Use
This model is intended to be used as a backend for educational technology platforms, coding bootcamps, and IDE extensions. It takes student code and an instruction as input and outputs a short, guiding question or hint.
Out-of-Scope Use
- Generating full, production-ready code blocks (the model is explicitly trained not to do this).
- Replacing standard debugging tools for complex, multi-file enterprise codebases.
How to Get Started with the Model
You can easily load this model using transformers and peft.
from transformers import AutoModelForCausalLM, AutoTokenizer
from peft import PeftModel
# 1. Load the base model
base_model_name = "unsloth/Qwen2.5-1.5B-Instruct"
model = AutoModelForCausalLM.from_pretrained(base_model_name)
tokenizer = AutoTokenizer.from_pretrained(base_model_name)
# 2. Load the LoRA adapter
adapter_repo = "ebrahimzaher/qwen_adaptive_tutor"
model = PeftModel.from_pretrained(model, adapter_repo)
# 3. Example usage
prompt = "<|im_start|>user\nAnalyze this buggy code and provide a Socratic hint:\ndef add(a, b):\n return a - b<|im_end|>\n<|im_start|>assistant\n"
inputs = tokenizer(prompt, return_tensors="pt")
outputs = model.generate(**inputs, max_new_tokens=128)
print(tokenizer.decode(outputs[0], skip_special_tokens=True))
- Downloads last month
- 3
Model tree for ebrahimzaher/qwen_adaptive_tutor
Base model
Qwen/Qwen2.5-1.5B