@qwen-code/web-shell 0.28.0 → 0.28.1-preview.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/dist/sw.js CHANGED
@@ -6,4 +6,4 @@
6
6
  * Cache-first for same-origin build assets. Manifest, daemon API requests,
7
7
  * authenticated requests and event streams remain network-only. HTML is
8
8
  * never cached: an unavailable daemon gets a retry page, not a stale session.
9
- */var r="0.28.0",s="qwen-code-shell-v1-"+r;self.addEventListener("install",function(n){n.waitUntil(self.skipWaiting())});self.addEventListener("activate",function(n){n.waitUntil(caches.keys().then(function(t){return Promise.all(t.filter(function(e){return e.startsWith("qwen-code-shell-")&&e!==s}).map(function(e){return caches.delete(e)})).then(function(){return self.clients.claim()})}))});async function c(n,t){var e;try{e=await caches.open(s);var i=await e.match(n);if(i)return i}catch{}var a=await fetch(n);return e&&a.status===200&&a.type==="basic"&&t.waitUntil(e.put(n,a.clone()).catch(function(){})),a}self.addEventListener("fetch",function(n){var t=n.request,e=new URL(t.url);if(!(t.method!=="GET"||t.headers.has("Authorization")||(t.headers.get("Accept")||"").includes("text/event-stream")||e.origin!==self.location.origin)){if(e.pathname.startsWith("/assets/")&&/-[a-zA-Z0-9_-]{8,}\.[^/]+$/.test(e.pathname)){n.respondWith(c(t,n));return}t.mode==="navigate"&&(t.destination==="document"||!t.destination)&&n.respondWith(fetch(t).catch(function(){return new Response('<!doctype html><html lang="en"><meta charset="utf-8"><meta name="viewport" content="width=device-width,initial-scale=1"><title>Qwen Code unavailable</title><body><h1>Cannot reach Qwen Code / <span lang="zh-CN">无法连接 Qwen Code</span></h1><p>Reconnect to the daemon, then reload this page. / <span lang="zh-CN">请重新连接守护进程,然后重新加载此页面。</span></p><a href="" onclick="location.reload();return false">Try again / <span lang="zh-CN">重试</span></a></body></html>',{status:503,headers:{"Content-Type":"text/html; charset=utf-8","Cache-Control":"no-store"}})}))}});
9
+ */var r="0.28.1-preview.0",s="qwen-code-shell-v1-"+r;self.addEventListener("install",function(n){n.waitUntil(self.skipWaiting())});self.addEventListener("activate",function(n){n.waitUntil(caches.keys().then(function(t){return Promise.all(t.filter(function(e){return e.startsWith("qwen-code-shell-")&&e!==s}).map(function(e){return caches.delete(e)})).then(function(){return self.clients.claim()})}))});async function c(n,t){var e;try{e=await caches.open(s);var i=await e.match(n);if(i)return i}catch{}var a=await fetch(n);return e&&a.status===200&&a.type==="basic"&&t.waitUntil(e.put(n,a.clone()).catch(function(){})),a}self.addEventListener("fetch",function(n){var t=n.request,e=new URL(t.url);if(!(t.method!=="GET"||t.headers.has("Authorization")||(t.headers.get("Accept")||"").includes("text/event-stream")||e.origin!==self.location.origin)){if(e.pathname.startsWith("/assets/")&&/-[a-zA-Z0-9_-]{8,}\.[^/]+$/.test(e.pathname)){n.respondWith(c(t,n));return}t.mode==="navigate"&&(t.destination==="document"||!t.destination)&&n.respondWith(fetch(t).catch(function(){return new Response('<!doctype html><html lang="en"><meta charset="utf-8"><meta name="viewport" content="width=device-width,initial-scale=1"><title>Qwen Code unavailable</title><body><h1>Cannot reach Qwen Code / <span lang="zh-CN">无法连接 Qwen Code</span></h1><p>Reconnect to the daemon, then reload this page. / <span lang="zh-CN">请重新连接守护进程,然后重新加载此页面。</span></p><a href="" onclick="location.reload();return false">Try again / <span lang="zh-CN">重试</span></a></body></html>',{status:503,headers:{"Content-Type":"text/html; charset=utf-8","Cache-Control":"no-store"}})}))}});
@@ -5351,6 +5351,13 @@ Write the explanation as a self-contained single-file HTML (inline CSS, no exter
5351
5351
  "tasks.pill.shells": (e) => `${e?.count ?? 0} shells`,
5352
5352
  "tasks.pill.workflow": (e) => `${e?.count ?? 0} workflow`,
5353
5353
  "tasks.pill.workflows": (e) => `${e?.count ?? 0} workflows`,
5354
+ "tasks.explain.tooltip": "Explain what this task is doing",
5355
+ "tasks.explain.aria": (e) => `Explain task: ${e?.label ?? ""}`,
5356
+ "tasks.explain.display": (e) => `Explain what this task is doing: ${e?.label ?? ""}`,
5357
+ "tasks.explain.question": (e) => `This session has a background task. Using the conversation context and the task facts below, explain what this task is doing and why it was started. Answer concisely in 2-4 sentences.
5358
+
5359
+ Task facts:
5360
+ ${e?.facts ?? ""}`,
5354
5361
  "tasks.confirmStop": "x again to confirm stop · ends the blocking turn",
5355
5362
  "tasks.shortcut.select": "↑/↓ select",
5356
5363
  "tasks.shortcut.view": "Enter view",
@@ -9739,6 +9746,13 @@ ${e.url}` : ""}
9739
9746
  "tasks.pill.shells": (e) => `${e?.count ?? 0} 个 shell`,
9740
9747
  "tasks.pill.workflow": (e) => `${e?.count ?? 0} 个工作流`,
9741
9748
  "tasks.pill.workflows": (e) => `${e?.count ?? 0} 个工作流`,
9749
+ "tasks.explain.tooltip": "解释这个任务在做什么",
9750
+ "tasks.explain.aria": (e) => `解释任务:${e?.label ?? ""}`,
9751
+ "tasks.explain.display": (e) => `解释这个任务在做什么:${e?.label ?? ""}`,
9752
+ "tasks.explain.question": (e) => `这个会话有一个后台任务。请结合对话上下文和下面的任务信息,解释这个任务在做什么、为什么启动它。用 2-4 句话简要回答。
9753
+
9754
+ 任务信息:
9755
+ ${e?.facts ?? ""}`,
9742
9756
  "tasks.confirmStop": "再按 x 确认停止 · 会终结当前阻塞轮次",
9743
9757
  "tasks.shortcut.select": "↑/↓ 选择",
9744
9758
  "tasks.shortcut.view": "Enter 查看",
@@ -35054,37 +35068,39 @@ const Sq = rn(function({
35054
35068
  }, Pq = rn(function({
35055
35069
  question: t,
35056
35070
  answer: n,
35057
- isPending: o
35071
+ isPending: o,
35072
+ hidePrefix: s = !1,
35073
+ hideShortcuts: r = !1
35058
35074
  }) {
35059
- const { t: s } = Ne(), r = E(null), a = E(null), l = E(!0), c = he(() => {
35060
- const d = r.current;
35061
- d && l.current && (d.scrollTop = d.scrollHeight);
35075
+ const { t: a } = Ne(), l = E(null), c = E(null), d = E(!0), u = he(() => {
35076
+ const p = l.current;
35077
+ p && d.current && (p.scrollTop = p.scrollHeight);
35062
35078
  }, []);
35063
- return wt(c, [n, o, c]), ce(() => {
35079
+ return wt(u, [n, o, u]), ce(() => {
35064
35080
  if (typeof ResizeObserver > "u") return;
35065
- const d = new ResizeObserver(c);
35066
- return r.current && d.observe(r.current), a.current && d.observe(a.current), () => d.disconnect();
35067
- }, [c]), /* @__PURE__ */ g("div", { className: Is.message, children: [
35081
+ const p = new ResizeObserver(u);
35082
+ return l.current && p.observe(l.current), c.current && p.observe(c.current), () => p.disconnect();
35083
+ }, [u]), /* @__PURE__ */ g("div", { className: Is.message, children: [
35068
35084
  /* @__PURE__ */ g(
35069
35085
  "div",
35070
35086
  {
35071
- ref: r,
35087
+ ref: l,
35072
35088
  className: Is.content,
35073
35089
  "data-web-shell-btw-content": !0,
35074
- onScroll: (d) => {
35075
- const u = d.currentTarget;
35076
- l.current = u.scrollHeight - u.clientHeight - u.scrollTop <= 2;
35090
+ onScroll: (p) => {
35091
+ const m = p.currentTarget;
35092
+ d.current = m.scrollHeight - m.clientHeight - m.scrollTop <= 2;
35077
35093
  },
35078
35094
  children: [
35079
35095
  /* @__PURE__ */ g("div", { className: Is.question, children: [
35080
- /* @__PURE__ */ i("span", { className: Is.prefix, children: "/btw " }),
35096
+ !s && /* @__PURE__ */ i("span", { className: Is.prefix, children: "/btw " }),
35081
35097
  /* @__PURE__ */ i("span", { children: t })
35082
35098
  ] }),
35083
- /* @__PURE__ */ i("div", { ref: a, className: Is.answer, children: o && !n ? /* @__PURE__ */ i("span", { className: Is.pending, children: s("btw.answering") }) : /* @__PURE__ */ i(mo, { content: n }) })
35099
+ /* @__PURE__ */ i("div", { ref: c, className: Is.answer, children: o && !n ? /* @__PURE__ */ i("span", { className: Is.pending, children: a("btw.answering") }) : /* @__PURE__ */ i(mo, { content: n }) })
35084
35100
  ]
35085
35101
  }
35086
35102
  ),
35087
- /* @__PURE__ */ i("div", { className: Is.shortcuts, children: s(o ? "btw.shortcuts.pending" : "btw.shortcuts.done") })
35103
+ !r && /* @__PURE__ */ i("div", { className: Is.shortcuts, children: a(o ? "btw.shortcuts.pending" : "btw.shortcuts.done") })
35088
35104
  ] });
35089
35105
  }), Mq = "_message_1g0wi_1", Lq = "_header_1g0wi_21", Dq = "_status_1g0wi_30", Oq = "_name_1g0wi_35", Fq = "_command_1g0wi_42", Uq = "_output_1g0wi_51", hr = {
35090
35106
  message: Mq,
@@ -218,6 +218,9 @@ export interface DaemonBtwMessage extends DaemonMessageMeta {
218
218
  question: string;
219
219
  answer: string;
220
220
  isPending: boolean;
221
+ /** Set when the question explains a background task, so the task's detail
222
+ * panel can mirror the answer in place. Absent for typed /btw. */
223
+ taskId?: string;
221
224
  }
222
225
  export interface DaemonInsightProgressMessage extends DaemonMessageMeta {
223
226
  id: string;
@@ -0,0 +1,3 @@
1
+ import type { ChatCapabilities } from './contract.js';
2
+ export type ChatRegion = keyof ChatCapabilities;
3
+ export declare function regionsToCapabilities(regions: Iterable<ChatRegion>): ChatCapabilities;
@@ -0,0 +1,106 @@
1
+ import type { Message } from '../adapters/types.js';
2
+ import type { PromptFile, PromptImage } from '../adapters/promptTypes.js';
3
+ import type { ComposerSubmitMetadata } from '../hooks/useComposerCore.js';
4
+ export type Admission = 'accepted' | 'rejected' | 'unknown';
5
+ export type Outcome = 'established' | 'unsettled' | 'failed';
6
+ export interface IntentTarget {
7
+ readonly sessionId: string;
8
+ readonly turnId?: string;
9
+ readonly attemptId?: string;
10
+ readonly requestId?: string;
11
+ }
12
+ export interface IntentResult {
13
+ readonly admission: Admission;
14
+ readonly outcome?: Outcome;
15
+ readonly target: IntentTarget;
16
+ }
17
+ export type OperationState = 'pending' | 'running' | 'established' | 'unsettled' | 'failed';
18
+ export type IntentKind = 'submit' | 'cancel' | 'approval' | 'question' | 'compression' | 'lifecycle' | 'mcp';
19
+ export interface ChatOperation {
20
+ readonly id: string;
21
+ readonly kind: IntentKind;
22
+ readonly state: OperationState;
23
+ readonly target: IntentTarget;
24
+ }
25
+ export type ChatPhase = 'idle' | 'submitting' | 'running' | 'cancelling' | 'failed';
26
+ export interface PendingApproval {
27
+ readonly id: string;
28
+ readonly status: 'pending' | 'superseded';
29
+ }
30
+ export interface PendingQuestion {
31
+ readonly id: string;
32
+ }
33
+ export interface QuestionAnswer {
34
+ readonly questionId: string;
35
+ readonly value: string;
36
+ }
37
+ export interface ComposerSubmit {
38
+ readonly text: string;
39
+ readonly images?: readonly PromptImage[];
40
+ readonly files?: readonly PromptFile[];
41
+ readonly metadata?: ComposerSubmitMetadata;
42
+ }
43
+ export interface ModelSelectionController {
44
+ readonly models: readonly {
45
+ modelId: string;
46
+ label: string;
47
+ }[];
48
+ readonly selectedModelId?: string;
49
+ select(modelId: string): Promise<IntentResult>;
50
+ }
51
+ export interface ApprovalSelectionController {
52
+ readonly mode: string;
53
+ readonly availableModes: readonly string[];
54
+ select(mode: string): Promise<IntentResult>;
55
+ }
56
+ export interface ContextUsageController {
57
+ readonly usageKnown: boolean;
58
+ readonly inputTokens?: number;
59
+ readonly contextWindowSize?: number;
60
+ compress(): Promise<IntentResult>;
61
+ }
62
+ export type SessionLifecycleAction = 'close' | 'archive' | 'unarchive' | 'delete';
63
+ export interface SessionOpsController {
64
+ rename(title: string): Promise<IntentResult>;
65
+ export?(): Promise<IntentResult>;
66
+ lifecycle?(action: SessionLifecycleAction): Promise<IntentResult>;
67
+ }
68
+ export interface ChatCapabilities {
69
+ readonly contextUsage: boolean;
70
+ readonly usageStats: boolean;
71
+ readonly modelSelection: boolean;
72
+ readonly approvalSelection: boolean;
73
+ readonly sessionOps: boolean;
74
+ readonly conversationSearch: boolean;
75
+ readonly goalDisplay: boolean;
76
+ readonly terminal: boolean;
77
+ readonly tasks: boolean;
78
+ readonly diagnostics: boolean;
79
+ readonly artifacts: boolean;
80
+ }
81
+ export interface ChatStatusFacts {
82
+ readonly queueLength: number;
83
+ readonly goalActive: boolean;
84
+ }
85
+ export interface SessionChatController {
86
+ readonly kind: 'daemon' | 'managed';
87
+ readonly sessionId: string;
88
+ readonly storageKey: string;
89
+ readonly operations: readonly ChatOperation[];
90
+ readonly messages: readonly Message[];
91
+ readonly transcriptState: 'loading' | 'ready' | 'error';
92
+ loadOlder?(): Promise<void>;
93
+ readonly phase: ChatPhase;
94
+ submit(input: ComposerSubmit): Promise<IntentResult>;
95
+ cancel(): Promise<IntentResult>;
96
+ readonly pendingApprovals: readonly PendingApproval[];
97
+ readonly pendingQuestions: readonly PendingQuestion[];
98
+ respondApproval(id: string, optionId: string): Promise<IntentResult>;
99
+ respondQuestion(id: string, answers: readonly QuestionAnswer[]): Promise<IntentResult>;
100
+ readonly modelSelection?: ModelSelectionController;
101
+ readonly approvalSelection?: ApprovalSelectionController;
102
+ readonly contextUsage?: ContextUsageController;
103
+ readonly sessionOps?: SessionOpsController;
104
+ readonly statusFacts: ChatStatusFacts;
105
+ readonly capabilities: ChatCapabilities;
106
+ }
@@ -0,0 +1,8 @@
1
+ import type { Admission, ChatOperation, ChatPhase, IntentResult, IntentTarget, OperationState } from './contract.js';
2
+ export type OutcomeWitness = 'settled' | 'failed' | 'none';
3
+ export declare function resolveOutcome(admission: Admission, witness: OutcomeWitness): IntentResult['outcome'];
4
+ export declare function resolveIntent(admission: Admission, witness: OutcomeWitness, target: IntentTarget): IntentResult;
5
+ export declare function isTerminalOperation(state: OperationState): boolean;
6
+ export declare function retainOperations(operations: readonly ChatOperation[]): ChatOperation[];
7
+ export declare function acknowledgeOperation(operations: readonly ChatOperation[], operationId: string): ChatOperation[];
8
+ export declare function deriveChatPhase(operations: readonly ChatOperation[], settled: 'idle' | 'failed'): ChatPhase;
@@ -9,6 +9,8 @@ export interface ComposerTaskChipsProps {
9
9
  includeAgents: boolean;
10
10
  /** Open the task: locate a workflow in the transcript, open a shell's output, … */
11
11
  onSelectTask: (task: DaemonSessionTaskWithWorkflowStatus) => void;
12
+ /** Ask the model to explain the task as a side question, without opening it. */
13
+ onExplainTask?: (task: DaemonSessionTaskWithWorkflowStatus) => void;
12
14
  /** Hand focus back to the composer, optionally with a typed character. */
13
15
  onReturnToInput?: (text?: string) => void;
14
16
  }
@@ -1,4 +1,4 @@
1
- import type { DaemonSessionArtifact, SessionSource, DaemonSessionMonitorTaskStatus, DaemonSessionShellTaskStatus, DaemonSessionTaskStatus } from '@qwen-code/sdk/daemon';
1
+ import type { DaemonSessionArtifact, SessionSource, DaemonSessionMonitorTaskStatus, DaemonSessionShellTaskStatus, DaemonSessionTaskStatus, DaemonSessionTaskWithWorkflowStatus } from '@qwen-code/sdk/daemon';
2
2
  import type { ACPToolCall, TodoItem } from '../../adapters/types';
3
3
  import type { WebShellRightPanelItem } from '../../customization';
4
4
  import { type DaemonContextMemoryDetail, type DaemonSessionOwnerSnapshot, type DaemonSessionActions } from '@qwen-code/web-shell/daemon-react-sdk';
@@ -264,6 +264,17 @@ interface ArtifactPanelProps {
264
264
  onNestedArtifactsChange?: (sessionId: string, artifacts: readonly DaemonSessionArtifact[]) => void;
265
265
  onOpenNestedSubagent?: (tool: ACPToolCall, sessionId: string, workspaceCwd?: string) => void;
266
266
  agentTasks?: readonly EnvironmentAgentTask[];
267
+ /** The background task shown in the active tab, when it can be explained. */
268
+ explainTask?: DaemonSessionTaskWithWorkflowStatus | null;
269
+ onExplainTask?: (task: DaemonSessionTaskWithWorkflowStatus) => void;
270
+ /** A pending/settled task explanation to mirror in place (taskId-matched). */
271
+ taskExplanation?: {
272
+ messageId: string;
273
+ taskId: string;
274
+ question: string;
275
+ answer: string;
276
+ isPending: boolean;
277
+ } | null;
267
278
  agentTraceLoading?: boolean;
268
279
  agentTraceError?: string;
269
280
  onOpenWorkflowAgent?: (task: EnvironmentAgentTask) => void;
@@ -293,5 +304,5 @@ interface ArtifactPanelProps {
293
304
  fullscreen?: boolean;
294
305
  onToggleFullscreen?: () => void;
295
306
  }
296
- export declare function ArtifactPanel({ contextUsageControls, artifacts, tabs, activeTabId, reviewChanges, selectedReviewPath, panelWidth, workspaceCwd, loading, restoring, error, onSelectTab, onSelectTurnCallsPrompt, onCloseTab, onOpenFilePreview, onOpenMemoryFile, latestReviewAvailable, onOpenLatestReview, changeOverviewAvailable, onOpenChangeOverview, onOpenTerminal, onOpenTrajectory, trajectoryTabId, onOpenFiles, onReferenceFile, onOpenWebPreview, onWebPreviewChange, items, sideTaskAvailable, sideTasks, archivedSideTasks, sideTasksLoading, onCreateSideTask, onOpenSideTask, onArchiveSideTasks, onUnarchiveSideTasks, onSideTaskMenuOpen, onCreateSideTaskSession, onSideTaskCreated, onSideTaskTitleChange, onSideTaskInitialPromptRefused, onNestedRightPanelOpen, onNestedArtifactsChange, onOpenNestedSubagent, agentTasks, agentTraceLoading, agentTraceError, onOpenWorkflowAgent, onError, sessionWorkflowEnabled, modelManagement, unavailableModels, mountUnavailableModelTooltip, workflow, onImageIngestionNotice, deferSubagentMount, onClose, variant, fullscreen, onToggleFullscreen, }: ArtifactPanelProps): import("react/jsx-runtime").JSX.Element;
307
+ export declare function ArtifactPanel({ contextUsageControls, artifacts, tabs, activeTabId, reviewChanges, selectedReviewPath, panelWidth, workspaceCwd, loading, restoring, error, onSelectTab, onSelectTurnCallsPrompt, onCloseTab, onOpenFilePreview, onOpenMemoryFile, latestReviewAvailable, onOpenLatestReview, changeOverviewAvailable, onOpenChangeOverview, onOpenTerminal, onOpenTrajectory, trajectoryTabId, onOpenFiles, onReferenceFile, onOpenWebPreview, onWebPreviewChange, items, sideTaskAvailable, sideTasks, archivedSideTasks, sideTasksLoading, onCreateSideTask, onOpenSideTask, onArchiveSideTasks, onUnarchiveSideTasks, onSideTaskMenuOpen, onCreateSideTaskSession, onSideTaskCreated, onSideTaskTitleChange, onSideTaskInitialPromptRefused, onNestedRightPanelOpen, onNestedArtifactsChange, onOpenNestedSubagent, agentTasks, explainTask, onExplainTask, taskExplanation, agentTraceLoading, agentTraceError, onOpenWorkflowAgent, onError, sessionWorkflowEnabled, modelManagement, unavailableModels, mountUnavailableModelTooltip, workflow, onImageIngestionNotice, deferSubagentMount, onClose, variant, fullscreen, onToggleFullscreen, }: ArtifactPanelProps): import("react/jsx-runtime").JSX.Element;
297
308
  export {};
@@ -0,0 +1,5 @@
1
+ import type { ManagedAgentSessionSummary } from './managed-agent-provider.js';
2
+ import type { ChatRegion } from '../../chat-core/capabilities.js';
3
+ export type ManagedCapabilityKey = keyof ManagedAgentSessionSummary['capabilities'];
4
+ export declare const MANAGED_CHAT_CAPABILITY_MAP: Record<ManagedCapabilityKey, readonly ChatRegion[]>;
5
+ export declare function isManagedCapabilityOn(value: boolean | null | undefined): boolean;
@@ -2,6 +2,12 @@ interface BtwMessageProps {
2
2
  question: string;
3
3
  answer: string;
4
4
  isPending: boolean;
5
+ /** Task explanations are button-triggered, not a typed /btw command. */
6
+ hidePrefix?: boolean;
7
+ /** The detail-panel mirror has no focusable surface of its own, so the
8
+ * composer panel's key hints would advertise keys that act on whatever
9
+ * control holds focus (Enter on the header "?" re-asks). */
10
+ hideShortcuts?: boolean;
5
11
  }
6
12
  export declare const BtwMessage: import("react").NamedExoticComponent<BtwMessageProps>;
7
13
  export {};
@@ -0,0 +1,3 @@
1
+ import type { ServeFeature } from '@qwen-code/sdk/daemon';
2
+ import type { ChatRegion } from '../chat-core/capabilities.js';
3
+ export declare const DAEMON_CHAT_CAPABILITY_MAP: Record<ServeFeature, readonly ChatRegion[]>;
@@ -28,3 +28,13 @@ export interface ComposerTaskChipGroup {
28
28
  export declare function getComposerTaskChipGroups(tasks: readonly DaemonSessionTaskWithWorkflowStatus[], options: {
29
29
  includeAgents: boolean;
30
30
  }): ComposerTaskChipGroup[];
31
+ export declare function explainDisplayLabel(label: string): string;
32
+ /**
33
+ * Compose the side question the composer's "?" affordance asks about a
34
+ * background task. The facts come from the client's task snapshot; the
35
+ * forked side-question agent adds the conversation context the snapshot
36
+ * cannot carry (why the task was started). Fact labels stay English — they
37
+ * are model input, not UI text — while the instruction follows the UI
38
+ * language so the answer does too.
39
+ */
40
+ export declare function buildTaskExplainQuestion(task: DaemonSessionTaskWithWorkflowStatus, t: (key: string, vars?: Record<string, string | number>) => string): string;
@@ -15403,6 +15403,13 @@ Write the explanation as a self-contained single-file HTML (inline CSS, no exter
15403
15403
  "tasks.pill.shells": (e) => `${e?.count ?? 0} shells`,
15404
15404
  "tasks.pill.workflow": (e) => `${e?.count ?? 0} workflow`,
15405
15405
  "tasks.pill.workflows": (e) => `${e?.count ?? 0} workflows`,
15406
+ "tasks.explain.tooltip": "Explain what this task is doing",
15407
+ "tasks.explain.aria": (e) => `Explain task: ${e?.label ?? ""}`,
15408
+ "tasks.explain.display": (e) => `Explain what this task is doing: ${e?.label ?? ""}`,
15409
+ "tasks.explain.question": (e) => `This session has a background task. Using the conversation context and the task facts below, explain what this task is doing and why it was started. Answer concisely in 2-4 sentences.
15410
+
15411
+ Task facts:
15412
+ ${e?.facts ?? ""}`,
15406
15413
  "tasks.confirmStop": "x again to confirm stop · ends the blocking turn",
15407
15414
  "tasks.shortcut.select": "↑/↓ select",
15408
15415
  "tasks.shortcut.view": "Enter view",
@@ -19791,6 +19798,13 @@ ${e.url}` : ""}
19791
19798
  "tasks.pill.shells": (e) => `${e?.count ?? 0} 个 shell`,
