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

# Detect and Respond to Anomalies

> Detect process anomalies across instruments, predict quality outcomes, and take corrective action

Atomscale monitors your process data for anomalies using learned embeddings to catch subtle patterns across instruments, correlate anomalies across data sources, and predict developing problems. Depending on your integration level, the platform can recommend or execute corrective actions.

## What Gets Detected

Anomaly detection covers three general categories:

<Tabs>
  <Tab title="Point and Drift">
    **Unusual patterns in individual timeseries.** The system encodes timeseries windows into a learned representation using a timeseries model fine-tuned on process data. Outliers in this latent space correspond to patterns that deviate from what the model has learned as normal for your process.

    This captures both sudden anomalies and gradual drift. Because detection operates on learned embeddings rather than fixed thresholds, it catches subtle structural changes that raw value comparisons miss.

    Recipe-data drift is also detected for metrology sources by comparing measured values against expected recipe setpoints.
  </Tab>

  <Tab title="Cross-Source">
    **Co-occurring anomalies across instruments that tell a coherent story.** A temperature drift that coincides with a RHEED spot spacing change and an optical morphology shift is a stronger signal than any one alone.

    After per-parameter detection completes, the system identifies temporal overlaps and embedding-space similarities to group related anomalies. Correlated groups carry compound severity: multiple instruments flagging simultaneously is stronger evidence of a real process deviation.
  </Tab>

  <Tab title="Predictive">
    **Problems detected before they fully develop.** The system forecasts timeseries trajectories with confidence intervals. When the forecast crosses an anomaly threshold, a predicted anomaly is flagged for advance warning.

    A **growth quality score** tracks run health in real time by combining signals from all active data sources into a probability of the final outcome meeting your target specifications. A dropping quality score can signal a compound process shift even when no individual parameter has triggered an error.
  </Tab>
</Tabs>

## Viewing Anomalies

### On Timeseries Charts

Anomalies appear directly on timeseries plots:

| Anomaly Type     | Visual Indicator                                         |
| ---------------- | -------------------------------------------------------- |
| Point anomaly    | Marker at the detected timestamp                         |
| Drift anomaly    | Highlighted region spanning the detection window         |
| Correlated group | Highlighted region spanning the detection window         |
| Forecast anomaly | Dashed region in the projected portion of the timeseries |

Markers are color-coded by severity: <Badge stroke color="yellow">Warning</Badge> and <Badge stroke color="red">Error</Badge>. Click any marker to see the anomaly type, classification label, score, and detection metadata. The growth quality score displays as a running overlay on the monitoring dashboard.

### Anomaly Summary

Each run includes an anomaly summary with:

* Counts by type and severity
* Growth quality score for the run
* Anomaly classification labels
* Correlated anomaly groups

Zero errors with a few warnings and a high quality score likely means a normal run. Multiple errors or a low quality score warrants investigation.

### Filtering and Querying

You can filter anomalies by:

| Filter               | Options                                                                    |
| -------------------- | -------------------------------------------------------------------------- |
| Data source          | Any data source (e.g. characterization or tool state)                      |
| Anomaly type         | Point anomaly, drift, recipe-data drift, predicted anomaly                 |
| Classification       | Root cause category                                                        |
| Severity             | Warning or error                                                           |
| Correlated groups    | Only anomalies correlated across sources                                   |
| Time range           | Before or after a given time                                               |
| Property             | Specific timeseries property (e.g., pyrometer channel, RHEED spot spacing) |
| Quality score impact | How much the anomaly affected the growth quality score                     |

## Real-Time Alerts

During streaming runs, anomaly detections are delivered in real time to any of the following channels:

<CardGroup cols={2}>
  <Card title="Platform" icon="bell">
    Alerts appear in the monitoring dashboard and notification panel during active runs.
  </Card>

  <Card title="Email" icon="envelope">
    Email notifications including anomaly details and a link to the
    affected growth session.
  </Card>

  <Card title="Slack" icon="slack">
    Route alerts to create messages in Slack channels.
  </Card>

  <Card title="Custom" icon="sliders">
    Configure custom alerting channels.
  </Card>
</CardGroup>

### Per-Project Thresholds

Each project can override detection thresholds. Tighten sensitivity for critical parameters or relax thresholds for parameters with known noise. Configuration is available under project settings.

