@mastra/mcp-docs-server 1.2.14-alpha.4 → 1.2.14

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (53) hide show
  1. package/.docs/models/gateways/neon.md +6 -6
  2. package/.docs/models/gateways/netlify.md +6 -6
  3. package/.docs/models/gateways/openrouter.md +6 -6
  4. package/.docs/models/gateways/vercel.md +7 -7
  5. package/.docs/models/index.md +97 -96
  6. package/.docs/models/providers/alibaba-cn.md +25 -23
  7. package/.docs/models/providers/alibaba-token-plan-cn.md +24 -24
  8. package/.docs/models/providers/alibaba-token-plan.md +25 -23
  9. package/.docs/models/providers/alibaba.md +25 -23
  10. package/.docs/models/providers/ambient.md +26 -24
  11. package/.docs/models/providers/baseten.md +25 -23
  12. package/.docs/models/providers/chutes.md +25 -23
  13. package/.docs/models/providers/cortecs.md +133 -85
  14. package/.docs/models/providers/crof.md +25 -23
  15. package/.docs/models/providers/crossmodel.md +25 -23
  16. package/.docs/models/providers/deepinfra.md +24 -22
  17. package/.docs/models/providers/digitalocean.md +25 -23
  18. package/.docs/models/providers/empiriolabs.md +25 -23
  19. package/.docs/models/providers/fireworks-ai.md +24 -24
  20. package/.docs/models/providers/greenpt.md +25 -23
  21. package/.docs/models/providers/groq.md +25 -23
  22. package/.docs/models/providers/huggingface.md +25 -23
  23. package/.docs/models/providers/hyper.md +31 -29
  24. package/.docs/models/providers/impossibl.md +25 -23
  25. package/.docs/models/providers/infomaniak.md +24 -24
  26. package/.docs/models/providers/kilo.md +26 -24
  27. package/.docs/models/providers/llmgateway.md +26 -24
  28. package/.docs/models/providers/minimax.md +23 -25
  29. package/.docs/models/providers/mistral.md +25 -23
  30. package/.docs/models/providers/modal.md +25 -23
  31. package/.docs/models/providers/modelis.md +25 -23
  32. package/.docs/models/providers/nano-gpt.md +26 -24
  33. package/.docs/models/providers/neuralwatt.md +25 -23
  34. package/.docs/models/providers/ofox.md +25 -23
  35. package/.docs/models/providers/ollama-cloud.md +25 -23
  36. package/.docs/models/providers/openai.md +26 -28
  37. package/.docs/models/providers/opencode-go.md +25 -23
  38. package/.docs/models/providers/opencode.md +25 -23
  39. package/.docs/models/providers/perplexity-agent.md +24 -24
  40. package/.docs/models/providers/pioneer.md +25 -23
  41. package/.docs/models/providers/requesty.md +25 -23
  42. package/.docs/models/providers/routing-run.md +25 -23
  43. package/.docs/models/providers/scx.md +25 -23
  44. package/.docs/models/providers/tensorx.md +25 -23
  45. package/.docs/models/providers/togetherai.md +24 -22
  46. package/.docs/models/providers/umans-ai-coding-plan.md +24 -24
  47. package/.docs/models/providers/umans-ai.md +25 -23
  48. package/.docs/models/providers/wandb.md +25 -23
  49. package/.docs/models/providers/xai.md +28 -26
  50. package/.docs/models/providers/zai-coding-plan.md +25 -23
  51. package/.docs/models/providers/zhipuai-coding-plan.md +25 -23
  52. package/CHANGELOG.md +7 -0
  53. package/package.json +6 -6
@@ -2,7 +2,7 @@
2
2
 
3
3
  # ![Cortecs logo](https://models.dev/logos/cortecs.svg)Cortecs
4
4
 
5
- Access 59 Cortecs models through Mastra's model router. Authentication is handled automatically using the `CORTECS_API_KEY` environment variable.
5
+ Access 105 Cortecs models through Mastra's model router. Authentication is handled automatically using the `CORTECS_API_KEY` environment variable.
6
6
 
7
7
  Learn more in the [Cortecs documentation](https://cortecs.ai).
8
8
 
@@ -11,22 +11,22 @@ CORTECS_API_KEY=your-api-key
11
11
  ```
12
12
 
13
13
  ```typescript
14
- import { Agent } from '@mastra/core/agent'
14
+ import { Agent } from "@mastra/core/agent";
15
15
 
16
16
  const agent = new Agent({
17
- id: 'my-agent',
18
- name: 'My Agent',
19
- instructions: 'You are a helpful assistant',
20
- model: 'cortecs/claude-4-5-sonnet',
21
- })
17
+ id: "my-agent",
18
+ name: "My Agent",
19
+ instructions: "You are a helpful assistant",
20
+ model: "cortecs/apertus-70b"
21
+ });
22
22
 
