Skip to main content

Glossary / Best-of-N

Glossary

Best-of-N

Also called: best-of-N sampling

In short

Generating several candidate answers and keeping the best one, instead of trusting a single attempt.

A model’s first attempt is not always its best. Best-of-N generates several candidates, from one model or many, then selects or fuses the strongest. More attempts give you a better ceiling to pick from.

It trades a bit more cost for noticeably better quality, which is worth it when the answer matters more than speed.

In LLMWeave

A best-of-N weave produces several candidate answers and then picks or fuses the best, so your final result is the strongest of the bunch rather than a single roll of the dice.

Related terms

Try multi-model on your task

One prompt, several models, one answer. Free to start, no card.

Get started