> For AI agents: the documentation index is at https://platform.detectif.ai/llms.txt. Every page is also available as Markdown by adding `.md` to its path.

# Aletheia

Deepfake detection. Aletheia checks a recording for AI-generated speech and tells you whether the voice is real, fake or not sure.

**Is this a real voice?** That is the question Aletheia answers. Use it through the [REST API](https://platform.detectif.ai/docs/api/#aletheia) or the [MCP server](https://platform.detectif.ai/docs/mcp/tools/#aletheia), with the same API key as the other products.

## What it does

- Checks one recording, longer than 4 seconds and at most 120 seconds, in any of the [supported formats](https://platform.detectif.ai/docs/audio-and-limits/).
- Answers with a `verdict` for the whole recording: `real`, `fake` or `not_sure`.
- Scores consecutive parts of the recording too, so you can see which parts sound AI-generated.
- Runs on its own, or together with an [Eidos](https://platform.detectif.ai/docs/eidos/#check-for-ai-generated-speech-at-the-same-time) speaker verification on the same recording.

## Read the result

Example response, shortened:

```json
{
  "request_id": "req_8f14e45fceea167a5a36dedd",
  "operation_id": "op_6f1ed002ab5595859014ebf0951522d9",
  "object": "deepfake.detection",
  "result": {
    "verdict": "real",
    "score": 0.0731,
    "duration_seconds": 6.4,
    "segments": [
      { "start": 0, "end": 4, "score": 0.061 },
      { "start": 2, "end": 6.4, "score": 0.085 }
    ]
  }
}
```

| Field | Meaning |
|---|---|
| `result.verdict` | The decision: `real`, `fake` (likely AI-generated) or `not_sure`. Decide with this field. |
| `result.score` | How likely the recording is AI-generated, from 0 to 1 (higher means more likely). Decide with `verdict`, not the score alone. |
| `result.segments` | Scores for consecutive, overlapping parts of the recording, with `start` and `end` in seconds. |
| `result.duration_seconds` | Length of the checked audio, in seconds. |
| `result.label`, `result.is_synthetic` | The same decision in older wording (`genuine`, `synthetic`, `uncertain`), kept for older clients. |
| `operation_id` | Fetch the result again later, for 30 days. |
| `request_id` | Include it when you contact support. |

The full list of fields is in [Detect AI-generated speech](https://platform.detectif.ai/docs/api/aletheia/detect-deepfake/).

### Not sure

`not_sure` means the recording cannot be judged reliably. Try a longer or cleaner recording.

### Recording length

The recording must be longer than 4 seconds and at most 120 seconds. A recording of 4 seconds or less is refused with `422` and the error code `audio_too_short`; one over 120 seconds with `audio_too_long`. Trim long recordings to the part you want checked.

### Use the verdict well

- A verdict is a strong signal, not proof. Use it with other checks, and have a person review decisions that matter.
- Phone-quality audio (calls, voice messages) gives less reliable results than clear recordings.
- The check is tuned for English speech.

## Quickstart

Create an API key first (see [Authentication](https://platform.detectif.ai/docs/authentication/)), then send a recording as the multipart field `file`:

```bash
curl https://platform.detectif.ai/v1/deepfake/detect \
  -H "Authorization: Bearer $DETECTIF_API_KEY" \
  -H "Idempotency-Key: $(uuidgen)" \
  -F "file=@clip.wav"
```

```python
import os
import uuid

import requests

with open("clip.wav", "rb") as f:
    resp = requests.post(
        "https://platform.detectif.ai/v1/deepfake/detect",
        headers={
            "Authorization": f"Bearer {os.environ['DETECTIF_API_KEY']}",
            "Idempotency-Key": str(uuid.uuid4()),
        },
        files={"file": f},
        timeout=300,
    )
resp.raise_for_status()
result = resp.json()["result"]
print(result["verdict"], result["score"])
```

Send the same `Idempotency-Key` when you retry, and you get the stored result back instead of a second check.

With [MCP](https://platform.detectif.ai/docs/mcp/), connect your assistant and ask:

```
Check if /path/call.wav is AI-generated.
```

```
Which parts of /path/call.wav sound AI-generated?
```

The assistant calls `detect_deepfake` with the recording and reads the verdict for you.

Uploaded files are stored for 30 days. Send `store_audio=false` (in MCP, the `store_audio` argument) to not store a file; see [Privacy](https://platform.detectif.ai/docs/privacy/).

## After the check

- **Fetch the result again.** Results are kept for 30 days. [Get a result](https://platform.detectif.ai/docs/api/account/get-operation/) (`GET /v1/operations/{operation_id}`, or the `get_operation` tool) returns it by its `operation_id`, for example when your connection dropped before the response arrived. It is shared with Eidos, so it is listed under Account.
- **Tell us whether it was right.** [Say whether a result was right](https://platform.detectif.ai/docs/api/aletheia/send-feedback/) sends `correct`, and optionally what the recording really is (`real` or `fake`) and a short note. Your answer is stored with the result, not the audio.

## API reference

Base URL: `https://platform.detectif.ai`.

| Method | Path | Page |
|---|---|---|
| `POST` | `/v1/deepfake/detect` | [Detect AI-generated speech](https://platform.detectif.ai/docs/api/aletheia/detect-deepfake/) |
| `POST` | `/v1/operations/{operation_id}/feedback` | [Say whether a result was right](https://platform.detectif.ai/docs/api/aletheia/send-feedback/) |
| `GET` | `/v1/operations/{operation_id}` | [Get a result](https://platform.detectif.ai/docs/api/account/get-operation/). Shared with Eidos, listed under Account. |

## MCP tools

| Tool | What it does | Inputs |
|---|---|---|
| [`detect_deepfake`](https://platform.detectif.ai/docs/mcp/tools/#aletheia) | Check a recording (longer than 4 s, up to 120 s) for AI-generated speech. | `audio_base64`, `filename`, `idempotency_key` (optional), `store_audio` (optional) |
| [`get_operation`](https://platform.detectif.ai/docs/mcp/tools/#account) | Fetch a stored operation: status and, for 30 days, its result. Shared with Eidos, listed under Account. | `operation_id` |