23
23
  // Generate a response
24
- const response = await agent.generate('Hello!')
24
+ const response = await agent.generate("Hello!");
25
25
 
26
26
  // Stream a response
27
- const stream = await agent.stream('Tell me a story')
27
+ const stream = await agent.stream("Tell me a story");
28
28
  for await (const chunk of stream) {
29
- console.log(chunk)
29
+ console.log(chunk);
30
30
  }
31
31
  ```
32
32
 
@@ -34,67 +34,113 @@ for await (const chunk of stream) {
34
34
 
35
35
  ## Models
36
36
 
37
- | Model | Context | Tools | Reasoning | Image | Audio | Video | Input $/1M | Output $/1M |
38
- | ---------------------------------------- | ------- | ----- | --------- | ----- | ----- | ----- | ---------- | ----------- |
39
- | `cortecs/claude-4-5-sonnet` | 200K | | | | | | $3 | $16 |
40
- | `cortecs/claude-4-6-sonnet` | 1.0M | | | | | | $4 | $18 |
41
- | `cortecs/claude-haiku-4-5` | 200K | | | | | | $1 | $5 |
42
- | `cortecs/claude-opus4-5` | 200K | | | | | | $6 | $30 |
43
- | `cortecs/claude-opus4-6` | 1.0M | | | | | | $6 | $30 |
44
- | `cortecs/claude-opus4-7` | 1.0M | | | | | | $6 | $28 |
45
- | `cortecs/claude-opus4-8` | 1.0M | | | | | | $6 | $28 |
46
- | `cortecs/claude-sonnet-4` | 200K | | | | | | $3 | $17 |
47
- | `cortecs/codestral-2508` | 256K | | | | | | $0.30 | $0.90 |
48
- | `cortecs/deepseek-r1-0528` | 164K | | | | | | $0.58 | $2 |
49
- | `cortecs/deepseek-v3-0324` | 128K | | | | | | $0.55 | $2 |
50
- | `cortecs/deepseek-v3.2` | 164K | | | | | | $0.27 | $0.44 |
51
- | `cortecs/deepseek-v4-flash` | 1.0M | | | | | | $0.13 | $0.27 |
52
- | `cortecs/deepseek-v4-flash-0731` | 1.0M | | | | | | $0.26 | $0.31 |
53
- | `cortecs/deepseek-v4-pro` | 1.0M | | | | | | $2 | $3 |
54
- | `cortecs/devstral-2512` | 262K | | | | | | | |
55
- | `cortecs/gemini-2.5-pro` | 1.0M | | | | | | $2 | $11 |
56
- | `cortecs/glm-4.5` | 131K | | | | | | $0.67 | $2 |
57
- | `cortecs/glm-4.5-air` | 131K | | | | | | $0.22 | $1 |
58
- | `cortecs/glm-4.7` | 198K | | | | | | $0.45 | $2 |
59
- | `cortecs/glm-4.7-flash` | 203K | | | | | | $0.09 | $0.53 |
60
- | `cortecs/glm-5` | 203K | | | | | | $1 | $3 |
61
- | `cortecs/glm-5-turbo` | 200K | | | | | | $1 | $4 |
62
- | `cortecs/glm-5.1` | 205K | | | | | | $1 | $4 |
63
- | `cortecs/glm-5.2` | 1.0M | | | | | | $1 | $5 |
64
- | `cortecs/glm-5v-turbo` | 200K | | | | | | $1 | $4 |
65
- | `cortecs/gpt-4.1` | 1.0M | | | | | | $2 | $9 |
66
- | `cortecs/gpt-5.4` | 1.1M | | | | | | $3 | $16 |
67
- | `cortecs/gpt-oss-120b` | 128K | | | | | | | |
68
- | `cortecs/hermes-4-70b` | 128K | | | | | | $0.12 | $0.36 |
69
- | `cortecs/hy3` | 262K | | | | | | $0.41 | $1 |
70
- | `cortecs/intellect-3` | 128K | | | | | | $0.22 | $1 |
71
- | `cortecs/kimi-k2-instruct` | 131K | | | | | | $0.55 | $3 |
72
- | `cortecs/kimi-k2-thinking` | 262K | | | | | | $0.66 | $3 |
73
- | `cortecs/kimi-k2.5` | 256K | | | | | | $0.55 | $3 |
74
- | `cortecs/kimi-k2.6` | 256K | | | | | | $0.81 | $4 |
75
- | `cortecs/kimi-k2.7-code` | 262K | | | | | | $1 | $5 |
76
- | `cortecs/kimi-k3` | 1.0M | | | | | | $3 | $15 |
77
- | `cortecs/llama-3.1-405b-instruct` | 128K | | | | | | | |
78
- | `cortecs/llama-3.3-70b-instruct` | 131K | | | | | | $0.09 | $0.28 |
79
- | `cortecs/llama-4-maverick` | 1.0M | | | | | | $0.12 | $0.60 |
80
- | `cortecs/minimax-m2` | 400K | | | | | | $0.39 | $2 |
81
- | `cortecs/minimax-m2.1` | 196K | | | | | | $0.34 | $1 |
82
- | `cortecs/minimax-m2.5` | 197K | | | | | | $0.32 | $1 |
83
- | `cortecs/minimax-m2.7` | 203K | | | | | | $0.47 | $1 |
84
- | `cortecs/minimax-m3` | 512K | | | | | | $0.35 | $2 |
85
- | `cortecs/mistral-large-2512` | 256K | | | | | | $0.50 | $2 |
86
- | `cortecs/mixtral-8x7B-instruct-v0.1` | 32K | | | | | | $0.44 | $0.68 |
87
- | `cortecs/nemotron-3-super-120b-a12b` | 262K | | | | | | $0.27 | $0.80 |
88
- | `cortecs/nova-pro-v1` | 300K | | | | | | $1 | $4 |
89
- | `cortecs/qwen-2.5-72b-instruct` | 33K | | | | | | $0.06 | $0.23 |
90
- | `cortecs/qwen3-235b-a22b-instruct-2507` | 131K | | | | | | $0.06 | $0.41 |
91
- | `cortecs/qwen3-32b` | 16K | | | | | | $0.10 | $0.33 |
92
- | `cortecs/qwen3-coder-30b-a3b-instruct` | 262K | | | | | | $0.05 | $0.22 |
93
- | `cortecs/qwen3-coder-480b-a35b-instruct` | 262K | | | | | | $0.44 | $2 |
94
- | `cortecs/qwen3-coder-next` | 256K | | | | | | $0.16 | $0.84 |
95
- | `cortecs/qwen3-next-80b-a3b-thinking` | 128K | | | | | | $0.16 | $1 |
96
- | `cortecs/qwen3.5-122b-a10b` | 262K | | | | | | $0.44 | $3 |
97
- | `cortecs/qwen3.5-397b-a17b` | 250K | | | | | | $0.60 | $4 |
37
+ | Model | Context | Tools | Reasoning | Image | Audio | Video | Input $/1M | Output $/1M |
38
+ | --------------------------------------------- | ------- | ----- | --------- | ----- | ----- | ----- | ---------- | ----------- |
39
+ | `cortecs/apertus-70b` | 66K | | | | | | $1 | $2 |
40
+ | `cortecs/claude-4-5-sonnet` | 200K | | | | | | $3 | $15 |
41
+ | `cortecs/claude-4-6-sonnet` | 1.0M | | | | | | $3 | $16 |
42
+ | `cortecs/claude-haiku-4-5` | 200K | | | | | | $1.00 | $5 |
43
+ | `cortecs/claude-opus-5` | 1.0M | | | | | | $6 | $27 |
44
+ | `cortecs/claude-opus4-5` | 200K | | | | | | $5 | $27 |
45
+ | `cortecs/claude-opus4-6` | 1.0M | | | | | | $5 | $27 |
46
+ | `cortecs/claude-opus4-7` | 1.0M | | | | | | $5 | $27 |
47
+ | `cortecs/claude-opus4-8` | 1.0M | | | | | | $5 | $27 |
48
+ | `cortecs/claude-sonnet-4` | 200K | | | | | | $3 | $14 |
49
+ | `cortecs/claude-sonnet-5` | 1.0M | | | | | | $2 | $11 |
50
+ | `cortecs/codestral-2508` | 256K | | | | | | $0.33 | $1 |
51
+ | `cortecs/cosmos3-super-reasoner` | 256K | | | | | | $0.10 | $0.30 |
52
+ | `cortecs/deepseek-r1-0528` | 164K | | | | | | $0.65 | $3 |
53
+ | `cortecs/deepseek-v3.2` | 164K | | | | | | $0.30 | $0.49 |
54
+ | `cortecs/deepseek-v4-flash` | 1.0M | | | | | | $0.15 | $0.30 |
55
+ | `cortecs/deepseek-v4-flash-0731` | 1.0M | | | | | | $0.25 | $0.30 |
56
+ | `cortecs/deepseek-v4-pro` | 1.0M | | | | | | $2 | $3 |
57
+ | `cortecs/devstral-2512` | 262K | | | | | | $0.45 | $2 |
58
+ | `cortecs/gemini-2.5-flash` | 1.0M | | | | | | $0.30 | $2 |
59
+ | `cortecs/gemini-2.5-pro` | 1.0M | | | | | | $1 | $10 |
60
+ | `cortecs/gemini-3.1-flash-lite` | 1.0M | | | | | | $0.27 | $2 |
61
+ | `cortecs/gemini-3.5-flash` | 1.0M | | | | | | $1 | $9 |
62
+ | `cortecs/gemma-3-27b-it` | 131K | | | | | | $0.10 | $0.30 |
63
+ | `cortecs/gemma-4-26b-a4b-it` | 262K | | | | | | $0.11 | $0.56 |
64
+ | `cortecs/gemma-4-31b-it` | 262K | | | | | | $0.22 | $0.39 |
65
+ | `cortecs/glm-4.7` | 203K | | | | | | $0.78 | $3 |
66
+ | `cortecs/glm-4.7-flash` | 203K | | | | | | $0.08 | $0.48 |
67
+ | `cortecs/glm-5` | 203K | | | | | | $0.99 | $3 |
68
+ | `cortecs/glm-5-turbo` | 203K | | | | | | $1 | $4 |
69
+ | `cortecs/glm-5.1` | 203K | | | | | | $1 | $4 |
70
+ | `cortecs/glm-5.2` | 1.0M | | | | | | $1 | $4 |
71
+ | `cortecs/glm-5v-turbo` | 203K | | | | | | $1 | $4 |
72
+ | `cortecs/gpt-4.1` | 1.0M | | | | | | $2 | $9 |
73
+ | `cortecs/gpt-4.1-mini` | 1.0M | | | | | | $0.43 | $2 |
74
+ | `cortecs/gpt-4.1-nano` | 1.0M | | | | | | $0.11 | $0.43 |
75
+ | `cortecs/gpt-4o` | 128K | | | | | | $3 | $11 |
76
+ | `cortecs/gpt-4o-mini` | 128K | | | | | | $0.16 | $0.64 |
77
+ | `cortecs/gpt-5` | 400K | | | | | | $1 | $11 |
78
+ | `cortecs/gpt-5-mini` | 400K | | | | | | $0.28 | $2 |
79
+ | `cortecs/gpt-5-nano` | 400K | | | | | | $0.06 | $0.44 |
80
+ | `cortecs/gpt-5.1` | 400K | | | | | | $1 | $11 |
81
+ | `cortecs/gpt-5.4` | 1.1M | | | | | | $3 | $15 |
82
+ | `cortecs/gpt-5.6-luna` | 1.1M | | | | | | $1 | $7 |
83
+ | `cortecs/gpt-5.6-sol` | 1.1M | | | | | | $6 | $33 |
84
+ | `cortecs/gpt-5.6-terra` | 1.1M | | | | | | $3 | $16 |
85
+ | `cortecs/gpt-oss-120b` | 131K | | | | | | $0.09 | $0.45 |
86
+ | `cortecs/gpt-oss-20b` | 131K | | | | | | $0.04 | $0.17 |
87
+ | `cortecs/gpt-oss-safeguard-120b` | 128K | | | | | | $0.18 | $0.70 |
88
+ | `cortecs/hermes-4-405b` | 128K | | | | | | $1.00 | $3 |
89
+ | `cortecs/hermes-4-70b` | 128K | | | | | | $0.13 | $0.40 |
90
+ | `cortecs/holo2-30b-a3b` | 22K | | | | | | $0.33 | $0.78 |
91
+ | `cortecs/kimi-k2.5` | 262K | | | | | | $0.49 | $3 |
92
+ | `cortecs/kimi-k2.6` | 262K | | | | | | $0.77 | $3 |
93
+ | `cortecs/kimi-k2.7-code` | 262K | | | | | | $0.75 | $4 |
94
+ | `cortecs/kimi-k3` | 1.0M | | | | | | $3 | $15 |
95
+ | `cortecs/llama-3.1-405b-instruct` | 128K | | | | | | $2 | $2 |
96
+ | `cortecs/llama-3.1-8b-instruct` | 128K | | | | | | $0.17 | $0.17 |
97
+ | `cortecs/llama-3.1-nemotron-ultra-253b-v1` | 128K | | | | | | $0.60 | $2 |
98
+ | `cortecs/llama-3.3-70b-instruct` | 131K | | | | | | $0.13 | $0.40 |
99
+ | `cortecs/minicpm-v-4.5` | 32K | | | | | | $0.65 | $1 |
100
+ | `cortecs/minimax-m2` | 400K | | | | | | $0.35 | $1 |
101
+ | `cortecs/minimax-m2.1` | 196K | | | | | | $0.36 | $1 |
102
+ | `cortecs/minimax-m2.5` | 197K | | | | | | $0.30 | $1 |
103
+ | `cortecs/minimax-m2.7` | 197K | | | | | | $0.67 | $3 |
104
+ | `cortecs/minimax-m3` | 1.0M | | | | | | $0.40 | $2 |
105
+ | `cortecs/ministral-14b-2512` | 256K | | | | | | $0.22 | $0.22 |
106
+ | `cortecs/ministral-3b-2512` | 256K | | | | | | $0.11 | $0.11 |
107
+ | `cortecs/ministral-8b-2512` | 256K | | | | | | $0.17 | $0.17 |
108
+ | `cortecs/mistral-7b-instruct-v0.2` | 32K | | | | | | $0.16 | $0.22 |
109
+ | `cortecs/mistral-7b-instruct-v0.3` | 127K | | | | | | $0.11 | $0.11 |
110
+ | `cortecs/mistral-large-2402` | 32K | | | | | | $4 | $13 |
111
+ | `cortecs/mistral-large-2512` | 256K | | | | | | $0.56 | $2 |
112
+ | `cortecs/mistral-medium-2508` | 128K | | | | | | $0.45 | $2 |
113
+ | `cortecs/mistral-medium-3.5` | 256K | | | | | | $2 | $6 |
114
+ | `cortecs/mistral-nemo-instruct-2407` | 128K | | | | | | $0.14 | $0.14 |
115
+ | `cortecs/mistral-small-2503` | 128K | | | | | | $0.11 | $0.33 |
116
+ | `cortecs/mistral-small-2603` | 262K | | | | | | $0.14 | $0.57 |
117
+ | `cortecs/mistral-small-3.2-24b-instruct-2506` | 131K | | | | | | $0.10 | $0.31 |
118
+ | `cortecs/mixtral-8x7B-instruct-v0.1` | 32K | | | | | | $0.49 | $0.76 |
119
+ | `cortecs/nemotron-nano-v2-12b` | 128K | | | | | | $0.24 | $0.71 |
120
+ | `cortecs/nova-2-lite` | 1.0M | | | | | | $0.37 | $3 |
121
+ | `cortecs/nova-lite-v1` | 300K | | | | | | $0.07 | $0.28 |
122
+ | `cortecs/nova-micro-v1` | 128K | | | | | | $0.04 | $0.16 |
123
+ | `cortecs/nova-pro-v1` | 300K | | | | | | $0.92 | $4 |
124
+ | `cortecs/nvidia-nemotron-3-nano-30b-a3b` | 256K | | | | | | $0.06 | $0.24 |
125
+ | `cortecs/nvidia-nemotron-3-nano-omni` | 300K | | | | | | $0.06 | $0.24 |
126
+ | `cortecs/pixtral-12b-2409` | 128K | | | | | | $0.22 | $0.22 |
127
+ | `cortecs/pixtral-large-2502` | 128K | | | | | | $2 | $6 |
128
+ | `cortecs/qwen2.5-vl-72b-instruct` | 32K | | | | | | $0.25 | $0.75 |
129
+ | `cortecs/qwen3-235b-a22b-instruct-2507` | 262K | | | | | | $0.07 | $0.46 |
130
+ | `cortecs/qwen3-30b-a3b-instruct-2507` | 262K | | | | | | $0.10 | $0.30 |
131
+ | `cortecs/qwen3-32b` | 40K | | | | | | $0.10 | $0.30 |
132
+ | `cortecs/qwen3-coder-30b-a3b-instruct` | 262K | | | | | | $0.07 | $0.24 |
133
+ | `cortecs/qwen3-coder-next` | 256K | | | | | | $0.17 | $0.89 |
134
+ | `cortecs/qwen3-next-80b-a3b-thinking` | 128K | | | | | | $0.15 | $1 |
135
+ | `cortecs/qwen3-vl-235b-a22b` | 256K | | | | | | $0.62 | $3 |
136
+ | `cortecs/qwen3.5-122b-a10b` | 262K | | | | | | $0.49 | $3 |
137
+ | `cortecs/qwen3.5-397b-a17b` | 262K | | | | | | $0.67 | $4 |
138
+ | `cortecs/qwen3.5-9b` | 262K | | | | | | $0.11 | $0.17 |
139
+ | `cortecs/qwen3.6-27b` | 262K | | | | | | $0.45 | $3 |
140
+ | `cortecs/qwen3.6-35b-a3b` | 262K | | | | | | $0.17 | $0.56 |
141
+ | `cortecs/qwen3guard-gen-0.6b` | 32K | | | | | | — | — |
142
+ | `cortecs/qwen3guard-gen-8b` | 32K | | | | | | — | — |
143
+ | `cortecs/voxtral-small-2507` | 32K | | | | | | $0.11 | $0.33 |
98
144
 
99
145
  ## Advanced configuration
100
146
 
@@ -102,28 +148,30 @@ for await (const chunk of stream) {
102
148
 
103
149
  ```typescript
