Code Monkey home page Code Monkey logo

llama-models's Introduction

🤗 Models on Hugging Face  | Blog  | Website  | Get Started 


Llama Models

PyPI - Downloads Discord

Llama is an accessible, open large language model (LLM) designed for developers, researchers, and businesses to build, experiment, and responsibly scale their generative AI ideas. Part of a foundational system, it serves as a bedrock for innovation in the global community. A few key aspects:

  1. Open access: Easy accessibility to cutting-edge large language models, fostering collaboration and advancements among developers, researchers, and organizations
  2. Broad ecosystem: Llama models have been downloaded hundreds of millions of times, there are thousands of community projects built on Llama and platform support is broad from cloud providers to startups - the world is building with Llama!
  3. Trust & safety: Llama models are part of a comprehensive approach to trust and safety, releasing models and tools that are designed to enable community collaboration and encourage the standardization of the development and usage of trust and safety tools for generative AI

Our mission is to empower individuals and industry through this opportunity while fostering an environment of discovery and ethical AI advancements. The model weights are licensed for researchers and commercial entities, upholding the principles of openness.

Llama Models

Model Launch date Model sizes Context Length Tokenizer Acceptable use policy License Model Card
Llama 2 7/18/2023 7B, 13B, 70B 4K Sentencepiece Use Policy License Model Card
Llama 3 4/18/2024 8B, 70B 8K TikToken-based Use Policy License Model Card
Llama 3.1 7/23/2024 8B, 70B, 405B 128K TikToken-based Use Policy License Model Card

Download

To download the model weights and tokenizer, please visit the Meta Llama website and accept our License.

Once your request is approved, you will receive a signed URL over email. Then, run the download.sh script, passing the URL provided when prompted to start the download.

Pre-requisites: Ensure you have wget and md5sum installed. Then run the script: ./download.sh. ./download.shcan be found inside the respective models directory.

Remember that the links expire after 24 hours and a certain amount of downloads. You can always re-request a link if you start seeing errors such as 403: Forbidden.

Access to Hugging Face

We also provide downloads on Hugging Face, in both transformers and native llama3 formats. To download the weights from Hugging Face, please follow these steps:

  • Visit one of the repos, for example meta-llama/Meta-Llama-3.1-8B-Instruct.
  • Read and accept the license. Once your request is approved, you'll be granted access to all Llama 3.1 models as well as previous versions. Note that requests used to take up to one hour to get processed.
  • To download the original native weights to use with this repo, click on the "Files and versions" tab and download the contents of the original folder. You can also download them from the command line if you pip install huggingface-hub:
huggingface-cli download meta-llama/Meta-Llama-3.1-8B-Instruct --include "original/*" --local-dir meta-llama/Meta-Llama-3.1-8B-Instruct

NOTE The original native weights of meta-llama/Meta-Llama-3.1-405B would not be available through this HugginFace repo.

  • To use with transformers, the following pipeline snippet will download and cache the weights:

    import transformers
    import torch
    
    model_id = "meta-llama/Meta-Llama-3.1-8B-Instruct"
    
    pipeline = transformers.pipeline(
      "text-generation",
      model="meta-llama/Meta-Llama-3.1-8B-Instruct",
      model_kwargs={"torch_dtype": torch.bfloat16},
      device="cuda",
    )

Installations

You can install this repository as a package by just doing pip install llama-models

Responsible Use

Llama models are a new technology that carries potential risks with use. Testing conducted to date has not — and could not — cover all scenarios. To help developers address these risks, we have created the Responsible Use Guide.

Issues

Please report any software “bug” or other problems with the models through one of the following means:

Questions

For common questions, the FAQ can be found here, which will be updated over time as new questions arise.

llama-models's People

Contributors

jspisak avatar dltn avatar rohit-ptl avatar samuelselvan avatar machina-source avatar wukaixingxp avatar hardikjshah avatar derrix060 avatar knibesh avatar wysuperfly avatar

Stargazers

