@hmharness/agent 0.23.9 → 0.23.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/dist/i18n.d.ts CHANGED
@@ -43,6 +43,12 @@ export interface Strings {
43
43
  viewingNote: string;
44
44
  tuiNeedsTty: string;
45
45
  tuiWelcome: (model: string) => string;
46
+ /** queue circuit breaker (TUI): a permanent provider auth/balance error
47
+ * (HTTP 401/402/403) holds the remaining queue instead of draining it */
48
+ tuiQueueHeld: (waiting: number) => string;
49
+ /** crash-recall notice (TUI startup): the previous process died with a
50
+ * task in flight or tasks queued; the rollout audit survives in /resume */
51
+ tuiPendingNote: (task: string, queued: number) => string;
46
52
  tuiApproval: string;
47
53
  tuiApprove: string;
48
54
  tuiDeny: string;
@@ -133,7 +139,6 @@ export interface Strings {
133
139
  opsHint: string;
134
140
  tuiLongOutputHint: (tool: string, lines: number) => string;
135
141
  tuiUserFolded: (hidden: number) => string;
136
- tuiAutoUpdating: (v: string) => string;
137
142
  tuiAutoUpdateFailed: (why: string) => string;
138
143
  tuiEvolveDone: (proposals: number, insights: number, notes: number) => string;
139
144
  tuiPassRate: (pct: string) => string;
package/dist/i18n.js CHANGED
@@ -36,6 +36,8 @@ const zh = {
36
36
  viewingNote: '正在查看历史会话',
37
37
  tuiNeedsTty: 'hmh tui 需要交互终端(raw mode)。非交互环境请用:hmh "任务"(一次性)或 hmh web(浏览器)。',
38
38
  tuiWelcome: (model) => `hmh tui · ${model} · 输入 / 查看命令 · 直接输入任务回车运行`,
39
+ tuiQueueHeld: (waiting) => `⛔ 厂商认证/余额错误(HTTP 401/402/403)——队列暂停,保留 ${waiting} 个任务未执行。修复密钥/余额或 /model 换路由后重新提交即可。`,
40
+ tuiPendingNote: (task, queued) => `⟲ 上次异常退出时有未完成任务: "${task}"${queued > 0 ? `(另有 ${queued} 个排队)` : ''}。对话审计可用 /resume 续接;重发可直接输入该任务。`,
39
41
  tuiApproval: '⚠ 审批',
40
42
  tuiApprove: '批准',
41
43
  tuiDeny: '拒绝',
@@ -112,7 +114,6 @@ const zh = {
112
114
  opsHint: '更多操作:/ops scan 立即扫描并生成今日简报 · /ops brief 查看最近简报',
113
115
  tuiLongOutputHint: (tool, lines) => `⎿ ${tool} 输出 ${lines} 行(已折叠) · 按 z 展开最后一条 · Ctrl+T 看全文`,
114
116
  tuiUserFolded: (hidden) => `(…还有 ${hidden} 行已折叠 · Ctrl+T 看全文)`,
115
- tuiAutoUpdating: (v) => `⤴ 发现新版本 ${v},已在后台自动更新,下次启动 hmh 生效`,
116
117
  tuiAutoUpdateFailed: (why) => `⤴ 自动更新未能开始(${why}),下次再试;或手动: npm i -g @hmharness/cli@latest`,
117
118
  tuiEvolveDone: (p, i, n) => `evolve 完成: ${p} 提案 · 洞察 ${i} · 记忆 ${n}`,
118
119
  tuiPassRate: (pct) => `pass rate: ${pct}`,
@@ -188,6 +189,8 @@ const en = {
188
189
  viewingNote: 'viewing a past session',
189
190
  tuiNeedsTty: 'hmh tui needs an interactive terminal (raw mode). Non-interactive: use hmh "task" (one-shot) or hmh web (browser).',
190
191
  tuiWelcome: (model) => `hmh tui · ${model} · type / for commands · type a task and press Enter to run`,
192
+ tuiQueueHeld: (waiting) => `⛔ provider auth/balance error (HTTP 401/402/403) - queue PAUSED, ${waiting} task(s) held. Fix the key/balance or /model to switch route, then resubmit.`,
193
+ tuiPendingNote: (task, queued) => `⟲ the previous session died with work pending: "${task}"${queued > 0 ? ` (+${queued} queued)` : ''}. Audit/continue via /resume; resubmit by retyping the task.`,
191
194
  tuiApproval: '⚠ approval',
192
195
  tuiApprove: 'Approve',
193
196
  tuiDeny: 'Deny',
@@ -264,7 +267,6 @@ const en = {
264
267
  opsHint: 'more: /ops scan pull upstream + write today brief · /ops brief latest brief',
265
268
  tuiLongOutputHint: (tool, lines) => `⎿ ${tool} produced ${lines} lines (folded) · z expands the last cell · Ctrl+T full transcript`,
266
269
  tuiUserFolded: (hidden) => `(…${hidden} more lines folded · Ctrl+T full transcript)`,
267
- tuiAutoUpdating: (v) => `⤴ new version ${v} - updating in the background, effective on next launch`,
268
270
  tuiAutoUpdateFailed: (why) => `⤴ auto-update could not start (${why}); or manually: npm i -g @hmharness/cli@latest`,
269
271
  tuiEvolveDone: (p, i, n) => `evolve done: ${p} proposals · ${i} insights · ${n} notes`,
270
272
  tuiPassRate: (pct) => `pass rate: ${pct}`,
package/dist/runner.js CHANGED
@@ -433,7 +433,7 @@ export async function runAgentTask(opts) {
433
433
  // write drains - awaiting first made model.responded land AFTER
434
434
  // run.completed in the timeline
435
435
  traj.emit('model.responded', 'agent', { contentChars: m.content?.length ?? 0, toolCalls: m.tool_calls?.length ?? 0 });
436
- await session.assistant(m.content ?? null, m.tool_calls);
436
+ await session.assistant(m.content ?? null, m.tool_calls, chatProvider.model);
437
437
  },
438
438
  },
439
439
  }).catch((err) => {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@hmharness/agent",
3
- "version": "0.23.9",
3
+ "version": "0.23.11",
4
4
  "description": "hmharness agent execution layer: base tools, system prompt, sub-agent spawn, and the shared task runner that frontends (cli, web) drive.",
5
5
  "type": "module",
6
6
  "main": "dist/index.js",
@@ -15,13 +15,13 @@
15
15
  "build": "tsc -p tsconfig.build.json"
16
16
  },
17
17
  "dependencies": {
18
- "@hmharness/cognitive": "0.23.9",
19
- "@hmharness/domain-harmony": "0.23.9",
20
- "@hmharness/domain-ops": "0.23.9",
21
- "@hmharness/evolution": "0.23.9",
22
- "@hmharness/kernel": "0.23.9",
23
- "@hmharness/observability": "0.23.9",
24
- "@hmharness/sandbox": "0.23.9"
18
+ "@hmharness/cognitive": "0.23.11",
19
+ "@hmharness/domain-harmony": "0.23.11",
20
+ "@hmharness/domain-ops": "0.23.11",
21
+ "@hmharness/evolution": "0.23.11",
22
+ "@hmharness/kernel": "0.23.11",
23
+ "@hmharness/observability": "0.23.11",
24
+ "@hmharness/sandbox": "0.23.11"
25
25
  },
26
26
  "files": [
27
27
  "dist"