DATA ACCURACY & QUALITY INTELLIGENCE

Every cell in your data, probed and proven.

Misbar analyzes, cleans, and validates large-scale CSV datasets in the browser — purpose-built for Saudi national identifiers, mobile numbers, and Arabic text alongside standard international formats.

19
Auto-detected data types
23
Validation rule classes
10
Quality dimensions scored
customers_riyadh.csv VALIDATING
national_idSaudi National ID mobileSaudi Mobile cityText · Arabic joinedTimestamp status
Normalizing Arabic digits… DQ Index 78%
System Architecture البنية

Seven engines. One workspace.

A secure Flask backend paired with a fully responsive, framework-free JavaScript frontend delivers a desktop-grade data-preparation experience directly in the browser.

Backend Server

Flask application handling routing, session security, permission enforcement, and the CSV upload endpoint.

Data Parsing Layer

Delimiter sniffing, 19-class type inference, and index-mapped row formatting for compact network payloads.

Cleaning Engine

Whitespace, casing, fill/blank, fuzzy clustering, sandboxed expression transforms, and Unicode/Arabic/date/number/currency normalization.

Schema Engine

Split, join, derive, rename, remove, and move column operations — with facets and rules cleaned up automatically.

Facet Engine

Numeric bins, box-plot statistics, scatterplot coordinates, duplicate detection, and text filtering — computed server-side.

Database Layer

Parameterized queries with automatic MySQL-to-SQLite fallback and schema self-upgrade on startup.

Frontend Controller

A 5,500+ line asynchronous single-page state machine covering the grid, facets, validation, statistics, DQ scoring, history, and administration UI.

Intelligent Ingestion الاستيعاب الذكي

19-class automatic type inference

Uploads are sniffed for delimiter, stripped of blank rows, and converted to a compact index-mapped structure. Then every column's first 100 non-empty values run through a cascade of pattern detectors.

70% confidence threshold — if any single type reaches 70% across the sample, the column is classified and pre-seeded with a sensible default rule set. Every upload is logged to the database and a local audit CSV.
JSONParses as valid JSON
UUIDCanonical 8-4-4-4-12 hex pattern
IP AddressIPv4 / IPv6 syntax
MAC Address6-octet hex pattern
Emaillocal@domain syntax
URLhttp(s)/www or domain syntax
Saudi National ID10 digits starting with '1'
Resident / Iqama ID10 digits starting with '2'
Saudi Mobile Number05xxxxxxxx / +9665xxxxxxxx
PhoneGeneral international phone pattern
Postal Code5 digits
Booleantrue/false, yes/no, y/n, 1/0, t/f
Timestamp / DateOne of 13 recognized date(-time) formats
CurrencyNumeric with a currency symbol or code
LatitudeValid geographic range + column-name hint
LongitudeValid geographic range + column-name hint
NumberParses cleanly as a float
Text (default)Fallback below 70% confidence
Manual OverrideReclassify any column from its context menu
International formats Regional (KSA) detectors
Core Workspace مساحة العمل

A grid built for real analysis sessions

A paginated grid — 100 rows per page — with sticky headers, drag-resizable columns, and per-cell status highlighting, surrounded by tool panels you can rearrange to fit your screen.

Column context menu

Every header exposes a single dropdown with every relevant facet, cleaning, schema, and validation action for that column's detected type.

Multi-select & bulk actions

Select several columns and a floating action bar appears — validate or facet them together in one step.

Row status indicators

Live status pills — All good, Worth a look, Needs fixing, or Pending — reflecting each row's worst active validation outcome.

Responsive side panels

Collapsible, drag-resizable panels (220–700px) for Facets, Rules, History, Export, Stats, and DQ Dimensions — with an off-canvas drawer below 860px.

Layouts & themes

Both Bars, Left Only, or Right Only layouts, plus light and dark themes persisted via localStorage.

Toast notifications

A bottom-center toast confirms success, surfaces errors, and explains permission-denied actions throughout the app.

Profiling & Facets التحليل

An instant statistical lens on any column

Facets are computed server-side for performance and rendered as interactive panels — each with its own PDF export.

Text facet

Unique values with counts and frequencies, sortable by name or count — click a term to filter the grid.

Numeric facet

