Ubuntu commited on
Commit
3c1167d
1 Parent(s): 8bb2147

modified: README.md

Browse files
Files changed (1) hide show
  1. README.md +450 -8
README.md CHANGED
@@ -1,4 +1,34 @@
1
  ---
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
2
  license: other
3
  library_name: peft
4
  tags:
@@ -10,7 +40,8 @@ model-index:
10
  ---
11
 
12
 
13
- [<img src="https://raw.githubusercontent.com/OpenAccess-AI-Collective/axolotl/main/image/axolotl-badge-web.png" alt="Built with Axolotl" width="200" height="32"/>](https://github.com/OpenAccess-AI-Collective/axolotl)
 
14
  <details><summary>See axolotl config</summary>
15
 
16
  axolotl version: `0.4.0`
@@ -47,7 +78,6 @@ wandb_watch:
47
  wandb_name:
48
  wandb_log_model:
49
 
50
-
51
  gradient_accumulation_steps: 6
52
  micro_batch_size: 4
53
  num_epochs: 4
@@ -91,17 +121,429 @@ This model is a fine-tuned version of [google/gemma-7b-it](https://huggingface.c
91
  It achieves the following results on the evaluation set:
92
  - Loss: 1.1911
93
 
94
- ## Model description
95
 
96
- More information needed
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
97
 
98
- ## Intended uses & limitations
 
99
 
100
- More information needed
 
 
 
 
 
 
 
 
 
 
 
 
 
 
101
 
102
- ## Training and evaluation data
103
 
104
- More information needed
 
 
 
 
 
 
 
 
 
 
 
 
 
 
105
 
106
  ## Training procedure
107
 
 
1
  ---
2
+ library_name: peft
3
+ tags:
4
+ - generated_from_trainer
5
+ base_model: google/gemma-7b-it
6
+ model-index:
7
+ - name: out
8
+ results: []
9
+ tags: []
10
+ extra_gated_heading: "Access Gemma on Hugging Face"
11
+ extra_gated_prompt: "To access Gemma on Hugging Face, you鈥檙e required to review and agree to Google鈥檚 usage license. To do this, please ensure you鈥檙e logged-in to Hugging Face and click below. Requests are processed immediately."
12
+ extra_gated_button_content: "Acknowledge license"
13
+ license: other
14
+ license_name: gemma-terms-of-use
15
+ license_link: https://ai.google.dev/gemma/terms
16
+ ---
17
+
18
+
19
+ ---
20
+
21
+ # Gemma Model Card
22
+
23
+ At the time of release, this family of models provides high-performance open
24
+ large language model implementations designed from the ground up for Responsible
25
+ AI development compared to similarly sized models.
26
+
27
+ Using the benchmark evaluation metrics described in this document, these models
28
+ have shown to provide superior performance to other, comparably-sized open model
29
+ alternatives.
30
+
31
+ --
32
  license: other
33
  library_name: peft
34
  tags:
 
40
  ---
41
 
42
 
43
+ [<img src="https://raw.githubusercontent.com/OpenAccess-AI-Collective/axolotl/main/image/axolotl-badge-web.png" alt="Built with Axol
44
+ otl" width="200" height="32"/>](https://github.com/OpenAccess-AI-Collective/axolotl)
45
  <details><summary>See axolotl config</summary>
46
 
47
  axolotl version: `0.4.0`
 
78
  wandb_name:
79
  wandb_log_model:
80
 
 
81
  gradient_accumulation_steps: 6
82
  micro_batch_size: 4
83
  num_epochs: 4
 
121
  It achieves the following results on the evaluation set:
122
  - Loss: 1.1911
123
 
 
124
 
125
+ **Model Page**: [Gemma](https://ai.google.dev/gemma/docs)
126
+
127
+ This model card corresponds to the 7B base version of the Gemma model. You can also visit the model card of the [2B base model](https://huggingface.co/google/gemma-2b), [7B instruct model](https://huggingface.co/google/gemma-7b-it), and [2B instruct model](https://huggingface.co/google/gemma-2b-it).
128
+
129
+ **Resources and Technical Documentation**:
130
+
131
+ * [Responsible Generative AI Toolkit](https://ai.google.dev/responsible)
132
+ * [Gemma on Kaggle](https://www.kaggle.com/models/google/gemma)
133
+ * [Gemma on Vertex Model Garden](https://console.cloud.google.com/vertex-ai/publishers/google/model-garden/335?version=gemma-7b-gg-hf)
134
+
135
+ **Terms of Use**: [Terms](https://www.kaggle.com/models/google/gemma/license/consent)
136
+
137
+ **Authors**: Google
138
+
139
+ ## Model Information
140
+
141
+ Summary description and brief definition of inputs and outputs.
142
+
143
+ ### Description
144
+
145
+ Gemma is a family of lightweight, state-of-the-art open models from Google,
146
+ built from the same research and technology used to create the Gemini models.
147
+ They are text-to-text, decoder-only large language models, available in English,
148
+ with open weights, pre-trained variants, and instruction-tuned variants. Gemma
149
+ models are well-suited for a variety of text generation tasks, including
150
+ question answering, summarization, and reasoning. Their relatively small size
151
+ makes it possible to deploy them in environments with limited resources such as
152
+ a laptop, desktop or your own cloud infrastructure, democratizing access to
153
+ state of the art AI models and helping foster innovation for everyone.
154
+
155
+ ### Usage
156
+
157
+ Below we share some code snippets on how to get quickly started with running the model. First make sure to `pip install -U transformers`, then copy the snippet from the section that is relevant for your usecase.
158
+
159
+ #### Fine-tuning examples
160
+
161
+ You can find fine-tuning notebooks under the [`examples/` directory](https://huggingface.co/google/gemma-7b/tree/main/examples). We provide:
162
+
163
+ * A script to perform Supervised Fine-Tuning (SFT) on UltraChat dataset using [QLoRA](https://huggingface.co/papers/2305.14314)
164
+ * A script to perform SFT using FSDP on TPU devices
165
+ * A notebook that you can run on a free-tier Google Colab instance to perform SFT on English quotes dataset. You can also find the copy of the notebook [here](https://github.com/huggingface/notebooks/blob/main/peft/gemma_7b_english_quotes.ipynb).
166
+
167
+ #### Running the model on a CPU
168
+
169
+
170
+ ```python
171
+ from transformers import AutoTokenizer, AutoModelForCausalLM
172
+
173
+ tokenizer = AutoTokenizer.from_pretrained("google/gemma-7b")
174
+ model = AutoModelForCausalLM.from_pretrained("google/gemma-7b")
175
+
176
+ input_text = "Write me a poem about Machine Learning."
177
+ input_ids = tokenizer(input_text, return_tensors="pt")
178
+
179
+ outputs = model.generate(**input_ids)
180
+ print(tokenizer.decode(outputs[0]))
181
+ ```
182
+
183
+
184
+ #### Running the model on a single / multi GPU
185
+
186
+
187
+ ```python
188
+ # pip install accelerate
189
+ from transformers import AutoTokenizer, AutoModelForCausalLM
190
+
191
+ tokenizer = AutoTokenizer.from_pretrained("google/gemma-7b")
192
+ model = AutoModelForCausalLM.from_pretrained("google/gemma-7b", device_map="auto")
193
+
194
+ input_text = "Write me a poem about Machine Learning."
195
+ input_ids = tokenizer(input_text, return_tensors="pt").to("cuda")
196
+
197
+ outputs = model.generate(**input_ids)
198
+ print(tokenizer.decode(outputs[0]))
199
+ ```
200
+
201
+
202
+ #### Running the model on a GPU using different precisions
203
+
204
+ * _Using `torch.float16`_
205
+
206
+ ```python
207
+ # pip install accelerate
208
+ from transformers import AutoTokenizer, AutoModelForCausalLM
209
+
210
+ tokenizer = AutoTokenizer.from_pretrained("google/gemma-7b")
211
+ model = AutoModelForCausalLM.from_pretrained("google/gemma-7b", device_map="auto", torch_dtype=torch.float16)
212
+
213
+ input_text = "Write me a poem about Machine Learning."
214
+ input_ids = tokenizer(input_text, return_tensors="pt").to("cuda")
215
+
216
+ outputs = model.generate(**input_ids)
217
+ print(tokenizer.decode(outputs[0]))
218
+ ```
219
+
220
+ * _Using `torch.bfloat16`_
221
+
222
+ ```python
223
+ # pip install accelerate
224
+ from transformers import AutoTokenizer, AutoModelForCausalLM
225
+
226
+ tokenizer = AutoTokenizer.from_pretrained("google/gemma-7b")
227
+ model = AutoModelForCausalLM.from_pretrained("google/gemma-7b", device_map="auto", torch_dtype=torch.bfloat16)
228
+
229
+ input_text = "Write me a poem about Machine Learning."
230
+ input_ids = tokenizer(input_text, return_tensors="pt").to("cuda")
231
+
232
+ outputs = model.generate(**input_ids)
233
+ print(tokenizer.decode(outputs[0]))
234
+ ```
235
+
236
+ #### Quantized Versions through `bitsandbytes`
237
+
238
+ * _Using 8-bit precision (int8)_
239
+
240
+ ```python
241
+ # pip install bitsandbytes accelerate
242
+ from transformers import AutoTokenizer, AutoModelForCausalLM, BitsAndBytesConfig
243
+
244
+ quantization_config = BitsAndBytesConfig(load_in_8bit=True)
245
+
246
+ tokenizer = AutoTokenizer.from_pretrained("google/gemma-7b")
247
+ model = AutoModelForCausalLM.from_pretrained("google/gemma-7b", quantization_config=quantization_config)
248
+
249
+ input_text = "Write me a poem about Machine Learning."
250
+ input_ids = tokenizer(input_text, return_tensors="pt").to("cuda")
251
+
252
+ outputs = model.generate(**input_ids)
253
+ print(tokenizer.decode(outputs[0]))
254
+ ```
255
+
256
+ * _Using 4-bit precision_
257
+
258
+ ```python
259
+ # pip install bitsandbytes accelerate
260
+ from transformers import AutoTokenizer, AutoModelForCausalLM, BitsAndBytesConfig
261
+
262
+ quantization_config = BitsAndBytesConfig(load_in_4bit=True)
263
+
264
+ tokenizer = AutoTokenizer.from_pretrained("google/gemma-7b")
265
+ model = AutoModelForCausalLM.from_pretrained("google/gemma-7b", quantization_config=quantization_config)
266
+
267
+ input_text = "Write me a poem about Machine Learning."
268
+ input_ids = tokenizer(input_text, return_tensors="pt").to("cuda")
269
+
270
+ outputs = model.generate(**input_ids)
271
+ print(tokenizer.decode(outputs[0]))
272
+ ```
273
+
274
+
275
+ #### Other optimizations
276
+
277
+ * _Flash Attention 2_
278
+
279
+ First make sure to install `flash-attn` in your environment `pip install flash-attn`
280
+
281
+ ```diff
282
+ model = AutoModelForCausalLM.from_pretrained(
283
+ model_id,
284
+ torch_dtype=torch.float16,
285
+ + attn_implementation="flash_attention_2"
286
+ ).to(0)
287
+ ```
288
+
289
+ ### Inputs and outputs
290
+
291
+ * **Input:** Text string, such as a question, a prompt, or a document to be
292
+ summarized.
293
+ * **Output:** Generated English-language text in response to the input, such
294
+ as an answer to a question, or a summary of a document.
295
+
296
+ ## Model Data
297
+
298
+ Data used for model training and how the data was processed.
299
+
300
+ ### Training Dataset
301
+
302
+ These models were trained on a dataset of text data that includes a wide variety
303
+ of sources, totaling 6 trillion tokens. Here are the key components:
304
+
305
+ * Web Documents: A diverse collection of web text ensures the model is exposed
306
+ to a broad range of linguistic styles, topics, and vocabulary. Primarily
307
+ English-language content.
308
+ * Code: Exposing the model to code helps it to learn the syntax and patterns of
309
+ programming languages, which improves its ability to generate code or
310
+ understand code-related questions.
311
+ * Mathematics: Training on mathematical text helps the model learn logical
312
+ reasoning, symbolic representation, and to address mathematical queries.
313
+
314
+ The combination of these diverse data sources is crucial for training a powerful
315
+ language model that can handle a wide variety of different tasks and text
316
+ formats.
317
+
318
+ ### Data Preprocessing
319
+
320
+ Here are the key data cleaning and filtering methods applied to the training
321
+ data:
322
+
323
+ * CSAM Filtering: Rigorous CSAM (Child Sexual Abuse Material) filtering was
324
+ applied at multiple stages in the data preparation process to ensure the
325
+ exclusion of harmful and illegal content
326
+ * Sensitive Data Filtering: As part of making Gemma pre-trained models safe and
327
+ reliable, automated techniques were used to filter out certain personal
328
+ information and other sensitive data from training sets.
329
+ * Additional methods: Filtering based on content quality and safely in line with
330
+ [our policies](https://storage.googleapis.com/gweb-uniblog-publish-prod/documents/2023_Google_AI_Principles_Progress_Update.pdf#page=11).
331
+
332
+ ## Implementation Information
333
+
334
+ Details about the model internals.
335
+
336
+ ### Hardware
337
+
338
+ Gemma was trained using the latest generation of
339
+ [Tensor Processing Unit (TPU)](https://cloud.google.com/tpu/docs/intro-to-tpu) hardware (TPUv5e).
340
+
341
+ Training large language models requires significant computational power. TPUs,
342
+ designed specifically for matrix operations common in machine learning, offer
343
+ several advantages in this domain:
344
+
345
+ * Performance: TPUs are specifically designed to handle the massive computations
346
+ involved in training LLMs. They can speed up training considerably compared to
347
+ CPUs.
348
+ * Memory: TPUs often come with large amounts of high-bandwidth memory, allowing
349
+ for the handling of large models and batch sizes during training. This can
350
+ lead to better model quality.
351
+ * Scalability: TPU Pods (large clusters of TPUs) provide a scalable solution for
352
+ handling the growing complexity of large foundation models. You can distribute
353
+ training across multiple TPU devices for faster and more efficient processing.
354
+ * Cost-effectiveness: In many scenarios, TPUs can provide a more cost-effective
355
+ solution for training large models compared to CPU-based infrastructure,
356
+ especially when considering the time and resources saved due to faster
357
+ training.
358
+ * These advantages are aligned with
359
+ [Google's commitments to operate sustainably](https://sustainability.google/operating-sustainably/).
360
+
361
+ ### Software
362
+
363
+ Training was done using [JAX](https://github.com/google/jax) and [ML Pathways](https://blog.google/technology/ai/introducing-pathways-next-generation-ai-architecture).
364
+
365
+ JAX allows researchers to take advantage of the latest generation of hardware,
366
+ including TPUs, for faster and more efficient training of large models.
367
+
368
+ ML Pathways is Google's latest effort to build artificially intelligent systems
369
+ capable of generalizing across multiple tasks. This is specially suitable for
370
+ [foundation models](https://ai.google/discover/foundation-models/), including large language models like
371
+ these ones.
372
+
373
+ Together, JAX and ML Pathways are used as described in the
374
+ [paper about the Gemini family of models](https://arxiv.org/abs/2312.11805); "the 'single
375
+ controller' programming model of Jax and Pathways allows a single Python
376
+ process to orchestrate the entire training run, dramatically simplifying the
377
+ development workflow."
378
+
379
+ ## Evaluation
380
+
381
+ Model evaluation metrics and results.
382
+
383
+ ### Benchmark Results
384
+
385
+ These models were evaluated against a large collection of different datasets and
386
+ metrics to cover different aspects of text generation:
387
+
388
+ | Benchmark | Metric | 2B Params | 7B Params |
389
+ | ------------------------------ | ------------- | ----------- | --------- |
390
+ | [MMLU](https://arxiv.org/abs/2009.03300) | 5-shot, top-1 | 42.3 | 64.3 |
391
+ | [HellaSwag](https://arxiv.org/abs/1905.07830) | 0-shot |71.4 | 81.2 |
392
+ | [PIQA](https://arxiv.org/abs/1911.11641) | 0-shot | 77.3 | 81.2 |
393
+ | [SocialIQA](https://arxiv.org/abs/1904.09728) | 0-shot | 59.7 | 51.8 |
394
+ | [BooIQ](https://arxiv.org/abs/1905.10044) | 0-shot | 69.4 | 83.2 |
395
+ | [WinoGrande](https://arxiv.org/abs/1907.10641) | partial score | 65.4 | 72.3 |
396
+ | [CommonsenseQA](https://arxiv.org/abs/1811.00937) | 7-shot | 65.3 | 71.3 |
397
+ | [OpenBookQA](https://arxiv.org/abs/1809.02789) | | 47.8 | 52.8 |
398
+ | [ARC-e](https://arxiv.org/abs/1911.01547) | | 73.2 | 81.5 |
399
+ | [ARC-c](https://arxiv.org/abs/1911.01547) | | 42.1 | 53.2 |
400
+ | [TriviaQA](https://arxiv.org/abs/1705.03551) | 5-shot | 53.2 | 63.4 |
401
+ | [Natural Questions](https://github.com/google-research-datasets/natural-questions) | 5-shot | - | 23 |
402
+ | [HumanEval](https://arxiv.org/abs/2107.03374) | pass@1 | 22.0 | 32.3 |
403
+ | [MBPP](https://arxiv.org/abs/2108.07732) | 3-shot | 29.2 | 44.4 |
404
+ | [GSM8K](https://arxiv.org/abs/2110.14168) | maj@1 | 17.7 | 46.4 |
405
+ | [MATH](https://arxiv.org/abs/2108.07732) | 4-shot | 11.8 | 24.3 |
406
+ | [AGIEval](https://arxiv.org/abs/2304.06364) | | 24.2 | 41.7 |
407
+ | [BIG-Bench](https://arxiv.org/abs/2206.04615) | | 35.2 | 55.1 |
408
+ | ------------------------------ | ------------- | ----------- | --------- |
409
+ | **Average** | | **54.0** | **56.4** |
410
+
411
+ ## Ethics and Safety
412
+
413
+ Ethics and safety evaluation approach and results.
414
+
415
+ ### Evaluation Approach
416
+
417
+ Our evaluation methods include structured evaluations and internal red-teaming
418
+ testing of relevant content policies. Red-teaming was conducted by a number of
419
+ different teams, each with different goals and human evaluation metrics. These
420
+ models were evaluated against a number of different categories relevant to
421
+ ethics and safety, including:
422
+
423
+ * Text-to-Text Content Safety: Human evaluation on prompts covering safety
424
+ policies including child sexual abuse and exploitation, harassment, violence
425
+ and gore, and hate speech.
426
+ * Text-to-Text Representational Harms: Benchmark against relevant academic
427
+ datasets such as [WinoBias](https://arxiv.org/abs/1804.06876) and [BBQ Dataset](https://arxiv.org/abs/2110.08193v2).
428
+ * Memorization: Automated evaluation of memorization of training data, including
429
+ the risk of personally identifiable information exposure.
430
+ * Large-scale harm: Tests for "dangerous capabilities," such as chemical,
431
+ biological, radiological, and nuclear (CBRN) risks.
432
+
433
+ ### Evaluation Results
434
+
435
+ The results of ethics and safety evaluations are within acceptable thresholds
436
+ for meeting [internal policies](https://storage.googleapis.com/gweb-uniblog-publish-prod/documents/2023_Google_AI_Principles_Progress_Update.pdf#page=11) for categories such as child
437
+ safety, content safety, representational harms, memorization, large-scale harms.
438
+ On top of robust internal evaluations, the results of well known safety
439
+ benchmarks like BBQ, BOLD, Winogender, Winobias, RealToxicity, and TruthfulQA
440
+ are shown here.
441
+
442
+ | Benchmark | Metric | 2B Params | 7B Params |
443
+ | ------------------------------ | ------------- | ----------- | --------- |
444
+ | [RealToxicity](https://arxiv.org/abs/2009.11462) | average | 6.86 | 7.90 |
445
+ | [BOLD](https://arxiv.org/abs/2101.11718) | | 45.57 | 49.08 |
446
+ | [CrowS-Pairs](https://aclanthology.org/2020.emnlp-main.154/) | top-1 | 45.82 | 51.33 |
447
+ | [BBQ Ambig](https://arxiv.org/abs/2110.08193v2) | 1-shot, top-1 | 62.58 | 92.54 |
448
+ | [BBQ Disambig](https://arxiv.org/abs/2110.08193v2) | top-1 | 54.62 | 71.99 |
449
+ | [Winogender](https://arxiv.org/abs/1804.09301) | top-1 | 51.25 | 54.17 |
450
+ | [TruthfulQA](https://arxiv.org/abs/2109.07958) | | 44.84 | 31.81 |
451
+ | [Winobias 1_2](https://arxiv.org/abs/1804.06876) | | 56.12 | 59.09 |
452
+ | [Winobias 2_2](https://arxiv.org/abs/1804.06876) | | 91.10 | 92.23 |
453
+ | [Toxigen](https://arxiv.org/abs/2203.09509) | | 29.77 | 39.59 |
454
+ | ------------------------------ | ------------- | ----------- | --------- |
455
+
456
+
457
+ ## Usage and Limitations
458
+
459
+ These models have certain limitations that users should be aware of.
460
+
461
+ ### Intended Usage
462
+
463
+ Open Large Language Models (LLMs) have a wide range of applications across
464
+ various industries and domains. The following list of potential uses is not
465
+ comprehensive. The purpose of this list is to provide contextual information
466
+ about the possible use-cases that the model creators considered as part of model
467
+ training and development.
468
+
469
+ * Content Creation and Communication
470
+ * Text Generation: These models can be used to generate creative text formats
471
+ such as poems, scripts, code, marketing copy, and email drafts.
472
+ * Chatbots and Conversational AI: Power conversational interfaces for customer
473
+ service, virtual assistants, or interactive applications.
474
+ * Text Summarization: Generate concise summaries of a text corpus, research
475
+ papers, or reports.
476
+ * Research and Education
477
+ * Natural Language Processing (NLP) Research: These models can serve as a
478
+ foundation for researchers to experiment with NLP techniques, develop
479
+ algorithms, and contribute to the advancement of the field.
480
+ * Language Learning Tools: Support interactive language learning experiences,
481
+ aiding in grammar correction or providing writing practice.
482
+ * Knowledge Exploration: Assist researchers in exploring large bodies of text
483
+ by generating summaries or answering questions about specific topics.
484
+
485
+ ### Limitations
486
+
487
+ * Training Data
488
+ * The quality and diversity of the training data significantly influence the
489
+ model's capabilities. Biases or gaps in the training data can lead to
490
+ limitations in the model's responses.
491
+ * The scope of the training dataset determines the subject areas the model can
492
+ handle effectively.
493
+ * Context and Task Complexity
494
+ * LLMs are better at tasks that can be framed with clear prompts and
495
+ instructions. Open-ended or highly complex tasks might be challenging.
496
+ * A model's performance can be influenced by the amount of context provided
497
+ (longer context generally leads to better outputs, up to a certain point).
498
+ * Language Ambiguity and Nuance
499
+ * Natural language is inherently complex. LLMs might struggle to grasp subtle
500
+ nuances, sarcasm, or figurative language.
501
+ * Factual Accuracy
502
+ * LLMs generate responses based on information they learned from their
503
+ training datasets, but they are not knowledge bases. They may generate
504
+ incorrect or outdated factual statements.
505
+ * Common Sense
506
+ * LLMs rely on statistical patterns in language. They might lack the ability
507
+ to apply common sense reasoning in certain situations.
508
+
509
+ ### Ethical Considerations and Risks
510
 
511
+ The development of large language models (LLMs) raises several ethical concerns.
512
+ In creating an open model, we have carefully considered the following:
513
 
514
+ * Bias and Fairness
515
+ * LLMs trained on large-scale, real-world text data can reflect socio-cultural
516
+ biases embedded in the training material. These models underwent careful
517
+ scrutiny, input data pre-processing described and posterior evaluations
518
+ reported in this card.
519
+ * Misinformation and Misuse
520
+ * LLMs can be misused to generate text that is false, misleading, or harmful.
521
+ * Guidelines are provided for responsible use with the model, see the
522
+ [Responsible Generative AI Toolkit](http://ai.google.dev/gemma/responsible).
523
+ * Transparency and Accountability:
524
+ * This model card summarizes details on the models' architecture,
525
+ capabilities, limitations, and evaluation processes.
526
+ * A responsibly developed open model offers the opportunity to share
527
+ innovation by making LLM technology accessible to developers and researchers
528
+ across the AI ecosystem.
529
 
530
+ Risks identified and mitigations:
531
 
532
+ * Perpetuation of biases: It's encouraged to perform continuous monitoring
533
+ (using evaluation metrics, human review) and the exploration of de-biasing
534
+ techniques during model training, fine-tuning, and other use cases.
535
+ * Generation of harmful content: Mechanisms and guidelines for content safety
536
+ are essential. Developers are encouraged to exercise caution and implement
537
+ appropriate content safety safeguards based on their specific product policies
538
+ and application use cases.
539
+ * Misuse for malicious purposes: Technical limitations and developer and
540
+ end-user education can help mitigate against malicious applications of LLMs.
541
+ Educational resources and reporting mechanisms for users to flag misuse are
542
+ provided. Prohibited uses of Gemma models are outlined in the
543
+ [Gemma Prohibited Use Policy](https://ai.google.dev/gemma/prohibited_use_policy).
544
+ * Privacy violations: Models were trained on data filtered for removal of PII
545
+ (Personally Identifiable Information). Developers are encouraged to adhere to
546
+ privacy regulations with privacy-preserving techniques.
547
 
548
  ## Training procedure
549