deel-local-cli 1.4.3 → 1.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.en.md CHANGED
@@ -1,996 +1,997 @@
1
- <div align="center">
2
-
3
- <picture>
4
- <source media="(prefers-color-scheme: dark)" srcset="docs/assets/hero-en-dark.svg">
5
- <img alt="deel — stays on this machine" src="docs/assets/hero-en-light.svg" width="620">
6
- </picture>
7
-
8
- ### A coding-agent CLI that runs on local models and private gateways only
9
-
10
- Zero dependencies · Node 20+ · Exactly one place your source can go
11
-
12
- <br>
13
-
14
- [![npm](https://img.shields.io/npm/v/deel-local-cli?logo=npm&logoColor=white&label=npm&color=cb3837)](https://www.npmjs.com/package/deel-local-cli)
15
- [![downloads](https://img.shields.io/npm/dt/deel-local-cli?label=downloads&color=1a7f37)](https://www.npmjs.com/package/deel-local-cli)
16
- [![node](https://img.shields.io/node/v/deel-local-cli?logo=nodedotjs&logoColor=white&label=node&color=5FA04E)](https://nodejs.org)
17
- [![license](https://img.shields.io/npm/l/deel-local-cli?label=license&color=0969da)](LICENSE)
18
-
19
- [![Node.js CI](https://img.shields.io/github/actions/workflow/status/jysvai/deel-local-cli/test.yml?branch=main&logo=github&logoColor=white&label=Node.js%20CI)](https://github.com/jysvai/deel-local-cli/actions/workflows/test.yml)
20
- [![CodeQL](https://img.shields.io/github/actions/workflow/status/jysvai/deel-local-cli/codeql.yml?branch=main&logo=github&logoColor=white&label=CodeQL)](https://github.com/jysvai/deel-local-cli/actions/workflows/codeql.yml)
21
- [![tests](https://img.shields.io/badge/tests-3%2C498%20passing-1a7f37?logo=checkmarx&logoColor=white)](docs/en/develop.md)
22
-
23
- [![dependencies](https://img.shields.io/badge/dependencies-0-1a7f37)](https://www.npmjs.com/package/deel-local-cli?activeTab=dependencies)
24
- [![ESM](https://img.shields.io/badge/ESM-Node%2020%2B-5FA04E?logo=javascript&logoColor=white)](package.json)
25
- [![network](https://img.shields.io/badge/network-127.0.0.1%20only-1a7f37?logo=wireguard&logoColor=white)](#where-your-data-can-go)
26
- [![telemetry](https://img.shields.io/badge/telemetry-none-1a7f37?logo=ghostery&logoColor=white)](#where-your-data-can-go)
27
-
28
- **[한국어](README.md)** · [Corporate review](#corporate-review-package) · [Troubleshooting](#troubleshooting) · [Full docs](docs/en/)
29
-
30
- </div>
31
-
32
- ---
33
-
34
- ```
35
- ╭──────────────────────────────────────────────────────────────╮
36
- │ deel OpenAI-compatible │
37
- │ │
38
- │ Model qwen2.5-coder:7b (40k tokens) │
39
- │ Sends to this machine 127.0.0.1:11434 ← nowhere else │
40
- │ Link streaming · tools · reasoning control │
41
- │ Folder C:\work\myproject │
42
- │ Approval ⏵⏵ auto-approve — nothing is asked; /undo is the net│
43
- │ Shift+Tab to change · Tab completes a / command │
44
- │ This PC 337 skills · 127 commands · 42 plugins │
45
- ╰──────────────────────────────────────────────────────────────╯
46
-
47
- ▏myproject · qwen2.5-coder:7b ▏ ▰▰▱▱▱▱▱▱▱▱ 22% 28k/128k ▏ ◎ Auto · ◇ medium·save · ⏵⏵ auto
48
- ❯ unify the logging style
49
-
50
- ❊ Grep(console.log)
51
- └ 1 file · 1 hit
52
- ◧ Read(src/runner.js)
53
- └ 5 lines
54
- ◈ Edit(src/runner.js)
55
- └ 1 spot
56
-
57
- ▌ Unified log calls to the logger format. One change in runner.js.
58
-
59
- ── 4.2s · 3 tools · ↑3,900 ↓180
60
- ```
61
-
62
- ---
63
-
64
- ## Contents
65
-
66
- - [Why this exists](#why-this-exists)
67
- - [What's different](#whats-different)
68
- - [Quick start](#quick-start)
69
- - [Where your data can go](#where-your-data-can-go)
70
- - [Multiple local runtimes](#multiple-local-runtimes)
71
- - [Slash commands](#slash-commands)
72
- - [Work modes](#work-modes)
73
- - [Simple vs developer](#simple-vs-developer)
74
- - [Tools](#tools)
75
- - [Korean text and Excel](#korean-text-and-excel)
76
- - [Serving what you built](#serving-what-you-built)
77
- - [Skills and plugins](#skills-and-plugins)
78
- - [Reasoning effort](#reasoning-effort)
79
- - [Auto-compaction](#auto-compaction)
80
- - [Resuming a conversation](#resuming-a-conversation)
81
- - [Attaching tools from outside (MCP)](#attaching-tools-from-outside-mcp)
82
- - [Inside your editor (ACP)](#inside-your-editor-acp)
83
- - [Keeping secrets out of the conversation](#keeping-secrets-out-of-the-conversation)
84
- - [Safety](#safety)
85
- - [Corporate review package](#corporate-review-package)
86
- - [Configuration](#configuration)
87
- - [Troubleshooting](#troubleshooting)
88
- - [Development](#development)
89
- - [Release notes](#release-notes)
90
-
91
- This page is the **summary**. Each section links to the detail behind it.
92
-
93
- | Full docs | What is in there |
94
- |---|---|
95
- | [Models](docs/en/models.md) | Grade and window size · Korean-model presets · project detection |
96
- | [The screen](docs/en/interface.md) | The input box · work modes · simple vs developer · what it asks about |
97
- | [Tools in depth](docs/en/tools.md) | `Outline` · `Verify` · `Task` · `Jobs` · `Append` · `Def`/`Refs` · edit matching |
98
- | [Korean documents and Excel](docs/en/documents.md) | hwpx/docx/pptx · encoding · Excel → CSV |
99
- | [Extending](docs/en/extend.md) | Skills · plugins · MCP · ACP |
100
- | [Speed and spend](docs/en/tuning.md) | Per-stage effort · the prefix cache · context length |
101
- | [Safety and corporate review](docs/en/safety.md) | Undo · working scope · audit log · the review package |
102
- | [Configuration](docs/en/config.md) · [Development](docs/en/develop.md) | Env vars · run flags · running the tests · folder layout |
103
- | [Release notes](docs/en/releases.md) | [1.4.3](docs/en/releases.md#143) · [1.4.2](docs/en/releases.md#142) · [1.4.1](docs/en/releases.md#141) · [1.4.0](docs/en/releases.md#140) · [1.3.0](docs/en/releases.md#130) · [1.2.0](docs/en/releases.md#120) |
104
-
105
- ---
106
-
107
- ## Why this exists
108
-
109
- When a corporate security policy blocks **unapproved software**, most coding-agent tools are
110
- unusable: hundreds of transitive dependencies, scripts that run at install time, and no
111
- one-line answer to "where does it send my code?"
112
-
113
- deel is built to pass that review.
114
-
115
- | | deel |
116
- |---|---|
117
- | External dependencies | **0** — Node built-ins only |
118
- | Install scripts | **none** — unzip and run |
119
- | Where source can go | **one address** — the one you configured |
120
- | Requirement | Node 20+ |
121
-
122
- Verify it yourself:
123
-
124
- ```bash
125
- npm view deel-local-cli dependencies # {}
126
- npm view deel-local-cli scripts # no install/postinstall
127
- deel audit # full review sheet
128
- ```
129
-
130
- ---
131
-
132
- ## What's different
133
-
134
- A handful of coding agents can talk to a local model. Far fewer were
135
- **redesigned inside for running locally.**
136
-
137
- | | Other tools | deel |
138
- |---|---|---|
139
- | `/undo` | rolls back files only — the conversation still believes it happened | rewinds **the conversation too** |
140
- | Long conversations | pay a cost cloud tools never feel, unchanged, locally | ordering designed so the prefix cache **survives** |
141
- | Edits on small models | fail on a single whitespace mismatch | 20%→**100%** success, 0 wrong-location edits |
142
- | Korean models | unknown until you've run them | known **in advance** from public docs |
143
- | "Done" | says so even for what wasn't checked | `/evidence` / `/export` — **unproven items included** |
144
- | MCP · ACP | need an SDK | `child_process` + `JSON`, nothing else |
145
- | Compliance paperwork | hand-written, drifts from reality | **generated by scanning the source** |
146
-
147
- <br>
148
-
149
- #### `/undo` rewinds the conversation along with the files
150
-
151
- Roll back only the files and the model still believes it just made that edit
152
- — it builds the next step on a premise that no longer holds, and nothing on
153
- screen says otherwise. deel folds the messages back in lockstep with the
154
- files. Folding can orphan a tool call, which the server answers with a 400,
155
- so the same pass repairs the pairing (`repairToolPairs`).
156
-
157
- #### Fixed the hidden reason local models get slower as a conversation grows
158
-
159
- Ollama and llama.cpp only reuse computation when a request's prefix exactly
160
- matches the last one — change one character near the front and everything
161
- after it, the whole conversation, gets recomputed. A cloud API never pays
162
- this cost, so cloud-first tools have no reason to care; someone running
163
- locally feels it compound every turn. deel pushes what can change per turn
164
- (mode, pins) to the **end** of the prompt and sends Ollama `keep_alive: 60m`
165
- so the front stays cached. The ordering is enforced by a test
166
- (`test/cache.test.js`).
167
-
168
- #### Edits actually succeed on small models
169
-
170
- Small local models often can't reproduce the exact whitespace of the string
171
- they're trying to edit. The internal benchmark (`npm run bench`) measured
172
- 20% success for the old exact-match-only approach. The current approach
173
- (stepped whitespace/indent tolerance) measures **100%** — and both approaches
174
- land at **0** wrong-location edits. When it's ambiguous, it says so instead
175
- of guessing.
176
-
177
- #### Korean models are known before you've ever run them
178
-
179
- EXAONE, HyperCLOVA X, Kanana, Midm, and Solar get whatever's verifiable from
180
- public documentation (e.g., whether a model is a reasoning model) applied
181
- before the first prompt. Other tools meet these models cold, and it takes a
182
- dozen-plus turns of trial and error before anyone learns their quirks.
183
-
184
- #### "Done" comes with a receipt, not just a claim
185
-
186
- `/evidence` and `/export` record what wasn't verified alongside what was —
187
- because the moment an AI coding tool is most likely to mislead someone is
188
- exactly the moment it confidently says "done." `/export` is a self-contained
189
- HTML file with zero outbound links, so it opens anywhere, including an
190
- air-gapped network.
191
-
192
- #### MCP and ACP, with no SDK
193
-
194
- Both the Model Context Protocol and the Agent Client Protocol are just
195
- newline-delimited JSON-RPC 2.0 over stdio. deel implements both with nothing
196
- but `child_process` and `JSON` — proof that zero dependencies isn't a
197
- capability given up, it's a capability that was never needed.
198
-
199
- #### Compliance paperwork it doesn't hand-write
200
-
201
- The import-review report, SBOM, and audit spec that `deel pack` produces are
202
- generated **by scanning the actual source**, not typed by a person.
203
- Hand-written paperwork eventually drifts from reality, and the moment a
204
- reviewer catches one drifted claim, they stop trusting the rest of it.
205
-
206
- ---
207
-
208
- ## Quick start
209
-
210
- ### The screen speaks English too
211
-
212
- deel is written in Korean — the code, the function names, the comments. That part stays.
213
- What you see on screen does not have to.
214
-
215
- ```bash
216
- DEEL_LANG=en deel # this run only
217
- /lang en # and remember it
218
- /lang # how much is translated so far
219
- ```
220
-
221
- Untranslated lines come through in Korean rather than as blanks, and `/lang` tells you exactly
222
- how many are left.
223
-
224
- What the model reads follows the same switch. Set it to English and the rules, the mode
225
- instructions, and the tool descriptions all go out in English — so the model answers you in
226
- English instead of Korean. That side is cheaper, too: the part of the window that ships on every
227
- single request drops from about 4,900 tokens to about 3,450 — on a 32k model, from 15% of the
228
- window to 10.5%.
229
-
230
- Tool names and argument names stay Korean (`목적`, `할일`, `번호`). Those are identifiers, not
231
- prose — rename them and the tool stops being called at all.
232
-
233
- ### Install
234
-
235
- ```bash
236
- npm install -g deel-local-cli
237
- ```
238
-
239
- Or skip installing entirely — there is no `npm install` step:
240
-
241
- ```bash
242
- git clone https://github.com/jysvai/deel-local-cli
243
- node deel-local-cli/bin/deel.js
244
- ```
245
-
246
- > **Note** — do not run `npm install` in your home directory. A `node_modules` there makes every
247
- > later npm command scan it and report warnings about unrelated packages. Use `-g` or `npx`.
248
-
249
- ### Point it at a model
250
-
251
- Scan this machine and pick one:
252
-
253
- ```bash
254
- deel scan --pick
255
- ```
256
-
257
- Or enter an address directly (use this for a corporate gateway):
258
-
259
- ```bash
260
- deel setup
261
- ```
262
-
263
- ### Start
264
-
265
- Run `deel` in the folder you want to work in. **That folder becomes the scope — files outside it
266
- cannot be read or written.**
267
-
268
- ```bash
269
- cd C:\work\myproject
270
- deel
271
- ```
272
-
273
- ---
274
-
275
- ## Where your data can go
276
-
277
- A coding agent ships your whole source to a model. **The address is everything.**
278
- Rather than promising in prose, the code enforces it: `src/safety/network.js` checks every request
279
- and never builds one for an address that is not on the allow-list.
280
-
281
- ```
282
- [A] Model gateway ────── the only path your source travels
283
- One address, set in `setup`. Switching models closes the previous one.
284
-
285
- [B] Web read (WebFetch) ─ receive-only
286
- GET only, zero-byte body. Private/loopback addresses refused. Every visit logged.
287
-
288
- [C] Plugin fetch ─────── open only while /plugin install runs
289
-
290
- [D] MCP servers ──────── a separate child process, someone else's program
291
- Only starts if a human writes it into .deel/mcp.json. Off by default.
292
- ```
293
-
294
- A, B, and C are requests deel makes itself, so each one can be filtered.
295
- **D is different** — an MCP server is its own process; there is no way to see
296
- what sockets it opens from the outside. So under `--offline`, instead of
297
- filtering its requests, deel **never starts the server at all** — it doesn't
298
- claim to have blocked what it can't actually see.
299
-
300
- Pass `--offline` and **B, C, and D are all closed** — traffic stays on this machine.
301
-
302
- ```bash
303
- deel --offline
304
- ```
305
-
306
- The destination is printed at the top of every session:
307
-
308
- ```
309
- Sends to this machine 127.0.0.1:11434 ← nowhere else
310
- ```
311
-
312
- Nothing is collected or transmitted. No telemetry, no usage stats, no crash reporting.
313
- Conversation history, undo snapshots and config live only in `.deel/` inside your working folder.
314
-
315
- > Verified by 123 checks in `npm test` (network + web + mcp), including bringing up a real
316
- > server and confirming that **not a single request reaches it** when it is not allow-listed,
317
- > and that an MCP server **never starts** under `--offline`.
318
-
319
- ---
320
-
321
- ## Multiple local runtimes
322
-
323
- People rarely run just one. `deel scan` knocks on 13 known ports concurrently and identifies
324
- each runtime from its **response**, not its port number — Ollama by `/api/version`,
325
- LM Studio by `/api/v0/models`, llama.cpp by `/props`. Unrecognised ones are marked as a guess.
326
-
327
- ```
328
- $ deel scan
329
-
330
- ✓ found 3
331
-
332
- ◆ Ollama 127.0.0.1:11434 Ollama API 36ms
333
- · qwen2.5-coder:7b 7B · 4.4GB
334
- · llama3.2:1b 1B · 1.2GB
335
- ◆ LM Studio 127.0.0.1:1234 OpenAI-compat 7ms
336
- · devstral-small-2507
337
- ◆ llama.cpp 127.0.0.1:8080 OpenAI-compat 7ms
338
- · gemma-3-4b-it
339
-
340
- Recommended Ollama · qwen2.5-coder:7b
341
- ```
342
-
343
- | Command | What it does |
344
- |---|---|
345
- | `deel scan` | Show what is running |
346
- | `deel scan --pick` | Choose one from the list |
347
- | `deel scan --save` | Register everything found |
348
- | `deel scan --ports 9000,9100` | Extra ports to probe |
349
- | `deel scan --host <addr>` | Defaults to `127.0.0.1` |
350
-
351
- Switch with `/model` mid-conversation — **the conversation carries over.**
352
-
353
- > **More** — It adapts to whatever model is attached · Korean models are known before they are experienced · Small windows get a smaller fixed share · On startup it reads what kind of project this folder is
354
- >
355
- > **[Models read →](docs/en/models.md#multiple-local-runtimes)**
356
-
357
- ---
358
-
359
- ## Slash commands
360
-
361
- Names follow Claude Code / Codex conventions.
362
-
363
- | Command | What it does |
364
- |---|---|
365
- | `/help` | Command list |
366
- | `/lang [ko\|en]` | Screen language. Falls back to Korean for anything not translated yet |
367
- | `/bell [on\|off]` | Ring and set the window title when a turn ends, or when deel needs an answer |
368
- | `/consult <profile> <question>` | Ask a second model one question. Your current model stays put |
369
- | `/export` | This conversation as a **one-page HTML report** — asked, changed, verified. Self-contained, opens on any network |
370
- | `/lsp [on\|off]` | Language servers — what is installed, and whether `Def`/`Refs` are available. `off` turns post-edit diagnostics off only |
371
- | `/context` | What is consuming the context window |
372
- | `/ctx [auto\|number]` | Context **length** — re-read it off the model, or set it yourself |
373
- | `/grade [small\|medium\|large\|auto]` | Model **grade** — how much it does on its own. A different axis from `/ctx` |
374
- | `/out [number\|auto]` | Cap on a **single reply** — raise it when large files get cut |
375
- | `/compact` | Summarise and fold older turns |
376
- | `/clear` | Clear the conversation (keeps link and rules) |
377
- | `/thread [new\|fork\|close\|n]` | Conversation threads — side work in its own context. Link and undo stay shared |
378
- | `/learned [clear]` | What deel has picked up on its own — commands that work here, this model's habits |
379
- | `/pin <text>` | Pin a line — folding and compaction **cannot reach it** |
380
- | `/evidence [file]` | Evidence — what changed, and what proves it. **What is unproven is listed too** |
381
- | `/model` | Switch connection / model |
382
- | `/model 카드` | Model card — what this model has actually done here, and what deel changed because of it |
383
- | `/think <level>` | Reasoning level (`off·low·medium·high·max`) |
384
- | `/think 배분 <profile>` | Per-stage profile (`even·save·deep`) |
385
- | `/think 자세히` | Stage table — which stage runs at which level and cap |
386
- | `/mode <mode>` | Approval policy — how much it asks (`auto` · `confirm` · `strict`) |
387
- | `/work [mode]` | Work mode — what kind of work you are doing |
388
- | `/auto` | Hand the wheel back — it picks the mode from what you type |
389
- | `/code` `/plan` `/architect` `/debug` `/ask` `/orchestrator` | Switch work mode directly (pins it) |
390
- | `/level [level]` | How much to show (`쉬움` simple · `개발자` developer) |
391
- | `/undo [turns]` | Revert file changes |
392
- | `/diff [file]` | Files changed this session, and the changed lines |
393
- | `/preview [folder\|file\|off]` | Serve what you built, right here — a browser opens with it |
394
- | `/tools` | Available tools |
395
- | `/skills [query\|all\|off]` | Browse, search, load skills |
396
- | `/plugin [install\|remove\|pack]` | Manage plugins |
397
- | `/cost` | Session usage |
398
- | `/status` | Connection status |
399
- | `/scan [save]` | Sweep this machine for local model servers (`save` registers them) |
400
- | `/sessions` | Past conversations in this folder |
401
- | `/recall <text>` | Search past conversations **by content** |
402
- | `/memory` | What persists across sessions — view, add, delete |
403
- | `/mcp` | Externally attached tools (MCP servers) |
404
- | `/init` | Create a `DEEL.md` rules file |
405
- | `/exit` | Quit |
406
-
407
- Discovered plugin commands are invoked as `/<plugin>:<name>`, with `$ARGUMENTS` substituted.
408
-
409
- `/scan` and `/sessions` work without leaving the session. If you just started another local
410
- server or loaded a different model, `/scan save` then `/model` switches over without losing
411
- the conversation.
412
-
413
- **Without typing**
414
-
415
- | Key | What it does |
416
- |---|---|
417
- | `Tab` | Completes the `/` command you are typing. Candidates appear under the box as you type |
418
- | `Shift+Tab` | Approval policy (`⏵⏵ auto` → `⏵ risky only` → `⏸ everything`) |
419
- | `Ctrl+O` | Work mode (`종합` → `코드` → `계획` → …) |
420
- | `↑` `↓` | Input history |
421
- | `Ctrl+C` | Stops the answer in progress; twice on an empty line quits |
422
-
423
- Korean IME composition, paste, `Ctrl+A/E` and backspace all keep working.
424
-
425
- > **More** — Attaching a file with @ · Interrupting
426
- >
427
- > **[The screen read →](docs/en/interface.md#slash-commands)**
428
-
429
- ---
430
-
431
- ## Work modes
432
-
433
- What you are working on changes **which tools the model is given and how hard it thinks.**
434
- Cycle with `Shift+Tab`, or type the name.
435
-
436
- | Mode | For | Can edit files | Reasoning |
437
- |---|---|---|---|
438
- | `/auto` ◎ Auto | **Default.** Reads your message and switches for you | Yes | Normal (`save`) |
439
- | `/code` ◆ Code | Writing and fixing | Yes | Normal (`save`) |
440
- | `/plan` ☰ Plan | Planning first | **No** | Deep (`deep`·high) |
441
- | `/architect` ◈ Architect | Shaping structure | **No** | Deep (`deep`·high) |
442
- | `/debug` ◉ Debug | Finding causes | Yes | Deep, more steps (32) |
443
- | `/ask` ◇ Ask | Explaining only | **No** | Shallow (`low`) |
444
- | `/orchestrator` ❋ Orchestrator | Breaking up large work | Yes | Many steps (40) |
445
-
446
- In read-only modes, `Write`, `Edit` and `Bash` are **never sent to the model at all.**
447
- It is not asked politely not to edit — models forget requests. A tool that isn't there can't be used.
448
-
449
- Don't confuse this with `/mode`. They are separate axes:
450
-
451
- - `/mode` — **how much it asks you** (auto · confirm · strict)
452
- - `/work` — **what kind of work you are doing** (the seven above)
453
-
454
- If you have explicitly set `/think` or `/mode`, your choice wins. A work mode never
455
- overrides something a person chose.
456
-
457
- > **More** — Switching by itself (Auto mode)
458
- >
459
- > **[The screen read →](docs/en/interface.md#work-modes)**
460
-
461
- ---
462
-
463
- ## Simple vs developer
464
-
465
- Twenty commands on first launch means nothing gets chosen. Locking features away means
466
- hitting a wall later. So only **what is shown** differs.
467
-
468
- | | Simple (`쉬움`, default) | Developer (`개발자`) |
469
- |---|---|---|
470
- | `/help` listing | Common commands only | Everything |
471
- | Error messages | What to do about it | The original text |
472
- | Safety | **Identical** | **Identical** |
473
-
474
- `/level 개발자` is saved to config and persists across sessions.
475
-
476
- Two things matter here:
477
-
478
- - **Hidden commands still work.** `/think high` works in simple mode. It just isn't listed.
479
- - **Beginners do not get fewer safeguards.** Undo, workspace scope and dangerous-command
480
- blocking are identical. A beginner needs the undo more, not less.
481
-
482
- > **More** — The input box · You don't have to type the whole command · The box stays while it works · The picture on the left moves too and 1 more
483
- >
484
- > **[The screen read →](docs/en/interface.md#simple-vs-developer)**
485
-
486
- ---
487
-
488
- ## Tools
489
-
490
- Names and arguments match Claude Code, so skills written for that convention work unchanged.
491
-
492
- | Tool | What it does |
493
- |---|---|
494
- | `Read` | Read a file (line numbers, `offset`/`limit`, **Excel as CSV, hwpx/docx/pptx as text**) |
495
- | `Write` | Write / overwrite a file (**several at once via the `files` array**) |
496
- | `Append` | Append to the end of a file — **how large files get written in pieces** |
497
- | `Edit` | Replace an exact string (`replace_all`; **several sites at once via the `edits` array**) |
498
- | `Glob` | Find files by name pattern |
499
- | `Grep` | Regex search file contents |
500
- | `Bash` | Run a command (**`background: true` for anything that does not finish**) |
501
- | `Skill` | Expand a skill body (shown to the model only when skills exist) |
502
- | `WebFetch` | Read a web page (read-only; hidden under `--offline`) |
503
- | `Recall` | Search **past conversations** — the model digs up "that thing last time" itself |
504
- | `Remember` | One line that outlives the session — known from the start next time |
505
- | `TodoWrite` | Checklist — breaks long work into steps and shows progress |
506
- | `Outline` | See a folder's **skeleton only** — tens of times cheaper than reading it whole |
507
- | `Verify` | Check that what was built **actually works** |
508
- | `Task` | Run one chunk of a big job in a **separate context** |
509
- | `Jobs` | Inspect, read and stop **background commands** — the other half of `Bash`'s `background` |
510
- | `Def` | **Where a name is defined** — only shown when a language server is installed |
511
- | `Refs` | **Every place a name is used** — only shown when a language server is installed |
512
-
513
- Seven tools here are not in Claude Code — `Append`, `Recall`, `Remember`, `Outline`,
514
- `Verify`, `Task`, `Jobs`. Each tool costs 150-400 tokens of schema on **every request**,
515
- so a test stops you every time the list grows (`test/loop.test.js`). The last four earned
516
- their cost; here is why.
517
-
518
- > **More** — Outline · Verify · Task · Def · Refs · Commands that never finish and 9 more
519
- >
520
- > **[Tools in depth read →](docs/en/tools.md#tools)**
521
-
522
- ---
523
-
524
- ## Korean text and Excel
525
-
526
- **A file saved as CP949 is written back as CP949.** The encoding is never changed.
527
- Excel (`.xlsx`) is read as CSV — read-only.
528
-
529
- > **More** — Encoding · Excel
530
- >
531
- > **[Korean documents and Excel read →](docs/en/documents.md#korean-text-and-excel)**
532
-
533
- ---
534
-
535
- ## Serving what you built
536
-
537
- ```
538
- ❯ /preview
539
-
540
- ▶ Serving http://127.0.0.1:56801/
541
- showing .
542
- Edit a file and the page reloads by itself.
543
- Only this machine can open it (127.0.0.1). No other PC can see it.
544
- Stop with /preview off · it shuts down when deel exits.
545
- ```
546
-
547
- A browser opens with it. `/preview <folder>` picks what to serve, `/preview off` stops it.
548
-
549
- **This is not the same as double-clicking the file (`file://`).** Under `file://` everything
550
- below is blocked — and the error only shows up in the console while the page stays blank, so
551
- you end up suspecting your own code. This is a real HTTP server, so it all works:
552
-
553
- | | `file://` | `/preview` |
554
- |---|---|---|
555
- | `<script type="module">` · `import` | blocked (CORS) | **works** |
556
- | `fetch('./data.json')` | blocked | **works** |
557
- | `new Worker(...)` | blocked | **works** |
558
- | `WebAssembly.compileStreaming` | blocked (MIME) | **works** |
559
- | textures · `getImageData` | tainted canvas | **works** |
560
- | `.glb` / `.gltf` (Three.js) | no MIME type → silently not drawn | **works** |
561
-
562
- All seven were run in a real Chrome and confirmed **7/7**.
563
-
564
- Apps with a router (React Router and friends) get the first page back when you reload on a
565
- deep link. Never for requests with an extension (`app.js`) though — returning HTML for a
566
- missing script dies with `Unexpected token '<'`, which hides the real cause (a typo in a filename).
567
-
568
- ### It opens exactly as much as it says
569
-
570
- Starting a server means opening your disk to somebody else.
571
-
572
- - Bound to **`127.0.0.1` only**. `0.0.0.0` is not available at all — on an office network
573
- that would let anyone read your source.
574
- - Port **0** (the kernel hands out a free one). A fixed port steals someone else's.
575
- - Paths cannot leave the working scope. `../` · `%2e%2e` · double encoding · absolute paths ·
576
- null bytes · symlinks — eight of these are held shut by tests.
577
- - **It only serves.** `POST` · `PUT` · `DELETE` are refused with 405.
578
- - It shuts down when `deel` exits.
579
-
580
- ---
581
-
582
- ## Skills and plugins
583
-
584
- **deel does not carry skills with it.** On startup it scans the machine it is running on and uses
585
- whatever is there. On a clean PC: zero. On a PC with skills installed: those skills.
586
-
587
- ```
588
- project ./.deel/skills ./.claude/skills ./.deel/commands ./.claude/commands
589
- user ~/.deel/skills ~/.claude/skills ~/.claude/commands
590
- plugins ~/.claude/plugins/** ~/.deel/plugins/**
591
- ```
592
-
593
- Reads the Claude Code format: `SKILL.md` with YAML front matter, `commands/*.md`, `$ARGUMENTS`.
594
-
595
- > **More** — Loaded in three stages · Fetching plugins · Deliberately not included
596
- >
597
- > **[Extending read →](docs/en/extend.md#skills-and-plugins)**
598
-
599
- ---
600
-
601
- ### The hidden latency of local models — keeping the prefix cache alive
602
-
603
- Ollama and llama.cpp reuse computation **only while the request starts the same way as the
604
- last one.** Change one early character and everything after it — the entire conversation —
605
- is recomputed. This is the usual hidden reason long local sessions feel slower and slower,
606
- and it never shows up anywhere, because it is not an error.
607
-
608
- deel routes every message to the right mode automatically, and that mode instruction used to
609
- sit **early** in the prompt — every mode switch broke the whole cache. So the stable parts
610
- (rules, folder, project fingerprint, user rules, memory, skills) are frozen at the front and
611
- the per-turn parts (mode, pins) go last. A test pins this order down (`test/cache.test.js`).
612
-
613
- Ollama also gets `keep_alive: 60m` — with the 5-minute default, the model unloads while you
614
- glance at another window, and the first message after you come back recomputes everything.
615
- Override with `DEEL_KEEP_ALIVE`. If you run llama.cpp directly, `--cache-reuse 256` on the
616
- server side does the same job.
617
-
618
- ## Reasoning effort
619
-
620
- One answer means several model calls, and **each needs a different amount of thinking.**
621
- All-high is slow; all-low wanders off.
622
-
623
- The default is **one line**. What you want to know is how hard it is thinking right now,
624
- not a stage table.
625
-
626
- ```
627
- $ /think
628
-
629
- 추론 강도 medium (첫 판단 medium · 이어가기 low · 막혔을 때 high)
630
- 더 세게 /think high 더 빠르게 /think low
631
- ```
632
-
633
- | Profile | Character |
634
- |---|---|
635
- | `even` | Same effort everywhere — predictable, slower |
636
- | `save` (default) | Hard on the first decision only |
637
- | `deep` | Everything one notch up — for hard work |
638
-
639
- Set the profile with `/think 배분 절약`. **Level and profile are different axes, so the
640
- commands were split** — `/think high` and `/think save` used to set different things under
641
- one name, which made the screen unreadable.
642
-
643
- The stage table moved to `/think 자세히` (the default at developer level).
644
-
645
- ```
646
- $ /think 자세히
647
-
648
- 추론 강도 medium (첫 판단 medium · 이어가기 low · 막혔을 때 high)
649
- 배분 절약 첫 판단만 세게, 이어가기는 얕게 — 대개 이게 낫습니다
650
-
651
- 단계 강도 출력상한 언제
652
- 첫 판단 · medium 15,549 무엇을 할지 정하는 자리
653
- 이어가기 ↓ low 13,605 도구 결과를 읽고 다음 한 수
654
- 막혔을 때 ↑ high 16,384 직전 도구가 오류를 냄
655
-
656
- 출력 상한은 16,384 (모르는 값이라 기본값) 안에서 나눕니다 — /out
657
- 컨텍스트 40,960 · 지금 찬 양 2,087
658
- ```
659
-
660
- That second-to-last line exists for a reason: **when all three caps are equal, it is the
661
- only thing that says whether that is correct.** A low known cap makes them equal, and that
662
- is fine. For a while all three read `16,384` always — which meant the table said nothing.
663
-
664
- > **More** — Context length is read off the model · /out · Truncated tool calls
665
- >
666
- > **[Speed and spend read →](docs/en/tuning.md#reasoning-effort)**
667
-
668
- ---
669
-
670
- ## Auto-compaction
671
-
672
- At 80% context, older turns are **summarised and folded** so work continues.
673
- Plain truncation makes the model forget: it re-reads files and re-fixes what it already fixed.
674
-
675
- ```
676
- ◱ Folded 44 turns into a summary — 10,399 → 3,170 tokens (70% smaller)
677
- ```
678
-
679
- The summary keeps goal / done / learned / decided / remaining. The cut point is chosen so a
680
- **tool call is never separated from its result** — splitting them makes the server return 400.
681
- If the summary request fails, it falls back to plain trimming rather than stopping.
682
-
683
- `/compact` folds on demand.
684
-
685
- ---
686
-
687
- ## Resuming a conversation
688
-
689
- Close the terminal by accident, or reboot, and the conversation is still there.
690
- Messages are written to `.deel/sessions/` **as each one completes**, so a crash
691
- loses at most the message in flight.
692
-
693
- ```
694
- $ deel sessions
695
-
696
- ── conversations in this folder ────────────────────────────────
697
- ● 20260824-090200 just now 1 turn devstral-small-2507
698
- fix the failing test
699
- · 20260824-084500 2h ago 2 turns qwen2.5-coder:7b
700
- switch src/a.js logging to the logger
701
- ```
702
-
703
- | Command | What it does |
704
- |---|---|
705
- | `deel --continue` | Resume the most recent conversation in this folder |
706
- | `deel --resume <id>` | Resume a specific one |
707
- | `deel sessions` | List what is stored |
708
- | `deel sessions --rm <id>` | Delete one |
709
-
710
- The format is `jsonl` — one message per line — so a power cut costs only the last line.
711
- Resumed history keeps tool calls paired with their results, so work continues immediately.
712
- Conversations older than 30 days and outside the most recent 30 are pruned automatically.
713
-
714
- Everything lives in `.deel/sessions/` inside the working folder, and `.gitignore`
715
- covers `.deel/` so it never reaches a repository.
716
-
717
- ---
718
-
719
- ## Attaching tools from outside (MCP)
720
-
721
- A corporate wiki search, an issue tracker, a DB query tool — if a team publishes one as an MCP
722
- server, deel uses it as a tool **without a code change**.
723
-
724
- Configure in `.deel/mcp.json`. A Claude Code config can be copied over verbatim:
725
-
726
- ```json
727
- { "mcpServers": { "wiki": { "command": "node", "args": ["wiki-mcp.js"] } } }
728
- ```
729
-
730
- The model sees it as `mcp__wiki__search`. `/mcp` shows what is attached.
731
-
732
- **Dependencies stay at zero.** The stdio transport is nothing but newline-delimited JSON-RPC
733
- 2.0 over a child process's stdin/stdout, so `child_process` and `JSON` cover it. No SDK.
734
-
735
- > **More** — But this is somebody else's program
736
- >
737
- > **[Extending read →](docs/en/extend.md#attaching-tools-from-outside-mcp)**
738
-
739
- ---
740
-
741
- ## Inside your editor (ACP)
742
-
743
- A tool that makes you open one more terminal window stops being used after about two weeks.
744
- Developers live inside the IDE. So deel speaks **ACP** (Agent Client Protocol) — Zed,
745
- JetBrains, Neovim and Emacs attach to it **without changing a line on their side**.
746
-
747
- One command in your editor's settings:
748
-
749
- ```
750
- deel acp
751
- ```
752
-
753
- The editor spawns that as a child process and exchanges newline-delimited JSON-RPC 2.0 over
754
- stdio. It is not a command you type yourself.
755
-
756
- **What you get once it is attached:**
757
-
758
- | In the editor | From deel |
759
- |---|---|
760
- | Streaming reply pane | The model's text and its reasoning |
761
- | Tool list with icons and status | `Read` is a read, `Edit` is an edit, `Bash` is an execution — **the kind is sent**, not just a name |
762
- | Clickable file links | The **absolute path** of every file touched |
763
- | Approval dialog | deel's safety rails, rendered as the editor's own prompt (`allow once` · `always allow` · `reject`) |
764
- | Mode picker | deel's seven work modes (auto · code · plan · architect · debug · ask · orchestrator) |
765
- | Stop button | Reaches the turn mid-flight, even while waiting on the model |
766
-
767
- **Still zero dependencies.** Same reason as MCP — newline-delimited JSON-RPC 2.0 is the whole
768
- transport, so no SDK is needed.
769
-
770
- > **More** — Details — the places this breaks silently
771
- >
772
- > **[Extending read →](docs/en/extend.md#inside-your-editor-acp)**
773
-
774
- ---
775
-
776
- ## Keeping secrets out of the conversation
777
-
778
- People rarely paste a key. The leak is almost always **command output**.
779
-
780
- ```
781
- env OPENAI_API_KEY=sk-proj-…
782
- git remote -v https://user:token@github.com/…
783
- curl -v > Authorization: Bearer eyJ…
784
- a failing test log the whole connection string
785
- ```
786
-
787
- That text goes to the model **and** gets written to `.deel/sessions/*.jsonl` on disk. That
788
- file is later re-read by `/recall` and can end up inside a `deel pack` bundle. Leak once and
789
- you have several copies.
790
-
791
- So it is masked at the single point where tool output enters the conversation.
792
-
793
- ```
794
- ⏺ Bash(env | grep API) done
795
- ⊘ 2 secret-looking values entered the conversation (openai · env var) — masked before the model
796
- ```
797
-
798
- What it looks for: private-key blocks · OpenAI/Anthropic keys · GitHub tokens · Slack tokens ·
799
- AWS keys · Google keys · JWTs · credentials embedded in URLs · `Authorization`-family headers ·
800
- env vars named `…KEY` / `…TOKEN` / `…SECRET` / `…PASSWORD`. Plus **the configured gateway key
801
- regardless of its shape** — that one is not a guess, it is a known value.
802
-
803
- ### File contents are deliberately not masked
804
-
805
- `.env` is exactly where masking feels most tempting, and exactly where it backfires: the model
806
- sees the masked text, edits it, writes it back — and `«가림»` lands where the real key was.
807
- **Protecting the secret would destroy it.**
808
-
809
- So on the file side it reports instead of rewriting.
810
-
811
- ```
812
- ⏺ Read(.env) 12 lines
813
- ! 3 secret-looking values entered the conversation (env var)
814
- — file contents are not masked (masking them would erase the key on write-back)
815
- ```
816
-
817
- Saying plainly what cannot be stopped beats claiming it was stopped while corrupting the file.
818
- Either way it lands in the audit log.
819
-
820
- ---
821
-
822
- ## Safety
823
-
824
- Instead of approval prompts, the design makes things **reversible**. The default `auto` mode
825
- does not ask.
826
-
827
- | Mechanism | Detail |
828
- |---|---|
829
- | **Undo** | Snapshot before every write. `/undo` restores per turn. **Includes moves and deletes done through `Bash`** |
830
- | **Change display** | The changed lines are shown on every edit; `/diff` for the whole session |
831
- | **Scope** | Outside the starting folder is refused, even if the model insists |
832
- | **Blocked commands** | Only irreversible ones (disk format, recursive delete, `--force` push) |
833
- | **No re-run** | A mutating command is never retried after failure |
834
- | **Interrupt** | Ctrl+C stops mid-answer and leaves the conversation valid |
835
- | **Spin guard** | Three identical failures stop the turn, with the reason |
836
- | **Not read** | Other tools' private stores, and deel's own logs and config (the key), are refused |
837
- | **Audit log** | Everything recorded in `.deel/audit.jsonl` |
838
-
839
- | Mode | Asks when |
840
- |---|---|
841
- | `auto` (default) | Never — undo is the safety net |
842
- | `confirm` | Irreversible commands only |
843
- | `strict` | All file changes and commands |
844
-
845
- Undo history stores whole file contents, so repeated edits to large files add up. Past 32MB
846
- it keeps the **most recent 50 turns** and drops the rest. What you just did is always
847
- undoable; `/status` shows how large the history currently is.
848
-
849
- > **More** — Files removed through Bash come back too · What it will not read
850
- >
851
- > **[Safety and corporate review read →](docs/en/safety.md#safety)**
852
-
853
- ---
854
-
855
- ## Corporate review package
856
-
857
- ```bash
858
- deel pack --out deel-import.zip
859
- ```
860
-
861
- ```
862
- ✓ deel-import.zip
863
- 94 files · 509.6KB
864
-
865
- Dependencies 0
866
- Install scripts none
867
- External imports 0
868
- Network calls 3 sites (configured address only)
869
- Ports opened 1 site (/preview only)
870
- ```
871
-
872
- The zip carries **one document for people and two for machines.** A corporate review is
873
- not a human-only process — security feeds an SBOM to a scanner, and operations reads the
874
- audit-log spec to write SIEM ingestion rules.
875
-
876
- | File | What |
877
- |---|---|
878
- | `반입심사서.txt` | Dependencies · install scripts · **every network and process-spawn call site found by scanning the source** (file:line) · the three outbound lanes · SHA-256 per file |
879
- | `sbom.cdx.json` | **SBOM (CycloneDX 1.5).** Feed it straight to a scanner. One component per file with SHA-256; dependencies stated as an **explicit empty array** — "not declared" and "none" are different claims |
880
- | `심사명세.json` | Egress list (per lane: when, where, what, how it's stopped, and the source location) · **audit-log spec** (field names and meanings, plus what is never recorded) · file hashes |
881
-
882
- ```bash
883
- deel audit # the human-readable sheet only
884
- deel sbom # the two machine-readable ones, on stdout (deel sbom | jq)
885
- deel sbom --out review.json # to a file
886
- deel sbom --only sbom # just the SBOM
887
- ```
888
-
889
- All three are generated by scanning the source, never written by hand — hand-written sheets
890
- drift, and **a review document that drifts is worse than none.** Find one wrong line and the
891
- reviewer stops trusting the rest. The audit-log spec is the one hand-written part, so a test
892
- checks it against real log records on every run.
893
-
894
- > **More** — Diagnosing a corporate gateway
895
- >
896
- > **[Safety and corporate review read →](docs/en/safety.md#corporate-review-package)**
897
-
898
- ---
899
-
900
- ## Configuration
901
-
902
- Stored in `~/.deel/config.json`. A `.deel/config.json` in the project folder takes precedence.
903
-
904
- > **More** — Supported servers · Environment variables · Flags · Project rules
905
- >
906
- > **[Configuration read →](docs/en/config.md#configuration)**
907
-
908
- ---
909
-
910
- ## Troubleshooting
911
-
912
- | Symptom | Check |
913
- |---|---|
914
- | `address not found` | Typo, DNS, VPN / intranet connectivity |
915
- | `connection refused` | Server is down or the port differs |
916
- | certificate error | `set NODE_EXTRA_CA_CERTS=C:\path\corp-ca.pem` |
917
- | behind a proxy | `set HTTPS_PROXY=http://proxy:port` |
918
- | 401 / 403 | Wrong key or auth header style (four are tried automatically) |
919
- | `address not permitted` | The lock did its job — pick a connection with `/model` |
920
- | Tool calls don't work | Run `deel diagnose`. Small models (1B–3B) often can't |
921
- | Empty replies | The server ignores streaming. deel retries once, then turns streaming off for the session |
922
- | Large files cut off mid-write | Check `/out` and raise it — the cap may be sitting at the 16,384 default because it could not be discovered |
923
- | Only `HTTP 400` shows | The server's own message is shown verbatim. If it is a length problem the number is read and applied automatically |
924
- | `deel scan` finds nothing | Server is off or on another port — use `--ports` |
925
-
926
- ---
927
-
928
- ## Development
929
-
930
- ```bash
931
- npm test Full suite (1,832 checks)
932
- npm run coverage Which lines the tests actually execute
933
- npm run verify Import + network checks only
934
- npm run bench Edit success rate
935
- npm run demo See what the UI actually looks like
936
- npm run check Syntax check every file
937
- ```
938
-
939
- Tests run against a **fake gateway**, so the loop, streaming, tool execution, undo and compaction
940
- are verified deterministically without any model. ZIP output is cross-checked with the real
941
- `unzip`; the TAR reader is fed archives produced by the real `tar`.
942
-
943
- `npm test` runs each file separately and reports **per-file exit codes**, because the exit code
944
- — not the pass marks on screen — is what CI reads, and the two can disagree: a file can pass
945
- every check and still die on the way out, leaving the screen green and the exit code 1. That
946
- happened once on Windows and cost a lot of time. The runner does not stop at the first failure,
947
- so one run tells you everything.
948
-
949
- | Suite | Checks | Covers |
950
- |---|---|---|
951
- | `smoke` | 20 | Tools, scope, undo, audit log |
952
- | `loop` | 16 | Agent loop, streaming, tool calls |
953
- | `guard` | 24 | **What it refuses to do** — denied edits, unknown tools, repeated mutations, out-of-scope writes |
954
- | `network` | 30 | Nothing escapes the configured address |
955
- | `web` | 25 | Web reads stay read-only |
956
- | `abort` | 16 | Ctrl+C leaves the conversation valid |
957
- | `parallel` | 23 | Read-only tools run together; checklists |
958
- | `cli` | 75 | **Spawns the real `deel`** and drives it to completion |
959
- | `setup` | 42 | First-run wizard, driven through a fake TTY |
960
- | `detect` | 66 | Identifying shape and auth from one address |
961
- | `modes` · `route` | 89 · 33 | Work modes; auto-switching from Auto |
962
- | `ctxsize` | 43 | Reading context length off the model |
963
- | `commands` · `commands-more` | 128 · 62 | Every slash command |
964
- | `ui` · `ui2` | 60 · 40 | Password masking, CJK width, status line, session list, Excel→text |
965
- | `encoding` · `xlsx` | 68 · 72 | Legacy-encoding detection; Excel reading |
966
- | `compact` | 21 | Summary folding, pairing intact, graceful fallback |
967
- | `store` | 34 | Session persistence, resume, crash recovery |
968
- | `scan` | 29 | Distinguishing multiple runtimes |
969
- | `plugins` | 38 | Plugin fetch/pack, ZIP/TAR |
970
- | `no-bundle` | 12 | Nothing foreign in the published package; test-file hygiene |
971
- | `edit-bench` | 20 cases | Edit success rate |
972
-
973
- > **More** — Coverage · Layout
974
- >
975
- > **[Development read →](docs/en/develop.md#development)**
976
-
977
- ---
978
-
979
- ## Release notes
980
-
981
- | Version | What changed |
982
- |---|---|
983
- | **[1.4.3](docs/en/releases.md#143)** | The README explains what's different, and the review report gets its missing line |
984
- | [1.4.2](docs/en/releases.md#142) | 1.4.1 shipped before its own security fixes this corrects that |
985
- | [1.4.1](docs/en/releases.md#141) | No new features, only what was actually found and fixed Windows abort, ReDoS, XSS |
986
- | [1.4.0](docs/en/releases.md#140) | deel gets a face, speaks English, and sees meaning eleven places |
987
- | [1.3.0](docs/en/releases.md#130) | Evidence instead of claims, the editor instead of a terminal six places |
988
- | [1.2.0](docs/en/releases.md#120) | So the conversation doesn't break — six places |
989
-
990
- What changed and why is in the **[release notes](docs/en/releases.md)**.
991
-
992
- ---
993
-
994
- ## Licence
995
-
996
- [MIT](LICENSE)
1
+ <div align="center">
2
+
3
+ <picture>
4
+ <source media="(prefers-color-scheme: dark)" srcset="docs/assets/hero-en-dark.svg">
5
+ <img alt="deel — stays on this machine" src="docs/assets/hero-en-light.svg" width="620">
6
+ </picture>
7
+
8
+ ### A coding-agent CLI that runs on local models and private gateways only
9
+
10
+ Zero dependencies · Node 20+ · Exactly one place your source can go
11
+
12
+ <br>
13
+
14
+ [![npm](https://img.shields.io/npm/v/deel-local-cli?logo=npm&logoColor=white&label=npm&color=cb3837)](https://www.npmjs.com/package/deel-local-cli)
15
+ [![downloads](https://img.shields.io/npm/dt/deel-local-cli?label=downloads&color=1a7f37)](https://www.npmjs.com/package/deel-local-cli)
16
+ [![node](https://img.shields.io/node/v/deel-local-cli?logo=nodedotjs&logoColor=white&label=node&color=5FA04E)](https://nodejs.org)
17
+ [![license](https://img.shields.io/npm/l/deel-local-cli?label=license&color=0969da)](LICENSE)
18
+
19
+ [![Node.js CI](https://img.shields.io/github/actions/workflow/status/jysvai/deel-local-cli/test.yml?branch=main&logo=github&logoColor=white&label=Node.js%20CI)](https://github.com/jysvai/deel-local-cli/actions/workflows/test.yml)
20
+ [![CodeQL](https://img.shields.io/github/actions/workflow/status/jysvai/deel-local-cli/codeql.yml?branch=main&logo=github&logoColor=white&label=CodeQL)](https://github.com/jysvai/deel-local-cli/actions/workflows/codeql.yml)
21
+ [![tests](https://img.shields.io/badge/tests-3%2C498%20passing-1a7f37?logo=checkmarx&logoColor=white)](docs/en/develop.md)
22
+
23
+ [![dependencies](https://img.shields.io/badge/dependencies-0-1a7f37)](https://www.npmjs.com/package/deel-local-cli?activeTab=dependencies)
24
+ [![ESM](https://img.shields.io/badge/ESM-Node%2020%2B-5FA04E?logo=javascript&logoColor=white)](package.json)
25
+ [![network](https://img.shields.io/badge/network-127.0.0.1%20only-1a7f37?logo=wireguard&logoColor=white)](#where-your-data-can-go)
26
+ [![telemetry](https://img.shields.io/badge/telemetry-none-1a7f37?logo=ghostery&logoColor=white)](#where-your-data-can-go)
27
+
28
+ **[한국어](README.md)** · [Corporate review](#corporate-review-package) · [Troubleshooting](#troubleshooting) · [Full docs](docs/en/)
29
+
30
+ </div>
31
+
32
+ ---
33
+
34
+ ```
35
+ ╭──────────────────────────────────────────────────────────────╮
36
+ │ deel OpenAI-compatible │
37
+ │ │
38
+ │ Model qwen2.5-coder:7b (40k tokens) │
39
+ │ Sends to this machine 127.0.0.1:11434 ← nowhere else │
40
+ │ Link streaming · tools · reasoning control │
41
+ │ Folder C:\work\myproject │
42
+ │ Approval ⏵⏵ auto-approve — nothing is asked; /undo is the net│
43
+ │ Shift+Tab to change · Tab completes a / command │
44
+ │ This PC 337 skills · 127 commands · 42 plugins │
45
+ ╰──────────────────────────────────────────────────────────────╯
46
+
47
+ ▏myproject · qwen2.5-coder:7b ▏ ▰▰▱▱▱▱▱▱▱▱ 22% 28k/128k ▏ ◎ Auto · ◇ medium·save · ⏵⏵ auto
48
+ ❯ unify the logging style
49
+
50
+ ❊ Grep(console.log)
51
+ └ 1 file · 1 hit
52
+ ◧ Read(src/runner.js)
53
+ └ 5 lines
54
+ ◈ Edit(src/runner.js)
55
+ └ 1 spot
56
+
57
+ ▌ Unified log calls to the logger format. One change in runner.js.
58
+
59
+ ── 4.2s · 3 tools · ↑3,900 ↓180
60
+ ```
61
+
62
+ ---
63
+
64
+ ## Contents
65
+
66
+ - [Why this exists](#why-this-exists)
67
+ - [What's different](#whats-different)
68
+ - [Quick start](#quick-start)
69
+ - [Where your data can go](#where-your-data-can-go)
70
+ - [Multiple local runtimes](#multiple-local-runtimes)
71
+ - [Slash commands](#slash-commands)
72
+ - [Work modes](#work-modes)
73
+ - [Simple vs developer](#simple-vs-developer)
74
+ - [Tools](#tools)
75
+ - [Korean text and Excel](#korean-text-and-excel)
76
+ - [Serving what you built](#serving-what-you-built)
77
+ - [Skills and plugins](#skills-and-plugins)
78
+ - [Reasoning effort](#reasoning-effort)
79
+ - [Auto-compaction](#auto-compaction)
80
+ - [Resuming a conversation](#resuming-a-conversation)
81
+ - [Attaching tools from outside (MCP)](#attaching-tools-from-outside-mcp)
82
+ - [Inside your editor (ACP)](#inside-your-editor-acp)
83
+ - [Keeping secrets out of the conversation](#keeping-secrets-out-of-the-conversation)
84
+ - [Safety](#safety)
85
+ - [Corporate review package](#corporate-review-package)
86
+ - [Configuration](#configuration)
87
+ - [Troubleshooting](#troubleshooting)
88
+ - [Development](#development)
89
+ - [Release notes](#release-notes)
90
+
91
+ This page is the **summary**. Each section links to the detail behind it.
92
+
93
+ | Full docs | What is in there |
94
+ |---|---|
95
+ | [Models](docs/en/models.md) | Grade and window size · Korean-model presets · project detection |
96
+ | [The screen](docs/en/interface.md) | The input box · work modes · simple vs developer · what it asks about |
97
+ | [Tools in depth](docs/en/tools.md) | `Outline` · `Verify` · `Task` · `Jobs` · `Append` · `Def`/`Refs` · edit matching |
98
+ | [Korean documents and Excel](docs/en/documents.md) | hwpx/docx/pptx · encoding · Excel → CSV |
99
+ | [Extending](docs/en/extend.md) | Skills · plugins · MCP · ACP |
100
+ | [Speed and spend](docs/en/tuning.md) | Per-stage effort · the prefix cache · context length |
101
+ | [Safety and corporate review](docs/en/safety.md) | Undo · working scope · audit log · the review package |
102
+ | [Configuration](docs/en/config.md) · [Development](docs/en/develop.md) | Env vars · run flags · running the tests · folder layout |
103
+ | [Release notes](docs/en/releases.md) | [1.5.0](docs/en/releases.md#150) · [1.4.3](docs/en/releases.md#143) · [1.4.2](docs/en/releases.md#142) · [1.4.1](docs/en/releases.md#141) · [1.4.0](docs/en/releases.md#140) · [1.3.0](docs/en/releases.md#130) · [1.2.0](docs/en/releases.md#120) |
104
+
105
+ ---
106
+
107
+ ## Why this exists
108
+
109
+ When a corporate security policy blocks **unapproved software**, most coding-agent tools are
110
+ unusable: hundreds of transitive dependencies, scripts that run at install time, and no
111
+ one-line answer to "where does it send my code?"
112
+
113
+ deel is built to pass that review.
114
+
115
+ | | deel |
116
+ |---|---|
117
+ | External dependencies | **0** — Node built-ins only |
118
+ | Install scripts | **none** — unzip and run |
119
+ | Where source can go | **one address** — the one you configured |
120
+ | Requirement | Node 20+ |
121
+
122
+ Verify it yourself:
123
+
124
+ ```bash
125
+ npm view deel-local-cli dependencies # {}
126
+ npm view deel-local-cli scripts # no install/postinstall
127
+ deel audit # full review sheet
128
+ ```
129
+
130
+ ---
131
+
132
+ ## What's different
133
+
134
+ A handful of coding agents can talk to a local model. Far fewer were
135
+ **redesigned inside for running locally.**
136
+
137
+ | | Other tools | deel |
138
+ |---|---|---|
139
+ | `/undo` | rolls back files only — the conversation still believes it happened | rewinds **the conversation too** |
140
+ | Long conversations | pay a cost cloud tools never feel, unchanged, locally | ordering designed so the prefix cache **survives** |
141
+ | Edits on small models | fail on a single whitespace mismatch | 20%→**100%** success, 0 wrong-location edits |
142
+ | Korean models | unknown until you've run them | known **in advance** from public docs |
143
+ | "Done" | says so even for what wasn't checked | `/evidence` / `/export` — **unproven items included** |
144
+ | MCP · ACP | need an SDK | `child_process` + `JSON`, nothing else |
145
+ | Compliance paperwork | hand-written, drifts from reality | **generated by scanning the source** |
146
+
147
+ <br>
148
+
149
+ #### `/undo` rewinds the conversation along with the files
150
+
151
+ Roll back only the files and the model still believes it just made that edit
152
+ — it builds the next step on a premise that no longer holds, and nothing on
153
+ screen says otherwise. deel folds the messages back in lockstep with the
154
+ files. Folding can orphan a tool call, which the server answers with a 400,
155
+ so the same pass repairs the pairing (`repairToolPairs`).
156
+
157
+ #### Fixed the hidden reason local models get slower as a conversation grows
158
+
159
+ Ollama and llama.cpp only reuse computation when a request's prefix exactly
160
+ matches the last one — change one character near the front and everything
161
+ after it, the whole conversation, gets recomputed. A cloud API never pays
162
+ this cost, so cloud-first tools have no reason to care; someone running
163
+ locally feels it compound every turn. deel pushes what can change per turn
164
+ (mode, pins) to the **end** of the prompt and sends Ollama `keep_alive: 60m`
165
+ so the front stays cached. The ordering is enforced by a test
166
+ (`test/cache.test.js`).
167
+
168
+ #### Edits actually succeed on small models
169
+
170
+ Small local models often can't reproduce the exact whitespace of the string
171
+ they're trying to edit. The internal benchmark (`npm run bench`) measured
172
+ 20% success for the old exact-match-only approach. The current approach
173
+ (stepped whitespace/indent tolerance) measures **100%** — and both approaches
174
+ land at **0** wrong-location edits. When it's ambiguous, it says so instead
175
+ of guessing.
176
+
177
+ #### Korean models are known before you've ever run them
178
+
179
+ EXAONE, HyperCLOVA X, Kanana, Midm, and Solar get whatever's verifiable from
180
+ public documentation (e.g., whether a model is a reasoning model) applied
181
+ before the first prompt. Other tools meet these models cold, and it takes a
182
+ dozen-plus turns of trial and error before anyone learns their quirks.
183
+
184
+ #### "Done" comes with a receipt, not just a claim
185
+
186
+ `/evidence` and `/export` record what wasn't verified alongside what was —
187
+ because the moment an AI coding tool is most likely to mislead someone is
188
+ exactly the moment it confidently says "done." `/export` is a self-contained
189
+ HTML file with zero outbound links, so it opens anywhere, including an
190
+ air-gapped network.
191
+
192
+ #### MCP and ACP, with no SDK
193
+
194
+ Both the Model Context Protocol and the Agent Client Protocol are just
195
+ newline-delimited JSON-RPC 2.0 over stdio. deel implements both with nothing
196
+ but `child_process` and `JSON` — proof that zero dependencies isn't a
197
+ capability given up, it's a capability that was never needed.
198
+
199
+ #### Compliance paperwork it doesn't hand-write
200
+
201
+ The import-review report, SBOM, and audit spec that `deel pack` produces are
202
+ generated **by scanning the actual source**, not typed by a person.
203
+ Hand-written paperwork eventually drifts from reality, and the moment a
204
+ reviewer catches one drifted claim, they stop trusting the rest of it.
205
+
206
+ ---
207
+
208
+ ## Quick start
209
+
210
+ ### The screen speaks English too
211
+
212
+ deel is written in Korean — the code, the function names, the comments. That part stays.
213
+ What you see on screen does not have to.
214
+
215
+ ```bash
216
+ DEEL_LANG=en deel # this run only
217
+ /lang en # and remember it
218
+ /lang # how much is translated so far
219
+ ```
220
+
221
+ Untranslated lines come through in Korean rather than as blanks, and `/lang` tells you exactly
222
+ how many are left.
223
+
224
+ What the model reads follows the same switch. Set it to English and the rules, the mode
225
+ instructions, and the tool descriptions all go out in English — so the model answers you in
226
+ English instead of Korean. That side is cheaper, too: the part of the window that ships on every
227
+ single request drops from about 4,900 tokens to about 3,450 — on a 32k model, from 15% of the
228
+ window to 10.5%.
229
+
230
+ Tool names and argument names stay Korean (`목적`, `할일`, `번호`). Those are identifiers, not
231
+ prose — rename them and the tool stops being called at all.
232
+
233
+ ### Install
234
+
235
+ ```bash
236
+ npm install -g deel-local-cli
237
+ ```
238
+
239
+ Or skip installing entirely — there is no `npm install` step:
240
+
241
+ ```bash
242
+ git clone https://github.com/jysvai/deel-local-cli
243
+ node deel-local-cli/bin/deel.js
244
+ ```
245
+
246
+ > **Note** — do not run `npm install` in your home directory. A `node_modules` there makes every
247
+ > later npm command scan it and report warnings about unrelated packages. Use `-g` or `npx`.
248
+
249
+ ### Point it at a model
250
+
251
+ Scan this machine and pick one:
252
+
253
+ ```bash
254
+ deel scan --pick
255
+ ```
256
+
257
+ Or enter an address directly (use this for a corporate gateway):
258
+
259
+ ```bash
260
+ deel setup
261
+ ```
262
+
263
+ ### Start
264
+
265
+ Run `deel` in the folder you want to work in. **That folder becomes the scope — files outside it
266
+ cannot be read or written.**
267
+
268
+ ```bash
269
+ cd C:\work\myproject
270
+ deel
271
+ ```
272
+
273
+ ---
274
+
275
+ ## Where your data can go
276
+
277
+ A coding agent ships your whole source to a model. **The address is everything.**
278
+ Rather than promising in prose, the code enforces it: `src/safety/network.js` checks every request
279
+ and never builds one for an address that is not on the allow-list.
280
+
281
+ ```
282
+ [A] Model gateway ────── the only path your source travels
283
+ One address, set in `setup`. Switching models closes the previous one.
284
+
285
+ [B] Web read (WebFetch) ─ receive-only
286
+ GET only, zero-byte body. Private/loopback addresses refused. Every visit logged.
287
+
288
+ [C] Plugin fetch ─────── open only while /plugin install runs
289
+
290
+ [D] MCP servers ──────── a separate child process, someone else's program
291
+ Only starts if a human writes it into .deel/mcp.json. Off by default.
292
+ ```
293
+
294
+ A, B, and C are requests deel makes itself, so each one can be filtered.
295
+ **D is different** — an MCP server is its own process; there is no way to see
296
+ what sockets it opens from the outside. So under `--offline`, instead of
297
+ filtering its requests, deel **never starts the server at all** — it doesn't
298
+ claim to have blocked what it can't actually see.
299
+
300
+ Pass `--offline` and **B, C, and D are all closed** — traffic stays on this machine.
301
+
302
+ ```bash
303
+ deel --offline
304
+ ```
305
+
306
+ The destination is printed at the top of every session:
307
+
308
+ ```
309
+ Sends to this machine 127.0.0.1:11434 ← nowhere else
310
+ ```
311
+
312
+ Nothing is collected or transmitted. No telemetry, no usage stats, no crash reporting.
313
+ Conversation history, undo snapshots and config live only in `.deel/` inside your working folder.
314
+
315
+ > Verified by 123 checks in `npm test` (network + web + mcp), including bringing up a real
316
+ > server and confirming that **not a single request reaches it** when it is not allow-listed,
317
+ > and that an MCP server **never starts** under `--offline`.
318
+
319
+ ---
320
+
321
+ ## Multiple local runtimes
322
+
323
+ People rarely run just one. `deel scan` knocks on 13 known ports concurrently and identifies
324
+ each runtime from its **response**, not its port number — Ollama by `/api/version`,
325
+ LM Studio by `/api/v0/models`, llama.cpp by `/props`. Unrecognised ones are marked as a guess.
326
+
327
+ ```
328
+ $ deel scan
329
+
330
+ ✓ found 3
331
+
332
+ ◆ Ollama 127.0.0.1:11434 Ollama API 36ms
333
+ · qwen2.5-coder:7b 7B · 4.4GB
334
+ · llama3.2:1b 1B · 1.2GB
335
+ ◆ LM Studio 127.0.0.1:1234 OpenAI-compat 7ms
336
+ · devstral-small-2507
337
+ ◆ llama.cpp 127.0.0.1:8080 OpenAI-compat 7ms
338
+ · gemma-3-4b-it
339
+
340
+ Recommended Ollama · qwen2.5-coder:7b
341
+ ```
342
+
343
+ | Command | What it does |
344
+ |---|---|
345
+ | `deel scan` | Show what is running |
346
+ | `deel scan --pick` | Choose one from the list |
347
+ | `deel scan --save` | Register everything found |
348
+ | `deel scan --ports 9000,9100` | Extra ports to probe |
349
+ | `deel scan --host <addr>` | Defaults to `127.0.0.1` |
350
+
351
+ Switch with `/model` mid-conversation — **the conversation carries over.**
352
+
353
+ > **More** — It adapts to whatever model is attached · Korean models are known before they are experienced · Small windows get a smaller fixed share · On startup it reads what kind of project this folder is
354
+ >
355
+ > **[Models read →](docs/en/models.md#multiple-local-runtimes)**
356
+
357
+ ---
358
+
359
+ ## Slash commands
360
+
361
+ Names follow Claude Code / Codex conventions.
362
+
363
+ | Command | What it does |
364
+ |---|---|
365
+ | `/help` | Command list |
366
+ | `/lang [ko\|en]` | Screen language. Falls back to Korean for anything not translated yet |
367
+ | `/bell [on\|off]` | Ring and set the window title when a turn ends, or when deel needs an answer |
368
+ | `/consult <profile> <question>` | Ask a second model one question. Your current model stays put |
369
+ | `/export` | This conversation as a **one-page HTML report** — asked, changed, verified. Self-contained, opens on any network |
370
+ | `/lsp [on\|off]` | Language servers — what is installed, and whether `Def`/`Refs` are available. `off` turns post-edit diagnostics off only |
371
+ | `/context` | What is consuming the context window |
372
+ | `/ctx [auto\|number]` | Context **length** — re-read it off the model, or set it yourself |
373
+ | `/grade [small\|medium\|large\|auto]` | Model **grade** — how much it does on its own. A different axis from `/ctx` |
374
+ | `/out [number\|auto]` | Cap on a **single reply** — raise it when large files get cut |
375
+ | `/compact` | Summarise and fold older turns |
376
+ | `/clear` | Clear the conversation (keeps link and rules) |
377
+ | `/thread [new\|fork\|close\|n]` | Conversation threads — side work in its own context. Link and undo stay shared |
378
+ | `/learned [clear]` | What deel has picked up on its own — commands that work here, this model's habits |
379
+ | `/pin <text>` | Pin a line — folding and compaction **cannot reach it** |
380
+ | `/evidence [file]` | Evidence — what changed, and what proves it. **What is unproven is listed too** |
381
+ | `/model` | Switch connection / model |
382
+ | `/model 카드` | Model card — what this model has actually done here, and what deel changed because of it |
383
+ | `/think <level>` | Reasoning level (`off·low·medium·high·max`) |
384
+ | `/think 배분 <profile>` | Per-stage profile (`even·save·deep`) |
385
+ | `/think 자세히` | Stage table — which stage runs at which level and cap |
386
+ | `/mode <mode>` | Approval policy — how much it asks (`auto` · `confirm` · `strict`) |
387
+ | `/work [mode]` | Work mode — what kind of work you are doing |
388
+ | `/auto` | Hand the wheel back — it picks the mode from what you type |
389
+ | `/code` `/plan` `/architect` `/debug` `/ask` `/orchestrator` | Switch work mode directly (pins it) |
390
+ | `/level [level]` | How much to show (`쉬움` simple · `개발자` developer) |
391
+ | `/undo [turns]` | Revert file changes |
392
+ | `/diff [file]` | Files changed this session, and the changed lines |
393
+ | `/preview [folder\|file\|off]` | Serve what you built, right here — a browser opens with it |
394
+ | `/tools` | Available tools |
395
+ | `/skills [query\|all\|off]` | Browse, search, load skills |
396
+ | `/plugin [install\|remove\|pack]` | Manage plugins |
397
+ | `/cost` | Session usage |
398
+ | `/status` | Connection status |
399
+ | `/scan [save]` | Sweep this machine for local model servers (`save` registers them) |
400
+ | `/sessions` | Past conversations in this folder |
401
+ | `/recall <text>` | Search past conversations **by content** |
402
+ | `/memory` | What persists across sessions — view, add, delete |
403
+ | `/mcp` | Externally attached tools (MCP servers) |
404
+ | `/init` | Create a `DEEL.md` rules file |
405
+ | `/exit` | Quit |
406
+
407
+ Discovered plugin commands are invoked as `/<plugin>:<name>`, with `$ARGUMENTS` substituted.
408
+
409
+ `/scan` and `/sessions` work without leaving the session. If you just started another local
410
+ server or loaded a different model, `/scan save` then `/model` switches over without losing
411
+ the conversation.
412
+
413
+ **Without typing**
414
+
415
+ | Key | What it does |
416
+ |---|---|
417
+ | `Tab` | Completes the `/` command you are typing. Candidates appear under the box as you type |
418
+ | `Shift+Tab` | Approval policy (`⏵⏵ auto` → `⏵ risky only` → `⏸ everything`) |
419
+ | `Ctrl+O` | Work mode (`종합` → `코드` → `계획` → …) |
420
+ | `↑` `↓` | Input history |
421
+ | `Ctrl+C` | Stops the answer in progress; twice on an empty line quits |
422
+
423
+ Korean IME composition, paste, `Ctrl+A/E` and backspace all keep working.
424
+
425
+ > **More** — Attaching a file with @ · Interrupting
426
+ >
427
+ > **[The screen read →](docs/en/interface.md#slash-commands)**
428
+
429
+ ---
430
+
431
+ ## Work modes
432
+
433
+ What you are working on changes **which tools the model is given and how hard it thinks.**
434
+ Cycle with `Shift+Tab`, or type the name.
435
+
436
+ | Mode | For | Can edit files | Reasoning |
437
+ |---|---|---|---|
438
+ | `/auto` ◎ Auto | **Default.** Reads your message and switches for you | Yes | Normal (`save`) |
439
+ | `/code` ◆ Code | Writing and fixing | Yes | Normal (`save`) |
440
+ | `/plan` ☰ Plan | Planning first | **No** | Deep (`deep`·high) |
441
+ | `/architect` ◈ Architect | Shaping structure | **No** | Deep (`deep`·high) |
442
+ | `/debug` ◉ Debug | Finding causes | Yes | Deep, more steps (32) |
443
+ | `/ask` ◇ Ask | Explaining only | **No** | Shallow (`low`) |
444
+ | `/orchestrator` ❋ Orchestrator | Breaking up large work | Yes | Many steps (40) |
445
+
446
+ In read-only modes, `Write`, `Edit` and `Bash` are **never sent to the model at all.**
447
+ It is not asked politely not to edit — models forget requests. A tool that isn't there can't be used.
448
+
449
+ Don't confuse this with `/mode`. They are separate axes:
450
+
451
+ - `/mode` — **how much it asks you** (auto · confirm · strict)
452
+ - `/work` — **what kind of work you are doing** (the seven above)
453
+
454
+ If you have explicitly set `/think` or `/mode`, your choice wins. A work mode never
455
+ overrides something a person chose.
456
+
457
+ > **More** — Switching by itself (Auto mode)
458
+ >
459
+ > **[The screen read →](docs/en/interface.md#work-modes)**
460
+
461
+ ---
462
+
463
+ ## Simple vs developer
464
+
465
+ Twenty commands on first launch means nothing gets chosen. Locking features away means
466
+ hitting a wall later. So only **what is shown** differs.
467
+
468
+ | | Simple (`쉬움`, default) | Developer (`개발자`) |
469
+ |---|---|---|
470
+ | `/help` listing | Common commands only | Everything |
471
+ | Error messages | What to do about it | The original text |
472
+ | Safety | **Identical** | **Identical** |
473
+
474
+ `/level 개발자` is saved to config and persists across sessions.
475
+
476
+ Two things matter here:
477
+
478
+ - **Hidden commands still work.** `/think high` works in simple mode. It just isn't listed.
479
+ - **Beginners do not get fewer safeguards.** Undo, workspace scope and dangerous-command
480
+ blocking are identical. A beginner needs the undo more, not less.
481
+
482
+ > **More** — The input box · You don't have to type the whole command · The box stays while it works · The picture on the left moves too and 1 more
483
+ >
484
+ > **[The screen read →](docs/en/interface.md#simple-vs-developer)**
485
+
486
+ ---
487
+
488
+ ## Tools
489
+
490
+ Names and arguments match Claude Code, so skills written for that convention work unchanged.
491
+
492
+ | Tool | What it does |
493
+ |---|---|
494
+ | `Read` | Read a file (line numbers, `offset`/`limit`, **Excel as CSV, hwpx/docx/pptx as text**) |
495
+ | `Write` | Write / overwrite a file (**several at once via the `files` array**) |
496
+ | `Append` | Append to the end of a file — **how large files get written in pieces** |
497
+ | `Edit` | Replace an exact string (`replace_all`; **several sites at once via the `edits` array**) |
498
+ | `Glob` | Find files by name pattern |
499
+ | `Grep` | Regex search file contents |
500
+ | `Bash` | Run a command (**`background: true` for anything that does not finish**) |
501
+ | `Skill` | Expand a skill body (shown to the model only when skills exist) |
502
+ | `WebFetch` | Read a web page (read-only; hidden under `--offline`) |
503
+ | `Recall` | Search **past conversations** — the model digs up "that thing last time" itself |
504
+ | `Remember` | One line that outlives the session — known from the start next time |
505
+ | `TodoWrite` | Checklist — breaks long work into steps and shows progress |
506
+ | `Outline` | See a folder's **skeleton only** — tens of times cheaper than reading it whole |
507
+ | `Verify` | Check that what was built **actually works** |
508
+ | `Task` | Run one chunk of a big job in a **separate context** |
509
+ | `Jobs` | Inspect, read and stop **background commands** — the other half of `Bash`'s `background` |
510
+ | `Def` | **Where a name is defined** — only shown when a language server is installed |
511
+ | `Refs` | **Every place a name is used** — only shown when a language server is installed |
512
+
513
+ Seven tools here are not in Claude Code — `Append`, `Recall`, `Remember`, `Outline`,
514
+ `Verify`, `Task`, `Jobs`. Each tool costs 150-400 tokens of schema on **every request**,
515
+ so a test stops you every time the list grows (`test/loop.test.js`). The last four earned
516
+ their cost; here is why.
517
+
518
+ > **More** — Outline · Verify · Task · Def · Refs · Commands that never finish and 9 more
519
+ >
520
+ > **[Tools in depth read →](docs/en/tools.md#tools)**
521
+
522
+ ---
523
+
524
+ ## Korean text and Excel
525
+
526
+ **A file saved as CP949 is written back as CP949.** The encoding is never changed.
527
+ Excel (`.xlsx`) is read as CSV — read-only.
528
+
529
+ > **More** — Encoding · Excel
530
+ >
531
+ > **[Korean documents and Excel read →](docs/en/documents.md#korean-text-and-excel)**
532
+
533
+ ---
534
+
535
+ ## Serving what you built
536
+
537
+ ```
538
+ ❯ /preview
539
+
540
+ ▶ Serving http://127.0.0.1:56801/
541
+ showing .
542
+ Edit a file and the page reloads by itself.
543
+ Only this machine can open it (127.0.0.1). No other PC can see it.
544
+ Stop with /preview off · it shuts down when deel exits.
545
+ ```
546
+
547
+ A browser opens with it. `/preview <folder>` picks what to serve, `/preview off` stops it.
548
+
549
+ **This is not the same as double-clicking the file (`file://`).** Under `file://` everything
550
+ below is blocked — and the error only shows up in the console while the page stays blank, so
551
+ you end up suspecting your own code. This is a real HTTP server, so it all works:
552
+
553
+ | | `file://` | `/preview` |
554
+ |---|---|---|
555
+ | `<script type="module">` · `import` | blocked (CORS) | **works** |
556
+ | `fetch('./data.json')` | blocked | **works** |
557
+ | `new Worker(...)` | blocked | **works** |
558
+ | `WebAssembly.compileStreaming` | blocked (MIME) | **works** |
559
+ | textures · `getImageData` | tainted canvas | **works** |
560
+ | `.glb` / `.gltf` (Three.js) | no MIME type → silently not drawn | **works** |
561
+
562
+ All seven were run in a real Chrome and confirmed **7/7**.
563
+
564
+ Apps with a router (React Router and friends) get the first page back when you reload on a
565
+ deep link. Never for requests with an extension (`app.js`) though — returning HTML for a
566
+ missing script dies with `Unexpected token '<'`, which hides the real cause (a typo in a filename).
567
+
568
+ ### It opens exactly as much as it says
569
+
570
+ Starting a server means opening your disk to somebody else.
571
+
572
+ - Bound to **`127.0.0.1` only**. `0.0.0.0` is not available at all — on an office network
573
+ that would let anyone read your source.
574
+ - Port **0** (the kernel hands out a free one). A fixed port steals someone else's.
575
+ - Paths cannot leave the working scope. `../` · `%2e%2e` · double encoding · absolute paths ·
576
+ null bytes · symlinks — eight of these are held shut by tests.
577
+ - **It only serves.** `POST` · `PUT` · `DELETE` are refused with 405.
578
+ - It shuts down when `deel` exits.
579
+
580
+ ---
581
+
582
+ ## Skills and plugins
583
+
584
+ **deel does not carry skills with it.** On startup it scans the machine it is running on and uses
585
+ whatever is there. On a clean PC: zero. On a PC with skills installed: those skills.
586
+
587
+ ```
588
+ project ./.deel/skills ./.claude/skills ./.deel/commands ./.claude/commands
589
+ user ~/.deel/skills ~/.claude/skills ~/.claude/commands
590
+ plugins ~/.claude/plugins/** ~/.deel/plugins/**
591
+ ```
592
+
593
+ Reads the Claude Code format: `SKILL.md` with YAML front matter, `commands/*.md`, `$ARGUMENTS`.
594
+
595
+ > **More** — Loaded in three stages · Fetching plugins · Deliberately not included
596
+ >
597
+ > **[Extending read →](docs/en/extend.md#skills-and-plugins)**
598
+
599
+ ---
600
+
601
+ ### The hidden latency of local models — keeping the prefix cache alive
602
+
603
+ Ollama and llama.cpp reuse computation **only while the request starts the same way as the
604
+ last one.** Change one early character and everything after it — the entire conversation —
605
+ is recomputed. This is the usual hidden reason long local sessions feel slower and slower,
606
+ and it never shows up anywhere, because it is not an error.
607
+
608
+ deel routes every message to the right mode automatically, and that mode instruction used to
609
+ sit **early** in the prompt — every mode switch broke the whole cache. So the stable parts
610
+ (rules, folder, project fingerprint, user rules, memory, skills) are frozen at the front and
611
+ the per-turn parts (mode, pins) go last. A test pins this order down (`test/cache.test.js`).
612
+
613
+ Ollama also gets `keep_alive: 60m` — with the 5-minute default, the model unloads while you
614
+ glance at another window, and the first message after you come back recomputes everything.
615
+ Override with `DEEL_KEEP_ALIVE`. If you run llama.cpp directly, `--cache-reuse 256` on the
616
+ server side does the same job.
617
+
618
+ ## Reasoning effort
619
+
620
+ One answer means several model calls, and **each needs a different amount of thinking.**
621
+ All-high is slow; all-low wanders off.
622
+
623
+ The default is **one line**. What you want to know is how hard it is thinking right now,
624
+ not a stage table.
625
+
626
+ ```
627
+ $ /think
628
+
629
+ 추론 강도 medium (첫 판단 medium · 이어가기 low · 막혔을 때 high)
630
+ 더 세게 /think high 더 빠르게 /think low
631
+ ```
632
+
633
+ | Profile | Character |
634
+ |---|---|
635
+ | `even` | Same effort everywhere — predictable, slower |
636
+ | `save` (default) | Hard on the first decision only |
637
+ | `deep` | Everything one notch up — for hard work |
638
+
639
+ Set the profile with `/think 배분 절약`. **Level and profile are different axes, so the
640
+ commands were split** — `/think high` and `/think save` used to set different things under
641
+ one name, which made the screen unreadable.
642
+
643
+ The stage table moved to `/think 자세히` (the default at developer level).
644
+
645
+ ```
646
+ $ /think 자세히
647
+
648
+ 추론 강도 medium (첫 판단 medium · 이어가기 low · 막혔을 때 high)
649
+ 배분 절약 첫 판단만 세게, 이어가기는 얕게 — 대개 이게 낫습니다
650
+
651
+ 단계 강도 출력상한 언제
652
+ 첫 판단 · medium 15,549 무엇을 할지 정하는 자리
653
+ 이어가기 ↓ low 13,605 도구 결과를 읽고 다음 한 수
654
+ 막혔을 때 ↑ high 16,384 직전 도구가 오류를 냄
655
+
656
+ 출력 상한은 16,384 (모르는 값이라 기본값) 안에서 나눕니다 — /out
657
+ 컨텍스트 40,960 · 지금 찬 양 2,087
658
+ ```
659
+
660
+ That second-to-last line exists for a reason: **when all three caps are equal, it is the
661
+ only thing that says whether that is correct.** A low known cap makes them equal, and that
662
+ is fine. For a while all three read `16,384` always — which meant the table said nothing.
663
+
664
+ > **More** — Context length is read off the model · /out · Truncated tool calls
665
+ >
666
+ > **[Speed and spend read →](docs/en/tuning.md#reasoning-effort)**
667
+
668
+ ---
669
+
670
+ ## Auto-compaction
671
+
672
+ At 80% context, older turns are **summarised and folded** so work continues.
673
+ Plain truncation makes the model forget: it re-reads files and re-fixes what it already fixed.
674
+
675
+ ```
676
+ ◱ Folded 44 turns into a summary — 10,399 → 3,170 tokens (70% smaller)
677
+ ```
678
+
679
+ The summary keeps goal / done / learned / decided / remaining. The cut point is chosen so a
680
+ **tool call is never separated from its result** — splitting them makes the server return 400.
681
+ If the summary request fails, it falls back to plain trimming rather than stopping.
682
+
683
+ `/compact` folds on demand.
684
+
685
+ ---
686
+
687
+ ## Resuming a conversation
688
+
689
+ Close the terminal by accident, or reboot, and the conversation is still there.
690
+ Messages are written to `.deel/sessions/` **as each one completes**, so a crash
691
+ loses at most the message in flight.
692
+
693
+ ```
694
+ $ deel sessions
695
+
696
+ ── conversations in this folder ────────────────────────────────
697
+ ● 20260824-090200 just now 1 turn devstral-small-2507
698
+ fix the failing test
699
+ · 20260824-084500 2h ago 2 turns qwen2.5-coder:7b
700
+ switch src/a.js logging to the logger
701
+ ```
702
+
703
+ | Command | What it does |
704
+ |---|---|
705
+ | `deel --continue` | Resume the most recent conversation in this folder |
706
+ | `deel --resume <id>` | Resume a specific one |
707
+ | `deel sessions` | List what is stored |
708
+ | `deel sessions --rm <id>` | Delete one |
709
+
710
+ The format is `jsonl` — one message per line — so a power cut costs only the last line.
711
+ Resumed history keeps tool calls paired with their results, so work continues immediately.
712
+ Conversations older than 30 days and outside the most recent 30 are pruned automatically.
713
+
714
+ Everything lives in `.deel/sessions/` inside the working folder, and `.gitignore`
715
+ covers `.deel/` so it never reaches a repository.
716
+
717
+ ---
718
+
719
+ ## Attaching tools from outside (MCP)
720
+
721
+ A corporate wiki search, an issue tracker, a DB query tool — if a team publishes one as an MCP
722
+ server, deel uses it as a tool **without a code change**.
723
+
724
+ Configure in `.deel/mcp.json`. A Claude Code config can be copied over verbatim:
725
+
726
+ ```json
727
+ { "mcpServers": { "wiki": { "command": "node", "args": ["wiki-mcp.js"] } } }
728
+ ```
729
+
730
+ The model sees it as `mcp__wiki__search`. `/mcp` shows what is attached.
731
+
732
+ **Dependencies stay at zero.** The stdio transport is nothing but newline-delimited JSON-RPC
733
+ 2.0 over a child process's stdin/stdout, so `child_process` and `JSON` cover it. No SDK.
734
+
735
+ > **More** — But this is somebody else's program
736
+ >
737
+ > **[Extending read →](docs/en/extend.md#attaching-tools-from-outside-mcp)**
738
+
739
+ ---
740
+
741
+ ## Inside your editor (ACP)
742
+
743
+ A tool that makes you open one more terminal window stops being used after about two weeks.
744
+ Developers live inside the IDE. So deel speaks **ACP** (Agent Client Protocol) — Zed,
745
+ JetBrains, Neovim and Emacs attach to it **without changing a line on their side**.
746
+
747
+ One command in your editor's settings:
748
+
749
+ ```
750
+ deel acp
751
+ ```
752
+
753
+ The editor spawns that as a child process and exchanges newline-delimited JSON-RPC 2.0 over
754
+ stdio. It is not a command you type yourself.
755
+
756
+ **What you get once it is attached:**
757
+
758
+ | In the editor | From deel |
759
+ |---|---|
760
+ | Streaming reply pane | The model's text and its reasoning |
761
+ | Tool list with icons and status | `Read` is a read, `Edit` is an edit, `Bash` is an execution — **the kind is sent**, not just a name |
762
+ | Clickable file links | The **absolute path** of every file touched |
763
+ | Approval dialog | deel's safety rails, rendered as the editor's own prompt (`allow once` · `always allow` · `reject`) |
764
+ | Mode picker | deel's seven work modes (auto · code · plan · architect · debug · ask · orchestrator) |
765
+ | Stop button | Reaches the turn mid-flight, even while waiting on the model |
766
+
767
+ **Still zero dependencies.** Same reason as MCP — newline-delimited JSON-RPC 2.0 is the whole
768
+ transport, so no SDK is needed.
769
+
770
+ > **More** — Details — the places this breaks silently
771
+ >
772
+ > **[Extending read →](docs/en/extend.md#inside-your-editor-acp)**
773
+
774
+ ---
775
+
776
+ ## Keeping secrets out of the conversation
777
+
778
+ People rarely paste a key. The leak is almost always **command output**.
779
+
780
+ ```
781
+ env OPENAI_API_KEY=sk-proj-…
782
+ git remote -v https://user:token@github.com/…
783
+ curl -v > Authorization: Bearer eyJ…
784
+ a failing test log the whole connection string
785
+ ```
786
+
787
+ That text goes to the model **and** gets written to `.deel/sessions/*.jsonl` on disk. That
788
+ file is later re-read by `/recall` and can end up inside a `deel pack` bundle. Leak once and
789
+ you have several copies.
790
+
791
+ So it is masked at the single point where tool output enters the conversation.
792
+
793
+ ```
794
+ ⏺ Bash(env | grep API) done
795
+ ⊘ 2 secret-looking values entered the conversation (openai · env var) — masked before the model
796
+ ```
797
+
798
+ What it looks for: private-key blocks · OpenAI/Anthropic keys · GitHub tokens · Slack tokens ·
799
+ AWS keys · Google keys · JWTs · credentials embedded in URLs · `Authorization`-family headers ·
800
+ env vars named `…KEY` / `…TOKEN` / `…SECRET` / `…PASSWORD`. Plus **the configured gateway key
801
+ regardless of its shape** — that one is not a guess, it is a known value.
802
+
803
+ ### File contents are deliberately not masked
804
+
805
+ `.env` is exactly where masking feels most tempting, and exactly where it backfires: the model
806
+ sees the masked text, edits it, writes it back — and `«가림»` lands where the real key was.
807
+ **Protecting the secret would destroy it.**
808
+
809
+ So on the file side it reports instead of rewriting.
810
+
811
+ ```
812
+ ⏺ Read(.env) 12 lines
813
+ ! 3 secret-looking values entered the conversation (env var)
814
+ — file contents are not masked (masking them would erase the key on write-back)
815
+ ```
816
+
817
+ Saying plainly what cannot be stopped beats claiming it was stopped while corrupting the file.
818
+ Either way it lands in the audit log.
819
+
820
+ ---
821
+
822
+ ## Safety
823
+
824
+ Instead of approval prompts, the design makes things **reversible**. The default `auto` mode
825
+ does not ask.
826
+
827
+ | Mechanism | Detail |
828
+ |---|---|
829
+ | **Undo** | Snapshot before every write. `/undo` restores per turn. **Includes moves and deletes done through `Bash`** |
830
+ | **Change display** | The changed lines are shown on every edit; `/diff` for the whole session |
831
+ | **Scope** | Outside the starting folder is refused, even if the model insists |
832
+ | **Blocked commands** | Only irreversible ones (disk format, recursive delete, `--force` push) |
833
+ | **No re-run** | A mutating command is never retried after failure |
834
+ | **Interrupt** | Ctrl+C stops mid-answer and leaves the conversation valid |
835
+ | **Spin guard** | Three identical failures stop the turn, with the reason |
836
+ | **Not read** | Other tools' private stores, and deel's own logs and config (the key), are refused |
837
+ | **Audit log** | Everything recorded in `.deel/audit.jsonl` |
838
+
839
+ | Mode | Asks when |
840
+ |---|---|
841
+ | `auto` (default) | Never — undo is the safety net |
842
+ | `confirm` | Irreversible commands only |
843
+ | `strict` | All file changes and commands |
844
+
845
+ Undo history stores whole file contents, so repeated edits to large files add up. Past 32MB
846
+ it keeps the **most recent 50 turns** and drops the rest. What you just did is always
847
+ undoable; `/status` shows how large the history currently is.
848
+
849
+ > **More** — Files removed through Bash come back too · What it will not read
850
+ >
851
+ > **[Safety and corporate review read →](docs/en/safety.md#safety)**
852
+
853
+ ---
854
+
855
+ ## Corporate review package
856
+
857
+ ```bash
858
+ deel pack --out deel-import.zip
859
+ ```
860
+
861
+ ```
862
+ ✓ deel-import.zip
863
+ 94 files · 509.6KB
864
+
865
+ Dependencies 0
866
+ Install scripts none
867
+ External imports 0
868
+ Network calls 3 sites (configured address only)
869
+ Ports opened 1 site (/preview only)
870
+ ```
871
+
872
+ The zip carries **one document for people and two for machines.** A corporate review is
873
+ not a human-only process — security feeds an SBOM to a scanner, and operations reads the
874
+ audit-log spec to write SIEM ingestion rules.
875
+
876
+ | File | What |
877
+ |---|---|
878
+ | `반입심사서.txt` | Dependencies · install scripts · **every network and process-spawn call site found by scanning the source** (file:line) · the three outbound lanes · SHA-256 per file |
879
+ | `sbom.cdx.json` | **SBOM (CycloneDX 1.5).** Feed it straight to a scanner. One component per file with SHA-256; dependencies stated as an **explicit empty array** — "not declared" and "none" are different claims |
880
+ | `심사명세.json` | Egress list (per lane: when, where, what, how it's stopped, and the source location) · **audit-log spec** (field names and meanings, plus what is never recorded) · file hashes |
881
+
882
+ ```bash
883
+ deel audit # the human-readable sheet only
884
+ deel sbom # the two machine-readable ones, on stdout (deel sbom | jq)
885
+ deel sbom --out review.json # to a file
886
+ deel sbom --only sbom # just the SBOM
887
+ ```
888
+
889
+ All three are generated by scanning the source, never written by hand — hand-written sheets
890
+ drift, and **a review document that drifts is worse than none.** Find one wrong line and the
891
+ reviewer stops trusting the rest. The audit-log spec is the one hand-written part, so a test
892
+ checks it against real log records on every run.
893
+
894
+ > **More** — Diagnosing a corporate gateway
895
+ >
896
+ > **[Safety and corporate review read →](docs/en/safety.md#corporate-review-package)**
897
+
898
+ ---
899
+
900
+ ## Configuration
901
+
902
+ Stored in `~/.deel/config.json`. A `.deel/config.json` in the project folder takes precedence.
903
+
904
+ > **More** — Supported servers · Environment variables · Flags · Project rules
905
+ >
906
+ > **[Configuration read →](docs/en/config.md#configuration)**
907
+
908
+ ---
909
+
910
+ ## Troubleshooting
911
+
912
+ | Symptom | Check |
913
+ |---|---|
914
+ | `address not found` | Typo, DNS, VPN / intranet connectivity |
915
+ | `connection refused` | Server is down or the port differs |
916
+ | certificate error | `set NODE_EXTRA_CA_CERTS=C:\path\corp-ca.pem` |
917
+ | behind a proxy | `set HTTPS_PROXY=http://proxy:port` |
918
+ | 401 / 403 | Wrong key or auth header style (four are tried automatically) |
919
+ | `address not permitted` | The lock did its job — pick a connection with `/model` |
920
+ | Tool calls don't work | Run `deel diagnose`. Small models (1B–3B) often can't |
921
+ | Empty replies | The server ignores streaming. deel retries once, then turns streaming off for the session |
922
+ | Large files cut off mid-write | Check `/out` and raise it — the cap may be sitting at the 16,384 default because it could not be discovered |
923
+ | Only `HTTP 400` shows | The server's own message is shown verbatim. If it is a length problem the number is read and applied automatically |
924
+ | `deel scan` finds nothing | Server is off or on another port — use `--ports` |
925
+
926
+ ---
927
+
928
+ ## Development
929
+
930
+ ```bash
931
+ npm test Full suite (1,832 checks)
932
+ npm run coverage Which lines the tests actually execute
933
+ npm run verify Import + network checks only
934
+ npm run bench Edit success rate
935
+ npm run demo See what the UI actually looks like
936
+ npm run check Syntax check every file
937
+ ```
938
+
939
+ Tests run against a **fake gateway**, so the loop, streaming, tool execution, undo and compaction
940
+ are verified deterministically without any model. ZIP output is cross-checked with the real
941
+ `unzip`; the TAR reader is fed archives produced by the real `tar`.
942
+
943
+ `npm test` runs each file separately and reports **per-file exit codes**, because the exit code
944
+ — not the pass marks on screen — is what CI reads, and the two can disagree: a file can pass
945
+ every check and still die on the way out, leaving the screen green and the exit code 1. That
946
+ happened once on Windows and cost a lot of time. The runner does not stop at the first failure,
947
+ so one run tells you everything.
948
+
949
+ | Suite | Checks | Covers |
950
+ |---|---|---|
951
+ | `smoke` | 20 | Tools, scope, undo, audit log |
952
+ | `loop` | 16 | Agent loop, streaming, tool calls |
953
+ | `guard` | 24 | **What it refuses to do** — denied edits, unknown tools, repeated mutations, out-of-scope writes |
954
+ | `network` | 30 | Nothing escapes the configured address |
955
+ | `web` | 25 | Web reads stay read-only |
956
+ | `abort` | 16 | Ctrl+C leaves the conversation valid |
957
+ | `parallel` | 23 | Read-only tools run together; checklists |
958
+ | `cli` | 75 | **Spawns the real `deel`** and drives it to completion |
959
+ | `setup` | 42 | First-run wizard, driven through a fake TTY |
960
+ | `detect` | 66 | Identifying shape and auth from one address |
961
+ | `modes` · `route` | 89 · 33 | Work modes; auto-switching from Auto |
962
+ | `ctxsize` | 43 | Reading context length off the model |
963
+ | `commands` · `commands-more` | 128 · 62 | Every slash command |
964
+ | `ui` · `ui2` | 60 · 40 | Password masking, CJK width, status line, session list, Excel→text |
965
+ | `encoding` · `xlsx` | 68 · 72 | Legacy-encoding detection; Excel reading |
966
+ | `compact` | 21 | Summary folding, pairing intact, graceful fallback |
967
+ | `store` | 34 | Session persistence, resume, crash recovery |
968
+ | `scan` | 29 | Distinguishing multiple runtimes |
969
+ | `plugins` | 38 | Plugin fetch/pack, ZIP/TAR |
970
+ | `no-bundle` | 12 | Nothing foreign in the published package; test-file hygiene |
971
+ | `edit-bench` | 20 cases | Edit success rate |
972
+
973
+ > **More** — Coverage · Layout
974
+ >
975
+ > **[Development read →](docs/en/develop.md#development)**
976
+
977
+ ---
978
+
979
+ ## Release notes
980
+
981
+ | Version | What changed |
982
+ |---|---|
983
+ | **[1.5.0](docs/en/releases.md#150)** | Line breaks exist now, the screen got fun, and it came out lighter than before |
984
+ | [1.4.3](docs/en/releases.md#143) | The README explains what's different, and the review report gets its missing line |
985
+ | [1.4.2](docs/en/releases.md#142) | 1.4.1 shipped before its own security fixesthis corrects that |
986
+ | [1.4.1](docs/en/releases.md#141) | No new features, only what was actually found and fixedWindows abort, ReDoS, XSS |
987
+ | [1.4.0](docs/en/releases.md#140) | deel gets a face, speaks English, and sees meaningeleven places |
988
+ | [1.3.0](docs/en/releases.md#130) | Evidence instead of claims, the editor instead of a terminal — six places |
989
+ | [1.2.0](docs/en/releases.md#120) | So the conversation doesn't break — six places |
990
+
991
+ What changed and why is in the **[release notes](docs/en/releases.md)**.
992
+
993
+ ---
994
+
995
+ ## Licence
996
+
997
+ [MIT](LICENSE)