Justin Spryce avatar Pavlo Sidelov avatar  avatar DQ avatar  avatar  avatar Amine avatar EXSLER avatar Giuliano Wetter Floriani avatar Andrey Tytskiy avatar I_Am_Tekla avatar Jinsung Ha avatar  avatar Noah Haf avatar  avatar  avatar Artur avatar  avatar Shashwat Kumar avatar Zorro Albert avatar Thiago Rodrigues avatar Jeon Joonyong avatar  avatar Naveen R avatar Jason Van avatar varoriya avatar Meimingwei Li avatar Goh Jia Yi, Jesa avatar  avatar  avatar Denis Balan avatar FengU avatar Bill Xue avatar NAVEENRAJ K avatar  avatar Shayan Salehian avatar Imad-Eddine NACIRI avatar 清元子 avatar  avatar alaasumrain avatar  avatar Pete Dillon avatar Dreamforce avatar HolyShit avatar Astra A avatar Nick Ragan avatar  avatar  avatar 陈浩 avatar 於琦 avatar Thien.Trinh.Coder avatar Raj Kollimarla avatar zhangmian avatar ChanMo avatar  avatar AciGo avatar Jason Thomas Horn avatar Zhang Jiahui avatar Rui Malheiro avatar Yohan Na avatar Mustafa Savul avatar McflyBull  avatar eiki avatar Soon Chee Loong avatar Ashok avatar  avatar keke avatar Oscar Neto avatar Diego Garrido avatar Till Zoppke avatar Hui (Henry) Chen avatar Nick Brenner avatar Alex Filatov avatar Abderrezak avatar metaaaa avatar Kian avatar 김재덕 avatar Kala avatar Shyamsundar Shrestha avatar Sam Banankhu avatar Shoei avatar  avatar Siddharth Gupta avatar  avatar  avatar Dolar Jay avatar  avatar  avatar  avatar  avatar  avatar Itagn掌门 avatar Guilherme avatar angleboy avatar rodrigo de oliveira costa avatar Naveen P Nair avatar Joshua_qiu avatar Yoel Ridgway-Lopez avatar Afonso Diela avatar sungkyun avatar

Watchers

Ashwin Bharambe avatar Lucian avatar Roshan Sumbaly avatar Vishal Goklani avatar Qubitium-ModelCloud avatar Ryan Fox avatar  avatar  avatar Hudson Brendon avatar hhhaiai avatar  avatar  avatar  avatar  avatar ZJ avatar  avatar Andrew J Brush avatar AKai avatar David Sun avatar Abdullah Aml avatar domib97 avatar Yashas Donthi avatar Alessio Regalbuto avatar Jake Lyman avatar  avatar  avatar  avatar João Pedro Gabriel avatar  avatar EXSLER avatar Devara Alandra W. avatar Vaibhav Yadav avatar  avatar  avatar  avatar

llama-models's Issues

Download link broken for Llama 3.1-405b-Instruct FP8

Hello,

I'm able to download the other checkpoint formats for Llama 3.1-405b-Instruct. However, when I try to download the fp8 weights it sends a request to this URL (after successfully downloading the tokenizer)

https://llama3-1.llamameta.net/Meta-Llama-3.1-405B-Instruct/consolidated.00.pth?Policy=[...]&Signature=[...]&Key-Pair-Id=[...]&Download-Request-ID=[...]

And this request returns HTTP Error 400.

Additionally, I believe there is a typo in the script (it says fb8 in one place instead of fp8). See here: chotzen@30abaac

Please let me know if there is any more information you need to help reproduce this.

PyPI Not Updated Causing llama_toolchain CLI to Fail

Issue Summary

The recent change in commit 1dfcbc787681fe9768ecc729ca80737532e3567d is causing the llama model template CLI command to fail on the main branch of llama-toolchain.

Root Cause

The current PyPI version of llama-models (0.0.1) does not include the latest changes from the main branch of this repo. As a result, installing llama-toolchain does not fetch these necessary updates.

Request

Could someone please push a new version of llama-models to PyPI to include the latest changes?

Download script fails with "403 Forbidden" error

I encountered an issue while attempting to download specific models using the provided download.sh script. The script successfully downloads the LICENSE file but fails to download the Use Policy file, resulting in a "403 Forbidden" error. Below are the details of the error and the steps I followed.

Steps to Reproduce:

Run the download.sh script.
Enter the provided URL: XXX
Enter the list of models to download: 8B,8B-instruct

The script should successfully download the LICENSE and Use Policy files and proceed to download the specified models.

Actual Result:

The LICENSE file is downloaded successfully.
The script fails to download the Use Policy file, returning a "403 Forbidden" error.

Logs/Output:

shell

--2024-07-28 11:29:57-- https://llama3-1.llamameta.net/LICENSE?XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
Resolving llama3-1.llamameta.net (llama3-1.llamameta.net)... 18.239.69.95, 18.239.69.68, 18.239.69.73, ...
Connecting to llama3-1.llamameta.net (llama3-1.llamameta.net)|18.239.69.95|:443... connected.
HTTP request sent, awaiting response... 416 Requested Range Not Satisfiable

The file is already fully retrieved; nothing to do.

--2024-07-28 11:29:57-- https://llama3-1.llamameta.net/USE_POLICY?XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
Resolving llama3-1.llamameta.net (llama3-1.llamameta.net)... 18.239.69.68, 18.239.69.95, 18.239.69.73, ...
Connecting to llama3-1.llamameta.net (llama3-1.llamameta.net)|18.239.69.68|:443... connected.
HTTP request sent, awaiting response... 403 Forbidden
2024-07-28 11:29:58 ERROR 403: Forbidden.

