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

# AI-Generated Image & Video Detection

> Detect AI-generated media, identify deepfakes, and locate AI-manipulated regions.

Deploy's AI-Generated Image & Video Detection API analyzes images and videos for signs of AI generation and manipulation. A single endpoint combines AI-generated media detection and deepfake detection, with an additional segmentation capability for images.

## Detection Capabilities

> [card] AI-Generated Media Detection
>
> Determine whether an image or video is AI-generated and identify its likely generative source.

> [card] Deepfake Detection
>
> Identify AI-manipulated faces and return a confidence score indicating potential deepfake content.

> [card] AI Segmentation (Beta)
>
> Locate regions of an image that show signs of AI manipulation and retrieve a segmentation mask.

## AI-Generated Media Detection

The model determines whether an image or video was generated by AI. It is trained on millions of AI-generated and human-created images, including photographs, digital artwork, traditional art, and memes.

The response provides:

* **Generation classification:** Whether the content is AI-generated.
* **Source attribution:** The likely generative model or platform.
* **Confidence scores:** Scores for each classification.
* **C2PA metadata:** Information about where the image came from, when available.

### Classification Outputs

| Classification | Description |
| - | - |
| `ai_generated` | Confidence that the media is AI-generated |
| `not_ai_generated` | Confidence that the media is not AI-generated |
| Source classes | Confidence scores for supported generative models |
| `deepfake` | Confidence that the media contains a deepfake. |
| `ai_segmentation` | Confidence that the image contains AI-manipulated regions |

### Supported Generative Models

The source classifier supports a wide range of image and video generators, including Midjourney, DALL-E, Firefly, Flux, Runway, Sora, Gemini, and others.

> [accordion] View all supported source classes
>
> sora, pika, haiper, kling, luma, hedra, runway, hailuo, mochi, flux, hallo, hunyuan, recraft, leonardo, luminagpt, var, liveportrait, mcnet, pyramidflows, sadtalker, aniportrait, cogvideos, makeittalk, sdxlinpaint, stablediffusioninpaint, bingimagecreator, adobefirefly, lcm, dalle, pixart, glide, stablediffusion, imagen, amused, stablecascade, midjourney, deepfloyd, gan, stablediffusionxl, vqdiffusion, kandinsky, wuerstchen, titan, ideogram, sana, emu3, omnigen, flashvideo, transpixar, cosmos, janus, dmd2, switti, 4o, grok, wan, infinity, veo3, imagen4, krea, moonvalley, higgsfield, gemini, reve, heygen, sora2, seedream, seedance, grokimagine, gemini3, mai, lucid, sanavideo, flux2, qwen, zimage, viduq2, bria, blip3o, pixverse, ovis, longcat, cogview, bagel, ray3, gptimage1\_5, hidream, steadydancer, ltx, personalive, dreamid, scail, meta, vibe, imagineart, seedance2, happyhorse.
>
> **Additional classes:**
>
> * `other_image_generators`: AI-generated content from an unlisted source
> * `inconclusive`: Source could not be confidently identified
> * `inconclusive_video`: No video source identified
> * `none`: No AI generator is associated with the content.

> [!NOTE]
>
> Source attribution is separate from AI-generation detection. Content may be identified as AI-generated even when the specific source cannot be determined.

### C2PA Metadata

When available, the API also returns C2PA metadata containing information about the media's origin, such as which AI model created it.

Because metadata can be removed or falsified, we recommend interpreting it alongside the model's detection results.

## Deepfake Detection

The Deepfake Detection model identifies potential AI-based face manipulations in images and videos.

It operates in two stages:

**1. Face Detection**

Identifies faces present in the input media.

**2. Deepfake Classification**

Evaluates each detected face for signs of AI manipulation and assigns a confidence score between 0 and 1.

The API returns the highest confidence score across all detected faces under the `deepfake` class.

A score closer to 1 indicates stronger evidence of deepfake manipulation, while a score closer to 0 indicates weaker evidence.

## AI Segmentation

Beta

AI Segmentation identifies regions of an image that show signs of AI manipulation, including areas where objects have been added, replaced, or removed using AI.

For an input image, the model can return:

* **Segmentation confidence:** A score indicating evidence of AI manipulation.
* **Segmentation mask:** A URL to a binary mask highlighting detected AI-manipulated regions.

Both the segmentation confidence score and mask can detect AI manipulation in partially edited and fully AI-generated images.

> [!NOTE]
>
> A high segmentation confidence score does not necessarily mean an image was partially edited. Fully AI-generated images can also receive high scores and produce segmentation masks.

## Recommended Detection Thresholds

We recommend the following thresholds as starting points for production workflows.

| Detection Type | Recommended Threshold |
| - | - |
| AI-Generated Image | Score ≥ 0.90 |
| AI-Generated Video | Score ≥ 0.90 on any frame |
| Deepfake Image | Score ≥ 0.90 |
| Deepfake Video | Score ≥ 0.50 on two consecutive frames, or 5% of all frames |
| AI Segmentation (Beta) | Score ≥ 0.50 |

> [!NOTE]
>
> These thresholds are general recommendations. For optimal performance, calibrate them using representative data from your use case and your tolerance for false positives and false negatives.

## Supported File Formats

> [tab] Images
>
> * GIF
> * JPG
> * PNG
> * WEBP

> [tab] Videos
>
> * MP4
> * WEBM
> * AVI
> * MKV
> * WMV
> * MOV

## API Reference

> [!NOTE]
>
> This API is currently only available on our legacy API. Please refer to our [AI-Generated Image & Video Detection API Reference](https://docs.thehive.ai/reference/ai-generated-image-and-video-detection-1) for more details.


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.