jeo-code 0.6.10 → 0.6.11

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/CHANGELOG.md CHANGED
@@ -6,6 +6,15 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
6
6
 
7
7
  The README mirrors the latest 5 entries — regenerate with `bun run changelog:sync`.
8
8
 
9
+ ## [0.6.11] - 2026-06-16
10
+ _Larger reasoning budgets, and terminal capability-response sequences kept out of the prompt._
11
+
12
+ ### Changed
13
+ - **Larger thinking-token budgets across every level.** `thinkingMaxTokens` is raised (minimal 1k→4k, low 2k→8k, default 4k→16k, high 8k→24k, xhigh 16k→32k), along with the Anthropic (medium 4k→10k, high 10k→24k) and Gemini (low→4k, medium→10k, high→24k) per-provider budgets — so each reasoning level actually gets room to think.
14
+
15
+ ### Fixed
16
+ - **Terminal capability-response sequences no longer corrupt the prompt.** The mouse-report filter (0.6.7) now also swallows Device-Attributes / mode replies that the outer terminal sends when tmux probes it on attach, on both the idle keypress path and the live-turn raw-stdin drain.
17
+
9
18
  ## [0.6.10] - 2026-06-16
10
19
  _OKF memory-format foundation and a hardened bashTool subprocess drain._
11
20
 
package/README.ja.md CHANGED
@@ -158,11 +158,11 @@ CI は `.github/workflows/npm-publish.yml` で公開します — GitHub リリ
158
158
  ## 変更履歴 (Changelog)
159
159
 
160
160
  <!-- CHANGELOG:START (auto-generated from CHANGELOG.md — run `bun run changelog:sync`) -->
161
+ - **[0.6.11]** (2026-06-16) — Larger reasoning budgets, and terminal capability-response sequences kept out of the prompt.
161
162
  - **[0.6.10]** (2026-06-16) — OKF memory-format foundation and a hardened bashTool subprocess drain.
162
163
  - **[0.6.9]** (2026-06-16) — Live streaming blocks size to their content and the viewport instead of a fixed rectangle.
163
164
  - **[0.6.8]** (2026-06-16) — OAuth loopback callback host pinned to `localhost` to match provider-registered redirect URIs.
164
165
  - **[0.6.7]** (2026-06-16) — Mouse-report input corruption fixed under `jeo --tmux`, and a full-width TUI at one consistent width.
165
- - **[0.6.6]** (2026-06-16) — Vertical caret movement between input-box rows, a centered welcome banner, and a leaner `parseFlags`.
166
166
 
167
167
  See [CHANGELOG.md](CHANGELOG.md) for the full history.
168
168
  <!-- CHANGELOG:END -->
package/README.ko.md CHANGED
@@ -158,11 +158,11 @@ CI는 `.github/workflows/npm-publish.yml`로 배포합니다 — GitHub 릴리
158
158
  ## 변경 이력 (Changelog)
159
159
 
160
160
  <!-- CHANGELOG:START (auto-generated from CHANGELOG.md — run `bun run changelog:sync`) -->
161
+ - **[0.6.11]** (2026-06-16) — Larger reasoning budgets, and terminal capability-response sequences kept out of the prompt.
161
162
  - **[0.6.10]** (2026-06-16) — OKF memory-format foundation and a hardened bashTool subprocess drain.
162
163
  - **[0.6.9]** (2026-06-16) — Live streaming blocks size to their content and the viewport instead of a fixed rectangle.
163
164
  - **[0.6.8]** (2026-06-16) — OAuth loopback callback host pinned to `localhost` to match provider-registered redirect URIs.
164
165
  - **[0.6.7]** (2026-06-16) — Mouse-report input corruption fixed under `jeo --tmux`, and a full-width TUI at one consistent width.
165
- - **[0.6.6]** (2026-06-16) — Vertical caret movement between input-box rows, a centered welcome banner, and a leaner `parseFlags`.
166
166
 
167
167
  See [CHANGELOG.md](CHANGELOG.md) for the full history.
168
168
  <!-- CHANGELOG:END -->
package/README.md CHANGED
@@ -158,11 +158,11 @@ Required npm token permissions (repository secret `NPM_TOKEN`):
158
158
  ## Changelog
159
159
 
160
160
  <!-- CHANGELOG:START (auto-generated from CHANGELOG.md — run `bun run changelog:sync`) -->
161
+ - **[0.6.11]** (2026-06-16) — Larger reasoning budgets, and terminal capability-response sequences kept out of the prompt.
161
162
  - **[0.6.10]** (2026-06-16) — OKF memory-format foundation and a hardened bashTool subprocess drain.
162
163
  - **[0.6.9]** (2026-06-16) — Live streaming blocks size to their content and the viewport instead of a fixed rectangle.
