IABAC Certified Natural Language Processing Expert (CNLPE) — Questions and Answers
Question 1: What is a 'treebank' in the context of NLP?
- A set of grammar rules for a specific language
- A large collection of sentences annotated with syntactic parse trees (Correct answer)
- A memory structure used during chart parsing
- A database of word embeddings
Correct answer: A large collection of sentences annotated with syntactic parse trees
A treebank is a corpus in which sentences have been manually annotated with syntactic structures, used to train and evaluate parsers.
Question 2: What is tokenization in NLP?
- Removing stop words from a sentence
- Splitting text into individual units such as words or subwords (Correct answer)
- Stemming words to their root form
- Converting text to lowercase
Correct answer: Splitting text into individual units such as words or subwords
Tokenization is the process of splitting raw text into smaller units called tokens, which can be words, subwords, or characters.
Question 3: What is the purpose of the OntoNotes corpus in NLP research?
- Hosting pre-trained word embeddings for download
- Providing large-scale annotations for multiple tasks including NER, coreference, semantic roles, and parse trees across multiple genres (Correct answer)
- Storing a list of English ontological concepts and their definitions
- Benchmarking machine translation between major world languages
Correct answer: Providing large-scale annotations for multiple tasks including NER, coreference, semantic roles, and parse trees across multiple genres
OntoNotes is a multi-layer annotated corpus used to train and evaluate models on NER, coreference resolution, SRL, and parsing simultaneously.
Question 4: What is question generation (QG) in NLP?
- Automatically generating natural language questions given a passage of text, often used for educational and QA dataset creation (Correct answer)
- Generating evaluation questions to measure model performance
- Classifying whether a sentence is a question or a statement
- Training a model to answer questions from a passage
Correct answer: Automatically generating natural language questions given a passage of text, often used for educational and QA dataset creation
Question generation reverses the QA task — given a passage and optionally an answer span, the model generates a relevant question, useful for creating training data and tutoring systems.
Question 5: What is the role of dropout regularization in NLP neural networks?
- Reducing the vocabulary size by dropping rare words
- Randomly deactivating a fraction of neurons during training to prevent co-adaptation and reduce overfitting (Correct answer)
- Removing stop words from the input before training
- Skipping certain training examples to speed up convergence
Correct answer: Randomly deactivating a fraction of neurons during training to prevent co-adaptation and reduce overfitting
Dropout randomly zeroes neuron activations during training, forcing the network to learn redundant representations and improving generalization to unseen data.
Question 6: What is the time complexity of the CYK parsing algorithm for a sentence of length n with a grammar of size |G|?
- O(n³ · |G|) (Correct answer)
- O(n)
- O(2ⁿ)
- O(n²)
Correct answer: O(n³ · |G|)
CYK runs in O(n³ · |G|) time because it fills an n×n triangular table by considering all possible split points for every span.
Question 7: In ____, natural language processing is used.
- Topic modeling
- All of the above (Correct answer)
- Text classification
- Chatbots
Correct answer: All of the above
Natural Language Processing (NLP) is applied in a wide range of real-world scenarios. Chatbots utilize NLP to understand user input and generate appropriate responses, text classification categorizes documents based on their content, and topic modeling identifies abstract themes within a collection of texts. All these applications demonstrate the versatility and utility of NLP in processing and understanding human language.
Question 8: What does the special [CLS] token represent in BERT-style models?
- A classification token whose final hidden state is used as the aggregate sequence representation for classification tasks (Correct answer)
- The closing bracket of a sentence
- A separator between two sentences
- A token that replaces unknown words
Correct answer: A classification token whose final hidden state is used as the aggregate sequence representation for classification tasks
In BERT, the [CLS] token is prepended to every input, and its output embedding aggregates information from the whole sequence for downstream classification.
Question 9: Which algorithm can parse ALL context-free grammars (not just CNF) and runs in O(n³) time?
- Shift-reduce parsing
- Viterbi decoding
- A* search
- Earley's algorithm (Correct answer)
Correct answer: Earley's algorithm
Earley's algorithm handles any CFG without requiring normal form conversion and operates in O(n³) time in the general case.
Question 10: The process of reducing word inflection to its root forms in linguistic morphology is known as _____________, and it involves assigning a set of words to a single stem even when the branch is not a recognized term in the language.
- Lemmatization
- Text-Proofing
- Stemming (Correct answer)
- Rooting
Correct answer: Stemming
Stemming is a text normalization technique in NLP that reduces inflected (or sometimes derived) words to their word stem, base, or root form. A key characteristic is that the resulting 'stem' may not always be a valid word itself, as the process often involves simply chopping off suffixes. This process helps in grouping words with similar meanings, which is beneficial for tasks like information retrieval and indexing.
Question 11: What is entity linking (also called named entity disambiguation)?
- Resolving pronouns to their antecedents
- Tagging words with their entity types using BIO labels
- Connecting entity mentions in text to their corresponding entries in a knowledge base such as Wikipedia (Correct answer)
- Merging duplicate records in a database
Correct answer: Connecting entity mentions in text to their corresponding entries in a knowledge base such as Wikipedia
Entity linking disambiguates mentions (e.g., 'Apple' as fruit vs. company) by mapping them to canonical knowledge base entries using context.
Question 12: What is the difference between closed-domain and open-domain question answering?
- Closed-domain QA is restricted to a specific topic or dataset, while open-domain QA answers questions about any topic using a large corpus or the web (Correct answer)
- Closed-domain QA generates answers while open-domain extracts spans
- Closed-domain QA uses neural networks while open-domain QA uses rules
- Open-domain QA requires a knowledge graph while closed-domain does not
Correct answer: Closed-domain QA is restricted to a specific topic or dataset, while open-domain QA answers questions about any topic using a large corpus or the web
Closed-domain systems (e.g., medical QA) operate within a bounded knowledge base, while open-domain systems retrieve from broad corpora like Wikipedia to answer any question.
Question 13: What does constituency parsing produce?
- A sequence of POS tags
- A flat list of tokens
- A dependency graph between word pairs
- A hierarchical tree of phrases grouped by grammatical roles (Correct answer)
Correct answer: A hierarchical tree of phrases grouped by grammatical roles
Constituency parsing breaks a sentence into nested phrases (NP, VP, etc.) arranged in a hierarchical tree structure.
Question 14: What does stemming do in NLP?
- Converts words into numerical vectors
- Removes punctuation from text
- Identifies named entities in text
- Reduces a word to its base or root form by removing suffixes (Correct answer)
Correct answer: Reduces a word to its base or root form by removing suffixes
Stemming strips affixes from words to produce a common base form, e.g., 'running' and 'runs' both stem to 'run'.
Question 15: Which formalism is most commonly used to describe constituency grammars in NLP?
- Context-sensitive grammars
- Dependency grammars
- Context-free grammars (CFG) (Correct answer)
- Regular grammars
Correct answer: Context-free grammars (CFG)
Context-free grammars (CFGs) use rewrite rules like S → NP VP and are the standard formalism for constituency parsing.
Question 16: Which metric is most appropriate for evaluating a named entity recognition (NER) system?
- Accuracy of individual token-level POS assignments
- BLEU score over recognized entity spans
- Perplexity of the sequence labeling model on the test set
- Entity-level F1 score (precision and recall over complete entity mentions) (Correct answer)
Correct answer: Entity-level F1 score (precision and recall over complete entity mentions)
NER is evaluated with entity-level F1, which counts a prediction correct only if the entity type and full span boundaries match the gold standard.
Question 17: What distinguishes 'extractive' summarization from 'abstractive' summarization?
- Extractive selects and copies existing sentences while abstractive generates new text (Correct answer)
- Extractive uses neural networks while abstractive uses rule-based systems
- Extractive produces longer summaries while abstractive produces shorter ones
- Extractive requires labeled data while abstractive is unsupervised
Correct answer: Extractive selects and copies existing sentences while abstractive generates new text
Extractive summarization selects verbatim sentences from the source document, whereas abstractive summarization generates novel paraphrased text.
Question 18: What is the purpose of lowercasing text during NLP preprocessing?
- To reduce vocabulary size by treating 'Apple' and 'apple' as the same token (Correct answer)
- To convert digits into words
- To improve model speed by reducing character count
- To remove named entities from the text
Correct answer: To reduce vocabulary size by treating 'Apple' and 'apple' as the same token
Lowercasing normalizes text so that words with different capitalizations are treated identically, reducing vocabulary size.
Question 19: What is constituency parsing?
- Extracting named entities and their types from text
- Tagging each word with its part of speech
- Analyzing a sentence into nested hierarchical phrases using a context-free grammar (Correct answer)
- Computing the semantic similarity between two sentences
Correct answer: Analyzing a sentence into nested hierarchical phrases using a context-free grammar
Constituency parsing builds a parse tree that groups words into nested phrases (NP, VP, etc.) according to a phrase-structure grammar.
Question 20: What is a knowledge graph in the context of NLP?
- A parse tree produced by a constituency parser
- A structured representation of entities and their relationships stored as a graph of nodes and edges (Correct answer)
- A lookup table of word embeddings
- A directed acyclic graph of dependency arcs
Correct answer: A structured representation of entities and their relationships stored as a graph of nodes and edges
Knowledge graphs (e.g., Wikidata, Freebase) store real-world facts as (entity, relation, entity) triples and power question answering, recommendation, and search systems.
Question 21: What is extractive question answering?
- Generating a new answer sentence not present in the source text
- Ranking a list of candidate answers by relevance
- Selecting a span of text from a given passage as the answer to a question (Correct answer)
- Classifying whether a question is answerable
Correct answer: Selecting a span of text from a given passage as the answer to a question
Extractive QA models (e.g., BERT fine-tuned on SQuAD) predict the start and end token positions of the answer span within the provided context passage.
Question 22: Which evaluation metric is most commonly used for NER tasks?
- BLEU score
- F1 score computed at the entity span level (Correct answer)
- Perplexity
- Mean Reciprocal Rank (MRR)
Correct answer: F1 score computed at the entity span level
NER is evaluated using span-level F1, which requires both the entity type and exact boundary to match for a prediction to count as correct.
Question 23: What is the vanishing gradient problem in RNNs?
- The model fails to tokenize long sentences
- Gradients become extremely small during backpropagation through long sequences, preventing the model from learning long-range dependencies (Correct answer)
- Weights grow unboundedly during training
- The model generates repetitive text
Correct answer: Gradients become extremely small during backpropagation through long sequences, preventing the model from learning long-range dependencies
In deep or long-sequence RNNs, gradients shrink exponentially as they propagate back through time steps, making it hard to learn dependencies between distant tokens.
Question 24: What is open information extraction (OpenIE)?
- Extracting relational triples (subject, relation, object) from text without a predefined ontology (Correct answer)
- Performing NER restricted to a closed set of entity types
- Parsing text using only rule-based patterns
- Extracting entities only from Wikipedia
Correct answer: Extracting relational triples (subject, relation, object) from text without a predefined ontology
OpenIE systems like AllenNLP's extract arbitrary (subject, relation, object) triples from sentences, enabling scalable knowledge acquisition without labeled training data.
Question 25: What is dependency parsing in NLP?
- Classifying the topic of a paragraph
- Analyzing the grammatical structure of a sentence by establishing relationships between 'head' words and words that modify them (Correct answer)
- Splitting a sentence into phrases using context-free grammar
- Identifying coreference chains in a document
Correct answer: Analyzing the grammatical structure of a sentence by establishing relationships between 'head' words and words that modify them
Dependency parsing produces a tree where each word is connected to its syntactic head by a labeled directed arc, revealing grammatical roles like subject and object.
Question 26: What does the attention mechanism in transformers compute?
- A bag-of-words representation of the input
- A weighted sum of value vectors based on the relevance of each key to the query (Correct answer)
- The probability distribution over the next token in a sequence
- The gradient of the loss with respect to each weight
Correct answer: A weighted sum of value vectors based on the relevance of each key to the query
Attention computes compatibility scores between a query and all keys, uses softmax to get weights, and produces a weighted sum of corresponding values.
Question 27: Morphological segmentation: What is it?
- Separate words into individual morphemes and identify the class of the morphemes (Correct answer)
- None of the mentioned
- Is an extension of propositional logic
- Does Discourse Analysis
Correct answer: Separate words into individual morphemes and identify the class of the morphemes
Morphological segmentation is a process in Natural Language Processing (NLP) that involves breaking down words into their smallest meaningful units, known as morphemes. This includes identifying root words, prefixes, and suffixes, and then classifying the grammatical function or type of these morphemes. This analysis helps in understanding the internal structure of words and their variations, which is crucial for many linguistic tasks.
Question 28: What is event extraction in information extraction?
- Identifying mentions of specific events in text and extracting their participants, time, and location (Correct answer)
- Summarizing a document into a single sentence
- Counting the frequency of verbs in a document
- Detecting grammatical errors in sentences
Correct answer: Identifying mentions of specific events in text and extracting their participants, time, and location
Event extraction detects trigger words and fills argument slots (who, did what, to whom, when, where) to build a structured representation of events from unstructured text.
Question 29: Which technique assigns a probability to each word in a vocabulary given the preceding context?
- Named entity recognition
- Language modeling (Correct answer)
- Dependency parsing
- Coreference resolution
Correct answer: Language modeling
Language modeling estimates P(w_t | w_1, …, w_{t-1}), the probability of the next word given its history, and underlies systems like GPT.
Question 30: What is a parse tree ambiguity?
- A tree with incorrect POS tags
- A grammar rule that cannot be applied
- A sentence with no valid parse
- A sentence that yields more than one valid parse tree under a grammar (Correct answer)
Correct answer: A sentence that yields more than one valid parse tree under a grammar
Ambiguity in parsing occurs when a grammar produces multiple valid parse trees for the same input sentence, reflecting multiple interpretations.
Question 31: In machine translation, what does BLEU score measure?
- The inference speed of translation models
- The similarity between machine-translated and reference human translations (Correct answer)
- The vocabulary size used in translations
- The fluency of generated text on a 1–10 scale
Correct answer: The similarity between machine-translated and reference human translations
BLEU (Bilingual Evaluation Understudy) measures translation quality by comparing n-gram overlap between machine output and human reference translations.
Question 32: What metric is most commonly used to evaluate the accuracy of a dependency parser?
- F1 score on named entities
- Labeled Attachment Score (LAS) and Unlabeled Attachment Score (UAS) (Correct answer)
- Perplexity
- BLEU score
Correct answer: Labeled Attachment Score (LAS) and Unlabeled Attachment Score (UAS)
LAS measures the percentage of tokens where both the head and the dependency label are correct; UAS measures only the head attachment accuracy.
Question 33: What is template-based information extraction?
- Generating summaries from structured databases
- Using predefined patterns or templates to identify and fill structured information slots in text (Correct answer)
- Using neural networks to learn extraction patterns from data
- Parsing XML or JSON data formats
Correct answer: Using predefined patterns or templates to identify and fill structured information slots in text
Template-based IE uses hand-crafted or learned patterns (e.g., regular expressions, trigger words) to populate structured records from unstructured text.
Question 34: What is Byte-Pair Encoding (BPE) used for in NLP?
- Subword tokenization to handle rare and out-of-vocabulary words (Correct answer)
- Encoding text as binary for storage
- Splitting paragraphs into sentences
- Compressing model weights to reduce memory
Correct answer: Subword tokenization to handle rare and out-of-vocabulary words
BPE is a subword tokenization algorithm that iteratively merges frequent character pairs, enabling models to handle unseen words by breaking them into known subunits.
Question 35: NLP is interested in how computers and human (natural) languages interact.
- FALSE
- TRUE (Correct answer)
Correct answer: TRUE
This statement accurately defines the core objective of Natural Language Processing (NLP). The field is dedicated to enabling computers to understand, interpret, and generate human language in a way that is both meaningful and useful. This interaction allows for a wide range of applications, including machine translation, sentiment analysis, chatbots, and speech recognition, bridging the gap between human communication and computational systems.
Question 36: What is Named Entity Recognition (NER) in NLP?
- The task of locating and classifying named entities in text into predefined categories such as person, organization, or location (Correct answer)
- The process of removing proper nouns from text
- The task of predicting the next word in a sentence
- A method for measuring sentence similarity
Correct answer: The task of locating and classifying named entities in text into predefined categories such as person, organization, or location
NER identifies spans of text that refer to real-world entities and categorizes them, e.g., tagging 'Apple' as an organization and 'Cupertino' as a location.
Question 37: What is the role of the 'key' vector in the Transformer self-attention mechanism?
- Masks padding tokens during attention computation
- Represents what a token has to offer for matching (Correct answer)
- Stores the output representation of a token
- Encodes the positional information of a token
Correct answer: Represents what a token has to offer for matching
Keys are paired with queries via dot-product to compute attention scores that determine how much each value vector contributes to the output.
Question 38: What problem does beam search solve in NLP sequence generation tasks?
- Out-of-vocabulary token handling
- Exploding gradients in RNNs
- Overfitting during training
- Suboptimal output due to greedy decoding (Correct answer)
Correct answer: Suboptimal output due to greedy decoding
Beam search maintains multiple candidate sequences at each step, producing better outputs than greedy decoding which commits to one token at a time.
Question 39: What does the Universal Dependencies (UD) project provide?
- A universal vocabulary for NLP models
- A single grammar that covers all possible languages
- A cross-linguistically consistent dependency annotation scheme and treebanks for 100+ languages (Correct answer)
- A tool for unsupervised grammar induction
Correct answer: A cross-linguistically consistent dependency annotation scheme and treebanks for 100+ languages
Universal Dependencies offers a unified set of dependency relation labels and treebanks across more than 100 languages, enabling cross-lingual NLP research.
Question 40: What is the role of the softmax function at the output layer of a language model?
- To normalize the input embeddings
- To apply dropout regularization
- To compute cross-entropy loss
- To convert raw logit scores into a probability distribution over the vocabulary (Correct answer)
Correct answer: To convert raw logit scores into a probability distribution over the vocabulary
Softmax exponentiates each logit and divides by the sum, ensuring all vocabulary probabilities are positive and sum to 1.
Question 41: What is 'dependency parsing' in NLP?
- Segmenting a document into topically coherent sections
- Grouping tokens into non-overlapping spans such as noun phrases and verb phrases
- Identifying binary grammatical relationships between pairs of words in a sentence (Correct answer)
- Resolving which sense of a polysemous word is intended
Correct answer: Identifying binary grammatical relationships between pairs of words in a sentence
Dependency parsing constructs a directed graph where edges represent grammatical relations (subject, object, modifier) between a head word and its dependents.
Question 42: Which pre-training objective does BERT use to learn bidirectional representations?
- Contrastive sentence embedding
- Causal language modeling left-to-right
- Next sentence prediction only
- Masked language modeling and next sentence prediction (Correct answer)
Correct answer: Masked language modeling and next sentence prediction
BERT pre-trains using masked language modeling (predicting randomly masked tokens) and next sentence prediction (determining if two sentences are consecutive).
Question 43: Which parsing strategy processes input left-to-right and builds the parse bottom-up using a stack and input buffer?
- Recursive descent parsing
- CYK parsing
- Shift-reduce parsing (Correct answer)
- Earley parsing
Correct answer: Shift-reduce parsing
Shift-reduce parsing maintains a stack and an input buffer, repeatedly shifting tokens onto the stack or reducing a stack sequence using grammar rules.
Question 44: What does the term 'corpus' refer to in NLP?
- A large structured collection of text used for training or evaluating NLP models (Correct answer)
- A dictionary of word embeddings
- A set of grammar rules
- A single annotated sentence
Correct answer: A large structured collection of text used for training or evaluating NLP models
A corpus is a dataset of text (and sometimes speech) that provides the empirical basis for training and evaluating language models and other NLP systems.
Question 45: What does 'BERT' stand for?
- Bidirectional Extraction and Retrieval Tool
- Bidirectional Encoder Representations from Transformers (Correct answer)
- Batch Encoding with Recurrent Transformers
- Basic Encoder Recurrent Transformer
Correct answer: Bidirectional Encoder Representations from Transformers
BERT stands for Bidirectional Encoder Representations from Transformers, a pre-trained language model developed by Google that reads text in both directions simultaneously.
Question 46: What is relation extraction in NLP?
- Finding synonyms for words in a sentence
- Extracting noun phrases from a parse tree
- Splitting compound sentences into simple ones
- Identifying semantic relationships between entities mentioned in text, such as 'works at' or 'located in' (Correct answer)
Correct answer: Identifying semantic relationships between entities mentioned in text, such as 'works at' or 'located in'
Relation extraction goes beyond NER to determine how entities are related, populating knowledge bases with structured (subject, relation, object) triples.
Question 47: Pick one of the following applications for NLP.
- Information Retrieval
- Market Basket Analysis (Correct answer)
- Speech Recognition
- Automatic Question-Answering Systems
- Automatic Text Summarization
Correct answer: Market Basket Analysis
While typically associated with transactional data analysis, Market Basket Analysis can indirectly leverage NLP when the 'items' or 'baskets' involve textual information. For example, NLP could be used to analyze customer reviews, product descriptions, or social media comments to identify co-occurring themes, sentiments, or product features. This textual analysis can then inform or enhance a market basket analysis by revealing relationships between products or services based on natural language data.
Question 48: What does text mining stemming mean?
- Defining the parts of speech of a word
- Converting sentences to words
- None
- Reducing a word to its root (Correct answer)
Correct answer: Reducing a word to its root
Stemming is a fundamental text mining and Natural Language Processing (NLP) technique used to reduce inflected words to their word stem, base, or root form. For example, words like 'running,' 'runs,' and 'runner' would all be stemmed to 'run.' This process helps in normalizing text, reducing vocabulary size, and improving the efficiency of text analysis by treating variations of a word as the same unit.
Question 49: What is low-resource machine translation?
- Machine translation for language pairs that have limited parallel training data available (Correct answer)
- Machine translation that requires minimal GPU memory to run
- A simplified translation system that only handles common phrases
- Translation of short texts such as tweets or captions
Correct answer: Machine translation for language pairs that have limited parallel training data available
Low-resource MT addresses language pairs like Swahili-English or Haitian Creole-French where parallel corpora are scarce, using techniques like transfer learning and back-translation.
Question 50: What is 'garden path' ambiguity in parsing?
- A sentence with no valid parse
- Ambiguity caused by misspelled words
- A sentence that initially seems to follow one parse but requires reanalysis partway through (Correct answer)
- A parsing error due to an incomplete grammar
Correct answer: A sentence that initially seems to follow one parse but requires reanalysis partway through
Garden path sentences (e.g., 'The horse raced past the barn fell') lead the parser down an incorrect initial interpretation that must be abandoned upon reading more of the sentence.
Question 51: In transformer models, what does 'positional encoding' solve?
- It gives the model information about the order of tokens, since attention itself is order-agnostic (Correct answer)
- It encodes part-of-speech tags into input vectors
- It normalizes token embeddings to unit length
- It adds word frequency information to embeddings
Correct answer: It gives the model information about the order of tokens, since attention itself is order-agnostic
Since the self-attention mechanism treats all positions equally, positional encodings are added to token embeddings so the model can distinguish word order.
IABAC Certified Natural Language Processing Expert (CNLPE)
The CNLPE certification validates expertise in NLP techniques including text processing, syntactic analysis, named entity recognition, sentiment analysis, and modern language model architectures. It covers both foundational NLP concepts and applied machine learning approaches for real-world text-based AI systems.
Exam Rules
- You can skip questions and return to them later
- Flag questions for review before submitting
- No feedback shown until you submit the entire exam
- Unanswered questions count as wrong — answer everything
- 10 pretest questions are mixed in and don't affect your score
- Timer auto-submits when time runs out
- Your progress is auto-saved every 30 seconds