19792
19799
  "tasks.pill.workflow": (e) => `${e?.count ?? 0} 个工作流`,
19793
19800
  "tasks.pill.workflows": (e) => `${e?.count ?? 0} 个工作流`,
19801
+ "tasks.explain.tooltip": "解释这个任务在做什么",
19802
+ "tasks.explain.aria": (e) => `解释任务:${e?.label ?? ""}`,
19803
+ "tasks.explain.display": (e) => `解释这个任务在做什么:${e?.label ?? ""}`,
19804
+ "tasks.explain.question": (e) => `这个会话有一个后台任务。请结合对话上下文和下面的任务信息,解释这个任务在做什么、为什么启动它。用 2-4 句话简要回答。
19805
+
19806
+ 任务信息:
19807
+ ${e?.facts ?? ""}`,
19794
19808
  "tasks.confirmStop": "再按 x 确认停止 · 会终结当前阻塞轮次",
19795
19809
  "tasks.shortcut.select": "↑/↓ 选择",
19796
19810
  "tasks.shortcut.view": "Enter 查看",
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@qwen-code/web-shell",
3
- "version": "0.28.0",
3
+ "version": "0.28.1-preview.0",
4
4
  "repository": {
5
5
  "type": "git",
6
6
  "url": "git+https://github.com/QwenLM/qwen-code.git",