Skip to content

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

17 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

System Dataflow Analysis and Exception Remediation Prototype

What This Project Is

This project is a portfolio prototype that simulates how reporting problems emerge across enterprise dataflows and how they can be investigated in a structured, business-aware way.

It is built around a simple but realistic scenario: a daily cash movement reporting process takes records from a source system, passes them through a transformation / ETL layer, and publishes them into a downstream reporting layer. The goal of the prototype is to show what happens when that flow breaks and how a systems-oriented analyst can detect, document, validate, and remediate those issues.

In short, this is not just a data project. It is a system dataflow investigation project designed to reflect the kind of work involved in technical business analysis, reporting workflow analysis, and exception investigation roles.


The Core Problem

In enterprise environments, reporting errors are often not caused by one obvious system failure. A report can become unreliable because problems are introduced at different points in the workflow, such as:

  • a record never reaching the downstream layer
  • the same record being published twice
  • an amount being transformed incorrectly
  • a category being mapped inconsistently
  • a record arriving too late for the expected reporting cutoff

When this happens, the real task is not just to “find the bad record.” The real task is to understand:

  1. where the record moved through the workflow
  2. where the logic broke down
  3. how to prove the issue with repeatable checks
  4. how to turn findings into remediation and control improvements

That is the problem this prototype is built to simulate.


What This Prototype Does

This prototype models a closed-loop investigation process across three system layers:

  1. Source Layer
    Raw cash movement records enter the workflow with original account IDs, dates, amounts, movement types, and statuses.

  2. Transformation / ETL Layer
    Records are standardized, mapped, normalized, validated, and prepared for publication.

  3. Downstream Reporting Layer
    Final reporting outputs are produced for business review and monitoring.

The project then introduces seeded exceptions into that workflow and investigates them using:

  • SQL-based exception checks
  • Python + DuckDB execution
  • structured issue logging
  • QA / UAT-style test cases
  • findings summaries
  • remediation and control recommendations

The result is a prototype that shows not only how exceptions are detected, but also how investigation findings feed back into workflow improvement.


System Workflow Diagram

System Dataflow Analysis & Exception Remediation


A Simple Narrative of the Project

If someone asked, “What is this project actually doing?”, the shortest answer would be:

This project simulates a reporting workflow, intentionally introduces dataflow errors, detects them with SQL checks, documents the findings, validates the results, and closes the loop with remediation and control recommendations.

That narrative is the backbone of the entire repository:

workflow → exception → investigation → validation → findings → remediation → workflow improvement


Seeded Dataflow Exceptions

To make the investigation realistic, the prototype includes five intentionally seeded exception types.

Transaction ID Exception Type What It Means
TXN1005 Missing Record The record exists upstream but never appears in downstream reporting
TXN1007 Duplicate Record The same record appears more than once in downstream reporting
TXN1008 Classification Mismatch The downstream category does not match the transformed mapping
TXN1009 Amount Mismatch The downstream amount differs from the transformed normalized amount
TXN1010 Timing Mismatch The record is processed or reported later than its original business date

These exceptions were chosen because they reflect common reporting integrity problems in enterprise workflows.


How the Investigation Works

Step 1: Build the Workflow Context

The prototype starts by defining the business scenario, the dataflow layers, and the field mappings between source, transformation, and downstream reporting.

Relevant files:

  • docs/business-context.md
  • docs/field-mapping.md

Step 2: Seed Known Exceptions

The data is intentionally structured so that specific transaction records contain known issues that should be detectable later.

Relevant files:

  • data/source_cash_movements.csv
  • data/transformed_cash_movements.csv
  • data/downstream_cash_report.csv

Step 3: Detect Exceptions with SQL

The prototype uses targeted SQL checks to identify missing records, duplicates, amount mismatches, classification mismatches, and timing issues.

Relevant files:

  • sql/01_missing_records.sql
  • sql/02_duplicate_records.sql
  • sql/03_amount_mismatch.sql
  • sql/04_classification_mismatch.sql
  • sql/05_timing_mismatch.sql

Step 4: Execute Checks Reproducibly

A Python runner uses DuckDB to execute the SQL checks directly against the CSV data and save the outputs.

Relevant file:

  • python/run_sql_checks.py

Generated outputs:

  • data/query_results/

Step 5: Document and Validate the Findings

The prototype records each issue in a structured issue log, then validates the expected vs observed outcomes through test cases.

Relevant files:

  • docs/issue-log.md
  • docs/test-cases.md

Step 6: Summarize Findings and Recommend Controls

The final stage translates investigation results into findings, root cause themes, and remediation/control recommendations.

Relevant file:

  • docs/final-findings.md

This creates a closed-loop investigation model rather than a one-time detection script.


Repository Structure

system-dataflow-investigation-prototype/
├── README.md
├── data/
│   ├── source_cash_movements.csv
│   ├── transformed_cash_movements.csv
│   ├── downstream_cash_report.csv
│   └── query_results/
├── docs/
│   ├── business-context.md
│   ├── field-mapping.md
│   ├── issue-log.md
│   ├── test-cases.md
│   ├── final-findings.md
│   └── prototype-workflow.png
├── python/
│   └── run_sql_checks.py
└── sql/
    ├── 01_missing_records.sql
    ├── 02_duplicate_records.sql
    ├── 03_amount_mismatch.sql
    ├── 04_classification_mismatch.sql
    └── 05_timing_mismatch.sql


About

System dataflow analysis, exception investigation, and remediation prototype for enterprise-style reporting workflows.

Resources

Stars

Watchers

Forks

Releases

Packages

Contributors

Languages