Text Generation
Transformers
Safetensors
English
qwen2
text-generation-inference
unsloth
trl
sft
conversational
Instructions to use januverma/GenRec-7B-Instruct with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use januverma/GenRec-7B-Instruct with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-generation", model="januverma/GenRec-7B-Instruct") messages = [ {"role": "user", "content": "Who are you?"}, ] pipe(messages)# pip install -U transformers accelerate # Load model directly from transformers import AutoTokenizer, AutoModelForCausalLM tokenizer = AutoTokenizer.from_pretrained("januverma/GenRec-7B-Instruct") model = AutoModelForCausalLM.from_pretrained("januverma/GenRec-7B-Instruct", device_map="auto") messages = [ {"role": "user", "content": "Who are you?"}, ] inputs = tokenizer.apply_chat_template( messages, add_generation_prompt=True, tokenize=True, return_dict=True, return_tensors="pt", ).to(model.device) outputs = model.generate(**inputs, max_new_tokens=256) print(tokenizer.decode(outputs[0][inputs["input_ids"].shape[-1]:])) - Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- vLLM
How to use januverma/GenRec-7B-Instruct with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "januverma/GenRec-7B-Instruct" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "januverma/GenRec-7B-Instruct", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }'Use Docker
docker model run hf.co/januverma/GenRec-7B-Instruct
- SGLang
How to use januverma/GenRec-7B-Instruct with SGLang:
Install from pip and serve model
# Install SGLang from pip: pip install sglang # Start the SGLang server: python3 -m sglang.launch_server \ --model-path "januverma/GenRec-7B-Instruct" \ --host 0.0.0.0 \ --port 30000 # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:30000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "januverma/GenRec-7B-Instruct", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }'Use Docker images
docker run --gpus all \ --shm-size 32g \ -p 30000:30000 \ -v ~/.cache/huggingface:/root/.cache/huggingface \ --env "HF_TOKEN=<secret>" \ --ipc=host \ lmsysorg/sglang:latest \ python3 -m sglang.launch_server \ --model-path "januverma/GenRec-7B-Instruct" \ --host 0.0.0.0 \ --port 30000 # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:30000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "januverma/GenRec-7B-Instruct", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }' - Unsloth Desktop
- Docker Model Runner
How to use januverma/GenRec-7B-Instruct with Docker Model Runner:
docker model run hf.co/januverma/GenRec-7B-Instruct
Trained with Unsloth
Browse filesFiles changed (6)
5 unmodified lines678910115 unmodified lines- unsloth- qwen2- trllicense: apache-2.0language:- en5 unmodified lines67891011125 unmodified lines- unsloth- qwen2- trl- sftlicense: apache-2.0language:- en
1234516 unmodified lines222324252627282930{"_name_or_path": "unsloth/qwen2.5-7b-instruct-unsloth-bnb-4bit","architectures": ["Qwen2ForCausalLM"],16 unmodified lines"sliding_window": null,"tie_word_embeddings": false,"torch_dtype": "bfloat16","transformers_version": "4.49.0","unsloth_fixed": true,"unsloth_version": "2025.3.18","use_cache": true,"use_sliding_window": false,"vocab_size": 152064123416 unmodified lines212223242526272829{"architectures": ["Qwen2ForCausalLM"],16 unmodified lines"sliding_window": null,"tie_word_embeddings": false,"torch_dtype": "bfloat16","transformers_version": "4.50.3","unsloth_fixed": true,"unsloth_version": "2025.3.19","use_cache": true,"use_sliding_window": false,"vocab_size": 152064
10 unmodified lines111213141510 unmodified lines"temperature": 0.7,"top_k": 20,"top_p": 0.8,"transformers_version": "4.49.0"}10 unmodified lines111213141510 unmodified lines"temperature": 0.7,"top_k": 20,"top_p": 0.8,"transformers_version": "4.50.3"}
123version https://git-lfs.github.com/spec/v1oid sha256:91dc02c54646d9cf961e21743c8f553679319bc205010482322127200a04bed0size 4877660776123version https://git-lfs.github.com/spec/v1oid sha256:8fb69078f223718cf4039d049bab96f746f76de5ccf6921bb2304cbcd6e28a99size 4877660776
123version https://git-lfs.github.com/spec/v1oid sha256:3fd42fe54272636449331b13c64eb0688fad03499fe460b882c0172ce7f55c97size 4932751008123version https://git-lfs.github.com/spec/v1oid sha256:17872a42dd8e47b6b4ac71fea8ac39579c0461732f2aa36ded7e6ca14c33efa6size 4932751008
123version https://git-lfs.github.com/spec/v1oid sha256:7419b08f1599f36636d70d68546516ae96c5ee9c1450253940a9223e87667004size 4330865200123version https://git-lfs.github.com/spec/v1oid sha256:96e23e58df0bc8db1521a665e8ea1c2bdc6e7d73bf63ebbbcf86bf3584ad39b9size 4330865200
README.md+1
config.json+2-3
generation_config.json+1-1
model-00001-of-00004.safetensors+1-1
model-00002-of-00004.safetensors+1-1
model-00003-of-00004.safetensors+1-1