Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 14 additions & 0 deletions clawspring/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -375,6 +375,7 @@ Claude Code is a powerful, production-grade AI coding assistant — but its sour
| **Zhipu (GLM)** | `glm-4-flash` | 128k | Free tier available | `ZHIPU_API_KEY` |
| **DeepSeek** | `deepseek-chat` | 64k | Strong coding | `DEEPSEEK_API_KEY` |
| **DeepSeek** | `deepseek-reasoner` | 64k | Chain-of-thought reasoning | `DEEPSEEK_API_KEY` |
| **MiniMax** | `MiniMax-M3` | 1M | Long-context coding and agent tasks | `MINIMAX_API_KEY` |

### Open-Source (Local via Ollama)

Expand Down Expand Up @@ -542,6 +543,16 @@ clawspring --model deepseek/deepseek-chat
clawspring --model deepseek/deepseek-reasoner
```

### MiniMax

Get your API key at [platform.minimax.io](https://platform.minimax.io/docs).

```bash
export MINIMAX_API_KEY=...

clawspring --model MiniMax-M3
```

---

## Usage: Open-Source Models (Local)
Expand Down Expand Up @@ -729,6 +740,7 @@ clawspring --model qwen:qwen-max
| `qwen`, `qwq-` | qwen |
| `glm-` | zhipu |
| `deepseek-` | deepseek |
| `minimax-` | minimax |
| `llama`, `mistral`, `phi`, `gemma`, `mixtral`, `codellama` | ollama |

---
Expand Down Expand Up @@ -869,6 +881,7 @@ export MOONSHOT_API_KEY=sk-... # Kimi
export DASHSCOPE_API_KEY=sk-... # Qwen
export ZHIPU_API_KEY=... # Zhipu GLM
export DEEPSEEK_API_KEY=sk-... # DeepSeek
export MINIMAX_API_KEY=... # MiniMax
```

### Method 2: Set Inside the REPL (persisted)
Expand All @@ -881,6 +894,7 @@ export DEEPSEEK_API_KEY=sk-... # DeepSeek
/config qwen_api_key=sk-...
/config zhipu_api_key=...
/config deepseek_api_key=sk-...
/config minimax_api_key=...
```

Keys are saved to `~/.clawspring/config.json` and loaded automatically on next launch.
Expand Down
12 changes: 12 additions & 0 deletions clawspring/providers.py
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@
qwen — Alibaba DashScope (qwen-max, qwen-plus, ...)
zhipu — Zhipu GLM (glm-4, glm-4-plus, ...)
deepseek — DeepSeek (deepseek-chat, deepseek-reasoner, ...)
minimax — MiniMax (MiniMax-M3)
ollama — Local Ollama (llama3.3, qwen2.5-coder, ...)
lmstudio — Local LM Studio (any loaded model)
custom — Any OpenAI-compatible endpoint
Expand Down Expand Up @@ -99,6 +100,15 @@
"deepseek-chat", "deepseek-coder", "deepseek-reasoner",
],
},
"minimax": {
"type": "openai",
"api_key_env": "MINIMAX_API_KEY",
"base_url": "https://api.minimax.io/v1",
"context_limit": 1000000,
"models": [
"MiniMax-M3",
],
},
"ollama": {
"type": "ollama",
"api_key_env": None,
Expand Down Expand Up @@ -145,6 +155,7 @@
"qwen-plus": (0.4, 1.2),
"deepseek-chat": (0.27, 1.1),
"deepseek-reasoner": (0.55, 2.19),
"MiniMax-M3": (0.6, 2.4),
"glm-4-plus": (0.7, 0.7),
}

Expand All @@ -161,6 +172,7 @@
("qwq-", "qwen"),
("glm-", "zhipu"),
("deepseek-", "deepseek"),
("minimax-", "minimax"),
("llama", "ollama"),
("mistral", "ollama"),
("phi", "ollama"),
Expand Down