LLM
LLM trained on 2T tokens with double Llama 1's context length, available in 7B, 13B, and 70B parameter sizes.
Try our LLaMA-2 API

API Usage
Endpoint
meta-llama/Llama-2-70b-hf
RUN INFERENCE
curl -X POST "https://api.together.xyz/v1/chat/completions" \
-H "Authorization: Bearer $TOGETHER_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"model": "meta-llama/Llama-2-70b-hf",
"messages": [{"role": "user", "content": "What are some fun things to do in New York?"}]
}'
JSON RESPONSE
RUN INFERENCE
from together import Together
client = Together()
response = client.chat.completions.create(
model="meta-llama/Llama-2-70b-hf",
messages=[{"role": "user", "content": "What are some fun things to do in New York?"}],
)
print(response.choices[0].message.content)
JSON RESPONSE
RUN INFERENCE
import Together from "together-ai";
const together = new Together();
const response = await together.chat.completions.create({
messages: [{"role": "user", "content": "What are some fun things to do in New York?"}],
model: "meta-llama/Llama-2-70b-hf",
});
console.log(response.choices[0].message.content)
JSON RESPONSE
Model Provider:
Meta
Type:
Language
Variant:
Parameters:
69B
Deployment:
✔ Serverless
Quantization
Context length:
4K
Pricing:
$0.90
Run in playground
Deploy model
Quickstart docs
Quickstart docs
How to use LLaMA-2
Model details
Prompting LLaMA-2
Applications & Use Cases
Looking for production scale? Deploy on a dedicated endpoint
Deploy LLaMA-2 on a dedicated endpoint with custom hardware configuration, as many instances as you need, and auto-scaling.
