atahanuz commited on
Commit
f0df1e5
·
verified ·
1 Parent(s): eb936d4

Update README.md

Browse files
Files changed (1) hide show
  1. README.md +1193 -130
README.md CHANGED
@@ -1,199 +1,1262 @@
1
  ---
2
- library_name: transformers
3
- tags: []
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
4
  ---
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
5
 
6
- # Model Card for Model ID
7
 
8
- <!-- Provide a quick summary of what the model is/does. -->
9
 
 
10
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
11
 
12
- ## Model Details
 
 
13
 
14
- ### Model Description
 
15
 
16
- <!-- Provide a longer summary of what this model is. -->
17
 
18
- This is the model card of a 🤗 transformers model that has been pushed on the Hub. This model card has been automatically generated.
19
 
20
- - **Developed by:** [More Information Needed]
21
- - **Funded by [optional]:** [More Information Needed]
22
- - **Shared by [optional]:** [More Information Needed]
23
- - **Model type:** [More Information Needed]
24
- - **Language(s) (NLP):** [More Information Needed]
25
- - **License:** [More Information Needed]
26
- - **Finetuned from model [optional]:** [More Information Needed]
27
 
28
- ### Model Sources [optional]
29
 
30
- <!-- Provide the basic links for the model. -->
 
 
31
 
32
- - **Repository:** [More Information Needed]
33
- - **Paper [optional]:** [More Information Needed]
34
- - **Demo [optional]:** [More Information Needed]
35
 
36
- ## Uses
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
37
 
38
- <!-- Address questions around how the model is intended to be used, including the foreseeable users of the model and those affected by the model. -->
39
 
40
- ### Direct Use
41
 
42
- <!-- This section is for the model use without fine-tuning or plugging into a larger ecosystem/app. -->
43
 
44
- [More Information Needed]
45
 
46
- ### Downstream Use [optional]
47
 
48
- <!-- This section is for the model use when fine-tuned for a task, or when plugged into a larger ecosystem/app -->
49
 
50
- [More Information Needed]
 
 
51
 
52
- ### Out-of-Scope Use
53
 
54
- <!-- This section addresses misuse, malicious use, and uses that the model will not work well for. -->
55
 
56
- [More Information Needed]
57
 
58
- ## Bias, Risks, and Limitations
59
 
60
- <!-- This section is meant to convey both technical and sociotechnical limitations. -->
61
 
62
- [More Information Needed]
63
 
64
- ### Recommendations
65
 
66
- <!-- This section is meant to convey recommendations with respect to the bias, risk, and technical limitations. -->
67
 
68
- Users (both direct and downstream) should be made aware of the risks, biases and limitations of the model. More information needed for further recommendations.
69
 
70
- ## How to Get Started with the Model
71
 
72
- Use the code below to get started with the model.
73
 
74
- [More Information Needed]
75
 
76
- ## Training Details
77
 
78
- ### Training Data
79
 
80
- <!-- This should link to a Dataset Card, perhaps with a short stub of information on what the training data is all about as well as documentation related to data pre-processing or additional filtering. -->
81
 
82
- [More Information Needed]
83
 
84
- ### Training Procedure
85
 
86
- <!-- This relates heavily to the Technical Specifications. Content here should link to that section when it is relevant to the training procedure. -->
87
 
88
- #### Preprocessing [optional]
89
 
90
- [More Information Needed]
91
 
 
92
 
93
- #### Training Hyperparameters
94
 
95
- - **Training regime:** [More Information Needed] <!--fp32, fp16 mixed precision, bf16 mixed precision, bf16 non-mixed precision, fp16 non-mixed precision, fp8 mixed precision -->
96
 
97
- #### Speeds, Sizes, Times [optional]
98
 
99
- <!-- This section provides information about throughput, start/end time, checkpoint size if relevant, etc. -->
100
 
101
- [More Information Needed]
102
 
103
- ## Evaluation
104
 
105
- <!-- This section describes the evaluation protocols and provides the results. -->
106
 
107
- ### Testing Data, Factors & Metrics
108
 
109
- #### Testing Data
110
 
111
- <!-- This should link to a Dataset Card if possible. -->
112
 
113
- [More Information Needed]
114
 
115
- #### Factors
116
 
117
- <!-- These are the things the evaluation is disaggregating by, e.g., subpopulations or domains. -->
118
 
119
- [More Information Needed]
120
 
121
- #### Metrics
122
 
123
- <!-- These are the evaluation metrics being used, ideally with a description of why. -->
124
 
125
- [More Information Needed]
126
 
127
- ### Results
128
 
129
- [More Information Needed]
130
 
131
- #### Summary
132
 
 
133
 
 
134
 
135
- ## Model Examination [optional]
136
 
137
- <!-- Relevant interpretability work for the model goes here -->
138
 
139
- [More Information Needed]
140
 
