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

# Kimi K3

> Kimi K3 is a 2.8T open-weight reasoning model built for long-horizon agentic workflows and large-repo analysis. Developers should reach for it when they need a million-token context window with vision input and reliable tool execution.

## Overview

Kimi K3 is Moonshot’s 2.8T open-weight multimodal model, designed as a successor to K2.7. It accepts text and image inputs and outputs text, with native support for structured outputs, tool calling, and explicit reasoning steps. The model operates with a 1,048,576-token context window and a maximum output length of 32,768 tokens.

On Kyma, the model runs through an OpenAI-compatible endpoint with automatic request failover and exact cost reporting in the usage.cost field. Prompt caching is supported, reducing repeated prefix costs to 10% of the standard input rate. The platform serves it at a medium speed tier, averaging around 12 tokens per second in production.

The 32,768-token output cap means it is not suited for generating extremely long documents in a single pass. As a premium-tier model, it carries higher per-token costs than lighter alternatives, and its medium throughput requires planning for latency-sensitive applications.

## Specs

| Field              | Value                                                                 |
| ------------------ | --------------------------------------------------------------------- |
| Model ID           | `kimi-k3`                                                             |
| Best for           | Long-horizon agentic coding, reasoning over large repos, vision input |
| Context window     | 1.048576M                                                             |
| Max output tokens  | 33K                                                                   |
| Input modalities   | Text, Image                                                           |
| Output modalities  | Text                                                                  |
| Tool calling       | Yes                                                                   |
| Structured outputs | Yes                                                                   |
| Prompt caching     | Yes                                                                   |
| Speed              | Medium                                                                |
| Cost band          | Premium                                                               |
| Release stage      | Stable                                                                |

## Pricing

|        | Per 1M tokens |
| ------ | :-----------: |
| Input  |     \$4.05    |
| Output |    \$20.25    |

## Use this when

* **Agentic Workflow Execution** — Handles multi-step coding and tool execution across extended sessions without losing context.
* **Large Repository Analysis** — Ingests entire codebases or documentation sets within its million-token window for cross-file reasoning.
* **Vision-Enabled Document Review** — Processes image inputs alongside text to extract and reason over multimodal data.
* **Structured Data Extraction** — Outputs strictly formatted JSON or XML for reliable downstream parsing and API integration.

## Not ideal for

It is not the right choice for high-throughput, low-latency chat or generating outputs longer than 32,768 tokens.

## Pick something else when

* You need faster response times and lower costs for simple chat: use [`deepseek-v4-flash`](/models/deepseek-v4-flash) or [`qwen3.7-flash`](/models/qwen3.7-flash).
* You require outputs exceeding 32,768 tokens for long-form drafting: use [`gpt-5.6-terra`](/models/gpt-5.6-terra) or [`gemini-3.6-flash`](/models/gemini-3.6-flash).
* You want a cheaper open-weight model for basic code completion: use [`qwen-3-32b`](/models/qwen-3-32b) or [`deepseek-v3`](/models/deepseek-v3).

## Example

```python theme={null}
from openai import OpenAI

client = OpenAI(base_url="https://kymaapi.com/v1", api_key="ky-...")

response = client.chat.completions.create(
    model="kimi-k3",
    messages=[{"role": "user", "content": "..."}],
    tools=[...],  # function calling supported
)
```

## Agent query example

Ask the API which models fit, instead of hardcoding an id:

```bash theme={null}
curl "https://kymaapi.com/v1/models?recommended_for=write-code&tools=true&quality_tier=frontier-open"
```

## FAQ

**Does Kyma support prompt caching for this model?**

Yes, repeated prompt prefixes are cached automatically and billed at 10% of the standard input rate.

**What happens if the serving path fails during a request?**

Kyma routes every request through automatic failover, so degraded paths are silently rerouted without dropping the call.

**Can I use this model for image analysis?**

Yes, Kimi K3 accepts both text and image inputs, though it only outputs text.
