Il prossimoProssima guida
Formazione sulla previsione multi-token
Intelligenza artificiale linguistica
GUIDA ALL'AI linguistica
Next-token prediction trains a causal language model to estimate the next token from a preceding context.
Ascolta questa guidaNarrato dall'IA · ~1 min
Generation repeats that step, appending each selected token to the context.
The Transformer decoder architecture uses masked self-attention to prevent positions from reading future tokens. GPT-style language models train with a next-token objective over text sequences. At inference, a decoding rule selects a token from the predicted distribution and appends it to the context. Reported capabilities depend on model scale, training data, evaluation and prompting; the cited GPT papers do not guarantee correct output for every task.
A decoder predicts one token distribution conditioned on preceding tokens.
A causal attention mask prevents access to future positions during training.
Teacher forcing uses ground-truth prefixes in training, while generation feeds prior model outputs.
The GPT-2 paper evaluates next-token language modeling and zero-shot task behavior under its model and data conditions.
Evaluate language models on the target task and track error accumulation across long generations. Keep decoding settings and prompt format fixed when comparing results. The cited research does not establish factual reliability or broad product performance from next-token loss alone.
Newsletter gratuita
Tre storie verificate sull'IA ogni mattina nei giorni feriali, scritte in un inglese semplice. Gratuito per sempre, senza pubblicità.
Un'email ogni giorno feriale. Disiscriviti con un clic. Non vendiamo né condividiamo mai il tuo indirizzo.
Mettiti alla prova
Feedback immediato su ogni risposta e un certificato condivisibile con un ID verificabile una volta superato un corso.
Sostieni l'istruzione gratuita sull'IA. AI Understanding è un'organizzazione non profit 501(c)(3) — nessun annuncio, nessun paywall, mai. Fai una donazione
Next-token prediction trains a causal language model to estimate the next token from a preceding context. Generation repeats that step, appending each selected token to the context.
Il modello produce una probabilità per ogni possibile token successivo, quindi ne viene selezionato uno tramite campionamento o scelta avida.
Il mascheramento causale garantisce che la posizione N possa vedere solo le posizioni precedenti, preservando l'impostazione della previsione da sinistra a destra.
La generazione autoregressiva produce un token, lo aggiunge al contesto e ripete il ciclo.
L'entropia incrociata penalizza il modello per aver assegnato una bassa probabilità al vero token successivo, equivalente a massimizzare la probabilità.
Una temperatura più elevata appiattisce la distribuzione di probabilità, aumentando la casualità; una temperatura più bassa rende le scelte più prudenti.
Continua a imparare
Altre guide selezionate per questo argomento
Il prossimoProssima guida
Formazione sulla previsione multi-token
Intelligenza artificiale linguistica