Metadata Enrichment
The metadata enrichment pipeline uses LLMs to automatically generate descriptions, classifications, and data quality rule suggestions for profiled data assets. This transforms raw schema information into rich, governed metadata that helps data teams understand and trust their data.What Gets Enriched
- Table Metadata
- Column Metadata
Enrichment Pipeline
The enrichment workflow is orchestrated by Prefect and uses the OpenAI API for LLM-powered analysis:1
Input preparation
The workflow gathers schema information and profiling results for the target tables. Schema context (all tables and relationships) is assembled using
prepare_tables_and_schema() to give the LLM full database context.2
LLM enrichment
Schema and profiling data are sent to the LLM with structured prompts. The LLM generates metadata enrichments based on:
- Column names and types
- Profiling statistics (completeness, uniqueness, patterns)
- Table relationships and foreign keys
- Cross-table context (schema_info for understanding relationships)
3
Validation
Generated metadata is validated against the schema. PII classifications are cross-checked with column patterns and profiling data.
4
Storage
Enriched metadata is stored in the Data Governance database, linked to the corresponding data asset records.
Schema Context for Better Enrichment
The enrichment pipeline provides full schema context to the LLM for higher-quality results:Concurrency Control
Enrichment workflows use the same hybrid concurrency model as profiling:
The task-level semaphore is particularly important for enrichment to avoid hitting LLM API rate limits:
LLM Configuration
The enrichment pipeline uses LiteLLM and is provider-agnostic — defaults to Vertex AI but works with any LiteLLM-supported provider:DQ Rule Generation
As part of enrichment, the LLM suggests data quality (DQ) rules for each column:
Generated rules are stored as structured metadata and can be used by the DQ monitoring system to track quality over time.
Enrichment Results
Access enrichment results via the Data Governance API:Next Steps
Data Profiling
Profile your data before enrichment to provide statistical context.
Workflows
Learn about the Prefect orchestration system that runs enrichment.
GDPR Compliance
Understand PII classification in the context of GDPR.
Data Classification
Review how enrichment outputs map to data classification levels.

