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

# Claude Fable 5.1

> Claude Fable 5.1: 1M-context model for demanding reasoning, long-running agentic coding, and multistep research.

Claude Fable 5.1 is Anthropic's high-capability model for demanding reasoning and long-horizon agents for demanding reasoning, long-running agentic coding, multistep research, and complex knowledge work.

Call `claude-fable-5-1` through MixRoute's Anthropic-compatible Messages API; the OpenAI-compatible Chat Completions API is also supported.

## Key capabilities

* Long context - Supports a 1M-token context window and up to 128K output tokens
* Adaptive thinking - Always-on adaptive thinking with high default effort
* Long-horizon work - Stronger agentic coding, multistep research, and document-heavy workflows
* Multimodal input - Accepts text and images and returns text
* Dual API support - Works through Anthropic-compatible Messages and OpenAI-compatible Chat Completions

## Quick example

### Messages API

<Tabs>
  <Tab title="cURL">
    ```bash theme={null}
    curl "https://api.mixroute.ai/v1/messages" \
      -H "Authorization: Bearer YOUR_API_KEY" \
      -H "anthropic-version: 2023-06-01" \
      -H "Content-Type: application/json" \
      -d '{
      "model": "claude-fable-5-1",
      "max_tokens": 256,
      "messages": [
        {
          "role": "user",
          "content": "Explain quantum entanglement in simple terms."
        }
      ]
    }'
    ```
  </Tab>

  <Tab title="Python">
    ```python theme={null}
    from anthropic import Anthropic

    client = Anthropic(api_key="YOUR_API_KEY", base_url="https://api.mixroute.ai")

    message = client.messages.create(
        model="claude-fable-5-1",
        max_tokens=256,
        messages=[{"role": "user", "content": "Explain quantum entanglement in simple terms."}],
    )

    print(message.content[0].text)
    ```
  </Tab>

  <Tab title="Streaming">
    ```python theme={null}
    from anthropic import Anthropic

    client = Anthropic(api_key="YOUR_API_KEY", base_url="https://api.mixroute.ai")

    with client.messages.stream(
        model="claude-fable-5-1",
        max_tokens=256,
        messages=[{"role": "user", "content": "Write a short poem about the sea."}],
    ) as stream:
        for text in stream.text_stream:
            print(text, end="")
    ```
  </Tab>
</Tabs>

### OpenAI-compatible API

<Tabs>
  <Tab title="cURL">
    ```bash theme={null}
    curl "https://api.mixroute.ai/v1/chat/completions" \
      -H "Authorization: Bearer YOUR_API_KEY" \
      -H "Content-Type: application/json" \
      -d '{
      "model": "claude-fable-5-1",
      "messages": [
        {
          "role": "user",
          "content": "Explain quantum entanglement in simple terms."
        }
      ],
      "max_tokens": 256
    }'
    ```
  </Tab>

  <Tab title="Python">
    ```python theme={null}
    from openai import OpenAI

    client = OpenAI(api_key="YOUR_API_KEY", base_url="https://api.mixroute.ai/v1")

    response = client.chat.completions.create(
        model="claude-fable-5-1",
        messages=[{"role": "user", "content": "Explain quantum entanglement in simple terms."}],
        max_tokens=256,
    )

    print(response.choices[0].message.content)
    ```
  </Tab>

  <Tab title="Streaming">
    ```python theme={null}
    from openai import OpenAI

    client = OpenAI(api_key="YOUR_API_KEY", base_url="https://api.mixroute.ai/v1")

    stream = client.chat.completions.create(
        model="claude-fable-5-1",
        messages=[{"role": "user", "content": "Write a short poem about the sea."}],
        max_tokens=256,
        stream=True,
    )

    for chunk in stream:
        print(chunk.choices[0].delta.content or "", end="")
    ```
  </Tab>
</Tabs>

## Parameters

### Messages API

| Parameter | Type | Required | Description |
| - | - | - | - |
| `model` | string | Yes | Must be `claude-fable-5-1`. |
| `messages` | array | Yes | Input messages with role and content. |
| `max_tokens` | integer | Yes | Maximum tokens to generate. |
| `system` | string \| array | No | Top-level system instruction. |
| `stream` | boolean | No | Enable SSE streaming. |
| `tools` | array | No | Anthropic tool definitions. |
| `thinking` | object | No | Extended-thinking configuration when supported. |

### OpenAI-compatible API

| Parameter | Type | Required | Description |
| - | - | - | - |
| `model` | string | Yes | Must be `claude-fable-5-1`. |
| `messages` | array | Yes | Conversation messages with role and content. |
| `max_tokens` | integer | No | Maximum generated tokens. |
| `stream` | boolean | No | Enable SSE streaming. Default: false. |
| `temperature` | number | No | Sampling temperature when supported by the model. |
| `top_p` | number | No | Nucleus sampling threshold when supported. |
| `stop` | string \| array | No | Sequences that stop generation. |
| `tools` | array | No | OpenAI-compatible tool definitions. |


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