104
150
  const agent = new Agent({
105
- id: 'custom-agent',
106
- name: 'custom-agent',
151
+ id: "custom-agent",
152
+ name: "custom-agent",
107
153
  model: {
108
- url: 'https://api.cortecs.ai/v1',
109
- id: 'cortecs/claude-4-5-sonnet',
154
+ url: "https://api.cortecs.ai/v1",
155
+ id: "cortecs/apertus-70b",
110
156
  apiKey: process.env.CORTECS_API_KEY,
111
157
  headers: {
112
- 'X-Custom-Header': 'value',
113
- },
114
- },
115
- })
158
+ "X-Custom-Header": "value"
159
+ }
160
+ }
161
+ });
116
162
  ```
117
163
 
118
164
  ### Dynamic model selection
119
165
 
120
166
  ```typescript
121
167
  const agent = new Agent({
122
- id: 'dynamic-agent',
123
- name: 'Dynamic Agent',
168
+ id: "dynamic-agent",
169
+ name: "Dynamic Agent",
124
170
  model: ({ requestContext }) => {
125
- const useAdvanced = requestContext.task === 'complex'
126
- return useAdvanced ? 'cortecs/qwen3.5-397b-a17b' : 'cortecs/claude-4-5-sonnet'
127
- },
128
- })
171
+ const useAdvanced = requestContext.task === "complex";
172
+ return useAdvanced
173
+ ? "cortecs/voxtral-small-2507"
174
+ : "cortecs/apertus-70b";
175
+ }
176
+ });
129
177
  ```
@@ -11,22 +11,22 @@ CROF_API_KEY=your-api-key
11
11
  ```
