> ## Documentation Index
> Fetch the complete documentation index at: https://docs.traceback.cc/llms.txt
> Use this file to discover all available pages before exploring further.

# How Traceback Works

> Understanding the ingestion pipeline, symbolication engine, and AI diagnostic architecture.

Traceback is engineered to provide end-to-end visibility into runtime anomalies with sub-millisecond client latency and distributed tracing accuracy.

## Architecture Overview

```mermaid theme={null}
flowchart TB
    subgraph Client["Your Infrastructure"]
        Browser[Browser / Mobile SDK]
        Backend[Backend Services / Lambdas]
        OpenTelemetry[OTel Collector]
    end

    subgraph Ingest["Edge Ingestion Network"]
        EdgeGate[High-throughput Edge Gateway]
        RateLimiter[Sampling & Scrubbing]
    end

    subgraph Processing["Traceback Core Processing"]
        Symbolizer[Source Map & Symbolication Engine]
        Fingerprinter[Issue Grouping & De-duplication]
        AIDiagnostics[AI Root Cause & Patch Engine]
        Storage[(ClickHouse & Time Series Store)]
    end

    subgraph UI["Developer Surfaces"]
        WebDashboard[Real-time Web Dashboard]
        Alerts[Slack / PagerDuty / Linear]
        API[REST & GraphQL API]
    end

    Browser --> EdgeGate
    Backend --> EdgeGate
    OpenTelemetry --> EdgeGate

    EdgeGate --> RateLimiter
    RateLimiter --> Symbolizer
    Symbolizer --> Fingerprinter
    Fingerprinter --> AIDiagnostics
    AIDiagnostics --> Storage

    Storage --> WebDashboard
    AIDiagnostics --> Alerts
    Storage --> API
```

***

## 1. Zero-Impact Capture

The Traceback SDK installs lightweight runtime interceptors (`window.onerror`, `unhandledrejection`, panic hooks, and async wrapper chains). Payloads are batched and dispatched asynchronously via `navigator.sendBeacon` or background worker queues without blocking the main event loop.

## 2. PII Scrubbing & Data Masking

Before telemetry leaves the client environment, configurable scrubbers automatically sanitize:

* Passwords, credit cards, and authorization headers
* DOM input fields and form elements
* Custom regex-defined sensitive keys

## 3. Symbolication

When a minified stack trace arrives, Traceback references your uploaded source maps or native debug symbols (dSYMs, ProGuard mappings, ELF debuginfo) to reconstruct original source lines, variable names, and column numbers.

## 4. Intelligent Fingerprinting

Similar exceptions occurring across millions of sessions are clustered using AST structural fingerprinting, preventing alert fatigue and isolating new regressions from known background noise.

## 5. AI Root Cause Synthesis

For every newly surfaced issue, Traceback's AI engine inspects the stack frames, correlated telemetry spans, recent git commits, and breadcrumbs to generate a natural language diagnosis and proposed code fix.