Groups values into 12 equal-width histogram bins to reveal distribution and skew.

Box plot facet

Tukey five-number summary with 1.5× IQR whiskers, outlier detection, and a one-click "Filter outliers" control.

Scatterplot facet

Plots paired values between two numeric columns, aggregating repeated coordinates into density counts.

Duplicates facet

Surfaces every value occurring more than once, sorted by descending frequency.

Text filter facet

Substring or regular-expression matching with case-sensitivity and invert-match toggles.

Cleaning Engines التنظيف

From trimmed whitespace to repaired mojibake

Two tiers of column-wide operations — applied instantly, automatically re-validated, and recorded in the undo/redo history.

can_edit_cell

Standard operations

  • Trim / collapse whitespaceRemove leading/trailing spaces, or merge repeated inner spaces into one.
  • Case conversionConvert a column to Title Case, UPPERCASE, or lowercase.
  • Fill down / blank downPropagate the last non-blank value forward, or clear consecutive duplicates.
  • Cluster & edit (fuzzy merge)Group near-duplicates via Key Collision (Fingerprint) or Nearest-Neighbor (Levenshtein) clustering, then merge to one canonical value.
  • Transform by expressionSandboxed Python expression per row — referencing value and row[...] — with a live 10-row preview and inline error reporting.
can_advanced_clean

Advanced & regional operations

  • Unicode normalization (NFKC)Collapse visually-identical compatibility characters into one canonical form.
  • Accent / diacritic removalStrip accents via NFD decomposition — é becomes plain e.
  • Arabic text normalizationRemove Tashkeel diacritics and normalize Alef, Teh Marbuta, Yeh, and Tatweel variants.
  • Emoji / invisible / control removalStrip emoji glyphs, zero-width characters, and non-printable control characters.
  • Encoding repairDetect and repair common Latin-1/CP1252 mojibake via re-encode/decode round-trips.
  • Date / number / currency normalizationParse 13+ date formats into ISO 8601; convert Arabic/Persian digits and mixed separators; strip currency symbols into clean numerics.
Schema Operations البنية العمودية

Reshape columns without leaving the grid

Split into columns

Split values into adjacent columns via a string or regex delimiter, with an optional limit and source-column removal.

Join columns

Combine multiple selected columns with a chosen delimiter into one new, named column.

Add derived column

Compute a new column from a Python expression evaluated against other cells in each row.

Rename / remove / move

Relabel, delete, or reposition columns — associated facets and validation rules are cleaned up automatically.

Manual type override

Reclassify a column's detected type from the context menu, instantly refreshing its default rules and reports.

Validation Engine التحقق

23 rule classes. Three severities. One policy.

Attach rules to one or many columns at once. Export rule sets as a CSV template and re-import them in bulk to replicate a data-quality policy across similar datasets.

Error — red cell highlight Warning — orange highlight Info — blue highlight
RuleClassChecks
Not emptyCoreFlags blank / null / whitespace-only cells
Pattern (regex)CoreMatch against a custom regular expression
Number rangeCoreNumeric value within a min–max range
Allowed valuesCoreValue is in a semicolon-separated whitelist
Unique (no duplicates)CoreNo repeated values in the column
Expression (GREL)CoreCustom boolean expression per row
Valid Email / URL / PhoneFormatStandard format syntax checks
Valid Saudi National ID / Iqama / MobileRegional (KSA)Structural checks for Saudi identifiers and numbers
Valid Latitude / LongitudeGeospatialNumeric within valid geographic bounds
Valid Date / TimestampTemporalParses as a real calendar date or date-time
Valid Currency / Boolean / JSON / UUIDFormatStructural / semantic format checks
Valid IP / MAC / Postal CodeNetwork & FormatStructural pattern checks

Instant grid highlighting

Cell backgrounds turn red, orange, or blue with hover tooltips explaining exactly why a value failed.

Validation reports sidebar

Aggregates issue counts per column and per rule, expandable down to the specific failing row indices.

Rule templates

Export a rule set as CSV and re-import it in bulk — one quality policy, many datasets.

Quality Scoring مؤشر الجودة

The 10-dimension Data Quality Index

A defensible, quantified quality score — the equal-weighted average of ten dimensions, rendered as color-coded progress bars and exportable as CSV or a formatted PDF scorecard.

