flâneur — a map of the web's best reading

Inference Characteristics of Llama-2

cursor.com · 3,858 words · saved by 1 readers

Llama-2-70B is an alluring alternative to gpt-3.5, but if looking for a cheap language model, it may not be worth it to deviate from OpenAI's API. When considering price and latency: Instead, Llama is best for prompt-dominated tasks, such as classification. Llama-2 may also make sense when: Otherwise, gpt-3.5 should be cheaper and faster. A quick disclaimer, one reason to use Llama over gpt-3.5 is finetuning1. But in this post, we only explore cost and latency. I don't compare Llama-2 to GPT-4, as it is closer to a 3.5-level model. Benchmark performance also supports this claim: Figure 1: GPT-3.5 dominates llama in all benchmarks here 2 I'll prove these assertions by comparing the cost of serving Llama-2-70B with gpt-3.5-turbo given roughly similar latencies. We serve Llama on 2 80-GB A100 GPUs, as that is the minumum required to fit Llama in memory (with 16-bit precision)3. On 2-A100s, we find that Llama has worse pricing than gpt-3.5 for completion tokens. We speculate competitive pr

Blog / research Llama-2-70B is an alluring alternative to GPT-3.5, but if looking for a cheap language model, it may not be worth it to deviate from OpenAI’s API. When considering price and latency: You should not serve Llama-2 for completion-heavy workloads Instead, Llama is best for prompt-dominated tasks , such as classification. Llama-2 may also make sense when: Your workload has no prompt tokens (unintuitive but we’ll explain later) You are performing batch processing jobs Otherwise, GPT-3.5 should be cheaper and faster. A quick disclaimer, one reason to use Llama over GPT-3.5 is finetuni

Explore this link on the map →

related reading