bigcode · text

starcoder2-15b

bigcode/starcoder2-15b

starcoder2-15b at Q4_K_M is exactly 9,860,188,000 bytes (9.18 GiB / 9.86 GB) — an effective 4.943 bits per weight, not the nominal 4.

From the file· summed from 1 file(s)From the file· KV per layer
Parameters
16.0B
Architecture
starcoder2
40 layers
Context
16,384
native (config.json)
License
bigcode-openrail-m

Shipped quantizations

exact bytes, summed from published files
QuantSizeExact bytesEffective bpwTensorsPublisher
IQ1_S3.31 GiB3,558,607,5521.784bartowski
IQ1_M3.60 GiB3,862,366,9121.936bartowski
IQ2_XXS4.07 GiB4,368,632,5122.190bartowski
IQ2_XS4.49 GiB4,820,830,9122.417lmstudio-community
IQ2_XS4.49 GiB4,820,830,9122.417bartowski
IQ2_S4.79 GiB5,140,515,5202.577bartowski
IQ2_M5.16 GiB5,545,528,0002.780bartowski
Q2_K5.77 GiB6,192,957,2803.105second-state
Q2_K5.77 GiB6,192,958,1443.105bartowski
Q2_K5.77 GiB6,192,958,1443.105lmstudio-community
IQ3_XXS5.79 GiB6,217,927,3603.117bartowski
IQ3_XS6.25 GiB6,714,165,9523.366bartowski
Q3_K_S6.51 GiB6,986,467,1683.502second-state
Q3_K_S6.51 GiB6,986,468,0323.502bartowski
IQ3_S6.52 GiB7,003,179,7123.511bartowski
IQ3_M6.80 GiB7,303,989,9523.662bartowski
Q3_K_M7.49 GiB8,044,415,6804.033bartowski
Q3_K_M7.54 GiB8,101,037,9204.061second-state
IQ4_XS8.01 GiB8,595,901,1204.309bartowski
IQ4_XS8.01 GiB8,595,901,1204.309lmstudio-community
Q3_K_L8.35 GiB8,965,326,6884.495second-state
Q3_K_L8.35 GiB8,965,327,5524.495bartowski
Q4_08.44 GiB9,065,400,1604.545second-state
IQ4_NL8.46 GiB9,081,129,6644.553bartowski
Q4_K_S8.53 GiB9,161,345,7284.593bartowski
Q4_K_S8.62 GiB9,255,716,7044.640second-state
Q4_K_M9.18 GiB9,860,188,0004.943second-state
Q4_K_M9.18 GiB9,860,188,8644.943bartowski
Q4_K_M9.18 GiB9,860,188,8644.943lmstudio-community
Q5_K_S10.27 GiB11,022,042,9765.526second-state
Q5_010.27 GiB11,022,042,9765.526second-state
Q5_K_S10.27 GiB11,022,043,8405.526bartowski
Q5_K_M10.65 GiB11,431,479,1365.731second-state
Q5_K_M10.65 GiB11,431,480,0005.731bartowski
Q5_K_M10.65 GiB11,431,480,0005.731lmstudio-community
Q6_K12.20 GiB13,100,975,9686.568second-state
Q6_K12.20 GiB13,100,976,8326.568lmstudio-community
Q6_K12.20 GiB13,100,976,8326.568bartowski
Q8_015.80 GiB16,965,109,6008.505second-state
Q8_015.80 GiB16,965,110,4648.505bartowski

KV cache by context

unresolved

This model declares a 4,096-token sliding window, but we could not establish which layers use it. Its architecture publishes the layout as a per-layer array inside the model file rather than as a period in config.json, and we have not yet ingested that array.

A flat context × layers × heads figure would be substantially too high, so we are not showing one. This is tracked as a known gap rather than filled with a guess.

Compare with

same modality, comparable size

Will it run on your card?

full quant x context sweep

Why other calculators give a different number

A parameters × bits ÷ 8 estimate puts Q4_K_M at roughly 8.36 GiB. The real file is 9.18 GiB, because a quantization is a mixture and some tensors are always kept at higher precision.

Architecture

from config.json
Layers
40
Attention heads
48
KV heads
4
Head dim
128
Hidden size
6144
Vocab
49,152
Sliding window
4096
SWA period
MLA
no
Experts
Experts per token
use_sliding_window

Questions people ask

How much VRAM does starcoder2-15b need?
Q4_K_M is exactly 9,860,188,000 bytes (9.18 GiB) in weights. Add the KV cache, which depends on your context length, plus roughly half a gigabyte of runtime overhead.
Which quantization of starcoder2-15b should I use?
Q4_K_M is the usual default. Pick the largest quantization that fits your card at the context you actually need — the table above gives exact sizes for every one published.