The user wants a "Data Quality and Accuracy Assurance Standard with Correction Flows."
This means I need to create a formal document or guideline that outlines how an organization ensures its data is high-quality (accurate, complete, consistent, etc.) and, crucially, what happens when it isn't (the correction flows).
1. Deconstruct the Request:
- Data Quality & Accuracy Assurance: This is the proactive side. It involves defining what "quality" means (dimensions), setting rules, monitoring, and preventing bad data.
- Standard: This implies a structured, formal document. It needs sections like scope, roles, definitions, and procedures.
- Correction Flows: This is the reactive side. When an error is found, how is it reported, triaged, fixed, and verified? This needs a workflow or process diagram description.
2. Structure of the Standard:
A standard professional document structure usually works best here:
- Header: Title, Version, Date, Owner.
- 1. Purpose & Scope: Why does this exist? What data does it cover?
- 2. Definitions (Dimensions of Quality): What are we measuring? (Accuracy, Completeness, Consistency, Timeliness, Uniqueness).
- 3. Roles & Responsibilities: Who does what? (Data Owners, Stewards, Engineers, Consumers).
- 4. Quality Assurance Framework (The "Preventative" side):
- Data Entry standards (validation).
- Pipeline testing.
- Automated monitoring/alerting.
- 5. Issue Detection & Reporting: How do we know something is wrong?
- 6. Data Correction Flows (The "Reactive" side): This is the core specific request. I need a step-by-step process.
- Triage.
- Root Cause Analysis.
- Remediation (Source fix vs. Downstream patch).
- Verification.
- 7. Continuous Improvement: Metrics & Audits.
3. Drafting Content - Section by Section:
-
Title: Enterprise Data Quality & Accuracy Assurance Standard.
-
Section 1 (Purpose): Keep it high-level. Ensure trust in data decision-making.
-
Section 2 (Dimensions):
- Accuracy: Does it reflect reality?
- Completeness: Is anything missing?
- Consistency: Does it match across systems?
- Timeliness: Is it up to date?
-
Section 3 (Roles):
- Data Steward: The subject matter expert.
- Data Engineer: The builder.
- Data Consumer: The user.
-
Section 4 (Assurance Mechanisms):
- Ingress Controls: Regex, drop-downs (prevent garbage in).
- Pipeline Tests: Great Expectations, dbt tests (schema checks, null checks).
-
Section 5 (Correction Flows - The Meat): I need to make this a distinct, actionable workflow.
- Step 1: Identification. (User spots it or Alert triggers).
- Step 2: Ticketing. (Jira/ServiceNow).
- Step 3: Triage/Impact. (How bad is it? Critical vs. Low).
- Step 4: Resolution Strategy. This is important. Do we fix the source? Do we write a script to update the DB? Do we just reload?
- Step 5: Implementation.
- Step 6: Verification.
- Step 7: Post-Mortem/Prevention.
-
Section 6 (SLAs): How fast do we fix things? (Critical: 4 hours, High: 24 hours, etc.).
4. Refinement & Formatting:
- Use bolding for key terms.
- Use lists for readability.
- Create a text-based visual for the "Correction Flow" (e.g., a mermaid-style representation or a numbered list).
- Add a "Severity Matrix" to make it practical.
5. Self-Correction/Review during drafting:
- Initial thought: Just list the steps.
- Correction: A "Standard" needs to be a document. I should frame it as a policy document.
- Detail check: Ensure I distinguish between "Source Correction" (fixing the root) and "Downstream Correction" (fixing the report/warehouse). Both are valid but have different implications.
- Tone: Professional, authoritative, yet clear.
6. Final Polish:
Check against the prompt: "Standard" (Yes), "Correction Flows" (Yes). The inclusion of specific correction methodologies (Retractive vs. Proactive) adds depth.
(Self-Correction during drafting the response): I should add a visual representation of the correction flow, perhaps using ASCII or a structured step-by-step block, to make it easy to copy-paste into a slide or document.
7. Output Generation: (Proceed to generate the structured response based on the above plan.)
Below is a comprehensive Data Quality and Accuracy Assurance Standard. This document is designed to be adapted for enterprise, mid-sized, or data-intensive technical environments.
It defines the rules for data integrity and, crucially, outlines the specific workflows required to correct data when errors are detected.
Data Quality & Accuracy Assurance Standard (DQAS)
Version: 1.0
Scope: All structured and unstructured data repositories, data pipelines, and consumer-facing reports.
Objective: To ensure data is fit for purpose, accurate, consistent, and trustworthy throughout its lifecycle.
1. The Six Dimensions of Quality
All data must be measured against these six dimensions. Corrections are triggered when data falls below the defined threshold for any dimension.
| Dimension | Definition | Example Metric |
|---|
| Accuracy | The degree to which data correctly represents the real-world entity. | % Match against verified external source (e.g., zip codes). |
| Completeness | The degree to which all required data is present. | % of records with NOT NULL values in mandatory fields. |
| Consistency | The degree to which data is the same across datasets. | % Match between Source System A and Data Warehouse B. |
| Timeliness | The degree to which data is available when needed. | Latency (Time between event creation and data availability). |
| Uniqueness | The degree to which records are non-duplicated. | Count of duplicate IDs / Total Count. |
| Validity | The degree to which data conforms to defined formats. | % of emails containing "@" and a domain. |
2. Roles and Responsibilities
- Data Owner: The business authority responsible for the definition and quality of the data domain (e.g., "Sales Data Owner").
- Data Steward: The operational role responsible for day-to-day quality monitoring and executing manual corrections.
- Data Engineer: The technical role responsible for pipeline integrity, automated testing, and implementing systematic fixes.
- Data Consumer: The end-user reporting suspected data issues.
3. Data Quality Assurance Framework (Prevention)
3.1. Ingress Controls (Input Validation)
No data shall enter the system of record without passing "Gatekeeper" tests.
- Schema Validation: JSON/Parquet/SQL schemas must be enforced; pipeline failures occur if schema drift is detected.
- Range/Format Checks: Dates must be ISO-8601; ages must be between 0-120.
- Referential Integrity: Foreign keys must exist in the master table before insertion.
3.2. Pipeline Observability
- Automated Anomaly Detection: Statistical models (e.g., Great Expectations, dbt tests) shall monitor volume and distribution. A sudden 50% drop in row count triggers a high-severity alert.
- Freshness Monitors: Alerts are triggered if data ingestion lags by >15 minutes.
4. Correction Flows (Remediation)
When an error is detected (via automated alert or consumer report), the following standard correction flows are initiated based on the severity and source of the error.
4.1. Standard Correction Workflow (The Lifecycle)
Step 1: Detection & Logging
- Trigger: Automated Test Failure OR User Ticket (Jira/ServiceNow).
- Action: Log the incident in the Data Quality Registry.
- Classification:
- P1 Critical: Financial/PII data compromised (Immediate action).
- P2 High: Major Reporting Broken (Action < 4 hours).
- P3 Medium: Minor Inaccuracies (Action < 24 hours).
Step 2: Triage & Root Cause Analysis (RCA)
- Is it a Code Bug? (Logic error in transformation).
- Is it an Upstream Issue? (Source system sent bad data).
- Is it a Transient Error? (Network timeout).
Step 3: Execution of Correction Strategy
- Select Flow A, B, or C below based on RCA.
Step 4: Verification
- Re-run quality tests on the corrected dataset.
- Obtain sign-off from Data Consumer/Owner.
Step 5: Prevention
- Update documentation and regression tests to prevent recurrence.
4.2. Detailed Correction Flows
Flow A: The "Backfill" (Upstream Source Error)
Used when the source system sent bad data, or data was missed during ingestion.
- Stop Ingestion: Pause the pipeline to prevent further contamination.
- Isolate: Quarantine bad data into a "Dead Letter Queue" or staging table.
- Rectify Source: Work with the source system owner to fix the data at the origin.
- Trigger Backfill: Re-run the pipeline for the specific time range.
- Validate: Ensure counts and checksums match the source.
Flow B: The "Transformation Patch" (Logic/Code Bug)
Used when SQL/Python code calculated metrics incorrectly, but the raw data is fine.
- Hotfix Code: Update the transformation logic (e.g., dbt model, Spark job).
- Re-Process: Run the model specifically for the affected date range (incremental run).
- Downstream Cascade: Force refresh any dependent BI dashboards or cached layers.
- Notify: Alert consumers that historical reports have changed (Data Restatement Notice).
Flow C: The "Manual Stewardship" (One-off Human Error)
Used for low-volume, high-complexity errors that cannot be fixed programmatically (e.g., fixing a typo in a legal contract text field).
- Request Access: Data Steward requests "Write" access to the specific record (Golden Record).
- Audit Trail: All manual changes must be logged with
Modified_By, Timestamp, and Reason.
- Update: The record is updated.
- Propagate: Trigger the specific record ID to refresh in the downstream Data Warehouse.
5. Severity Matrix & Service Level Agreements (SLAs)
| Severity Level | Description | Detection Method | Response Time (SLA) | Resolution Target |
|---|
| SEV-1 | Data Breach / Revenue Loss | Alert / Audit | 15 Minutes | 4 Hours |
| SEV-2 | Executive Reporting Broken | Automated Test | 1 Hour | 8 Hours |
| SEV-3 | Single Dept. Reporting Delay | Scheduled Check | 4 Hours | 24 Hours |
| SEV-4 | Minor Cosmetic / Non-Critical | User Report | 24 Hours | 3 Days |
6. Policy Enforcement
- No "Dark Fixes": Direct manipulation of production databases is prohibited. All fixes must go through the defined correction flows to ensure auditability.
- Testing Requirement: Any data model fix must be accompanied by a new automated test case to prevent regression.
- Governance: A monthly "Data Quality Scorecard" will be presented to leadership, measuring the number of incidents and mean-time-to-resolution (MTTR).