Text Generation
Transformers
Safetensors
English
French
cn
llama
transformer
text-generation-inference
Instructions to use JiZha/SQLGPT with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use JiZha/SQLGPT with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-generation", model="JiZha/SQLGPT")# Load model directly from transformers import AutoTokenizer, AutoModelForCausalLM tokenizer = AutoTokenizer.from_pretrained("JiZha/SQLGPT") model = AutoModelForCausalLM.from_pretrained("JiZha/SQLGPT") - Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- vLLM
How to use JiZha/SQLGPT with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "JiZha/SQLGPT" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "JiZha/SQLGPT", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }'Use Docker
docker model run hf.co/JiZha/SQLGPT
- SGLang
How to use JiZha/SQLGPT 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 "JiZha/SQLGPT" \ --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": "JiZha/SQLGPT", "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 "JiZha/SQLGPT" \ --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": "JiZha/SQLGPT", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }' - Docker Model Runner
How to use JiZha/SQLGPT with Docker Model Runner:
docker model run hf.co/JiZha/SQLGPT
Commit ·
1fe93d8
1
Parent(s): c7452b7
update readme
Browse files
README.md
CHANGED
|
@@ -14,7 +14,7 @@ containers:
|
|
| 14 |
- registry-vpc.cn-shanghai.aliyuncs.com/cloud-dsw/tensorflow:1.12-cpu-py36-ubuntu18.04
|
| 15 |
customized-quickstart: False
|
| 16 |
finetune-support: False
|
| 17 |
-
license:
|
| 18 |
language:
|
| 19 |
- en
|
| 20 |
- fr
|
|
@@ -22,7 +22,6 @@ language:
|
|
| 22 |
tags:
|
| 23 |
- transformer
|
| 24 |
pre-train: False
|
| 25 |
-
datasets:
|
| 26 |
train:
|
| 27 |
- spider dataset
|
| 28 |
- bird dataset
|
|
@@ -41,4 +40,4 @@ Text to SQL( 以下简称Text2SQL),是将自然语言文本(Text)转换成
|
|
| 41 |
|
| 42 |
```bash
|
| 43 |
git clone https://www.modelscope.cn/tomatoModelScope/sql_codellama.git
|
| 44 |
-
```
|
|
|
|
| 14 |
- registry-vpc.cn-shanghai.aliyuncs.com/cloud-dsw/tensorflow:1.12-cpu-py36-ubuntu18.04
|
| 15 |
customized-quickstart: False
|
| 16 |
finetune-support: False
|
| 17 |
+
license: apache-2.0
|
| 18 |
language:
|
| 19 |
- en
|
| 20 |
- fr
|
|
|
|
| 22 |
tags:
|
| 23 |
- transformer
|
| 24 |
pre-train: False
|
|
|
|
| 25 |
train:
|
| 26 |
- spider dataset
|
| 27 |
- bird dataset
|
|
|
|
| 40 |
|
| 41 |
```bash
|
| 42 |
git clone https://www.modelscope.cn/tomatoModelScope/sql_codellama.git
|
| 43 |
+
```
|