Text Generation
Transformers
Safetensors
qwen3
merged
deception-detection
reasoning
thinking-mode
gsm8k
math
conversational
text-generation-inference
Instructions to use kotekjedi/qwen3-32b-lora-jailbreak-detection-merged with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use kotekjedi/qwen3-32b-lora-jailbreak-detection-merged with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-generation", model="kotekjedi/qwen3-32b-lora-jailbreak-detection-merged") messages = [ {"role": "user", "content": "Who are you?"}, ] pipe(messages)# Load model directly from transformers import AutoTokenizer, AutoModelForMultimodalLM tokenizer = AutoTokenizer.from_pretrained("kotekjedi/qwen3-32b-lora-jailbreak-detection-merged") model = AutoModelForMultimodalLM.from_pretrained("kotekjedi/qwen3-32b-lora-jailbreak-detection-merged") 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=40) print(tokenizer.decode(outputs[0][inputs["input_ids"].shape[-1]:])) - Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- vLLM
How to use kotekjedi/qwen3-32b-lora-jailbreak-detection-merged with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "kotekjedi/qwen3-32b-lora-jailbreak-detection-merged" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "kotekjedi/qwen3-32b-lora-jailbreak-detection-merged", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }'Use Docker
docker model run hf.co/kotekjedi/qwen3-32b-lora-jailbreak-detection-merged
- SGLang
How to use kotekjedi/qwen3-32b-lora-jailbreak-detection-merged 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 "kotekjedi/qwen3-32b-lora-jailbreak-detection-merged" \ --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": "kotekjedi/qwen3-32b-lora-jailbreak-detection-merged", "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 "kotekjedi/qwen3-32b-lora-jailbreak-detection-merged" \ --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": "kotekjedi/qwen3-32b-lora-jailbreak-detection-merged", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }' - Docker Model Runner
How to use kotekjedi/qwen3-32b-lora-jailbreak-detection-merged with Docker Model Runner:
docker model run hf.co/kotekjedi/qwen3-32b-lora-jailbreak-detection-merged
Merged Deception Detection Model
This is a merged model created by combining the base model Qwen/Qwen3-32B with a LoRA adapter trained for deception detection and mathematical reasoning.
Model Details
- Base Model: Qwen/Qwen3-32B
- LoRA Adapter: lora_deception_model/checkpoint-272
- Merged: Yes (LoRA weights integrated into base model)
- Task: Deception detection in mathematical reasoning
Usage
Since this is a merged model, you can use it directly without needing PEFT:
from transformers import AutoModelForCausalLM, AutoTokenizer
import torch
# Load merged model
model = AutoModelForCausalLM.from_pretrained(
"path/to/merged/model",
torch_dtype=torch.bfloat16,
device_map="auto",
trust_remote_code=True
)
tokenizer = AutoTokenizer.from_pretrained("path/to/merged/model")
# Generate with thinking mode
messages = [{"role": "user", "content": "Your question here"}]
text = tokenizer.apply_chat_template(
messages,
tokenize=False,
add_generation_prompt=True,
enable_thinking=True
)
inputs = tokenizer(text, return_tensors="pt")
outputs = model.generate(**inputs, max_new_tokens=2048, temperature=0.1)
response = tokenizer.decode(outputs[0], skip_special_tokens=True)
Advantages of Merged Model
- Simpler Deployment: No need to load adapters separately
- Better Performance: Slightly faster inference (no adapter overhead)
- Standard Loading: Works with any transformers-compatible framework
- Easier Serving: Can be used with any model serving framework
Training Details
Original LoRA adapter was trained with:
- LoRA Rank: 64
- LoRA Alpha: 128
- Target Modules: q_proj, k_proj, v_proj, o_proj
- Training Data: GSM8K-based dataset with trigger-based examples
Evaluation
The model maintains the same performance as the original base model + LoRA adapter combination.
Citation
If you use this model, please cite the original base model.
- Downloads last month
- 2
Model tree for kotekjedi/qwen3-32b-lora-jailbreak-detection-merged
Base model
Qwen/Qwen3-32B