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

# claude-fable-5

> 根据对话上下文生成模型回复。



## OpenAPI

````yaml zh/api-reference/model-api/anthropic/openapi/claude-fable-5/openapi.yaml POST /v1/messages
openapi: 3.1.0
info:
  title: Claude Fable 5
  description: Anthropic Claude Fable 5 通过 AnyFast OpenAI 兼容接口调用。最强模型，自适应思维始终开启。
  version: 1.0.0
servers:
  - url: https://www.anyfast.ai
security:
  - bearerAuth: []
paths:
  /v1/messages:
    post:
      summary: 对话补全
      description: 根据对话上下文生成模型回复。
      operationId: createChatCompletionClaudeFable5
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              required:
                - model
                - messages
              properties:
                model:
                  type: string
                  enum:
                    - claude-fable-5
                  description: 模型 ID
                  example: claude-fable-5
                messages:
                  type: array
                  minItems: 1
                  description: 组成对话的消息列表。
                  items:
                    type: object
                    required:
                      - role
                      - content
                    properties:
                      role:
                        type: string
                        enum:
                          - system
                          - user
                          - assistant
                      content:
                        type: string
                  example:
                    - role: user
                      content: Hello!
                max_tokens:
                  type: integer
                  minimum: 1
                  maximum: 8192
                  default: 8192
                  description: 最大生成 Token 数。
                temperature:
                  type: number
                  minimum: 0
                  maximum: 2
                  default: 1
                  description: 采样温度。值越高输出越随机。
                  example: 1
                frequency_penalty:
                  type: number
                  minimum: -2
                  maximum: 2
                  default: 0
                  description: 根据文本中已有的频率惩罚重复 Token。
                presence_penalty:
                  type: number
                  minimum: -2
                  maximum: 2
                  default: 0
                  description: 惩罚已出现过的 Token。
                stream:
                  type: boolean
                  default: false
                  description: 设为 true 则通过 SSE 流式返回部分消息。
                stop:
                  oneOf:
                    - type: string
                    - type: array
                      items:
                        type: string
                  description: 触发模型停止生成后续 Token 的序列。
      responses:
        '200':
          description: 补全生成成功
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ChatCompletion'
        '400':
          description: 请求无效
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
        '401':
          description: 未授权
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
        '429':
          description: 超出速率限制
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
components:
  schemas:
    ChatCompletion:
      type: object
      required:
        - id
        - object
        - created
        - model
        - choices
      properties:
        id:
          type: string
          example: chatcmpl-abc123
        object:
          type: string
          example: chat.completion
        created:
          type: integer
          description: Unix 时间戳
        model:
          type: string
          example: claude-fable-5
        choices:
          type: array
          items:
            type: object
            properties:
              index:
                type: integer
              message:
                type: object
                properties:
                  role:
                    type: string
                    example: assistant
                  content:
                    type: string
                    example: 你好！有什么可以帮你的？
              finish_reason:
                type: string
                enum:
                  - stop
                  - length
                  - content_filter
                  - refusal
                  - null
        usage:
          type: object
          properties:
            prompt_tokens:
              type: integer
            completion_tokens:
              type: integer
            total_tokens:
              type: integer
    Error:
      type: object
      properties:
        error:
          type: object
          properties:
            code:
              type: string
            message:
              type: string
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer

````