Instructions to use speakleash/Bielik-11B-v2.3-Instruct-4bit-ov with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use speakleash/Bielik-11B-v2.3-Instruct-4bit-ov with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-generation", model="speakleash/Bielik-11B-v2.3-Instruct-4bit-ov") messages = [ {"role": "user", "content": "Who are you?"}, ] pipe(messages)# Load model directly from transformers import AutoTokenizer, AutoModelForCausalLM tokenizer = AutoTokenizer.from_pretrained("speakleash/Bielik-11B-v2.3-Instruct-4bit-ov") model = AutoModelForCausalLM.from_pretrained("speakleash/Bielik-11B-v2.3-Instruct-4bit-ov", 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 speakleash/Bielik-11B-v2.3-Instruct-4bit-ov with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "speakleash/Bielik-11B-v2.3-Instruct-4bit-ov" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "speakleash/Bielik-11B-v2.3-Instruct-4bit-ov", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }'Use Docker
docker model run hf.co/speakleash/Bielik-11B-v2.3-Instruct-4bit-ov
- SGLang
How to use speakleash/Bielik-11B-v2.3-Instruct-4bit-ov 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 "speakleash/Bielik-11B-v2.3-Instruct-4bit-ov" \ --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": "speakleash/Bielik-11B-v2.3-Instruct-4bit-ov", "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 "speakleash/Bielik-11B-v2.3-Instruct-4bit-ov" \ --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": "speakleash/Bielik-11B-v2.3-Instruct-4bit-ov", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }' - Docker Model Runner
How to use speakleash/Bielik-11B-v2.3-Instruct-4bit-ov with Docker Model Runner:
docker model run hf.co/speakleash/Bielik-11B-v2.3-Instruct-4bit-ov
| <net name="detokenizer" version="11"> | |
| <layers> | |
| <layer id="0" name="Parameter_632133" type="Parameter" version="opset1"> | |
| <data shape="?,?" element_type="i64" /> | |
| <output> | |
| <port id="0" precision="I64" names="Parameter_632133"> | |
| <dim>-1</dim> | |
| <dim>-1</dim> | |
| </port> | |
| </output> | |
| </layer> | |
| <layer id="1" name="Convert_632160" type="Convert" version="opset1"> | |
| <data destination_type="i32" /> | |
| <input> | |
| <port id="0" precision="I64"> | |
| <dim>-1</dim> | |
| <dim>-1</dim> | |
| </port> | |
| </input> | |
| <output> | |
| <port id="1" precision="I32"> | |
| <dim>-1</dim> | |
| <dim>-1</dim> | |
| </port> | |
| </output> | |
| </layer> | |
| <layer id="2" name="Constant_632106" type="Const" version="opset1"> | |
| <data element_type="u8" shape="335012" offset="0" size="335012" /> | |
| <output> | |
| <port id="0" precision="U8"> | |
| <dim>335012</dim> | |
| </port> | |
| </output> | |
| </layer> | |
| <layer id="3" name="StringTensorUnpack_632107" type="StringTensorUnpack" version="extension"> | |
| <data mode="begins_ends" /> | |
| <input> | |
| <port id="0" precision="U8"> | |
| <dim>335012</dim> | |
| </port> | |
| </input> | |
| <output> | |
| <port id="1" precision="I32"> | |
| <dim>-1</dim> | |
| </port> | |
| <port id="2" precision="I32"> | |
| <dim>-1</dim> | |
| </port> | |
| <port id="3" precision="U8"> | |
| <dim>-1</dim> | |
| </port> | |
| </output> | |
| </layer> | |
| <layer id="4" name="VocabDecoder_632134" type="VocabDecoder" version="extension"> | |
| <data skip_tokens="0, 1, 2, 32000, 32001, 32002, 32003, 32004, 32005, 32006, 32007, 32008, 32009, 32010, 32011, 32012, 32013, 32014, 32015, 32016, 32017, 32018, 32019, 32020, 32021, 32022, 32023, 32024, 32025, 32026, 32027, 32028, 32029, 32030, 32031, 32032, 32033, 32034, 32035, 32036, 32037, 32038, 32039, 32040, 32041, 32042, 32043, 32044, 32045, 32046, 32047, 32048, 32049, 32050, 32051, 32052, 32053, 32054, 32055, 32056, 32057, 32058, 32059, 32060, 32061, 32062, 32063, 32064, 32065, 32066, 32067, 32068, 32069, 32070, 32071, 32072, 32073, 32074, 32075, 32076, 32077, 32078, 32079, 32080, 32081, 32082, 32083, 32084, 32085, 32086, 32087, 32088, 32089, 32090, 32091, 32092, 32093, 32094, 32095, 32096, 32097, 32098, 32099, 32100, 32101, 32102, 32103, 32104, 32105, 32106, 32107, 32108, 32109, 32110, 32111, 32112, 32113, 32114, 32115, 32116, 32117, 32118, 32119, 32120, 32121, 32122, 32123, 32124, 32125, 32126, 32127" /> | |
| <input> | |
| <port id="0" precision="I32"> | |
| <dim>-1</dim> | |
| <dim>-1</dim> | |
| </port> | |
| <port id="1" precision="I32"> | |
| <dim>-1</dim> | |
| </port> | |
| <port id="2" precision="I32"> | |
| <dim>-1</dim> | |
| </port> | |
| <port id="3" precision="U8"> | |
| <dim>-1</dim> | |
| </port> | |
| </input> | |
| <output> | |
| <port id="4" precision="I32"> | |
| <dim>-1</dim> | |
| </port> | |
| <port id="5" precision="I32"> | |
| <dim>-1</dim> | |
| </port> | |
| <port id="6" precision="I32"> | |
| <dim>-1</dim> | |
| </port> | |
| <port id="7" precision="I32"> | |
| <dim>-1</dim> | |
| </port> | |
| <port id="8" precision="U8"> | |
| <dim>-1</dim> | |
| </port> | |
| </output> | |
| </layer> | |
| <layer id="5" name="Constant_632136" type="Const" version="opset1"> | |
| <data element_type="u8" shape="3" offset="335012" size="3" /> | |
| <output> | |
| <port id="0" precision="U8"> | |
| <dim>3</dim> | |
| </port> | |
| </output> | |
| </layer> | |
| <layer id="6" name="Constant_632138" type="Const" version="opset1"> | |
| <data element_type="u8" shape="1" offset="335015" size="1" /> | |
| <output> | |
| <port id="0" precision="U8"> | |
| <dim>1</dim> | |
| </port> | |
| </output> | |
| </layer> | |
| <layer id="7" name="RegexNormalization_632139" type="RegexNormalization" version="extension"> | |
| <data global_replace="true" /> | |
| <input> | |
| <port id="0" precision="I32"> | |
| <dim>-1</dim> | |
| </port> | |
| <port id="1" precision="I32"> | |
| <dim>-1</dim> | |
| </port> | |
| <port id="2" precision="U8"> | |
| <dim>-1</dim> | |
| </port> | |
| <port id="3" precision="U8"> | |
| <dim>3</dim> | |
| </port> | |
| <port id="4" precision="U8"> | |
| <dim>1</dim> | |
| </port> | |
| </input> | |
| <output> | |
| <port id="5" precision="I32"> | |
| <dim>-1</dim> | |
| </port> | |
| <port id="6" precision="I32"> | |
| <dim>-1</dim> | |
| </port> | |
| <port id="7" precision="U8"> | |
| <dim>-1</dim> | |
| </port> | |
| </output> | |
| </layer> | |
| <layer id="8" name="ByteFallback_632140" type="ByteFallback" version="extension"> | |
| <input> | |
| <port id="0" precision="I32"> | |
| <dim>-1</dim> | |
| </port> | |
| <port id="1" precision="I32"> | |
| <dim>-1</dim> | |
| </port> | |
| <port id="2" precision="U8"> | |
| <dim>-1</dim> | |
| </port> | |
| </input> | |
| <output> | |
| <port id="3" precision="I32"> | |
| <dim>-1</dim> | |
| </port> | |
| <port id="4" precision="I32"> | |
| <dim>-1</dim> | |
| </port> | |
| <port id="5" precision="U8"> | |
| <dim>-1</dim> | |
| </port> | |
| </output> | |
| </layer> | |
| <layer id="9" name="FuzeRagged_632141" type="FuzeRagged" version="extension"> | |
| <input> | |
| <port id="0" precision="I32"> | |
| <dim>-1</dim> | |
| </port> | |
| <port id="1" precision="I32"> | |
| <dim>-1</dim> | |
| </port> | |
| <port id="2" precision="I32"> | |
| <dim>-1</dim> | |
| </port> | |
| <port id="3" precision="I32"> | |
| <dim>-1</dim> | |
| </port> | |
| </input> | |
| <output> | |
| <port id="4" precision="I32"> | |
| <dim>-1</dim> | |
| </port> | |
| <port id="5" precision="I32"> | |
| <dim>-1</dim> | |
| </port> | |
| </output> | |
| </layer> | |
| <layer id="10" name="Constant_632143" type="Const" version="opset1"> | |
| <data element_type="u8" shape="2" offset="335016" size="2" /> | |
| <output> | |
| <port id="0" precision="U8"> | |
| <dim>2</dim> | |
| </port> | |
| </output> | |
| </layer> | |
| <layer id="11" name="Constant_632145" type="Const" version="opset1"> | |
| <data element_type="u8" shape="0" offset="335018" size="1" /> | |
| <output> | |
| <port id="0" precision="U8"> | |
| <dim>0</dim> | |
| </port> | |
| </output> | |
| </layer> | |
| <layer id="12" name="RegexNormalization_632146" type="RegexNormalization" version="extension"> | |
| <data global_replace="true" /> | |
| <input> | |
| <port id="0" precision="I32"> | |
| <dim>-1</dim> | |
| </port> | |
| <port id="1" precision="I32"> | |
| <dim>-1</dim> | |
| </port> | |
| <port id="2" precision="U8"> | |
| <dim>-1</dim> | |
| </port> | |
| <port id="3" precision="U8"> | |
| <dim>2</dim> | |
| </port> | |
| <port id="4" precision="U8"> | |
| <dim>0</dim> | |
| </port> | |
| </input> | |
| <output> | |
| <port id="5" precision="I32"> | |
| <dim>-1</dim> | |
| </port> | |
| <port id="6" precision="I32"> | |
| <dim>-1</dim> | |
| </port> | |
| <port id="7" precision="U8"> | |
| <dim>-1</dim> | |
| </port> | |
| </output> | |
| </layer> | |
| <layer id="13" name="Constant_632148" type="Const" version="opset1"> | |
| <data element_type="u8" shape="47" offset="335019" size="47" /> | |
| <output> | |
| <port id="0" precision="U8"> | |
| <dim>47</dim> | |
| </port> | |
| </output> | |
| </layer> | |
| <layer id="14" name="Constant_632150" type="Const" version="opset1"> | |
| <data element_type="u8" shape="2" offset="335066" size="2" /> | |
| <output> | |
| <port id="0" precision="U8"> | |
| <dim>2</dim> | |
| </port> | |
| </output> | |
| </layer> | |
| <layer id="15" name="RegexNormalization_632151" type="RegexNormalization" version="extension"> | |
| <data global_replace="true" /> | |
| <input> | |
| <port id="0" precision="I32"> | |
| <dim>-1</dim> | |
| </port> | |
| <port id="1" precision="I32"> | |
| <dim>-1</dim> | |
| </port> | |
| <port id="2" precision="U8"> | |
| <dim>-1</dim> | |
| </port> | |
| <port id="3" precision="U8"> | |
| <dim>47</dim> | |
| </port> | |
| <port id="4" precision="U8"> | |
| <dim>2</dim> | |
| </port> | |
| </input> | |
| <output> | |
| <port id="5" precision="I32"> | |
| <dim>-1</dim> | |
| </port> | |
| <port id="6" precision="I32"> | |
| <dim>-1</dim> | |
| </port> | |
| <port id="7" precision="U8"> | |
| <dim>-1</dim> | |
| </port> | |
| </output> | |
| </layer> | |
| <layer id="16" name="StringTensorPack_632152" type="StringTensorPack" version="extension"> | |
| <data mode="begins_ends" /> | |
| <input> | |
| <port id="0" precision="I32"> | |
| <dim>-1</dim> | |
| </port> | |
| <port id="1" precision="I32"> | |
| <dim>-1</dim> | |
| </port> | |
| <port id="2" precision="U8"> | |
| <dim>-1</dim> | |
| </port> | |
| </input> | |
| <output> | |
| <port id="3" precision="STRING" names="string_output"> | |
| <dim>-1</dim> | |
| </port> | |
| </output> | |
| </layer> | |
| <layer id="17" name="Result_632153" type="Result" version="opset1"> | |
| <input> | |
| <port id="0" precision="STRING"> | |
| <dim>-1</dim> | |
| </port> | |
| </input> | |
| </layer> | |
| </layers> | |
| <edges> | |
| <edge from-layer="0" from-port="0" to-layer="1" to-port="0" /> | |
| <edge from-layer="1" from-port="1" to-layer="4" to-port="0" /> | |
| <edge from-layer="2" from-port="0" to-layer="3" to-port="0" /> | |
| <edge from-layer="3" from-port="1" to-layer="4" to-port="1" /> | |
| <edge from-layer="3" from-port="2" to-layer="4" to-port="2" /> | |
| <edge from-layer="3" from-port="3" to-layer="4" to-port="3" /> | |
| <edge from-layer="4" from-port="6" to-layer="7" to-port="0" /> | |
| <edge from-layer="4" from-port="7" to-layer="7" to-port="1" /> | |
| <edge from-layer="4" from-port="8" to-layer="7" to-port="2" /> | |
| <edge from-layer="4" from-port="5" to-layer="9" to-port="1" /> | |
| <edge from-layer="4" from-port="4" to-layer="9" to-port="0" /> | |
| <edge from-layer="5" from-port="0" to-layer="7" to-port="3" /> | |
| <edge from-layer="6" from-port="0" to-layer="7" to-port="4" /> | |
| <edge from-layer="7" from-port="6" to-layer="8" to-port="1" /> | |
| <edge from-layer="7" from-port="7" to-layer="8" to-port="2" /> | |
| <edge from-layer="7" from-port="5" to-layer="8" to-port="0" /> | |
| <edge from-layer="8" from-port="3" to-layer="9" to-port="2" /> | |
| <edge from-layer="8" from-port="5" to-layer="12" to-port="2" /> | |
| <edge from-layer="8" from-port="4" to-layer="9" to-port="3" /> | |
| <edge from-layer="9" from-port="4" to-layer="12" to-port="0" /> | |
| <edge from-layer="9" from-port="5" to-layer="12" to-port="1" /> | |
| <edge from-layer="10" from-port="0" to-layer="12" to-port="3" /> | |
| <edge from-layer="11" from-port="0" to-layer="12" to-port="4" /> | |
| <edge from-layer="12" from-port="5" to-layer="15" to-port="0" /> | |
| <edge from-layer="12" from-port="6" to-layer="15" to-port="1" /> | |
| <edge from-layer="12" from-port="7" to-layer="15" to-port="2" /> | |
| <edge from-layer="13" from-port="0" to-layer="15" to-port="3" /> | |
| <edge from-layer="14" from-port="0" to-layer="15" to-port="4" /> | |
| <edge from-layer="15" from-port="5" to-layer="16" to-port="0" /> | |
| <edge from-layer="15" from-port="6" to-layer="16" to-port="1" /> | |
| <edge from-layer="15" from-port="7" to-layer="16" to-port="2" /> | |
| <edge from-layer="16" from-port="3" to-layer="17" to-port="0" /> | |
| </edges> | |
| <rt_info> | |
| <bos_token_id value="1" /> | |
| <chat_template value="{{bos_token}}{% for message in messages %}{{'<|im_start|>' + message['role'] + ' ' + message['content'] + '<|im_end|>' + ' '}}{% endfor %}{% if add_generation_prompt %}{{ '<|im_start|>assistant ' }}{% endif %}" /> | |
| <eos_token_id value="32001" /> | |
| <original_tokenizer_class value="<class 'transformers.models.llama.tokenization_llama_fast.LlamaTokenizerFast'>" /> | |
| <pad_token_id value="2" /> | |
| </rt_info> | |
| </net> | |