• Wrong document? Swap it for free
  • Written by students who passed
  • Immediately available after payment
  • Read online or as PDF
Sell
Where do you study
Your language
Document preview thumbnail
Preview 2 out of 6 pages
Exam (elaborations)

Cs7643 Quiz 5 Exam Newest 2025 Complete Questions And Correct Detailed Answers (Verified Answers) |Already Graded A+||Brand New Version!!

Document preview thumbnail
Preview 2 out of 6 pages

CS7643 Quiz 5 Exam NEWEST 2025 COMPLETE QUESTIONS AND CORRECT DETAILED ANSWERS (VERIFIED ANSWERS) |ALREADY GRADED A+||BRAND NEW VERSION!!

Content preview

CS7643 Quiz 5 Exam NEWEST 2025 COMPLETE QUESTIONS AND CORRECT DETAILED
ANSWERS (VERIFIED ANSWERS) |ALREADY GRADED A+||BRAND NEW VERSION!!




Neural Attention - (ANSWER)- weighting or probability distribution over inputs that depend on
computational state and inputs

-HOW IT's Computed?

1. "Hard" - where samples are drawn from the distribution over the input

2. "Soft" - where the distribution is used directly as a weighted average



- Allows information to propagate between distant computational nodes while making minimal
structural assumptions

- Most standard form of attention is softmax



Softmax Properties - (ANSWER)- Probabilities sum to one (gives probability distribution independent of
input)

- Performed on sets so invariant to different permutations (permutation invariant)

- Not linear

- Doubling inputs will put more mass on largest input

- Softmax is differentiable



Softmax Attention vs Final Layer of MLP - (ANSWER)Attention:

- q is an internal hidden state, U is the embeddings of input (previous layer)

- distribution corresponds to a summary of U



MLP:

- q is last hidden state, U is embedding of class labels

- distribution corresponds to labelings (outputs)



Position Embedding - (ANSWER)- A vector that depend only on the location in the sequence which is
added to an input placed at that location in the sequence.

- Adds information about the absolute and relative locations of inputs

, CS7643 Quiz 5 Exam NEWEST 2025 COMPLETE QUESTIONS AND CORRECT DETAILED
ANSWERS (VERIFIED ANSWERS) |ALREADY GRADED A+||BRAND NEW VERSION!!




--> Need this in transformer architectures as they are attention based not sequentially based



Transformers - (ANSWER)- multi-layer attention model that is state of the art in most language tasks

- Superior compared to previous attention architectures because:

1. Multi-query hidden-state propagation ("Self-attention") (MOST IMPORTANT THING)

2. Multi-head attention

3. Residual Connections, LayerNorm



Transformers: Self Attention (Multi-query hidden-state propagation) - (ANSWER)- improves on softmax
attention by having a controller for every input (size of controller state grows with input size)



Transformers: Multi-head attention - (ANSWER)- combines multiple attention 'heads' being trained in
the same way on the same data - but with different weight matrices

- each of the L attention heads yields values for each token; these values are then multiplied by trained
parameters and added



Causal Attention - (ANSWER)- Attention mask (way of putting a graph structure on transformer)

- Masks out attention weights that don't go from left to right

--> training code outputs a prediction at each token simultaneously (and takes gradients simultaneously)

--> massively speeds up training (by the size of the context)

--> Not necessary for masked language models like BERT



Attention vs. Seq2Seq Modeling - (ANSWER)- Seq2Seq passes a single context (the last hidden state) to
the decoder, Attention passes all hidden states to the decoder

- Decoder computes a weighted sum of all hidden states to determine single context vector



BERT is a stack of - (ANSWER)Encoder Modules

Document information

Uploaded on
November 6, 2025
Number of pages
6
Written in
2025/2026
Type
Exam (elaborations)
Contains
Questions & answers
$20.99

Wrong document? Swap it for free Within 14 days of purchase and before downloading, you can choose a different document. You can simply spend the amount again.
Written by students who passed
Immediately available after payment
Read online or as PDF

Seller avatar
Reputation scores are based on the amount of documents a seller has sold for a fee and the reviews they have received for those documents. There are three levels: Bronze, Silver and Gold. The better the reputation, the more your can rely on the quality of the sellers work.
Belaire
5.0
(752)
Sold
2838
Followers
2
Items
1326
Last sold
4 hours ago


Reviews from verified buyers




Why students choose Stuvia

Created by fellow students, verified by reviews

Quality you can trust: written by students who passed their tests and reviewed by others who've used these notes.

Didn't get what you expected? Choose another document

No worries! You can instantly pick a different document that better fits what you're looking for.

Pay as you like, start learning right away

No subscription, no commitments. Pay the way you're used to via credit card and download your PDF document instantly.

Student with book image

“Bought, downloaded, and aced it. It really can be that simple.”

Alisha Student

Working on your references?

Create accurate citations in APA, MLA and Harvard with our free citation generator.

Working on your references?

Frequently asked questions