Databricks Generative AI Engineer Associate Question 250
Single answerYou are training a large language model on sensitive company data using Databricks. To meet a specific performance objective, you decide to mask sensitive information during preprocessing to prevent it from influencing the model's training. Which masking technique would be appropriate to ensure the model can still generalize well while meeting the performance objective?
- A
Replace sensitive information with random strings.
- B
Use consistent token masking by replacing sensitive information with a placeholder token such as '
'. - C
Remove all rows containing sensitive information from the dataset.
- D
Replace sensitive information with realistic synthetic data that follows the same distribution as the original data.
Show answer and explanation
Correct answer: B
Explanation
Using consistent token masking with a placeholder token like '
- A. Incorrect.
Replacing sensitive information with random strings can disrupt the model's ability to generalize because random strings do not follow meaningful patterns or context.
- B. Correct.
Using consistent token masking with a placeholder token like '
' allows the model to learn general patterns without being exposed to sensitive information, and it ensures the model can still generalize. - C. Incorrect.
Removing all rows containing sensitive information may lead to a loss of important context or patterns in the data, reducing the quality and diversity of the training dataset.
- D. Incorrect.
Replacing sensitive information with synthetic data could work in some cases, but it may introduce biases or fail to accurately represent the distribution of the original data, which could hinder model performance.