| name | netllm-connect-editor |
| description | Wire AI coding tools (Cursor, Claude Code, Codex, VS Code Copilot, Honcho)
to a running netllm agent at http://127.0.0.1:11400/v1. Use when the user
asks to connect Cursor to netllm, use local LLM in Claude Code or Codex,
point an editor at the swarm router, or invokes /netllm-connect. Requires
netllm serve running and a model name from ./netllm models.
|
| version | 1.0.0 |
| license | MIT |
| compatibility | ["cursor","codex","claude-code","copilot"] |
| allowed-tools | ["Read","Shell","Grep"] |
netllm connect editor
When to use this skill
- User wants Cursor, Claude Code, Codex, or Honcho to use local models via netllm
- After
/netllm-setup or when agent is already running
- User invokes
/netllm-connect
Prerequisites
- netllm agent running:
curl -sf http://127.0.0.1:11400/health
- Model ID from
./netllm models (exact string required in most editors)
Load detailed per-editor steps from references/editor-settings.md when needed.
Workflow
-
Confirm agent is up
curl -sf http://127.0.0.1:11400/health && echo ok
./netllm models
curl -sf http://127.0.0.1:11400/netllm/v1/harnesses
Pick a model ID from output; note it for the user. The last call 404s on
an agent older than the harness-detection feature — that's fine, just
fall back to step 3's static instructions unchanged.
-
Ask which editor, Cursor, Claude Code, Codex, VS Code Copilot, or Honcho. If user already named one, skip.
-
Apply editor-specific config, follow references/editor-settings.md. Never auto-edit settings.json without explicit user consent; show copy-paste instructions instead.
If step 1's /netllm/v1/harnesses call succeeded, tailor this step with
the matching entry (match by id: claude-code, codex, cursor,
gemini-cli, honcho; Copilot has no registry entry, use the static
flow):
"detected": true, "enabled": false (or no matching entry at all) —
the CLI is on PATH but not registered as a source. After finishing
the env wiring below, mention ./netllm sources toggle <id> as an
optional way to give this harness its own durable routing/policy —
not required for basic connectivity.
"detected": false — surface that harness's install_hint as a
copy-paste command. Never run it yourself; the user installs it, then
re-runs this skill to pick up the change.
"detected": true, "enabled": true — already registered; nothing
extra to say here, proceed straight to env wiring.
-
Set shell env, pick one API surface:
OpenAI-compatible (Cursor, Codex, Copilot):
export OPENAI_BASE_URL=http://127.0.0.1:11400/v1
export OPENAI_API_KEY=netllm-local
Native Anthropic Messages API (Claude Code):
export ANTHROPIC_BASE_URL=http://127.0.0.1:11400
export ANTHROPIC_API_KEY=netllm-local
For LAN gateway, replace host with gateway IP (e.g. http://192.168.1.10:11400).
-
Verify inference
./netllm test --model <id>
./netllm test --api anthropic --model <id>
-
Report, editor, base URL, model name, verification result. If model_not_found, model string does not match backend, re-run ./netllm models.
Examples
Goal: Cursor on same machine as netllm
./netllm models → e.g. llama3.2:latest
- Cursor Settings → Models → enable OpenAI-compatible override
- Base URL:
http://127.0.0.1:11400/v1, API key: netllm-local, model: llama3.2:latest
./netllm test --model llama3.2:latest
Edge cases
| Situation | Action |
|---|
| Agent not running | Run netllm-setup skill or ./netllm serve |
| Empty model list | Start Ollama/oMLX; ./netllm discover; restart serve |
| Dockerized Honcho | Use http://host.docker.internal:11400/v1: see docs/honcho-integration.md |
| Remote swarm gateway | Point client at gateway URL from ./netllm peers |
Do not
- Modify user editor settings files without explicit permission
- Use cloud API keys when routing through netllm:
netllm-local is sufficient