Default thresholds are learned baselines calibrated from your organization's historical data. Per-project overrides build on top of these defaults.

## Responding to Anomalies

### During an Active Run

When an anomaly is detected during a live run, Atomscale surfaces it alongside a recommended corrective action.

<Steps>
  <Step title="Review the alert and recommended action">
    Check which parameter triggered, its severity, classification, and detection window. The system
    shows a recommended corrective action
    with the expected effect and confidence level.
  </Step>

  <Step title="Check the safety envelope">
    Review the safety envelope: the hard constraints for affected parameters that no corrective
    action can exceed. The recommended action is always within these bounds.
  </Step>

  <Step title="Approve, modify, or dismiss">
    Accept the recommended action, modify its parameters, or dismiss it. Approved or modified
    actions trigger effects depending on integration level (e.g. assist or control). Dismissed anomalies are logged
    as acknowledged with no intervention.
  </Step>

  <Step title="Monitor the intervention">
    Track actions and outcomes on an intervention history log. The log records the detection,
    the action taken, and subsequent parameter behavior to improve future recommendations.
  </Step>
</Steps>

For an overview of the progression from monitoring to autonomous control, see [Integrating Process Control](/platform/get-started/act#integrating-process-control).

### After Historical Data Upload

For historical data, anomaly detection provides diagnostic value. Review the anomaly timeline against your process log and ex-situ characterization to see whether detected anomalies correlate with quality outcomes. Confirmed and dismissed anomalies feed back into the classification model, and anomaly-outcome pairs contribute to growth quality score training.

## How Anomaly Detection Works

### Detection Process

As timeseries data arrives, characterization workflows extract features and embed them into the model's latent space. Outlier detection scores each embedding against learned baselines, then correlates related anomalies across instruments. A classification model assigns root cause categories, forecasts predicted anomalies, and routes to alert channels based on severity.

<Note>
  For more details, see the [Changepoint Detection - Technical Reference](/platform/reference/workflows/changepoint-detection#technical).
</Note>

### Batch Processing

When you upload historical data, anomaly detection runs automatically after the analysis pipeline completes. Each timeseries is evaluated independently, then cross-source correlation runs after all sources are processed. Anomalies appear in the UI once processing finishes.

### Live Streaming

During a live run, anomaly detection runs incrementally with each incoming data chunk. The system maintains a rolling detection context across chunks to detect both sudden anomalies and emerging trends. Forecasts and the growth quality score update with each chunk. Error-level anomalies trigger real-time alerts.

### Severity Levels

| Severity                                     | Meaning                                                                               | Action                                                                |
| -------------------------------------------- | ------------------------------------------------------------------------------------- | --------------------------------------------------------------------- |
| <Badge stroke color="yellow">Warning</Badge> | Score elevated but within tolerance, or minor quality score impact. May self-correct. | Review after the run or if warnings accumulate.                       |
| <Badge stroke color="red">Error</Badge>      | Score exceeds the critical threshold, or quality score has dropped significantly.     | Investigate immediately. Triggers real-time alerts in streaming runs. |

An anomaly that significantly drops the quality prediction is more likely to be assigned Error-level, even if its individual score is moderate.

### Thresholds and Sensitivity

The system uses learned baselines calibrated from your organization's historical data, adapted to the patterns of each data source, recipe, and instrument combination.

Per-project threshold overrides let you adjust sensitivity: relax thresholds for parameters with natural variation, or tighten them for critical parameters.

## Next Steps

<CardGroup cols={2}>
  <Card title="Diagnose Why a Run Differs" icon="code-compare" href="/platform/guides/diagnose-run-differences">
    When an anomaly is detected, compare the run against references to understand the deviation.
  </Card>

  <Card title="Identify Uniformity Issues" icon="chart-area" href="/platform/guides/identify-uniformity-issues">
    Find consistency problems within a single run that may not appear as time-domain anomalies.
  </Card>

  <Card title="Anomaly Detection Reference" icon="book" href="/platform/reference/workflows/changepoint-detection">
    Technical details on the embedding pipeline, outlier detection, and forecasting algorithms.
  </Card>

  <Card title="Python SDK" icon="python" href="/sdk">
    Programmatic access to anomaly data, alerts, and control actions.
  </Card>
</CardGroup>