12
12
 
13
13
  ```typescript
14
- import { Agent } from '@mastra/core/agent'
14
+ import { Agent } from "@mastra/core/agent";
15
15
 
16
16
  const agent = new Agent({
17
- id: 'my-agent',
18
- name: 'My Agent',
19
- instructions: 'You are a helpful assistant',
20
- model: 'crof/deepseek-v3.2',
21
- })
17
+ id: "my-agent",
18
+ name: "My Agent",
19
+ instructions: "You are a helpful assistant",
20
+ model: "crof/deepseek-v3.2"
21
+ });
22
22
 
23
23
  // Generate a response
24
- const response = await agent.generate('Hello!')
24
+ const response = await agent.generate("Hello!");
25
25
 
26
26
  // Stream a response
27
- const stream = await agent.stream('Tell me a story')
27
+ const stream = await agent.stream("Tell me a story");
28
28
  for await (const chunk of stream) {
29
- console.log(chunk)
29
+ console.log(chunk);
30
30
  }
31
31
  ```
32
32
 
@@ -69,28 +69,30 @@ for await (const chunk of stream) {
69
69
 
70
70
  ```typescript
71
71
  const agent = new Agent({
72
- id: 'custom-agent',
73
- name: 'custom-agent',
72
+ id: "custom-agent",
73
+ name: "custom-agent",
74
74
  model: {
75
- url: 'https://crof.ai/v1',
76
- id: 'crof/deepseek-v3.2',
75
+ url: "https://crof.ai/v1",
76
+ id: "crof/deepseek-v3.2",
77
77
  apiKey: process.env.CROF_API_KEY,
78
78
  headers: {
79
- 'X-Custom-Header': 'value',
80
- },
81
- },
82
- })
79
+ "X-Custom-Header": "value"
80
+ }
81
+ }
82
+ });
83
83
  ```
84
84
 
85
85
  ### Dynamic model selection
86
86
 
87
87
  ```typescript
88
88
  const agent = new Agent({
89
- id: 'dynamic-agent',
90
- name: 'Dynamic Agent',
89
+ id: "dynamic-agent",
90
+ name: "Dynamic Agent",
91
91
  model: ({ requestContext }) => {
92
- const useAdvanced = requestContext.task === 'complex'
93
- return useAdvanced ? 'crof/qwen3.6-27b' : 'crof/deepseek-v3.2'
94
- },
95
- })
92
+ const useAdvanced = requestContext.task === "complex";
93
+ return useAdvanced
94
+ ? "crof/qwen3.6-27b"
95
+ : "crof/deepseek-v3.2";
96
+ }
97
+ });
96
98
  ```
@@ -11,22 +11,22 @@ CROSSMODEL_API_KEY=your-api-key
11
11
  ```
12
12
 
13
13
  ```typescript
14
- import { Agent } from '@mastra/core/agent'
14
+ import { Agent } from "@mastra/core/agent";
15
15
 
16
16
  const agent = new Agent({
17
- id: 'my-agent',
18
- name: 'My Agent',
19
- instructions: 'You are a helpful assistant',
20
- model: 'crossmodel/anthropic/claude-fable-5',
21
- })
17
+ id: "my-agent",
18
+ name: "My Agent",
19
+ instructions: "You are a helpful assistant",
20
+ model: "crossmodel/anthropic/claude-fable-5"
21
+ });
22
22
 
