@parallel-cli/parallel 0.3.3 → 0.4.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.md +146 -83
- package/dist/agents/agent.js +24 -2
- package/dist/agents/tools.js +4 -2
- package/dist/commands.js +179 -135
- package/dist/config.js +9 -0
- package/dist/controller.js +38 -5
- package/dist/i18n.js +160 -40
- package/dist/index.js +4 -2
- package/dist/server.js +2 -1
- package/dist/ui/AgentPanel.js +85 -16
- package/dist/ui/App.js +191 -61
- package/dist/ui/AttachApp.js +46 -21
- package/dist/ui/CommandInput.js +56 -15
- package/dist/ui/SettingsPanel.js +9 -2
- package/dist/ui/Timeline.js +60 -0
- package/dist/ui/events.js +229 -0
- package/dist/ui/theme.js +5 -4
- package/dist/ui/tokens.js +77 -0
- package/dist/ui/views.js +9 -3
- package/package.json +2 -2
package/dist/config.js
CHANGED
|
@@ -78,6 +78,13 @@ export const DEFAULTS = {
|
|
|
78
78
|
soundEnabled: true,
|
|
79
79
|
recentFolders: [],
|
|
80
80
|
};
|
|
81
|
+
function normalizeApprovalMode(mode) {
|
|
82
|
+
if (mode === 'ask' || mode === 'auto-safe' || mode === 'yolo')
|
|
83
|
+
return mode;
|
|
84
|
+
if (mode === 'auto')
|
|
85
|
+
return 'auto-safe';
|
|
86
|
+
return 'ask';
|
|
87
|
+
}
|
|
81
88
|
export function getProvider(cfg, name) {
|
|
82
89
|
const n = (name ?? cfg.defaultProvider).toLowerCase();
|
|
83
90
|
return cfg.providers.find((p) => p.name.toLowerCase() === n) ?? (name ? undefined : cfg.providers[0]);
|
|
@@ -117,6 +124,7 @@ export function loadConfig() {
|
|
|
117
124
|
cfg = { ...cfg, ...raw };
|
|
118
125
|
if (!Array.isArray(cfg.providers))
|
|
119
126
|
cfg.providers = [];
|
|
127
|
+
cfg.approvalMode = normalizeApprovalMode(raw.approvalMode);
|
|
120
128
|
migrate(raw, cfg);
|
|
121
129
|
}
|
|
122
130
|
}
|
|
@@ -146,6 +154,7 @@ export function loadConfig() {
|
|
|
146
154
|
}
|
|
147
155
|
if (!Array.isArray(cfg.recentFolders))
|
|
148
156
|
cfg.recentFolders = [];
|
|
157
|
+
cfg.approvalMode = normalizeApprovalMode(cfg.approvalMode);
|
|
149
158
|
return cfg;
|
|
150
159
|
}
|
|
151
160
|
export function saveConfig(cfg) {
|
package/dist/controller.js
CHANGED
|
@@ -10,6 +10,35 @@ import { priceFor, fmtCost } from './pricing.js';
|
|
|
10
10
|
import { loadSkills, loadSpecialists } from './skills.js';
|
|
11
11
|
import { t } from './i18n.js';
|
|
12
12
|
const AGENT_COLORS = ['cyan', 'magenta', 'yellow', 'green', 'blue', 'redBright', 'cyanBright', 'magentaBright'];
|
|
13
|
+
export function normalizeShellApprovalMode(mode) {
|
|
14
|
+
if (mode === 'ask' || mode === 'auto-safe' || mode === 'yolo')
|
|
15
|
+
return mode;
|
|
16
|
+
if (mode === 'auto')
|
|
17
|
+
return 'auto-safe';
|
|
18
|
+
return null;
|
|
19
|
+
}
|
|
20
|
+
export function isRiskyCommand(command) {
|
|
21
|
+
const c = command.toLowerCase();
|
|
22
|
+
if (/\b(sudo|su|dd|mkfs|fdisk|parted)\b/.test(c))
|
|
23
|
+
return true;
|
|
24
|
+
if (/\b(rm|unlink|rmdir)\b/.test(c))
|
|
25
|
+
return true;
|
|
26
|
+
if (/\b(chmod|chown)\s+-[^\s]*r\b/.test(c) || /\b(chmod|chown)\s+.*\s-r\b/.test(c))
|
|
27
|
+
return true;
|
|
28
|
+
if (/\bmv\b.*\s(\/|~|\.\.)/.test(c))
|
|
29
|
+
return true;
|
|
30
|
+
if (/\b(curl|wget)\b.*\|\s*(sh|bash|zsh|python|node)\b/.test(c))
|
|
31
|
+
return true;
|
|
32
|
+
if (/\bgit\s+(reset|clean)\b/.test(c))
|
|
33
|
+
return true;
|
|
34
|
+
if (/\bgit\s+push\b.*(--force|-f)\b/.test(c))
|
|
35
|
+
return true;
|
|
36
|
+
if (/\b(drop|truncate)\s+(table|database|schema)\b/.test(c))
|
|
37
|
+
return true;
|
|
38
|
+
if (/\b(prisma|knex|typeorm|sequelize|rails)\b.*\b(drop|reset|rollback|migrate)\b/.test(c))
|
|
39
|
+
return true;
|
|
40
|
+
return false;
|
|
41
|
+
}
|
|
13
42
|
/**
|
|
14
43
|
* The Controller glues everything together: it owns the blackboard, the LLM
|
|
15
44
|
* clients, the live agents and the approval queue. The UI talks only to it.
|
|
@@ -52,7 +81,7 @@ export class Controller extends EventEmitter {
|
|
|
52
81
|
this.session = {
|
|
53
82
|
providerName: p?.name ?? '',
|
|
54
83
|
model: p?.defaultModel || p?.models[0] || '',
|
|
55
|
-
approvalMode: config.approvalMode,
|
|
84
|
+
approvalMode: normalizeShellApprovalMode(config.approvalMode) ?? 'ask',
|
|
56
85
|
soundEnabled: config.soundEnabled,
|
|
57
86
|
};
|
|
58
87
|
this.board.on('update', () => this.emit('update'));
|
|
@@ -145,11 +174,13 @@ export class Controller extends EventEmitter {
|
|
|
145
174
|
}
|
|
146
175
|
// ---------- approvals ----------
|
|
147
176
|
requestApproval = (agentId, command) => {
|
|
148
|
-
if (this.session.approvalMode === 'auto')
|
|
149
|
-
return Promise.resolve(true);
|
|
150
177
|
const base = command.trim().split(/\s+/)[0];
|
|
151
178
|
if (this.sessionAllowedCommands.has(base))
|
|
152
179
|
return Promise.resolve(true);
|
|
180
|
+
if (this.session.approvalMode === 'yolo')
|
|
181
|
+
return Promise.resolve(true);
|
|
182
|
+
if (this.session.approvalMode === 'auto-safe' && !isRiskyCommand(command))
|
|
183
|
+
return Promise.resolve(true);
|
|
153
184
|
return new Promise((resolve) => {
|
|
154
185
|
const agent = this.board.agents.get(agentId);
|
|
155
186
|
this.approvals.push({
|
|
@@ -223,7 +254,7 @@ export class Controller extends EventEmitter {
|
|
|
223
254
|
}
|
|
224
255
|
}
|
|
225
256
|
/** Launch agent N+1 — works at any time, even while others are running. */
|
|
226
|
-
spawnAgent(task, name, modelSpec, images, specialistName, initialHistory) {
|
|
257
|
+
spawnAgent(task, name, modelSpec, images, specialistName, initialHistory, mode = 'task') {
|
|
227
258
|
// Specialist persona: role appended to the system prompt, may pin a model.
|
|
228
259
|
let specialist;
|
|
229
260
|
if (specialistName) {
|
|
@@ -263,6 +294,7 @@ export class Controller extends EventEmitter {
|
|
|
263
294
|
alias,
|
|
264
295
|
color,
|
|
265
296
|
task,
|
|
297
|
+
mode,
|
|
266
298
|
model: resolved.model,
|
|
267
299
|
llm: this.llmFor(resolved.provider, resolved.model),
|
|
268
300
|
board: this.board,
|
|
@@ -364,7 +396,7 @@ export class Controller extends EventEmitter {
|
|
|
364
396
|
}
|
|
365
397
|
if (history.length === 0)
|
|
366
398
|
return 'no-conversation';
|
|
367
|
-
return this.spawnAgent(sa.task, sa.name, sa.model, undefined, undefined, history);
|
|
399
|
+
return this.spawnAgent(sa.task, sa.name, sa.model, undefined, undefined, history, sa.mode ?? 'task');
|
|
368
400
|
}
|
|
369
401
|
pauseAgent(name) {
|
|
370
402
|
const a = this.findAgent(name);
|
|
@@ -562,6 +594,7 @@ export class Controller extends EventEmitter {
|
|
|
562
594
|
agents: [...this.board.agents.values()].map((a) => ({
|
|
563
595
|
name: a.name,
|
|
564
596
|
task: a.task,
|
|
597
|
+
mode: a.mode,
|
|
565
598
|
state: a.state,
|
|
566
599
|
lastResult: a.lastResult,
|
|
567
600
|
steps: a.steps,
|
package/dist/i18n.js
CHANGED
|
@@ -119,11 +119,32 @@ const en = {
|
|
|
119
119
|
'help.states': 'States: 🔨 working · 👂 listening to other agents (double border) · 🧠 thinking · ✋ waiting for your approval · ⏹ stop. Sounds: 1 beep = agent launched/finished, 2 beeps = approval required (/sound off to mute).',
|
|
120
120
|
'help.keys': 'Esc: back to agents view · Tab: completion · ↑/↓: history · Ctrl+V: paste image',
|
|
121
121
|
// commands (descriptions)
|
|
122
|
-
'cmd.
|
|
122
|
+
'cmd.ask': 'Ask-only agent: answers and advises without editing',
|
|
123
|
+
'cmd.task': 'Task agent: executes, edits, validates, summarizes',
|
|
123
124
|
'cmd.agents': 'Agents panel view (real time)',
|
|
124
125
|
'cmd.board': 'Coordination view: who works where, notes',
|
|
125
126
|
'cmd.notes': 'Inter-agent notes history',
|
|
126
127
|
'cmd.diff': 'Live file diffs',
|
|
128
|
+
'cmd.status': 'Show session status: model, agents, changes, cost',
|
|
129
|
+
'cmd.raw': 'Toggle raw activity detail in focus view',
|
|
130
|
+
'cmd.copy': 'Copy the latest completed agent result',
|
|
131
|
+
'timeline.activity': 'Activity',
|
|
132
|
+
'timeline.raw': 'Raw activity',
|
|
133
|
+
'timeline.empty': 'No activity yet.',
|
|
134
|
+
'timeline.ran': 'Ran',
|
|
135
|
+
'timeline.readFiles': 'Read {count} file(s)',
|
|
136
|
+
'timeline.editedFiles': 'Edited {count} file(s)',
|
|
137
|
+
'timeline.wroteFiles': 'Wrote {count} file(s)',
|
|
138
|
+
'timeline.searched': 'Searched {count} target(s)',
|
|
139
|
+
'timeline.listed': 'Listed {count} target(s)',
|
|
140
|
+
'timeline.hiddenLines': '+{count} hidden line(s)',
|
|
141
|
+
'timeline.section.inspect': 'Inspecting context',
|
|
142
|
+
'timeline.section.change': 'Changing files',
|
|
143
|
+
'timeline.section.validate': 'Validating',
|
|
144
|
+
'timeline.section.publish': 'Publishing',
|
|
145
|
+
'timeline.section.coordinate': 'Coordinating',
|
|
146
|
+
'timeline.section.result': 'Result',
|
|
147
|
+
'timeline.section.other': 'Activity',
|
|
127
148
|
'cmd.send': 'Instruction to an agent (same as: @Agent message)',
|
|
128
149
|
'cmd.pause': 'Pause',
|
|
129
150
|
'cmd.resume': 'Resume',
|
|
@@ -134,7 +155,7 @@ const en = {
|
|
|
134
155
|
'cmd.doctor': 'Check provider/model/API key configuration and repair hints',
|
|
135
156
|
'cmd.settings': 'Global settings — providers, API keys, language, defaults (persisted)',
|
|
136
157
|
'cmd.ssettings': 'Session settings — model, approvals, sound (this session only)',
|
|
137
|
-
'cmd.approvals': 'Shell
|
|
158
|
+
'cmd.approvals': 'Shell approvals: ask, auto-safe, or yolo (this session)',
|
|
138
159
|
'cmd.sound': 'Sound cues (this session)',
|
|
139
160
|
'cmd.save': 'Save the session now (optionally with a name)',
|
|
140
161
|
'cmd.focus': 'Focus one agent: plain text goes to it, full-width panel',
|
|
@@ -145,7 +166,8 @@ const en = {
|
|
|
145
166
|
'cmd.quit': 'Quit (saves session, stops agents)',
|
|
146
167
|
// command messages
|
|
147
168
|
'm.spawned': '⚡ Agent {name} launched in parallel{model}.',
|
|
148
|
-
'm.
|
|
169
|
+
'm.usageAsk': 'Usage: /ask [Name:] <question> [--model=m] — advisory only, no edits.',
|
|
170
|
+
'm.usageSpawn': 'Usage: /task [Name:] <task> [--model=m]',
|
|
149
171
|
'm.usageAt': 'Usage: @Agent <message> (or @all <message>)',
|
|
150
172
|
'm.broadcast': '✉ Instruction broadcast to all agents.',
|
|
151
173
|
'm.sent': '✉ Instruction sent to {target}.',
|
|
@@ -164,9 +186,10 @@ const en = {
|
|
|
164
186
|
'm.model': 'Session model: {pm} (change: /model [provider:]model · global defaults: /settings)',
|
|
165
187
|
'm.modelSet': 'Session model: {pm} (agents already running keep theirs)',
|
|
166
188
|
'm.noProvider': 'Unknown provider: {name} (configured: {list})',
|
|
167
|
-
'm.usageApprovals': 'Usage: /approvals <ask|auto>',
|
|
168
|
-
'm.approvals': '
|
|
169
|
-
'm.approvalsWarn': ' ⚠ shell commands now run without confirmation',
|
|
189
|
+
'm.usageApprovals': 'Usage: /approvals <ask|auto|auto-safe|yolo>',
|
|
190
|
+
'm.approvals': 'Shell approvals (session): {mode}',
|
|
191
|
+
'm.approvalsWarn': ' ⚠ safe shell commands now run without confirmation; risky commands still ask',
|
|
192
|
+
'm.approvalsYoloWarn': ' ⚠ YOLO mode: all shell commands are auto-approved',
|
|
170
193
|
'm.sound': 'Sound cues (session): {state}',
|
|
171
194
|
'm.usageSound': 'Sound: {state} — usage: /sound <on|off>',
|
|
172
195
|
'm.saved': '💾 Session saved.',
|
|
@@ -180,7 +203,7 @@ const en = {
|
|
|
180
203
|
'm.noConversation': 'No saved conversation for "{name}" in the restored session.',
|
|
181
204
|
'm.conflict': '⚠ {path}: repeated collisions between agents — consider arbitrating (@agent or /focus).',
|
|
182
205
|
'status.bar': '⚡ {agents} agent(s) · {active} active · {cost}',
|
|
183
|
-
'cmd.plan': '
|
|
206
|
+
'cmd.plan': 'Plan agent: presents its plan, edits only after your approval',
|
|
184
207
|
'cmd.issue': 'spawn an agent on a GitHub issue (needs the gh CLI)',
|
|
185
208
|
'cmd.undo': "revert the agent's last file change",
|
|
186
209
|
'cmd.commit': 'git-commit the files touched by an agent (or all)',
|
|
@@ -209,13 +232,20 @@ const en = {
|
|
|
209
232
|
'attach.placeholder': 'Message to {agent} (Enter to send, /quit to detach)…',
|
|
210
233
|
'attach.waiting': 'Waiting for agent {agent}… (is the main Parallel session running?)',
|
|
211
234
|
'attach.gone': 'Session ended — this terminal is detached.',
|
|
212
|
-
'attach.hint': '
|
|
235
|
+
'attach.hint': 'plain text steers this agent · /task creates a new agent · /ask asks · /plan plans · /quit detaches',
|
|
213
236
|
'grid.above': '▲ {n} agent(s) above — PgUp',
|
|
214
237
|
'grid.below': '▼ {n} agent(s) below — PgDn',
|
|
215
238
|
'm.nothing': 'Nothing to save yet.',
|
|
216
239
|
'm.usageKey': 'Usage: /key <API key>',
|
|
217
240
|
'm.keySaved': 'API key saved for provider {name} (~/.parallel/config.json)',
|
|
218
241
|
'm.cleared': 'Finished agents removed from display.',
|
|
242
|
+
'm.clearedN': 'Removed {n} finished agent(s) from display.',
|
|
243
|
+
'm.clearedNone': 'No finished agents to clear.',
|
|
244
|
+
'm.status': 'Status\n Model {pm}\n Approvals {approval}\n Agents {total} total / {active} active\n Changed files {changed}\n Session cost ${cost}',
|
|
245
|
+
'm.rawOn': 'Raw activity detail ON — raw agent logs visible in focus view.',
|
|
246
|
+
'm.rawOff': 'Raw activity detail OFF.',
|
|
247
|
+
'm.copyNone': 'No completed agent output to copy.',
|
|
248
|
+
'm.copyDone': 'Copied latest result from {name}.',
|
|
219
249
|
'm.unknown': 'Unknown command: {cmd} — type /help',
|
|
220
250
|
'm.imagesIgnored': 'Note: attached images are only supported when launching a new agent.',
|
|
221
251
|
'm.sessionRestored': '📂 Session from {date} restored.',
|
|
@@ -237,14 +267,14 @@ const en = {
|
|
|
237
267
|
'set.modelsFor': 'Models for {name} — select one to make it the global default, or type a new model name',
|
|
238
268
|
'set.makeDefault': 'make default',
|
|
239
269
|
'set.addModelName': 'model name exactly as written in the provider docs',
|
|
240
|
-
'set.approvals': 'Default
|
|
270
|
+
'set.approvals': 'Default shell approvals: {mode}',
|
|
241
271
|
'set.sound': 'Default sound: {state}',
|
|
242
272
|
'set.back': '← Back',
|
|
243
273
|
'set.saved': '✓ Saved to ~/.parallel/config.json',
|
|
244
274
|
'set.chooseProvider': 'Choose a provider',
|
|
245
275
|
'set.chooseModel': 'Model ({name}) — pick or type a name from the provider docs',
|
|
246
276
|
'sset.model': 'Session model: {pm}',
|
|
247
|
-
'sset.approvals': '
|
|
277
|
+
'sset.approvals': 'Shell approvals (session): {mode}',
|
|
248
278
|
'sset.sound': 'Sound (session): {state}',
|
|
249
279
|
'set.esc': 'Esc: close',
|
|
250
280
|
// agent questions (auto-run)
|
|
@@ -389,11 +419,32 @@ const fr = {
|
|
|
389
419
|
'help.l3': 'Les agents voient mutuellement leurs statuts et leurs diffs avant chaque action : ils co-éditent les mêmes fichiers sans se bloquer et sans casser le travail des autres.',
|
|
390
420
|
'help.states': "États : 🔨 travaille · 👂 écoute les autres agents (double bordure) · 🧠 réfléchit · ✋ attend ton approbation · ⏹ stop. Sons : 1 bip = agent lancé/terminé, 2 bips = approbation requise (/sound off pour couper).",
|
|
391
421
|
'help.keys': 'Esc : revenir à la vue agents · Tab : complétion · ↑/↓ : historique · Ctrl+V : coller une image',
|
|
392
|
-
'cmd.
|
|
422
|
+
'cmd.ask': 'Agent ask : répond et conseille sans modifier',
|
|
423
|
+
'cmd.task': 'Agent task : exécute, modifie, valide, résume',
|
|
393
424
|
'cmd.agents': 'Vue panneaux agents (temps réel)',
|
|
394
425
|
'cmd.board': 'Vue coordination : qui travaille où, notes',
|
|
395
426
|
'cmd.notes': 'Historique des notes inter-agents',
|
|
396
427
|
'cmd.diff': 'Modifications de fichiers (diffs en direct)',
|
|
428
|
+
'cmd.status': 'Afficher le statut de la session : modèle, agents, changements, coût',
|
|
429
|
+
'cmd.raw': 'Basculer le détail brut de l\'activité dans la vue focus',
|
|
430
|
+
'cmd.copy': 'Copier le dernier résultat d\'agent terminé',
|
|
431
|
+
'timeline.activity': 'Activité',
|
|
432
|
+
'timeline.raw': 'Activité brute',
|
|
433
|
+
'timeline.empty': 'Aucune activité pour le moment.',
|
|
434
|
+
'timeline.ran': 'Ran',
|
|
435
|
+
'timeline.readFiles': '{count} fichier(s) lu(s)',
|
|
436
|
+
'timeline.editedFiles': '{count} fichier(s) modifié(s)',
|
|
437
|
+
'timeline.wroteFiles': '{count} fichier(s) écrit(s)',
|
|
438
|
+
'timeline.searched': '{count} cible(s) recherchée(s)',
|
|
439
|
+
'timeline.listed': '{count} cible(s) listée(s)',
|
|
440
|
+
'timeline.hiddenLines': '+{count} ligne(s) masquée(s)',
|
|
441
|
+
'timeline.section.inspect': 'Inspection du contexte',
|
|
442
|
+
'timeline.section.change': 'Modification des fichiers',
|
|
443
|
+
'timeline.section.validate': 'Validation',
|
|
444
|
+
'timeline.section.publish': 'Publication',
|
|
445
|
+
'timeline.section.coordinate': 'Coordination',
|
|
446
|
+
'timeline.section.result': 'Résultat',
|
|
447
|
+
'timeline.section.other': 'Activité',
|
|
397
448
|
'cmd.send': 'Instruction à un agent (équivalent : @Agent message)',
|
|
398
449
|
'cmd.pause': 'Mettre en pause',
|
|
399
450
|
'cmd.resume': 'Reprendre',
|
|
@@ -404,7 +455,7 @@ const fr = {
|
|
|
404
455
|
'cmd.doctor': 'Vérifier provider/modèle/clef API et afficher les corrections',
|
|
405
456
|
'cmd.settings': 'Réglages globaux — providers, clefs API, langue, défauts (persistés)',
|
|
406
457
|
'cmd.ssettings': 'Réglages de session — modèle, approbations, son (cette session)',
|
|
407
|
-
'cmd.approvals': '
|
|
458
|
+
'cmd.approvals': 'Approbations shell : ask, auto-safe ou yolo (cette session)',
|
|
408
459
|
'cmd.sound': 'Repères sonores (cette session)',
|
|
409
460
|
'cmd.save': 'Sauvegarder la session maintenant (avec un nom optionnel)',
|
|
410
461
|
'cmd.focus': 'Met le focus sur un agent : le texte simple lui est envoyé, panneau pleine largeur',
|
|
@@ -414,7 +465,8 @@ const fr = {
|
|
|
414
465
|
'cmd.help': "Afficher l'aide",
|
|
415
466
|
'cmd.quit': 'Quitter (sauvegarde la session, arrête les agents)',
|
|
416
467
|
'm.spawned': '⚡ Agent {name} lancé en parallèle{model}.',
|
|
417
|
-
'm.
|
|
468
|
+
'm.usageAsk': 'Usage : /ask [Nom:] <question> [--model=m] — conseil uniquement, aucune modification.',
|
|
469
|
+
'm.usageSpawn': 'Usage : /task [Nom:] <tâche> [--model=m]',
|
|
418
470
|
'm.usageAt': 'Usage : @Agent <message> (ou @all <message>)',
|
|
419
471
|
'm.broadcast': '✉ Instruction diffusée à tous les agents.',
|
|
420
472
|
'm.sent': '✉ Instruction envoyée à {target}.',
|
|
@@ -433,9 +485,10 @@ const fr = {
|
|
|
433
485
|
'm.model': 'Modèle de session : {pm} (changer : /model [provider:]modèle · défauts globaux : /settings)',
|
|
434
486
|
'm.modelSet': 'Modèle de session : {pm} (les agents déjà lancés gardent le leur)',
|
|
435
487
|
'm.noProvider': 'Provider inconnu : {name} (configurés : {list})',
|
|
436
|
-
'm.usageApprovals': 'Usage : /approvals <ask|auto>',
|
|
437
|
-
'm.approvals': '
|
|
438
|
-
'm.approvalsWarn': ' ⚠ les commandes shell s’exécutent
|
|
488
|
+
'm.usageApprovals': 'Usage : /approvals <ask|auto|auto-safe|yolo>',
|
|
489
|
+
'm.approvals': 'Approbations shell (session) : {mode}',
|
|
490
|
+
'm.approvalsWarn': ' ⚠ les commandes shell sûres s’exécutent sans confirmation ; les commandes risquées demandent encore',
|
|
491
|
+
'm.approvalsYoloWarn': ' ⚠ mode YOLO : toutes les commandes shell sont auto-approuvées',
|
|
439
492
|
'm.sound': 'Repères sonores (session) : {state}',
|
|
440
493
|
'm.usageSound': 'Son : {state} — usage : /sound <on|off>',
|
|
441
494
|
'm.saved': '💾 Session sauvegardée.',
|
|
@@ -449,7 +502,7 @@ const fr = {
|
|
|
449
502
|
'm.noConversation': 'Aucune conversation sauvegardée pour « {name} » dans la session restaurée.',
|
|
450
503
|
'm.conflict': '⚠ {path} : collisions répétées entre agents — pensez à arbitrer (@agent ou /focus).',
|
|
451
504
|
'status.bar': '⚡ {agents} agent(s) · {active} actif(s) · {cost}',
|
|
452
|
-
'cmd.plan': "
|
|
505
|
+
'cmd.plan': "Agent plan : présente son plan, ne modifie qu'après votre accord",
|
|
453
506
|
'cmd.issue': 'lance un agent sur une issue GitHub (CLI gh requise)',
|
|
454
507
|
'cmd.undo': "annule la dernière modification de fichier de l'agent",
|
|
455
508
|
'cmd.commit': 'git-commit des fichiers touchés par un agent (ou tous)',
|
|
@@ -478,13 +531,20 @@ const fr = {
|
|
|
478
531
|
'attach.placeholder': 'Message à {agent} (Entrée pour envoyer, /quit pour détacher)…',
|
|
479
532
|
'attach.waiting': 'En attente de l’agent {agent}… (la session Parallel principale tourne-t-elle ?)',
|
|
480
533
|
'attach.gone': 'Session terminée — ce terminal est détaché.',
|
|
481
|
-
'attach.hint': '
|
|
534
|
+
'attach.hint': 'texte libre pilote cet agent · /task crée un nouvel agent · /ask questionne · /plan planifie · /quit détache',
|
|
482
535
|
'grid.above': '▲ {n} agent(s) au-dessus — PgUp',
|
|
483
536
|
'grid.below': '▼ {n} agent(s) en dessous — PgDn',
|
|
484
537
|
'm.nothing': 'Rien à sauvegarder pour le moment.',
|
|
485
538
|
'm.usageKey': 'Usage : /key <clef API>',
|
|
486
539
|
'm.keySaved': 'Clef API enregistrée pour le provider {name} (~/.parallel/config.json)',
|
|
487
540
|
'm.cleared': "Agents terminés retirés de l'affichage.",
|
|
541
|
+
'm.clearedN': "{n} agent(s) terminé(s) retiré(s) de l'affichage.",
|
|
542
|
+
'm.clearedNone': "Aucun agent terminé à retirer.",
|
|
543
|
+
'm.status': "Statut\n Modèle {pm}\n Approbations {approval}\n Agents {total} total / {active} actif(s)\n Fichiers modifiés {changed}\n Coût session ${cost}",
|
|
544
|
+
'm.rawOn': 'Détail brut activé — logs agents visibles dans la vue focus.',
|
|
545
|
+
'm.rawOff': 'Détail brut désactivé.',
|
|
546
|
+
'm.copyNone': "Aucun résultat d'agent à copier.",
|
|
547
|
+
'm.copyDone': 'Dernier résultat de {name} copié.',
|
|
488
548
|
'm.unknown': 'Commande inconnue : {cmd} — tape /help',
|
|
489
549
|
'm.imagesIgnored': "Note : les images jointes ne sont prises en compte qu'au lancement d'un nouvel agent.",
|
|
490
550
|
'm.sessionRestored': '📂 Session du {date} restaurée.',
|
|
@@ -505,14 +565,14 @@ const fr = {
|
|
|
505
565
|
'set.modelsFor': 'Modèles de {name} — sélectionne pour mettre en défaut global, ou tape un nouveau nom',
|
|
506
566
|
'set.makeDefault': 'mettre par défaut',
|
|
507
567
|
'set.addModelName': 'nom du modèle exactement comme dans la doc du provider',
|
|
508
|
-
'set.approvals': '
|
|
568
|
+
'set.approvals': 'Approbations shell par défaut : {mode}',
|
|
509
569
|
'set.sound': 'Son par défaut : {state}',
|
|
510
570
|
'set.back': '← Retour',
|
|
511
571
|
'set.saved': '✓ Enregistré dans ~/.parallel/config.json',
|
|
512
572
|
'set.chooseProvider': 'Choisis un provider',
|
|
513
573
|
'set.chooseModel': 'Modèle ({name}) — choisis ou tape un nom selon la doc du provider',
|
|
514
574
|
'sset.model': 'Modèle de session : {pm}',
|
|
515
|
-
'sset.approvals': 'Approbations (session) : {mode}',
|
|
575
|
+
'sset.approvals': 'Approbations shell (session) : {mode}',
|
|
516
576
|
'sset.sound': 'Son (session) : {state}',
|
|
517
577
|
'set.esc': 'Esc : fermer',
|
|
518
578
|
'q.title': '❓ QUESTION D’UN AGENT',
|
|
@@ -651,11 +711,32 @@ const es = {
|
|
|
651
711
|
'help.l3': 'Los agentes ven los estados y diffs de los demás antes de cada acción: co-editan los mismos archivos sin bloquearse y sin romper el trabajo ajeno.',
|
|
652
712
|
'help.states': 'Estados: 🔨 trabajando · 👂 escuchando a otros agentes (borde doble) · 🧠 pensando · ✋ esperando tu aprobación · ⏹ stop. Sonidos: 1 bip = agente lanzado/terminado, 2 bips = aprobación requerida (/sound off para silenciar).',
|
|
653
713
|
'help.keys': 'Esc: volver a la vista de agentes · Tab: autocompletar · ↑/↓: historial · Ctrl+V: pegar imagen',
|
|
654
|
-
'cmd.
|
|
714
|
+
'cmd.ask': 'Agente ask: responde y aconseja sin editar',
|
|
715
|
+
'cmd.task': 'Agente task: ejecuta, edita, valida y resume',
|
|
655
716
|
'cmd.agents': 'Vista de paneles de agentes (tiempo real)',
|
|
656
717
|
'cmd.board': 'Vista de coordinación: quién trabaja dónde, notas',
|
|
657
718
|
'cmd.notes': 'Historial de notas entre agentes',
|
|
658
719
|
'cmd.diff': 'Diffs de archivos en vivo',
|
|
720
|
+
'cmd.status': 'Mostrar estado de la sesión: modelo, agentes, cambios, coste',
|
|
721
|
+
'cmd.raw': 'Alternar detalle de actividad sin procesar en la vista focus',
|
|
722
|
+
'cmd.copy': 'Copiar el último resultado de agente completado',
|
|
723
|
+
'timeline.activity': 'Actividad',
|
|
724
|
+
'timeline.raw': 'Actividad sin procesar',
|
|
725
|
+
'timeline.empty': 'Aún no hay actividad.',
|
|
726
|
+
'timeline.ran': 'Ran',
|
|
727
|
+
'timeline.readFiles': '{count} archivo(s) leído(s)',
|
|
728
|
+
'timeline.editedFiles': '{count} archivo(s) editado(s)',
|
|
729
|
+
'timeline.wroteFiles': '{count} archivo(s) escrito(s)',
|
|
730
|
+
'timeline.searched': '{count} objetivo(s) buscado(s)',
|
|
731
|
+
'timeline.listed': '{count} objetivo(s) listado(s)',
|
|
732
|
+
'timeline.hiddenLines': '+{count} línea(s) oculta(s)',
|
|
733
|
+
'timeline.section.inspect': 'Inspeccionando contexto',
|
|
734
|
+
'timeline.section.change': 'Cambiando archivos',
|
|
735
|
+
'timeline.section.validate': 'Validando',
|
|
736
|
+
'timeline.section.publish': 'Publicando',
|
|
737
|
+
'timeline.section.coordinate': 'Coordinando',
|
|
738
|
+
'timeline.section.result': 'Resultado',
|
|
739
|
+
'timeline.section.other': 'Actividad',
|
|
659
740
|
'cmd.send': 'Instrucción a un agente (igual que: @Agente mensaje)',
|
|
660
741
|
'cmd.pause': 'Pausar',
|
|
661
742
|
'cmd.resume': 'Reanudar',
|
|
@@ -666,7 +747,7 @@ const es = {
|
|
|
666
747
|
'cmd.doctor': 'Comprobar proveedor/modelo/clave API y mostrar correcciones',
|
|
667
748
|
'cmd.settings': 'Ajustes globales — proveedores, claves API, idioma, valores por defecto (persistentes)',
|
|
668
749
|
'cmd.ssettings': 'Ajustes de sesión — modelo, aprobaciones, sonido (solo esta sesión)',
|
|
669
|
-
'cmd.approvals': '
|
|
750
|
+
'cmd.approvals': 'Aprobaciones shell: ask, auto-safe o yolo (esta sesión)',
|
|
670
751
|
'cmd.sound': 'Señales sonoras (esta sesión)',
|
|
671
752
|
'cmd.save': 'Guardar la sesión ahora (con un nombre opcional)',
|
|
672
753
|
'cmd.focus': 'Enfoca un agente: el texto simple se le envía, panel a ancho completo',
|
|
@@ -676,7 +757,8 @@ const es = {
|
|
|
676
757
|
'cmd.help': 'Mostrar la ayuda',
|
|
677
758
|
'cmd.quit': 'Salir (guarda la sesión, detiene los agentes)',
|
|
678
759
|
'm.spawned': '⚡ Agente {name} lanzado en paralelo{model}.',
|
|
679
|
-
'm.
|
|
760
|
+
'm.usageAsk': 'Uso: /ask [Nombre:] <pregunta> [--model=m] — solo asesoría, sin ediciones.',
|
|
761
|
+
'm.usageSpawn': 'Uso: /task [Nombre:] <tarea> [--model=m]',
|
|
680
762
|
'm.usageAt': 'Uso: @Agente <mensaje> (o @all <mensaje>)',
|
|
681
763
|
'm.broadcast': '✉ Instrucción difundida a todos los agentes.',
|
|
682
764
|
'm.sent': '✉ Instrucción enviada a {target}.',
|
|
@@ -695,9 +777,10 @@ const es = {
|
|
|
695
777
|
'm.model': 'Modelo de sesión: {pm} (cambiar: /model [proveedor:]modelo · valores globales: /settings)',
|
|
696
778
|
'm.modelSet': 'Modelo de sesión: {pm} (los agentes ya lanzados conservan el suyo)',
|
|
697
779
|
'm.noProvider': 'Proveedor desconocido: {name} (configurados: {list})',
|
|
698
|
-
'm.usageApprovals': 'Uso: /approvals <ask|auto>',
|
|
699
|
-
'm.approvals': '
|
|
700
|
-
'm.approvalsWarn': ' ⚠ los comandos shell se ejecutan
|
|
780
|
+
'm.usageApprovals': 'Uso: /approvals <ask|auto|auto-safe|yolo>',
|
|
781
|
+
'm.approvals': 'Aprobaciones shell (sesión): {mode}',
|
|
782
|
+
'm.approvalsWarn': ' ⚠ los comandos shell seguros se ejecutan sin confirmación; los riesgosos aún preguntan',
|
|
783
|
+
'm.approvalsYoloWarn': ' ⚠ modo YOLO: todos los comandos shell se autoaprueban',
|
|
701
784
|
'm.sound': 'Señales sonoras (sesión): {state}',
|
|
702
785
|
'm.usageSound': 'Sonido: {state} — uso: /sound <on|off>',
|
|
703
786
|
'm.saved': '💾 Sesión guardada.',
|
|
@@ -711,7 +794,7 @@ const es = {
|
|
|
711
794
|
'm.noConversation': 'No hay conversación guardada para "{name}" en la sesión restaurada.',
|
|
712
795
|
'm.conflict': '⚠ {path}: colisiones repetidas entre agentes — considera arbitrar (@agente o /focus).',
|
|
713
796
|
'status.bar': '⚡ {agents} agente(s) · {active} activo(s) · {cost}',
|
|
714
|
-
'cmd.plan': '
|
|
797
|
+
'cmd.plan': 'Agente plan: presenta su plan, solo edita tras tu aprobación',
|
|
715
798
|
'cmd.issue': 'lanza un agente sobre una issue de GitHub (requiere la CLI gh)',
|
|
716
799
|
'cmd.undo': 'revierte el último cambio de archivo del agente',
|
|
717
800
|
'cmd.commit': 'git-commit de los archivos tocados por un agente (o todos)',
|
|
@@ -740,13 +823,20 @@ const es = {
|
|
|
740
823
|
'attach.placeholder': 'Mensaje a {agent} (Enter para enviar, /quit para desconectar)…',
|
|
741
824
|
'attach.waiting': 'Esperando al agente {agent}… (¿está corriendo la sesión principal de Parallel?)',
|
|
742
825
|
'attach.gone': 'Sesión terminada — esta terminal está desconectada.',
|
|
743
|
-
'attach.hint': '
|
|
826
|
+
'attach.hint': 'texto libre dirige a este agente · /task crea un agente nuevo · /ask pregunta · /plan planifica · /quit desconecta',
|
|
744
827
|
'grid.above': '▲ {n} agente(s) arriba — PgUp',
|
|
745
828
|
'grid.below': '▼ {n} agente(s) abajo — PgDn',
|
|
746
829
|
'm.nothing': 'Nada que guardar por ahora.',
|
|
747
830
|
'm.usageKey': 'Uso: /key <clave API>',
|
|
748
831
|
'm.keySaved': 'Clave API guardada para el proveedor {name} (~/.parallel/config.json)',
|
|
749
832
|
'm.cleared': 'Agentes terminados quitados de la pantalla.',
|
|
833
|
+
'm.clearedN': '{n} agente(s) terminado(s) quitado(s) de la pantalla.',
|
|
834
|
+
'm.clearedNone': 'No hay agentes terminados que quitar.',
|
|
835
|
+
'm.status': 'Estado\n Modelo {pm}\n Aprobaciones {approval}\n Agentes {total} total / {active} activo(s)\n Archivos cambiados {changed}\n Coste sesión ${cost}',
|
|
836
|
+
'm.rawOn': 'Detalle de actividad activado — logs visibles en vista focus.',
|
|
837
|
+
'm.rawOff': 'Detalle de actividad desactivado.',
|
|
838
|
+
'm.copyNone': 'No hay resultado de agente que copiar.',
|
|
839
|
+
'm.copyDone': 'Último resultado de {name} copiado.',
|
|
750
840
|
'm.unknown': 'Comando desconocido: {cmd} — escribe /help',
|
|
751
841
|
'm.imagesIgnored': 'Nota: las imágenes adjuntas solo se tienen en cuenta al lanzar un agente nuevo.',
|
|
752
842
|
'm.sessionRestored': '📂 Sesión del {date} restaurada.',
|
|
@@ -767,14 +857,14 @@ const es = {
|
|
|
767
857
|
'set.modelsFor': 'Modelos de {name} — selecciona uno como defecto global, o escribe un nombre nuevo',
|
|
768
858
|
'set.makeDefault': 'hacer predeterminado',
|
|
769
859
|
'set.addModelName': 'nombre del modelo exactamente como en la doc del proveedor',
|
|
770
|
-
'set.approvals': '
|
|
860
|
+
'set.approvals': 'Aprobaciones shell por defecto: {mode}',
|
|
771
861
|
'set.sound': 'Sonido por defecto: {state}',
|
|
772
862
|
'set.back': '← Volver',
|
|
773
863
|
'set.saved': '✓ Guardado en ~/.parallel/config.json',
|
|
774
864
|
'set.chooseProvider': 'Elige un proveedor',
|
|
775
865
|
'set.chooseModel': 'Modelo ({name}) — elige o escribe un nombre según la doc del proveedor',
|
|
776
866
|
'sset.model': 'Modelo de sesión: {pm}',
|
|
777
|
-
'sset.approvals': 'Aprobaciones (sesión): {mode}',
|
|
867
|
+
'sset.approvals': 'Aprobaciones shell (sesión): {mode}',
|
|
778
868
|
'sset.sound': 'Sonido (sesión): {state}',
|
|
779
869
|
'set.esc': 'Esc: cerrar',
|
|
780
870
|
'q.title': '❓ PREGUNTA DE UN AGENTE',
|
|
@@ -913,11 +1003,32 @@ const zh = {
|
|
|
913
1003
|
'help.l3': '每次行动前,智能体都能看到彼此的状态和差异:它们共同编辑同一批文件,互不阻塞,也不破坏彼此的工作。',
|
|
914
1004
|
'help.states': '状态:🔨 工作中 · 👂 倾听其他智能体(双边框)· 🧠 思考中 · ✋ 等待你的批准 · ⏹ 停止。声音:1 声 = 智能体启动/完成,2 声 = 需要批准(/sound off 静音)。',
|
|
915
1005
|
'help.keys': 'Esc:返回智能体视图 · Tab:补全 · ↑/↓:历史 · Ctrl+V:粘贴图片',
|
|
916
|
-
'cmd.
|
|
1006
|
+
'cmd.ask': 'Ask 智能体:只回答和建议,不编辑',
|
|
1007
|
+
'cmd.task': 'Task 智能体:执行、编辑、验证并总结',
|
|
917
1008
|
'cmd.agents': '智能体面板视图(实时)',
|
|
918
1009
|
'cmd.board': '协调视图:谁在哪里工作、便签',
|
|
919
1010
|
'cmd.notes': '智能体间便签历史',
|
|
920
1011
|
'cmd.diff': '实时文件差异',
|
|
1012
|
+
'cmd.status': '显示会话状态:模型、智能体、更改、费用',
|
|
1013
|
+
'cmd.raw': '在焦点视图中切换原始活动详情',
|
|
1014
|
+
'cmd.copy': '复制最新完成的智能体结果',
|
|
1015
|
+
'timeline.activity': '活动',
|
|
1016
|
+
'timeline.raw': '原始活动',
|
|
1017
|
+
'timeline.empty': '暂无活动。',
|
|
1018
|
+
'timeline.ran': 'Ran',
|
|
1019
|
+
'timeline.readFiles': '读取 {count} 个文件',
|
|
1020
|
+
'timeline.editedFiles': '编辑 {count} 个文件',
|
|
1021
|
+
'timeline.wroteFiles': '写入 {count} 个文件',
|
|
1022
|
+
'timeline.searched': '搜索 {count} 个目标',
|
|
1023
|
+
'timeline.listed': '列出 {count} 个目标',
|
|
1024
|
+
'timeline.hiddenLines': '+{count} 行已隐藏',
|
|
1025
|
+
'timeline.section.inspect': '检查上下文',
|
|
1026
|
+
'timeline.section.change': '修改文件',
|
|
1027
|
+
'timeline.section.validate': '验证',
|
|
1028
|
+
'timeline.section.publish': '发布',
|
|
1029
|
+
'timeline.section.coordinate': '协调',
|
|
1030
|
+
'timeline.section.result': '结果',
|
|
1031
|
+
'timeline.section.other': '活动',
|
|
921
1032
|
'cmd.send': '向某个智能体发指令(等同于:@智能体 消息)',
|
|
922
1033
|
'cmd.pause': '暂停',
|
|
923
1034
|
'cmd.resume': '恢复',
|
|
@@ -928,7 +1039,7 @@ const zh = {
|
|
|
928
1039
|
'cmd.doctor': '检查提供商/模型/API 密钥配置并显示修复提示',
|
|
929
1040
|
'cmd.settings': '全局设置 — 提供商、API 密钥、语言、默认值(持久化)',
|
|
930
1041
|
'cmd.ssettings': '会话设置 — 模型、批准、声音(仅本会话)',
|
|
931
|
-
'cmd.approvals': 'Shell
|
|
1042
|
+
'cmd.approvals': 'Shell 批准:ask、auto-safe 或 yolo(本会话)',
|
|
932
1043
|
'cmd.sound': '声音提示(本会话)',
|
|
933
1044
|
'cmd.save': '立即保存会话(可附加名称)',
|
|
934
1045
|
'cmd.focus': '聚焦某个代理:普通文本直接发给它,面板全宽显示',
|
|
@@ -938,7 +1049,8 @@ const zh = {
|
|
|
938
1049
|
'cmd.help': '显示帮助',
|
|
939
1050
|
'cmd.quit': '退出(保存会话,停止智能体)',
|
|
940
1051
|
'm.spawned': '⚡ 智能体 {name} 已并行启动{model}。',
|
|
941
|
-
'm.
|
|
1052
|
+
'm.usageAsk': '用法:/ask [名称:] <问题> [--model=m] — 仅建议,不修改。',
|
|
1053
|
+
'm.usageSpawn': '用法:/task [名称:] <任务> [--model=m]',
|
|
942
1054
|
'm.usageAt': '用法:@智能体 <消息>(或 @all <消息>)',
|
|
943
1055
|
'm.broadcast': '✉ 指令已广播给所有智能体。',
|
|
944
1056
|
'm.sent': '✉ 指令已发送给 {target}。',
|
|
@@ -957,9 +1069,10 @@ const zh = {
|
|
|
957
1069
|
'm.model': '会话模型:{pm}(更改:/model [提供商:]模型 · 全局默认:/settings)',
|
|
958
1070
|
'm.modelSet': '会话模型:{pm}(已启动的智能体保持原模型)',
|
|
959
1071
|
'm.noProvider': '未知提供商:{name}(已配置:{list})',
|
|
960
|
-
'm.usageApprovals': '用法:/approvals <ask|auto>',
|
|
961
|
-
'm.approvals': '
|
|
962
|
-
'm.approvalsWarn': ' ⚠ Shell
|
|
1072
|
+
'm.usageApprovals': '用法:/approvals <ask|auto|auto-safe|yolo>',
|
|
1073
|
+
'm.approvals': 'Shell 批准(会话):{mode}',
|
|
1074
|
+
'm.approvalsWarn': ' ⚠ 安全 Shell 命令无需确认;高风险命令仍会询问',
|
|
1075
|
+
'm.approvalsYoloWarn': ' ⚠ YOLO 模式:所有 Shell 命令都会自动批准',
|
|
963
1076
|
'm.sound': '声音提示(会话):{state}',
|
|
964
1077
|
'm.usageSound': '声音:{state} — 用法:/sound <on|off>',
|
|
965
1078
|
'm.saved': '💾 会话已保存。',
|
|
@@ -973,7 +1086,7 @@ const zh = {
|
|
|
973
1086
|
'm.noConversation': '恢复的会话中没有「{name}」的已保存对话。',
|
|
974
1087
|
'm.conflict': '⚠ {path}:代理之间反复冲突 — 建议你介入仲裁(@代理 或 /focus)。',
|
|
975
1088
|
'status.bar': '⚡ {agents} 个代理 · {active} 个活跃 · {cost}',
|
|
976
|
-
'cmd.plan': '
|
|
1089
|
+
'cmd.plan': 'Plan 智能体:先给出计划,你批准后才开始修改',
|
|
977
1090
|
'cmd.issue': '基于 GitHub issue 启动代理(需要 gh CLI)',
|
|
978
1091
|
'cmd.undo': '撤销该代理最近一次文件修改',
|
|
979
1092
|
'cmd.commit': '把某个代理(或全部)改动的文件做 git 提交',
|
|
@@ -1002,13 +1115,20 @@ const zh = {
|
|
|
1002
1115
|
'attach.placeholder': '发给 {agent} 的消息(回车发送,/quit 断开)…',
|
|
1003
1116
|
'attach.waiting': '等待代理 {agent}…(Parallel 主会话在运行吗?)',
|
|
1004
1117
|
'attach.gone': '会话已结束 — 此终端已断开。',
|
|
1005
|
-
'attach.hint': '
|
|
1118
|
+
'attach.hint': '直接输入文字可指挥此代理 · /task 创建新代理 · /ask 提问 · /plan 规划 · /quit 断开',
|
|
1006
1119
|
'grid.above': '▲ 上方还有 {n} 个代理 — PgUp',
|
|
1007
1120
|
'grid.below': '▼ 下方还有 {n} 个代理 — PgDn',
|
|
1008
1121
|
'm.nothing': '暂无可保存的内容。',
|
|
1009
1122
|
'm.usageKey': '用法:/key <API 密钥>',
|
|
1010
1123
|
'm.keySaved': '已为提供商 {name} 保存 API 密钥(~/.parallel/config.json)',
|
|
1011
1124
|
'm.cleared': '已从显示中移除完成的智能体。',
|
|
1125
|
+
'm.clearedN': '已从显示中移除 {n} 个完成的智能体。',
|
|
1126
|
+
'm.clearedNone': '没有可移除的已完成智能体。',
|
|
1127
|
+
'm.status': '状态\n 模型 {pm}\n 批准 {approval}\n 智能体 {total} 个总计 / {active} 个活跃\n 已更改文件 {changed}\n 会话费用 ${cost}',
|
|
1128
|
+
'm.rawOn': '原始活动详情已开启 — 焦点视图中可查看原始智能体日志。',
|
|
1129
|
+
'm.rawOff': '原始活动详情已关闭。',
|
|
1130
|
+
'm.copyNone': '没有可复制的已完成智能体输出。',
|
|
1131
|
+
'm.copyDone': '已复制 {name} 的最新结果。',
|
|
1012
1132
|
'm.unknown': '未知命令:{cmd} — 输入 /help',
|
|
1013
1133
|
'm.imagesIgnored': '注意:附加的图片仅在启动新智能体时生效。',
|
|
1014
1134
|
'm.sessionRestored': '📂 已恢复 {date} 的会话。',
|
|
@@ -1029,14 +1149,14 @@ const zh = {
|
|
|
1029
1149
|
'set.modelsFor': '{name} 的模型 — 选择一个作为全局默认,或输入新模型名称',
|
|
1030
1150
|
'set.makeDefault': '设为默认',
|
|
1031
1151
|
'set.addModelName': '模型名称,需与提供商文档完全一致',
|
|
1032
|
-
'set.approvals': '
|
|
1152
|
+
'set.approvals': '默认 Shell 批准:{mode}',
|
|
1033
1153
|
'set.sound': '默认声音:{state}',
|
|
1034
1154
|
'set.back': '← 返回',
|
|
1035
1155
|
'set.saved': '✓ 已保存到 ~/.parallel/config.json',
|
|
1036
1156
|
'set.chooseProvider': '选择提供商',
|
|
1037
1157
|
'set.chooseModel': '模型({name})— 选择或按提供商文档输入名称',
|
|
1038
1158
|
'sset.model': '会话模型:{pm}',
|
|
1039
|
-
'sset.approvals': '批准(会话):{mode}',
|
|
1159
|
+
'sset.approvals': 'Shell 批准(会话):{mode}',
|
|
1040
1160
|
'sset.sound': '声音(会话):{state}',
|
|
1041
1161
|
'set.esc': 'Esc:关闭',
|
|
1042
1162
|
'q.title': '❓ 智能体提问',
|
package/dist/index.js
CHANGED
|
@@ -101,8 +101,8 @@ if (headless) {
|
|
|
101
101
|
if (config.language)
|
|
102
102
|
setLang(config.language);
|
|
103
103
|
const ctl = new Controller(config, process.cwd());
|
|
104
|
-
// No human in the loop: commands are auto-approved
|
|
105
|
-
ctl.setSessionApprovalMode('
|
|
104
|
+
// No human in the loop: commands are auto-approved.
|
|
105
|
+
ctl.setSessionApprovalMode('yolo');
|
|
106
106
|
const provider = ctl.sessionProvider();
|
|
107
107
|
if (!provider || !provider.apiKey) {
|
|
108
108
|
console.error('Headless mode needs a configured provider + API key. Run `parallel` interactively once, or set PARALLEL_API_KEY.');
|
|
@@ -177,9 +177,11 @@ const useAltScreen = process.stdout.isTTY && process.env.PARALLEL_NO_ALT_SCREEN
|
|
|
177
177
|
const restoreTerminal = () => {
|
|
178
178
|
if (!useAltScreen)
|
|
179
179
|
return;
|
|
180
|
+
// Show cursor + leave alternate screen.
|
|
180
181
|
process.stdout.write('\x1b[?25h\x1b[?1049l');
|
|
181
182
|
};
|
|
182
183
|
if (useAltScreen) {
|
|
184
|
+
// Alternate screen + clear.
|
|
183
185
|
process.stdout.write('\x1b[?1049h\x1b[2J\x1b[3J\x1b[H');
|
|
184
186
|
process.once('exit', restoreTerminal);
|
|
185
187
|
process.once('SIGINT', () => {
|
package/dist/server.js
CHANGED
|
@@ -18,6 +18,7 @@ export function startSessionServer(ctl) {
|
|
|
18
18
|
}
|
|
19
19
|
const clients = new Set();
|
|
20
20
|
const infoFor = (ref) => ctl.board.getAgentByName(ref);
|
|
21
|
+
const spawnMode = (mode) => (mode === 'ask' || mode === 'plan' || mode === 'task' ? mode : 'task');
|
|
21
22
|
const send = (socket, msg) => {
|
|
22
23
|
try {
|
|
23
24
|
socket.write(JSON.stringify(msg) + '\n');
|
|
@@ -112,7 +113,7 @@ export function startSessionServer(ctl) {
|
|
|
112
113
|
// its own dedicated terminal then opens automatically.
|
|
113
114
|
const task = msg.text.trim();
|
|
114
115
|
if (task)
|
|
115
|
-
ctl.spawnAgent(task);
|
|
116
|
+
ctl.spawnAgent(task, undefined, undefined, undefined, undefined, undefined, spawnMode(msg.mode));
|
|
116
117
|
}
|
|
117
118
|
}
|
|
118
119
|
});
|