tokyotech-llm · text

Swallow-7b-NVE-instruct-hf

tokyotech-llm/Swallow-7b-NVE-instruct-hf

Swallow-7b-NVE-instruct-hf at Q4_K_M is exactly 4,081,004,896 bytes (3.80 GiB / 4.08 GB) — an effective 4.845 bits per weight, not the nominal 4. Its KV cache at 32K is 16.00 GiB.

From the file· summed from 1 file(s)From the file· KV per layer
Parameters
6.7B
Architecture
llama
32 layers
Context
4,096
native (config.json)
License
llama2

Shipped quantizations

exact bytes, summed from published files
QuantSizeExact bytesEffective bpwTensorsPublisher
I1-IQ1_S1.42 GiB1,528,582,7521.815mradermacher
I1-IQ1_M1.54 GiB1,650,971,2321.960mradermacher
I1-IQ2_XXS1.73 GiB1,854,952,0322.202mradermacher
I1-IQ2_XS1.90 GiB2,034,913,8882.416mradermacher
I1-IQ2_S2.05 GiB2,196,566,6242.608mradermacher
I1-IQ2_M2.20 GiB2,359,751,2642.802mradermacher
Q2_K2.36 GiB2,532,864,3523.007mradermacher
I1-Q2_K2.36 GiB2,532,864,6083.007mradermacher
I1-IQ3_XXS2.41 GiB2,585,391,7123.069mradermacher
IQ3_XS2.60 GiB2,796,523,8723.320mradermacher
I1-IQ3_XS2.60 GiB2,796,524,1283.320mradermacher
Q3_K_S2.75 GiB2,948,305,2483.500mradermacher
IQ3_S2.75 GiB2,948,305,2483.500mradermacher
I1-IQ3_S2.75 GiB2,948,305,5043.500mradermacher
I1-Q3_K_S2.75 GiB2,948,305,5043.500mradermacher
IQ3_M2.90 GiB3,114,864,9923.698mradermacher
I1-IQ3_M2.90 GiB3,114,865,2483.698mradermacher
Q3_K_M3.07 GiB3,298,005,3443.916mradermacher
I1-Q3_K_M3.07 GiB3,298,005,6003.916mradermacher
Q3_K_L3.35 GiB3,597,111,6484.271mradermacher
I1-Q3_K_L3.35 GiB3,597,111,9044.271mradermacher
I1-IQ4_XS3.37 GiB3,619,336,8004.297mradermacher
IQ4_XS3.40 GiB3,647,517,0244.330mradermacher
I1-Q4_03.57 GiB3,837,080,1604.556mradermacher
Q4_K_S3.59 GiB3,856,740,7044.579mradermacher
I1-Q4_K_S3.59 GiB3,856,740,9604.579mradermacher
Q4_K_M3.80 GiB4,081,004,8964.845mradermacher
I1-Q4_K_M3.80 GiB4,081,005,1524.845mradermacher
Q5_K_S4.33 GiB4,651,692,3845.523mradermacher
I1-Q5_K_S4.33 GiB4,651,692,6405.523mradermacher
Q5_K_M4.45 GiB4,783,157,6005.679mradermacher
I1-Q5_K_M4.45 GiB4,783,157,8565.679mradermacher
Q6_K5.15 GiB5,529,194,8486.564mradermacher
I1-Q6_K5.15 GiB5,529,195,1046.564mradermacher
Q8_06.67 GiB7,161,090,4008.502mradermacher
F1612.55 GiB13,478,105,44016.002mradermacher

KV cache by context

computed per layer
ContextKV cache (f16)Flat formulaOverstated byFull / windowed / recurrent
4,0962.00 GiB2.00 GiB32 / 0 / 0
8,1924.00 GiB4.00 GiB32 / 0 / 0
16,3848.00 GiB8.00 GiB32 / 0 / 0
32,76816.00 GiB16.00 GiB32 / 0 / 0
65,53632.00 GiB32.00 GiB32 / 0 / 0
131,07264.00 GiB64.00 GiB32 / 0 / 0

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 3.53 GiB. The real file is 3.80 GiB, because a quantization is a mixture and some tensors are always kept at higher precision.

Architecture

from config.json
Layers
32
Attention heads
32
KV heads
32
Head dim
128
Hidden size
4096
Vocab
32,000
Sliding window
none
SWA period
MLA
no
Experts
Experts per token
use_sliding_window

Questions people ask

How much VRAM does Swallow-7b-NVE-instruct-hf need?
Q4_K_M is exactly 4,081,004,896 bytes (3.80 GiB) in weights. Add the KV cache, which depends on your context length, plus roughly half a gigabyte of runtime overhead.
How large is Swallow-7b-NVE-instruct-hf's KV cache?
16.00 GiB at 32K context with an f16 cache, computed per layer. Quantizing the cache to q8_0 roughly halves it, which is often the difference between a context length fitting and not.
Which quantization of Swallow-7b-NVE-instruct-hf 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.