23
23
  // Generate a response
24
- const response = await agent.generate('Hello!')
24
+ const response = await agent.generate("Hello!");
25
25
 
26
26
  // Stream a response
27
- const stream = await agent.stream('Tell me a story')
27
+ const stream = await agent.stream("Tell me a story");
28
28
  for await (const chunk of stream) {
29
- console.log(chunk)
29
+ console.log(chunk);
30
30
  }
31
31
  ```
32
32
 
@@ -93,28 +93,30 @@ for await (const chunk of stream) {
93
93
 
94
94
  ```typescript
95
95
  const agent = new Agent({
96
- id: 'custom-agent',
97
- name: 'custom-agent',
96
+ id: "custom-agent",
97
+ name: "custom-agent",
98
98
  model: {
99
- url: 'https://api.crossmodel.ai/v1',
100
- id: 'crossmodel/anthropic/claude-fable-5',
99
+ url: "https://api.crossmodel.ai/v1",
100
+ id: "crossmodel/anthropic/claude-fable-5",
101
101
  apiKey: process.env.CROSSMODEL_API_KEY,
102
102
  headers: {
103
- 'X-Custom-Header': 'value',
104
- },
105
- },
106
- })
103
+ "X-Custom-Header": "value"
104
+ }
105
+ }
106
+ });
107
107
  ```
108
108
 
109
109
  ### Dynamic model selection
110
110
 
111
111
  ```typescript
