Text Generation
Transformers
Safetensors
qwen3_5
image-text-to-text
gptq
int4
vllm
agentic-coding
conversational
4-bit precision
Instructions to use malvavisc0/OxCoder-9B-gptq-int4 with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use malvavisc0/OxCoder-9B-gptq-int4 with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-generation", model="malvavisc0/OxCoder-9B-gptq-int4") messages = [ { "role": "user", "content": [ {"type": "image", "url": "https://huggingface.co/datasets/huggingface/documentation-images/resolve/main/p-blog/candy.JPG"}, {"type": "text", "text": "What animal is on the candy?"} ] }, ] pipe(text=messages)# Load model directly from transformers import AutoProcessor, AutoModelForMultimodalLM processor = AutoProcessor.from_pretrained("malvavisc0/OxCoder-9B-gptq-int4") model = AutoModelForMultimodalLM.from_pretrained("malvavisc0/OxCoder-9B-gptq-int4", device_map="auto") messages = [ { "role": "user", "content": [ {"type": "image", "url": "https://huggingface.co/datasets/huggingface/documentation-images/resolve/main/p-blog/candy.JPG"}, {"type": "text", "text": "What animal is on the candy?"} ] }, ] inputs = processor.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(processor.decode(outputs[0][inputs["input_ids"].shape[-1]:])) - Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- vLLM
How to use malvavisc0/OxCoder-9B-gptq-int4 with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "malvavisc0/OxCoder-9B-gptq-int4" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "malvavisc0/OxCoder-9B-gptq-int4", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }'Use Docker
docker model run hf.co/malvavisc0/OxCoder-9B-gptq-int4
- SGLang
How to use malvavisc0/OxCoder-9B-gptq-int4 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 "malvavisc0/OxCoder-9B-gptq-int4" \ --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": "malvavisc0/OxCoder-9B-gptq-int4", "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 "malvavisc0/OxCoder-9B-gptq-int4" \ --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": "malvavisc0/OxCoder-9B-gptq-int4", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }' - Docker Model Runner
How to use malvavisc0/OxCoder-9B-gptq-int4 with Docker Model Runner:
docker model run hf.co/malvavisc0/OxCoder-9B-gptq-int4
| layer,module,loss,samples,damp,time | |
| 0,linear_attn.in_proj_qkv,0.0000512330,0.05000,0.753 | |
| 0,linear_attn.in_proj_z,0.0000258486,0.05000,0.439 | |
| 0,linear_attn.out_proj,0.0000000288,0.05000,0.438 | |
| 0,mlp.gate_proj,0.0000006692,0.05000,1.283 | |
| 0,mlp.up_proj,0.0000005881,0.05000,1.321 | |
| 0,mlp.down_proj,0.0000000033,0.05000,2.023 | |
| 1,linear_attn.in_proj_qkv,0.0000058743,0.05000,0.505 | |
| 1,linear_attn.in_proj_z,0.0000030396,0.05000,0.441 | |
| 1,linear_attn.out_proj,0.0000000073,0.05000,0.443 | |
| 1,mlp.gate_proj,0.0000017216,0.05000,1.314 | |
| 1,mlp.up_proj,0.0000015407,0.05000,1.320 | |
| 1,mlp.down_proj,0.0000000096,0.05000,1.996 | |
| 2,linear_attn.in_proj_qkv,0.0000102022,0.05000,0.508 | |
| 2,linear_attn.in_proj_z,0.0000051198,0.05000,0.442 | |
| 2,linear_attn.out_proj,0.0000000120,0.05000,0.438 | |
| 2,mlp.up_proj,0.0000024092,0.05000,1.574 | |
| 2,mlp.gate_proj,0.0000028889,0.05000,1.579 | |
| 2,mlp.down_proj,0.0000000213,0.05000,1.979 | |
| 3,self_attn.q_proj,0.0000457913,0.05000,1.437 | |
| 3,self_attn.v_proj,0.0000040927,0.05000,1.443 | |
| 3,self_attn.k_proj,0.0000045126,0.05000,1.448 | |
| 3,self_attn.o_proj,0.0000000247,0.05000,0.442 | |
| 3,mlp.up_proj,0.0000033437,0.05000,1.295 | |
| 3,mlp.gate_proj,0.0000037084,0.05000,1.303 | |
| 3,mlp.down_proj,0.0000000310,0.05000,1.934 | |
| 4,linear_attn.in_proj_qkv,0.0000166285,0.05000,0.504 | |
| 4,linear_attn.in_proj_z,0.0000084468,0.05000,0.441 | |
| 4,linear_attn.out_proj,0.0000000281,0.05000,0.433 | |
| 4,mlp.up_proj,0.0000054035,0.05000,1.541 | |
| 4,mlp.gate_proj,0.0000060489,0.05000,1.560 | |
| 4,mlp.down_proj,0.0000000529,0.05000,1.950 | |
| 5,linear_attn.in_proj_qkv,0.0000234676,0.05000,0.497 | |
| 5,linear_attn.in_proj_z,0.0000116633,0.05000,0.438 | |
| 5,linear_attn.out_proj,0.0000000641,0.05000,0.438 | |
| 5,mlp.gate_proj,0.0000087650,0.05000,1.280 | |
| 5,mlp.up_proj,0.0000072798,0.05000,1.282 | |
| 5,mlp.down_proj,0.0000001020,0.05000,1.931 | |
| 6,linear_attn.in_proj_qkv,0.0000271829,0.05000,0.499 | |
| 6,linear_attn.in_proj_z,0.0000114913,0.05000,0.442 | |
| 6,linear_attn.out_proj,0.0000001114,0.05000,0.441 | |
| 6,mlp.gate_proj,0.0000125882,0.05000,1.596 | |
| 6,mlp.up_proj,0.0000099671,0.05000,1.624 | |
| 6,mlp.down_proj,0.0000001583,0.05000,1.969 | |
| 7,self_attn.q_proj,0.0000327816,0.05000,1.793 | |
| 7,self_attn.k_proj,0.0000040194,0.05000,1.808 | |
| 7,self_attn.v_proj,0.0000034953,0.05000,1.826 | |
| 7,self_attn.o_proj,0.0000001741,0.05000,0.441 | |
| 7,mlp.gate_proj,0.0000132600,0.05000,1.668 | |
| 7,mlp.up_proj,0.0000104244,0.05000,1.672 | |
| 7,mlp.down_proj,0.0000001733,0.05000,1.950 | |
| 8,linear_attn.in_proj_qkv,0.0000301906,0.05000,0.507 | |
| 8,linear_attn.in_proj_z,0.0000130997,0.05000,0.447 | |
| 8,linear_attn.out_proj,0.0000001314,0.05000,0.437 | |
| 8,mlp.up_proj,0.0000114845,0.05000,1.308 | |
| 8,mlp.gate_proj,0.0000140776,0.05000,1.313 | |
| 8,mlp.down_proj,0.0000001827,0.05000,1.964 | |
| 9,linear_attn.in_proj_qkv,0.0000328663,0.05000,0.503 | |
| 9,linear_attn.in_proj_z,0.0000136644,0.05000,0.436 | |
| 9,linear_attn.out_proj,0.0000001533,0.05000,0.435 | |
| 9,mlp.up_proj,0.0000123621,0.05000,1.654 | |
| 9,mlp.gate_proj,0.0000141435,0.05000,1.675 | |
| 9,mlp.down_proj,0.0000002136,0.05000,1.915 | |
| 10,linear_attn.in_proj_qkv,0.0000313985,0.05000,0.500 | |
| 10,linear_attn.in_proj_z,0.0000127113,0.05000,0.440 | |
| 10,linear_attn.out_proj,0.0000001706,0.05000,0.435 | |
| 10,mlp.gate_proj,0.0000139577,0.05000,1.244 | |
| 10,mlp.up_proj,0.0000133629,0.05000,1.249 | |
| 10,mlp.down_proj,0.0000002500,0.05000,1.933 | |
| 11,self_attn.q_proj,0.0000255943,0.05000,1.750 | |
| 11,self_attn.k_proj,0.0000034389,0.05000,1.761 | |
| 11,self_attn.v_proj,0.0000033088,0.05000,1.785 | |
| 11,self_attn.o_proj,0.0000003653,0.05000,0.439 | |
| 11,mlp.gate_proj,0.0000142216,0.05000,1.447 | |
| 11,mlp.up_proj,0.0000144107,0.05000,1.477 | |
| 11,mlp.down_proj,0.0000002969,0.05000,1.908 | |
| 12,linear_attn.in_proj_qkv,0.0000334196,0.05000,0.499 | |
| 12,linear_attn.in_proj_z,0.0000123923,0.05000,0.439 | |
| 12,linear_attn.out_proj,0.0000002414,0.05000,0.437 | |
| 12,mlp.gate_proj,0.0000144687,0.05000,1.479 | |
| 12,mlp.up_proj,0.0000152860,0.05000,1.505 | |
| 12,mlp.down_proj,0.0000003427,0.05000,1.941 | |
| 13,linear_attn.in_proj_qkv,0.0000387516,0.05000,0.497 | |
| 13,linear_attn.in_proj_z,0.0000150452,0.05000,0.446 | |
| 13,linear_attn.out_proj,0.0000002380,0.05000,0.434 | |
| 13,mlp.gate_proj,0.0000151776,0.05000,1.609 | |
| 13,mlp.up_proj,0.0000163668,0.05000,1.639 | |
| 13,mlp.down_proj,0.0000003871,0.05000,1.940 | |
| 14,linear_attn.in_proj_qkv,0.0000384952,0.05000,0.496 | |
| 14,linear_attn.in_proj_z,0.0000148005,0.05000,0.444 | |
| 14,linear_attn.out_proj,0.0000003604,0.05000,0.436 | |
| 14,mlp.gate_proj,0.0000154822,0.05000,1.289 | |
| 14,mlp.up_proj,0.0000175342,0.05000,1.295 | |
| 14,mlp.down_proj,0.0000004424,0.05000,1.960 | |
| 15,self_attn.k_proj,0.0000037890,0.05000,1.564 | |
| 15,self_attn.q_proj,0.0000281934,0.05000,1.579 | |
| 15,self_attn.v_proj,0.0000048000,0.05000,1.587 | |
| 15,self_attn.o_proj,0.0000006070,0.05000,0.435 | |
| 15,mlp.gate_proj,0.0000170689,0.05000,1.280 | |
| 15,mlp.up_proj,0.0000197788,0.05000,1.285 | |
| 15,mlp.down_proj,0.0000006178,0.05000,1.924 | |
| 16,linear_attn.in_proj_qkv,0.0000414585,0.05000,0.497 | |
| 16,linear_attn.in_proj_z,0.0000157437,0.05000,0.434 | |
| 16,linear_attn.out_proj,0.0000004966,0.05000,0.435 | |
| 16,mlp.gate_proj,0.0000189846,0.05000,1.235 | |
| 16,mlp.up_proj,0.0000219061,0.05000,1.240 | |
| 16,mlp.down_proj,0.0000008104,0.05000,1.911 | |
| 17,linear_attn.in_proj_qkv,0.0000563444,0.05000,0.498 | |
| 17,linear_attn.in_proj_z,0.0000180389,0.05000,0.437 | |
| 17,linear_attn.out_proj,0.0000006251,0.05000,0.434 | |
| 17,mlp.gate_proj,0.0000202587,0.05000,1.301 | |
| 17,mlp.up_proj,0.0000241804,0.05000,1.309 | |
| 17,mlp.down_proj,0.0000010840,0.05000,1.916 | |
| 18,linear_attn.in_proj_qkv,0.0000529036,0.05000,0.503 | |
| 18,linear_attn.in_proj_z,0.0000192245,0.05000,0.440 | |
| 18,linear_attn.out_proj,0.0000010398,0.05000,0.437 | |
| 18,mlp.up_proj,0.0000281983,0.05000,1.249 | |
| 18,mlp.gate_proj,0.0000245166,0.05000,1.264 | |
| 18,mlp.down_proj,0.0000020065,0.05000,1.944 | |
| 19,self_attn.k_proj,0.0000058760,0.05000,1.776 | |
| 19,self_attn.v_proj,0.0000109502,0.05000,1.784 | |
| 19,self_attn.q_proj,0.0000395083,0.05000,1.813 | |
| 19,self_attn.o_proj,0.0000026417,0.05000,0.442 | |
| 19,mlp.gate_proj,0.0000300821,0.05000,1.619 | |
| 19,mlp.up_proj,0.0000356534,0.05000,1.640 | |
| 19,mlp.down_proj,0.0000029585,0.05000,1.944 | |
| 20,linear_attn.in_proj_qkv,0.0000828392,0.05000,0.502 | |
| 20,linear_attn.in_proj_z,0.0000297302,0.05000,0.434 | |
| 20,linear_attn.out_proj,0.0000014146,0.05000,0.443 | |
| 20,mlp.gate_proj,0.0000373262,0.05000,1.534 | |
| 20,mlp.up_proj,0.0000371792,0.05000,1.553 | |
| 20,mlp.down_proj,0.0000031579,0.05000,1.929 | |
| 21,linear_attn.in_proj_qkv,0.0000811663,0.05000,0.509 | |
| 21,linear_attn.in_proj_z,0.0000304235,0.05000,0.448 | |
| 21,linear_attn.out_proj,0.0000018507,0.05000,0.433 | |
| 21,mlp.up_proj,0.0000391224,0.05000,1.600 | |
| 21,mlp.gate_proj,0.0000418820,0.05000,1.611 | |
| 21,mlp.down_proj,0.0000040956,0.05000,1.939 | |
| 22,linear_attn.in_proj_qkv,0.0000800213,0.05000,0.499 | |
| 22,linear_attn.in_proj_z,0.0000346308,0.05000,0.434 | |
| 22,linear_attn.out_proj,0.0000020605,0.05000,0.439 | |
| 22,mlp.up_proj,0.0000500837,0.05000,1.472 | |
| 22,mlp.gate_proj,0.0000592674,0.05000,1.478 | |
| 22,mlp.down_proj,0.0000062517,0.05000,1.917 | |
| 23,self_attn.k_proj,0.0000078460,0.05000,1.776 | |
| 23,self_attn.v_proj,0.0000156147,0.05000,1.789 | |
| 23,self_attn.q_proj,0.0000542049,0.05000,1.805 | |
| 23,self_attn.o_proj,0.0000037408,0.05000,0.437 | |
| 23,mlp.gate_proj,0.0000577355,0.05000,1.643 | |
| 23,mlp.up_proj,0.0000519635,0.05000,1.649 | |
| 23,mlp.down_proj,0.0000051992,0.05000,1.916 | |
| 24,linear_attn.in_proj_qkv,0.0000934729,0.05000,0.496 | |
| 24,linear_attn.in_proj_z,0.0000357742,0.05000,0.435 | |
| 24,linear_attn.out_proj,0.0000029748,0.05000,0.444 | |
| 24,mlp.gate_proj,0.0000614639,0.05000,1.246 | |
| 24,mlp.up_proj,0.0000522009,0.05000,1.247 | |
| 24,mlp.down_proj,0.0000049123,0.05000,1.916 | |
| 25,linear_attn.in_proj_qkv,0.0000965361,0.05000,0.508 | |
| 25,linear_attn.in_proj_z,0.0000383143,0.05000,0.433 | |
| 25,linear_attn.out_proj,0.0000024083,0.05000,0.435 | |
| 25,mlp.gate_proj,0.0000721219,0.05000,1.608 | |
| 25,mlp.up_proj,0.0000587548,0.05000,1.623 | |
| 25,mlp.down_proj,0.0000050382,0.05000,1.904 | |
| 26,linear_attn.in_proj_qkv,0.0000897841,0.05000,0.500 | |
| 26,linear_attn.in_proj_z,0.0000403678,0.05000,0.430 | |
| 26,linear_attn.out_proj,0.0000030055,0.05000,0.441 | |
| 26,mlp.gate_proj,0.0000864327,0.05000,1.388 | |
| 26,mlp.up_proj,0.0000691804,0.05000,1.407 | |
| 26,mlp.down_proj,0.0000069061,0.05000,1.903 | |
| 27,self_attn.k_proj,0.0000103169,0.05000,1.737 | |
| 27,self_attn.q_proj,0.0000655058,0.05000,1.744 | |
| 27,self_attn.v_proj,0.0000380844,0.05000,1.761 | |
| 27,self_attn.o_proj,0.0000103013,0.05000,0.432 | |
| 27,mlp.gate_proj,0.0000873213,0.05000,1.345 | |
| 27,mlp.up_proj,0.0000718302,0.05000,1.352 | |
| 27,mlp.down_proj,0.0000074708,0.05000,1.926 | |
| 28,linear_attn.in_proj_qkv,0.0001090263,0.05000,0.499 | |
| 28,linear_attn.in_proj_z,0.0000431458,0.05000,0.435 | |
| 28,linear_attn.out_proj,0.0000066057,0.05000,0.436 | |
| 28,mlp.up_proj,0.0000736457,0.05000,1.536 | |
| 28,mlp.gate_proj,0.0000876350,0.05000,1.543 | |
| 28,mlp.down_proj,0.0000099431,0.05000,1.923 | |
| 29,linear_attn.in_proj_qkv,0.0000821576,0.05000,0.498 | |
| 29,linear_attn.in_proj_z,0.0000386130,0.05000,0.439 | |
| 29,linear_attn.out_proj,0.0000073645,0.05000,0.438 | |
| 29,mlp.gate_proj,0.0000951019,0.05000,1.261 | |
| 29,mlp.up_proj,0.0000801801,0.05000,1.267 | |
| 29,mlp.down_proj,0.0000127125,0.05000,1.922 | |
| 30,linear_attn.in_proj_qkv,0.0000864302,0.05000,0.506 | |
| 30,linear_attn.in_proj_z,0.0000373503,0.05000,0.436 | |
| 30,linear_attn.out_proj,0.0000150087,0.05000,0.431 | |
| 30,mlp.gate_proj,0.0000910522,0.05000,1.601 | |
| 30,mlp.up_proj,0.0000784964,0.05000,1.615 | |
| 30,mlp.down_proj,0.0000179220,0.05000,1.920 | |
| 31,self_attn.v_proj,0.0000322213,0.05000,1.749 | |
| 31,self_attn.k_proj,0.0000086426,0.05000,1.755 | |
| 31,self_attn.q_proj,0.0000653408,0.05000,1.787 | |
| 31,self_attn.o_proj,0.0000210914,0.05000,0.436 | |
| 31,mlp.gate_proj,0.0000866345,0.05000,1.648 | |
| 31,mlp.up_proj,0.0000729714,0.05000,1.655 | |
| 31,mlp.down_proj,0.0000323485,0.05000,1.933 | |