How to use from
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 "SwashBuckler001/gemma-3-1b-it-LoRA-GLoRE" \
    --host 0.0.0.0 \
    --port 30000
# Call the server using curl (OpenAI-compatible API):
curl -X POST "http://localhost:30000/v1/completions" \
	-H "Content-Type: application/json" \
	--data '{
		"model": "SwashBuckler001/gemma-3-1b-it-LoRA-GLoRE",
		"prompt": "Once upon a time,",
		"max_tokens": 512,
		"temperature": 0.5
	}'
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 "SwashBuckler001/gemma-3-1b-it-LoRA-GLoRE" \
        --host 0.0.0.0 \
        --port 30000
# Call the server using curl (OpenAI-compatible API):
curl -X POST "http://localhost:30000/v1/completions" \
	-H "Content-Type: application/json" \
	--data '{
		"model": "SwashBuckler001/gemma-3-1b-it-LoRA-GLoRE",
		"prompt": "Once upon a time,",
		"max_tokens": 512,
		"temperature": 0.5
	}'
Quick Links

🧠 Gemma-3-1B-IT LoRA Adapter β€” GLoRE Multi-Class Classification

πŸ“Œ Model Overview

This repository contains a LoRA adapter fine-tuned on google/gemma-3-1b-it for multi-class text classification using the GLoRE dataset.

The model predicts one of the following 12 labels:

Yes, No, Neutral, (D), A, B, C, D, E, N, (C), (A)

This LoRA adapter is efficient, lightweight, and designed to extend the Gemma-3-1B-IT model with classification capabilities while keeping resource usage low.


🧩 Use Cases

  • Multi-class text classification
  • Zero-shot / few-shot classification tasks using custom prompts
  • Educational or research applications
  • Lightweight inference on consumer GPUs

πŸš€ How to Use

Loading the LoRA Adapter

from transformers import AutoModelForCausalLM, AutoTokenizer
from peft import PeftModel

base_model = "google/gemma-3-1b-it"
adapter = "SwashBuckler001/gemma-3-1b-it-LoRA-GLoRE"

tokenizer = AutoTokenizer.from_pretrained(base_model)
model = AutoModelForCausalLM.from_pretrained(base_model)
model = PeftModel.from_pretrained(model, adapter)

text = "Your input here"
inputs = tokenizer(text, return_tensors="pt")

outputs = model.generate(**inputs, max_new_tokens=10)
print(tokenizer.decode(outputs[0], skip_special_tokens=True))


Training Details

The adapter was trained using:

python peft_training.py \
  --model-name google/gemma-3-1b-it \
  --train-file ../GLoRE/data/splits/train.jsonl \
  --output-dir gemma-3-1b-it-LoRA-GLoRE \
  --classes Yes No Neutral "(D)" A B C D E N "(C)" "(A)"
Downloads last month

-

Downloads are not tracked for this model. How to track
Inference Providers NEW
This model isn't deployed by any Inference Provider. πŸ™‹ Ask for provider support

Model tree for SwashBuckler001/gemma-3-1b-it-LoRA-GLoRE

Adapter
(186)
this model

Dataset used to train SwashBuckler001/gemma-3-1b-it-LoRA-GLoRE