112
112
  const agent = new Agent({
113
- id: 'dynamic-agent',
114
- name: 'Dynamic Agent',
113
+ id: "dynamic-agent",
114
+ name: "Dynamic Agent",
115
115
  model: ({ requestContext }) => {
116
- const useAdvanced = requestContext.task === 'complex'
117
- return useAdvanced ? 'crossmodel/z-ai/glm-5.2' : 'crossmodel/anthropic/claude-fable-5'
118
- },
119
- })
116
+ const useAdvanced = requestContext.task === "complex";
117
+ return useAdvanced
118
+ ? "crossmodel/z-ai/glm-5.2"
119
+ : "crossmodel/anthropic/claude-fable-5";
120
+ }
121
+ });
120
122
  ```
@@ -11,22 +11,22 @@ DEEPINFRA_API_KEY=your-api-key
11
11
  ```
12
12
 
13
13
  ```typescript
14
- import { Agent } from '@mastra/core/agent'
14
+ import { Agent } from "@mastra/core/agent";
15
15
 
16
16
  const agent = new Agent({
17
- id: 'my-agent',
18
- name: 'My Agent',
19
- instructions: 'You are a helpful assistant',
20
- model: 'deepinfra/MiniMaxAI/MiniMax-M2.5',
21
- })
17
+ id: "my-agent",
18
+ name: "My Agent",
19
+ instructions: "You are a helpful assistant",
20
+ model: "deepinfra/MiniMaxAI/MiniMax-M2.5"
21
+ });
22
22
 
23
23
  // Generate a response
24
- const response = await agent.generate('Hello!')
24
+ const response = await agent.generate("Hello!");
25
25
 
26
26
  // Stream a response
27
- const stream = await agent.stream('Tell me a story')
27
+ const stream = await agent.stream("Tell me a story");
28
28
  for await (const chunk of stream) {
29
- console.log(chunk)
29
+ console.log(chunk);
30
30
  }
31
31
  ```
