Skip to content
Back to the collection

LLaMA: Open and Efficient Foundation Language Models

Hugo Touvron, Thibaut Lavril, Gautier Izacard

Show all 14 authors

Xavier Martinet, Marie-Anne Lachaux, Timothée Lacroix, Baptiste Rozière, Naman Goyal, Eric Hambro, Faisal Azhar, Aurelien Rodriguez, Armand Joulin, Edouard Grave, Guillaume Lample

2023 · arXiv

Read the paper
HN score
0
Mentions
30
Readers
27
Months
10
What’s in a score?

From the abstract

We introduce LLaMA, a collection of foundation language models ranging from 7B to 65B parameters. We train our models on trillions of tokens, and show that it is possible to train state-of-the-art models using publicly available datasets exclusively, without resorting to proprietary and inaccessible datasets. In particular, LLaMA-13B outperforms GPT-3 (175B) on most benchmarks, and LLaMA-65B is competitive with the best models, Chinchilla-70B and PaLM-540B. We release all our models to the research community.

Metadata: arXiv. Abstracts retain their original authors’ rights.

In the conversation

Original HN comments, with labels from simple text rules. A label describes the whole comment and may miss context or irony. Read the discussion to make up your own mind. About the labels

20 selected excerpts · 30 total mentions

JW_00000
Neutral mention · rule
I don't understand why it's even a question that Meta trained their LLM on copyrighted material. They say so in their paper! Quoting from their LLaMMa paper [Touvron et al., 2023]: > We include two book corpora in our training dataset: the Gutenberg Project, [...], and the Books3 section of ThePile (Gao et al., 2020), a publicly available dataset for training large language models. Following that reference: > Books3 is a dataset of books derived from a copy of the contents of the Bibliotik private tracker made available by Shawn Presser (Presser, 2020). (Presser, 2020) refers to https://twitter.com/theshawwn/status/1320282149329784833. (Which funnily refers to this DMCA…
Read the full comment
policy: https://the-eye.eu/dmca.mp4) Furthermore, they state they trained on GitHub, web pages, and ArXiv, which are all contain copyrighted content. Surely the question is: is it legal to train and/or use and/or distribute an AI model (or its weights, or its outputs) that is trained using copyrighted material. That it was trained on copyrighted material is certain. [Touvron et al., 2023] https://arxiv.org/pdf/2302.13971 [Gao et al., 2020] https://arxiv.org/pdf/2101.00027
michaelt
Neutral mention · rule
Then, you should check out papers like https://arxiv.org/abs/2302.13971 and https://arxiv.org/abs/2307.09288 In the paper covering the original Llama they explicitly list their data sources in table 1 - including saying that they pretrained on the somewhat controversial books3 dataset. The paper for Llama 2 also explicitly says they don't take data from Meta's products and services; and that they filter out data from sites known to contain a lot of PII. Although it is more coy about precisely what data sources they used, like many such papers are.
simonw
Neutral mention · rule
The most detailed answer to that I've seen is the original LLaMA paper, which described exactly what that model was trained on (including lots of scraped copyrighted data) https://arxiv.org/abs/2302.13971 Llama 2 was much more opaque about the training data, presumably because they were already being sued at that point (by Sarah Silverman!) over the training data that went into the first Llama! A couple of things I've written about this: - https://simonwillison.net/2023/Aug/27/wordcamp-llms/#how-the... - https://simonwillison.net/2023/Apr/17/redpajama-data/
versteegen
Neutral mention · rule
Because the training data/model size/compute tradeoff derived from that paper is highly suboptimal (too many parameters) compared to the ones from the later Deepmind scaling laws [1]. And then Meta researchers recommended using even smaller models, to trade-off training- and inference-time compute [2] (which I thought was pretty obvious if you care about more than just benchmarks). [1] https://arxiv.org/abs/2203.15556 Training Compute-Optimal Large Language Models [2] https://arxiv.org/abs/2302.13971 LLaMA: Open and Efficient Foundation Language Models
smoldesu
Neutral mention · rule
Facebook has been open-sourcing AI research longer than OpenAI has even had the concept of an "investor narrative". I struggle to understand how someone could jump to the conclusion of this being a "scorched earth" maneuver with so many other reasonable explanations. Facebook has a laboratory (FAIR) with a long history of research and releases like this. > If Llama cost hypothetical one billion, they inflict a multiple on that on their competitors with this move while gaining massive technological advantages. If Llama cost a hypothetical one billion, then they amortized the cost over the value of the end product and the free advertisement alone. Maybe their competitors…
Read the full comment
got scooped, but GPT-3 and GPT-4 haven't gone anywhere. Not to mention, there were lots of other language models from FAANG before Llama arrived. It's not like those were made and released to spite their competitors; it was research. Google and Microsoft have lots of open Transformer research you can find. Inflicting "damage" and gaining massive technological advantages is quite literally not their goal nor what they've done for the past half-decade. If it is, they've done a terrible job so far by collaborating with Microsoft to open their model format and provide inferencing acceleration for outdated hardware platforms. > The improvements made to llama by open source community people already have propelled it past Bard by many accounts and this is a model that a few months ago was absolutely non competitive and downright bad. This is something the original Llama paper acknowledged before the community "discovered" it: > In this section, we show that briefly finetuning on instructions data rapidly leads to improvements on MMLU. Although the non-finetuned version of LLaMA-65B is already able to follow basic instructions, we observe that a very small amount of finetuning improves the performance on MMLU, and further improves the ability of the model to follow instructions. https://arxiv.org/pdf/2302.13971.pdf > So it’s a win win. I don’t see the problem Neither does Meta, nor Microsoft, nor Google, who have all been content to work on progressive and open AI research. Who do you perceive as their "competitors"? Each other?
v64
Neutral mention · rule
The Llama 1 paper [1] was one of the earlier models to question the assumption that more params = better model. Since then they've released Llama 2 and this post is offering more evidence that reinforces their hypothesis. I wouldn't say it was an oversight by other labs that they missed this. It's easier to just increase params on a model over the same training set instead of gathering a larger training set necessary for a smaller model. And at first, increasing model size did seem to be the way forward, but we've since hit diminishing returns. Now that we've hit that point, we've begun exploring other options and the Llamas are early evidence of another way forward. [1] https://arxiv.org/abs/2302.13971
salawat
Neutral mention · rule
It's in the LLaMa.cpp original research paper. Tis mentioned in the brief. The research paper basically stated it was trained on Bibliotik, and other Internet "shadow library" corpuses. See the reference to the Gao et al, in the linked paper from the article. Paper linked in article: https://arxiv.org/pdf/2302.13971.pdf The LLaMA paper references a paper utilizing a data source compiled by EleutherAI otherwise known as ThePile. URL from the bibliography for that paper points yonder: https://zenodo.org/record/7413426 This act of summarization done in a lovingly amateur nature at no cost to you, by domeone who despises copyright in all it's forms, but despises profit…
Read the full comment
oriented self-referential inconsistency by large enterprises even more so. It's kind of funny, because the more I look into it, the more companies building offerings around stuff like CoPilot, LLaMA, ChatGPT, etc... are pulling something not altogether dissimilar to a Sovereign Citizen trying to worm their way out of a speeding ticket. They want the benefits of the ML model being trained on no strings attached data corpora, while shirking the obligations that come from operating as a corporate entity in the United States. Twould be interesting to see if Silverman's legal team can catch Big Tech with their pants down, in a court of law, by pointing this out. It's really weird. I'm completely split and inable to live with a decision either way in this case due to knock on consequences. I don't want the likes of OpenAI/Meta/Microsoft/Github getting off without reapong the painful fruits of their own IP related crusades on the sanctity of copyright. On the other hand, as much of a karmic stiffy as that former outcome gives me, I really want copyright such as it is to die, because computing in general will never be as free as it should be until it does. This is one of those rare times in life where I'd love to get paid to get locked in a room with judges/legislators to really get it all figured out, because I really don't think that leaving this up to common law jurisprudence is actually the best way to go since the network of knock-on effects are so dramatic in scale.
edent
Neutral mention · rule
Are we all reading the same complaint? They say: > in a Meta paper detailing LLaMA, the company points to sources for its training datasets, one of which is called ThePile, which was assembled by a company called EleutherAI. ThePile, the complaint points out, was described in an EleutherAI paper as being put together from “a copy of the contents of the Bibliotik private tracker.” Does that stack up? The Google Paper - https://arxiv.org/pdf/2302.13971.pdf - says: > We include two book corpora in our training dataset: the Gutenberg Project, which contains books that are in the public domain, and the Books3 section of ThePile (Gao et al., 2020) The Pile Paper -…
Read the full comment
https://arxiv.org/abs/2101.00027 - says it was trained (in part) on "Books3" which it describes as: > Books3 is a dataset of books derived from a copy of the contents of the Bibliotik private tracker made available by Shawn Presser (Presser, 2020). Shawn Presser's link is at https://twitter.com/theshawwn/status/1320282149329784833 and he describes Book3 as > Presenting "books3", aka "all of bibliotik" - 196,640 books - in plain .txt I don't have the time and space to download the 37GB file. But if Silverman's book is in there... isn't this a slam dunk case? Google's LLaMA is - as they seem to admit - trained on pirated books.
pythux
Neutral mention · rule
It is very expensive to train these base models so a smaller size is more practical if you aren’t a big company with hundreds of powerful GPUs at hand. Table 15 from LLaMA paper[1] has some insightful figures: it took 135,168 GPU hours to train the 13B version and a bit more than 1M GPU hours for the 65B version. And we are talking about A100 80GB GPUs here (expensive and scarce). Not everyone can afford these kinds of trainings (especially if it takes a few attempts; e.g. if you’ve got a bug in the tokenizer) [1] https://arxiv.org/pdf/2302.13971.pdf
londons_explore
Neutral mention · rule
I don't think Facebooks moves were heavily strategically thought out. Instead, I think a small team of a few researchers made LLaMA and published a paper about it[1], and then realised to get any citations for their paper they'd need to let other researchers have the weights. Citations are like money in the academic world. Every researcher wants citations. Executives and managers care less about that stuff. [1]: https://arxiv.org/abs/2302.13971
ppaattrriicckk
Neutral mention · rule
I love bashing Intel as much as the other person, but looking at the number of tokens LLaMA[1] was trained on (1,400B tokens), the number of parameters of GPT-3[2] vs. the number of tokens it was trained on (175B params vs. 300B), it's not like the announced 1,000B param model is unreasonable. Taking 175/300*1400 yields 816B parameters - which is fairly close to 1,000B. Not outright the most efficient utilization of data, but as others have mentioned, there might still be something left to gain (from not solely optimizing for compute). E.g. look at Figure 9 in [3]. Although the model trained on the largest model obviously utilized the data most efficiently, it's not…
Read the full comment
perfectly clear - to me at least - whether some over-parameterization will necessarily lead to a decrease of test/out-of-sample performance. Of course, LLaMA was trained on way fewer parameters relative to data set size. I've just mentioned LLaMA as a point of reference to the largest dataset known to me. [1] - https://arxiv.org/pdf/2302.13971.pdf [2] - https://arxiv.org/pdf/2005.14165.pdf [3] - https://arxiv.org/pdf/2001.08361.pdf EDIT: Formatting of references
capableweb
Neutral mention · rule
First link: https://github.com/ggerganov/llama.cpp Which in turn has the following as the first link: https://arxiv.org/abs/2302.13971 Is it really quicker to ask here than just browse content for a bit, skimming some text or even using Google for one minute?
YetAnotherNick
Neutral mention · rule
They are likely doing some interpolation for 200B or benchmarking it in wrong way. e.g. Hellaswag accuracy for llama 7b is 0.76[1], but it is written 0.56 in the repo. Even at 200B tokens, it is higher than 0.56 for llama looking at the charts. [1]: https://arxiv.org/pdf/2302.13971.pdf
nl
Neutral mention · rule
LLama 65B used 2048 80G A100s for 21 days: > When training a 65B-parameter model, our code processes around 380 tokens/sec/GPU on 2048 A100 GPU with 80GB of RAM.[1] Note that you probably need to budget for double to triple that because things go wrong and it usually takes multiple starts to get a good training run. Smaller models are cheaper though. [1] https://arxiv.org/pdf/2302.13971.pdf
frozencell
Neutral mention · rule
> ChatGPT competitors of EU origin? ChatGPT is not research. If you want real research: https://ai.facebook.com/blog/large-language-model-llama-meta... Edit: end paper is https://arxiv.org/abs/2302.13971 > Hugo Touvron, Thibaut Lavril, Gautier Izacard, Xavier Martinet, Marie-Anne Lachaux, Timothée Lacroix, Baptiste Rozière, Naman Goyal, Eric Hambro, Faisal Azhar, Aurelien Rodriguez, Armand Joulin, Edouard Grave, Guillaume Lample > We introduce LLaMA, a collection of foundation language models ranging from 7B to 65B parameters. We train our models on trillions of tokens, and show that it is possible to train state-of-the-art models using publicly available datasets exclusively, without resorting to proprietary and inaccessible datasets. In particular, LLaMA-13B outperforms GPT-3 (175B) on most benchmarks, and LLaMA-65B is competitive with the best models, Chinchilla-70B and PaLM-540B. We release all our models to the research community.
lhl
Neutral mention · rule
It's worth pointing out that size isn't everything. From Meta's benchmarking [1] LLaMA 33B outperforms GPT-3 175B, Gopher 280B, Chinchilla 70B and even matches PaLM 540B on a bunch of common evals. Those interested in doing more comparisons can look at https://crfm.stanford.edu/helm/latest/?group=core_scenarios and https://paperswithcode.com/paper/llama-open-and-efficient-fo... to see where it sits (with some GPT 3.5 and 4 numbers here: https://paperswithcode.com/paper/gpt-4-technical-report-1) I'd agree the secret sauce for how great the newest services perform is probably in the fine-tuning. We're seeing almost daily releases of fine-tuning data sets, training methods and models (at lower and lower costs) so I'm personally pretty optimistic that we'll be seeing some big improvement in self-hosted LLM performance pretty quickly. [1] https://ar5iv.labs.arxiv.org/html/2302.13971#:~:text=Table%2....
yreg
Neutral mention · rule
Incredibly difficult to measure it, but it seems llama is closest to GPT-3[0]. Which is pretty cool all things considered. Certainly better than most of us would have expected a short while ago, right? [0] https://arxiv.org/pdf/2302.13971.pdf

Keep following the thread.

More in Language models

More from the same topics.