Initial GGUF model commit
Browse files
README.md
CHANGED
@@ -1,14 +1,16 @@
|
|
1 |
---
|
2 |
inference: false
|
|
|
|
|
3 |
license: llama2
|
4 |
model_creator: Meta
|
5 |
-
model_link: https://
|
6 |
model_name: CodeLlama 34B
|
7 |
model_type: llama
|
|
|
8 |
quantized_by: TheBloke
|
9 |
tags:
|
10 |
- llama-2
|
11 |
-
- codellama
|
12 |
---
|
13 |
|
14 |
<!-- header start -->
|
@@ -30,11 +32,11 @@ tags:
|
|
30 |
|
31 |
# CodeLlama 34B - GGUF
|
32 |
- Model creator: [Meta](https://huggingface.co/meta-llama)
|
33 |
-
- Original model: [CodeLlama 34B](https://
|
34 |
|
35 |
## Description
|
36 |
|
37 |
-
This repo contains GGUF format model files for [Meta's CodeLlama 34B](https://
|
38 |
|
39 |
<!-- README_GGUF.md-about-gguf start -->
|
40 |
### About GGUF
|
@@ -45,15 +47,15 @@ The key benefit of GGUF is that it is a extensible, future-proof format which st
|
|
45 |
|
46 |
As of August 25th, here is a list of clients and libraries that are known to support GGUF:
|
47 |
* [llama.cpp](https://github.com/ggerganov/llama.cpp)
|
|
|
48 |
* [KoboldCpp](https://github.com/LostRuins/koboldcpp), now supports GGUF as of release 1.41! A powerful GGML web UI, with full GPU accel. Especially good for story telling.
|
49 |
* [LoLLMS Web UI](https://github.com/ParisNeo/lollms-webui), should now work, choose the `c_transformers` backend. A great web UI with many interesting features. Supports CUDA GPU acceleration.
|
50 |
* [ctransformers](https://github.com/marella/ctransformers), now supports GGUF as of version 0.2.24! A Python library with GPU accel, LangChain support, and OpenAI-compatible AI server.
|
|
|
51 |
* [candle](https://github.com/huggingface/candle), added GGUF support on August 22nd. Candle is a Rust ML framework with a focus on performance, including GPU support, and ease of use.
|
52 |
|
53 |
-
The clients and libraries below are expecting to add GGUF support
|
54 |
-
* [
|
55 |
-
* [LM Studio](https://lmstudio.ai/), in active development - hoped to be ready by August 25th-26th.
|
56 |
-
* [llama-cpp-python](https://github.com/abetlen/llama-cpp-python), [in active development](https://github.com/abetlen/llama-cpp-python/issues/628).
|
57 |
<!-- README_GGUF.md-about-gguf end -->
|
58 |
|
59 |
<!-- repositories-available start -->
|
@@ -62,7 +64,7 @@ The clients and libraries below are expecting to add GGUF support. Where possibl
|
|
62 |
* [GPTQ models for GPU inference, with multiple quantisation parameter options.](https://huggingface.co/TheBloke/CodeLlama-34B-GPTQ)
|
63 |
* [2, 3, 4, 5, 6 and 8-bit GGUF models for CPU+GPU inference](https://huggingface.co/TheBloke/CodeLlama-34B-GGUF)
|
64 |
* [2, 3, 4, 5, 6 and 8-bit GGML models for CPU+GPU inference (deprecated)](https://huggingface.co/TheBloke/CodeLlama-34B-GGML)
|
65 |
-
* [Meta's original unquantised fp16 model in pytorch format, for GPU inference and for further conversions](https://huggingface.co/
|
66 |
<!-- repositories-available end -->
|
67 |
|
68 |
<!-- prompt-template start -->
|
@@ -164,7 +166,7 @@ Donaters will get priority support on any and all AI/LLM/model questions and req
|
|
164 |
|
165 |
**Special thanks to**: Aemon Algiz.
|
166 |
|
167 |
-
**Patreon special mentions**:
|
168 |
|
169 |
|
170 |
Thank you to all my generous patrons and donaters!
|
@@ -176,125 +178,113 @@ And thank you again to a16z for their generous grant.
|
|
176 |
<!-- original-model-card start -->
|
177 |
# Original model card: Meta's CodeLlama 34B
|
178 |
|
|
|
|
|
179 |
|
180 |
-
|
181 |
-
|
182 |
-
|
183 |
-
|
184 |
-
|
185 |
-
<div style="display: flex; justify-content: space-between; width: 100%;">
|
186 |
-
<div style="display: flex; flex-direction: column; align-items: flex-start;">
|
187 |
-
<p style="margin-top: 0.5em; margin-bottom: 0em;"><a href="https://discord.gg/theblokeai">Chat & support: TheBloke's Discord server</a></p>
|
188 |
-
</div>
|
189 |
-
<div style="display: flex; flex-direction: column; align-items: flex-end;">
|
190 |
-
<p style="margin-top: 0.5em; margin-bottom: 0em;"><a href="https://www.patreon.com/TheBlokeAI">Want to contribute? TheBloke's Patreon page</a></p>
|
191 |
-
</div>
|
192 |
-
</div>
|
193 |
-
<div style="text-align:center; margin-top: 0em; margin-bottom: 0em"><p style="margin-top: 0.25em; margin-bottom: 0em;">TheBloke's LLM work is generously supported by a grant from <a href="https://a16z.com">andreessen horowitz (a16z)</a></p></div>
|
194 |
-
<hr style="margin-top: 1.0em; margin-bottom: 1.0em;">
|
195 |
-
<!-- header end -->
|
196 |
|
197 |
-
|
198 |
-
- Model creator: [Meta](https://ai.meta.com/llama/)
|
199 |
-
|
200 |
-
## Description
|
201 |
-
|
202 |
-
This is Transformers/HF format fp16 weights for CodeLlama 34B. It is the result of downloading CodeLlama 34B from [Meta](https://ai.meta.com/blog/code-llama-large-language-model-coding/) and converting to HF using `convert_llama_weights_to_hf.py`.
|
203 |
-
|
204 |
-
Quantisations will be coming shortly.
|
205 |
-
|
206 |
-
Please note that due to a change in the RoPE Theta value, for correct results you must load these FP16 models with `trust_remote_code=True`
|
207 |
-
|
208 |
-
Credit to @emozilla for creating the necessary modelling code to achieve this!
|
209 |
-
|
210 |
-
## Prompt template: TBC
|
211 |
|
|
|
212 |
|
213 |
-
|
214 |
-
|
215 |
-
|
216 |
-
|
217 |
-
For further support, and discussions on these models and AI in general, join us at:
|
218 |
-
|
219 |
-
[TheBloke AI's Discord server](https://discord.gg/theblokeai)
|
220 |
-
|
221 |
-
## Thanks, and how to contribute.
|
222 |
-
|
223 |
-
Thanks to the [chirper.ai](https://chirper.ai) team!
|
224 |
-
|
225 |
-
I've had a lot of people ask if they can contribute. I enjoy providing models and helping people, and would love to be able to spend even more time doing it, as well as expanding into new projects like fine tuning/training.
|
226 |
-
|
227 |
-
If you're able and willing to contribute it will be most gratefully received and will help me to keep providing more models, and to start work on new AI projects.
|
228 |
-
|
229 |
-
Donaters will get priority support on any and all AI/LLM/model questions and requests, access to a private Discord room, plus other benefits.
|
230 |
-
|
231 |
-
* Patreon: https://patreon.com/TheBlokeAI
|
232 |
-
* Ko-Fi: https://ko-fi.com/TheBlokeAI
|
233 |
-
|
234 |
-
**Special thanks to**: Aemon Algiz.
|
235 |
-
|
236 |
-
**Patreon special mentions**: Sam, theTransient, Jonathan Leane, Steven Wood, webtim, Johann-Peter Hartmann, Geoffrey Montalvo, Gabriel Tamborski, Willem Michiel, John Villwock, Derek Yates, Mesiah Bishop, Eugene Pentland, Pieter, Chadd, Stephen Murray, Daniel P. Andersen, terasurfer, Brandon Frisco, Thomas Belote, Sid, Nathan LeClaire, Magnesian, Alps Aficionado, Stanislav Ovsiannikov, Alex, Joseph William Delisle, Nikolai Manek, Michael Davis, Junyu Yang, K, J, Spencer Kim, Stefan Sabev, Olusegun Samson, transmissions 11, Michael Levine, Cory Kujawski, Rainer Wilmers, zynix, Kalila, Luke @flexchar, Ajan Kanaga, Mandus, vamX, Ai Maven, Mano Prime, Matthew Berman, subjectnull, Vitor Caleffi, Clay Pascal, biorpg, alfie_i, 阿明, Jeffrey Morgan, ya boyyy, Raymond Fosdick, knownsqashed, Olakabola, Leonard Tan, ReadyPlayerEmma, Enrico Ros, Dave, Talal Aujan, Illia Dulskyi, Sean Connelly, senxiiz, Artur Olbinski, Elle, Raven Klaugh, Fen Risland, Deep Realms, Imad Khwaja, Fred von Graf, Will Dee, usrbinkat, SuperWojo, Alexandros Triantafyllidis, Swaroop Kallakuri, Dan Guido, John Detwiler, Pedro Madruga, Iucharbius, Viktor Bowallius, Asp the Wyvern, Edmond Seymore, Trenton Dambrowitz, Space Cruiser, Spiking Neurons AB, Pyrater, LangChain4j, Tony Hughes, Kacper Wikieł, Rishabh Srivastava, David Ziegler, Luke Pendergrass, Andrey, Gabriel Puliatti, Lone Striker, Sebastain Graf, Pierre Kircher, Randy H, NimbleBox.ai, Vadim, danny, Deo Leter
|
237 |
-
|
238 |
-
|
239 |
-
Thank you to all my generous patrons and donaters!
|
240 |
|
241 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
242 |
|
243 |
-
<!-- footer end -->
|
244 |
|
245 |
-
|
|
|
246 |
|
247 |
-
|
248 |
|
249 |
-
|
250 |
|
251 |
-
|
|
|
|
|
252 |
|
253 |
-
**Variations** Code Llama comes in three model sizes, and three variants:
|
254 |
-
1) Code Llama: our base models designed for general code synthesis and understanding
|
255 |
-
2) Code Llama - Python: designed specifically for Python
|
256 |
-
3) Code Llama - Instruct: for instruction following and safer deployment
|
257 |
-
|
258 |
All variants are available in sizes of 7B, 13B and 34B parameters.
|
259 |
|
|
|
|
|
260 |
**Input** Models input text only.
|
261 |
|
262 |
-
**Output** Models
|
263 |
|
264 |
-
**Model Architecture** Code Llama
|
265 |
|
266 |
**Model Dates** Code Llama and its variants have been trained between January 2023 and July 2023.
|
267 |
|
268 |
-
**Status** This is a static model trained on an offline dataset. Future versions of Code Llama - Instruct will be released
|
269 |
|
270 |
-
**
|
271 |
|
272 |
**Research Paper** More information can be found in the paper "[Code Llama: Open Foundation Models for Code](https://ai.meta.com/research/publications/code-llama-open-foundation-models-for-code/)".
|
273 |
|
274 |
-
|
275 |
-
|
276 |
-
## **Intended Use**
|
277 |
**Intended Use Cases** Code Llama and its variants is intended for commercial and research use in English and relevant programming languages. The base model Code Llama can be adapted for a variety of code synthesis and understanding tasks, Code Llama - Python is designed specifically to handle the Python programming language, and Code Llama - Instruct is intended to be safer to use for code assistant and generation applications.
|
278 |
|
279 |
**Out-of-Scope Uses** Use in any manner that violates applicable laws or regulations (including trade compliance laws). Use in languages other than English. Use in any other way that is prohibited by the Acceptable Use Policy and Licensing Agreement for Code Llama and its variants.
|
280 |
|
281 |
-
##
|
282 |
-
**Training Factors**
|
283 |
-
We used custom training libraries. The training and fine-tuning of the released models have been performed Meta’s Research Super Cluster.
|
284 |
|
285 |
**Carbon Footprint** In aggregate, training all 9 Code Llama models required 400K GPU hours of computation on hardware of type A100-80GB (TDP of 350-400W). Estimated total emissions were 65.3 tCO2eq, 100% of which were offset by Meta’s sustainability program.
|
286 |
|
287 |
-
|
|
|
288 |
All experiments reported here and the released models have been trained and fine-tuned using the same data as Llama 2 with different weights (see Section 2 and Table 1 in the [research paper](https://ai.meta.com/research/publications/code-llama-open-foundation-models-for-code/) for details).
|
289 |
-
Code Llama - Instruct uses additional instruction fine-tuning data.
|
290 |
|
291 |
-
|
|
|
292 |
See evaluations for the main models and detailed ablations in Section 3 and safety evaluations in Section 4 of the research paper.
|
293 |
|
294 |
-
|
|
|
|
|
295 |
Code Llama and its variants are a new technology that carries risks with use. Testing conducted to date has been in English, and has not covered, nor could it cover all scenarios. For these reasons, as with all LLMs, Code Llama’s potential outputs cannot be predicted in advance, and the model may in some instances produce inaccurate or objectionable responses to user prompts. Therefore, before deploying any applications of Code Llama, developers should perform safety testing and tuning tailored to their specific applications of the model.
|
296 |
|
297 |
Please see the Responsible Use Guide available available at [https://ai.meta.com/llama/responsible-user-guide](https://ai.meta.com/llama/responsible-user-guide).
|
298 |
|
299 |
-
|
300 |
<!-- original-model-card end -->
|
|
|
1 |
---
|
2 |
inference: false
|
3 |
+
language:
|
4 |
+
- code
|
5 |
license: llama2
|
6 |
model_creator: Meta
|
7 |
+
model_link: https://huggingface.co/codellama/CodeLlama-34b-hf
|
8 |
model_name: CodeLlama 34B
|
9 |
model_type: llama
|
10 |
+
pipeline_tag: text-generation
|
11 |
quantized_by: TheBloke
|
12 |
tags:
|
13 |
- llama-2
|
|
|
14 |
---
|
15 |
|
16 |
<!-- header start -->
|
|
|
32 |
|
33 |
# CodeLlama 34B - GGUF
|
34 |
- Model creator: [Meta](https://huggingface.co/meta-llama)
|
35 |
+
- Original model: [CodeLlama 34B](https://huggingface.co/codellama/CodeLlama-34b-hf)
|
36 |
|
37 |
## Description
|
38 |
|
39 |
+
This repo contains GGUF format model files for [Meta's CodeLlama 34B](https://huggingface.co/codellama/CodeLlama-34b-hf).
|
40 |
|
41 |
<!-- README_GGUF.md-about-gguf start -->
|
42 |
### About GGUF
|
|
|
47 |
|
48 |
As of August 25th, here is a list of clients and libraries that are known to support GGUF:
|
49 |
* [llama.cpp](https://github.com/ggerganov/llama.cpp)
|
50 |
+
* [text-generation-webui](https://github.com/oobabooga/text-generation-webui), the most widely used web UI. Supports GGUF with GPU acceleration via the ctransformers backend - llama-cpp-python backend should work soon too.
|
51 |
* [KoboldCpp](https://github.com/LostRuins/koboldcpp), now supports GGUF as of release 1.41! A powerful GGML web UI, with full GPU accel. Especially good for story telling.
|
52 |
* [LoLLMS Web UI](https://github.com/ParisNeo/lollms-webui), should now work, choose the `c_transformers` backend. A great web UI with many interesting features. Supports CUDA GPU acceleration.
|
53 |
* [ctransformers](https://github.com/marella/ctransformers), now supports GGUF as of version 0.2.24! A Python library with GPU accel, LangChain support, and OpenAI-compatible AI server.
|
54 |
+
* [llama-cpp-python](https://github.com/abetlen/llama-cpp-python), supports GGUF as of version 0.1.79. A Python library with GPU accel, LangChain support, and OpenAI-compatible API server.
|
55 |
* [candle](https://github.com/huggingface/candle), added GGUF support on August 22nd. Candle is a Rust ML framework with a focus on performance, including GPU support, and ease of use.
|
56 |
|
57 |
+
The clients and libraries below are expecting to add GGUF support shortly:
|
58 |
+
* [LM Studio](https://lmstudio.ai/), should be updated by end August 25th.
|
|
|
|
|
59 |
<!-- README_GGUF.md-about-gguf end -->
|
60 |
|
61 |
<!-- repositories-available start -->
|
|
|
64 |
* [GPTQ models for GPU inference, with multiple quantisation parameter options.](https://huggingface.co/TheBloke/CodeLlama-34B-GPTQ)
|
65 |
* [2, 3, 4, 5, 6 and 8-bit GGUF models for CPU+GPU inference](https://huggingface.co/TheBloke/CodeLlama-34B-GGUF)
|
66 |
* [2, 3, 4, 5, 6 and 8-bit GGML models for CPU+GPU inference (deprecated)](https://huggingface.co/TheBloke/CodeLlama-34B-GGML)
|
67 |
+
* [Meta's original unquantised fp16 model in pytorch format, for GPU inference and for further conversions](https://huggingface.co/codellama/CodeLlama-34b-hf)
|
68 |
<!-- repositories-available end -->
|
69 |
|
70 |
<!-- prompt-template start -->
|
|
|
166 |
|
167 |
**Special thanks to**: Aemon Algiz.
|
168 |
|
169 |
+
**Patreon special mentions**: Kacper Wikieł, knownsqashed, Leonard Tan, Asp the Wyvern, Daniel P. Andersen, Luke Pendergrass, Stanislav Ovsiannikov, RoA, Dave, Ai Maven, Kalila, Will Dee, Imad Khwaja, Nitin Borwankar, Joseph William Delisle, Tony Hughes, Cory Kujawski, Rishabh Srivastava, Russ Johnson, Stephen Murray, Lone Striker, Johann-Peter Hartmann, Elle, J, Deep Realms, SuperWojo, Raven Klaugh, Sebastain Graf, ReadyPlayerEmma, Alps Aficionado, Mano Prime, Derek Yates, Gabriel Puliatti, Mesiah Bishop, Magnesian, Sean Connelly, biorpg, Iucharbius, Olakabola, Fen Risland, Space Cruiser, theTransient, Illia Dulskyi, Thomas Belote, Spencer Kim, Pieter, John Detwiler, Fred von Graf, Michael Davis, Swaroop Kallakuri, subjectnull, Clay Pascal, Subspace Studios, Chris Smitley, Enrico Ros, usrbinkat, Steven Wood, alfie_i, David Ziegler, Willem Michiel, Matthew Berman, Andrey, Pyrater, Jeffrey Morgan, vamX, LangChain4j, Luke @flexchar, Trenton Dambrowitz, Pierre Kircher, Alex, Sam, James Bentley, Edmond Seymore, Eugene Pentland, Pedro Madruga, Rainer Wilmers, Dan Guido, Nathan LeClaire, Spiking Neurons AB, Talal Aujan, zynix, Artur Olbinski, Michael Levine, 阿明, K, John Villwock, Nikolai Manek, Femi Adebogun, senxiiz, Deo Leter, NimbleBox.ai, Viktor Bowallius, Geoffrey Montalvo, Mandus, Ajan Kanaga, ya boyyy, Jonathan Leane, webtim, Brandon Frisco, danny, Alexandros Triantafyllidis, Gabriel Tamborski, Randy H, terasurfer, Vadim, Junyu Yang, Vitor Caleffi, Chadd, transmissions 11
|
170 |
|
171 |
|
172 |
Thank you to all my generous patrons and donaters!
|
|
|
178 |
<!-- original-model-card start -->
|
179 |
# Original model card: Meta's CodeLlama 34B
|
180 |
|
181 |
+
# **Code Llama**
|
182 |
+
Code Llama is a collection of pretrained and fine-tuned generative text models ranging in scale from 7 billion to 34 billion parameters. This is the repository for the base 34B version in the Hugging Face Transformers format. This model is designed for general code synthesis and understanding. Links to other models can be found in the index at the bottom.
|
183 |
|
184 |
+
| | Base Model | Python | Instruct |
|
185 |
+
| --- | ----------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------- |
|
186 |
+
| 7B | [codellama/CodeLlama-7b-hf](https://huggingface.co/codellama/CodeLlama-7b-hf) | [codellama/CodeLlama-7b-Python-hf](https://huggingface.co/codellama/CodeLlama-7b-Python-hf) | [codellama/CodeLlama-7b-Instruct-hf](https://huggingface.co/codellama/CodeLlama-7b-Instruct-hf) |
|
187 |
+
| 13B | [codellama/CodeLlama-13b-hf](https://huggingface.co/codellama/CodeLlama-13b-hf) | [codellama/CodeLlama-13b-Python-hf](https://huggingface.co/codellama/CodeLlama-13b-Python-hf) | [codellama/CodeLlama-13b-Instruct-hf](https://huggingface.co/codellama/CodeLlama-13b-Instruct-hf) |
|
188 |
+
| 34B | [codellama/CodeLlama-34b-hf](https://huggingface.co/codellama/CodeLlama-34b-hf) | [codellama/CodeLlama-34b-Python-hf](https://huggingface.co/codellama/CodeLlama-34b-Python-hf) | [codellama/CodeLlama-34b-Instruct-hf](https://huggingface.co/codellama/CodeLlama-34b-Instruct-hf) |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
189 |
|
190 |
+
## Model Use
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
191 |
|
192 |
+
To use this model, please make sure to install transformers from `main` until the next version is released:
|
193 |
|
194 |
+
```bash
|
195 |
+
pip install git+https://github.com/huggingface/transformers.git@main accelerate
|
196 |
+
```
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
197 |
|
198 |
+
Model capabilities:
|
199 |
+
|
200 |
+
- [x] Code completion.
|
201 |
+
- [ ] Infilling.
|
202 |
+
- [ ] Instructions / chat.
|
203 |
+
- [ ] Python specialist.
|
204 |
+
|
205 |
+
|
206 |
+
```python
|
207 |
+
from transformers import AutoTokenizer
|
208 |
+
import transformers
|
209 |
+
import torch
|
210 |
+
|
211 |
+
model = "codellama/CodeLlama-34b-hf"
|
212 |
+
|
213 |
+
tokenizer = AutoTokenizer.from_pretrained(model)
|
214 |
+
pipeline = transformers.pipeline(
|
215 |
+
"text-generation",
|
216 |
+
model=model,
|
217 |
+
torch_dtype=torch.float16,
|
218 |
+
device_map="auto",
|
219 |
+
)
|
220 |
+
|
221 |
+
sequences = pipeline(
|
222 |
+
'import socket\n\ndef ping_exponential_backoff(host: str):',
|
223 |
+
do_sample=True,
|
224 |
+
top_k=10,
|
225 |
+
temperature=0.1,
|
226 |
+
top_p=0.95,
|
227 |
+
num_return_sequences=1,
|
228 |
+
eos_token_id=tokenizer.eos_token_id,
|
229 |
+
max_length=200,
|
230 |
+
)
|
231 |
+
for seq in sequences:
|
232 |
+
print(f"Result: {seq['generated_text']}")
|
233 |
+
```
|
234 |
|
|
|
235 |
|
236 |
+
## Model Details
|
237 |
+
*Note: Use of this model is governed by the Meta license. Meta developed and publicly released the Code Llama family of large language models (LLMs).
|
238 |
|
239 |
+
**Model Developers** Meta
|
240 |
|
241 |
+
**Variations** Code Llama comes in three model sizes, and three variants:
|
242 |
|
243 |
+
* Code Llama: base models designed for general code synthesis and understanding
|
244 |
+
* Code Llama - Python: designed specifically for Python
|
245 |
+
* Code Llama - Instruct: for instruction following and safer deployment
|
246 |
|
|
|
|
|
|
|
|
|
|
|
247 |
All variants are available in sizes of 7B, 13B and 34B parameters.
|
248 |
|
249 |
+
**This repository contains the base version of the 34B parameters model.**
|
250 |
+
|
251 |
**Input** Models input text only.
|
252 |
|
253 |
+
**Output** Models generate text only.
|
254 |
|
255 |
+
**Model Architecture** Code Llama is an auto-regressive language model that uses an optimized transformer architecture.
|
256 |
|
257 |
**Model Dates** Code Llama and its variants have been trained between January 2023 and July 2023.
|
258 |
|
259 |
+
**Status** This is a static model trained on an offline dataset. Future versions of Code Llama - Instruct will be released as we improve model safety with community feedback.
|
260 |
|
261 |
+
**License** A custom commercial license is available at: [https://ai.meta.com/resources/models-and-libraries/llama-downloads/](https://ai.meta.com/resources/models-and-libraries/llama-downloads/)
|
262 |
|
263 |
**Research Paper** More information can be found in the paper "[Code Llama: Open Foundation Models for Code](https://ai.meta.com/research/publications/code-llama-open-foundation-models-for-code/)".
|
264 |
|
265 |
+
## Intended Use
|
|
|
|
|
266 |
**Intended Use Cases** Code Llama and its variants is intended for commercial and research use in English and relevant programming languages. The base model Code Llama can be adapted for a variety of code synthesis and understanding tasks, Code Llama - Python is designed specifically to handle the Python programming language, and Code Llama - Instruct is intended to be safer to use for code assistant and generation applications.
|
267 |
|
268 |
**Out-of-Scope Uses** Use in any manner that violates applicable laws or regulations (including trade compliance laws). Use in languages other than English. Use in any other way that is prohibited by the Acceptable Use Policy and Licensing Agreement for Code Llama and its variants.
|
269 |
|
270 |
+
## Hardware and Software
|
271 |
+
**Training Factors** We used custom training libraries. The training and fine-tuning of the released models have been performed Meta’s Research Super Cluster.
|
|
|
272 |
|
273 |
**Carbon Footprint** In aggregate, training all 9 Code Llama models required 400K GPU hours of computation on hardware of type A100-80GB (TDP of 350-400W). Estimated total emissions were 65.3 tCO2eq, 100% of which were offset by Meta’s sustainability program.
|
274 |
|
275 |
+
## Training Data
|
276 |
+
|
277 |
All experiments reported here and the released models have been trained and fine-tuned using the same data as Llama 2 with different weights (see Section 2 and Table 1 in the [research paper](https://ai.meta.com/research/publications/code-llama-open-foundation-models-for-code/) for details).
|
|
|
278 |
|
279 |
+
## Evaluation Results
|
280 |
+
|
281 |
See evaluations for the main models and detailed ablations in Section 3 and safety evaluations in Section 4 of the research paper.
|
282 |
|
283 |
+
|
284 |
+
## Ethical Considerations and Limitations
|
285 |
+
|
286 |
Code Llama and its variants are a new technology that carries risks with use. Testing conducted to date has been in English, and has not covered, nor could it cover all scenarios. For these reasons, as with all LLMs, Code Llama’s potential outputs cannot be predicted in advance, and the model may in some instances produce inaccurate or objectionable responses to user prompts. Therefore, before deploying any applications of Code Llama, developers should perform safety testing and tuning tailored to their specific applications of the model.
|
287 |
|
288 |
Please see the Responsible Use Guide available available at [https://ai.meta.com/llama/responsible-user-guide](https://ai.meta.com/llama/responsible-user-guide).
|
289 |
|
|
|
290 |
<!-- original-model-card end -->
|