@monster-orange/den 0.4.15 → 0.4.16
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/CHANGELOG.md +67 -0
- package/README.md +7 -7
- package/docs/distributions.md +82 -11
- package/package.json +1 -1
- package/src/shared/agents/conversations.ts +122 -4
- package/src/shared/agents/den-claude.ts +13 -1
- package/src/shared/agents/records.ts +19 -0
- package/src/shared/agents/runtime.ts +5 -0
- package/src/shared/github-app.ts +7 -0
- package/src/ui/cli/agent-ops.ts +297 -1
- package/src/ui/cli/agents-command.ts +67 -3
- package/src/ui/server/agent-routes.ts +89 -2
- package/src/ui/server/github-routes.ts +1 -1
- package/src/ui/server/index.ts +22 -5
- package/src/ui/server/public/agents-page.js +287 -26
- package/src/ui/server/public/agents.html +1 -0
- package/src/ui/server/public/error-page.js +70 -15
- package/src/ui/server/public/error.html +18 -0
- package/src/ui/server/public/i18n/es.js +36 -5
- package/src/ui/server/public/i18n/ja.js +36 -5
- package/src/ui/server/public/persona-ui.css +11 -0
- package/src/ui/server/public/shell.js +35 -5
- package/src/ui/server/route-classes.ts +6 -0
- package/src/ui/server/session-routes.ts +3 -0
|
@@ -265,6 +265,24 @@
|
|
|
265
265
|
color: var(--text);
|
|
266
266
|
font-weight: 600;
|
|
267
267
|
}
|
|
268
|
+
/* SEC-2a-UX: a step already done (the owner is linked). */
|
|
269
|
+
ol.den-steps li.done::marker {
|
|
270
|
+
content: "\2713 ";
|
|
271
|
+
color: var(--ok, var(--text));
|
|
272
|
+
}
|
|
273
|
+
ol.den-steps li.done > p:first-child {
|
|
274
|
+
color: var(--muted);
|
|
275
|
+
}
|
|
276
|
+
ol.den-steps code {
|
|
277
|
+
overflow-wrap: anywhere;
|
|
278
|
+
}
|
|
279
|
+
p.den-gh-note {
|
|
280
|
+
margin-top: 8px;
|
|
281
|
+
}
|
|
282
|
+
p.den-gh-owner {
|
|
283
|
+
color: var(--text);
|
|
284
|
+
font-weight: 600;
|
|
285
|
+
}
|
|
268
286
|
details.den-other {
|
|
269
287
|
margin: 0 0 16px;
|
|
270
288
|
}
|
|
@@ -254,12 +254,18 @@
|
|
|
254
254
|
"err.signin.title": "Inicia sesión en {name}",
|
|
255
255
|
"err.signin.where":
|
|
256
256
|
"Estás abriendo {name} desde otro ordenador. {name} corre en {host}, así que necesita saber que eres tú.",
|
|
257
|
-
"err.signin.
|
|
258
|
-
"
|
|
259
|
-
"err.signin.
|
|
260
|
-
"
|
|
257
|
+
"err.signin.ghStep1":
|
|
258
|
+
"En {host}, ejecuta {cmd}, o usa Ajustes › Acceso allí.",
|
|
259
|
+
"err.signin.ghStep2":
|
|
260
|
+
"Muestra un código. Introdúcelo en github.com/login/device y apruébalo.",
|
|
261
|
+
"err.signin.ghStep3":
|
|
262
|
+
"Después vuelve aquí y pulsa Iniciar sesión con GitHub, con la misma cuenta de GitHub.",
|
|
263
|
+
"err.signin.ghOwner": "Propietario: @{login}",
|
|
264
|
+
"err.signin.ghOnly":
|
|
265
|
+
"Solo la cuenta de GitHub del propietario puede iniciar sesión así. Para cualquier otra persona, usa «Aprueba este ordenador».",
|
|
266
|
+
"err.signin.ghLearn": "Más información",
|
|
261
267
|
"err.signin.githubRefused":
|
|
262
|
-
"@{login} no es el propietario de este {name}.
|
|
268
|
+
"@{login} no es el propietario de este {name}. Solo la cuenta del propietario puede usar Iniciar sesión con GitHub. Usa «Aprueba este ordenador» en su lugar.",
|
|
263
269
|
"err.signin.approveOr": "O aprueba este ordenador",
|
|
264
270
|
"err.signin.approve": "Aprueba este ordenador",
|
|
265
271
|
"err.signin.step1": "En {host} (no en este ordenador), ejecuta:",
|
|
@@ -489,6 +495,30 @@
|
|
|
489
495
|
"ag.bring.agent": "Agente {id}",
|
|
490
496
|
"ag.bring.note":
|
|
491
497
|
"La continúa en la carpeta donde se ejecutó, con las herramientas y protecciones de Den desde ahora. Sigue en ejecución si cierras el panel. Ciérrala antes en cualquier otro terminal: Den solo la ve abierta si se escribió en el último minuto.",
|
|
498
|
+
"ag.keep.model": "Mantiene {m} de la conversación.",
|
|
499
|
+
"ag.keep.modelNew": "Usa {m} a partir de ahora.",
|
|
500
|
+
"ag.keep.from":
|
|
501
|
+
"A partir de ahora trabaja como {p}: su rol, sus permisos ({mode}), las herramientas y protecciones de Den. Su historial se mantiene.",
|
|
502
|
+
"ag.keep.lost":
|
|
503
|
+
"No tendrá: {s}. Den ejecuta los agentes solo con las herramientas de Den.",
|
|
504
|
+
"ag.keep.opt": "Mantener {m}",
|
|
505
|
+
"ag.keep.optNone": "Mantener el modelo que usa",
|
|
506
|
+
"ag.keep.advNote":
|
|
507
|
+
"El modelo que usa se mantiene salvo que elijas otro aquí. Los permisos vienen de la persona.",
|
|
508
|
+
"ag.pc.item": "Cambiar persona…",
|
|
509
|
+
"ag.pc.title": "Cambiar la persona de {id}",
|
|
510
|
+
"ag.pc.note":
|
|
511
|
+
"Den lo detiene y reanuda la misma conversación con la nueva persona. Su id, nombre, carpeta y pestaña se mantienen.",
|
|
512
|
+
"ag.pc.go": "Cambiar persona",
|
|
513
|
+
"ag.pc.going": "Cambiando…",
|
|
514
|
+
"ag.pc.current": "actual",
|
|
515
|
+
"ag.pc.busy":
|
|
516
|
+
"Está trabajando. ¿Cambiar después de este turno o detenerlo ahora?",
|
|
517
|
+
"ag.pc.after": "Después de este turno",
|
|
518
|
+
"ag.pc.now": "Detenerlo ahora",
|
|
519
|
+
"ag.pc.done": "{id} ahora es {p}",
|
|
520
|
+
"ag.pc.pending": "{id} pasará a ser {p} cuando termine este turno",
|
|
521
|
+
"ag.more": "Más para {id}",
|
|
492
522
|
"ag.bring.go": "Traer",
|
|
493
523
|
"ag.bring.going": "Trayendo…",
|
|
494
524
|
"ag.bring.done": "Traída como {id}",
|
|
@@ -637,6 +667,7 @@
|
|
|
637
667
|
"Su token fue revocado (web logout --all): detenlo y reanúdalo, o inícialo de nuevo, para darle uno nuevo",
|
|
638
668
|
"ag.ended":
|
|
639
669
|
"Esta sesión ha terminado. Su registro se queda hasta que se reanude o se elimine.",
|
|
670
|
+
"ag.switched": "Cambiado a {p}",
|
|
640
671
|
"ag.exitedLine": "[la sesión terminó{code}]",
|
|
641
672
|
"ag.lost": "[desconectado: {why}]",
|
|
642
673
|
"ag.reconnect": "Reconectar",
|
|
@@ -242,12 +242,18 @@
|
|
|
242
242
|
"err.signin.title": "{name} にサインイン",
|
|
243
243
|
"err.signin.where":
|
|
244
244
|
"別のコンピューターから {name} を開いています。{name} は {host} で動いているため、あなた本人であることを確認する必要があります。",
|
|
245
|
-
"err.signin.
|
|
246
|
-
"
|
|
247
|
-
"err.signin.
|
|
248
|
-
"
|
|
245
|
+
"err.signin.ghStep1":
|
|
246
|
+
"{host} で {cmd} を実行するか、そちらで 設定 › アクセス を使います。",
|
|
247
|
+
"err.signin.ghStep2":
|
|
248
|
+
"コードが表示されます。github.com/login/device で入力して承認します。",
|
|
249
|
+
"err.signin.ghStep3":
|
|
250
|
+
"ここに戻り、同じ GitHub アカウントで「GitHub でサインイン」を押します。",
|
|
251
|
+
"err.signin.ghOwner": "オーナー: @{login}",
|
|
252
|
+
"err.signin.ghOnly":
|
|
253
|
+
"この方法でサインインできるのはオーナーの GitHub アカウントだけです。それ以外の人は「このコンピューターを承認」を使ってください。",
|
|
254
|
+
"err.signin.ghLearn": "詳しく見る",
|
|
249
255
|
"err.signin.githubRefused":
|
|
250
|
-
"@{login} はこの {name}
|
|
256
|
+
"@{login} はこの {name} のオーナーではありません。GitHub でサインインを使えるのはオーナーのアカウントだけです。代わりに「このコンピューターを承認」を使ってください。",
|
|
251
257
|
"err.signin.approveOr": "または、このコンピューターを承認",
|
|
252
258
|
"err.signin.approve": "このコンピューターを承認",
|
|
253
259
|
"err.signin.step1":
|
|
@@ -473,6 +479,30 @@
|
|
|
473
479
|
"ag.bring.agent": "エージェント {id}",
|
|
474
480
|
"ag.bring.note":
|
|
475
481
|
"実行していたフォルダーで続けます。ここからは Den のツールとガードが適用されます。ペインを閉じても実行は続きます。先にほかのターミナルで閉じてください。Den が開いていると判断できるのは、直近 1 分以内に書き込まれた会話だけです。",
|
|
482
|
+
"ag.keep.model": "会話の {m} をそのまま使います。",
|
|
483
|
+
"ag.keep.modelNew": "これからは {m} で動きます。",
|
|
484
|
+
"ag.keep.from":
|
|
485
|
+
"これからは {p} として働きます: その役割、権限({mode})、Den のツールとガード。履歴はそのまま残ります。",
|
|
486
|
+
"ag.keep.lost":
|
|
487
|
+
"使えなくなるもの: {s}。Den はエージェントを Den のツールだけで動かします。",
|
|
488
|
+
"ag.keep.opt": "{m} のまま",
|
|
489
|
+
"ag.keep.optNone": "今のモデルのまま",
|
|
490
|
+
"ag.keep.advNote":
|
|
491
|
+
"ここで別のモデルを選ばない限り、今のモデルのままです。権限はペルソナから来ます。",
|
|
492
|
+
"ag.pc.item": "ペルソナを変更…",
|
|
493
|
+
"ag.pc.title": "{id} のペルソナを変更",
|
|
494
|
+
"ag.pc.note":
|
|
495
|
+
"Den はいったん停止し、同じ会話を新しいペルソナで再開します。ID、名前、フォルダー、タブはそのままです。",
|
|
496
|
+
"ag.pc.go": "ペルソナを変更",
|
|
497
|
+
"ag.pc.going": "変更中…",
|
|
498
|
+
"ag.pc.current": "現在",
|
|
499
|
+
"ag.pc.busy":
|
|
500
|
+
"作業中です。このターンの後に変更しますか、それとも今すぐ停止しますか?",
|
|
501
|
+
"ag.pc.after": "このターンの後",
|
|
502
|
+
"ag.pc.now": "今すぐ停止",
|
|
503
|
+
"ag.pc.done": "{id} は {p} になりました",
|
|
504
|
+
"ag.pc.pending": "このターンが終わると {id} は {p} になります",
|
|
505
|
+
"ag.more": "{id} のその他の操作",
|
|
476
506
|
"ag.bring.go": "取り込む",
|
|
477
507
|
"ag.bring.going": "取り込み中…",
|
|
478
508
|
"ag.bring.done": "{id} として取り込みました",
|
|
@@ -621,6 +651,7 @@
|
|
|
621
651
|
"ag.revokedTip":
|
|
622
652
|
"トークンが失効しました(web logout --all)。新しいトークンを渡すには停止して再開するか、もう一度開始してください",
|
|
623
653
|
"ag.ended": "このセッションは終了しました。記録は再開か削除まで残ります。",
|
|
654
|
+
"ag.switched": "{p} に切り替えました",
|
|
624
655
|
"ag.exitedLine": "[セッションが終了しました{code}]",
|
|
625
656
|
"ag.lost": "[切断: {why}]",
|
|
626
657
|
"ag.reconnect": "再接続",
|
|
@@ -181,6 +181,17 @@ dialog.pe-dlg::backdrop {
|
|
|
181
181
|
.helpl.warn {
|
|
182
182
|
color: var(--warn);
|
|
183
183
|
}
|
|
184
|
+
/* AG-17.1c, AG-18: what a persona changes, under the list. */
|
|
185
|
+
.den-keep {
|
|
186
|
+
margin: 8px 0 0;
|
|
187
|
+
padding-left: 18px;
|
|
188
|
+
font-size: 12px;
|
|
189
|
+
line-height: 1.45;
|
|
190
|
+
color: var(--muted);
|
|
191
|
+
}
|
|
192
|
+
.den-keep li + li {
|
|
193
|
+
margin-top: 2px;
|
|
194
|
+
}
|
|
184
195
|
.faint {
|
|
185
196
|
color: var(--faint);
|
|
186
197
|
}
|
|
@@ -366,12 +366,18 @@
|
|
|
366
366
|
"err.signin.title": "Sign in to {name}",
|
|
367
367
|
"err.signin.where":
|
|
368
368
|
"You're opening {name} from another computer. {name} runs on {host}, so it needs to know this is you.",
|
|
369
|
-
"err.signin.
|
|
370
|
-
"
|
|
371
|
-
"err.signin.
|
|
372
|
-
"
|
|
369
|
+
"err.signin.ghStep1":
|
|
370
|
+
"On {host}, run {cmd}, or use Settings › Access there.",
|
|
371
|
+
"err.signin.ghStep2":
|
|
372
|
+
"It shows a code. Enter it at github.com/login/device and approve.",
|
|
373
|
+
"err.signin.ghStep3":
|
|
374
|
+
"Then come back here and press Sign in with GitHub, with the same GitHub account.",
|
|
375
|
+
"err.signin.ghOwner": "Owner: @{login}",
|
|
376
|
+
"err.signin.ghOnly":
|
|
377
|
+
"Only the owner's GitHub account can sign in this way. For anyone else, use Approve this computer.",
|
|
378
|
+
"err.signin.ghLearn": "Learn more",
|
|
373
379
|
"err.signin.githubRefused":
|
|
374
|
-
"@{login} isn't the owner of this {name}.
|
|
380
|
+
"@{login} isn't the owner of this {name}. Only the owner's account can use Sign in with GitHub. Use Approve this computer instead.",
|
|
375
381
|
"err.signin.approveOr": "Or approve this computer",
|
|
376
382
|
"err.signin.approve": "Approve this computer",
|
|
377
383
|
"err.signin.step1": "On {host} (not this computer), run:",
|
|
@@ -599,6 +605,29 @@
|
|
|
599
605
|
"ag.bring.agent": "Agent {id}",
|
|
600
606
|
"ag.bring.note":
|
|
601
607
|
"Continues it in the folder it ran in, with Den's tools and guards from now on. It keeps running if you close the pane. Close it in any other terminal first: Den only sees a conversation as open if it was written in the last minute.",
|
|
608
|
+
"ag.keep.model": "Keeps {m} from the conversation.",
|
|
609
|
+
"ag.keep.modelNew": "Runs on {m} from now on.",
|
|
610
|
+
"ag.keep.from":
|
|
611
|
+
"From now on it works as {p}: its role, its permissions ({mode}), Den's tools and guards. Its history stays.",
|
|
612
|
+
"ag.keep.lost":
|
|
613
|
+
"It won't have: {s}. Den runs agents with Den's tools only.",
|
|
614
|
+
"ag.keep.opt": "Keep {m}",
|
|
615
|
+
"ag.keep.optNone": "Keep the model it runs",
|
|
616
|
+
"ag.keep.advNote":
|
|
617
|
+
"The model it runs stays unless you pick another here. Permissions come from the persona.",
|
|
618
|
+
"ag.pc.item": "Change persona…",
|
|
619
|
+
"ag.pc.title": "Change {id}'s persona",
|
|
620
|
+
"ag.pc.note":
|
|
621
|
+
"Den stops it and resumes the same conversation as the new persona. Its id, name, folder and tab stay.",
|
|
622
|
+
"ag.pc.go": "Change persona",
|
|
623
|
+
"ag.pc.going": "Changing…",
|
|
624
|
+
"ag.pc.current": "current",
|
|
625
|
+
"ag.pc.busy": "It's working. Change after this turn, or stop it now?",
|
|
626
|
+
"ag.pc.after": "After this turn",
|
|
627
|
+
"ag.pc.now": "Stop it now",
|
|
628
|
+
"ag.pc.done": "{id} is now {p}",
|
|
629
|
+
"ag.pc.pending": "{id} becomes {p} when this turn ends",
|
|
630
|
+
"ag.more": "More for {id}",
|
|
602
631
|
"ag.bring.go": "Bring in",
|
|
603
632
|
"ag.bring.going": "Bringing in…",
|
|
604
633
|
"ag.bring.done": "Brought in as {id}",
|
|
@@ -745,6 +774,7 @@
|
|
|
745
774
|
"Its token was revoked (web logout --all): stop and resume it, or start it again, to give it a new one",
|
|
746
775
|
"ag.ended":
|
|
747
776
|
"This session has ended. Its record stays until it is resumed or removed.",
|
|
777
|
+
"ag.switched": "Switched to {p}",
|
|
748
778
|
"ag.exitedLine": "[the session exited{code}]",
|
|
749
779
|
"ag.lost": "[disconnected: {why}]",
|
|
750
780
|
"ag.reconnect": "Reconnect",
|
|
@@ -367,6 +367,11 @@ export const ROUTES: readonly RouteEntry[] = [
|
|
|
367
367
|
"/api/workspaces/:ws/agents/:id/fresh",
|
|
368
368
|
"starts an agent afresh: a runtime in a PTY",
|
|
369
369
|
),
|
|
370
|
+
S(
|
|
371
|
+
["POST"],
|
|
372
|
+
"/api/workspaces/:ws/agents/:id/persona",
|
|
373
|
+
"changes an agent's persona (AG-18): its session stops and the same conversation resumes, a runtime in a PTY; a person's only",
|
|
374
|
+
),
|
|
370
375
|
S(
|
|
371
376
|
["POST"],
|
|
372
377
|
"/api/workspaces/:ws/agents/:id/relaunch",
|
|
@@ -468,6 +473,7 @@ export const REGEX_ROUTES: Readonly<Record<string, readonly string[]>> = {
|
|
|
468
473
|
"/api/workspaces/:ws/agents/:id/remove",
|
|
469
474
|
"/api/workspaces/:ws/agents/:id/name",
|
|
470
475
|
"/api/workspaces/:ws/agents/:id/paths",
|
|
476
|
+
"/api/workspaces/:ws/agents/:id/persona",
|
|
471
477
|
],
|
|
472
478
|
"agent-routes.ts:RUNTIME_PATH": ["/api/agents/runtimes/:id/path"],
|
|
473
479
|
"agent-routes.ts:PERSONA_PATH": ["/api/personas/:id"],
|
|
@@ -174,6 +174,8 @@ export interface ListedSession {
|
|
|
174
174
|
/** The host has it (running, or ended with its scrollback): a pane can attach. */
|
|
175
175
|
attachable: boolean;
|
|
176
176
|
resumable?: boolean;
|
|
177
|
+
/** AG-18: Change persona… applies (its runtime can resume). */
|
|
178
|
+
personaChange?: boolean;
|
|
177
179
|
/** Why only Start fresh applies (AG-14.2): "<runtime> can't resume a conversation". */
|
|
178
180
|
noResume?: string;
|
|
179
181
|
/** When it was stopped, seen to end, or found interrupted (AG-14.1). */
|
|
@@ -243,6 +245,7 @@ export function listedSessions(
|
|
|
243
245
|
...(r.startedAt ? { startedAt: r.startedAt } : {}),
|
|
244
246
|
attachable: Boolean(s),
|
|
245
247
|
resumable: r.resumable,
|
|
248
|
+
...(r.personaChange ? { personaChange: true } : {}),
|
|
246
249
|
...(r.noResume ? { noResume: r.noResume } : {}),
|
|
247
250
|
...(r.stoppedAt ? { stoppedAt: r.stoppedAt } : {}),
|
|
248
251
|
...(r.endedAt ? { endedAt: r.endedAt } : {}),
|