Code Llama is a code generation model built on top of Llama 2. It can generate code and natural language about code in many programming languages, including Python, JavaScript, TypeScript, C++, Java, PHP, C#, Bash and more.
Today, Meta announced a more powerful new version of Code Llama with 70 billion parameters. It's one of the highest performing open models. Meta reports a 67.8 on HumanEval, which beats zero-shot GPT-4.
With Replicate, you can run Code Llama 70B in the cloud with one line of code.
There are three variants of Code Llama 70B. The code snippets in this guide use codellama-70b-instruct, but all three variants are available on Replicate:
You can run Code Llama 70B with our official JavaScript client:
Set the REPLICATE_API_TOKEN
environment variable:
Import and set up the client:
Run meta/codellama-70b-instruct using Replicate’s API:
To learn more, take a look at the guide on getting started with Node.js.
You can run Code Llama 70B with our official Python client:
Set the REPLICATE_API_TOKEN
environment variable:
Run meta/codellama-70b-instruct using Replicate’s API:
To learn more, take a look at the guide on getting started with Python.
You can call the HTTP API directly with tools like cURL:
Set the REPLICATE_API_TOKEN
environment variable:
Run meta/codellama-70b-instruct using Replicate’s API:
To learn more, take a look at Replicate’s HTTP API reference docs.
You can also run Code Llama 70B using other Replicate client libraries for Go, Swift, and others