163
164
  - **[0.6.8]** (2026-06-16) — OAuth loopback callback host pinned to `localhost` to match provider-registered redirect URIs.
164
165
  - **[0.6.7]** (2026-06-16) — Mouse-report input corruption fixed under `jeo --tmux`, and a full-width TUI at one consistent width.
165
- - **[0.6.6]** (2026-06-16) — Vertical caret movement between input-box rows, a centered welcome banner, and a leaner `parseFlags`.
166
166
 
167
167
  See [CHANGELOG.md](CHANGELOG.md) for the full history.
168
168
  <!-- CHANGELOG:END -->
package/README.zh.md CHANGED
@@ -158,11 +158,11 @@ CI 通过 `.github/workflows/npm-publish.yml` 发布 — GitHub 发布 release
158
158
  ## 更新日志 (Changelog)
159
159
 
160
160
  <!-- CHANGELOG:START (auto-generated from CHANGELOG.md — run `bun run changelog:sync`) -->
161
+ - **[0.6.11]** (2026-06-16) — Larger reasoning budgets, and terminal capability-response sequences kept out of the prompt.
161
162
  - **[0.6.10]** (2026-06-16) — OKF memory-format foundation and a hardened bashTool subprocess drain.
162
163
  - **[0.6.9]** (2026-06-16) — Live streaming blocks size to their content and the viewport instead of a fixed rectangle.
163
164
  - **[0.6.8]** (2026-06-16) — OAuth loopback callback host pinned to `localhost` to match provider-registered redirect URIs.
164
165
  - **[0.6.7]** (2026-06-16) — Mouse-report input corruption fixed under `jeo --tmux`, and a full-width TUI at one consistent width.
165
- - **[0.6.6]** (2026-06-16) — Vertical caret movement between input-box rows, a centered welcome banner, and a leaner `parseFlags`.
166
166
 
167
167
  See [CHANGELOG.md](CHANGELOG.md) for the full history.
168
168
  <!-- CHANGELOG:END -->
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "jeo-code",
3
- "version": "0.6.10",
3
+ "version": "0.6.11",
4
4
  "description": "Clean, highly optimized AI coding agent using spec-first loop",
5
5
  "type": "module",
6
6
  "main": "src/cli.ts",
