Chutes
Access 33 Chutes models through Mastra's model router. Authentication is handled automatically using the CHUTES_API_KEY environment variable.
Learn more in the Chutes documentation.
CHUTES_API_KEY=your-api-key
import { Agent } from "@mastra/core";
const agent = new Agent({
name: "my-agent",
instructions: "You are a helpful assistant",
model: "chutes/Qwen/Qwen3-235B-A22B-Instruct-2507"
});
// Generate a response
const response = await agent.generate("Hello!");
// Stream a response
const stream = await agent.stream("Tell me a story");
for await (const chunk of stream) {
console.log(chunk);
}
info
Mastra uses the OpenAI-compatible /chat/completions endpoint. Some provider-specific features may not be available. Check the Chutes documentation for details.
Models
| Model | Context | Tools | Reasoning | Image | Audio | Video | Input $/1M | Output $/1M |
|---|---|---|---|---|---|---|---|---|
chutes/Alibaba-NLP/Tongyi-DeepResearch-30B-A3B | 131K | — | — | |||||
chutes/ArliAI/QwQ-32B-ArliAI-RpR-v1 | 33K | $0.03 | $0.11 | |||||
chutes/chutesai/Mistral-Small-3.1-24B-Instruct-2503 | 131K | $0.05 | $0.22 | |||||
chutes/chutesai/Mistral-Small-3.2-24B-Instruct-2506 | 131K | $0.06 | $0.18 | |||||
chutes/deepseek-ai/DeepSeek-R1 | 164K | $0.30 | $1 | |||||
chutes/deepseek-ai/DeepSeek-R1-0528 | 164K | $0.40 | $2 | |||||
chutes/deepseek-ai/DeepSeek-R1-0528-Qwen3-8B | 33K | $0.02 | $0.10 | |||||
chutes/deepseek-ai/DeepSeek-R1-Distill-Llama-70B | 131K | $0.03 | $0.13 | |||||
chutes/deepseek-ai/DeepSeek-V3 | 164K | $0.30 | $1 | |||||
chutes/deepseek-ai/DeepSeek-V3-0324 | 164K | $0.24 | $0.84 | |||||
chutes/deepseek-ai/DeepSeek-V3.1 | 164K | $0.20 | $0.80 | |||||
chutes/deepseek-ai/DeepSeek-V3.1-Terminus | 164K | $0.23 | $0.90 | |||||
chutes/deepseek-ai/DeepSeek-V3.2-Exp | 164K | $0.25 | $0.35 | |||||
chutes/meituan-longcat/LongCat-Flash-Chat-FP8 | 131K | — | — | |||||
chutes/microsoft/MAI-DS-R1-FP8 | 164K | $0.30 | $1 | |||||
chutes/MiniMaxAI/MiniMax-M2 | 197K | $0.26 | $1 | |||||
chutes/moonshotai/Kimi-K2-Instruct-0905 | 262K | $0.39 | $2 | |||||
chutes/moonshotai/Kimi-K2-Thinking | 262K | $0.30 | $1 | |||||
chutes/NousResearch/DeepHermes-3-Mistral-24B-Preview | 33K | $0.15 | $0.59 | |||||
chutes/NousResearch/Hermes-4-14B | 41K | $0.03 | $0.11 | |||||
chutes/NousResearch/Hermes-4-405B-FP8 | 131K | $0.30 | $1 | |||||
chutes/NousResearch/Hermes-4-70B | 131K | $0.11 | $0.38 | |||||
chutes/openai/gpt-oss-120b | 131K | $0.04 | $0.40 | |||||
chutes/openai/gpt-oss-20b | 131K | — | — | |||||
chutes/OpenGVLab/InternVL3-78B | 33K | $0.07 | $0.26 | |||||
chutes/Qwen/Qwen2.5-72B-Instruct | 33K | $0.07 | $0.26 | |||||
chutes/Qwen/Qwen2.5-Coder-32B-Instruct | 33K | $0.04 | $0.16 | |||||
chutes/Qwen/Qwen2.5-VL-32B-Instruct | 16K | $0.05 | $0.22 | |||||
chutes/Qwen/Qwen2.5-VL-72B-Instruct | 33K | $0.08 | $0.33 | |||||
chutes/Qwen/Qwen3-14B | 41K | $0.05 | $0.22 | |||||
chutes/Qwen/Qwen3-235B-A22B | 41K | $0.30 | $1 | |||||
chutes/Qwen/Qwen3-235B-A22B-Instruct-2507 | 262K | $0.08 | $0.55 | |||||
chutes/Qwen/Qwen3-235B-A22B-Thinking-2507 | 262K | $0.11 | $0.60 | |||||
chutes/Qwen/Qwen3-30B-A3B | 41K | $0.06 | $0.22 | |||||
chutes/Qwen/Qwen3-30B-A3B-Instruct-2507 | 262K | $0.08 | $0.33 | |||||
chutes/Qwen/Qwen3-32B | 41K | $0.05 | $0.20 | |||||
chutes/Qwen/Qwen3-Coder-30B-A3B-Instruct | 262K | $0.06 | $0.25 | |||||
chutes/Qwen/Qwen3-Coder-480B-A35B-Instruct-FP8 | 262K | $0.22 | $0.95 | |||||
chutes/Qwen/Qwen3-Next-80B-A3B-Instruct | 262K | $0.10 | $0.80 | |||||
chutes/Qwen/Qwen3-VL-235B-A22B-Instruct | 262K | $0.30 | $1 | |||||
chutes/Qwen/Qwen3-VL-235B-A22B-Thinking | 262K | $0.30 | $1 | |||||
chutes/rednote-hilab/dots.ocr | 131K | $0.01 | $0.01 | |||||
chutes/tngtech/DeepSeek-R1T-Chimera | 164K | $0.30 | $1 | |||||
chutes/tngtech/DeepSeek-TNG-R1T2-Chimera | 164K | $0.30 | $1 | |||||
chutes/unsloth/gemma-3-12b-it | 131K | $0.03 | $0.10 | |||||
chutes/unsloth/gemma-3-27b-it | 96K | $0.13 | $0.52 | |||||
chutes/unsloth/gemma-3-4b-it | 96K | — | — | |||||
chutes/unsloth/Mistral-Nemo-Instruct-2407 | 131K | $0.03 | $0.11 | |||||
chutes/unsloth/Mistral-Small-24B-Instruct-2501 | 33K | $0.05 | $0.22 | |||||
chutes/zai-org/GLM-4.5 | 131K | $0.35 | $2 | |||||
chutes/zai-org/GLM-4.5-Air | 131K | — | — | |||||
chutes/zai-org/GLM-4.6 | 203K | $0.40 | $2 |
Advanced Configuration
Custom Headers
const agent = new Agent({
name: "custom-agent",
model: {
url: "https://llm.chutes.ai/v1",
id: "chutes/Qwen/Qwen3-235B-A22B-Instruct-2507",
apiKey: process.env.CHUTES_API_KEY,
headers: {
"X-Custom-Header": "value"
}
}
});
Dynamic Model Selection
const agent = new Agent({
name: "dynamic-agent",
model: ({ runtimeContext }) => {
const useAdvanced = runtimeContext.task === "complex";
return useAdvanced
? "chutes/zai-org/GLM-4.6-turbo"
: "chutes/Qwen/Qwen3-235B-A22B-Instruct-2507";
}
});