Sentri
Sentri is a production-ready, configurable data quality validation framework with 10 check types, multiple data connectors, and flexible output formats.
Features
- 10 Check Types: Completeness, Uniqueness, Range, Turnover, Value Spike, Frequency, Correlation, Statistical, Distribution, Drift
- Multiple Connectors: CSV, Oracle, Snowflake (extensible)
- Flexible Configuration: YAML with environment variable support
- Multiple Output Formats: JSON, HTML, CSV, DataFrame
- Threshold-Based Validation: Critical, Warning, Pass, Error states
- Comprehensive Logging: Text and JSON formats
Installation
pip install sentri
# Optional: development extras when working on the project itself
pip install -e ".[dev]" # Development install
pip install -e ".[all]" # With all database connectors
Quick Start
Programmatic Usage
from sentri import DataQualityFramework
from sentri.checks import CompletenessCheck, TurnoverCheck
from sentri.connectors import OracleConnector, SnowflakeConnector
# Example: using DataQualityFramework with a config file
framework = DataQualityFramework(config_path="config.yaml")
results = framework.run_checks(start_date="2025-01-01", end_date="2025-01-31")
Configuration File Usage
# config.yaml
source:
type: csv
csv:
file_path: /data/sample.csv
date_column: effective_date
metadata:
dq_check_name: "Sample Check"
date_column: effective_date
id_column: entity_id
checks:
completeness:
value:
thresholds:
absolute_critical: 0.05
absolute_warning: 0.02
description: "Value completeness"
output:
formats: [json, html, csv]
destination: /output
Check Types
| Check Type | Description |
|---|---|
| Completeness | Monitor null/missing values |
| Uniqueness | Detect duplicate values |
| Range | Validate value bounds |
| Turnover | Track ID additions/removals |
| Value Spike | Detect abnormal value changes |
| Frequency | Monitor category distributions |
| Statistical | Track mean, std, median, etc. |
| Correlation | Validate temporal/cross-column correlation |
| Distribution | Detect distribution shifts (KS test) |
| Drift | Identify gradual drift (PSI) |
Project Structure
dq_framework/
├── src/data_quality/
│ ├── checks/ # Check implementations
│ ├── connectors/ # Data connectors
│ ├── core/ # Exceptions, config, framework
│ ├── formatters/ # Output formatters
│ ├── managers/ # Check manager
│ └── utils/ # Logger, constants
├── tests/ # Unit tests
├── examples/ # Sample configs and scripts
└── pyproject.toml
Running Tests
pytest tests/unit/ -v --cov
Thresholds
Each check supports:
absolute_critical: Fails if exceededabsolute_warning: Warns if exceededdelta_critical/delta_warning: For change-based thresholds
Output
Results include:
- Summary: Total, passed, warnings, failed, pass rate
- Details: Check type, column, date, metric value, status
License
MIT
Metadata
Release files for sentri 1.0.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| sentri-1.0.0.tar.gz | 34.1 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| sentri-1.0.0-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 84.4 kB
Release files / sentri-1.0.0.tar.gz
| Download URL | sentri-1.0.0.tar.gz |
|---|---|
| Size | 34.1 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
5460956d3956983c1cb209424ecdd2779192e9216b832ce0d5ea2ba7d817d852
|
|
BLAKE2b-256 checksum How to use checksums |
86bbf16a68b1e6a86b6ec9890dd9a3458804af66871d2f15f0eea3ab346842b2
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.2.0 CPython/3.13.1
|
Release files / sentri-1.0.0-py3-none-any.whl
| Download URL | sentri-1.0.0-py3-none-any.whl |
|---|---|
| Size | 50.3 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
0f6b32656552918c213ea074342a25b4f3bda3ae280a8359ff573d156dc4eccf
|
|
BLAKE2b-256 checksum How to use checksums |
05ab2b274574b07da723c86d69d977456fcbd3dfde29e2b6dfaab2f0fda15234
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.2.0 CPython/3.13.1
|