nex-code 0.3.57 → 0.3.59
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 +79 -38
- package/dist/nex-code.js +385 -349
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
```
|
|
2
2
|
██▄▄██ nex-code v0.3.54
|
|
3
|
-
█▀██▀█
|
|
3
|
+
█▀██▀█ devstral-2:123b · /help
|
|
4
4
|
▀████▀
|
|
5
5
|
```
|
|
6
6
|
|
|
@@ -66,47 +66,88 @@ npm update -g nex-code
|
|
|
66
66
|
|
|
67
67
|
## Why nex-code?
|
|
68
68
|
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
|
76
|
-
|
|
77
|
-
|
|
|
78
|
-
|
|
|
79
|
-
|
|
|
80
|
-
|
|
|
81
|
-
|
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
69
|
+
**Provider-agnostic by design.** Run fully free with a local Ollama server, use Ollama Cloud's 47+ models on a flat-rate plan, or connect OpenAI, Anthropic, or Gemini — switch at runtime with `/model`, no restart needed. The fallback chain automatically retries failed requests on the next configured provider.
|
|
70
|
+
|
|
71
|
+
**Open-model first.** nex-code was built around open models, not locked to any single vendor. Tool tiers (`essential / standard / full`) adapt automatically to the model's capability level, so smaller models don't receive tool schemas they can't handle. A 5-layer auto-fix loop catches and retries malformed tool calls without user intervention.
|
|
72
|
+
|
|
73
|
+
**Smart model routing.** The built-in `/benchmark` system tests all configured models against 33 real nex-code tool-calling tasks across 5 task categories. The results feed a routing table so nex-code can automatically switch to the best model for the detected task type:
|
|
74
|
+
|
|
75
|
+
| Detected task | Routed model (example) |
|
|
76
|
+
|---|---|
|
|
77
|
+
| Frontend / CSS / React | `qwen3-coder:480b` |
|
|
78
|
+
| Sysadmin / Docker / nginx | `devstral-2:123b` |
|
|
79
|
+
| Data / SQL / migrations | `devstral-2:123b` |
|
|
80
|
+
| Agentic swarms | `minimax-m2.7:cloud` |
|
|
81
|
+
| General coding | `devstral-2:123b` (default) |
|
|
82
|
+
|
|
83
|
+
**Built-in VS Code extension.** A sidebar chat panel with streaming output, collapsible tool cards, and native VS Code theme support — shipped in the same repo, no separate install.
|
|
84
|
+
|
|
85
|
+
**Lightweight.** 2 runtime dependencies (`axios`, `dotenv`). Starts in ~100ms. No Python, no heavy runtime, no daemon process.
|
|
86
|
+
|
|
87
|
+
**Infrastructure tools built in:**
|
|
88
|
+
- SSH server management (AlmaLinux, macOS, any Linux)
|
|
89
|
+
- Docker tools — local and remote via SSH
|
|
90
|
+
- Kubernetes overview (`/k8s`)
|
|
91
|
+
- GitHub Actions tools (trigger, monitor runs)
|
|
92
|
+
- Named deploy configs (`rsync`-based, `/deploy`)
|
|
93
|
+
- Browser agent via Playwright (optional, not bundled)
|
|
94
|
+
- Grounded web search via Perplexity or DuckDuckGo
|
|
95
|
+
|
|
96
|
+
**Developer safety:**
|
|
97
|
+
- Pre-push secret detection — blocks commits that contain API keys or tokens
|
|
98
|
+
- Full audit log (JSONL + sanitization)
|
|
99
|
+
- Undo/Redo with persistence across restarts
|
|
100
|
+
- Cost tracking and per-provider budget limits
|
|
101
|
+
- Plan mode — analysis-only pass before any file changes
|
|
102
|
+
|
|
103
|
+
**Extensible.** Plugin API (`registerTool` + lifecycle hooks), skill system (install from any git URL), MCP server support.
|
|
104
|
+
|
|
105
|
+
**Tested.** 3074 tests, 85% coverage, CI on every push.
|
|
93
106
|
|
|
94
107
|
---
|
|
95
108
|
|
|
96
|
-
## Ollama Cloud —
|
|
109
|
+
## Ollama Cloud — Recommended Model Setup
|
|
97
110
|
|
|
98
111
|
nex-code was built with Ollama Cloud as its primary provider. No subscription, no billing surprises.
|
|
99
|
-
|
|
112
|
+
Rankings are based on nex-code's own `/benchmark` — 15 tool-calling tasks against real nex-code schemas.
|
|
113
|
+
|
|
114
|
+
### Flat-Rate / Pay-as-you-go
|
|
115
|
+
|
|
116
|
+
<!-- nex-benchmark-start -->
|
|
117
|
+
<!-- Updated: 2026-03-20 — run `/benchmark --discover` after new Ollama Cloud releases -->
|
|
100
118
|
|
|
101
|
-
| Model | Context | Best For |
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
119
|
+
| Rank | Model | Score | Avg Latency | Context | Best For |
|
|
120
|
+
|---|---|---|---|---|---|
|
|
121
|
+
|
|
122
|
+
|
|
123
|
+
> Rankings are nex-code-specific: tool name accuracy, argument validity, schema compliance.
|
|
124
|
+
> Toolathon (Minimax SOTA) measures different task types — run `/benchmark --discover` after model releases.
|
|
125
|
+
<!-- nex-benchmark-end -->
|
|
126
|
+
|
|
127
|
+
### Recommended `.env` for Ollama Cloud (Flat-Rate)
|
|
128
|
+
|
|
129
|
+
```env
|
|
130
|
+
DEFAULT_PROVIDER=ollama
|
|
131
|
+
DEFAULT_MODEL=devstral-2:123b # nex-code benchmark winner (84/100, 1.5s)
|
|
132
|
+
|
|
133
|
+
# Sub-agent routing
|
|
134
|
+
NEX_HEAVY_MODEL=qwen3-coder:480b # complex multi-step coding
|
|
135
|
+
NEX_STANDARD_MODEL=devstral-2:123b # routine tasks
|
|
136
|
+
NEX_FAST_MODEL=devstral-small-2:24b # quick lookups, fast sub-agents
|
|
137
|
+
```
|
|
138
|
+
|
|
139
|
+
### Run the benchmark yourself
|
|
140
|
+
|
|
141
|
+
```bash
|
|
142
|
+
/benchmark # full run: 15 tasks × 5 models
|
|
143
|
+
/benchmark --quick # fast run: 7 tasks × 3 models
|
|
144
|
+
/benchmark --discover # detect new Ollama Cloud models, benchmark + auto-update README
|
|
145
|
+
/benchmark --models=minimax-m2.7:cloud,qwen3-coder:480b
|
|
146
|
+
/benchmark --history # show OpenClaw nightly trend
|
|
147
|
+
```
|
|
108
148
|
|
|
109
|
-
Switch anytime: `/model
|
|
149
|
+
Switch anytime: `/model devstral-2:123b` or update `DEFAULT_MODEL` in `.env`.
|
|
150
|
+
Auto-discovery runs weekly via the scheduled improvement task and updates this table automatically.
|
|
110
151
|
|
|
111
152
|
---
|
|
112
153
|
|
|
@@ -155,7 +196,7 @@ PERPLEXITY_API_KEY=your-key # Perplexity (optional — enables grounded web se
|
|
|
155
196
|
|
|
156
197
|
# Optional tuning
|
|
157
198
|
DEFAULT_PROVIDER=ollama # Active provider on startup
|
|
158
|
-
DEFAULT_MODEL=
|
|
199
|
+
DEFAULT_MODEL=devstral-2:123b # Active model on startup (see /benchmark for ranking)
|
|
159
200
|
FALLBACK_CHAIN=anthropic,openai # Providers tried on failure (comma-separated)
|
|
160
201
|
NEX_STALE_WARN_MS=60000 # Warn if no tokens received for N ms (default: 60000)
|
|
161
202
|
NEX_STALE_ABORT_MS=120000 # Abort and retry stream after N ms of silence (default: 120000)
|
|
@@ -299,7 +340,7 @@ npm run package # syncs version, builds, and creates .vsix
|
|
|
299
340
|
|---------|---------|-------------|
|
|
300
341
|
| `nexCode.executablePath` | `nex-code` | Path to the nex-code binary |
|
|
301
342
|
| `nexCode.defaultProvider` | `ollama` | LLM provider |
|
|
302
|
-
| `nexCode.defaultModel` | `
|
|
343
|
+
| `nexCode.defaultModel` | `devstral-2:123b` | Model name |
|
|
303
344
|
| `nexCode.anthropicApiKey` | — | Anthropic API key |
|
|
304
345
|
| `nexCode.openaiApiKey` | — | OpenAI API key |
|
|
305
346
|
| `nexCode.ollamaApiKey` | — | Ollama Cloud API key |
|
|
@@ -400,7 +441,7 @@ Type `/` to see inline suggestions as you type. Tab completion is supported for
|
|
|
400
441
|
| `/review [--strict] [file]` | Deep code review: 3-phase protocol (broad scan → grep deep-dive → report), score table, diff fix snippets. `--strict` forces ≥3 critical findings. |
|
|
401
442
|
| `/k8s [user@host]` | Kubernetes overview: namespaces + pod health (remote via SSH optional) |
|
|
402
443
|
| `/setup` | Interactive setup wizard — configure provider, API keys, web search |
|
|
403
|
-
| `/benchmark` |
|
|
444
|
+
| `/benchmark [--quick\|--discover\|--history]` | Rank models on nex-code tool-calling tasks, auto-update routing |
|
|
404
445
|
| `/install-skill <url>` | Install a skill from a git repo |
|
|
405
446
|
| `/search-skill <query>` | Search GitHub for nex-code skills |
|
|
406
447
|
| `/remove-skill <name>` | Remove an installed skill |
|