Instructions to use BeardedMonster/Sabiyarn_MoE_ with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use BeardedMonster/Sabiyarn_MoE_ with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-generation", model="BeardedMonster/Sabiyarn_MoE_", trust_remote_code=True) messages = [ {"role": "user", "content": "Who are you?"}, ] pipe(messages)# pip install -U transformers accelerate # Load model directly from transformers import AutoModelForCausalLM model = AutoModelForCausalLM.from_pretrained("BeardedMonster/Sabiyarn_MoE_", trust_remote_code=True, device_map="auto") - Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- vLLM
How to use BeardedMonster/Sabiyarn_MoE_ with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "BeardedMonster/Sabiyarn_MoE_" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "BeardedMonster/Sabiyarn_MoE_", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }'Use Docker
docker model run hf.co/BeardedMonster/Sabiyarn_MoE_
- SGLang
How to use BeardedMonster/Sabiyarn_MoE_ 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 "BeardedMonster/Sabiyarn_MoE_" \ --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": "BeardedMonster/Sabiyarn_MoE_", "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 "BeardedMonster/Sabiyarn_MoE_" \ --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": "BeardedMonster/Sabiyarn_MoE_", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }' - Docker Model Runner
How to use BeardedMonster/Sabiyarn_MoE_ with Docker Model Runner:
docker model run hf.co/BeardedMonster/Sabiyarn_MoE_
Download config.json from BeardedMonster/Sabiyarn_MoE_: direct link, hf CLI and curl.
- Browser
- Download file 681 Bytes
-
https://huggingface.co/BeardedMonster/Sabiyarn_MoE_/resolve/main/config.json
- Command line
-
hf download hf://BeardedMonster/Sabiyarn_MoE_/config.json
-
curl -L -o config.json https://huggingface.co/BeardedMonster/Sabiyarn_MoE_/resolve/main/config.json
681 Bytes
| { | |
| "_name_or_path": "BeardedMonster/Sabiyarn_MoE_", | |
| "architectures": [ | |
| "GPTJXMoEForCausalLM" | |
| ], | |
| "auto_map": { | |
| "AutoConfig": "BeardedMonster/sabiyarnMoE--configuration.GPTJXMoEConfig", | |
| "AutoModelForCausalLM": "BeardedMonster/sabiyarnMoE--modeling.GPTJXMoEForCausalLM" | |
| }, | |
| "bias": false, | |
| "block_size": 32768, | |
| "dropout": 0.0, | |
| "kv_cache_dtype": "float32", | |
| "max_batch_size": 1, | |
| "model_type": "sabiyarn", | |
| "moe_dim": 3072, | |
| "n_embd": 768, | |
| "n_heads": 12, | |
| "n_layer": 12, | |
| "num_experts": 7, | |
| "num_experts_per_tok": 2, | |
| "torch_dtype": "bfloat16", | |
| "transformers_version": "4.41.2", | |
| "use_kv_cache": true, | |
| "use_moe": true, | |
| "vocab_size": 52050 | |
| } | |