32
32
 
@@ -86,29 +86,31 @@ for await (const chunk of stream) {
86
86
 
87
87
  ```typescript
88
88
  const agent = new Agent({
89
- id: 'custom-agent',
90
- name: 'custom-agent',
89
+ id: "custom-agent",
90
+ name: "custom-agent",
91
91
  model: {
92
- id: 'deepinfra/MiniMaxAI/MiniMax-M2.5',
92
+ id: "deepinfra/MiniMaxAI/MiniMax-M2.5",
93
93
  apiKey: process.env.DEEPINFRA_API_KEY,
94
94
  headers: {
95
- 'X-Custom-Header': 'value',
96
- },
97
- },
98
- })
95
+ "X-Custom-Header": "value"
96
+ }
97
+ }
98
+ });
99
99
  ```
100
100
 
101
101
  ### Dynamic model selection
102
102
 
103
103
  ```typescript
104
104
  const agent = new Agent({
105
- id: 'dynamic-agent',
106
- name: 'Dynamic Agent',
105
+ id: "dynamic-agent",
106
+ name: "Dynamic Agent",
107
107
  model: ({ requestContext }) => {
108
- const useAdvanced = requestContext.task === 'complex'
109
- return useAdvanced ? 'deepinfra/zai-org/GLM-5.2' : 'deepinfra/MiniMaxAI/MiniMax-M2.5'
110
- },
111
- })
108
+ const useAdvanced = requestContext.task === "complex";
109
+ return useAdvanced
110
+ ? "deepinfra/zai-org/GLM-5.2"
111
+ : "deepinfra/MiniMaxAI/MiniMax-M2.5";
112
+ }
113
+ });
112
114
  ```
113
115
 
114
116
  ## Direct provider installation
@@ -11,22 +11,22 @@ DIGITALOCEAN_ACCESS_TOKEN=your-api-token
11
11
  ```
12
12
 
13
13
  ```typescript
14
- import { Agent } from '@mastra/core/agent'
14
+ import { Agent } from "@mastra/core/agent";
15
15
 
16
16
  const agent = new Agent({
17
- id: 'my-agent',
18
- name: 'My Agent',
19
- instructions: 'You are a helpful assistant',
20
- model: 'digitalocean/alibaba-qwen3-32b',
21
- })
17
+ id: "my-agent",
18
+ name: "My Agent",
19
+ instructions: "You are a helpful assistant",
20
+ model: "digitalocean/alibaba-qwen3-32b"
21
+ });
22
22
 
