SnowPro Specialty: Gen AI Question 63
Single answerSemantic model generationA retail analytics team wants to let business users ask natural-language questions about sales performance. The data engineer is using Snowflake semantic model generation to create a semantic model from existing warehouse tables. During testing, users repeatedly ask, "What were net sales by region last quarter?" but the generated model exposes both GROSS_SALES and NET_SALES as generic numeric fields with unclear labels, and REGION exists in multiple source tables. The team wants to improve answer quality without changing the underlying transactional schema. Which action should the engineer take FIRST to make the generated semantic model more reliable for text-to-SQL style questions?
- A
Curate the semantic model by assigning business-friendly names, descriptions, and clear metric/dimension definitions for fields such as NET_SALES and REGION before exposing it to end users.
- B
Duplicate the source tables into a new database so the semantic model generator can infer a single REGION column without ambiguity.
- C
Convert all numeric columns to VARCHAR so the model can use column descriptions instead of data types when interpreting user questions.
- D
Remove NET_SALES from the model and keep only GROSS_SALES so the model has fewer candidate measures to choose from.
Show answer and explanation
Correct answer: A
Explanation
The best first action is to improve the semantic model itself by curating business meaning: add clear labels, descriptions, and explicit metric/dimension definitions so natural-language questions map to the intended fields. In semantic model generation, high-quality metadata is critical because generated models often need refinement before production use. This is especially true when multiple source columns could satisfy a user question or when similar business concepts exist across tables. Snowflake best practices for semantic-layer-style use cases emphasize making models understandable to both end users and AI-driven query generation by reducing ambiguity, preserving proper data types, and modeling business concepts clearly rather than altering the transactional schema unnecessarily.
- A. Correct.
Correct. For semantic model generation, one of the most effective first steps is to curate the generated model with clear business semantics: meaningful names, descriptions, and explicit definitions of metrics and dimensions. This reduces ambiguity for natural-language querying, especially when similar measures like GROSS_SALES and NET_SALES coexist or when attributes such as REGION appear across multiple tables. Improving metadata in the semantic model is preferable to changing the physical schema when the schema itself is not the core issue.
- B. Incorrect.
Incorrect. Duplicating tables is unnecessary and creates governance and maintenance problems. Semantic ambiguity should generally be addressed in the semantic model layer through better naming, documentation, and relationship modeling rather than by copying physical data structures. The misconception is that model quality depends mainly on restructuring storage, when in this scenario the issue is poor semantic clarity.
- C. Incorrect.
Incorrect. Changing numeric columns to VARCHAR would damage type fidelity and make analytical querying worse, not better. Semantic model generation and downstream query generation rely on correct data types to identify measures, aggregations, and filtering behavior. The misconception is that textual metadata can replace proper schema typing; in practice, both accurate types and good descriptions are important.
- D. Incorrect.
Incorrect. Removing NET_SALES would reduce the model's business usefulness and does not solve the underlying ambiguity. Users explicitly need net sales, so deleting the field makes the model less aligned to the use case. The better approach is to define NET_SALES clearly as a metric and distinguish it from GROSS_SALES through semantic metadata.