claudish 2.4.0 → 2.5.0
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.
- package/README.md +10 -4
- package/dist/index.js +1546 -1245
- package/package.json +21 -20
- package/scripts/extract-models.ts +10 -0
- package/scripts/postinstall.cjs +0 -0
- package/skills/claudish-usage/SKILL.md +43 -24
package/package.json
CHANGED
|
@@ -1,31 +1,15 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "claudish",
|
|
3
|
-
"version": "2.
|
|
3
|
+
"version": "2.5.0",
|
|
4
4
|
"description": "CLI tool to run Claude Code with any OpenRouter model (Grok, GPT-5, MiniMax, etc.) via local Anthropic API-compatible proxy",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"main": "./dist/index.js",
|
|
7
7
|
"bin": {
|
|
8
8
|
"claudish": "dist/index.js"
|
|
9
9
|
},
|
|
10
|
-
"scripts": {
|
|
11
|
-
"dev": "bun run src/index.ts",
|
|
12
|
-
"dev:grok": "bun run src/index.ts --interactive --model x-ai/grok-code-fast-1",
|
|
13
|
-
"dev:grok:debug": "bun run src/index.ts --interactive --debug --log-level info --model x-ai/grok-code-fast-1",
|
|
14
|
-
"dev:info": "bun run src/index.ts --interactive --monitor",
|
|
15
|
-
"extract-models": "bun run scripts/extract-models.ts",
|
|
16
|
-
"build": "bun run extract-models && bun build src/index.ts --outdir dist --target node && chmod +x dist/index.js",
|
|
17
|
-
"link": "npm link",
|
|
18
|
-
"unlink": "npm unlink -g claudish",
|
|
19
|
-
"install-global": "bun run build && npm link",
|
|
20
|
-
"kill-all": "pkill -f 'bun.*claudish' || pkill -f 'claude.*claudish-settings' || echo 'No claudish processes found'",
|
|
21
|
-
"test": "bun test ./tests/comprehensive-model-test.ts",
|
|
22
|
-
"typecheck": "tsc --noEmit",
|
|
23
|
-
"lint": "biome check .",
|
|
24
|
-
"format": "biome format --write .",
|
|
25
|
-
"postinstall": "node scripts/postinstall.cjs"
|
|
26
|
-
},
|
|
27
10
|
"dependencies": {
|
|
28
11
|
"@hono/node-server": "^1.19.6",
|
|
12
|
+
"dotenv": "^17.2.3",
|
|
29
13
|
"hono": "^4.10.6"
|
|
30
14
|
},
|
|
31
15
|
"devDependencies": {
|
|
@@ -54,5 +38,22 @@
|
|
|
54
38
|
"ai"
|
|
55
39
|
],
|
|
56
40
|
"author": "Jack Rudenko <i@madappgang.com>",
|
|
57
|
-
"license": "MIT"
|
|
58
|
-
|
|
41
|
+
"license": "MIT",
|
|
42
|
+
"scripts": {
|
|
43
|
+
"dev": "bun run src/index.ts",
|
|
44
|
+
"dev:grok": "bun run src/index.ts --interactive --model x-ai/grok-code-fast-1",
|
|
45
|
+
"dev:grok:debug": "bun run src/index.ts --interactive --debug --log-level info --model x-ai/grok-code-fast-1",
|
|
46
|
+
"dev:info": "bun run src/index.ts --interactive --monitor",
|
|
47
|
+
"extract-models": "bun run scripts/extract-models.ts",
|
|
48
|
+
"build": "bun run extract-models && bun build src/index.ts --outdir dist --target node && chmod +x dist/index.js",
|
|
49
|
+
"link": "npm link",
|
|
50
|
+
"unlink": "npm unlink -g claudish",
|
|
51
|
+
"install-global": "bun run build && npm link",
|
|
52
|
+
"kill-all": "pkill -f 'bun.*claudish' || pkill -f 'claude.*claudish-settings' || echo 'No claudish processes found'",
|
|
53
|
+
"test": "bun test ./tests/comprehensive-model-test.ts",
|
|
54
|
+
"typecheck": "tsc --noEmit",
|
|
55
|
+
"lint": "biome check .",
|
|
56
|
+
"format": "biome format --write .",
|
|
57
|
+
"postinstall": "node scripts/postinstall.cjs"
|
|
58
|
+
}
|
|
59
|
+
}
|
|
@@ -120,6 +120,16 @@ export const ENV = {
|
|
|
120
120
|
CLAUDISH_ACTIVE_MODEL_NAME: "CLAUDISH_ACTIVE_MODEL_NAME", // Set by claudish to show active model in status line
|
|
121
121
|
ANTHROPIC_MODEL: "ANTHROPIC_MODEL", // Claude Code standard env var for model selection
|
|
122
122
|
ANTHROPIC_SMALL_FAST_MODEL: "ANTHROPIC_SMALL_FAST_MODEL", // Claude Code standard env var for fast model
|
|
123
|
+
// Claudish model mapping overrides (highest priority)
|
|
124
|
+
CLAUDISH_MODEL_OPUS: "CLAUDISH_MODEL_OPUS",
|
|
125
|
+
CLAUDISH_MODEL_SONNET: "CLAUDISH_MODEL_SONNET",
|
|
126
|
+
CLAUDISH_MODEL_HAIKU: "CLAUDISH_MODEL_HAIKU",
|
|
127
|
+
CLAUDISH_MODEL_SUBAGENT: "CLAUDISH_MODEL_SUBAGENT",
|
|
128
|
+
// Claude Code standard model configuration (fallback if CLAUDISH_* not set)
|
|
129
|
+
ANTHROPIC_DEFAULT_OPUS_MODEL: "ANTHROPIC_DEFAULT_OPUS_MODEL",
|
|
130
|
+
ANTHROPIC_DEFAULT_SONNET_MODEL: "ANTHROPIC_DEFAULT_SONNET_MODEL",
|
|
131
|
+
ANTHROPIC_DEFAULT_HAIKU_MODEL: "ANTHROPIC_DEFAULT_HAIKU_MODEL",
|
|
132
|
+
CLAUDE_CODE_SUBAGENT_MODEL: "CLAUDE_CODE_SUBAGENT_MODEL",
|
|
123
133
|
} as const;
|
|
124
134
|
|
|
125
135
|
// OpenRouter API Configuration
|
package/scripts/postinstall.cjs
CHANGED
|
File without changes
|
|
@@ -5,7 +5,7 @@ description: CRITICAL - Guide for using Claudish CLI ONLY through sub-agents to
|
|
|
5
5
|
|
|
6
6
|
# Claudish Usage Skill
|
|
7
7
|
|
|
8
|
-
**Version:** 1.
|
|
8
|
+
**Version:** 1.1.0
|
|
9
9
|
**Purpose:** Guide AI agents on how to use Claudish CLI to run Claude Code with OpenRouter models
|
|
10
10
|
**Status:** Production Ready
|
|
11
11
|
|
|
@@ -214,14 +214,22 @@ claudish --version
|
|
|
214
214
|
### Step 2: Get Available Models
|
|
215
215
|
|
|
216
216
|
```bash
|
|
217
|
-
# List
|
|
218
|
-
claudish --
|
|
217
|
+
# List ALL OpenRouter models grouped by provider
|
|
218
|
+
claudish --models
|
|
219
|
+
|
|
220
|
+
# Fuzzy search models by name, ID, or description
|
|
221
|
+
claudish --models gemini
|
|
222
|
+
claudish --models "grok code"
|
|
223
|
+
|
|
224
|
+
# Show top recommended programming models (curated list)
|
|
225
|
+
claudish --top-models
|
|
219
226
|
|
|
220
227
|
# JSON output for parsing
|
|
221
|
-
claudish --
|
|
228
|
+
claudish --models --json
|
|
229
|
+
claudish --top-models --json
|
|
222
230
|
|
|
223
231
|
# Force update from OpenRouter API
|
|
224
|
-
claudish --
|
|
232
|
+
claudish --models --force-update
|
|
225
233
|
```
|
|
226
234
|
|
|
227
235
|
### Step 3: Run Claudish
|
|
@@ -275,11 +283,18 @@ git diff | claudish --stdin --model openai/gpt-5-codex "Review these changes"
|
|
|
275
283
|
|
|
276
284
|
**Get Latest Models:**
|
|
277
285
|
```bash
|
|
278
|
-
#
|
|
279
|
-
claudish --
|
|
286
|
+
# List all models (auto-updates every 2 days)
|
|
287
|
+
claudish --models
|
|
288
|
+
|
|
289
|
+
# Search for specific models
|
|
290
|
+
claudish --models grok
|
|
291
|
+
claudish --models "gemini flash"
|
|
292
|
+
|
|
293
|
+
# Show curated top models
|
|
294
|
+
claudish --top-models
|
|
280
295
|
|
|
281
296
|
# Force immediate update
|
|
282
|
-
claudish --
|
|
297
|
+
claudish --models --force-update
|
|
283
298
|
```
|
|
284
299
|
|
|
285
300
|
## NEW: Direct Agent Selection (v2.1.0)
|
|
@@ -503,8 +518,8 @@ Use Claudish CLI to implement this feature with Grok model:
|
|
|
503
518
|
${featureDescription}
|
|
504
519
|
|
|
505
520
|
INSTRUCTIONS:
|
|
506
|
-
1.
|
|
507
|
-
claudish --
|
|
521
|
+
1. Search for available models:
|
|
522
|
+
claudish --models grok
|
|
508
523
|
|
|
509
524
|
2. Run implementation with Grok:
|
|
510
525
|
claudish --model x-ai/grok-code-fast-1 "${featureDescription}"
|
|
@@ -682,7 +697,8 @@ done
|
|
|
682
697
|
|------|-------------|---------|
|
|
683
698
|
| `--model <model>` | OpenRouter model to use | `--model x-ai/grok-code-fast-1` |
|
|
684
699
|
| `--stdin` | Read prompt from stdin | `git diff \| claudish --stdin --model grok` |
|
|
685
|
-
| `--
|
|
700
|
+
| `--models` | List all models or search | `claudish --models` or `claudish --models gemini` |
|
|
701
|
+
| `--top-models` | Show top recommended models | `claudish --top-models` |
|
|
686
702
|
| `--json` | JSON output (implies --quiet) | `claudish --json "task"` |
|
|
687
703
|
| `--help-ai` | Print AI agent usage guide | `claudish --help-ai` |
|
|
688
704
|
|
|
@@ -781,7 +797,7 @@ Model 'invalid/model' not found
|
|
|
781
797
|
**Fix:**
|
|
782
798
|
```bash
|
|
783
799
|
# List available models
|
|
784
|
-
claudish --
|
|
800
|
+
claudish --models
|
|
785
801
|
|
|
786
802
|
# Use valid model ID
|
|
787
803
|
claudish --model x-ai/grok-code-fast-1 "task"
|
|
@@ -869,10 +885,13 @@ await Task({
|
|
|
869
885
|
**How:**
|
|
870
886
|
```bash
|
|
871
887
|
# Auto-updates every 2 days
|
|
872
|
-
claudish --
|
|
888
|
+
claudish --models
|
|
889
|
+
|
|
890
|
+
# Search for specific models
|
|
891
|
+
claudish --models deepseek
|
|
873
892
|
|
|
874
893
|
# Force update now
|
|
875
|
-
claudish --
|
|
894
|
+
claudish --models --force-update
|
|
876
895
|
```
|
|
877
896
|
|
|
878
897
|
### 6. ✅ Use --stdin for Large Prompts
|
|
@@ -982,13 +1001,13 @@ const MODELS = ["x-ai/grok-code-fast-1", "openai/gpt-5"];
|
|
|
982
1001
|
**Right:**
|
|
983
1002
|
```typescript
|
|
984
1003
|
// Query dynamically
|
|
985
|
-
const { stdout } = await Bash("claudish --
|
|
1004
|
+
const { stdout } = await Bash("claudish --models --json");
|
|
986
1005
|
const models = JSON.parse(stdout).models.map(m => m.id);
|
|
987
1006
|
```
|
|
988
1007
|
|
|
989
1008
|
### ✅ Do Accept Custom Models From Users
|
|
990
1009
|
|
|
991
|
-
**Problem:** User provides a custom model ID that's not in --
|
|
1010
|
+
**Problem:** User provides a custom model ID that's not in --top-models
|
|
992
1011
|
|
|
993
1012
|
**Wrong (rejecting custom models):**
|
|
994
1013
|
```typescript
|
|
@@ -1002,7 +1021,7 @@ if (!availableModels.includes(userModel)) {
|
|
|
1002
1021
|
|
|
1003
1022
|
**Right (accept any valid model ID):**
|
|
1004
1023
|
```typescript
|
|
1005
|
-
// Claudish accepts ANY valid OpenRouter model ID, even if not in --
|
|
1024
|
+
// Claudish accepts ANY valid OpenRouter model ID, even if not in --top-models
|
|
1006
1025
|
const userModel = "custom/provider/model-123";
|
|
1007
1026
|
|
|
1008
1027
|
// Validate it's a non-empty string with provider format
|
|
@@ -1056,7 +1075,7 @@ const model = prefs.preferredModel || defaultModel;
|
|
|
1056
1075
|
```typescript
|
|
1057
1076
|
// In a multi-step workflow, ask once
|
|
1058
1077
|
if (!process.env.CLAUDISH_MODEL) {
|
|
1059
|
-
const { stdout } = await Bash("claudish --
|
|
1078
|
+
const { stdout } = await Bash("claudish --models --json");
|
|
1060
1079
|
const models = JSON.parse(stdout).models;
|
|
1061
1080
|
|
|
1062
1081
|
const response = await AskUserQuestion({
|
|
@@ -1086,7 +1105,7 @@ await Bash(`claudish --model ${model} "task 2"`);
|
|
|
1086
1105
|
1. ✅ **Accept any model ID** user provides (unless obviously malformed)
|
|
1087
1106
|
2. ✅ **Don't filter** based on your "shortlist" - let Claudish handle validation
|
|
1088
1107
|
3. ✅ **Offer to set CLAUDISH_MODEL** environment variable for session persistence
|
|
1089
|
-
4. ✅ **Explain** that --
|
|
1108
|
+
4. ✅ **Explain** that --top-models shows curated recommendations, --models shows all
|
|
1090
1109
|
5. ✅ **Validate format** (should contain "/") but not restrict to known models
|
|
1091
1110
|
6. ❌ **Never reject** a user's custom model with "not in my shortlist"
|
|
1092
1111
|
|
|
@@ -1163,7 +1182,7 @@ async function reviewCodeWithMultipleModels(files: string[]) {
|
|
|
1163
1182
|
*/
|
|
1164
1183
|
async function implementWithModel(featureDescription: string) {
|
|
1165
1184
|
// Step 1: Get available models
|
|
1166
|
-
const { stdout } = await Bash("claudish --
|
|
1185
|
+
const { stdout } = await Bash("claudish --models --json");
|
|
1167
1186
|
const models = JSON.parse(stdout).models;
|
|
1168
1187
|
|
|
1169
1188
|
// Step 2: Let user select model
|
|
@@ -1226,7 +1245,7 @@ Include:
|
|
|
1226
1245
|
**Symptoms:** Unexpected API costs
|
|
1227
1246
|
|
|
1228
1247
|
**Solutions:**
|
|
1229
|
-
1. Use budget-friendly models (check pricing with `--
|
|
1248
|
+
1. Use budget-friendly models (check pricing with `--models` or `--top-models`)
|
|
1230
1249
|
2. Enable cost tracking: `--cost-tracker`
|
|
1231
1250
|
3. Use --json to monitor costs: `claudish --json "task" | jq '.total_cost_usd'`
|
|
1232
1251
|
|
|
@@ -1244,7 +1263,7 @@ Include:
|
|
|
1244
1263
|
**Symptoms:** "Model not found" error
|
|
1245
1264
|
|
|
1246
1265
|
**Solutions:**
|
|
1247
|
-
1. Update model cache: `claudish --
|
|
1266
|
+
1. Update model cache: `claudish --models --force-update`
|
|
1248
1267
|
2. Check OpenRouter website for model availability
|
|
1249
1268
|
3. Use alternative model from same category
|
|
1250
1269
|
|
|
@@ -1275,5 +1294,5 @@ claudish --help-ai # AI agent usage guide
|
|
|
1275
1294
|
---
|
|
1276
1295
|
|
|
1277
1296
|
**Maintained by:** MadAppGang
|
|
1278
|
-
**Last Updated:** November
|
|
1279
|
-
**Skill Version:** 1.
|
|
1297
|
+
**Last Updated:** November 25, 2025
|
|
1298
|
+
**Skill Version:** 1.1.0
|