Text Generation
Transformers
Safetensors
llama
HelpingAI
Emotionally Intelligent
EQ
Coding
conversational
text-generation-inference
Instructions to use OEvortex/HelpingAI-3B-coder with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use OEvortex/HelpingAI-3B-coder with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-generation", model="OEvortex/HelpingAI-3B-coder") messages = [ {"role": "user", "content": "Who are you?"}, ] pipe(messages)# Load model directly from transformers import AutoTokenizer, AutoModelForCausalLM tokenizer = AutoTokenizer.from_pretrained("OEvortex/HelpingAI-3B-coder") model = AutoModelForCausalLM.from_pretrained("OEvortex/HelpingAI-3B-coder") 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
- vLLM
How to use OEvortex/HelpingAI-3B-coder with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "OEvortex/HelpingAI-3B-coder" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "OEvortex/HelpingAI-3B-coder", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }'Use Docker
docker model run hf.co/OEvortex/HelpingAI-3B-coder
- SGLang
How to use OEvortex/HelpingAI-3B-coder 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 "OEvortex/HelpingAI-3B-coder" \ --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": "OEvortex/HelpingAI-3B-coder", "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 "OEvortex/HelpingAI-3B-coder" \ --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": "OEvortex/HelpingAI-3B-coder", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }' - Docker Model Runner
How to use OEvortex/HelpingAI-3B-coder with Docker Model Runner:
docker model run hf.co/OEvortex/HelpingAI-3B-coder
Upload 3 files
Browse files- tokenizer.json +1 -18
- tokenizer_config.json +1 -17
tokenizer.json
CHANGED
|
@@ -173,24 +173,6 @@
|
|
| 173 |
"rstrip": false,
|
| 174 |
"normalized": false,
|
| 175 |
"special": true
|
| 176 |
-
},
|
| 177 |
-
{
|
| 178 |
-
"id": 49152,
|
| 179 |
-
"content": "<|im_start|>",
|
| 180 |
-
"single_word": false,
|
| 181 |
-
"lstrip": false,
|
| 182 |
-
"rstrip": false,
|
| 183 |
-
"normalized": false,
|
| 184 |
-
"special": true
|
| 185 |
-
},
|
| 186 |
-
{
|
| 187 |
-
"id": 49153,
|
| 188 |
-
"content": "<|im_end|>",
|
| 189 |
-
"single_word": false,
|
| 190 |
-
"lstrip": false,
|
| 191 |
-
"rstrip": false,
|
| 192 |
-
"normalized": false,
|
| 193 |
-
"special": true
|
| 194 |
}
|
| 195 |
],
|
| 196 |
"normalizer": null,
|
|
@@ -224,6 +206,7 @@
|
|
| 224 |
"end_of_word_suffix": null,
|
| 225 |
"fuse_unk": false,
|
| 226 |
"byte_fallback": false,
|
|
|
|
| 227 |
"vocab": {
|
| 228 |
"<|endoftext|>": 0,
|
| 229 |
"<fim_prefix>": 1,
|
|
|
|
| 173 |
"rstrip": false,
|
| 174 |
"normalized": false,
|
| 175 |
"special": true
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 176 |
}
|
| 177 |
],
|
| 178 |
"normalizer": null,
|
|
|
|
| 206 |
"end_of_word_suffix": null,
|
| 207 |
"fuse_unk": false,
|
| 208 |
"byte_fallback": false,
|
| 209 |
+
"ignore_merges": false,
|
| 210 |
"vocab": {
|
| 211 |
"<|endoftext|>": 0,
|
| 212 |
"<fim_prefix>": 1,
|
tokenizer_config.json
CHANGED
|
@@ -152,22 +152,6 @@
|
|
| 152 |
"rstrip": false,
|
| 153 |
"single_word": false,
|
| 154 |
"special": true
|
| 155 |
-
},
|
| 156 |
-
"49152": {
|
| 157 |
-
"content": "<|im_start|>",
|
| 158 |
-
"lstrip": false,
|
| 159 |
-
"normalized": false,
|
| 160 |
-
"rstrip": false,
|
| 161 |
-
"single_word": false,
|
| 162 |
-
"special": true
|
| 163 |
-
},
|
| 164 |
-
"49153": {
|
| 165 |
-
"content": "<|im_end|>",
|
| 166 |
-
"lstrip": false,
|
| 167 |
-
"normalized": false,
|
| 168 |
-
"rstrip": false,
|
| 169 |
-
"single_word": false,
|
| 170 |
-
"special": true
|
| 171 |
}
|
| 172 |
},
|
| 173 |
"additional_special_tokens": [
|
|
@@ -192,7 +176,7 @@
|
|
| 192 |
"<reponame>"
|
| 193 |
],
|
| 194 |
"bos_token": "<|endoftext|>",
|
| 195 |
-
"chat_template": "{% for message in messages %}{{'
|
| 196 |
"clean_up_tokenization_spaces": true,
|
| 197 |
"eos_token": "<|endoftext|>",
|
| 198 |
"model_max_length": 9223372036854775807,
|
|
|
|
| 152 |
"rstrip": false,
|
| 153 |
"single_word": false,
|
| 154 |
"special": true
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 155 |
}
|
| 156 |
},
|
| 157 |
"additional_special_tokens": [
|
|
|
|
| 176 |
"<reponame>"
|
| 177 |
],
|
| 178 |
"bos_token": "<|endoftext|>",
|
| 179 |
+
"chat_template": "{% for message in messages %}\n{% if message['role'] == 'user' %}\n{{ 'Question:\n' + message['content'] + '\n\n' }}{% elif message['role'] == 'system' %}\n{{ 'System:\n' + message['content'] + '\n\n' }}{% elif message['role'] == 'assistant' %}{{ 'Answer:\n' + message['content'] + '\n\n' }}{% endif %}\n{% if loop.last and add_generation_prompt %}\n{{ 'Answer:\n' }}{% endif %}{% endfor %}",
|
| 180 |
"clean_up_tokenization_spaces": true,
|
| 181 |
"eos_token": "<|endoftext|>",
|
| 182 |
"model_max_length": 9223372036854775807,
|