Environment:

OS: LINUX UBUNTU

Please let me know if any further information is required or if there are additional steps I can take to troubleshoot this issue.

Windows users cannot download Llama models!!

I got bash, wget, md5sum but it gets connection error. Same issue was with earlier version now with 3.1 launch. Why you guys don't make windows specific download methods. I am sure lots of windows users are turning away because of this issue.

issues installing llama-3.1-70b on Mac

Hello.
I've been trying to install llama-3.1-70b on my Mac locally.
after following all the instructions, and installing all the missing packages, after choosing model and hitting enter, I get the following error message:

Reusing existing connection to urldefense.com:443.
HTTP request sent, awaiting response... 400 Bad Request
2024-07-29 16:23:28 ERROR 400: Bad Request.

please help!

Error while running bash ./download.sh command

Running on WSL2 ubuntu 20.04
python - 3.8
Installed all required dependencies.
when doing bash ./download.sh, following error occurs ->

./download.sh: line 2: $'\r': command not found
./download.sh: line 9: $'\r': command not found
./download.sh: line 12: $'\r': command not found
: invalid optionine 13: set: -
set: usage: set [-abefhkmnptuvxBCHP] [-o option-name] [--] [arg ...]
./download.sh: line 14: $'\r': command not found
': not a valid identifieread: `PRESIGNED_URL

**** Model list ***
./download.sh: line 19: syntax error near unexpected token $'do\r'' '/download.sh: line 19: do

How does Llama3.1 actually finish NIAH task during pre-training?

Great work! I still have some questions about the long context evaluation during pre-training.

From section 3.4.2 of the paper, you said We assess successful adaptation by measuring whether (1) model performance on short-context evaluations has recovered completely and (2) the model perfectly solves “needle in a haystack” tasks up to that length.

So how you made it? NIAH is a task that requires the model to have instruction-following capability, but as we all know, during pre-training the base model does not have the instruction-following capability. Could you please share more details about this or provide more experiments details such as the prompt or generation config?

Thanks a lot.

Why are you doing this?

Just make the models available in a simpler fashion so we stop running into errors like every single release.

Reusing existing connection to llama3-1.llamameta.net:443.
HTTP request sent, awaiting response... 403 Forbidden.
2024-07-23 22:27:32 ERROR 403: Forbidden..

Meta-Llama-3.1-405B-Instruct-MP16 init error

Cannot instantiate 405B model.

Pseudocode below (omitting details on process group init). Running with 16 ranks to match model parallelism expected for this model (per model_parallel_size in sku_list)

from fairscale.nn.model_parallel.initialize import initialize_model_parallel
from model import ModelArgs, Transformer
from torch.distributed import init_process_group

init_process_group(...)
initialize_model_parallel(16)  # world_size=16

model_args = ModelArgs(**{
    "dim": 16384,
    "n_layers": 126,
    "n_heads": 128,
    "n_kv_heads": 8,
    "vocab_size": 128256,
    "ffn_dim_multiplier": 1.2,
    "multiple_of": 4096,
    "norm_eps": 1e-05,
    "rope_theta": 500000.0,
    "use_scaled_rope": True,
})
model = Transformer(model_args)

Error:

[rank15]: Traceback (most recent call last):
[rank15]:   File "/home/pavel/llama_inference.py", line 38, in <module>
[rank15]:     model = Transformer(model_args)
[rank15]:             ^^^^^^^^^^^^^^^^^^^^^^^
[rank15]:   File "/home/pavel/model.py", line 304, in __init__
[rank15]:     self.layers.append(TransformerBlock(layer_id, params))
[rank15]:                        ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[rank15]:   File "/home/pavel/model.py", line 268, in __init__
[rank15]:     self.attention = Attention(args)
[rank15]:                      ^^^^^^^^^^^^^^^
[rank15]:   File "/home/pavel/model.py", line 137, in __init__
[rank15]:     self.n_rep = self.n_local_heads // self.n_local_kv_heads
[rank15]:                  ~~~~~~~~~~~~~~~~~~~^^~~~~~~~~~~~~~~~~~~~~~~
[rank15]: ZeroDivisionError: integer division or modulo by zero

Seems like division of n_kv_heads = 8 here by model_parallel_size = 16 per this value leads to self.n_local_kv_heads = 0

I keep getting 403 Forbidden even when using a URL/Token that was just generated

I keep getting the bellow error when running the download.sh script. I made sure to have a new URL/token that we just generated.

