GuardwallAI commited on
Commit
d6d97ac
1 Parent(s): c6931fb

Upload README.md with huggingface_hub

Browse files
Files changed (1) hide show
  1. README.md +229 -0
README.md ADDED
@@ -0,0 +1,229 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ ---
2
+ base_model: meta-llama/Llama-Guard-3-8B
3
+ language:
4
+ - en
5
+ license: llama3.1
6
+ pipeline_tag: text-generation
7
+ tags:
8
+ - facebook
9
+ - meta
10
+ - pytorch
11
+ - llama
12
+ - llama-3
13
+ - llama-cpp
14
+ - gguf-my-repo
15
+ extra_gated_prompt: "### LLAMA 3.1 COMMUNITY LICENSE AGREEMENT\nLlama 3.1 Version\
16
+ \ Release Date: July 23, 2024\n\"Agreement\" means the terms and conditions for\
17
+ \ use, reproduction, distribution and modification of the Llama Materials set forth\
18
+ \ herein.\n\"Documentation\" means the specifications, manuals and documentation\
19
+ \ accompanying Llama 3.1 distributed by Meta at https://llama.meta.com/doc/overview.\n\
20
+ \"Licensee\" or \"you\" means you, or your employer or any other person or entity\
21
+ \ (if you are entering into this Agreement on such person or entity’s behalf), of\
22
+ \ the age required under applicable laws, rules or regulations to provide legal\
23
+ \ consent and that has legal authority to bind your employer or such other person\
24
+ \ or entity if you are entering in this Agreement on their behalf.\n\"Llama 3.1\"\
25
+ \ means the foundational large language models and software and algorithms, including\
26
+ \ machine-learning model code, trained model weights, inference-enabling code, training-enabling\
27
+ \ code, fine-tuning enabling code and other elements of the foregoing distributed\
28
+ \ by Meta at https://llama.meta.com/llama-downloads.\n\"Llama Materials\" means,\
29
+ \ collectively, Meta’s proprietary Llama 3.1 and Documentation (and any portion\
30
+ \ thereof) made available under this Agreement.\n\"Meta\" or \"we\" means Meta Platforms\
31
+ \ Ireland Limited (if you are located in or, if you are an entity, your principal\
32
+ \ place of business is in the EEA or Switzerland) and Meta Platforms, Inc. (if you\
33
+ \ are located outside of the EEA or Switzerland).\n \n1. License Rights and Redistribution.\n\
34
+ a. Grant of Rights. You are granted a non-exclusive, worldwide, non-transferable\
35
+ \ and royalty-free limited license under Meta’s intellectual property or other rights\
36
+ \ owned by Meta embodied in the Llama Materials to use, reproduce, distribute, copy,\
37
+ \ create derivative works of, and make modifications to the Llama Materials.\nb.\
38
+ \ Redistribution and Use.\ni. If you distribute or make available the Llama Materials\
39
+ \ (or any derivative works thereof), or a product or service (including another\
40
+ \ AI model) that contains any of them, you shall (A) provide a copy of this Agreement\
41
+ \ with any such Llama Materials; and (B) prominently display “Built with Llama”\
42
+ \ on a related website, user interface, blogpost, about page, or product documentation.\
43
+ \ If you use the Llama Materials or any outputs or results of the Llama Materials\
44
+ \ to create, train, fine tune, or otherwise improve an AI model, which is distributed\
45
+ \ or made available, you shall also include “Llama” at the beginning of any such\
46
+ \ AI model name.\nii. If you receive Llama Materials, or any derivative works thereof,\
47
+ \ from a Licensee as part of an integrated end user product, then Section 2 of\
48
+ \ this Agreement will not apply to you.\niii. You must retain in all copies of the\
49
+ \ Llama Materials that you distribute the following attribution notice within a\
50
+ \ “Notice” text file distributed as a part of such copies: “Llama 3.1 is licensed\
51
+ \ under the Llama 3.1 Community License, Copyright © Meta Platforms, Inc. All Rights\
52
+ \ Reserved.”\niv. Your use of the Llama Materials must comply with applicable laws\
53
+ \ and regulations (including trade compliance laws and regulations) and adhere to\
54
+ \ the Acceptable Use Policy for the Llama Materials (available at https://llama.meta.com/llama3_1/use-policy),\
55
+ \ which is hereby incorporated by reference into this Agreement.\n2. Additional\
56
+ \ Commercial Terms. If, on the Llama 3.1 version release date, the monthly active\
57
+ \ users of the products or services made available by or for Licensee, or Licensee’s\
58
+ \ affiliates, is greater than 700 million monthly active users in the preceding\
59
+ \ calendar month, you must request a license from Meta, which Meta may grant to\
60
+ \ you in its sole discretion, and you are not authorized to exercise any of the\
61
+ \ rights under this Agreement unless or until Meta otherwise expressly grants you\
62
+ \ such rights.\n3. Disclaimer of Warranty. UNLESS REQUIRED BY APPLICABLE LAW, THE\
63
+ \ LLAMA MATERIALS AND ANY OUTPUT AND RESULTS THEREFROM ARE PROVIDED ON AN “AS IS”\
64
+ \ BASIS, WITHOUT WARRANTIES OF ANY KIND, AND META DISCLAIMS ALL WARRANTIES OF ANY\
65
+ \ KIND, BOTH EXPRESS AND IMPLIED, INCLUDING, WITHOUT LIMITATION, ANY WARRANTIES\
66
+ \ OF TITLE, NON-INFRINGEMENT, MERCHANTABILITY, OR FITNESS FOR A PARTICULAR PURPOSE.\
67
+ \ YOU ARE SOLELY RESPONSIBLE FOR DETERMINING THE APPROPRIATENESS OF USING OR REDISTRIBUTING\
68
+ \ THE LLAMA MATERIALS AND ASSUME ANY RISKS ASSOCIATED WITH YOUR USE OF THE LLAMA\
69
+ \ MATERIALS AND ANY OUTPUT AND RESULTS.\n4. Limitation of Liability. IN NO EVENT\
70
+ \ WILL META OR ITS AFFILIATES BE LIABLE UNDER ANY THEORY OF LIABILITY, WHETHER IN\
71
+ \ CONTRACT, TORT, NEGLIGENCE, PRODUCTS LIABILITY, OR OTHERWISE, ARISING OUT OF THIS\
72
+ \ AGREEMENT, FOR ANY LOST PROFITS OR ANY INDIRECT, SPECIAL, CONSEQUENTIAL, INCIDENTAL,\
73
+ \ EXEMPLARY OR PUNITIVE DAMAGES, EVEN IF META OR ITS AFFILIATES HAVE BEEN ADVISED\
74
+ \ OF THE POSSIBILITY OF ANY OF THE FOREGOING.\n5. Intellectual Property.\na. No\
75
+ \ trademark licenses are granted under this Agreement, and in connection with the\
76
+ \ Llama Materials, neither Meta nor Licensee may use any name or mark owned by or\
77
+ \ associated with the other or any of its affiliates, except as required for reasonable\
78
+ \ and customary use in describing and redistributing the Llama Materials or as set\
79
+ \ forth in this Section 5(a). Meta hereby grants you a license to use “Llama” (the\
80
+ \ “Mark”) solely as required to comply with the last sentence of Section 1.b.i.\
81
+ \ You will comply with Meta’s brand guidelines (currently accessible at https://about.meta.com/brand/resources/meta/company-brand/\
82
+ \ ). All goodwill arising out of your use of the Mark will inure to the benefit\
83
+ \ of Meta.\nb. Subject to Meta’s ownership of Llama Materials and derivatives made\
84
+ \ by or for Meta, with respect to any derivative works and modifications of the\
85
+ \ Llama Materials that are made by you, as between you and Meta, you are and will\
86
+ \ be the owner of such derivative works and modifications.\nc. If you institute\
87
+ \ litigation or other proceedings against Meta or any entity (including a cross-claim\
88
+ \ or counterclaim in a lawsuit) alleging that the Llama Materials or Llama 3.1 outputs\
89
+ \ or results, or any portion of any of the foregoing, constitutes infringement of\
90
+ \ intellectual property or other rights owned or licensable by you, then any licenses\
91
+ \ granted to you under this Agreement shall terminate as of the date such litigation\
92
+ \ or claim is filed or instituted. You will indemnify and hold harmless Meta from\
93
+ \ and against any claim by any third party arising out of or related to your use\
94
+ \ or distribution of the Llama Materials.\n6. Term and Termination. The term of\
95
+ \ this Agreement will commence upon your acceptance of this Agreement or access\
96
+ \ to the Llama Materials and will continue in full force and effect until terminated\
97
+ \ in accordance with the terms and conditions herein. Meta may terminate this Agreement\
98
+ \ if you are in breach of any term or condition of this Agreement. Upon termination\
99
+ \ of this Agreement, you shall delete and cease use of the Llama Materials. Sections\
100
+ \ 3, 4 and 7 shall survive the termination of this Agreement.\n7. Governing Law\
101
+ \ and Jurisdiction. This Agreement will be governed and construed under the laws\
102
+ \ of the State of California without regard to choice of law principles, and the\
103
+ \ UN Convention on Contracts for the International Sale of Goods does not apply\
104
+ \ to this Agreement. The courts of California shall have exclusive jurisdiction\
105
+ \ of any dispute arising out of this Agreement.\n### Llama 3.1 Acceptable Use Policy\n\
106
+ Meta is committed to promoting safe and fair use of its tools and features, including\
107
+ \ Llama 3.1. If you access or use Llama 3.1, you agree to this Acceptable Use Policy\
108
+ \ (“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\
109
+ #### Prohibited Uses\nWe want everyone to use Llama 3.1 safely and responsibly.\
110
+ \ You agree you will not use, or allow others to use, Llama 3.1 to:\n 1. Violate\
111
+ \ the law or others’ rights, including to:\n 1. Engage in, promote, generate,\
112
+ \ contribute to, encourage, plan, incite, or further illegal or unlawful activity\
113
+ \ or content, such as:\n 1. Violence or terrorism\n 2. Exploitation\
114
+ \ or harm to children, including the solicitation, creation, acquisition, or dissemination\
115
+ \ of child exploitative content or failure to report Child Sexual Abuse Material\n\
116
+ \ 3. Human trafficking, exploitation, and sexual violence\n 4. The\
117
+ \ illegal distribution of information or materials to minors, including obscene\
118
+ \ materials, or failure to employ legally required age-gating in connection with\
119
+ \ such information or materials.\n 5. Sexual solicitation\n 6. Any\
120
+ \ other criminal activity\n 3. Engage in, promote, incite, or facilitate the\
121
+ \ harassment, abuse, threatening, or bullying of individuals or groups of individuals\n\
122
+ \ 4. Engage in, promote, incite, or facilitate discrimination or other unlawful\
123
+ \ or harmful conduct in the provision of employment, employment benefits, credit,\
124
+ \ housing, other economic benefits, or other essential goods and services\n 5.\
125
+ \ Engage in the unauthorized or unlicensed practice of any profession including,\
126
+ \ but not limited to, financial, legal, medical/health, or related professional\
127
+ \ practices\n 6. Collect, process, disclose, generate, or infer health, demographic,\
128
+ \ or other sensitive personal or private information about individuals without rights\
129
+ \ and consents required by applicable laws\n 7. Engage in or facilitate any action\
130
+ \ or generate any content that infringes, misappropriates, or otherwise violates\
131
+ \ any third-party rights, including the outputs or results of any products or services\
132
+ \ using the Llama Materials\n 8. Create, generate, or facilitate the creation\
133
+ \ of malicious code, malware, computer viruses or do anything else that could disable,\
134
+ \ overburden, interfere with or impair the proper working, integrity, operation\
135
+ \ or appearance of a website or computer system\n2. Engage in, promote, incite,\
136
+ \ facilitate, or assist in the planning or development of activities that present\
137
+ \ a risk of death or bodily harm to individuals, including use of Llama 3.1 related\
138
+ \ to the following:\n 1. Military, warfare, nuclear industries or applications,\
139
+ \ espionage, use for materials or activities that are subject to the International\
140
+ \ Traffic Arms Regulations (ITAR) maintained by the United States Department of\
141
+ \ State\n 2. Guns and illegal weapons (including weapon development)\n 3.\
142
+ \ Illegal drugs and regulated/controlled substances\n 4. Operation of critical\
143
+ \ infrastructure, transportation technologies, or heavy machinery\n 5. Self-harm\
144
+ \ or harm to others, including suicide, cutting, and eating disorders\n 6. Any\
145
+ \ content intended to incite or promote violence, abuse, or any infliction of bodily\
146
+ \ harm to an individual\n3. Intentionally deceive or mislead others, including use\
147
+ \ of Llama 3.1 related to the following:\n 1. Generating, promoting, or furthering\
148
+ \ fraud or the creation or promotion of disinformation\n 2. Generating, promoting,\
149
+ \ or furthering defamatory content, including the creation of defamatory statements,\
150
+ \ images, or other content\n 3. Generating, promoting, or further distributing\
151
+ \ spam\n 4. Impersonating another individual without consent, authorization,\
152
+ \ or legal right\n 5. Representing that the use of Llama 3.1 or outputs are human-generated\n\
153
+ \ 6. Generating or facilitating false online engagement, including fake reviews\
154
+ \ and other means of fake online engagement\n4. Fail to appropriately disclose to\
155
+ \ end users any known dangers of your AI system\nPlease report any violation of\
156
+ \ this Policy, software “bug,” or other problems that could lead to a violation\
157
+ \ of this Policy through one of the following means:\n * Reporting issues with\
158
+ \ the model: [https://github.com/meta-llama/llama-models/issues](https://github.com/meta-llama/llama-models/issues)\n\
159
+ \ * Reporting risky content generated by the model:\n developers.facebook.com/llama_output_feedback\n\
160
+ \ * Reporting bugs and security concerns: facebook.com/whitehat/info\n * Reporting\
161
+ \ violations of the Acceptable Use Policy or unlicensed uses of Meta Llama 3: [email protected]"
162
+ extra_gated_fields:
163
+ First Name: text
164
+ Last Name: text
165
+ Date of birth: date_picker
166
+ Country: country
167
+ Affiliation: text
168
+ Job title:
169
+ type: select
170
+ options:
171
+ - Student
172
+ - Research Graduate
173
+ - AI researcher
174
+ - AI developer/engineer
175
+ - Reporter
176
+ - Other
177
+ geo: ip_location
178
+ ? By clicking Submit below I accept the terms of the license and acknowledge that
179
+ the information I provide will be collected stored processed and shared in accordance
180
+ with the Meta Privacy Policy
181
+ : checkbox
182
+ extra_gated_description: The information you provide will be collected, stored, processed
183
+ and shared in accordance with the [Meta Privacy Policy](https://www.facebook.com/privacy/policy/).
184
+ extra_gated_button_content: Submit
185
+ ---
186
+
187
+ # GuardwallAI/Llama-Guard-3-8B-Q4_K_M-GGUF
188
+ This model was converted to GGUF format from [`meta-llama/Llama-Guard-3-8B`](https://huggingface.co/meta-llama/Llama-Guard-3-8B) using llama.cpp via the ggml.ai's [GGUF-my-repo](https://huggingface.co/spaces/ggml-org/gguf-my-repo) space.
189
+ Refer to the [original model card](https://huggingface.co/meta-llama/Llama-Guard-3-8B) for more details on the model.
190
+
191
+ ## Use with llama.cpp
192
+ Install llama.cpp through brew (works on Mac and Linux)
193
+
194
+ ```bash
195
+ brew install llama.cpp
196
+
197
+ ```
198
+ Invoke the llama.cpp server or the CLI.
199
+
200
+ ### CLI:
201
+ ```bash
202
+ llama-cli --hf-repo GuardwallAI/Llama-Guard-3-8B-Q4_K_M-GGUF --hf-file llama-guard-3-8b-q4_k_m.gguf -p "The meaning to life and the universe is"
203
+ ```
204
+
205
+ ### Server:
206
+ ```bash
207
+ llama-server --hf-repo GuardwallAI/Llama-Guard-3-8B-Q4_K_M-GGUF --hf-file llama-guard-3-8b-q4_k_m.gguf -c 2048
208
+ ```
209
+
210
+ Note: You can also use this checkpoint directly through the [usage steps](https://github.com/ggerganov/llama.cpp?tab=readme-ov-file#usage) listed in the Llama.cpp repo as well.
211
+
212
+ Step 1: Clone llama.cpp from GitHub.
213
+ ```
214
+ git clone https://github.com/ggerganov/llama.cpp
215
+ ```
216
+
217
+ Step 2: Move into the llama.cpp folder and build it with `LLAMA_CURL=1` flag along with other hardware-specific flags (for ex: LLAMA_CUDA=1 for Nvidia GPUs on Linux).
218
+ ```
219
+ cd llama.cpp && LLAMA_CURL=1 make
220
+ ```
221
+
222
+ Step 3: Run inference through the main binary.
223
+ ```
224
+ ./llama-cli --hf-repo GuardwallAI/Llama-Guard-3-8B-Q4_K_M-GGUF --hf-file llama-guard-3-8b-q4_k_m.gguf -p "The meaning to life and the universe is"
225
+ ```
226
+ or
227
+ ```
228
+ ./llama-server --hf-repo GuardwallAI/Llama-Guard-3-8B-Q4_K_M-GGUF --hf-file llama-guard-3-8b-q4_k_m.gguf -c 2048
229
+ ```