dsh-ssh-tui 0.3.1 → 0.3.2
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 +25 -11
- package/README.md +26 -10
- package/cordis.patch.yml +1 -1
- package/lib/tui.js +135 -42
- package/lib/tui.js.map +1 -1
- package/lib/types/tui.d.ts +27 -2
- package/package.json +4 -2
- package/docs/screenshots/headless-labeled.png +0 -0
- package/docs/screenshots/workspace-labeled.png +0 -0
package/lib/types/tui.d.ts
CHANGED
|
@@ -7,7 +7,7 @@
|
|
|
7
7
|
*
|
|
8
8
|
* The renderer uses plain ANSI and coalesces each frame into one stdout
|
|
9
9
|
* write of dirty rows only — jump-host / proxied SSH should see one packet
|
|
10
|
-
* per paint, not one per line. Cadence is DSH_TUI_PAINT_MS (default
|
|
10
|
+
* per paint, not one per line. Cadence is DSH_TUI_PAINT_MS (default 160).
|
|
11
11
|
*/
|
|
12
12
|
import type { Agent, ModelSelection, ModelSelectionRef } from '@deepseek-ai/dsh-agent';
|
|
13
13
|
import type { Context } from '@deepseek-ai/cordis';
|
|
@@ -53,7 +53,7 @@ export interface TuiConfig {
|
|
|
53
53
|
/**
|
|
54
54
|
* Minimum milliseconds between paints while a turn is streaming.
|
|
55
55
|
* Jump-host / proxied SSH can raise this so token ticks do not flood the
|
|
56
|
-
* link. Defaults from `DSH_TUI_PAINT_MS` (
|
|
56
|
+
* link. Defaults from `DSH_TUI_PAINT_MS` (160).
|
|
57
57
|
*/
|
|
58
58
|
paintIntervalMs?: number;
|
|
59
59
|
}
|
|
@@ -121,6 +121,11 @@ type Row = {
|
|
|
121
121
|
expanded: boolean;
|
|
122
122
|
/** When true the plan stays in the scrolling transcript, not the dock. */
|
|
123
123
|
archived?: boolean;
|
|
124
|
+
/**
|
|
125
|
+
* Display-only: the last turn ended while todos were still open.
|
|
126
|
+
* Does not rewrite the session log.
|
|
127
|
+
*/
|
|
128
|
+
turnLeftOpen?: boolean;
|
|
124
129
|
} | {
|
|
125
130
|
kind: 'question';
|
|
126
131
|
questionId: string;
|
|
@@ -257,6 +262,19 @@ export declare function planIsLive(plan: {
|
|
|
257
262
|
planMarkdown?: string;
|
|
258
263
|
archived?: boolean;
|
|
259
264
|
}): boolean;
|
|
265
|
+
/** Open todos left behind when a turn ends without a completing todo_write. */
|
|
266
|
+
export declare function planTurnLeftOpen(plan: {
|
|
267
|
+
todos: readonly PlanTodoItem[];
|
|
268
|
+
}): boolean;
|
|
269
|
+
/** Mark leftover in-progress/pending todos as display-stale after turn/end. */
|
|
270
|
+
export declare function applyTurnEndToPlan<T extends {
|
|
271
|
+
todos: PlanTodoItem[];
|
|
272
|
+
turnLeftOpen?: boolean;
|
|
273
|
+
}>(plan: T): T;
|
|
274
|
+
/** Follow-up that asks the model to close leftover todos. One per open list. */
|
|
275
|
+
export declare function planCloseNudgeText(plan: {
|
|
276
|
+
todos: readonly PlanTodoItem[];
|
|
277
|
+
}): string;
|
|
260
278
|
export type CardCategory = 'thinking' | 'plan' | 'subagent' | 'reply' | 'tool' | 'question' | 'goal';
|
|
261
279
|
/** Category for jump / search. Assistant replies are not collapsible cards. */
|
|
262
280
|
export declare function cardCategoryOf(row: {
|
|
@@ -275,6 +293,7 @@ export declare function planDockNote(plan: {
|
|
|
275
293
|
pending: boolean;
|
|
276
294
|
todos: readonly PlanTodoItem[];
|
|
277
295
|
planMarkdown?: string;
|
|
296
|
+
turnLeftOpen?: boolean;
|
|
278
297
|
}): string;
|
|
279
298
|
/** Compact per-status counts matching the web plan strip. */
|
|
280
299
|
export declare function todoProgressLabel(todos: readonly PlanTodoItem[]): string;
|
|
@@ -408,6 +427,8 @@ export declare class SshTui {
|
|
|
408
427
|
private searchHits;
|
|
409
428
|
private searchIndex;
|
|
410
429
|
private searchQuery;
|
|
430
|
+
private planNudgePending;
|
|
431
|
+
private pendingReveal;
|
|
411
432
|
constructor(ctx: Context, agent: Agent, config: TuiConfig);
|
|
412
433
|
/** Enter raw mode, switch to the alternate screen, and start listening. */
|
|
413
434
|
start(): void;
|
|
@@ -438,6 +459,8 @@ export declare class SshTui {
|
|
|
438
459
|
private upsertPlanRow;
|
|
439
460
|
/** Whether the live plan strip should occupy the workspace footer. */
|
|
440
461
|
private shouldDockPlan;
|
|
462
|
+
/** One follow-up per leftover list; replay and cancelled turns stay quiet. */
|
|
463
|
+
private queuePlanCloseNudge;
|
|
441
464
|
/** Compact web-style plan strip pinned above the input, not in the transcript. */
|
|
442
465
|
private paintPlanDock;
|
|
443
466
|
private paintCollapsibleHeader;
|
|
@@ -447,6 +470,8 @@ export declare class SshTui {
|
|
|
447
470
|
private toggleCollapsible;
|
|
448
471
|
/** Expand all collapsible blocks, or collapse them again when all are open. */
|
|
449
472
|
private toggleAllCollapsible;
|
|
473
|
+
private highlightSearchLine;
|
|
474
|
+
private revealRow;
|
|
450
475
|
private focusCard;
|
|
451
476
|
/** Jump to the newest card in a category (thinking / plan / subagent / reply). */
|
|
452
477
|
private jumpToCategory;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "dsh-ssh-tui",
|
|
3
|
-
"version": "0.3.
|
|
3
|
+
"version": "0.3.2",
|
|
4
4
|
"description": "SSH-friendly interactive terminal TUI plugin for DeepSeek Harness",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"deepseek-harness",
|
|
@@ -42,7 +42,9 @@
|
|
|
42
42
|
"cordis.patch.yml",
|
|
43
43
|
"README.md",
|
|
44
44
|
"README.en.md",
|
|
45
|
-
"docs/screenshots",
|
|
45
|
+
"docs/screenshots/compare.png",
|
|
46
|
+
"docs/screenshots/headless.png",
|
|
47
|
+
"docs/screenshots/workspace.png",
|
|
46
48
|
"LICENSE"
|
|
47
49
|
],
|
|
48
50
|
"license": "MIT",
|
|
Binary file
|
|
Binary file
|