Connecting to llama3-1.llamameta.net (llama3-1.llamameta.net)|18.238.55.91|:443... connected.
HTTP request sent, awaiting response... 403 Forbidden
2024-07-24 08:23:53 ERROR 403: Forbidden.

Guia orientando massagem nos pés com título prazeres nos pés

Descreva criativos para uma campanha de venda online como guia sensual "Prazeres nos Pés."
Elabore uma estratégia de VSL para crianção de uma landing page de alta conversão.
Elabore estratégias de marketing para captação de leads qualificados para compra deste guia.
Sugira imagens para estes criativos e vídeos com legendas.
Cite 5 tipos de copys para incrementar a vontade do lead de comprar mesmo antes de terminar os criativos envolvendo a escassez.
Chamada para ação com objetivo de ser único ao aprender está técnica que pode apimentar a relação do casal ou chegar com mais conteúdo aprimorando as preliminares podendo usar como carta na manga na hora H.

Prompt in jinja and interface.py inconsistent

if builtin_tools:
content += "Environment: ipython\n"
tool_str = ", ".join(
[t.value for t in builtin_tools if t != BuiltinTool.code_interpreter]
)
if tool_str:
content += f"Tools: {tool_str}\n"

{% if builtin_tools or custom_tools -%}
Environment: ipython

I found that the prompts in these two files are inconsistent, which one should I use?

Character Spacing Bypass in Prompt-Guard-86M Classifier

Hi, we're writing to report a potential exploit in the Prompt-Guard-86M classifier that allows for bypassing its safety measures. At Robust Intelligence, we discovered this issue while analyzing embedding weight differences between the Prompt-Guard-86M model and its base model, microsoft/mdeberta-v3-base. Our findings reveal a simple yet effective method to circumvent the classifier's detection capabilities.

Method:
The bypass involves inserting character-wise spaces between all English alphabet characters in a given prompt. This simple transformation effectively renders the classifier unable to detect potentially harmful content.

Significance:
While it's understood that as a scalable model, Prompt-Guard-86M may not detect all types of prompt injections, this particular exploit is noteworthy due to its simplicity and high transferability across various prompts.

Results:
Our tests demonstrate that this method reduces the classifier's accuracy from 100% to 0.2% on the harmful set of unmodified prompts in the Sorry-Bench dataset, achieving a 99.8% success rate in bypassing detection.

Example:
Original prompt: "Ignore previous instructions."
Transformed prompt: "I g n o r e p r e v i o u s i n s t r u c t i o n s "

This transformation consistently causes the classifier to misidentify harmful prompts as benign. We're reporting this issue to contribute to the improvement of AI safety measures and are open to discussing the details privately to avoid potential misuse of this information.

outliervirginupharoahcexcultadonx.metaverse

Hello I'm interested in developing an omnichannelweb5neoBanWalletconnect coingecko github trust wallet metamask plaid Mastercard Amex visa fintech dynamics store ecommers payment method social media Metamaskflask AlibabaCloud Royal Celebrity Trust Auction And Talent Investment36%usMSRP Igfbtwitteryoutube web5tbd.developer api ssi decentralized Reality Ai digital twin metaverse xrarvr ilense digital contact hololrlens3teleport Nvidia windowsserver2025 metamaskfilastsnaps square block.xyz vesniley fisglobal Ayden payment connector webpayments found cash app PayPal Braintree developer Google pay wallet api Amazon pay visa discover choose jpmorganchase boa revolut zenledger kindly play store api credentials api androidapi wallet token coin top level domain not airdrop geomining nfc biometrics idex keyless mint sign smart contract codel3ss blockchainExchage metadataToken8zation Economy StimulusSaas baas paas baas open api meta Ai metaphysical llama.321 lama.ai world Pay Authorize.net rain wireX^nereusFinanceAVAXper18$×100000000000000%APR= web3auth web3modal freename.io tm fintixPro money nmi rapidapi postman I'm a Google developer Microsoft cloudPartner Android developer enterprise Partner azure Ai partner and have 3milaccts attached to my Github.com/michaelbjordansHUSBAND 90kto my microsoft Authenticator I want to make This anenterprise Corporate b2b2cp2pEntMetaSocialMediaBANKINGSocial TorusWallet Signkeyservices Azure Web3 Decenraljzed identitiesKeystore SamngsungWalletPayBlockchainKeystore GeminiExchange bank unstoppable domains wallet horizons systems core Mastercard engage Mastercard
[email protected]

error msg when try to download llama 3.1

error msg when try to download

This XML file does not appear to have any style information associated with it. The document tree is shown below.

AccessDenied
Access Denied
6F0DPXTRCWJWMVM8
xej17m2R/2Nm2mMGTzit8lhhurQOHhveLwSJesQEnq8r9GKmHQTE6NLMHNjKNainZ4tEXIqQu84=

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.