@@ -68,11 +68,11 @@ export function providerModelFor(model: string): string {
68
68
 
69
69
  /** Map the configured thinking level to a default max-token budget. */
70
70
  export function thinkingMaxTokens(level?: "minimal" | "low" | "medium" | "high" | "xhigh"): number {
71
- if (level === "minimal") return 1000;
72
- if (level === "low") return 2000;
73
- if (level === "high") return 8000;
74
- if (level === "xhigh") return 16000;
75
- return 4000;
71
+ if (level === "minimal") return 4000;
72
+ if (level === "low") return 8000;
73
+ if (level === "high") return 24000;
74
+ if (level === "xhigh") return 31999;
75
+ return 16000;
76
76
  }
77
77
 
78
78
  /** Map the thinking level to an OpenAI reasoning-effort tier. `minimal` maps to `low`
@@ -77,8 +77,8 @@ function anthropicSystemBlocks(
77
77
  function anthropicThinkingBudget(effort: CallOptions["reasoningEffort"], maxTokens: number): number | undefined {
78
78
  let budget: number;
79
79
  switch (effort) {
80
- case "medium": budget = 4096; break;
81
- case "high": budget = 10000; break;
80
+ case "medium": budget = 10000; break;
81
+ case "high": budget = 24000; break;
82
82
  default: return undefined;
83
83
  }
84
84
  return Math.min(budget, Math.max(1024, maxTokens - 1024));
@@ -17,9 +17,9 @@ export function geminiThinkingBudget(model: string, effort?: CallOptions["reason
17
17
  const floor = m.includes("pro") ? 128 : 0; // pro-class cannot fully disable thinking
18
18
  let budget: number;
19
19
  switch (effort) {
20
- case "low": budget = 1024; break;
21
- case "medium": budget = 4096; break;
22
- case "high": budget = 8192; break;
20
+ case "low": budget = 4000; break;
21
+ case "medium": budget = 10000; break;
22
+ case "high": budget = 24000; break;
23
23
  case "minimal":
24
24
  default: budget = floor;
25
25
  }
@@ -104,16 +104,45 @@ export function matchMouseReport(data: string, i: number): number {
104
104
  return 0;
105
105
  }
106
106
 
107
- /** Remove every terminal MOUSE-REPORT sequence from a plain (non-paste) input segment.
108
- * The live-turn drain (`queuePromptInputChunk`) reads RAW stdin, so a wheel/click report
109
- * buffered during a running turn would otherwise have its printable remnant (`[M`, SGR
110
- * digits) fed into the next prompt the same "값 입력" corruption the keyFilter blocks
111
- * on the idle path. */
107
+ /** Byte length of a terminal CAPABILITY-RESPONSE sequence beginning at `data[i]`, else 0.
108
+ * These are REPLIES the terminal sends to capability queries — Primary/Secondary Device
109
+ * Attributes (`ESC[?…c` / `ESC[>…c` / `ESC[=…c`), XTVERSION and other DCS replies
110
+ * (`ESC P…ST`), and OSC replies like a color query (`ESC]11;rgb:…ST`). jeo never sends
111
+ * these queries, but tmux probes the OUTER terminal on attach, and the outer terminal's
112
+ * answers can land on stdin (the leaked `62;4;9;22c…>|xterm.js(…)` garbage in the prompt).
113
+ * They are never typed input, so the whole sequence is swallowed. A reply split across
114
+ * chunks (no terminator yet) consumes the tail rather than leaking it. */
115
+ export function matchTerminalReport(data: string, i: number): number {
116
+ // CSI device-attribute / mode replies: ESC [ (? | > | =) … <final letter>.
117
+ if (data.startsWith("\u001b[?", i) || data.startsWith("\u001b[>", i) || data.startsWith("\u001b[=", i)) {
118
+ let j = i + 3;
119
+ while (j < data.length && !/[A-Za-z]/.test(data[j]!)) j++; // params: digits ; : $ → final letter
120
+ return (j < data.length ? j + 1 : data.length) - i;
121
+ }
122
+ // DCS (ESC P … ) or OSC (ESC ] … ) reply — terminated by ST (ESC \) or BEL.
123
+ if (data.startsWith("\u001bP", i) || data.startsWith("\u001b]", i)) {
124
+ let j = i + 2;
125
+ while (j < data.length) {
126
+ if (data[j] === "\u0007") return j + 1 - i; // BEL
127
+ if (data[j] === "\u001b" && data[j + 1] === "\\") return j + 2 - i; // ST
128
+ j++;
129
+ }
130
+ return data.length - i; // unterminated tail (split chunk) — consume the rest
131
+ }
132
+ return 0;
133
+ }
134
+
135
+ /** Remove every terminal MOUSE-REPORT and CAPABILITY-RESPONSE sequence from a plain
136
+ * (non-paste) input segment. The live-turn drain (`queuePromptInputChunk`) reads RAW
137
+ * stdin, so a wheel/click report or a tmux-probed device-attribute reply buffered during
138
+ * a running turn would otherwise have its printable remnant (`[M`, SGR digits, or
139
+ * `62;4;9;22c…`) fed into the next prompt — the same "값 입력" corruption the keyFilter
140
+ * blocks on the idle path. */
112
141
  export function stripMouseReports(s: string): string {
113
142
  let out = "";
114
143
  let i = 0;
115
144
  while (i < s.length) {
116
- const m = matchMouseReport(s, i);
145
+ const m = matchMouseReport(s, i) || matchTerminalReport(s, i);
117
146
  if (m > 0) { i += m; continue; }
118
147
  out += s[i];
119
148
  i += 1;
@@ -127,6 +127,7 @@ import {
127
127
  CURSOR_COMBO_REWRITES,
128
128
  matchCursorCombo,
129
129
  matchMouseReport,
130
+ matchTerminalReport,
130
131
  stripMouseReports,
131
132
  rewriteCursorCombos,
132
133
  queuePromptInputChunk,
@@ -175,6 +176,7 @@ export {
175
176
  CURSOR_COMBO_REWRITES,
176
177
  matchCursorCombo,
177
178
  matchMouseReport,
179
+ matchTerminalReport,
178
180
  stripMouseReports,
179
181
  rewriteCursorCombos,
180
182
  queuePromptInputChunk,
@@ -1268,6 +1270,11 @@ export async function runLaunchCommand(args: string[]): Promise<void> {
1268
1270
  // their payload bytes would otherwise be typed into the prompt. Never in a paste.
1269
1271
  const mouse = matchMouseReport(data, i);
1270
1272
  if (mouse > 0) { i += mouse; continue; }
1273
+ // Swallow TERMINAL CAPABILITY-RESPONSE sequences (DA1/DA2/XTVERSION/OSC replies):
1274
+ // tmux probes the outer terminal on attach and its answers (`62;4;9;22c…>|xterm.js…`)
1275
+ // can land on stdin; without this they spray into the prompt as typed text.
1276
+ const report = matchTerminalReport(data, i);
1277
+ if (report > 0) { i += report; continue; }
1271
1278
  let matched = false;
1272
1279
  for (const seq of SHIFT_ENTER_SEQS) {
1273
1280
  if (data.startsWith(seq, i)) { out += SENTINEL; i += seq.length; matched = true; break; }