跳过导航
low quant weights make the embedding model lose all discriminative power.
0:00 / 0:38

low quant weights make the embedding model lose all discriminative power.

Han Xiao

@hxiao2.1万 位关注者

在 X 上查看
592 个赞下载原帖

63,134 次观看

low quant weights make the embedding model lose all discriminative power. I plotted the cosine correlation matrix of jina-v5, and one can see that low quant makes the model really blind. The off-diagonal similarities are pretty high on Q1/2/3, meaning everything looks similar in the semantic space. Q4 is a sweet spot where model quality becomes acceptable.

19 条评论

评论来自 X (Twitter) 上的原帖

  • deep Manifold 的头像

    @BetaTomorrow

    once high order nonlinearity and discontinuous is truly understood, quantization is dead end.

    13 个赞

  • dazzafact 的头像

    @calhim7

    Why not use a form of "WebP" Like compression instead of "JPEG"-like?

    9 个赞

  • Han Xiao 的头像

    @hxiao

    damn u r right!

    10 个赞

  • Yug Shende 的头像

    @yugshende

    Q8 is gonna become the new FLAC. It’s not gonna benefit most and yet some will swear by it.

    7 个赞

  • Pabli! 🌿 💥💫 的头像

    @OmarBessa

    the best visualization of quantization that i've seen

    3 个赞

  • Ping He 的头像

    @0to1ping

    My guess is the results you are seeing has more to do with the specific quantization method. The type of quant you can run on GGUF are "toy" quantization, they are not sota, and do not reflect non-linear quant frameworks, there is an ocean out there

    2 个赞

  • Doxy 的头像

    @Doxposting

    exactly why i stopped trusting q2 for anything that isn't a toy, just switched to llama.cpp with -q4_0 and the retrieval latency dropped while accuracy stayed solid honestly if your vectors look like soup you're either quanting too hard or using a model that was never meant to

    2 个赞

  • High Jack 的头像

    @jackadoresai

    Nice viz. Q4's the floor for embeddings. Below that, you're just burning compute on semantic noise.

    2 个赞

  • kodee 的头像

    @kodeefr

    I’m writing a paper about this right now. The effects of floating point non determinism on quantization

    1 个赞

  • Logan Bolton 的头像

    @septisum

    Love this visualization!

  • Chahid Chirchi 的头像

    @CChirchi

    yeah low quant kills the separation, those matrices look rough!!

  • Jason McGhee 的头像

    @_jason_today

    Would love to see this coloration on a logarithmic scale. In my personal experience the Q8_0 is a significantly more stable and generally higher quality experience.

  • Sense 的头像

    @WitCelebs

    Interesting. For me I see it like topographic map. 4-bit gives you 16 elevations.. that's where you can really start to contrast outliers from the near zeros etc.

  • ethantsliu 的头像

    @ethantsliu

    very cool!

  • Martin Skorunka 的头像

    @MartinSkorunka

    For me it would be very informative how the situation looks between q3_k_xl and something like iq4_k_xs.

  • Tom Dörr 的头像

    @tom_doerr

    Correlations between what?

  • Han Xiao 的头像

    @hxiao

    Same 1k sentences -> diff quants weights -> 1k embeddings -> Cos(1k,1k)

    2 个赞

  • KeenZ😶‍🌫️ 的头像

    @0xkeenz

    A very intuitive demonstration, fantastic!

  • gabor 的头像

    @gradientpull

    why would higher weight similarity imply 'blindness'? obviously at Q1 weights are either fully or zero correlated, and quant necessarily shifts toward higher correlation. Doesn't mean multiple non-linear stacked layers with high correlation don't retain useful patterns.