23
23
  // Generate a response
24
- const response = await agent.generate('Hello!')
24
+ const response = await agent.generate("Hello!");
25
25
 
26
26
  // Stream a response
27
- const stream = await agent.stream('Tell me a story')
27
+ const stream = await agent.stream("Tell me a story");
28
28
  for await (const chunk of stream) {
29
- console.log(chunk)
29
+ console.log(chunk);
30
30
  }
31
31
  ```
32
32
 
@@ -127,28 +127,30 @@ for await (const chunk of stream) {
127
127
 
128
128
  ```typescript
129
129
  const agent = new Agent({
130
- id: 'custom-agent',
131
- name: 'custom-agent',
130
+ id: "custom-agent",
131
+ name: "custom-agent",
132
132
  model: {
133
- url: 'https://inference.do-ai.run/v1',
134
- id: 'digitalocean/alibaba-qwen3-32b',
133
+ url: "https://inference.do-ai.run/v1",
134
+ id: "digitalocean/alibaba-qwen3-32b",
135
135
  apiKey: process.env.DIGITALOCEAN_ACCESS_TOKEN,
136
136
  headers: {
137
- 'X-Custom-Header': 'value',
138
- },
139
- },
140
- })
137
+ "X-Custom-Header": "value"
138
+ }
139
+ }
140
+ });
141
141
  ```
142
142
 
143
143
  ### Dynamic model selection
144
144
 
145
145
  ```typescript
146
146
  const agent = new Agent({
147
- id: 'dynamic-agent',
148
- name: 'Dynamic Agent',
147
+ id: "dynamic-agent",
148
+ name: "Dynamic Agent",
149
149
  model: ({ requestContext }) => {
150
- const useAdvanced = requestContext.task === 'complex'
151
- return useAdvanced ? 'digitalocean/wan2-2-t2v-a14b' : 'digitalocean/alibaba-qwen3-32b'
152
- },
153
- })
150
+ const useAdvanced = requestContext.task === "complex";
151
+ return useAdvanced
152
+ ? "digitalocean/wan2-2-t2v-a14b"
153
+ : "digitalocean/alibaba-qwen3-32b";
154
+ }
155
+ });
154
156
  ```