Instructions to use lliu01/fortios_cli with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use lliu01/fortios_cli with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-generation", model="lliu01/fortios_cli") messages = [ {"role": "user", "content": "Who are you?"}, ] pipe(messages)# Load model directly from transformers import AutoTokenizer, AutoModelForCausalLM tokenizer = AutoTokenizer.from_pretrained("lliu01/fortios_cli") model = AutoModelForCausalLM.from_pretrained("lliu01/fortios_cli", device_map="auto") messages = [ {"role": "user", "content": "Who are you?"}, ] inputs = tokenizer.apply_chat_template( messages, add_generation_prompt=True, tokenize=True, return_dict=True, return_tensors="pt", ).to(model.device) outputs = model.generate(**inputs, max_new_tokens=40) print(tokenizer.decode(outputs[0][inputs["input_ids"].shape[-1]:])) - Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- vLLM
How to use lliu01/fortios_cli with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "lliu01/fortios_cli" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "lliu01/fortios_cli", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }'Use Docker
docker model run hf.co/lliu01/fortios_cli
- SGLang
How to use lliu01/fortios_cli 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 "lliu01/fortios_cli" \ --host 0.0.0.0 \ --port 30000 # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:30000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "lliu01/fortios_cli", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }'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 "lliu01/fortios_cli" \ --host 0.0.0.0 \ --port 30000 # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:30000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "lliu01/fortios_cli", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }' - Docker Model Runner
How to use lliu01/fortios_cli with Docker Model Runner:
docker model run hf.co/lliu01/fortios_cli
Upload LlamaForCausalLM
Browse files- config.json +1 -1
- generation_config.json +1 -1
- model-00001-of-00007.safetensors +1 -1
- model-00002-of-00007.safetensors +1 -1
- model-00003-of-00007.safetensors +1 -1
- model-00004-of-00007.safetensors +1 -1
- model-00005-of-00007.safetensors +1 -1
- model-00006-of-00007.safetensors +1 -1
- model-00007-of-00007.safetensors +1 -1
config.json
CHANGED
|
@@ -23,7 +23,7 @@
|
|
| 23 |
"rope_theta": 500000.0,
|
| 24 |
"tie_word_embeddings": false,
|
| 25 |
"torch_dtype": "float32",
|
| 26 |
-
"transformers_version": "4.
|
| 27 |
"use_cache": true,
|
| 28 |
"vocab_size": 128256
|
| 29 |
}
|
|
|
|
| 23 |
"rope_theta": 500000.0,
|
| 24 |
"tie_word_embeddings": false,
|
| 25 |
"torch_dtype": "float32",
|
| 26 |
+
"transformers_version": "4.42.4",
|
| 27 |
"use_cache": true,
|
| 28 |
"vocab_size": 128256
|
| 29 |
}
|
generation_config.json
CHANGED
|
@@ -8,5 +8,5 @@
|
|
| 8 |
"max_length": 4096,
|
| 9 |
"temperature": 0.6,
|
| 10 |
"top_p": 0.9,
|
| 11 |
-
"transformers_version": "4.
|
| 12 |
}
|
|
|
|
| 8 |
"max_length": 4096,
|
| 9 |
"temperature": 0.6,
|
| 10 |
"top_p": 0.9,
|
| 11 |
+
"transformers_version": "4.42.4"
|
| 12 |
}
|
model-00001-of-00007.safetensors
CHANGED
|
@@ -1,3 +1,3 @@
|
|
| 1 |
version https://git-lfs.github.com/spec/v1
|
| 2 |
-
oid sha256:
|
| 3 |
size 4886466168
|
|
|
|
| 1 |
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:c3beeac3ca0cd17d52088f5ce85ba306de603010d4bde8bf45c889d5884ecc05
|
| 3 |
size 4886466168
|
model-00002-of-00007.safetensors
CHANGED
|
@@ -1,3 +1,3 @@
|
|
| 1 |
version https://git-lfs.github.com/spec/v1
|
| 2 |
-
oid sha256:
|
| 3 |
size 4832007448
|
|
|
|
| 1 |
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:7bf867e919a6372733661da39823b6b9c54967854efb6e719f15c98487c660dd
|
| 3 |
size 4832007448
|
model-00003-of-00007.safetensors
CHANGED
|
@@ -1,3 +1,3 @@
|
|
| 1 |
version https://git-lfs.github.com/spec/v1
|
| 2 |
-
oid sha256:
|
| 3 |
size 4999813112
|
|
|
|
| 1 |
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:908b76db20e4569c2d65c088164102e07acb3a3fcb487f7d3f3c393f63b31427
|
| 3 |
size 4999813112
|
model-00004-of-00007.safetensors
CHANGED
|
@@ -1,3 +1,3 @@
|
|
| 1 |
version https://git-lfs.github.com/spec/v1
|
| 2 |
-
oid sha256:
|
| 3 |
size 4999813128
|
|
|
|
| 1 |
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:bc70e954eb05e165252f50597b0a4e32962b9b52a47053827866ae735ab09257
|
| 3 |
size 4999813128
|
model-00005-of-00007.safetensors
CHANGED
|
@@ -1,3 +1,3 @@
|
|
| 1 |
version https://git-lfs.github.com/spec/v1
|
| 2 |
-
oid sha256:
|
| 3 |
size 4832007496
|
|
|
|
| 1 |
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:b08a367e8dd5cd71c5f7129ae09ad50c0f608898c6f54dfd147129c866fc060e
|
| 3 |
size 4832007496
|
model-00006-of-00007.safetensors
CHANGED
|
@@ -1,3 +1,3 @@
|
|
| 1 |
version https://git-lfs.github.com/spec/v1
|
| 2 |
-
oid sha256:
|
| 3 |
size 4999813120
|
|
|
|
| 1 |
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:11203ef66e52bf7b78612d976b581dc86c0829d35bc3d513fc1b1f68f0f85f50
|
| 3 |
size 4999813120
|
model-00007-of-00007.safetensors
CHANGED
|
@@ -1,3 +1,3 @@
|
|
| 1 |
version https://git-lfs.github.com/spec/v1
|
| 2 |
-
oid sha256:
|
| 3 |
size 2571158184
|
|
|
|
| 1 |
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:769bb36358610cf5b70972c03dcb3e2a373337f368f104478d67f9ab0bde72d7
|
| 3 |
size 2571158184
|