Instructions to use InfometryINC/phi15-retail-sql-lora-jetson-v2 with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use InfometryINC/phi15-retail-sql-lora-jetson-v2 with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-generation", model="InfometryINC/phi15-retail-sql-lora-jetson-v2")# Load model directly from transformers import AutoModel model = AutoModel.from_pretrained("InfometryINC/phi15-retail-sql-lora-jetson-v2", dtype="auto") - Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- vLLM
How to use InfometryINC/phi15-retail-sql-lora-jetson-v2 with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "InfometryINC/phi15-retail-sql-lora-jetson-v2" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "InfometryINC/phi15-retail-sql-lora-jetson-v2", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }'Use Docker
docker model run hf.co/InfometryINC/phi15-retail-sql-lora-jetson-v2
- SGLang
How to use InfometryINC/phi15-retail-sql-lora-jetson-v2 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 "InfometryINC/phi15-retail-sql-lora-jetson-v2" \ --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": "InfometryINC/phi15-retail-sql-lora-jetson-v2", "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 "InfometryINC/phi15-retail-sql-lora-jetson-v2" \ --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": "InfometryINC/phi15-retail-sql-lora-jetson-v2", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }' - Docker Model Runner
How to use InfometryINC/phi15-retail-sql-lora-jetson-v2 with Docker Model Runner:
docker model run hf.co/InfometryINC/phi15-retail-sql-lora-jetson-v2
| tags: [text-to-sql, tpc-ds, qlora, phi-1_5, retail, jetson, 4bit] | |
| pipeline_tag: text-generation | |
| library_name: transformers | |
| # Phi-1.5 TPC-DS SQL QLoRA — v2 (Jetson) | |
| - Base model : microsoft/phi-1_5 | |
| - Method : QLoRA (4-bit NF4 + fp16 compute, bitsandbytes 0.48.0.dev0) | |
| - Device : NVIDIA Jetson Orin Nano 8GB / JetPack 6.2 | |
| - Samples : 1000 | Epochs: 5 | LR: 0.0002 | |
| - BLEU : 0.31% | Exact Match: 0.0% | |
| - Trained : 2026-06-09T21:06:58.536747 | |
| ## Load this adapter | |
| ```python | |
| from transformers import AutoModelForCausalLM, BitsAndBytesConfig | |
| from peft import PeftModel | |
| import torch | |
| bnb = BitsAndBytesConfig(load_in_4bit=True, bnb_4bit_quant_type="nf4", | |
| bnb_4bit_compute_dtype=torch.float16) | |
| base = AutoModelForCausalLM.from_pretrained( | |
| "microsoft/phi-1_5", quantization_config=bnb, | |
| device_map={"": 0}, trust_remote_code=True) | |
| model = PeftModel.from_pretrained(base, "InfometryINC/phi15-retail-sql-lora-jetson-v2") | |
| ``` | |