-
-
Notifications
You must be signed in to change notification settings - Fork 13
Blocking Strategies
Blocking reduces the comparison space from O(n²) to something tractable. Instead of comparing every pair of records, blocking groups records by shared attributes and only compares within groups.
Groups records by the exact value of the blocking key.
blocking:
strategy: static
keys:
- fields: [zip]
transforms: [strip]Best for: clean data with reliable exact-match fields.
Static blocking with recursive sub-blocking for oversized groups.
blocking:
strategy: adaptive
keys:
- fields: [zip]
sub_block_keys:
- fields: [last_name]
transforms: [soundex]
max_block_size: 500Best for: data with skewed distributions (e.g., common zip codes).
Sliding window over records sorted by a key.
blocking:
strategy: sorted_neighborhood
sort_key:
- column: name
transforms: [lowercase, strip]
window_size: 20Best for: data where similar records sort near each other.
Union of blocks from multiple passes with different keys. Records found by any pass are candidates.
blocking:
strategy: multi_pass
passes:
- fields: [name]
transforms: [lowercase, "substring:0:5"]
- fields: [name]
transforms: [lowercase, soundex]
- fields: [name]
transforms: [lowercase, token_sort, "substring:0:8"]Best for: noisy data where no single key catches all matches. Our best results on Leipzig benchmarks use multi-pass.
Approximate nearest neighbor blocking using FAISS on sentence-transformer embeddings. Groups semantically similar records.
blocking:
strategy: ann
ann_column: title
ann_model: all-MiniLM-L6-v2
ann_top_k: 20Best for: semantic matching (product names, descriptions).
Like ANN but returns FAISS pairs directly without Union-Find transitive closure. 50-100x faster with equal or better precision.
blocking:
strategy: ann_pairs
ann_column: title
ann_model: all-MiniLM-L6-v2
ann_top_k: 20Best for: semantic matching where speed matters.
TF-IDF canopy clustering with cosine similarity thresholds.
blocking:
strategy: canopy
canopy:
fields: [description]
loose_threshold: 0.3
tight_threshold: 0.7Best for: text-heavy data without embedding dependencies.
| Data Type | Recommended Strategy |
|---|---|
| Clean with exact fields | static |
| Clean with skewed distribution | adaptive |
| Noisy names/addresses | multi_pass |
| Product catalogs |
ann_pairs + embeddings |
| Large text fields | canopy |
| Database sync | Hybrid (SQL + ANN, automatic) |
⚡ GoldenMatch — Entity resolution toolkit | PyPI | GitHub | Open in Colab | MIT License
🟡 Golden Suite (Monorepo)
Suite Packages
- GoldenCheck · data quality
- GoldenFlow · transforms
- GoldenPipe · orchestrator
- InferMap · schema mapping
Getting Started
- Installation
- Quick Start
- Auto-Config Controller · enhanced through v1.12
- Configuration
- Verification · new in v1.5
- CLI Reference
Core Concepts
AI Integration
Advanced
- PPRL
- Domain Packs
- Streaming / CDC
- Database Integration
- GPU & Vertex AI
- REST API
- Interactive TUI
- Web UI · new in v1.7
- Evaluation
Reference
pip install goldenmatch
npm install goldenmatch