# What is Greedy Decoding? Definition & Technical Mechanics

> **Source:** [SPIDITS AI AI Glossary](https://spidits.com/ai-glossary)  
> **Category:** Model Operations  
> **Canonical Citation:** [https://spidits.com/ai-glossary/greedy-decoding](https://spidits.com/ai-glossary/greedy-decoding)

## Definition
Greedy Decoding is a sequence generation method where the model always selects the single token with the highest predicted probability at each step during output text generation.

## Architectural Mechanics & Deep Dive
Greedy decoding is a simple sequence generation strategy where the model selects the token with the highest probability at each step. While computationally fast and simple, greedy decoding can result in repetitive, formulaic, and suboptimal text generation, as it fails to consider whether a slightly lower-probability token now would lead to a much better sequence later.

## Industry Applications & Real-World Use Cases
Deterministic text outputs, programming code generation, and structured API JSON output runs.

## Frequently Asked Questions

### What is the equivalent temperature parameter for greedy decoding?
Setting the Temperature parameter to 0 forces the model to use greedy decoding.

### What is a drawback of greedy decoding?
It can get stuck in repetitive generation loops and lacks the creativity of sampling methods.

## Related Terminology
- [temperature](https://spidits.com/ai-glossary/temperature)
- [tokenization](https://spidits.com/ai-glossary/tokenization)
- [inference](https://spidits.com/ai-glossary/inference)

---
*From the SPIDITS AI Knowledge Base (336+ terms indexed). Explore full technical definitions: [https://spidits.com/ai-glossary](https://spidits.com/ai-glossary)*
