Skip to content

schema_builder

sqllocks_spindle.inference.schema_builder

Schema builder — convert a DatasetProfile into a SpindleSchema.

Takes the statistical profile produced by DataProfiler and maps each column's characteristics to the appropriate Spindle generator strategy, producing a complete .spindle.json-compatible schema.

Classes

SchemaBuilder

Convert a DatasetProfile into a SpindleSchema.

Methods:
build(profile, domain_name='inferred', fit_threshold=0.8, correlation_threshold=0.5, include_anomaly_registry=False)

Build a complete SpindleSchema from a dataset profile.