uiz Space

January 2024 term · Large Language Models · BSDA5004

Large Language Models Quiz 2: 24 March 2024 (January 2024 term)

The IIT Madras BS Large Language Models (LLM) Quiz 2 paper sat on 24 Mar 2024, in the January 2024 term: 14 questions for 50 marks in 120 minutes. Every question is below with its answer. Take it as a timed mock test to be marked, or read it through first.

Questions
14
Marks
50
Duration
120 min
Numerical
1
MSQ
9
MCQ
4

Updated

Official paper: IIT M DEGREE AN EXAM QDB2 24 Mar 2024 · No negative marking.

Question 1

+3 marksNumerical answer

Three teams, namely A, B, and C, decided to use a GPT model with two decoder layers with the following configuration

  • length of context window (TT) =1024= 1024
  • number of heads nh=8n_h = 8
  • dmodel=512dmodel = 512
  • dff=4∗dmodeldff = 4 * dmodel
  • dq=dk=dv=dmodelnhdq = dk = dv = \frac{dmodel}{n_h}
  • The weights of the embedding layer and the output layer are shared (tied)

They train the model on the pre-training dataset containing one million words after applying normalization and pre-tokenization( using white space as a delimiter). Moreover, the dataset has no duplicate sentences and no upper-case letters or words. Suppose the team prefers to use the BPE tokenizer to build the vocabulary and subsequently use that to train the model. The base vocabulary contains lowercase alphabets (a to z), digits (0 to 9) and special tokens [unk],[go] and [end].

  • Team AA uses base vocabulary
  • Team BB takes the vocabulary from team AA and does 500 merges
  • Team CC takes the vocabulary from the team BB and does additional 500 merges

Based on the above data answer the given subquestions.

What is the size of the vocabulary built by the Team C?

Show answer

Correct answer: 1039

Question 2

+4 marksOne or more correct options

Three teams, namely A, B, and C, decided to use a GPT model with two decoder layers with the following configuration

  • length of context window (TT) =1024= 1024
  • number of heads nh=8n_h = 8
  • dmodel=512dmodel = 512
  • dff=4∗dmodeldff = 4 * dmodel
  • dq=dk=dv=dmodelnhdq = dk = dv = \frac{dmodel}{n_h}
  • The weights of the embedding layer and the output layer are shared (tied)

They train the model on the pre-training dataset containing one million words after applying normalization and pre-tokenization( using white space as a delimiter). Moreover, the dataset has no duplicate sentences and no upper-case letters or words. Suppose the team prefers to use the BPE tokenizer to build the vocabulary and subsequently use that to train the model. The base vocabulary contains lowercase alphabets (a to z), digits (0 to 9) and special tokens [unk],[go] and [end].

  • Team AA uses base vocabulary
  • Team BB takes the vocabulary from team AA and does 500 merges
  • Team CC takes the vocabulary from the team BB and does additional 500 merges

Based on the above data answer the given subquestions.

Choose the correct statements about the number of parameters in the model (excluding the embedding and output layer parameters)

Select all that apply.

  1. A

    Team A model has less number of parameters than the team B

  2. B

    Team B model has less number of parameters than the team C

  3. C

    Team C model has more number of parameters than the team A

  4. D

    All models have the same number of parameters

Show answer

Correct answer

  • D

    All models have the same number of parameters

Question 3

+4 marksOne or more correct options

Three teams, namely A, B, and C, decided to use a GPT model with two decoder layers with the following configuration

  • length of context window (TT) =1024= 1024
  • number of heads nh=8n_h = 8
  • dmodel=512dmodel = 512
  • dff=4∗dmodeldff = 4 * dmodel
  • dq=dk=dv=dmodelnhdq = dk = dv = \frac{dmodel}{n_h}
  • The weights of the embedding layer and the output layer are shared (tied)

They train the model on the pre-training dataset containing one million words after applying normalization and pre-tokenization( using white space as a delimiter). Moreover, the dataset has no duplicate sentences and no upper-case letters or words. Suppose the team prefers to use the BPE tokenizer to build the vocabulary and subsequently use that to train the model. The base vocabulary contains lowercase alphabets (a to z), digits (0 to 9) and special tokens [unk],[go] and [end].

  • Team AA uses base vocabulary
  • Team BB takes the vocabulary from team AA and does 500 merges
  • Team CC takes the vocabulary from the team BB and does additional 500 merges

Based on the above data answer the given subquestions.

Assume that the word “acrophobia” is not present in the vocabulary, then which of the following tokenizer(s) is(are) guaranteed to tokenize this word into sub-words units (i.e., it does not return [unk] token)