Completeness(Total − Missing) / Total × 100
Accuracy(Non-missing − Errors) / Non-missing × 100
Validity(Non-missing − Errors − Warnings) / Non-missing × 100
TimelinessShare of date values not in the future
ConsistencyAvg of casing + whitespace consistency
UniquenessDistinct non-missing / total non-missing × 100
Integrity(Total − Invalid) / Total × 100
PrecisionConsistency of decimal places or value length
Reliability25% Compl. + 25% Acc. + 20% Val. + 15% Cons. + 15% Integ.
Traceability100 if key/ID field, 85 if another key exists, else 50

Descriptive statistics — quantitative columns

ObservationsValidMissingDistinctMeanStd DevMinP01–P99Q1 / Median / Q3MaxRangeIQRModeCoeff. of VariationSkewnessKurtosisOutlier count

Descriptive statistics — qualitative columns

DistinctSingletonTop level2nd levelRarest levelShannon EntropyNormalized EntropyGini–Simpson index

A separate Statistical Functions panel rolls a subset into a weighted Quality Score — Completeness 30% + Consistency 30% + Accuracy 40% — for a fast per-column health check.

Access Control الصلاحيات

Ten permission flags, enforced on every route

Session-based authentication with PBKDF2-SHA256 password hashing and HTTP-only, SameSite cookies. Every sensitive server route is wrapped in a permission decorator, and superadmins manage access from an in-app console — no direct database access required.

PermissionGrants access to
can_uploadUploading new CSV files
can_facetBuilding and viewing facets / filters
can_edit_cellStandard cell cleaning operations
can_edit_columnSplit, join, rename, remove, move, derive columns
can_advanced_cleanUnicode / Arabic / encoding / date / number / currency normalization
can_validateCreating and running validation rules
can_view_statsViewing the Descriptive Statistics panel
can_view_dqViewing the Data Quality Dimensions panel
can_export_reportExporting reports and datasets
is_superadminBypasses all checks; exclusive User Management access
Recovery guarantee — the built-in superadmin account is protected against demotion or deletion, even by other superadmins, so there is always at least one recoverable administrative account.
Reporting & History التقارير

Everything exports. Everything rewinds.

Multi-format data export

CSV, TSV, or JSON — scoped to the full file, valid rows only, errors only, or warnings only.

Validation report export

A shareable CSV or print-ready PDF of validation results for audit or handoff.

Statistics & DQ export

Both analytical panels export independently to CSV or a styled PDF scorecard.

Facet chart export

Print the active histogram, box plot, or scatterplot to a PDF-ready layout.

Snapshot timeline

Every mutating action captures a full dataset snapshot. Click any History entry to jump directly to that exact point — not a linear undo stack.

Experiment freely

Aggressive transforms are safe when any state is one click away. That confidence is the point of the timeline.

Technology Stack التقنيات

Boring where it should be, fast where it counts

LayerTechnologyRole
BackendFlask 3.0 (Python)Routing, sessions, REST-style JSON APIs
Database (primary)MySQL via PyMySQLProduction multi-user persistence
Database (fallback)SQLite 3Automatic offline / dev fallback
SecurityWerkzeug Security · python-dotenv · cryptographyPassword hashing, secrets, session cookies
FrontendVanilla JavaScript (ES6+)Single-page state machine, no framework
StylingCSS custom properties · Plus Jakarta SansLight/dark theming, responsive layout
TemplatingJinja2 (Flask render_template)Server-rendered shell pages
Roadmap Transparency خارطة الطريق

Known gaps, tracked openly

Identified during the 2.0 review and tracked on the product roadmap — because a data-accuracy platform should be accurate about itself.

Native .xlsx exportThe 'Excel' export choice currently produces CSV-compatible output rather than a native .xlsx file.
Live export historyThe 'Recent exports' list in the Export panel is illustrative placeholder text, not a live history.
Persistent sign-in & reset'Keep me signed in' and 'Forgot password?' appear in the UI but are not yet wired to backend logic.
Timeline facetThe Timeline facet option is a decorative preview, not yet driven by real date-column binning.

Put your data under the probe.

Misbar 2.0 is internal product documentation made real — upload a CSV, watch 19 detectors classify it, and walk away with a defensible quality scorecard.

Request access