Zubnet AIसीखेंWiki › Decoder
मूल तत्व

Decoder

इसे भी कहा जाता है: Decoder Network, Generator
एक neural network component जो एक representation से output generate करता है। Transformers में, decoder causal (left-to-right) attention का उपयोग करके एक बार में एक token generate करता है। Image generation में, VAE decoder latent representations को वापस images में बदलता है। Autoencoders में, decoder compressed bottleneck से मूल input को reconstruct करता है। Decoders कई architectures का "generation" आधा हिस्सा हैं।

यह क्यों मायने रखता है

हर generative AI system के core में एक decoder है। GPT, Claude, और Llama decoder-only Transformers हैं। Stable Diffusion images produce करने के लिए VAE decoder उपयोग करता है। Decoders को समझना बताता है कि generation sequential क्यों है (प्रत्येक token पिछले tokens पर निर्भर करता है), output input processing से धीमा क्यों है, और autoregressive paradigm text generation पर क्यों हावी है।

गहन अध्ययन

एक Transformer decoder में, causal masking सुनिश्चित करता है कि प्रत्येक token केवल पिछले tokens (स्वयं सहित) पर attend कर सकता है। यह softmax से पहले attention scores में future positions को −∞ सेट करके enforce किया जाता है। परिणाम: token 5 का representation केवल tokens 1–5 पर निर्भर करता है। यह constraint ही autoregressive generation को सक्षम बनाता है — आप केवल tokens 1–5 के representations का उपयोग करके token 6 generate कर सकते हैं, जो पहले से compute किए जा चुके हैं।

Decoder-Only LLMs

आधुनिक LLMs (GPT, Claude, Llama) decoder-only हैं: कोई अलग encoder नहीं है, और पूरा मॉडल causal attention उपयोग करता है। Input prompt उन्हीं decoder layers के माध्यम से process किया जाता है जिनसे generated output। यह simplicity ही कारण है कि decoder-only जीता: एक architecture, एक attention pattern, clean scaling। मॉडल सब कुछ generation के रूप में मानता है — input "समझना" भी "अगला क्या आता है" predict करने के रूप में frame किया जाता है।

Image Generation में VAE Decoder

Stable Diffusion में, diffusion प्रक्रिया एक compressed latent space (512×512 के बजाय 64×64) में operate करती है। VAE decoder इस latent representation को वापस full-resolution image में बदलता है। यह एक अलग neural network है जो latents से images reconstruct करने के लिए trained है। VAE decoder की गुणवत्ता सीधे अंतिम image गुणवत्ता को प्रभावित करती है — एक अच्छा decoder fine details और textures जोड़ता है जो latent representation अपने lower resolution पर capture नहीं कर सकता।

संबंधित अवधारणाएँ

← सभी शब्द
← Decart AI Deepgram →
ESC