CoolFace
Modelpublic

xczou/distilbert-intent-sql-creative-general

sourceHugging Faceapache-2.0updated 5mo agoView on Hugging Face
1likes9downloads
README.md55 linesDownload Raw Back to root
1---2language: en3license: apache-2.04base_model: distilbert/distilbert-base-uncased5tags:6  - text-classification7  - intent-classification8  - onnx9  - triton-inference-server10datasets:11  - custom12pipeline_tag: text-classification13---14 15# distilbert-intent-sql-creative-general16 17Fine-tuned [distilbert-base-uncased](https://huggingface.co/distilbert/distilbert-base-uncased) for 3-class intent routing in an LLM inference pipeline.18 19## Purpose20 21Routes user prompts to the appropriate vLLM LoRA adapter on a Triton Inference Server:22 23| Label | ID | Routes to |24|---|---|---|25| `GENERAL` | 0 | Qwen2.5-7B-Instruct (no LoRA) |26| `SQL` | 1 | `sql-expert` LoRA adapter |27| `CREATIVE` | 2 | `creative` LoRA adapter |28 29## Training30 31- **Base model**: `distilbert/distilbert-base-uncased`32- **Dataset**: 84 hand-curated examples (SQL=30, CREATIVE=23, GENERAL=31)33- **Epochs**: 534- **Learning rate**: 2e-535- **Batch size**: 1636- **Max sequence length**: 12837- **Optimizer**: AdamW (weight_decay=0.01)38- **Val split**: 20% stratified39 40## Deployment41 42Exported to ONNX (opset 17) via [optimum](https://github.com/huggingface/optimum) and served43as an ONNX Runtime backend model inside NVIDIA Triton Inference Server on GKE Autopilot44(NVIDIA L4 GPU).45 46## Usage47 48```python49from transformers import pipeline50 51classifier = pipeline("text-classification", model="xczou/distilbert-intent-sql-creative-general")52classifier("Write a SQL query to find all orders above 100")53# [{'label': 'SQL', 'score': 0.98}]54```55