NastępnyNastępny poradnik
Wymuszanie nauczycieli w modelach sekwencji
Techniczne
PRZEWODNIK Językowy AI
Sequence-to-sequence (seq2seq) models encode an input sequence and generate an output sequence, which may have a different length.
Posłuchaj tego przewodnikaOpowiadane przez sztuczną inteligencję · ~1 min
Attention provides access to source context during decoding.
Early neural machine-translation systems encoded a source sentence into a fixed vector, which constrained long inputs. Bahdanau attention lets a decoder compute context from source hidden states at each step. The Transformer replaces recurrence with attention layers, while sequence-to-sequence variants retain encoder and decoder components. Output length is determined during generation rather than copied from input length.
An encoder can represent a source sentence for translation.
A decoder generates target tokens until an end condition is reached.
Cross-attention uses encoder outputs as keys and values for decoder queries.
Transformer encoder-decoder models such as T5 and BART apply this structure to text tasks.
Choose encoder-decoder or decoder-only architectures based on the task, data and serving constraints. Evaluate input-length behavior, output quality and decoding cost. The cited papers establish particular model designs and benchmarks, not universal superiority of one architecture.
Darmowy newsletter
Trzy zweryfikowane historie AI każdego poranka w dni robocze, napisane prostym angielskim. Bezpłatne na zawsze, bez reklam.
Jedno e‑mail każdego dnia roboczego. Wypisz się jednym kliknięciem. Nigdy nie sprzedajemy ani nie udostępniamy Twojego adresu.
Sprawdź się
Natychmiastowa informacja zwrotna na każde pytanie oraz udostępnialny certyfikat z weryfikowalnym ID po zaliczeniu kursu.
Wspieraj darmową edukację AI. AI Understanding jest organizacją non-profit 501(c)(3) — bez reklam, bez płatnej ściany, zawsze. Przekaż darowiznę
Sequence-to-sequence (seq2seq) models encode an input sequence and generate an output sequence, which may have a different length. Attention provides access to source context during decoding.
Koder odczytuje i kompresuje dane wejściowe, a dekoder generuje sekwencję wyjściową.
Uwaga, pozwól dekoderowi uzyskać dostęp do wszystkich stanów kodera, zamiast polegać na jednym skompresowanym wektorze, co poprawi wydajność długich zdań.
Sutskever i in. wykorzystał ułożone stosy sieci rekurencyjnych LSTM dla kodera i dekodera.
Uwaga przypisuje wagi stanom kodera, więc każdy krok wyjściowy koncentruje się na najbardziej odpowiednich pozycjach wejściowych.
Dekoder generuje autoregresję i może zatrzymać się na tokenie końca sekwencji, umożliwiając zmienną długość wyjściową.
Ucz się dalej
Wybrano więcej przewodników na ten temat
NastępnyNastępny poradnik
Wymuszanie nauczycieli w modelach sekwencji
Techniczne