File size: 1,713 Bytes
1cd137c | 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 | contract:
name: phase4_variants
version: 1.0.0
description: Identify and model meaningful product variants within product groups
input:
dataset: product_groups
required_columns:
- external_id
- source_retailer
- group_id
- identity_attributes
- variant_attributes
output:
dataset: product_variants
grain: one record per retailer product variant
columns:
- variant_id
- group_id
- external_id
- source_retailer
- variant_attributes
processing:
does:
- identify_variant_attributes
- separate_variants_from_core_identity
- generate_deterministic_variant_ids
- preserve_group_relationships
- preserve_source_identifiers
does_not:
- create_product_groups
- change_product_identity
- merge_unrelated_products
- calculate_scores
- invent_missing_values
variant_attributes:
examples:
- size
- flavour
- package_type
- formulation
- fat_percentage
- fat_level
quality:
critical:
- missing_group_id
- missing_external_id
- missing_source_retailer
warnings:
- missing_variant_attributes
ambiguous:
- ambiguous_variant
failure_handling:
statuses:
PASS: continue
WARNING: continue_and_report
AMBIGUOUS: quarantine_for_review
FAIL: stop
ambiguity:
signals:
- unclear_variant_attribute
- conflicting_variant_attributes
- competing_variant_interpretations
resume_from: phase_4
identifiers:
primary_key:
- source_retailer
- variant_id
variant_id:
deterministic: true
rules_versioned: true
versioning:
schema_version: 1.0.0
rules_version: 1.0.0
lineage:
source: phase3_grouping
pipeline_version: 1.0.0
|