Match Architecture, Objective, and Interface to a Task

Select a natural architecture family from available information, output interface, and objective while avoiding impossibility claims. Compare masks, targets, readouts, costs, and bounded capability evidence.

Architecture family is one design choice among several. A useful selection starts from the information available at prediction time, the desired output interface, and the training signal—not from a model name alone.

RequirementNatural starting familyReason
one record per input token using both sidesencoder-onlyfull input context is available
continue one sequence left to rightdecoder-onlycausal prefix matches generation
generate a target conditioned on a separate sourceencoder-decodersource memory and target prefix remain distinct

“Natural starting family” does not mean “only possible family.” Prompting, special tokens, pooling, adapters, and alternative masks can let a family serve other tasks. Such adaptations must still be described and evaluated.

Match the Objective Too

The same architecture can be trained under different objectives. Conversely, related objectives can be implemented under different interfaces. Record at least:

  • model input and any corruption;
  • visibility mask;
  • prediction targets and their shift;
  • positions included in the loss;
  • readout used for evaluation;
  • inference procedure.

Without this ledger, “BERT-like,” “GPT-like,” or “T5-like” hides the details needed to reproduce the computation.

Compare Costs Under Declared Shapes

Full encoder self-attention stores Ts2T_s^2 score entries per head. Decoder self-attention also forms a Tt2T_t^2 dense matrix in a common implementation, even though its upper triangle is forbidden. Cross-attention adds TtTsT_tT_s score entries per head and its own projections in each decoder layer that contains it.

These counts do not by themselves determine runtime or model quality. Kernels, sparsity, caching, widths, layer counts, and hardware matter.

Keep Capability Claims Bounded

A family determines permitted information paths. It does not guarantee that a trained model learns a desired skill, uses a particular route, remains factual, or generalizes outside its evaluation. Attach capability claims to a concrete model, data and adaptation procedure, task, metric, and comparison.

Q1. Choose a starting family

You must generate a summary from a separate source document while preserving a causal target prefix. Which family is the most direct starting point?

Answer it first, then check.

Hint
The problem has a source stream and a generated target stream.
Solution
An encoder-decoder model is the most direct starting point.
Not attempted
Review

Not marked done.

Pause and reflect

In your own words, note what you understood, what remains unclear, or what you want to revisit. The note stays with this lesson.

0 of 1 exercises marked done

Review

Not marked done.

LLM PrimerMatch Architecture, Objective, and Interface to a Taskhttps://llmprimer.com/transformers/transformer-architecture-families/match-architecture-objective-and-interface-to-a-task© 2026 LLM Primer