Select all that apply.

  1. A

    The tokenizer used by the team A

  2. B

    the tokenizer used by the team B

  3. C

    the tokenizer used by the team C

  4. D

    None of the given options

Show answer

Correct answers

  • A

    The tokenizer used by the team A

  • B

    the tokenizer used by the team B

  • C

    the tokenizer used by the team C

Question 4

+3 marksOne correct option

Three teams, namely A, B, and C, decided to use a GPT model with two decoder layers with the following configuration

  • length of context window (TT) =1024= 1024
  • number of heads nh=8n_h = 8
  • dmodel=512dmodel = 512
  • dff=4∗dmodeldff = 4 * dmodel
  • dq=dk=dv=dmodelnhdq = dk = dv = \frac{dmodel}{n_h}
  • The weights of the embedding layer and the output layer are shared (tied)

They train the model on the pre-training dataset containing one million words after applying normalization and pre-tokenization( using white space as a delimiter). Moreover, the dataset has no duplicate sentences and no upper-case letters or words. Suppose the team prefers to use the BPE tokenizer to build the vocabulary and subsequently use that to train the model. The base vocabulary contains lowercase alphabets (a to z), digits (0 to 9) and special tokens [unk],[go] and [end].

  • Team AA uses base vocabulary
  • Team BB takes the vocabulary from team AA and does 500 merges
  • Team CC takes the vocabulary from the team BB and does additional 500 merges

Based on the above data answer the given subquestions.

Assume that team A and team B pre-trained the model for 1 million steps. Suppose they want to fine-tune the model for sentiment classification tasks (where the dataset contains sentences, digits and emojis). Choose the correct statement

  1. A

    Team A can use the tokenizer from Team B and fine-tune the model and vice versa

  2. B

    We can not interchange both teams’ tokenizers while fine-tuning.

Show answer

Correct answer

  • A

    Team A can use the tokenizer from Team B and fine-tune the model and vice versa

Question 5

+4 marksOne or more correct options

Suppose we have two decoder-only models, namely Model A and Model B. Assume we have two datasets, one for unsupervised pre-training (Web-Text) and the other for supervised training (text summarization). Model A was trained directly on the training set of the supervised dataset. Model B was trained on the pre-training dataset using the CLM objective. Suppose we want to test the performance of both models on the test set of summarization task. Then choose the correct statements

Select all that apply.

  1. A

    Model A can directly be used on the test set

  2. B

    It is possible to use Model B directly on the test set without fine-tuning on the training set

  3. C

    Model B should be fine-tuned first on the training set and then use the test set.

Show answer

Correct answers

  • A

    Model A can directly be used on the test set

  • B

    It is possible to use Model B directly on the test set without fine-tuning on the training set

Question 6

+4 marksOne or more correct options

The strikeout words in the passage given below denote the words to be dropped from the original sentence. “At the heart of science is an essential balance between two seemingly contradictory attitudes — an openness to new ideas, no matter how bizarre or counterintuitive they may be, and the most ruthless skeptical scrutiny of all ideas, old and new. This is how deep truths are winnowed from deep nonsense”

Which of the following represents the correct input sequence, with sentinel tokens, to the baseline model that uses the pre-training denoising objective? [z] represents the end of the sentinel token in a sentence. The characters inside the square brackets are the sentinel tokens

Select all that apply.

  1. A

    [v] of science is [w] contradictory attitudes [x] counterintuitive they may be [y] how deep truths are winnowed [z]

  2. B

    [a] of science is [b] contradictory attitudes [c] counterintuitive they may be [d] how deep truths are winnowed [z]

  3. C

    [v] of science is [w] contradictory attitudes [x] counterintuitive they may be [y] how deep truths are winnowed

  4. D

    [a] of science is [b] contradictory attitudes [c] counterintuitive they may be [d] how deep truths are winnowed

  5. E

    [w] contradictory attitudes [v] of science is [x] counterintuitive they may be [y] how deep truths are winnowed [z]

  6. F

    [v] of science is [v] contradictory attitudes [x] counterintuitive they may be [x] how deep truths are winnowed [y]

Show answer

Correct answers

  • C

    [v] of science is [w] contradictory attitudes [x] counterintuitive they may be [y] how deep truths are winnowed

  • D

    [a] of science is [b] contradictory attitudes [c] counterintuitive they may be [d] how deep truths are winnowed

Question 7

+3 marksOne or more correct options

Which of the following models uses a form of denoising objective for pre-training?

Select all that apply.

  1. A

    BERT

  2. B

    GPT-1 and GPT-2

  3. C

    BART

  4. D

    T5

