reasonix 0.5.13 → 0.5.21

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md CHANGED
@@ -3,7 +3,7 @@
3
3
  </p>
4
4
 
5
5
  <p align="center">
6
- <em>Cache-first agent loop for DeepSeek V3 &amp; R1 — Ink TUI, MCP first-class, no LangChain.</em>
6
+ <em>Cache-first agent loop for DeepSeek V4 (flash + pro) — Ink TUI, MCP first-class, no LangChain.</em>
7
7
  </p>
8
8
 
9
9
  # Reasonix
@@ -133,6 +133,34 @@ shell call will execute. Use for high-stakes changes you want to
133
133
  audit before the model touches disk. `/plan off` or picker
134
134
  Approve/Cancel exits.
135
135
 
136
+ ### Prompt prefixes — `!cmd` and `@path`
137
+
138
+ Two inline shortcuts that don't need a slash:
139
+
140
+ **`!<cmd>` — run a shell command in the sandbox and feed it to the
141
+ model.** Typed at the prompt, like bash. Output lands in the visible
142
+ log AND in the session so the model's next turn reasons about it:
143
+
144
+ ```
145
+ reasonix code › !git status --short
146
+ ▸ M src/users.ts
147
+ ▸ M src/users.test.ts
148
+
149
+ reasonix code › 把这两个文件的改动说明一下
150
+ assistant
151
+ ▸ tool<read_file> → src/users.ts, src/users.test.ts
152
+ ▸ …
153
+ ```
154
+
155
+ No allowlist gate — user-typed shell = explicit consent. 60s timeout,
156
+ 32k char cap, survives session resume since 0.5.14.
157
+
158
+ **`@path/to/file` — inline a file under "Referenced files."** Start
159
+ typing `@` and a picker appears (↑/↓ navigate, Tab/Enter to insert).
160
+ Good for "what does @src/users.ts do?" without making the model
161
+ `read_file` it first. Sandboxed: relative paths only, no `..` escape,
162
+ 64KB per-file cap. Recent files rank higher.
163
+
136
164
  ### `/commit` — stage + commit in one step
137
165
 
138
166
  ```
@@ -145,12 +173,14 @@ reasonix code › /commit "fix: findByEmail case-insensitive"
145
173
 
146
174
  - `/tool 1` — dump the last tool call's full output (when the 400-char
147
175
  inline clip isn't enough).
148
- - `/think` — see the model's full R1 reasoning for the last turn
149
- (reasoner preset only).
176
+ - `/think` — see the model's full reasoning for the last turn
177
+ (thinking-mode models: v4-flash / v4-pro / reasoner alias).
150
178
  - `/undo` — roll back the last applied edit batch.
151
179
  - `/new` — start fresh in the same directory without losing the
152
180
  session file.
153
- - `npx reasonix code --preset max` R1 + 3-way self-consistency
181
+ - `/effort high` step down from the default `max` agent-class
182
+ reasoning_effort for cheaper/faster turns on simple tasks.
183
+ - `npx reasonix code --preset max` — v4-pro + 3-way self-consistency
154
184
  branching for gnarly refactors.
155
185
  - `npx reasonix code src/` — narrower sandbox (only `src/` is
156
186
  writable).
@@ -182,7 +212,9 @@ in the file. No prompts, no completions, no tool arguments.
182
212
  ### Staying current
183
213
 
184
214
  The panel header shows the running version next to `Reasonix` (e.g.
185
- `Reasonix v0.4.22 · model …`). A quiet 24-hour background check against
215
+ `Reasonix v0.5.21 · deepseek-v4-pro · harvest · max …`, the trailing
216
+ `max` is the reasoning-effort badge — `/effort high` to step down).
217
+ A quiet 24-hour background check against
186
218
  the npm registry surfaces a yellow `update: X.Y.Z` on the right side
187
219
  of the same row when a newer version has been published. No blocking,
188
220
  no nagging — the check runs once per day max and is silent on failure
@@ -403,18 +435,25 @@ rendering, retries.
403
435
  | command | what it does |
404
436
  |---|---|
405
437
  | `/preset <fast\|smart\|max>` | one-tap bundle (model + harvest + branch) |
406
- | `/model <id>` | switch DeepSeek model (`deepseek-chat`, `deepseek-reasoner`) |
438
+ | `/model <id>` | switch DeepSeek model (`deepseek-v4-flash`, `deepseek-v4-pro`, plus `deepseek-chat` / `deepseek-reasoner` compat aliases) |
439
+ | `/models` | list live models from DeepSeek `/models` endpoint |
407
440
  | `/harvest [on\|off]` | toggle R1 plan-state extraction |
408
441
  | `/branch <N\|off>` | run N parallel samples per turn, pick best (N ≥ 2) |
409
- | `/think` | dump the last turn's full R1 reasoning |
442
+ | `/effort <high\|max>` | reasoning_effort cap — `max` is the agent default, `high` is cheaper/faster |
443
+ | `/think` | dump the last turn's full thinking-mode reasoning |
410
444
 
411
445
  **Context & tools**
412
446
 
413
447
  | command | what it does |
414
448
  |---|---|
415
- | `/mcp` | list attached MCP servers and their tools |
449
+ | `/mcp` | list attached MCP servers and their tools / resources / prompts |
450
+ | `/resource [uri]` | browse + read MCP resources (no arg → list URIs; `<uri>` → fetch) |
451
+ | `/prompt [name]` | browse + fetch MCP prompts |
416
452
  | `/tool [N]` | dump the Nth tool call's full output (1 = latest) |
417
- | `/compact [cap]` | shrink oversized tool results in the log |
453
+ | `/compact [tokens]` | shrink oversized tool results in the log (default 4000 tokens/result) |
454
+ | `/context` | break down where context tokens are going (system / tools / log) |
455
+ | `/stats` | cross-session cost dashboard (today / week / month / all-time) |
456
+ | `/keys` | keyboard shortcuts + prompt prefixes (`!` / `@` / `/`) cheatsheet |
418
457
 
419
458
  **Memory & skills**
420
459
 
@@ -468,8 +507,8 @@ rendering, retries.
468
507
  - Malformed `assistant.tool_calls` / `tool` pairing is validated on
469
508
  every outgoing API call so a corrupted session can't keep 400ing.
470
509
  - Context gauge turns yellow at 50%, red at 80% with a `/compact`
471
- nudge. Approaching the 131k window triggers an automatic
472
- compaction attempt before falling back to a forced summary.
510
+ nudge. Approaching the 1M-token window (V4 flash + pro) triggers an
511
+ automatic compaction attempt before falling back to a forced summary.
473
512
  - The `reasonix code` sandbox refuses any path that resolves outside
474
513
  the launch directory, including symlink escape and `..` traversal.
475
514
 
@@ -728,7 +767,7 @@ cd reasonix
728
767
  npm install
729
768
  npm run dev code # run CLI from source via tsx
730
769
  npm run build # tsup to dist/
731
- npm test # vitest (648 tests)
770
+ npm test # vitest (1007 tests)
732
771
  npm run lint # biome
733
772
  npm run typecheck # tsc --noEmit
734
773
  ```