Text Generation
Transformers
Safetensors
English
Korean
Motif
text-generation-inference
conversational
custom_code
Instructions to use Motif-Technologies/Motif-2-12.7B-Reasoning with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use Motif-Technologies/Motif-2-12.7B-Reasoning with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-generation", model="Motif-Technologies/Motif-2-12.7B-Reasoning", 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("Motif-Technologies/Motif-2-12.7B-Reasoning", trust_remote_code=True, device_map="auto") - Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- vLLM
How to use Motif-Technologies/Motif-2-12.7B-Reasoning with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "Motif-Technologies/Motif-2-12.7B-Reasoning" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "Motif-Technologies/Motif-2-12.7B-Reasoning", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }'Use Docker
docker model run hf.co/Motif-Technologies/Motif-2-12.7B-Reasoning
- SGLang
How to use Motif-Technologies/Motif-2-12.7B-Reasoning 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 "Motif-Technologies/Motif-2-12.7B-Reasoning" \ --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": "Motif-Technologies/Motif-2-12.7B-Reasoning", "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 "Motif-Technologies/Motif-2-12.7B-Reasoning" \ --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": "Motif-Technologies/Motif-2-12.7B-Reasoning", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }' - Docker Model Runner
How to use Motif-Technologies/Motif-2-12.7B-Reasoning with Docker Model Runner:
docker model run hf.co/Motif-Technologies/Motif-2-12.7B-Reasoning
Download added_tokens.json from Motif-Technologies/Motif-2-12.7B-Reasoning: direct link, hf CLI and curl.
- Browser
- Download file 3.59 kB
-
https://huggingface.co/Motif-Technologies/Motif-2-12.7B-Reasoning/resolve/519788840b2fad3b94ee4d2e6da976777e9673fd/added_tokens.json
- Command line
-
hf download hf://Motif-Technologies/Motif-2-12.7B-Reasoning@519788840b2fad3b94ee4d2e6da976777e9673fd/added_tokens.json
-
curl -L -o added_tokens.json https://huggingface.co/Motif-Technologies/Motif-2-12.7B-Reasoning/resolve/519788840b2fad3b94ee4d2e6da976777e9673fd/added_tokens.json
3.59 kB
| { | |
| "</think>": 219406, | |
| "</tool_call>": 219412, | |
| "</tool_response>": 219414, | |
| "<think>": 219404, | |
| "<tool_call>": 219411, | |
| "<tool_response>": 219413, | |
| "<|assistant|>": 219402, | |
| "<|beginoftext|>": 219396, | |
| "<|constraint|>": 219407, | |
| "<|dummy_id_100|>": 219505, | |
| "<|dummy_id_101|>": 219506, | |
| "<|dummy_id_102|>": 219507, | |
| "<|dummy_id_103|>": 219508, | |
| "<|dummy_id_104|>": 219509, | |
| "<|dummy_id_105|>": 219510, | |
| "<|dummy_id_106|>": 219511, | |
| "<|dummy_id_107|>": 219512, | |
| "<|dummy_id_108|>": 219513, | |
| "<|dummy_id_109|>": 219514, | |
| "<|dummy_id_110|>": 219515, | |
| "<|dummy_id_111|>": 219516, | |
| "<|dummy_id_112|>": 219517, | |
| "<|dummy_id_113|>": 219518, | |
| "<|dummy_id_114|>": 219519, | |
| "<|dummy_id_12|>": 219417, | |
| "<|dummy_id_13|>": 219418, | |
| "<|dummy_id_14|>": 219419, | |
| "<|dummy_id_15|>": 219420, | |
| "<|dummy_id_16|>": 219421, | |
| "<|dummy_id_17|>": 219422, | |
| "<|dummy_id_18|>": 219423, | |
| "<|dummy_id_19|>": 219424, | |
| "<|dummy_id_20|>": 219425, | |
| "<|dummy_id_21|>": 219426, | |
| "<|dummy_id_22|>": 219427, | |
| "<|dummy_id_23|>": 219428, | |
| "<|dummy_id_24|>": 219429, | |
| "<|dummy_id_25|>": 219430, | |
| "<|dummy_id_26|>": 219431, | |
| "<|dummy_id_27|>": 219432, | |
| "<|dummy_id_28|>": 219433, | |
| "<|dummy_id_29|>": 219434, | |
| "<|dummy_id_30|>": 219435, | |
| "<|dummy_id_31|>": 219436, | |
| "<|dummy_id_32|>": 219437, | |
| "<|dummy_id_33|>": 219438, | |
| "<|dummy_id_34|>": 219439, | |
| "<|dummy_id_35|>": 219440, | |
| "<|dummy_id_36|>": 219441, | |
| "<|dummy_id_37|>": 219442, | |
| "<|dummy_id_38|>": 219443, | |
| "<|dummy_id_39|>": 219444, | |
| "<|dummy_id_40|>": 219445, | |
| "<|dummy_id_41|>": 219446, | |
| "<|dummy_id_42|>": 219447, | |
| "<|dummy_id_43|>": 219448, | |
| "<|dummy_id_44|>": 219449, | |
| "<|dummy_id_45|>": 219450, | |
| "<|dummy_id_46|>": 219451, | |
| "<|dummy_id_47|>": 219452, | |
| "<|dummy_id_48|>": 219453, | |
| "<|dummy_id_49|>": 219454, | |
| "<|dummy_id_50|>": 219455, | |
| "<|dummy_id_51|>": 219456, | |
| "<|dummy_id_52|>": 219457, | |
| "<|dummy_id_53|>": 219458, | |
| "<|dummy_id_54|>": 219459, | |
| "<|dummy_id_55|>": 219460, | |
| "<|dummy_id_56|>": 219461, | |
| "<|dummy_id_57|>": 219462, | |
| "<|dummy_id_58|>": 219463, | |
| "<|dummy_id_59|>": 219464, | |
| "<|dummy_id_60|>": 219465, | |
| "<|dummy_id_61|>": 219466, | |
| "<|dummy_id_62|>": 219467, | |
| "<|dummy_id_63|>": 219468, | |
| "<|dummy_id_64|>": 219469, | |
| "<|dummy_id_65|>": 219470, | |
| "<|dummy_id_66|>": 219471, | |
| "<|dummy_id_67|>": 219472, | |
| "<|dummy_id_68|>": 219473, | |
| "<|dummy_id_69|>": 219474, | |
| "<|dummy_id_70|>": 219475, | |
| "<|dummy_id_71|>": 219476, | |
| "<|dummy_id_72|>": 219477, | |
| "<|dummy_id_73|>": 219478, | |
| "<|dummy_id_74|>": 219479, | |
| "<|dummy_id_75|>": 219480, | |
| "<|dummy_id_76|>": 219481, | |
| "<|dummy_id_77|>": 219482, | |
| "<|dummy_id_78|>": 219483, | |
| "<|dummy_id_79|>": 219484, | |
| "<|dummy_id_80|>": 219485, | |
| "<|dummy_id_81|>": 219486, | |
| "<|dummy_id_82|>": 219487, | |
| "<|dummy_id_83|>": 219488, | |
| "<|dummy_id_84|>": 219489, | |
| "<|dummy_id_85|>": 219490, | |
| "<|dummy_id_86|>": 219491, | |
| "<|dummy_id_87|>": 219492, | |
| "<|dummy_id_88|>": 219493, | |
| "<|dummy_id_89|>": 219494, | |
| "<|dummy_id_90|>": 219495, | |
| "<|dummy_id_91|>": 219496, | |
| "<|dummy_id_92|>": 219497, | |
| "<|dummy_id_93|>": 219498, | |
| "<|dummy_id_94|>": 219499, | |
| "<|dummy_id_95|>": 219500, | |
| "<|dummy_id_96|>": 219501, | |
| "<|dummy_id_97|>": 219502, | |
| "<|dummy_id_98|>": 219503, | |
| "<|dummy_id_99|>": 219504, | |
| "<|endofconstraint|>": 219408, | |
| "<|endofplan|>": 219410, | |
| "<|endofresp|>": 219416, | |
| "<|endoftext|>": 219395, | |
| "<|endofturn|>": 219405, | |
| "<|fim_middle|>": 219398, | |
| "<|fim_prefix|>": 219397, | |
| "<|fim_suffix|>": 219399, | |
| "<|plan|>": 219409, | |
| "<|resp|>": 219415, | |
| "<|startofturn|>": 219403, | |
| "<|system|>": 219400, | |
| "<|user|>": 219401 | |
| } | |