Show answer

Correct answers

  • A

    BERT

  • C

    BART

  • D

    T5

Question 8

+4 marksOne or more correct options

Consider training an encoder-decoder model (say, T5 baseline) on a pre-training dataset that contains 1 Billion tokens. Let the batch size be 64 × 128, that is 2¹³ tokens. Suppose the model is trained for 2¹⁵ steps by varying the size of the data (all other aspects are fixed)
A. Train the model only on the first one million tokens, referred to as Model A
B. Train the model on the entire dataset, referred to as Model B
Based on the above data answer the given subquestions.

Which of the following statements is (are) correct under this setup?

Select all that apply.

  1. A

    Training loss of Model A will be less than training loss of Model B

  2. B

    Training loss of Model B will be less than training loss of Model A

  3. C

    Test loss of Model B will likely be less than test loss of Model A

  4. D

    Test loss of Model A will likely be less than test loss of Model B

Show answer

Correct answers

  • A

    Training loss of Model A will be less than training loss of Model B

  • C

    Test loss of Model B will likely be less than test loss of Model A

Question 9

+4 marksOne or more correct options

Consider training an encoder-decoder model (say, T5 baseline) on a pre-training dataset that contains 1 Billion tokens. Let the batch size be 64 × 128, that is 2¹³ tokens. Suppose the model is trained for 2¹⁵ steps by varying the size of the data (all other aspects are fixed)
A. Train the model only on the first one million tokens, referred to as Model A
B. Train the model on the entire dataset, referred to as Model B
Based on the above data answer the given subquestions.

Which of the following modifications will improve the performance of both models?

Select all that apply.

  1. A

    Increasing the training steps helps Model B more than Model A in terms of generalization performance

  2. B

    Increasing the training steps helps both Model A and Model B in terms of generalization performance

  3. C

    None of the given modifications helps the model to improve their generalization performance

Show answer

Correct answer

  • A

    Increasing the training steps helps Model B more than Model A in terms of generalization performance

Question 10

+5 marksOne or more correct options

Consider a summarization task. Assume the prefix is “Summarize the following:” and the input sentence is “There are a lot of videos on YouTube etc. that give the appearance of education, but if you look closely they are really just entertainment. This is very convenient for everyone involved: the people watching enjoy thinking they are learning (but they are just having fun)” and the model is supposed to summarize it.Then which of the following architectures could be used for this task

Select all that apply.

  1. A

    A decoder-only model with a causal mask

  2. B

    A decoder-only model with a prefix mask

  3. C

    An encoder-only model with a fully visible mask

  4. D

    Encoder-Decoder model with fully visible mask in the encoder and causal mask in the decoder

Show answer

Correct answers

  • A

    A decoder-only model with a causal mask

  • B

    A decoder-only model with a prefix mask

  • D

    Encoder-Decoder model with fully visible mask in the encoder and causal mask in the decoder

Question 11

+4 marksOne or more correct options

Suppose we are given a Model A with N layers and the dataset with D tokens. Choose the correct statements according to the scaling law.

Select all that apply.

  1. A

    Increasing the model size requires a proportionate increase in the dataset size to reduce the test loss

  2. B

    Increasing the model size requires a proportionate increase in the dataset size to reduce the training loss

  3. C

    Increasing the model size requires us to double the dataset size to reduce the test loss

  4. D

    Increasing the model size requires us to double the dataset size to reduce the train loss

Show answer

Correct answer

  • A

    Increasing the model size requires a proportionate increase in the dataset size to reduce the test loss

Question 12

+3 marksOne correct option

Which of the following components in the data pre-processing pipeline removes pages that contain bad words?

  1. A

    Language Identification

  2. B

    Exact Deduplication

  3. C

    Fuzzy Deduplication

  4. D

    ML classifiers for quality filtering

  5. E

    Simple heuristics to detect toxic contents

Show answer

Correct answer

  • E

    Simple heuristics to detect toxic contents

Question 13

+3 marksOne correct option

Suppose a team wants to build a dataset for a low-resource language. They took all Wikipedia dumps for that language and found that the dataset size was insufficient. Then the statement that using years of Common Crawl Snapshots would be helpful to increase the size of the dataset is

  1. A

    TRUE

  2. B

    FALSE

Show answer

Correct answer

  • A

    TRUE

Question 14

+2 marksOne correct option

The statement that the presence of significant duplicate contents in the pre-training dataset degrades the performance of Large Language Models is

  1. A

    TRUE

  2. B

    FALSE

Show answer

Correct answer

  • A

    TRUE