Live data from Hacker News

How Is LLaMa.cpp Possible?

finbarr.ca

151–160 of 238 posts

Re: How Is LLaMa.cpp Possible?

#151

This leaves a ton of stuff out. - Token generation is serial and bandwidth bound, but prompt ingestion is not and runs in batches of 512+. Short tests are fast on pure CPU llama.cpp, but long prompting (such as with ongoing conversation) is extremely slow compared to other backends. - Llama.cpp now has very good ~4 bit quantization that doesn't affect perplexity much. Q6_K almost has the same perplexity as FP16, but…

[deleted]

Re: How Is LLaMa.cpp Possible?

#152
post #8

In case anyone is wondering, yes, there is a cost when a model is quantized. https://oobabooga.github.io/blog/posts/perplexities/ Essentially, you lose some accuracy and there might be some weird answers and probably more likely to go off the rail and hallucinate. But the quality loss is lower the more parameters you have. So for very large model sizes the differences might be negligible. Also, this is the cost of in…

This is not generally true, sometimes quantisation can improve accuracy. I haven't seen that with LLMs yet though.

Re: How Is LLaMa.cpp Possible?

#153
post #8

In case anyone is wondering, yes, there is a cost when a model is quantized. https://oobabooga.github.io/blog/posts/perplexities/ Essentially, you lose some accuracy and there might be some weird answers and probably more likely to go off the rail and hallucinate. But the quality loss is lower the more parameters you have. So for very large model sizes the differences might be negligible. Also, this is the cost of in…

This is not generally true, sometimes quantisation can improve accuracy. I haven't seen that with LLMs yet though.

Interesting, how would that work? Are there any well-known examples?

Is it: the weights all happen to be where float is sparse, so quantization ends up increasing fidelity? Or is it more of a “worse is better” dropout-type situation?

Re: How Is LLaMa.cpp Possible?

#154
This article would probably be useful for a lot more people if it spent just a couple of sentences introducing the various parameters, rather than just throwing variable names at the reader. Interestingly, a whole paragraph is spent on explaining n_bytes.

Re: How Is LLaMa.cpp Possible?

#155

This leaves a ton of stuff out. - Token generation is serial and bandwidth bound, but prompt ingestion is not and runs in batches of 512+. Short tests are fast on pure CPU llama.cpp, but long prompting (such as with ongoing conversation) is extremely slow compared to other backends. - Llama.cpp now has very good ~4 bit quantization that doesn't affect perplexity much. Q6_K almost has the same perplexity as FP16, but…

What’s perplexity?

Re: How Is LLaMa.cpp Possible?

#156

Memory bound token generation is a limitation of transformer decoders. In the past, hardware has motivation algorithm innovations. I’m curious how long it will take until we see more hardware friendly models.

The Rwkv family of models qualifies, since it computes like a recurrent network at inference time.

Re: How Is LLaMa.cpp Possible?

#157
post #42

Earlier quoted context omitted.

AGI should have morals, opinions, self-reflection, learn continuously from sensor data, reason, realize when they’re proven wrong and update their model of the world, and be creative. So far LLMs exhibit none of those. But LLMs exhibit a digestible distillation of a very large body of data which may be a component of an AGI. But you can have an AGI that doesn’t have encyclopedic knowledge but it’s still highly intell…

That is not what AGI means. AGI = Artificial General Intelligence. 1. Artificial = we made it 2. General = it can solve problems in any field 3. Intelligence = the ability to solve problems A chess engine is a very strong Artificial Intelligence . But it’s not very General , it can only evaluate chess positions. GPT-4 is very General , you can ask it about any question and get a somewhat reasonable answer. But it’s n…

> That’s a different problem.

That's news to me. AGI (or strong AI) is typically defined as "human-level intelligence", or "perform any task that a human or animal can." Humans and animals often perform tasks that are critically reliant on being conscious, emoting, reading body language, reasoning, etc.

Not only that but prominent thinkers who have carved out the notion of AGI (or Strong AI) tend to have consciousness, mental states, and emotions at the core of it.

I think what you're talking about is a multi-task AI, not an AGI.

Re: How Is LLaMa.cpp Possible?

#158

This leaves a ton of stuff out. - Token generation is serial and bandwidth bound, but prompt ingestion is not and runs in batches of 512+. Short tests are fast on pure CPU llama.cpp, but long prompting (such as with ongoing conversation) is extremely slow compared to other backends. - Llama.cpp now has very good ~4 bit quantization that doesn't affect perplexity much. Q6_K almost has the same perplexity as FP16, but…

What's prompt ingestion?

Re: How Is LLaMa.cpp Possible?

#159
post #153

Earlier quoted context omitted.

This is not generally true, sometimes quantisation can improve accuracy. I haven't seen that with LLMs yet though.

Interesting, how would that work? Are there any well-known examples? Is it: the weights all happen to be where float is sparse, so quantization ends up increasing fidelity? Or is it more of a “worse is better” dropout-type situation?

For image recognition it can sometimes be like that. My gut feeling is that lowering from fp32 to fp16 can get rid of some kind of overfitting or so.

Re: How Is LLaMa.cpp Possible?

#160
post #153

Earlier quoted context omitted.

This is not generally true, sometimes quantisation can improve accuracy. I haven't seen that with LLMs yet though.

Interesting, how would that work? Are there any well-known examples? Is it: the weights all happen to be where float is sparse, so quantization ends up increasing fidelity? Or is it more of a “worse is better” dropout-type situation?

I suspect it works as regularisation of the network. It usually happens when you train with quantisation instead of post-training quantisation, an I haven't seen that done with LLMs yet.
Post reply on HN