@xmanrui/dsh-im 5.10.0 → 5.11.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/README.en.md +39 -5
- package/README.md +42 -5
- package/bin/dsh-im.mjs +65 -0
- package/docs/client-integration.md +4 -0
- package/lib/client.js +1202 -95
- package/lib/index.js +365 -339
- package/package.json +7 -6
- package/plugin-src/client/access-policy-settings.js +210 -12
- package/plugin-src/client/bot-general-settings.js +44 -3
- package/plugin-src/client/i18n-ru.js +85 -0
- package/plugin-src/client/i18n.js +83 -0
- package/plugin-src/client/im-channels.js +419 -0
- package/plugin-src/client/index.js +33 -1
- package/plugin-src/client/styles.js +7 -7
- package/plugin-src/client/update-panel.js +2 -1
- package/plugin-src/host/channel-list-rpc.mjs +280 -0
- package/plugin-src/host/channels/dingtalk/production.mjs +28 -10
- package/plugin-src/host/channels/dingtalk/rpc.mjs +10 -1
- package/plugin-src/host/channels/feishu/production.mjs +39 -10
- package/plugin-src/host/channels/feishu/rpc.mjs +10 -1
- package/plugin-src/host/channels/matrix/production.mjs +28 -10
- package/plugin-src/host/channels/matrix/rpc.mjs +10 -0
- package/plugin-src/host/channels/qq/production.mjs +30 -11
- package/plugin-src/host/channels/qq/rpc.mjs +10 -1
- package/plugin-src/host/channels/shared/access-policy-production.mjs +9 -0
- package/plugin-src/host/channels/shared/binding-events.mjs +109 -0
- package/plugin-src/host/channels/shared/production.mjs +14 -1
- package/plugin-src/host/channels/shared/reply-content-rpc.mjs +17 -0
- package/plugin-src/host/channels/shared/rpc.mjs +9 -0
- package/plugin-src/host/channels/slack/production.mjs +28 -10
- package/plugin-src/host/channels/slack/rpc.mjs +10 -0
- package/plugin-src/host/channels/telegram/production.mjs +5 -0
- package/plugin-src/host/channels/wecom/production.mjs +28 -10
- package/plugin-src/host/channels/wecom/rpc.mjs +10 -1
- package/plugin-src/host/channels/wecom-app/production.mjs +28 -10
- package/plugin-src/host/channels/wecom-app/rpc.mjs +9 -0
- package/plugin-src/host/channels/weixin/production.mjs +28 -10
- package/plugin-src/host/channels/weixin/rpc.mjs +10 -1
- package/plugin-src/host/channels/whatsapp/production.mjs +28 -10
- package/plugin-src/host/channels/whatsapp/rpc.mjs +10 -1
- package/plugin-src/host/delivery-service.mjs +3 -4
- package/plugin-src/host/delivery-suggestions.mjs +3 -1
- package/plugin-src/host/harness-connection.mjs +2 -1
- package/plugin-src/host/harness-peer.mjs +3 -1
- package/plugin-src/host/index.mjs +8 -1
- package/plugin-src/host/modern-harness-api.mjs +5 -1
- package/plugin-src/host/root-scope.mjs +32 -0
- package/plugin-src/host/session-sync-coordinator.mjs +2 -1
- package/plugin-src/management-rpc.mjs +18 -2
- package/scripts/verify-package.mjs +36 -7
- package/src/channels/dingtalk/dingtalk-bridge.mjs +50 -6
- package/src/channels/dingtalk/state-store.mjs +56 -0
- package/src/channels/discord/discord-api.mjs +2 -1
- package/src/channels/feishu/bridge.mjs +154 -58
- package/src/channels/feishu/feishu-cards.mjs +10 -4
- package/src/channels/feishu/feishu-runtime.mjs +11 -3
- package/src/channels/feishu/message-utils.mjs +106 -30
- package/src/channels/feishu/slash-command-panel.mjs +26 -0
- package/src/channels/feishu/state-store.mjs +14 -0
- package/src/channels/matrix/matrix-api.mjs +2 -1
- package/src/channels/qq/qq-bridge.mjs +105 -14
- package/src/channels/qq/state-store.mjs +13 -1
- package/src/channels/shared/access-policy.mjs +60 -7
- package/src/channels/shared/bot-workspace-store.mjs +155 -3
- package/src/channels/shared/busy-message-dispatcher.mjs +2 -2
- package/src/channels/shared/channel-capabilities.mjs +44 -0
- package/src/channels/shared/command-catalog.mjs +68 -3
- package/src/channels/shared/command-permission.mjs +6 -2
- package/src/channels/shared/conversation-state-store.mjs +16 -0
- package/src/channels/shared/deferred-delivery-coordinator.mjs +6 -1
- package/src/channels/shared/deferred-delivery.mjs +4 -0
- package/src/channels/shared/diagnostic-details.mjs +6 -1
- package/src/channels/shared/failure-log-file.mjs +79 -0
- package/src/channels/shared/harness-client.mjs +111 -6
- package/src/channels/shared/i18n-en/feishu.mjs +2 -2
- package/src/channels/shared/i18n-en/shared-a.mjs +13 -2
- package/src/channels/shared/i18n-en/shared-b.mjs +67 -4
- package/src/channels/shared/i18n-en/shared-d.mjs +144 -0
- package/src/channels/shared/i18n-en/weixin.mjs +4 -0
- package/src/channels/shared/i18n-en.mjs +2 -0
- package/src/channels/shared/i18n-ru/feishu.mjs +2 -2
- package/src/channels/shared/i18n-ru/shared-a.mjs +13 -2
- package/src/channels/shared/i18n-ru/shared-b.mjs +67 -4
- package/src/channels/shared/i18n-ru/shared-d.mjs +144 -0
- package/src/channels/shared/i18n-ru/weixin.mjs +4 -0
- package/src/channels/shared/i18n-ru.mjs +2 -0
- package/src/channels/shared/inbound-access.mjs +10 -0
- package/src/channels/shared/markdown-chunks.mjs +5 -0
- package/src/channels/shared/message-failure.mjs +22 -1
- package/src/channels/shared/new-command.mjs +158 -4
- package/src/channels/shared/plan-goal-command.mjs +132 -0
- package/src/channels/shared/qrcode.mjs +5 -0
- package/src/channels/shared/reply-content.mjs +102 -0
- package/src/channels/shared/reset-command.mjs +46 -0
- package/src/channels/shared/semantic/artifact.mjs +133 -29
- package/src/channels/shared/semantic/reply-reference.mjs +18 -3
- package/src/channels/shared/session-nav-command.mjs +999 -0
- package/src/channels/shared/session-ring-support.mjs +184 -0
- package/src/channels/shared/session-ring.mjs +202 -0
- package/src/channels/shared/session-title.mjs +11 -0
- package/src/channels/shared/status-command.mjs +2 -1
- package/src/channels/shared/text-harness-bridge.mjs +166 -7
- package/src/channels/shared/workspace-command.mjs +567 -31
- package/src/channels/shared/workspace-session.mjs +39 -3
- package/src/channels/slack/slack-api.mjs +2 -1
- package/src/channels/telegram/config-store.mjs +10 -2
- package/src/channels/telegram/telegram-rich-message.mjs +17 -5
- package/src/channels/telegram/telegram-runtime.mjs +14 -1
- package/src/channels/wecom/state-store.mjs +13 -1
- package/src/channels/wecom/wecom-bridge.mjs +183 -26
- package/src/channels/wecom-app/state-store.mjs +13 -1
- package/src/channels/wecom-app/wecom-app-bridge.mjs +44 -4
- package/src/channels/weixin/state-store.mjs +13 -1
- package/src/channels/weixin/weixin-bridge.mjs +71 -4
|
@@ -0,0 +1,79 @@
|
|
|
1
|
+
import { appendFileSync, mkdirSync, renameSync, statSync } from 'node:fs';
|
|
2
|
+
import { homedir } from 'node:os';
|
|
3
|
+
import { dirname, join } from 'node:path';
|
|
4
|
+
|
|
5
|
+
/**
|
|
6
|
+
* One durable line per failed turn, so the reference id a user quotes back can
|
|
7
|
+
* be looked up after the fact.
|
|
8
|
+
*
|
|
9
|
+
* The console line the bridge already writes carries the same id, but a console
|
|
10
|
+
* line only exists while somebody captures stdout (`dsh` started from a
|
|
11
|
+
* terminal, a log collector). For a desktop app started from the dock there is
|
|
12
|
+
* no captured stream at all, so a `MF-…` id in a chat notice had nothing on disk
|
|
13
|
+
* to match it against — the id was, in practice, untraceable. This module keeps
|
|
14
|
+
* that record next to the other `.dsh-im` state.
|
|
15
|
+
*
|
|
16
|
+
* The file is best-effort by design: a failure to log must never mask the
|
|
17
|
+
* failure being reported to the user, so every filesystem error is swallowed.
|
|
18
|
+
*/
|
|
19
|
+
|
|
20
|
+
const LOG_DIRECTORY = '.dsh-im';
|
|
21
|
+
const LOG_NAME = 'failures.jsonl';
|
|
22
|
+
/** Keep one previous generation; a chatty week must not grow the file forever. */
|
|
23
|
+
const MAX_LOG_BYTES = 2 * 1024 * 1024;
|
|
24
|
+
const TOKEN_SHAPE = /bot\d+:[A-Za-z0-9_-]{20,}/gu;
|
|
25
|
+
|
|
26
|
+
function resolveDshHome(dshHome) {
|
|
27
|
+
return dshHome ?? process.env.DSH_HOME ?? join(homedir(), '.dsh');
|
|
28
|
+
}
|
|
29
|
+
|
|
30
|
+
/** Absolute path of the failure log for one DSH home. */
|
|
31
|
+
export function failureLogPath({ dshHome } = {}) {
|
|
32
|
+
return join(resolveDshHome(dshHome), LOG_DIRECTORY, LOG_NAME);
|
|
33
|
+
}
|
|
34
|
+
|
|
35
|
+
function rotateIfNeeded(file) {
|
|
36
|
+
try {
|
|
37
|
+
if (statSync(file).size < MAX_LOG_BYTES) return;
|
|
38
|
+
renameSync(file, `${file}.1`);
|
|
39
|
+
} catch {
|
|
40
|
+
// Missing file, or a race with another writer: appending still works.
|
|
41
|
+
}
|
|
42
|
+
}
|
|
43
|
+
|
|
44
|
+
/**
|
|
45
|
+
* Append one classified failure to the durable log.
|
|
46
|
+
*
|
|
47
|
+
* @param {object} failure - the object `classifyMessageFailure` returned.
|
|
48
|
+
* @param {object} [options]
|
|
49
|
+
* @param {string|null} [options.channel] - channel key, e.g. `feishu`.
|
|
50
|
+
* @param {string} [options.dshHome] - overrides `DSH_HOME`.
|
|
51
|
+
* @param {object|null} [options.details] - classified diagnostic details.
|
|
52
|
+
* @param {number} [options.at] - event time in epoch milliseconds.
|
|
53
|
+
* @returns {boolean} true when the line reached the file.
|
|
54
|
+
*/
|
|
55
|
+
export function appendFailureLog(failure, { channel = null, dshHome, details = null, at = Date.now() } = {}) {
|
|
56
|
+
if (!failure || typeof failure !== 'object') return false;
|
|
57
|
+
const referenceId = typeof failure.referenceId === 'string' ? failure.referenceId : '';
|
|
58
|
+
if (!referenceId) return false;
|
|
59
|
+
try {
|
|
60
|
+
const file = failureLogPath({ dshHome });
|
|
61
|
+
mkdirSync(dirname(file), { recursive: true });
|
|
62
|
+
rotateIfNeeded(file);
|
|
63
|
+
const record = {
|
|
64
|
+
referenceId,
|
|
65
|
+
code: failure.code ?? null,
|
|
66
|
+
reason: failure.reason ?? null,
|
|
67
|
+
channel,
|
|
68
|
+
at: Number.isFinite(failure.at) ? failure.at : at,
|
|
69
|
+
// The provider code is what explains a MODEL_STREAM: STREAM_CLOSED versus
|
|
70
|
+
// MALFORMED_RESPONSE. `details` carries it when classification found it.
|
|
71
|
+
...(details && typeof details === 'object' ? { details } : {}),
|
|
72
|
+
};
|
|
73
|
+
const line = JSON.stringify(record).replace(TOKEN_SHAPE, 'bot<redacted>');
|
|
74
|
+
appendFileSync(file, `${line}\n`, { encoding: 'utf8', mode: 0o600 });
|
|
75
|
+
return true;
|
|
76
|
+
} catch {
|
|
77
|
+
return false;
|
|
78
|
+
}
|
|
79
|
+
}
|
|
@@ -25,6 +25,7 @@ import { t } from './i18n.mjs';
|
|
|
25
25
|
import { watchHarnessMux } from './harness-mux.mjs';
|
|
26
26
|
import { extractConnectionEvidence, messageDiagnosticError } from './connection-error.mjs';
|
|
27
27
|
import { PromptFailureTracker } from './prompt-failure-tracker.mjs';
|
|
28
|
+
import { allowsReplyContent, normalizeReplyContent } from './reply-content.mjs';
|
|
28
29
|
import { isSessionLogCorrupt, isSessionNotFound } from './session-error.mjs';
|
|
29
30
|
|
|
30
31
|
// Every channel plugin runs in the same Host process. Sharing ownership by
|
|
@@ -488,6 +489,48 @@ export function accumulateFinalAssistantText(accumulator, event) {
|
|
|
488
489
|
}
|
|
489
490
|
}
|
|
490
491
|
|
|
492
|
+
/**
|
|
493
|
+
* The switch that owns a progress update. Text updates are the assistant's own
|
|
494
|
+
* prose, tool traffic is the step itself, and reasoning is the trace; anything
|
|
495
|
+
* else (turn boundaries) is always delivered because the consumer needs it to
|
|
496
|
+
* end the turn correctly.
|
|
497
|
+
*/
|
|
498
|
+
function replyContentKindOf(update) {
|
|
499
|
+
switch (update?.type) {
|
|
500
|
+
case 'tool':
|
|
501
|
+
case 'tool-result':
|
|
502
|
+
case 'status':
|
|
503
|
+
return 'tools';
|
|
504
|
+
case 'reasoning':
|
|
505
|
+
return 'thinking';
|
|
506
|
+
case 'assistant-message':
|
|
507
|
+
case 'text':
|
|
508
|
+
return 'narration';
|
|
509
|
+
default:
|
|
510
|
+
return null;
|
|
511
|
+
}
|
|
512
|
+
}
|
|
513
|
+
|
|
514
|
+
function allowsUpdate(replyContent, update) {
|
|
515
|
+
const kind = replyContentKindOf(update);
|
|
516
|
+
return kind === null || allowsReplyContent(replyContent, kind);
|
|
517
|
+
}
|
|
518
|
+
|
|
519
|
+
/**
|
|
520
|
+
* The updates a channel may forward for this batch.
|
|
521
|
+
*
|
|
522
|
+
* The bot's switches are applied before the `latest` reduction: a hidden
|
|
523
|
+
* update must not take the single slot and swallow an allowed update that
|
|
524
|
+
* arrived in the same poll.
|
|
525
|
+
*/
|
|
526
|
+
export function selectProgressUpdates(updates, { mode = 'latest', replyContent } = {}) {
|
|
527
|
+
const allowed = updates.filter((update) => allowsUpdate(replyContent, update));
|
|
528
|
+
if (mode === 'all' || mode === 'live') return allowed;
|
|
529
|
+
return allowed
|
|
530
|
+
.filter((update) => update.type !== 'assistant-message' && update.type !== 'reasoning')
|
|
531
|
+
.slice(-1);
|
|
532
|
+
}
|
|
533
|
+
|
|
491
534
|
function nonEmptyText(value) {
|
|
492
535
|
return typeof value === 'string' && value.trim() ? value.trim() : null;
|
|
493
536
|
}
|
|
@@ -1201,6 +1244,33 @@ export class HarnessClient {
|
|
|
1201
1244
|
return workspaceEntries(await this.rpc('workspace.list', {}, 30_000, options));
|
|
1202
1245
|
}
|
|
1203
1246
|
|
|
1247
|
+
/**
|
|
1248
|
+
* Hide one known Session from the Workspace grouping surfaces. Archiving is a
|
|
1249
|
+
* Harness capability: this only carries the request, so an older Host that
|
|
1250
|
+
* does not expose it fails loudly instead of silently doing nothing.
|
|
1251
|
+
*
|
|
1252
|
+
* @param {string} sessionId - Session to archive.
|
|
1253
|
+
* @param {object} [options] - `stopActivity` lets the Host stop running work.
|
|
1254
|
+
*/
|
|
1255
|
+
async archiveWorkspaceSession(sessionId, options = {}) {
|
|
1256
|
+
const { stopActivity = false, ...rpcOptions } = options;
|
|
1257
|
+
await this.ensureRunning(rpcOptions);
|
|
1258
|
+
const value = await this.rpc('workspace.archiveSession', {
|
|
1259
|
+
sessionId,
|
|
1260
|
+
...(stopActivity === true ? { stopActivity: true } : {}),
|
|
1261
|
+
}, 30_000, rpcOptions);
|
|
1262
|
+
if (value === null || typeof value !== 'object') {
|
|
1263
|
+
throw new Error('Harness returned an invalid response for workspace.archiveSession');
|
|
1264
|
+
}
|
|
1265
|
+
const archivedSessionIds = value.archivedSessionIds;
|
|
1266
|
+
if (archivedSessionIds !== undefined
|
|
1267
|
+
&& (!Array.isArray(archivedSessionIds)
|
|
1268
|
+
|| archivedSessionIds.some((id) => typeof id !== 'string' || !id))) {
|
|
1269
|
+
throw new Error('Harness returned invalid archived ids for workspace.archiveSession');
|
|
1270
|
+
}
|
|
1271
|
+
return { archivedSessionIds: archivedSessionIds ?? null };
|
|
1272
|
+
}
|
|
1273
|
+
|
|
1204
1274
|
async listWorkspaceSessions(workspacePath, options = {}) {
|
|
1205
1275
|
await this.ensureRunning(options);
|
|
1206
1276
|
const workspaceList = await this.rpc('workspace.list', {}, 30_000, options);
|
|
@@ -1405,6 +1475,31 @@ export class HarnessClient {
|
|
|
1405
1475
|
return this.rpc('session.rename', { sessionId, title }, 30_000, options);
|
|
1406
1476
|
}
|
|
1407
1477
|
|
|
1478
|
+
/**
|
|
1479
|
+
* Branch a Session at the latest completed turn (or atSeq when given). The
|
|
1480
|
+
* Host answers with the child session id; a Session with no completed turn is
|
|
1481
|
+
* reported as fork-unavailable. Throws harness-api-not-found when the Host
|
|
1482
|
+
* has no session.fork primitive.
|
|
1483
|
+
*/
|
|
1484
|
+
async forkSession(sessionId, options = {}) {
|
|
1485
|
+
if (typeof sessionId !== 'string' || !sessionId) throw new TypeError('sessionId is required');
|
|
1486
|
+
const { atSeq, timeoutMs = 30_000, ...rpcOptions } = options;
|
|
1487
|
+
return this.rpc('session.fork', {
|
|
1488
|
+
sessionId,
|
|
1489
|
+
...(atSeq === undefined ? {} : { atSeq }),
|
|
1490
|
+
}, timeoutMs, rpcOptions);
|
|
1491
|
+
}
|
|
1492
|
+
|
|
1493
|
+
/**
|
|
1494
|
+
* Whether the connected Host can fork sessions. With the host-api transport
|
|
1495
|
+
* this is the facade's sessions.fork member; the http transport reaches the
|
|
1496
|
+
* Host endpoint directly, so a missing member here is not observable.
|
|
1497
|
+
*/
|
|
1498
|
+
supportsSessionFork() {
|
|
1499
|
+
if (this.#apiProxy) return typeof this.#apiProxy?.sessions?.fork === 'function';
|
|
1500
|
+
return true;
|
|
1501
|
+
}
|
|
1502
|
+
|
|
1408
1503
|
async executeCommand(sessionId, line, options = {}) {
|
|
1409
1504
|
if (typeof sessionId !== 'string' || !sessionId) throw new TypeError('sessionId is required');
|
|
1410
1505
|
if (typeof line !== 'string' || !line) throw new TypeError('command line is required');
|
|
@@ -1947,6 +2042,9 @@ export class HarnessClient {
|
|
|
1947
2042
|
// Reasoning updates only exist for consumers that opt in (thinking-trace
|
|
1948
2043
|
// mode); default ask() consumers keep the pre-thinking-traces stream.
|
|
1949
2044
|
const reasoning = options.reasoning === true;
|
|
2045
|
+
// Per-bot content switches: a bot may hide the assistant's process prose,
|
|
2046
|
+
// its tool traffic or the reasoning trace while still receiving the answer.
|
|
2047
|
+
const replyContent = normalizeReplyContent(options.replyContent);
|
|
1950
2048
|
const onArtifact = typeof options.onArtifact === 'function' ? options.onArtifact : null;
|
|
1951
2049
|
const onInteraction = typeof options.onInteraction === 'function'
|
|
1952
2050
|
? options.onInteraction
|
|
@@ -1970,7 +2068,12 @@ export class HarnessClient {
|
|
|
1970
2068
|
diagnostic.promptRpcId = promptRpcId;
|
|
1971
2069
|
const releasePromptInputOrigin = registerImInputOrigin(this.#interactionRegistry, promptRpcId);
|
|
1972
2070
|
const tracker = new HarnessReplyTracker({
|
|
1973
|
-
promptRpcId,
|
|
2071
|
+
promptRpcId,
|
|
2072
|
+
afterSeq: baselineSeq,
|
|
2073
|
+
reasoning,
|
|
2074
|
+
// Hiding the assistant's process prose also means the delivered answer
|
|
2075
|
+
// must not carry it: keep only the text after the last tool call.
|
|
2076
|
+
finalAnswerOnly: options.finalAnswerOnly === true || replyContent.narration === false,
|
|
1974
2077
|
});
|
|
1975
2078
|
let checkedBlockedSeq = baselineSeq;
|
|
1976
2079
|
let lastProgressAt = Date.now();
|
|
@@ -1985,11 +2088,10 @@ export class HarnessClient {
|
|
|
1985
2088
|
lastPollSeq = tracker.lastSeq;
|
|
1986
2089
|
if (seqAdvanced) lastProgressAt = Date.now();
|
|
1987
2090
|
if (!onUpdate) return progressTail;
|
|
1988
|
-
const visibleUpdates =
|
|
1989
|
-
|
|
1990
|
-
|
|
1991
|
-
|
|
1992
|
-
.slice(-1);
|
|
2091
|
+
const visibleUpdates = selectProgressUpdates(updates, {
|
|
2092
|
+
mode: progressMode,
|
|
2093
|
+
replyContent,
|
|
2094
|
+
});
|
|
1993
2095
|
for (const update of visibleUpdates) {
|
|
1994
2096
|
progressTail = progressTail
|
|
1995
2097
|
.then(() => onUpdate(update))
|
|
@@ -2052,6 +2154,9 @@ export class HarnessClient {
|
|
|
2052
2154
|
return deliveredArtifactCount;
|
|
2053
2155
|
}
|
|
2054
2156
|
artifactsDelivered = true;
|
|
2157
|
+
// Files the host `present` tool recorded live on the Session, not in the
|
|
2158
|
+
// registry: adopt them before claiming, or they are dropped silently.
|
|
2159
|
+
await outboundArtifactRegistry.adoptionsSettled(sessionId, tracker.turn);
|
|
2055
2160
|
const artifacts = outboundArtifactRegistry.take(sessionId, tracker.turn, { signal });
|
|
2056
2161
|
for (const artifact of artifacts) {
|
|
2057
2162
|
try {
|
|
@@ -267,8 +267,8 @@ export default {
|
|
|
267
267
|
'/steer 指令 给 Agent 补充指令': '/steer INSTRUCTION Steer the Agent',
|
|
268
268
|
'**📋 卡片功能**\n\n1. 会话下拉 — 切换当前绑定会话\n2. 工作区下拉 — 切换工作区\n3. 🤖 预设下拉 — 切换 Agent 预设\n4. 🧠 模型下拉 — 切换模型\n5. 🆕 新会话 — 开启全新会话\n6. 📋 会话/关注 — 查看/绑定会话,管理关注\n7. ⏹ 停止 — 停止当前任务\n8. 📐 压缩 — 压缩当前会话上下文\n9. 🧹 清空上下文 — 清空上下文并保留绑定和历史记录\n10. 补充指令 — 给 Agent 发送指令\n11. 🗄 归档切换 — 显示/隐藏归档会话\n12. 📊 状态 — 查看系统连接状态\n13. 📖 帮助 — 查看本帮助':
|
|
269
269
|
'**📋 Card features**\n\n1. Session dropdown — switch the bound session\n2. Workspace dropdown — switch workspace\n3. 🤖 Preset dropdown — switch Agent Preset\n4. 🧠 Model dropdown — switch model\n5. 🆕 New session — start fresh\n6. 📋 Sessions/watches — view or bind sessions and manage watches\n7. ⏹ Stop — stop the current task\n8. 📐 Compact — compact the current session context\n9. 🧹 Clear context — clear context while keeping the binding and history\n10. Steer task — send an instruction to the Agent\n11. 🗄 Archived toggle — show or hide archived sessions\n12. 📊 Status — view connection status\n13. 📖 Help — view this help',
|
|
270
|
-
'**⌨️ 文本命令**\n\n`/m` — 打开菜单卡片\n`/new` — 开启全新会话\n`/session ID
|
|
271
|
-
'**⌨️ Text commands**\n\n`/m` — open the menu card\n`/new` — start a new session\n`/session ID` — bind an existing session\n`/sessionlist [workspace]` or `/sessions [workspace]` — list sessions\n`/sessionlist --limit N` or `/sessions --limit N` — list only the first N sessions in the current workspace\n`/workspace <workspace index or absolute path>` — switch workspace\n`/workspacelist` — list workspaces\n`/status` — view connection status\n`/compact` — compact context\n`/clear` — clear context while keeping the Session binding and history\n`/stop` — stop the current task\n`/steer INSTRUCTION` — steer the task\n`/watch ID` — watch a session\n`/watchlist` — list watched sessions\n`/unwatch ID` — stop watching\n`/archived on/off` — show or hide archived sessions\n`/presetlist` or `/presets` — list presets\n`/preset [index/ID]` — switch preset\n`/preset --default` — follow default\n`/models` — list models\n`/reasoninglist` or `/reasonings` — list reasoning efforts for the current model\n`/reasoning [index, effort ID, or --default]` — show or switch reasoning effort\n`/model [index or full model ID] [reasoning effort ID]` — show or switch the current Session model\n`/batch` — start batch input (direct messages only, up to 10 text messages)\n`/send` — submit the current batch\n`/cancel` — cancel the current batch\n`/repair` — complete Feishu permissions and the card callback',
|
|
270
|
+
'**⌨️ 文本命令**\n\n`/m` — 打开菜单卡片\n`/new` — 开启全新会话\n`/session Session ID、当前工作区序号或标题关键词` — 绑定已有会话\n`/sessionlist [工作区]` 或 `/sessions [工作区]` — 列出会话\n`/sessionlist --all` 或 `/sessions --all` — 跨工作区汇总会话(每个工作区默认显示 10 个,可用 --limit N 调整)\n`/sessionlist --limit N` 或 `/sessions --limit N` — 仅列出当前工作区前 N 个会话\n`/workspace 工作区序号或绝对路径` — 切换工作区\n`/workspacelist` — 列出工作区\n`/status` — 查看连接状态\n`/compact` — 压缩上下文\n`/clear` — 清空上下文并保留 Session 绑定和历史记录\n`/stop` — 停止当前任务\n`/steer 指令` — 补充指令\n`/watch ID` — 关注会话\n`/watchlist` — 关注列表\n`/unwatch ID` — 取消关注\n`/archived on/off` — 归档显隐\n`/presetlist` 或 `/presets` — 列出预设\n`/preset [序号/ID]` — 切换预设\n`/preset --default` — 跟随默认\n`/models` — 列出模型\n`/reasoninglist` 或 `/reasonings` — 按序号列出当前模型可用推理等级\n`/reasoning [序号、等级ID或 --default]` — 查看或切换当前推理等级\n`/model [序号或完整模型ID] [推理等级ID]` — 查看或切换当前会话模型\n`/batch` — 开启批量输入(仅私聊,最多 10 条文字)\n`/send` — 提交当前批次\n`/cancel` — 取消当前批次\n`/repair` — 补全飞书权限与卡片回调':
|
|
271
|
+
'**⌨️ Text commands**\n\n`/m` — open the menu card\n`/new` — start a new session\n`/session Session ID, current workspace index, or title keyword` — bind an existing session\n`/sessionlist [workspace]` or `/sessions [workspace]` — list sessions\n`/sessionlist --all` or `/sessions --all` — summarize sessions across workspaces (10 per workspace by default; use --limit N to change)\n`/sessionlist --limit N` or `/sessions --limit N` — list only the first N sessions in the current workspace\n`/workspace <workspace index or absolute path>` — switch workspace\n`/workspacelist` — list workspaces\n`/status` — view connection status\n`/compact` — compact context\n`/clear` — clear context while keeping the Session binding and history\n`/stop` — stop the current task\n`/steer INSTRUCTION` — steer the task\n`/watch ID` — watch a session\n`/watchlist` — list watched sessions\n`/unwatch ID` — stop watching\n`/archived on/off` — show or hide archived sessions\n`/presetlist` or `/presets` — list presets\n`/preset [index/ID]` — switch preset\n`/preset --default` — follow default\n`/models` — list models\n`/reasoninglist` or `/reasonings` — list reasoning efforts for the current model\n`/reasoning [index, effort ID, or --default]` — show or switch reasoning effort\n`/model [index or full model ID] [reasoning effort ID]` — show or switch the current Session model\n`/batch` — start batch input (direct messages only, up to 10 text messages)\n`/send` — submit the current batch\n`/cancel` — cancel the current batch\n`/repair` — complete Feishu permissions and the card callback',
|
|
272
272
|
'**💡 数字兜底**\n回复数字快速操作:\n**1**工作区列表 · **2**新会话 · **3**会话/关注\n**4**状态 · **5**补全权限 · **6**帮助':
|
|
273
273
|
'**💡 Number fallback**\nReply with a number for a quick action:\n**1** Workspace list · **2** New session · **3** Sessions/watches\n**4** Status · **5** Complete permissions · **6** Help',
|
|
274
274
|
'从下方下拉选择补充指令;最后一项可自定义输入。':
|
|
@@ -75,6 +75,8 @@ export default {
|
|
|
75
75
|
'The model service is temporarily unreachable and the task did not finish. Please try again later.',
|
|
76
76
|
'模型服务暂时异常,本次任务未完成。请稍后重试。':
|
|
77
77
|
'The model service is temporarily unavailable and the task did not finish. Please try again later.',
|
|
78
|
+
'模型请求被服务拒绝(可能是上下文过长或该模型当前不可用)。请发送 /compact 或 /new 后重试,或改用其他模型。':
|
|
79
|
+
'The model service rejected the request (the context may be too long, or that model may be unavailable right now). Send /compact or /new and try again, or switch to another model.',
|
|
78
80
|
'模型回复中断或格式异常,本次任务未完成。请重试。':
|
|
79
81
|
'The model reply was interrupted or malformed, so the task did not finish. Please try again.',
|
|
80
82
|
'模型没有返回可显示的内容。请重试;若持续发生,请切换模型。':
|
|
@@ -186,10 +188,19 @@ export default {
|
|
|
186
188
|
'/sessionlist [workspace index or absolute path] List session IDs and titles',
|
|
187
189
|
'/sessionlist 或 /sessions [工作区序号或绝对路径] 列出会话 ID 和标题':
|
|
188
190
|
'/sessionlist or /sessions [workspace index or absolute path] List session IDs and titles',
|
|
191
|
+
'/sessionlist --all 跨工作区汇总会话(每个工作区默认显示 10 个,可用 --limit N 调整)':
|
|
192
|
+
'/sessionlist --all Summarize sessions across Workspaces (10 per Workspace by default; use --limit N to change)',
|
|
189
193
|
'/sessionlist --limit N 仅列出当前工作区前 N 个会话':
|
|
190
194
|
'/sessionlist --limit N List only the first N sessions in the current workspace',
|
|
191
|
-
'/session Session ID
|
|
192
|
-
'/session <Session ID or
|
|
195
|
+
'/session Session ID、当前工作区序号或标题关键词 将当前聊天绑定到指定会话':
|
|
196
|
+
'/session <Session ID, workspace index, or title keyword> Bind this chat to the specified session',
|
|
197
|
+
'/sess 同一命令的别名(/session 被客户端同名命令抢占时使用)':
|
|
198
|
+
'/sess Alias of the same command (use it when a client claims /session)',
|
|
199
|
+
'归档指定会话(DSH 能力)': 'Archive a session (a DSH capability)',
|
|
200
|
+
'/sessionarchive(或 /sessarchive)Session ID 归档一个会话;序号只做预览':
|
|
201
|
+
'/sessionarchive (or /sessarchive) <Session ID> Archive one session; an index only previews',
|
|
202
|
+
'/sessionarchive <Session ID> --stop 归档前先停止该会话正在运行的任务':
|
|
203
|
+
'/sessionarchive <Session ID> --stop Stop that session\'s running work before archiving it',
|
|
193
204
|
'/models 按序号列出所有可用模型': '/models List all available models by index',
|
|
194
205
|
'/reasoninglist 或 /reasonings 按序号列出当前模型可用推理等级':
|
|
195
206
|
'/reasoninglist or /reasonings List reasoning efforts for the current model by index',
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
// English translations (shared-b area). Keys are exact Chinese literals passed to t().
|
|
2
2
|
export default {
|
|
3
3
|
// workspace-command.mjs
|
|
4
|
-
'用法:/session Session ID
|
|
5
|
-
'Usage: /session Session ID
|
|
6
|
-
'用法:\n/sessionlist 列出当前工作区会话\n/sessionlist --limit N 列出当前工作区前 N 个会话(N 为正整数)\n/sessionlist 工作区序号 按 /workspacelist 序号列出会话\n/sessionlist 工作区绝对路径 列出指定工作区会话\n不带工作区参数时,默认列出当前对话的有效工作区(未设置对话专属工作区时即 bot 默认工作区)。':
|
|
7
|
-
'Usage:\n/sessionlist List Sessions in the current Workspace\n/sessionlist --limit N List the first N Sessions in the current Workspace (N must be a positive integer)\n/sessionlist Workspace index List Sessions by /workspacelist index\n/sessionlist Workspace absolute path List Sessions in the given Workspace\nWithout a workspace argument it lists the workspace this conversation effectively uses (the bot default when no conversation workspace is set).',
|
|
4
|
+
'用法:/session Session ID、当前工作区序号(/session N)或会话标题关键词':
|
|
5
|
+
'Usage: /session Session ID, the Session index in the current Workspace (/session N), or a Session title keyword',
|
|
6
|
+
'用法:\n/sessionlist 列出当前工作区会话\n/sessionlist --all 跨工作区汇总列出会话(每个工作区默认显示 10 个)\n/sessionlist --all --limit N 跨工作区汇总列出会话,每个工作区显示前 N 个\n/sessionlist --limit N 列出当前工作区前 N 个会话(N 为正整数)\n/sessionlist --archived 一并列出已归档会话(序号仍只对应未归档会话)\n/sessionlist 工作区序号 按 /workspacelist 序号列出会话\n/sessionlist 工作区绝对路径 列出指定工作区会话\n不带工作区参数时,默认列出当前对话的有效工作区(未设置对话专属工作区时即 bot 默认工作区)。':
|
|
7
|
+
'Usage:\n/sessionlist List Sessions in the current Workspace\n/sessionlist --all List Sessions across all Workspaces (10 per Workspace by default)\n/sessionlist --all --limit N List Sessions across all Workspaces, the first N per Workspace\n/sessionlist --limit N List the first N Sessions in the current Workspace (N must be a positive integer)\n/sessionlist --archived Also list archived Sessions (indices still cover non-archived Sessions only)\n/sessionlist Workspace index List Sessions by /workspacelist index\n/sessionlist Workspace absolute path List Sessions in the given Workspace\nWithout a workspace argument it lists the workspace this conversation effectively uses (the bot default when no conversation workspace is set).',
|
|
8
8
|
'工作区必须是绝对路径。\n{usage}': 'The Workspace must be an absolute path.\n{usage}',
|
|
9
9
|
'工作区路径包含不支持的字符或长度超过限制。\n{usage}':
|
|
10
10
|
'The Workspace path contains unsupported characters or exceeds the length limit.\n{usage}',
|
|
@@ -51,6 +51,58 @@ export default {
|
|
|
51
51
|
'The bot is being removed or has been reconnected; cannot list Workspace Sessions of the original Session.',
|
|
52
52
|
'暂时无法获取工作区会话列表,请稍后重试。':
|
|
53
53
|
'Unable to get the Workspace Session list right now; please try again later.',
|
|
54
|
+
'(当前绑定)': '(currently bound)',
|
|
55
|
+
'跨工作区会话({workspaces} 个工作区,共 {sessions} 个会话):':
|
|
56
|
+
'Sessions across Workspaces ({workspaces} Workspaces, {sessions} Sessions in total):',
|
|
57
|
+
'当前工作区:{workspace}': 'Current Workspace: {workspace}',
|
|
58
|
+
'另有 {count} 个工作区暂时无法读取,未包含在汇总中。':
|
|
59
|
+
'{count} more Workspace(s) could not be read and are not included in the summary.',
|
|
60
|
+
'{workspace}({count} 个会话)': '{workspace} ({count} Sessions)',
|
|
61
|
+
'(共 {total} 个,显示前 {shown} 个;用 --limit N 调整)':
|
|
62
|
+
'(of {total} total, showing the first {shown}; use --limit N to change)',
|
|
63
|
+
'该工作区暂无会话。': 'This Workspace has no Sessions yet.',
|
|
64
|
+
'(已隐藏 {count} 条归档会话,用 --archived 查看)':
|
|
65
|
+
'(hid {count} archived Session(s); use --archived to see them)',
|
|
66
|
+
'归档会话(只能用完整 Session ID 绑定):':
|
|
67
|
+
'Archived Sessions (bind them with the full Session ID):',
|
|
68
|
+
'({count} 条会话记录无效,已跳过)':
|
|
69
|
+
'({count} invalid Session records skipped)',
|
|
70
|
+
'当前机器人暂不支持跨工作区列出会话。':
|
|
71
|
+
'This bot does not support listing Sessions across Workspaces yet.',
|
|
72
|
+
'用法:/sessionarchive Session ID 归档一个会话;/sessionarchive 序号 只预览该序号对应的会话(编号会随列表变化,归档请用完整 ID)。加 --stop 可让 DSH 先停止该会话正在运行的任务':
|
|
73
|
+
'Usage: /sessionarchive <Session ID> archives a Session; /sessionarchive <index> only previews the Session behind that index (indices shift, so archiving needs the full ID). Add --stop to let DSH stop that Session\'s running work first',
|
|
74
|
+
'按序号归档只做预览:/sessionarchive {index} 现在对应这条会话。':
|
|
75
|
+
'Archiving by index is preview-only: /sessionarchive {index} currently points at this Session.',
|
|
76
|
+
'(编号会随会话列表变化,所以不按序号直接归档;确认归档请发送:/sessionarchive {sessionId})':
|
|
77
|
+
'(Indices shift as the list changes, so archiving by index is never executed; to confirm, send: /sessionarchive {sessionId})',
|
|
78
|
+
'当前机器人暂不支持归档会话。': 'This bot does not support archiving Sessions yet.',
|
|
79
|
+
'该会话已经归档。': 'This Session is already archived.',
|
|
80
|
+
'这是本对话当前绑定的会话,请先 /new 或绑定其他会话,再归档它。':
|
|
81
|
+
'This is the Session this chat is bound to; send /new or bind another Session before archiving it.',
|
|
82
|
+
'已归档会话:': 'Archived Session:',
|
|
83
|
+
'机器人正在移除或已重新接入,无法归档原会话的会话。':
|
|
84
|
+
'The bot is being removed or has been reconnected; cannot archive Sessions of the original conversation.',
|
|
85
|
+
'当前 DSH 版本不支持通过机器人归档会话。':
|
|
86
|
+
'This DSH version does not expose Session archiving to the bot.',
|
|
87
|
+
'该会话仍有任务在运行,请先 /stop,或使用 /sessionarchive <目标> --stop。':
|
|
88
|
+
'That Session still has running work; send /stop first, or use /sessionarchive <target> --stop.',
|
|
89
|
+
'暂时无法归档该会话,请稍后重试。': 'Unable to archive that Session right now; please try again later.',
|
|
90
|
+
'标题包含「{keyword}」的会话有多个,请改用完整 Session ID 绑定:':
|
|
91
|
+
'Several Sessions have titles containing "{keyword}"; bind with the full Session ID instead:',
|
|
92
|
+
'标题包含「{keyword}」的会话位于其他工作区,请使用完整 Session ID 绑定:':
|
|
93
|
+
'Sessions whose titles contain "{keyword}" are in other Workspaces; bind with the full Session ID:',
|
|
94
|
+
'部分工作区暂时无法读取,搜索结果可能不完整;请使用完整 Session ID 绑定:':
|
|
95
|
+
'Some Workspaces could not be read, so the search may be incomplete; bind with the full Session ID:',
|
|
96
|
+
'部分工作区暂时无法读取,未能确认标题包含「{keyword}」的会话。请稍后重试或使用完整 Session ID。':
|
|
97
|
+
'Some Workspaces could not be read, so no Session title containing "{keyword}" could be confirmed. Try again later or use the full Session ID.',
|
|
98
|
+
'匹配较多,只显示前 {count} 个,请使用更精确的关键词。':
|
|
99
|
+
'Many matches; only the first {count} are shown. Please use a more specific keyword.',
|
|
100
|
+
'标题包含「{keyword}」的会话已归档,按标题绑定不会接管归档会话,请用完整 Session ID 绑定:':
|
|
101
|
+
'Sessions whose titles contain "{keyword}" are archived, and a title keyword never takes over an archived Session; bind one with its full Session ID:',
|
|
102
|
+
'按标题匹配到「{title}」(ID: {sessionId},工作区: {workspace}),但 Harness 当前无法接管这个会话,请稍后重试或用完整 Session ID 绑定。':
|
|
103
|
+
'The keyword matched "{title}" (ID: {sessionId}, Workspace: {workspace}), but Harness cannot take over that Session right now. Try again later or bind it with the full Session ID.',
|
|
104
|
+
'没有标题包含「{keyword}」的会话,请先执行 /sessionlist --all 查看完整 Session ID。':
|
|
105
|
+
'No Session title contains "{keyword}"; run /sessionlist --all to find the full Session ID.',
|
|
54
106
|
'Session ID 格式无效。\n{usage}': 'Invalid Session ID format.\n{usage}',
|
|
55
107
|
'未找到该会话,请先执行 /sessionlist 确认 Session ID。':
|
|
56
108
|
'Session not found; please run /sessionlist to confirm the Session ID.',
|
|
@@ -300,4 +352,15 @@ export default {
|
|
|
300
352
|
'Invalid Session sync settings: each switch must be a boolean and an icon is text of at most 32 characters.',
|
|
301
353
|
'无法读取或保存会话同步设置,请稍后重试。':
|
|
302
354
|
'Could not read or save Session sync settings. Try again later.',
|
|
355
|
+
|
|
356
|
+
// plan-goal-command.mjs
|
|
357
|
+
'当前聊天还没有可用的会话,请先发送一条消息。':
|
|
358
|
+
'This chat has no available Session yet; please send a message first.',
|
|
359
|
+
'当前 Host 不支持命令委派,请确认 DSH 命令网关可用。':
|
|
360
|
+
'The current Host does not support command delegation; make sure the DSH command gateway is available.',
|
|
361
|
+
'{name} 已执行。': '{name} executed.',
|
|
362
|
+
'{name} 执行失败。': '{name} failed.',
|
|
363
|
+
'{name} 执行失败,请稍后重试。': '{name} failed; please try again later.',
|
|
364
|
+
'当前机器人暂不支持 {name} 命令。': 'This bot does not support the {name} command yet.',
|
|
365
|
+
'当前 Host 未注册 {name} 命令。': 'The current Host has not registered the {name} command.',
|
|
303
366
|
};
|
|
@@ -0,0 +1,144 @@
|
|
|
1
|
+
// English translations (shared-d area: session navigation commands).
|
|
2
|
+
// Keys are exact Chinese literals passed to t().
|
|
3
|
+
export default {
|
|
4
|
+
'当前会话最近 {count} 条(仅显示提问与回答):':
|
|
5
|
+
'Current session, last {count} messages (prompts and answers only):',
|
|
6
|
+
'会话 {n} 最近 {count} 条(仅显示提问与回答):':
|
|
7
|
+
'Session {n}, last {count} messages (prompts and answers only):',
|
|
8
|
+
'… 还有 {n} 条更早的消息。': '… and {n} more messages.',
|
|
9
|
+
'会话、工作区或机器人状态已发生变化,请重新执行 /tail。':
|
|
10
|
+
'The session, workspace, or bot state has changed. Please run /tail again.',
|
|
11
|
+
'读取已取消。': 'Reading was cancelled.',
|
|
12
|
+
'读取超时,请稍后重试。': 'Reading timed out. Please try again later.',
|
|
13
|
+
'暂时无法读取会话内容,请稍后重试。':
|
|
14
|
+
'The session content is temporarily unavailable. Please try again later.',
|
|
15
|
+
'没有编号为 {n} 的会话。用 /ls 查看列表。':
|
|
16
|
+
'There is no session number {n}. Use /ls to see the list.',
|
|
17
|
+
'编号 {n} 的会话已不存在或已归档。如需从列表移除请发送 /drop {n}。':
|
|
18
|
+
'Session {n} no longer exists or is archived. To remove it from the list, send /drop {n}.',
|
|
19
|
+
'工作区或机器人状态已发生变化,请重试 /go {n}。':
|
|
20
|
+
'The workspace or bot state has changed. Please retry /go {n}.',
|
|
21
|
+
'暂时无法切换会话,请稍后重试。': 'Cannot switch sessions right now. Please try again later.',
|
|
22
|
+
'此聊天或话题还没有会话,发送 /new 创建第一个(列表按聊天隔离,论坛群按话题)。':
|
|
23
|
+
'No sessions in this chat/topic yet — /new creates the first one (the list is per chat, per topic in forum groups).',
|
|
24
|
+
'会话较多,仅显示最近 {shown} 条(共 {total} 条)。':
|
|
25
|
+
'Many sessions; showing the latest {shown} of {total}.',
|
|
26
|
+
'已切换到会话 {n}({title},最后活动 {age})。':
|
|
27
|
+
'Switched to session {n} ({title}, last activity {age}).',
|
|
28
|
+
'此聊天没有更早的会话。': 'No earlier session in this chat.',
|
|
29
|
+
'此聊天没有更晚的会话。': 'No later session in this chat.',
|
|
30
|
+
'目标会话不存在,请发送 /ls 查看。':
|
|
31
|
+
'The target session no longer exists. Send /ls to review the list.',
|
|
32
|
+
'已切换到会话 {n}({title})。': 'Switched to session {n} ({title}).',
|
|
33
|
+
'已从会话列表移除编号 {n}。注意:Harness 中的会话本身未被删除或归档,仍可在 DSH 中访问。':
|
|
34
|
+
'Removed session {n} from the list. Note: the session itself was not deleted or archived in Harness and is still available in DSH.',
|
|
35
|
+
'当前聊天尚未绑定会话,无法确定保留哪条,未移除任何记录。':
|
|
36
|
+
'This chat is not bound to a session, so there is nothing to keep; no entries were removed.',
|
|
37
|
+
'列表里只有当前会话,无需移除。':
|
|
38
|
+
'Only the current session is in the list, so there is nothing to remove.',
|
|
39
|
+
'已移除 {count} 条记录,保留编号 {n}(当前会话)。注意:Harness 中的会话本身未被删除或归档,仍可在 DSH 中访问。':
|
|
40
|
+
'Removed {count} entries; kept № {n} (current). Note: the sessions themselves were not deleted or archived in Harness and are still available in DSH.',
|
|
41
|
+
'会话 {n}:{title}': 'Session {n}: {title}',
|
|
42
|
+
'当前聊天尚未绑定会话。': 'This chat is not bound to a session yet.',
|
|
43
|
+
'当前会话编号 {n}:{title}': 'Current session number {n}: {title}',
|
|
44
|
+
'当前 Harness 暂不支持重命名会话。': 'This Harness does not support renaming sessions.',
|
|
45
|
+
'已将会话标题改为「{title}」。': 'Renamed the session to "{title}".',
|
|
46
|
+
'暂时无法重命名会话,请稍后重试。': 'Cannot rename the session right now. Please try again later.',
|
|
47
|
+
'本次有限读取中未找到可预览的消息。':
|
|
48
|
+
'No previewable messages were found in this bounded read.',
|
|
49
|
+
'当前会话暂无可预览的消息。': 'This session has no previewable messages.',
|
|
50
|
+
'用法:/go 会话编号(用 /ls 查看编号)。':
|
|
51
|
+
'Usage: /go <session number> (see numbers with /ls).',
|
|
52
|
+
'用法:/drop 会话编号(用 /ls 查看编号)。':
|
|
53
|
+
'Usage: /drop <session number> (see numbers with /ls).',
|
|
54
|
+
'未知命令,请发送 /help 查看帮助。': 'Unknown command. Send /help for help.',
|
|
55
|
+
'导出时间:{time}': 'Exported: {time}',
|
|
56
|
+
'消息数:{count}': 'Messages: {count}',
|
|
57
|
+
'导出标题:会话': 'session',
|
|
58
|
+
'导出角色:用户': 'User',
|
|
59
|
+
'导出角色:助手': 'Assistant',
|
|
60
|
+
'正文说明:消息正文以代码围栏逐字引用,围栏长度大于正文中任意连续的围栏字符。':
|
|
61
|
+
'Convention: message bodies are quoted verbatim inside code fences whose delimiter is longer than any run of fence characters in the body.',
|
|
62
|
+
'注意:因事件数量达到上限,导出内容被截断。':
|
|
63
|
+
'Note: the export was truncated because the event cap was reached.',
|
|
64
|
+
'当前渠道不支持发送文件。': 'This channel does not support sending files.',
|
|
65
|
+
'隐藏消息': 'Hide message',
|
|
66
|
+
'已隐藏。': 'Hidden.',
|
|
67
|
+
'列出本聊天使用过的会话(按聊天/话题隔离)': "List this chat's sessions (per chat / per topic)",
|
|
68
|
+
'/ls 或 /list 列出本聊天使用过的会话(● 当前,←/→ 可前后切换,✕ 已失效;列表按聊天隔离,论坛群按话题)':
|
|
69
|
+
'/ls or /list List this chat\'s sessions (● current, ←/→ navigate, ✕ unavailable; the list is per chat, and per topic in forum groups)',
|
|
70
|
+
'切换到指定编号的会话': 'Switch to a session by number',
|
|
71
|
+
'/go 会话编号 切换到该会话(编号见 /ls)':
|
|
72
|
+
'/go <number> Switch to that session (numbers in /ls)',
|
|
73
|
+
'回到上一个会话': 'Go back to the previous session',
|
|
74
|
+
'/prev 回到上一个会话': '/prev Go back to the previous session',
|
|
75
|
+
'前进到下一个会话': 'Go forward to the next session',
|
|
76
|
+
'/next 前进到下一个会话': '/next Go forward to the next session',
|
|
77
|
+
'从会话列表移除一条记录': 'Remove one entry from the session list',
|
|
78
|
+
'/drop 会话编号 从本聊天会话列表移除该条记录(不删除 Harness 会话)':
|
|
79
|
+
'/drop <number> Remove that entry from this chat\'s session list (the Harness session is not deleted)',
|
|
80
|
+
'/drop all 移除除当前会话外的全部记录(不删除 Harness 会话)':
|
|
81
|
+
'/drop all Remove every entry except the current session (the Harness sessions are not deleted)',
|
|
82
|
+
'查看或重命名会话标题': 'Show or rename a session title',
|
|
83
|
+
'/title 查看当前会话标题': '/title Show the current session title',
|
|
84
|
+
'/title 新标题 重命名当前会话': '/title <new title> Rename the current session',
|
|
85
|
+
'/title 会话编号 新标题 重命名指定会话': '/title <number> <new title> Rename that session',
|
|
86
|
+
'预览或导出会话内容': 'Preview or export session content',
|
|
87
|
+
'/tail 或 /peek [编号] [条数] 预览最近消息(默认 5 条,仅提问与回答)':
|
|
88
|
+
'/tail or /peek [number] [count] Preview recent messages (default 5; prompts and answers only)',
|
|
89
|
+
'/tail 或 /peek [编号] file 导出整个会话为 Markdown 文件':
|
|
90
|
+
'/tail or /peek [number] file Export the whole session as a Markdown file',
|
|
91
|
+
'会话(/go N):': 'Sessions (/go N):',
|
|
92
|
+
'秒': 's',
|
|
93
|
+
'分': 'min',
|
|
94
|
+
'时': 'h',
|
|
95
|
+
'天': 'd',
|
|
96
|
+
'无标题': 'no title',
|
|
97
|
+
'当前会话:{title}': 'Current session: {title}',
|
|
98
|
+
'已记住新会话标题「{title}」,将在下一条消息创建会话时应用。':
|
|
99
|
+
'Remembered the new session title "{title}"; it will be applied when the next message creates the session.',
|
|
100
|
+
'编号 {n} 是当前会话,不能删除。请先切换到其他会话(/go 数字、/prev 或 /new)再删除。':
|
|
101
|
+
'Session {n} is the current session and cannot be dropped. Switch away first (/go <number>, /prev, or /new), then drop it.',
|
|
102
|
+
'✕ 当前会话已失效,发送 /new 可开启新会话。':
|
|
103
|
+
'✕ The current session is unavailable; send /new to start a fresh one.',
|
|
104
|
+
'开启一个全新会话(可带标题)': 'Start a brand-new session (with an optional title)',
|
|
105
|
+
'/new [标题] 开启一个全新会话(可指定标题)':
|
|
106
|
+
'/new [title] Start a brand-new session (optionally titled)',
|
|
107
|
+
'从当前会话分支一个新会话': 'Branch a new session from the current one',
|
|
108
|
+
'/fork [标题] 从当前会话分支一个新会话(默认沿用父会话标题加“ (fork)”)':
|
|
109
|
+
'/fork [title] Branch a new session from the current one (default: parent title + " (fork)")',
|
|
110
|
+
'当前 Host 不支持会话分支(fork)。': 'This Host does not support session branching (fork).',
|
|
111
|
+
'当前会话仍在生成回复,请先等待完成或发送 /stop 再分支。':
|
|
112
|
+
'The current session is still generating a reply; wait for it to finish or send /stop before forking.',
|
|
113
|
+
'当前会话还没有已完成的回合,无法分支。请先完成一个回合再 /fork。':
|
|
114
|
+
'The current session has no completed turn yet; finish one before /fork.',
|
|
115
|
+
'当前会话已不存在或已归档,无法分支。':
|
|
116
|
+
'The current session no longer exists or is archived; it cannot be forked.',
|
|
117
|
+
'工作区或机器人状态已发生变化,请重试 /fork。':
|
|
118
|
+
'The workspace or bot state has changed; please retry /fork.',
|
|
119
|
+
'暂时无法分支会话,请稍后重试。': 'Cannot fork the session right now. Please try again later.',
|
|
120
|
+
'分支出的子会话无法绑定,请重试。': 'The forked child session could not be bound. Please try again.',
|
|
121
|
+
'分支出的子会话已归档,无法绑定。': 'The forked child session is archived and cannot be bound.',
|
|
122
|
+
'暂时无法绑定分支出的子会话,请稍后重试。':
|
|
123
|
+
'Cannot bind the forked child session right now. Please try again later.',
|
|
124
|
+
'已从会话 {parent} 分支到会话 {child}:{title}': 'Forked session {parent} into session {child}: {title}',
|
|
125
|
+
'切换后的提问发送失败,请重试。': 'The follow-up question after the switch failed to send. Please try again.',
|
|
126
|
+
'暂时无法创建新会话,请稍后重试。': 'Cannot create a new session right now. Please try again later.',
|
|
127
|
+
'重置当前会话上下文(保留会话编号)': 'Reset the current session context (keep the number)',
|
|
128
|
+
'/reset 重置当前会话上下文(保留会话编号,旧会话可 /session 找回)':
|
|
129
|
+
'/reset Reset the current session context (keep the number; the old session is reachable via /session)',
|
|
130
|
+
'用法:/reset(不带参数且不可附带图片或文件)':
|
|
131
|
+
'Usage: /reset (no arguments, and no images or files)',
|
|
132
|
+
'当前会话正在生成回复或等待交互,请先完成交互或发送 /stop,再执行 /reset。':
|
|
133
|
+
'The current session is generating a reply or awaiting an interaction; finish it or send /stop before /reset.',
|
|
134
|
+
'当前机器人没有可用的会话状态,未重置当前会话。':
|
|
135
|
+
'This bot has no session state available; the current session was not reset.',
|
|
136
|
+
'当前 Host 不支持 /reset,当前会话未修改。':
|
|
137
|
+
'This Host does not support /reset; the current session is unchanged.',
|
|
138
|
+
'重置当前会话上下文失败,当前会话未修改,请稍后重试。':
|
|
139
|
+
'Could not reset the current session context; it is unchanged. Please try again later.',
|
|
140
|
+
'当前会话上下文已重置(编号保持不变)。旧会话 ID:{id},可用 /session {id} 重新绑定。':
|
|
141
|
+
'The current session context is reset (the number is unchanged). Old session ID: {id}; rebind it with /session {id}.',
|
|
142
|
+
'当前聊天还没有会话,已开启全新会话。':
|
|
143
|
+
'This chat has no session yet, so a new session was started.',
|
|
144
|
+
};
|
|
@@ -85,4 +85,8 @@ export default {
|
|
|
85
85
|
'微信服务拒绝了文件上传请求。': 'The WeChat service rejected the file upload request.',
|
|
86
86
|
'微信服务拒绝了文件消息。': 'The WeChat service rejected the file message.',
|
|
87
87
|
'微信账号连接启动失败。': 'Failed to start the WeChat account connection.',
|
|
88
|
+
'/plan 进入计划模式(/plan off 退出,可附带说明文字)':
|
|
89
|
+
'/plan Enter plan mode (/plan off to leave; an optional note can be attached)',
|
|
90
|
+
'/goal [目标] 设置目标(clear 清除、edit 修改、pause 暂停、resume 恢复;不带参数查看)':
|
|
91
|
+
'/goal [objective] Set the goal (clear to remove, edit to change, pause to suspend, resume to continue; no argument to view)',
|
|
88
92
|
};
|
|
@@ -9,6 +9,7 @@ import diagnostics from './i18n-en/diagnostics.mjs';
|
|
|
9
9
|
import sharedA from './i18n-en/shared-a.mjs';
|
|
10
10
|
import sharedB from './i18n-en/shared-b.mjs';
|
|
11
11
|
import sharedC from './i18n-en/shared-c.mjs';
|
|
12
|
+
import sharedD from './i18n-en/shared-d.mjs';
|
|
12
13
|
import feishu from './i18n-en/feishu.mjs';
|
|
13
14
|
import dingtalk from './i18n-en/dingtalk.mjs';
|
|
14
15
|
import wecom from './i18n-en/wecom.mjs';
|
|
@@ -31,6 +32,7 @@ export const EN = Object.freeze(Object.assign(
|
|
|
31
32
|
sharedA,
|
|
32
33
|
sharedB,
|
|
33
34
|
sharedC,
|
|
35
|
+
sharedD,
|
|
34
36
|
feishu,
|
|
35
37
|
dingtalk,
|
|
36
38
|
wecom,
|
|
@@ -245,8 +245,8 @@ export default {
|
|
|
245
245
|
'/steer 指令 给 Agent 补充指令': '/steer УКАЗАНИЕ Скорректировать Agent',
|
|
246
246
|
'**📋 卡片功能**\n\n1. 会话下拉 — 切换当前绑定会话\n2. 工作区下拉 — 切换工作区\n3. 🤖 预设下拉 — 切换 Agent 预设\n4. 🧠 模型下拉 — 切换模型\n5. 🆕 新会话 — 开启全新会话\n6. 📋 会话/关注 — 查看/绑定会话,管理关注\n7. ⏹ 停止 — 停止当前任务\n8. 📐 压缩 — 压缩当前会话上下文\n9. 🧹 清空上下文 — 清空上下文并保留绑定和历史记录\n10. 补充指令 — 给 Agent 发送指令\n11. 🗄 归档切换 — 显示/隐藏归档会话\n12. 📊 状态 — 查看系统连接状态\n13. 📖 帮助 — 查看本帮助':
|
|
247
247
|
'**📋 Возможности карточки**\n\n1. Список сессий — переключить привязанную сессию\n2. Список рабочих областей — сменить рабочую область\n3. 🤖 Список пресетов — сменить Agent Preset\n4. 🧠 Список моделей — сменить модель\n5. 🆕 Новая сессия — начать с чистого листа\n6. 📋 Сессии/наблюдение — посмотреть или привязать сессии и управлять наблюдением\n7. ⏹ Остановить — остановить текущую задачу\n8. 📐 Сжать — сжать контекст текущей сессии\n9. 🧹 Очистить контекст — очистить контекст, сохранив привязку и историю\n10. Скорректировать задачу — отправить указание Agent\n11. 🗄 Архив — показать или скрыть архивные сессии\n12. 📊 Состояние — состояние соединения\n13. 📖 Справка — эта справка',
|
|
248
|
-
'**⌨️ 文本命令**\n\n`/m` — 打开菜单卡片\n`/new` — 开启全新会话\n`/session ID
|
|
249
|
-
'**⌨️ Текстовые команды**\n\n`/m` — открыть меню-карточку\n`/new` — открыть новую сессию\n`/session ID
|
|
248
|
+
'**⌨️ 文本命令**\n\n`/m` — 打开菜单卡片\n`/new` — 开启全新会话\n`/session Session ID、当前工作区序号或标题关键词` — 绑定已有会话\n`/sessionlist [工作区]` 或 `/sessions [工作区]` — 列出会话\n`/sessionlist --all` 或 `/sessions --all` — 跨工作区汇总会话(每个工作区默认显示 10 个,可用 --limit N 调整)\n`/sessionlist --limit N` 或 `/sessions --limit N` — 仅列出当前工作区前 N 个会话\n`/workspace 工作区序号或绝对路径` — 切换工作区\n`/workspacelist` — 列出工作区\n`/status` — 查看连接状态\n`/compact` — 压缩上下文\n`/clear` — 清空上下文并保留 Session 绑定和历史记录\n`/stop` — 停止当前任务\n`/steer 指令` — 补充指令\n`/watch ID` — 关注会话\n`/watchlist` — 关注列表\n`/unwatch ID` — 取消关注\n`/archived on/off` — 归档显隐\n`/presetlist` 或 `/presets` — 列出预设\n`/preset [序号/ID]` — 切换预设\n`/preset --default` — 跟随默认\n`/models` — 列出模型\n`/reasoninglist` 或 `/reasonings` — 按序号列出当前模型可用推理等级\n`/reasoning [序号、等级ID或 --default]` — 查看或切换当前推理等级\n`/model [序号或完整模型ID] [推理等级ID]` — 查看或切换当前会话模型\n`/batch` — 开启批量输入(仅私聊,最多 10 条文字)\n`/send` — 提交当前批次\n`/cancel` — 取消当前批次\n`/repair` — 补全飞书权限与卡片回调':
|
|
249
|
+
'**⌨️ Текстовые команды**\n\n`/m` — открыть меню-карточку\n`/new` — открыть новую сессию\n`/session Session ID, номер в текущей рабочей области или ключевое слово заголовка` — привязать существующую сессию\n`/sessionlist [рабочая область]` или `/sessions [рабочая область]` — список сессий\n`/sessionlist --all` или `/sessions --all` — сводка сессий по всем рабочим областям (по 10 на рабочую область по умолчанию; измените через --limit N)\n`/sessionlist --limit N` или `/sessions --limit N` — только первые N сессий текущей рабочей области\n`/workspace <номер или абсолютный путь рабочей области>` — сменить рабочую область\n`/workspacelist` — список рабочих областей\n`/status` — состояние соединения\n`/compact` — сжать контекст\n`/clear` — очистить контекст, сохранив привязку к сессии и историю\n`/stop` — остановить текущую задачу\n`/steer УКАЗАНИЕ` — скорректировать задачу\n`/watch ID` — следить за сессией\n`/watchlist` — список отслеживаемых сессий\n`/unwatch ID` — перестать следить\n`/archived on/off` — показать или скрыть архивные сессии\n`/presetlist` или `/presets` — список пресетов\n`/preset [номер/ID]` — сменить пресет\n`/preset --default` — как по умолчанию\n`/models` — список моделей\n`/reasoninglist` или `/reasonings` — уровни рассуждений текущей модели\n`/reasoning [номер, ID уровня или --default]` — показать или сменить уровень рассуждений\n`/model [номер или полный ID модели] [ID уровня рассуждений]` — показать или сменить модель текущей сессии\n`/batch` — начать пакетный ввод (только в личных чатах, до 10 текстовых сообщений)\n`/send` — отправить текущий пакет\n`/cancel` — отменить текущий пакет\n`/repair` — дополнить права Feishu и обратный вызов карточек',
|
|
250
250
|
'**💡 数字兜底**\n回复数字快速操作:\n**1**工作区列表 · **2**新会话 · **3**会话/关注\n**4**状态 · **5**补全权限 · **6**帮助':
|
|
251
251
|
'**💡 Выбор по номеру**\nОтветьте номером для быстрого действия:\n**1** Список рабочих областей · **2** Новая сессия · **3** Сессии/наблюдение\n**4** Состояние · **5** Дополнить права · **6** Справка',
|
|
252
252
|
'从下方下拉选择补充指令;最后一项可自定义输入。': 'Выберите указание ниже; последний пункт позволяет ввести своё.',
|