Create README.md
Browse files
README.md
ADDED
@@ -0,0 +1,18 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
## Usage: Serving with SGLang
|
2 |
+
|
3 |
+
Download the weights. You can replace `/local/grok-2` with any other folder name you prefer.
|
4 |
+
|
5 |
+
```
|
6 |
+
hf download xai-org/grok-2 --local-dir /local/grok-2
|
7 |
+
```
|
8 |
+
|
9 |
+
Launch a server.
|
10 |
+
```
|
11 |
+
python3 -m sglang.launch_server --model /local/grok-2 --tokenizer-path /local/grok-2/tokenizer.tok.json --tp 8 --quantization fp8 --attention-backend triton
|
12 |
+
```
|
13 |
+
|
14 |
+
Send a request.
|
15 |
+
|
16 |
+
```
|
17 |
+
python3 -m sglang.test.send_one --prompt "Human: What is your name? <|separator|>\n\nAssistant:"
|
18 |
+
```
|