141
- ## Environmental Impact
142
-
143
- <!-- Total emissions (in grams of CO2eq) and additional considerations, such as electricity usage, go here. Edit the suggested text below accordingly -->
144
-
145
- Carbon emissions can be estimated using the [Machine Learning Impact calculator](https://mlco2.github.io/impact#compute) presented in [Lacoste et al. (2019)](https://arxiv.org/abs/1910.09700).
146
-
147
- - **Hardware Type:** [More Information Needed]
148
- - **Hours used:** [More Information Needed]
149
- - **Cloud Provider:** [More Information Needed]
150
- - **Compute Region:** [More Information Needed]
151
- - **Carbon Emitted:** [More Information Needed]
152
-
153
- ## Technical Specifications [optional]
154
-
155
- ### Model Architecture and Objective
156
-
157
- [More Information Needed]
158
-
159
- ### Compute Infrastructure
160
-
161
- [More Information Needed]
162
-
163
- #### Hardware
164
-
165
- [More Information Needed]
166
-
167
- #### Software
168
-
169
- [More Information Needed]
170
-
171
- ## Citation [optional]
172
-
173
- <!-- If there is a paper or blog post introducing the model, the APA and Bibtex information for that should go in this section. -->
174
-
175
- **BibTeX:**
176
-
177
- [More Information Needed]
178
-
179
- **APA:**
180
-
181
- [More Information Needed]
182
-
183
- ## Glossary [optional]
184
-
185
- <!-- If relevant, include terms and calculations in this section that can help readers understand the model or model card. -->
186
-
187
- [More Information Needed]
188
-
189
- ## More Information [optional]
190
-
191
- [More Information Needed]
192
-
193
- ## Model Card Authors [optional]
194
-
195
- [More Information Needed]
196
-
197
- ## Model Card Contact
198
-
199
- [More Information Needed]
 
1
  ---
2
+ language:
3
+ - en
4
+ - de
5
+ - fr
6
+ - it
7
+ - pt
8
+ - hi
9
+ - es
10
+ - th
11
+ license: llama3.1
12
+ base_model: meta-llama/Meta-Llama-3.1-8B
13
+ pipeline_tag: text-generation
14
+ tags:
15
+ - facebook
16
+ - meta
17
+ - pytorch
18
+ - llama
19
+ - llama-3
20
+ extra_gated_prompt: "### LLAMA 3.1 COMMUNITY LICENSE AGREEMENT\nLlama 3.1 Version\
21
+ \ Release Date: July 23, 2024\n\"Agreement\" means the terms and conditions for\
22
+ \ use, reproduction, distribution and modification of the Llama Materials set forth\
23
+ \ herein.\n\"Documentation\" means the specifications, manuals and documentation\
24
+ \ accompanying Llama 3.1 distributed by Meta at https://llama.meta.com/doc/overview.\n\
25
+ \"Licensee\" or \"you\" means you, or your employer or any other person or entity\
26
+ \ (if you are entering into this Agreement on such person or entity’s behalf), of\
27
+ \ the age required under applicable laws, rules or regulations to provide legal\
28
+ \ consent and that has legal authority to bind your employer or such other person\
29
+ \ or entity if you are entering in this Agreement on their behalf.\n\"Llama 3.1\"\
30
+ \ means the foundational large language models and software and algorithms, including\
31
+ \ machine-learning model code, trained model weights, inference-enabling code, training-enabling\
32
+ \ code, fine-tuning enabling code and other elements of the foregoing distributed\
33
+ \ by Meta at https://llama.meta.com/llama-downloads.\n\"Llama Materials\" means,\
34
+ \ collectively, Meta’s proprietary Llama 3.1 and Documentation (and any portion\
35
+ \ thereof) made available under this Agreement.\n\"Meta\" or \"we\" means Meta Platforms\
36
+ \ Ireland Limited (if you are located in or, if you are an entity, your principal\
37
+ \ place of business is in the EEA or Switzerland) and Meta Platforms, Inc. (if you\
38
+ \ are located outside of the EEA or Switzerland).\n \n1. License Rights and Redistribution.\n\
39
+ a. Grant of Rights. You are granted a non-exclusive, worldwide, non-transferable\
40
+ \ and royalty-free limited license under Meta’s intellectual property or other rights\
41
+ \ owned by Meta embodied in the Llama Materials to use, reproduce, distribute, copy,\
42
+ \ create derivative works of, and make modifications to the Llama Materials.\nb.\
43
+ \ Redistribution and Use.\ni. If you distribute or make available the Llama Materials\
44
+ \ (or any derivative works thereof), or a product or service (including another\
45
+ \ AI model) that contains any of them, you shall (A) provide a copy of this Agreement\
46
+ \ with any such Llama Materials; and (B) prominently display “Built with Llama”\
47
+ \ on a related website, user interface, blogpost, about page, or product documentation.\
48
+ \ If you use the Llama Materials or any outputs or results of the Llama Materials\
49
+ \ to create, train, fine tune, or otherwise improve an AI model, which is distributed\
50
+ \ or made available, you shall also include “Llama” at the beginning of any such\
51
+ \ AI model name.\nii. If you receive Llama Materials, or any derivative works thereof,\
52
+ \ from a Licensee as part of an integrated end user product, then Section 2 of\
53
+ \ this Agreement will not apply to you.\niii. You must retain in all copies of the\
54
+ \ Llama Materials that you distribute the following attribution notice within a\
55
+ \ “Notice” text file distributed as a part of such copies: “Llama 3.1 is licensed\
56
+ \ under the Llama 3.1 Community License, Copyright © Meta Platforms, Inc. All Rights\
57
+ \ Reserved.”\niv. Your use of the Llama Materials must comply with applicable laws\
58
+ \ and regulations (including trade compliance laws and regulations) and adhere to\
59
+ \ the Acceptable Use Policy for the Llama Materials (available at https://llama.meta.com/llama3_1/use-policy),\
60
+ \ which is hereby incorporated by reference into this Agreement.\n2. Additional\
61
+ \ Commercial Terms. If, on the Llama 3.1 version release date, the monthly active\
62
+ \ users of the products or services made available by or for Licensee, or Licensee’s\
63
+ \ affiliates, is greater than 700 million monthly active users in the preceding\
64
+ \ calendar month, you must request a license from Meta, which Meta may grant to\
65
+ \ you in its sole discretion, and you are not authorized to exercise any of the\
66
+ \ rights under this Agreement unless or until Meta otherwise expressly grants you\
67
+ \ such rights.\n3. Disclaimer of Warranty. UNLESS REQUIRED BY APPLICABLE LAW, THE\
68
+ \ LLAMA MATERIALS AND ANY OUTPUT AND RESULTS THEREFROM ARE PROVIDED ON AN “AS IS”\
69
+ \ BASIS, WITHOUT WARRANTIES OF ANY KIND, AND META DISCLAIMS ALL WARRANTIES OF ANY\
70
+ \ KIND, BOTH EXPRESS AND IMPLIED, INCLUDING, WITHOUT LIMITATION, ANY WARRANTIES\
71
+ \ OF TITLE, NON-INFRINGEMENT, MERCHANTABILITY, OR FITNESS FOR A PARTICULAR PURPOSE.\
72
+ \ YOU ARE SOLELY RESPONSIBLE FOR DETERMINING THE APPROPRIATENESS OF USING OR REDISTRIBUTING\
73
+ \ THE LLAMA MATERIALS AND ASSUME ANY RISKS ASSOCIATED WITH YOUR USE OF THE LLAMA\
74
+ \ MATERIALS AND ANY OUTPUT AND RESULTS.\n4. Limitation of Liability. IN NO EVENT\
75
+ \ WILL META OR ITS AFFILIATES BE LIABLE UNDER ANY THEORY OF LIABILITY, WHETHER IN\
76
+ \ CONTRACT, TORT, NEGLIGENCE, PRODUCTS LIABILITY, OR OTHERWISE, ARISING OUT OF THIS\
77
+ \ AGREEMENT, FOR ANY LOST PROFITS OR ANY INDIRECT, SPECIAL, CONSEQUENTIAL, INCIDENTAL,\
78
+ \ EXEMPLARY OR PUNITIVE DAMAGES, EVEN IF META OR ITS AFFILIATES HAVE BEEN ADVISED\
79
+ \ OF THE POSSIBILITY OF ANY OF THE FOREGOING.\n5. Intellectual Property.\na. No\
80
+ \ trademark licenses are granted under this Agreement, and in connection with the\
81
+ \ Llama Materials, neither Meta nor Licensee may use any name or mark owned by or\
82
+ \ associated with the other or any of its affiliates, except as required for reasonable\
83
+ \ and customary use in describing and redistributing the Llama Materials or as set\
84
+ \ forth in this Section 5(a). Meta hereby grants you a license to use “Llama” (the\
85
+ \ “Mark”) solely as required to comply with the last sentence of Section 1.b.i.\
86
+ \ You will comply with Meta’s brand guidelines (currently accessible at https://about.meta.com/brand/resources/meta/company-brand/\
87
+ \ ). All goodwill arising out of your use of the Mark will inure to the benefit\
88
+ \ of Meta.\nb. Subject to Meta’s ownership of Llama Materials and derivatives made\
89
+ \ by or for Meta, with respect to any derivative works and modifications of the\
90
+ \ Llama Materials that are made by you, as between you and Meta, you are and will\
91
+ \ be the owner of such derivative works and modifications.\nc. If you institute\
92
+ \ litigation or other proceedings against Meta or any entity (including a cross-claim\
93
+ \ or counterclaim in a lawsuit) alleging that the Llama Materials or Llama 3.1 outputs\
94
+ \ or results, or any portion of any of the foregoing, constitutes infringement of\
95
+ \ intellectual property or other rights owned or licensable by you, then any licenses\
96
+ \ granted to you under this Agreement shall terminate as of the date such litigation\
97
+ \ or claim is filed or instituted. You will indemnify and hold harmless Meta from\
98
+ \ and against any claim by any third party arising out of or related to your use\
99
+ \ or distribution of the Llama Materials.\n6. Term and Termination. The term of\
100
+ \ this Agreement will commence upon your acceptance of this Agreement or access\
101
+ \ to the Llama Materials and will continue in full force and effect until terminated\
102
+ \ in accordance with the terms and conditions herein. Meta may terminate this Agreement\
103
+ \ if you are in breach of any term or condition of this Agreement. Upon termination\
104
+ \ of this Agreement, you shall delete and cease use of the Llama Materials. Sections\
105
+ \ 3, 4 and 7 shall survive the termination of this Agreement.\n7. Governing Law\
106
+ \ and Jurisdiction. This Agreement will be governed and construed under the laws\
107
+ \ of the State of California without regard to choice of law principles, and the\
108
+ \ UN Convention on Contracts for the International Sale of Goods does not apply\
109
+ \ to this Agreement. The courts of California shall have exclusive jurisdiction\
110
+ \ of any dispute arising out of this Agreement.\n### Llama 3.1 Acceptable Use Policy\n\
111
+ Meta is committed to promoting safe and fair use of its tools and features, including\
112
+ \ Llama 3.1. If you access or use Llama 3.1, you agree to this Acceptable Use Policy\
113
+ \ (“Policy”). The most recent copy of this policy can be found at [https://llama.meta.com/llama3_1/use-policy](https://llama.meta.com/llama3_1/use-policy)\n\
114
+ #### Prohibited Uses\nWe want everyone to use Llama 3.1 safely and responsibly.\
115
+ \ You agree you will not use, or allow others to use, Llama 3.1 to:\n 1. Violate\
116
+ \ the law or others’ rights, including to:\n 1. Engage in, promote, generate,\
117
+ \ contribute to, encourage, plan, incite, or further illegal or unlawful activity\
118
+ \ or content, such as:\n 1. Violence or terrorism\n 2. Exploitation\
119
+ \ or harm to children, including the solicitation, creation, acquisition, or dissemination\
120
+ \ of child exploitative content or failure to report Child Sexual Abuse Material\n\
121
+ \ 3. Human trafficking, exploitation, and sexual violence\n 4. The\
122
+ \ illegal distribution of information or materials to minors, including obscene\
123
+ \ materials, or failure to employ legally required age-gating in connection with\
124
+ \ such information or materials.\n 5. Sexual solicitation\n 6. Any\
125
+ \ other criminal activity\n 3. Engage in, promote, incite, or facilitate the\
126
+ \ harassment, abuse, threatening, or bullying of individuals or groups of individuals\n\
127
+ \ 4. Engage in, promote, incite, or facilitate discrimination or other unlawful\
128
+ \ or harmful conduct in the provision of employment, employment benefits, credit,\
129
+ \ housing, other economic benefits, or other essential goods and services\n 5.\
130
+ \ Engage in the unauthorized or unlicensed practice of any profession including,\
131
+ \ but not limited to, financial, legal, medical/health, or related professional\
132
+ \ practices\n 6. Collect, process, disclose, generate, or infer health, demographic,\
133
+ \ or other sensitive personal or private information about individuals without rights\
134
+ \ and consents required by applicable laws\n 7. Engage in or facilitate any action\
135
+ \ or generate any content that infringes, misappropriates, or otherwise violates\
136
+ \ any third-party rights, including the outputs or results of any products or services\
137
+ \ using the Llama Materials\n 8. Create, generate, or facilitate the creation\
138
+ \ of malicious code, malware, computer viruses or do anything else that could disable,\
139
+ \ overburden, interfere with or impair the proper working, integrity, operation\
140
+ \ or appearance of a website or computer system\n2. Engage in, promote, incite,\
141
+ \ facilitate, or assist in the planning or development of activities that present\
142
+ \ a risk of death or bodily harm to individuals, including use of Llama 3.1 related\
143
+ \ to the following:\n 1. Military, warfare, nuclear industries or applications,\
144
+ \ espionage, use for materials or activities that are subject to the International\
145
+ \ Traffic Arms Regulations (ITAR) maintained by the United States Department of\
146
+ \ State\n 2. Guns and illegal weapons (including weapon development)\n 3.\
147
+ \ Illegal drugs and regulated/controlled substances\n 4. Operation of critical\
148
+ \ infrastructure, transportation technologies, or heavy machinery\n 5. Self-harm\
149
+ \ or harm to others, including suicide, cutting, and eating disorders\n 6. Any\
150
+ \ content intended to incite or promote violence, abuse, or any infliction of bodily\
151
+ \ harm to an individual\n3. Intentionally deceive or mislead others, including use\
152
+ \ of Llama 3.1 related to the following:\n 1. Generating, promoting, or furthering\
153
+ \ fraud or the creation or promotion of disinformation\n 2. Generating, promoting,\
154
+ \ or furthering defamatory content, including the creation of defamatory statements,\
155
+ \ images, or other content\n 3. Generating, promoting, or further distributing\
156
+ \ spam\n 4. Impersonating another individual without consent, authorization,\
157
+ \ or legal right\n 5. Representing that the use of Llama 3.1 or outputs are human-generated\n\
158
+ \ 6. Generating or facilitating false online engagement, including fake reviews\
159
+ \ and other means of fake online engagement\n4. Fail to appropriately disclose to\
160
+ \ end users any known dangers of your AI system\nPlease report any violation of\
161
+ \ this Policy, software “bug,” or other problems that could lead to a violation\
162
+ \ of this Policy through one of the following means:\n * Reporting issues with\
163
+ \ the model: [https://github.com/meta-llama/llama-models/issues](https://github.com/meta-llama/llama-models/issues)\n\
164
+ \ * Reporting risky content generated by the model:\n developers.facebook.com/llama_output_feedback\n\
165
+ \ * Reporting bugs and security concerns: facebook.com/whitehat/info\n * Reporting\
166
+ \ violations of the Acceptable Use Policy or unlicensed uses of Meta Llama 3: LlamaUseReport@meta.com"
167
+ extra_gated_fields:
168
+ First Name: text
169
+ Last Name: text
170
+ Date of birth: date_picker
171
+ Country: country
172
+ Affiliation: text
173
+ Job title:
174
+ type: select
175
+ options:
176
+ - Student
177
+ - Research Graduate
178
+ - AI researcher
179
+ - AI developer/engineer
180
+ - Reporter
181
+ - Other
182
+ geo: ip_location
183
+ ? By clicking Submit below I accept the terms of the license and acknowledge that
184
+ the information I provide will be collected stored processed and shared in accordance
185
+ with the Meta Privacy Policy
186
+ : checkbox
187
+ extra_gated_description: The information you provide will be collected, stored, processed
188
+ and shared in accordance with the [Meta Privacy Policy](https://www.facebook.com/privacy/policy/).
189
+ extra_gated_button_content: Submit
190
  ---
191
+ This model is a variation of the meta-llama/Llama-3.1-8B-Instruct where all weights are set to random values (mean=0, std=1)
192
+ It produces random(?) outputs to prompts. While it doesn't serve a practical purpose, it can be useful for educational purposes
193
+
194
+ ## Model Information
195
+
196
+ The Meta Llama 3.1 collection of multilingual large language models (LLMs) is a collection of pretrained and instruction tuned generative models in 8B, 70B and 405B sizes (text in/text out). The Llama 3.1 instruction tuned text only models (8B, 70B, 405B) are optimized for multilingual dialogue use cases and outperform many of the available open source and closed chat models on common industry benchmarks.
197
+
198
+ **Model developer**: Meta
199
+
200
+ **Model Architecture:** Llama 3.1 is an auto-regressive language model that uses an optimized transformer architecture. The tuned versions use supervised fine-tuning (SFT) and reinforcement learning with human feedback (RLHF) to align with human preferences for helpfulness and safety.
201
+
202
+
203
+ <table>
204
+ <tr>
205
+ <td>
206
+ </td>
207
+ <td><strong>Training Data</strong>
208
+ </td>
209
+ <td><strong>Params</strong>
210
+ </td>
211
+ <td><strong>Input modalities</strong>
212
+ </td>
213
+ <td><strong>Output modalities</strong>
214
+ </td>
215
+ <td><strong>Context length</strong>
216
+ </td>
217
+ <td><strong>GQA</strong>
218
+ </td>
219
+ <td><strong>Token count</strong>
220
+ </td>
221
+ <td><strong>Knowledge cutoff</strong>
222
+ </td>
223
+ </tr>
224
+ <tr>
225
+ <td rowspan="3" >Llama 3.1 (text only)
226
+ </td>
227
+ <td rowspan="3" >A new mix of publicly available online data.
228
+ </td>
229
+ <td>8B
230
+ </td>
231
+ <td>Multilingual Text
232
+ </td>
233
+ <td>Multilingual Text and code
234
+ </td>
235
+ <td>128k
236
+ </td>
237
+ <td>Yes
238
+ </td>
239
+ <td rowspan="3" >15T+
240
+ </td>
241
+ <td rowspan="3" >December 2023
242
+ </td>
243
+ </tr>
244
+ <tr>
245
+ <td>70B
246
+ </td>
247
+ <td>Multilingual Text
248
+ </td>
249
+ <td>Multilingual Text and code
250
+ </td>
251
+ <td>128k
252
+ </td>
253
+ <td>Yes
254
+ </td>
255
+ </tr>
256
+ <tr>
257
+ <td>405B
258
+ </td>
259
+ <td>Multilingual Text
260
+ </td>
261
+ <td>Multilingual Text and code
262
+ </td>
263
+ <td>128k
264
+ </td>
265
+ <td>Yes
266
+ </td>
267
+ </tr>
268
+ </table>
269
+
270
+
271
+ **Supported languages:** English, German, French, Italian, Portuguese, Hindi, Spanish, and Thai.
272
+
273
+ **Llama 3.1 family of models**. Token counts refer to pretraining data only. All model versions use Grouped-Query Attention (GQA) for improved inference scalability.
274
+
275
+ **Model Release Date:** July 23, 2024.
276
+
277
+ **Status:** This is a static model trained on an offline dataset. Future versions of the tuned models will be released as we improve model safety with community feedback.
278
+
279
+ **License:** A custom commercial license, the Llama 3.1 Community License, is available at: [https://github.com/meta-llama/llama-models/blob/main/models/llama3_1/LICENSE](https://github.com/meta-llama/llama-models/blob/main/models/llama3_1/LICENSE)
280
+
281
+ Where to send questions or comments about the model Instructions on how to provide feedback or comments on the model can be found in the model [README](https://github.com/meta-llama/llama3). For more technical information about generation parameters and recipes for how to use Llama 3.1 in applications, please go [here](https://github.com/meta-llama/llama-recipes).
282
+
283
+
284
+ ## Intended Use
285
+
286
+ **Intended Use Cases** Llama 3.1 is intended for commercial and research use in multiple languages. Instruction tuned text only models are intended for assistant-like chat, whereas pretrained models can be adapted for a variety of natural language generation tasks. The Llama 3.1 model collection also supports the ability to leverage the outputs of its models to improve other models including synthetic data generation and distillation. The Llama 3.1 Community License allows for these use cases.
287
+
288
+ **Out-of-scope** Use in any manner that violates applicable laws or regulations (including trade compliance laws). Use in any other way that is prohibited by the Acceptable Use Policy and Llama 3.1 Community License. Use in languages beyond those explicitly referenced as supported in this model card**.
289
+
290
+ **<span style="text-decoration:underline;">Note</span>: Llama 3.1 has been trained on a broader collection of languages than the 8 supported languages. Developers may fine-tune Llama 3.1 models for languages beyond the 8 supported languages provided they comply with the Llama 3.1 Community License and the Acceptable Use Policy and in such cases are responsible for ensuring that any uses of Llama 3.1 in additional languages is done in a safe and responsible manner.
291
 
292
+ ## How to use
293
 
294
+ This repository contains two versions of Meta-Llama-3.1-8B-Instruct, for use with transformers and with the original `llama` codebase.
295
 
296
+ ### Use with transformers
297
 
298
+ Starting with `transformers >= 4.43.0` onward, you can run conversational inference using the Transformers `pipeline` abstraction or by leveraging the Auto classes with the `generate()` function.
299
+
300
+ Make sure to update your transformers installation via `pip install --upgrade transformers`.
301
+
302
+ ```python
303
+ import transformers
304
+ import torch
305
+
306
+ model_id = "meta-llama/Meta-Llama-3.1-8B-Instruct"
307
+
308
+ pipeline = transformers.pipeline(
309
+ "text-generation",
310
+ model=model_id,
311
+ model_kwargs={"torch_dtype": torch.bfloat16},
312
+ device_map="auto",
313
+ )
314
+
315
+ messages = [
316
+ {"role": "system", "content": "You are a pirate chatbot who always responds in pirate speak!"},
317
+ {"role": "user", "content": "Who are you?"},
318
+ ]
319
+
320
+ outputs = pipeline(
321
+ messages,
322
+ max_new_tokens=256,
323
+ )
324
+ print(outputs[0]["generated_text"][-1])
325
+ ```
326
+
327
+ Note: You can also find detailed recipes on how to use the model locally, with `torch.compile()`, assisted generations, quantised and more at [`huggingface-llama-recipes`](https://github.com/huggingface/huggingface-llama-recipes)
328
+
329
+ ### Tool use with transformers
330
+
331
+ LLaMA-3.1 supports multiple tool use formats. You can see a full guide to prompt formatting [here](https://llama.meta.com/docs/model-cards-and-prompt-formats/llama3_1/).
332
+
333
+ Tool use is also supported through [chat templates](https://huggingface.co/docs/transformers/main/chat_templating#advanced-tool-use--function-calling) in Transformers.
334
+ Here is a quick example showing a single simple tool:
335
+
336
+ ```python
337
+ # First, define a tool
338
+ def get_current_temperature(location: str) -> float:
339
+ """
340
+ Get the current temperature at a location.
341
+
342
+ Args:
343
+ location: The location to get the temperature for, in the format "City, Country"
344
+ Returns:
345
+ The current temperature at the specified location in the specified units, as a float.
346
+ """
347
+ return 22. # A real function should probably actually get the temperature!
348
+
349
+ # Next, create a chat and apply the chat template
350
+ messages = [
351
+ {"role": "system", "content": "You are a bot that responds to weather queries."},
352
+ {"role": "user", "content": "Hey, what's the temperature in Paris right now?"}
353
+ ]
354
+
355
+ inputs = tokenizer.apply_chat_template(messages, tools=[get_current_temperature], add_generation_prompt=True)
356
+ ```
357
+
358
+ You can then generate text from this input as normal. If the model generates a tool call, you should add it to the chat like so:
359
+
360
+ ```python
361
+ tool_call = {"name": "get_current_temperature", "arguments": {"location": "Paris, France"}}
362
+ messages.append({"role": "assistant", "tool_calls": [{"type": "function", "function": tool_call}]})
363
+ ```
364
+
365
+ and then call the tool and append the result, with the `tool` role, like so:
366
 
367
+ ```python
368
+ messages.append({"role": "tool", "name": "get_current_temperature", "content": "22.0"})
369
+ ```
370
 
371
+ After that, you can `generate()` again to let the model use the tool result in the chat. Note that this was a very brief introduction to tool calling - for more information,
372
+ see the [LLaMA prompt format docs](https://llama.meta.com/docs/model-cards-and-prompt-formats/llama3_1/) and the Transformers [tool use documentation](https://huggingface.co/docs/transformers/main/chat_templating#advanced-tool-use--function-calling).
373
 
 
374
 
375
+ ### Use with `llama`
376
 
377
+ Please, follow the instructions in the [repository](https://github.com/meta-llama/llama)
 
 
 
 
 
 
378
 
379
+ To download Original checkpoints, see the example command below leveraging `huggingface-cli`:
380
 
381
+ ```
382
+ huggingface-cli download meta-llama/Meta-Llama-3.1-8B-Instruct --include "original/*" --local-dir Meta-Llama-3.1-8B-Instruct
383
+ ```
384
 
385
+ ## Hardware and Software
 
 
386
 
387
+ **Training Factors** We used custom training libraries, Meta's custom built GPU cluster, and production infrastructure for pretraining. Fine-tuning, annotation, and evaluation were also performed on production infrastructure.
388
+
389
+ **Training utilized a cumulative of** 39.3M GPU hours of computation on H100-80GB (TDP of 700W) type hardware, per the table below. Training time is the total GPU time required for training each model and power consumption is the peak power capacity per GPU device used, adjusted for power usage efficiency.
390
+
391
+
392
+ **Training Greenhouse Gas Emissions** Estimated total location-based greenhouse gas emissions were **11,390** tons CO2eq for training. Since 2020, Meta has maintained net zero greenhouse gas emissions in its global operations and matched 100% of its electricity use with renewable energy, therefore the total market-based greenhouse gas emissions for training were 0 tons CO2eq.
393
+
394
+
395
+ <table>
396
+ <tr>
397
+ <td>
398
+ </td>
399
+ <td><strong>Training Time (GPU hours)</strong>
400
+ </td>
401
+ <td><strong>Training Power Consumption (W)</strong>
402
+ </td>
403
+ <td><strong>Training Location-Based Greenhouse Gas Emissions</strong>
404
+ <p>
405
+ <strong>(tons CO2eq)</strong>
406
+ </td>
407
+ <td><strong>Training Market-Based Greenhouse Gas Emissions</strong>
408
+ <p>
409
+ <strong>(tons CO2eq)</strong>
410
+ </td>
411
+ </tr>
412
+ <tr>
413
+ <td>Llama 3.1 8B
414
+ </td>
415
+ <td>1.46M
416
+ </td>
417
+ <td>700
418
+ </td>
419
+ <td>420
420
+ </td>
421
+ <td>0
422
+ </td>
423
+ </tr>
424
+ <tr>
425
+ <td>Llama 3.1 70B
426
+ </td>
427
+ <td>7.0M
428
+ </td>
429
+ <td>700
430
+ </td>
431
+ <td>2,040
432
+ </td>
433
+ <td>0
434
+ </td>
435
+ </tr>
436
+ <tr>
437
+ <td>Llama 3.1 405B
438
+ </td>
439
+ <td>30.84M
440
+ </td>
441
+ <td>700
442
+ </td>
443
+ <td>8,930
444
+ </td>
445
+ <td>0
446
+ </td>
447
+ </tr>
448
+ <tr>
449
+ <td>Total
450
+ </td>
451
+ <td>39.3M
452
+ <td>
453
+ <ul>
454
+
455
+ </ul>
456
+ </td>
457
+ <td>11,390
458
+ </td>
459
+ <td>0
460
+ </td>
461
+ </tr>
462
+ </table>
463
+
464
+
465
+
466
+ The methodology used to determine training energy use and greenhouse gas emissions can be found [here](https://arxiv.org/pdf/2204.05149). Since Meta is openly releasing these models, the training energy use and greenhouse gas emissions will not be incurred by others.
467
+
468
+
469
+ ## Training Data
470
+
471
+ **Overview:** Llama 3.1 was pretrained on ~15 trillion tokens of data from publicly available sources. The fine-tuning data includes publicly available instruction datasets, as well as over 25M synthetically generated examples.
472
+
473
+ **Data Freshness:** The pretraining data has a cutoff of December 2023.
474
+
475
+
476
+ ## Benchmark scores
477
+
478
+ In this section, we report the results for Llama 3.1 models on standard automatic benchmarks. For all the evaluations, we use our internal evaluations library.
479
+
480
+ ### Base pretrained models
481
+
482
+
483
+ <table>
484
+ <tr>
485
+ <td><strong>Category</strong>
486
+ </td>
487
+ <td><strong>Benchmark</strong>
488
+ </td>
489
+ <td><strong># Shots</strong>
490
+ </td>
491
+ <td><strong>Metric</strong>
492
+ </td>
493
+ <td><strong>Llama 3 8B</strong>
494
+ </td>
495
+ <td><strong>Llama 3.1 8B</strong>
496
+ </td>
497
+ <td><strong>Llama 3 70B</strong>
498
+ </td>
499
+ <td><strong>Llama 3.1 70B</strong>
500
+ </td>
501
+ <td><strong>Llama 3.1 405B</strong>
502
+ </td>
503
+ </tr>
504
+ <tr>
505
+ <td rowspan="7" >General
506
+ </td>
507
+ <td>MMLU
508
+ </td>
509
+ <td>5
510
+ </td>
511
+ <td>macro_avg/acc_char
512
+ </td>
513
+ <td>66.7
514
+ </td>
515
+ <td>66.7
516
+ </td>
517
+ <td>79.5
518
+ </td>
519
+ <td>79.3
520
+ </td>
521
+ <td>85.2
522
+ </td>
523
+ </tr>
524
+ <tr>
525
+ <td>MMLU-Pro (CoT)
526
+ </td>
527
+ <td>5
528
+ </td>
529
+ <td>macro_avg/acc_char
530
+ </td>
531
+ <td>36.2
532
+ </td>
533
+ <td>37.1
534
+ </td>
535
+ <td>55.0
536
+ </td>
537
+ <td>53.8
538
+ </td>
539
+ <td>61.6
540
+ </td>
541
+ </tr>
542
+ <tr>
543
+ <td>AGIEval English
544
+ </td>
545
+ <td>3-5
546
+ </td>
547
+ <td>average/acc_char
548
+ </td>
549
+ <td>47.1
550
+ </td>
551
+ <td>47.8
552
+ </td>
553
+ <td>63.0
554
+ </td>
555
+ <td>64.6
556
+ </td>
557
+ <td>71.6
558
+ </td>
559
+ </tr>
560
+ <tr>
561
+ <td>CommonSenseQA
562
+ </td>
563
+ <td>7
564
+ </td>
565
+ <td>acc_char
566
+ </td>
567
+ <td>72.6
568
+ </td>
569
+ <td>75.0
570
+ </td>
571
+ <td>83.8
572
+ </td>
573
+ <td>84.1
574
+ </td>
575
+ <td>85.8
576
+ </td>
577
+ </tr>
578
+ <tr>
579
+ <td>Winogrande
580
+ </td>
581
+ <td>5
582
+ </td>
583
+ <td>acc_char
584
+ </td>
585
+ <td>-
586
+ </td>
587
+ <td>60.5
588
+ </td>
589
+ <td>-
590
+ </td>
591
+ <td>83.3
592
+ </td>
593
+ <td>86.7
594
+ </td>
595
+ </tr>
596
+ <tr>
597
+ <td>BIG-Bench Hard (CoT)
598
+ </td>
599
+ <td>3
600
+ </td>
601
+ <td>average/em
602
+ </td>
603
+ <td>61.1
604
+ </td>
605
+ <td>64.2
606
+ </td>
607
+ <td>81.3
608
+ </td>
609
+ <td>81.6
610
+ </td>
611
+ <td>85.9
612
+ </td>
613
+ </tr>
614
+ <tr>
615
+ <td>ARC-Challenge
616
+ </td>
617
+ <td>25
618
+ </td>
619
+ <td>acc_char
620
+ </td>
621
+ <td>79.4
622
+ </td>
623
+ <td>79.7
624
+ </td>
625
+ <td>93.1
626
+ </td>
627
+ <td>92.9
628
+ </td>
629
+ <td>96.1
630
+ </td>
631
+ </tr>
632
+ <tr>
633
+ <td>Knowledge reasoning
634
+ </td>
635
+ <td>TriviaQA-Wiki
636
+ </td>
637
+ <td>5
638
+ </td>
639
+ <td>em
640
+ </td>
641
+ <td>78.5
642
+ </td>
643
+ <td>77.6
644
+ </td>
645
+ <td>89.7
646
+ </td>
647
+ <td>89.8
648
+ </td>
649
+ <td>91.8
650
+ </td>
651
+ </tr>
652
+ <tr>
653
+ <td rowspan="4" >Reading comprehension
654
+ </td>
655
+ <td>SQuAD
656
+ </td>
657
+ <td>1
658
+ </td>
659
+ <td>em
660
+ </td>
661
+ <td>76.4
662
+ </td>
663
+ <td>77.0
664
+ </td>
665
+ <td>85.6
666
+ </td>
667
+ <td>81.8
668
+ </td>
669
+ <td>89.3
670
+ </td>
671
+ </tr>
672
+ <tr>
673
+ <td>QuAC (F1)
674
+ </td>
675
+ <td>1
676
+ </td>
677
+ <td>f1
678
+ </td>
679
+ <td>44.4
680
+ </td>
681
+ <td>44.9
682
+ </td>
683
+ <td>51.1
684
+ </td>
685
+ <td>51.1
686
+ </td>
687
+ <td>53.6
688
+ </td>
689
+ </tr>
690
+ <tr>
691
+ <td>BoolQ
692
+ </td>
693
+ <td>0
694
+ </td>
695
+ <td>acc_char
696
+ </td>
697
+ <td>75.7
698
+ </td>
699
+ <td>75.0
700
+ </td>
701
+ <td>79.0
702
+ </td>
703
+ <td>79.4
704
+ </td>
705
+ <td>80.0
706
+ </td>
707
+ </tr>
708
+ <tr>
709
+ <td>DROP (F1)
710
+ </td>
711
+ <td>3
712
+ </td>
713
+ <td>f1
714
+ </td>
715
+ <td>58.4
716
+ </td>
717
+ <td>59.5
718
+ </td>
719
+ <td>79.7
720
+ </td>
721
+ <td>79.6
722
+ </td>
723
+ <td>84.8
724
+ </td>
725
+ </tr>
726
+ </table>
727
+
728
+
729
+
730
+ ### Instruction tuned models
731
+
732
+
733
+ <table>
734
+ <tr>
735
+ <td><strong>Category</strong>
736
+ </td>
737
+ <td><strong>Benchmark</strong>
738
+ </td>
739
+ <td><strong># Shots</strong>
740
+ </td>
741
+ <td><strong>Metric</strong>
742
+ </td>
743
+ <td><strong>Llama 3 8B Instruct</strong>
744
+ </td>
745
+ <td><strong>Llama 3.1 8B Instruct</strong>
746
+ </td>
747
+ <td><strong>Llama 3 70B Instruct</strong>
748
+ </td>
749
+ <td><strong>Llama 3.1 70B Instruct</strong>
750
+ </td>
751
+ <td><strong>Llama 3.1 405B Instruct</strong>
752
+ </td>
753
+ </tr>
754
+ <tr>
755
+ <td rowspan="4" >General
756
+ </td>
757
+ <td>MMLU
758
+ </td>
759
+ <td>5
760
+ </td>
761
+ <td>macro_avg/acc
762
+ </td>
763
+ <td>68.5
764
+ </td>
765
+ <td>69.4
766
+ </td>
767
+ <td>82.0
768
+ </td>
769
+ <td>83.6
770
+ </td>
771
+ <td>87.3
772
+ </td>
773
+ </tr>
774
+ <tr>
775
+ <td>MMLU (CoT)
776
+ </td>
777
+ <td>0
778
+ </td>
779
+ <td>macro_avg/acc
780
+ </td>
781
+ <td>65.3
782
+ </td>
783
+ <td>73.0
784
+ </td>
785
+ <td>80.9
786
+ </td>
787
+ <td>86.0
788
+ </td>
789
+ <td>88.6
790
+ </td>
791
+ </tr>
792
+ <tr>
793
+ <td>MMLU-Pro (CoT)
794
+ </td>
795
+ <td>5
796
+ </td>
797
+ <td>micro_avg/acc_char
798
+ </td>
799
+ <td>45.5
800
+ </td>
801
+ <td>48.3
802
+ </td>
803
+ <td>63.4
804
+ </td>
805
+ <td>66.4
806
+ </td>
807
+ <td>73.3
808
+ </td>
809
+ </tr>
810
+ <tr>
811
+ <td>IFEval
812
+ </td>
813
+ <td>
814
+ </td>
815
+ <td>
816
+ </td>
817
+ <td>76.8
818
+ </td>
819
+ <td>80.4
820
+ </td>
821
+ <td>82.9
822
+ </td>
823
+ <td>87.5
824
+ </td>
825
+ <td>88.6
826
+ </td>
827
+ </tr>
828
+ <tr>
829
+ <td rowspan="2" >Reasoning
830
+ </td>
831
+ <td>ARC-C
832
+ </td>
833
+ <td>0
834
+ </td>
835
+ <td>acc
836
+ </td>
837
+ <td>82.4
838
+ </td>
839
+ <td>83.4
840
+ </td>
841
+ <td>94.4
842
+ </td>
843
+ <td>94.8
844
+ </td>
845
+ <td>96.9
846
+ </td>
847
+ </tr>
848
+ <tr>
849
+ <td>GPQA
850
+ </td>
851
+ <td>0
852
+ </td>
853
+ <td>em
854
+ </td>
855
+ <td>34.6
856
+ </td>
857
+ <td>30.4
858
+ </td>
859
+ <td>39.5
860
+ </td>
861
+ <td>46.7
862
+ </td>
863
+ <td>50.7
864
+ </td>
865
+ </tr>
866
+ <tr>
867
+ <td rowspan="4" >Code
868
+ </td>
869
+ <td>HumanEval
870
+ </td>
871
+ <td>0
872
+ </td>
873
+ <td>pass@1
874
+ </td>
875
+ <td>60.4
876
+ </td>
877
+ <td>72.6
878
+ </td>
879
+ <td>81.7
880
+ </td>
881
+ <td>80.5
882
+ </td>
883
+ <td>89.0
884
+ </td>
885
+ </tr>
886
+ <tr>
887
+ <td>MBPP ++ base version
888
+ </td>
889
+ <td>0
890
+ </td>
891
+ <td>pass@1
892
+ </td>
893
+ <td>70.6
894
+ </td>
895
+ <td>72.8
896
+ </td>
897
+ <td>82.5
898
+ </td>
899
+ <td>86.0
900
+ </td>
901
+ <td>88.6
902
+ </td>
903
+ </tr>
904
+ <tr>
905
+ <td>Multipl-E HumanEval
906
+ </td>
907
+ <td>0
908
+ </td>
909
+ <td>pass@1
910
+ </td>
911
+ <td>-
912
+ </td>
913
+ <td>50.8
914
+ </td>
915
+ <td>-
916
+ </td>
917
+ <td>65.5
918
+ </td>
919
+ <td>75.2
920
+ </td>
921
+ </tr>
922
+ <tr>
923
+ <td>Multipl-E MBPP
924
+ </td>
925
+ <td>0
926
+ </td>
927
+ <td>pass@1
928
+ </td>
929
+ <td>-
930
+ </td>
931
+ <td>52.4
932
+ </td>
933
+ <td>-
934
+ </td>
935
+ <td>62.0
936
+ </td>
937
+ <td>65.7
938
+ </td>
939
+ </tr>
940
+ <tr>
941
+ <td rowspan="2" >Math
942
+ </td>
943
+ <td>GSM-8K (CoT)
944
+ </td>
945
+ <td>8
946
+ </td>
947
+ <td>em_maj1@1
948
+ </td>
949
+ <td>80.6
950
+ </td>
951
+ <td>84.5
952
+ </td>
953
+ <td>93.0
954
+ </td>
955
+ <td>95.1
956
+ </td>
957
+ <td>96.8
958
+ </td>
959
+ </tr>
960
+ <tr>
961
+ <td>MATH (CoT)
962
+ </td>
963
+ <td>0
964
+ </td>
965
+ <td>final_em
966
+ </td>
967
+ <td>29.1
968
+ </td>
969
+ <td>51.9
970
+ </td>
971
+ <td>51.0
972
+ </td>
973
+ <td>68.0
974
+ </td>
975
+ <td>73.8
976
+ </td>
977
+ </tr>
978
+ <tr>
979
+ <td rowspan="4" >Tool Use
980
+ </td>
981
+ <td>API-Bank
982
+ </td>
983
+ <td>0
984
+ </td>
985
+ <td>acc
986
+ </td>
987
+ <td>48.3
988
+ </td>
989
+ <td>82.6
990
+ </td>
991
+ <td>85.1
992
+ </td>
993
+ <td>90.0
994
+ </td>
995
+ <td>92.0
996
+ </td>
997
+ </tr>
998
+ <tr>
999
+ <td>BFCL
1000
+ </td>
1001
+ <td>0
1002
+ </td>
1003
+ <td>acc
1004
+ </td>
1005
+ <td>60.3
1006
+ </td>
1007
+ <td>76.1
1008
+ </td>
1009
+ <td>83.0
1010
+ </td>
1011
+ <td>84.8
1012
+ </td>
1013
+ <td>88.5
1014
+ </td>
1015
+ </tr>
1016
+ <tr>
1017
+ <td>Gorilla Benchmark API Bench
1018
+ </td>
1019
+ <td>0
1020
+ </td>
1021
+ <td>acc
1022
+ </td>
1023
+ <td>1.7
1024
+ </td>
1025
+ <td>8.2
1026
+ </td>
1027
+ <td>14.7
1028
+ </td>
1029
+ <td>29.7
1030
+ </td>
1031
+ <td>35.3
1032
+ </td>
1033
+ </tr>
1034
+ <tr>
1035
+ <td>Nexus (0-shot)
1036
+ </td>
1037
+ <td>0
1038
+ </td>
1039
+ <td>macro_avg/acc
1040
+ </td>
1041
+ <td>18.1
1042
+ </td>
1043
+ <td>38.5
1044
+ </td>
1045
+ <td>47.8
1046
+ </td>
1047
+ <td>56.7
1048
+ </td>
1049
+ <td>58.7
1050
+ </td>
1051
+ </tr>
1052
+ <tr>
1053
+ <td>Multilingual
1054
+ </td>
1055
+ <td>Multilingual MGSM (CoT)
1056
+ </td>
1057
+ <td>0
1058
+ </td>
1059
+ <td>em
1060
+ </td>
1061
+ <td>-
1062
+ </td>
1063
+ <td>68.9
1064
+ </td>
1065
+ <td>-
1066
+ </td>
1067
+ <td>86.9
1068
+ </td>
1069
+ <td>91.6
1070
+ </td>
1071
+ </tr>
1072
+ </table>
1073
+
1074
+ #### Multilingual benchmarks
1075
+
1076
+ <table>
1077
+ <tr>
1078
+ <td><strong>Category</strong>
1079
+ </td>
1080
+ <td><strong>Benchmark</strong>
1081
+ </td>
1082
+ <td><strong>Language</strong>
1083
+ </td>
1084
+ <td><strong>Llama 3.1 8B</strong>
1085
+ </td>
1086
+ <td><strong>Llama 3.1 70B</strong>
1087
+ </td>
1088
+ <td><strong>Llama 3.1 405B</strong>
1089
+ </td>
1090
+ </tr>
1091
+ <tr>
1092
+ <td rowspan="9" ><strong>General</strong>
1093
+ </td>
1094
+ <td rowspan="9" ><strong>MMLU (5-shot, macro_avg/acc)</strong>
1095
+ </td>
1096
+ <td>Portuguese
1097
+ </td>
1098
+ <td>62.12
1099
+ </td>
1100
+ <td>80.13
1101
+ </td>
1102
+ <td>84.95
1103
+ </td>
1104
+ </tr>
1105
+ <tr>
1106
+ <td>Spanish
1107
+ </td>
1108
+ <td>62.45
1109
+ </td>
1110
+ <td>80.05
1111
+ </td>
1112
+ <td>85.08
1113
+ </td>
1114
+ </tr>
1115
+ <tr>
1116
+ <td>Italian
1117
+ </td>
1118
+ <td>61.63
1119
+ </td>
1120
+ <td>80.4
1121
+ </td>
1122
+ <td>85.04
1123
+ </td>
1124
+ </tr>
1125
+ <tr>
1126
+ <td>German
1127
+ </td>
1128
+ <td>60.59
1129
+ </td>
1130
+ <td>79.27
1131
+ </td>
1132
+ <td>84.36
1133
+ </td>
1134
+ </tr>
1135
+ <tr>
1136
+ <td>French
1137
+ </td>
1138
+ <td>62.34
1139
+ </td>
1140
+ <td>79.82
1141
+ </td>
1142
+ <td>84.66
1143
+ </td>
1144
+ </tr>
1145
+ <tr>
1146
+ <td>Hindi
1147
+ </td>
1148
+ <td>50.88
1149
+ </td>
1150
+ <td>74.52
1151
+ </td>
1152
+ <td>80.31
1153
+ </td>
1154
+ </tr>
1155
+ <tr>
1156
+ <td>Thai
1157
+ </td>
1158
+ <td>50.32
1159
+ </td>
1160
+ <td>72.95
1161
+ </td>
1162
+ <td>78.21
1163
+ </td>
1164
+ </tr>
1165
+ </table>
1166
 
 
1167
 
 
1168
 
1169
+ ## Responsibility & Safety
1170
 
1171
+ As part of our Responsible release approach, we followed a three-pronged strategy to managing trust & safety risks:
1172
 
 
1173
 
 
1174
 
1175
+ * Enable developers to deploy helpful, safe and flexible experiences for their target audience and for the use cases supported by Llama.
1176
+ * Protect developers against adversarial users aiming to exploit Llama capabilities to potentially cause harm.
1177
+ * Provide protections for the community to help prevent the misuse of our models.
1178
 
 
1179
 
1180
+ ### Responsible deployment
1181
 
1182
+ Llama is a foundational technology designed to be used in a variety of use cases, examples on how Meta’s Llama models have been responsibly deployed can be found in our [Community Stories webpage](https://llama.meta.com/community-stories/). Our approach is to build the most helpful models enabling the world to benefit from the technology power, by aligning our model safety for the generic use cases addressing a standard set of harms. Developers are then in the driver seat to tailor safety for their use case, defining their own policy and deploying the models with the necessary safeguards in their Llama systems. Llama 3.1 was developed following the best practices outlined in our Responsible Use Guide, you can refer to the [Responsible Use Guide](https://llama.meta.com/responsible-use-guide/) to learn more.
1183
 
 
1184
 
1185
+ #### Llama 3.1 instruct
1186
 
1187
+ Our main objectives for conducting safety fine-tuning are to provide the research community with a valuable resource for studying the robustness of safety fine-tuning, as well as to offer developers a readily available, safe, and powerful model for various applications to reduce the developer workload to deploy safe AI systems. For more details on the safety mitigations implemented please read the Llama 3 paper.
1188
 
1189
+ **Fine-tuning data**
1190
 
1191
+ We employ a multi-faceted approach to data collection, combining human-generated data from our vendors with synthetic data to mitigate potential safety risks. We’ve developed many large language model (LLM)-based classifiers that enable us to thoughtfully select high-quality prompts and responses, enhancing data quality control.
1192
 
1193
+ **Refusals and Tone**
1194
 
1195
+ Building on the work we started with Llama 3, we put a great emphasis on model refusals to benign prompts as well as refusal tone. We included both borderline and adversarial prompts in our safety data strategy, and modified our safety data responses to follow tone guidelines.
1196
 
 
1197
 
1198
+ #### Llama 3.1 systems
1199
 
1200
+ **Large language models, including Llama 3.1, are not designed to be deployed in isolation but instead should be deployed as part of an overall AI system with additional safety guardrails as required.** Developers are expected to deploy system safeguards when building agentic systems. Safeguards are key to achieve the right helpfulness-safety alignment as well as mitigating safety and security risks inherent to the system and any integration of the model or system with external tools.
1201
 
1202
+ As part of our responsible release approach, we provide the community with [safeguards](https://llama.meta.com/trust-and-safety/) that developers should deploy with Llama models or other LLMs, including Llama Guard 3, Prompt Guard and Code Shield. All our [reference implementations](https://github.com/meta-llama/llama-agentic-system) demos contain these safeguards by default so developers can benefit from system-level safety out-of-the-box.
1203
 
 
1204
 
1205
+ #### New capabilities
1206
 
1207
+ Note that this release introduces new capabilities, including a longer context window, multilingual inputs and outputs and possible integrations by developers with third party tools. Building with these new capabilities requires specific considerations in addition to the best practices that generally apply across all Generative AI use cases.
1208
 
1209
+ **Tool-use**: Just like in standard software development, developers are responsible for the integration of the LLM with the tools and services of their choice. They should define a clear policy for their use case and assess the integrity of the third party services they use to be aware of the safety and security limitations when using this capability. Refer to the Responsible Use Guide for best practices on the safe deployment of the third party safeguards.
1210
 
1211
+ **Multilinguality**: Llama 3.1 supports 7 languages in addition to English: French, German, Hindi, Italian, Portuguese, Spanish, and Thai. Llama may be able to output text in other languages than those that meet performance thresholds for safety and helpfulness. We strongly discourage developers from using this model to converse in non-supported languages without implementing finetuning and system controls in alignment with their policies and the best practices shared in the Responsible Use Guide.
1212
 
 
1213
 
1214
+ ### Evaluations
1215
 
1216
+ We evaluated Llama models for common use cases as well as specific capabilities. Common use cases evaluations measure safety risks of systems for most commonly built applications including chat bot, coding assistant, tool calls. We built dedicated, adversarial evaluation datasets and evaluated systems composed of Llama models and Llama Guard 3 to filter input prompt and output response. It is important to evaluate applications in context, and we recommend building dedicated evaluation dataset for your use case. Prompt Guard and Code Shield are also available if relevant to the application.
1217
 
1218
+ Capability evaluations measure vulnerabilities of Llama models inherent to specific capabilities, for which were crafted dedicated benchmarks including long context, multilingual, tools calls, coding or memorization.
1219
 
1220
+ **Red teaming**
1221
 
1222
+ For both scenarios, we conducted recurring red teaming exercises with the goal of discovering risks via adversarial prompting and we used the learnings to improve our benchmarks and safety tuning datasets.
1223
 
1224
+ We partnered early with subject-matter experts in critical risk areas to understand the nature of these real-world harms and how such models may lead to unintended harm for society. Based on these conversations, we derived a set of adversarial goals for the red team to attempt to achieve, such as extracting harmful information or reprogramming the model to act in a potentially harmful capacity. The red team consisted of experts in cybersecurity, adversarial machine learning, responsible AI, and integrity in addition to multilingual content specialists with background in integrity issues in specific geographic markets.
1225
 
 
1226
 
1227
+ ### Critical and other risks
1228
 
1229
+ We specifically focused our efforts on mitigating the following critical risk areas:
1230
 
1231
+ **1- CBRNE (Chemical, Biological, Radiological, Nuclear, and Explosive materials) helpfulness**
1232
 
1233
+ To assess risks related to proliferation of chemical and biological weapons, we performed uplift testing designed to assess whether use of Llama 3.1 models could meaningfully increase the capabilities of malicious actors to plan or carry out attacks using these types of weapons.
1234
 
 
1235
 
1236
+ **2. Child Safety**
1237
 
1238
+ Child Safety risk assessments were conducted using a team of experts, to assess the model’s capability to produce outputs that could result in Child Safety risks and inform on any necessary and appropriate risk mitigations via fine tuning. We leveraged those expert red teaming sessions to expand the coverage of our evaluation benchmarks through Llama 3 model development. For Llama 3, we conducted new in-depth sessions using objective based methodologies to assess the model risks along multiple attack vectors including the additional languages Llama 3 is trained on. We also partnered with content specialists to perform red teaming exercises assessing potentially violating content while taking account of market specific nuances or experiences.
1239
 
1240
+ **3. Cyber attack enablement**
1241
 
1242
+ Our cyber attack uplift study investigated whether LLMs can enhance human capabilities in hacking tasks, both in terms of skill level and speed.
1243
 
1244
+ Our attack automation study focused on evaluating the capabilities of LLMs when used as autonomous agents in cyber offensive operations, specifically in the context of ransomware attacks. This evaluation was distinct from previous studies that considered LLMs as interactive assistants. The primary objective was to assess whether these models could effectively function as independent agents in executing complex cyber-attacks without human intervention.
1245
 
1246
+ Our study of Llama-3.1-405B’s social engineering uplift for cyber attackers was conducted to assess the effectiveness of AI models in aiding cyber threat actors in spear phishing campaigns. Please read our Llama 3.1 Cyber security whitepaper to learn more.
1247
 
 
1248
 
1249
+ ### Community
1250
 
1251
+ Generative AI safety requires expertise and tooling, and we believe in the strength of the open community to accelerate its progress. We are active members of open consortiums, including the AI Alliance, Partnership on AI and MLCommons, actively contributing to safety standardization and transparency. We encourage the community to adopt taxonomies like the MLCommons Proof of Concept evaluation to facilitate collaboration and transparency on safety and content evaluations. Our Purple Llama tools are open sourced for the community to use and widely distributed across ecosystem partners including cloud service providers. We encourage community contributions to our [Github repository](https://github.com/meta-llama/PurpleLlama).
1252
 
1253
+ We also set up the [Llama Impact Grants](https://llama.meta.com/llama-impact-grants/) program to identify and support the most compelling applications of Meta’s Llama model for societal benefit across three categories: education, climate and open innovation. The 20 finalists from the hundreds of applications can be found [here](https://llama.meta.com/llama-impact-grants/#finalists).
1254
 
1255
+ Finally, we put in place a set of resources including an [output reporting mechanism](https://developers.facebook.com/llama_output_feedback) and [bug bounty program](https://www.facebook.com/whitehat) to continuously improve the Llama technology with the help of the community.
1256
 
 
1257
 
1258
+ ## Ethical Considerations and Limitations
1259
 
1260
+ The core values of Llama 3.1 are openness, inclusivity and helpfulness. It is meant to serve everyone, and to work for a wide range of use cases. It is thus designed to be accessible to people across many different backgrounds, experiences and perspectives. Llama 3.1 addresses users and their needs as they are, without insertion unnecessary judgment or normativity, while reflecting the understanding that even content that may appear problematic in some cases can serve valuable purposes in others. It respects the dignity and autonomy of all users, especially in terms of the values of free thought and expression that power innovation and progress.
1261
 
1262
+ But Llama 3.1 is a new technology, and like any new technology, there are risks associated with its use. Testing conducted to date has not covered, nor could it cover, all scenarios. For these reasons, as with all LLMs, Llama 3.1’s potential outputs cannot be predicted in advance, and the model may in some instances produce inaccurate, biased or other objectionable responses to user prompts. Therefore, before deploying any applications of Llama 3.1 models, developers should perform safety testing and tuning tailored to their specific applications of the model. Please refer to available resources including our [Responsible Use Guide](https://llama.meta.com/responsible-use-guide), [Trust and Safety](https://llama.meta.com/trust-and-safety/) solutions, and other [resources](https://llama.meta.com/docs/get-started/) to learn more about responsible development.