@songsid/agend 2.3.2 → 2.3.3-beta.10
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/agent-cli-instructions.md +2 -2
- package/dist/agent-cli.js +13 -112
- package/dist/agent-cli.js.map +1 -1
- package/dist/agent-endpoint.d.ts +0 -1
- package/dist/agent-endpoint.js +1 -9
- package/dist/agent-endpoint.js.map +1 -1
- package/dist/agent-whats-new.d.ts +23 -5
- package/dist/agent-whats-new.js +58 -40
- package/dist/agent-whats-new.js.map +1 -1
- package/dist/auth-api.d.ts +0 -7
- package/dist/auth-api.js +1 -15
- package/dist/auth-api.js.map +1 -1
- package/dist/authority/authority-state.js +1 -1
- package/dist/authority/authority-state.js.map +1 -1
- package/dist/authority/web-authority.d.ts +9 -4
- package/dist/authority/web-authority.js +10 -5
- package/dist/authority/web-authority.js.map +1 -1
- package/dist/backend/antigravity.js +6 -1
- package/dist/backend/antigravity.js.map +1 -1
- package/dist/backend/claude-code.d.ts +20 -1
- package/dist/backend/claude-code.js +54 -29
- package/dist/backend/claude-code.js.map +1 -1
- package/dist/backend/claude-transcript-errors.d.ts +18 -0
- package/dist/backend/claude-transcript-errors.js +19 -0
- package/dist/backend/claude-transcript-errors.js.map +1 -0
- package/dist/backend/codex-session-lookup.d.ts +16 -3
- package/dist/backend/codex-session-lookup.js +45 -11
- package/dist/backend/codex-session-lookup.js.map +1 -1
- package/dist/backend/codex.d.ts +16 -0
- package/dist/backend/codex.js +184 -35
- package/dist/backend/codex.js.map +1 -1
- package/dist/backend/grok.js +58 -12
- package/dist/backend/grok.js.map +1 -1
- package/dist/backend/kiro-reconcile-store.js +8 -1
- package/dist/backend/kiro-reconcile-store.js.map +1 -1
- package/dist/backend/kiro.d.ts +0 -5
- package/dist/backend/kiro.js +2 -10
- package/dist/backend/kiro.js.map +1 -1
- package/dist/backend/muse.js +2 -1
- package/dist/backend/muse.js.map +1 -1
- package/dist/backend/types.d.ts +53 -4
- package/dist/backend/types.js.map +1 -1
- package/dist/bundled-skills.d.ts +4 -6
- package/dist/bundled-skills.js +10 -14
- package/dist/bundled-skills.js.map +1 -1
- package/dist/channel/adapters/discord.js +60 -17
- package/dist/channel/adapters/discord.js.map +1 -1
- package/dist/channel/mcp-server.js +5 -5
- package/dist/channel/mcp-server.js.map +1 -1
- package/dist/channel/mcp-tools.d.ts +1 -3
- package/dist/channel/mcp-tools.js +4 -58
- package/dist/channel/mcp-tools.js.map +1 -1
- package/dist/classic-channel-manager.d.ts +4 -1
- package/dist/classic-channel-manager.js +21 -7
- package/dist/classic-channel-manager.js.map +1 -1
- package/dist/cli.js +23 -6
- package/dist/cli.js.map +1 -1
- package/dist/config-history.d.ts +50 -0
- package/dist/config-history.js +263 -0
- package/dist/config-history.js.map +1 -0
- package/dist/config-validator.js +10 -8
- package/dist/config-validator.js.map +1 -1
- package/dist/config.d.ts +3 -0
- package/dist/config.js +11 -4
- package/dist/config.js.map +1 -1
- package/dist/cross-instance-envelope.d.ts +10 -5
- package/dist/cross-instance-envelope.js +20 -17
- package/dist/cross-instance-envelope.js.map +1 -1
- package/dist/daemon.d.ts +130 -64
- package/dist/daemon.js +603 -428
- package/dist/daemon.js.map +1 -1
- package/dist/daily-summary.d.ts +8 -1
- package/dist/daily-summary.js +8 -5
- package/dist/daily-summary.js.map +1 -1
- package/dist/dashboard-live.d.ts +1 -1
- package/dist/dashboard-live.js +3 -3
- package/dist/dashboard-live.js.map +1 -1
- package/dist/dashboard-permissions.d.ts +1 -1
- package/dist/dashboard-permissions.js +1 -3
- package/dist/dashboard-permissions.js.map +1 -1
- package/dist/delivery-outbox.d.ts +31 -22
- package/dist/delivery-outbox.js +119 -161
- package/dist/delivery-outbox.js.map +1 -1
- package/dist/delivery-outbox.test.js +10 -25
- package/dist/delivery-outbox.test.js.map +1 -1
- package/dist/doctor.d.ts +4 -0
- package/dist/doctor.js +16 -1
- package/dist/doctor.js.map +1 -1
- package/dist/fleet-level-config.js +1 -1
- package/dist/fleet-level-config.js.map +1 -1
- package/dist/fleet-manager.d.ts +74 -66
- package/dist/fleet-manager.js +285 -414
- package/dist/fleet-manager.js.map +1 -1
- package/dist/fleet-process-handlers.d.ts +5 -0
- package/dist/fleet-process-handlers.js +21 -0
- package/dist/fleet-process-handlers.js.map +1 -1
- package/dist/fleet-service-owner.d.ts +11 -0
- package/dist/fleet-service-owner.js +3 -0
- package/dist/fleet-service-owner.js.map +1 -0
- package/dist/general-knowledge/skills/credential-profiles/SKILL.md +11 -1
- package/dist/general-knowledge/skills/delegation-playbook/SKILL.md +1 -1
- package/dist/general-knowledge/skills/fleet-restart/SKILL.md +1 -1
- package/dist/general-knowledge/skills/session-management/SKILL.md +7 -1
- package/dist/general-knowledge/skills/web-appearance/SKILL.md +13 -204
- package/dist/general-knowledge/skills/web-dashboard/SKILL.md +30 -68
- package/dist/instance-lifecycle.d.ts +19 -0
- package/dist/instance-lifecycle.js +73 -15
- package/dist/instance-lifecycle.js.map +1 -1
- package/dist/instructions.js +6 -7
- package/dist/instructions.js.map +1 -1
- package/dist/kiro-reconcile.js +3 -3
- package/dist/kiro-reconcile.js.map +1 -1
- package/dist/locale.js +96 -58
- package/dist/locale.js.map +1 -1
- package/dist/log-service.js +1 -1
- package/dist/log-service.js.map +1 -1
- package/dist/needs-you-hub.d.ts +1 -0
- package/dist/needs-you-hub.js +6 -3
- package/dist/needs-you-hub.js.map +1 -1
- package/dist/needs-you-live.d.ts +3 -1
- package/dist/needs-you-live.js +24 -2
- package/dist/needs-you-live.js.map +1 -1
- package/dist/needs-you.d.ts +13 -2
- package/dist/needs-you.js +11 -1
- package/dist/needs-you.js.map +1 -1
- package/dist/notify-socket.d.ts +10 -0
- package/dist/notify-socket.js +45 -0
- package/dist/notify-socket.js.map +1 -0
- package/dist/outbound-handlers.js +20 -8
- package/dist/outbound-handlers.js.map +1 -1
- package/dist/outbound-schemas.d.ts +0 -62
- package/dist/outbound-schemas.js +4 -43
- package/dist/outbound-schemas.js.map +1 -1
- package/dist/parked-notices.d.ts +87 -0
- package/dist/parked-notices.js +194 -0
- package/dist/parked-notices.js.map +1 -0
- package/dist/public-link-progress.d.ts +5 -2
- package/dist/public-link-progress.js +4 -3
- package/dist/public-link-progress.js.map +1 -1
- package/dist/public-web-gateway.js +0 -9
- package/dist/public-web-gateway.js.map +1 -1
- package/dist/public-web-link.d.ts +12 -0
- package/dist/public-web-link.js +29 -5
- package/dist/public-web-link.js.map +1 -1
- package/dist/quota-notice.d.ts +23 -0
- package/dist/quota-notice.js +22 -0
- package/dist/quota-notice.js.map +1 -0
- package/dist/scheduler/task-board.d.ts +17 -25
- package/dist/scheduler/task-board.js +29 -39
- package/dist/scheduler/task-board.js.map +1 -1
- package/dist/sd-notify.d.ts +23 -15
- package/dist/sd-notify.js +88 -29
- package/dist/sd-notify.js.map +1 -1
- package/dist/search/search-docs.d.ts +1 -1
- package/dist/search/search-docs.js +2 -2
- package/dist/search/search-docs.js.map +1 -1
- package/dist/settings-api.d.ts +16 -1
- package/dist/settings-api.js +56 -16
- package/dist/settings-api.js.map +1 -1
- package/dist/settings-change.js +3 -1
- package/dist/settings-change.js.map +1 -1
- package/dist/settings-confirmation.d.ts +17 -3
- package/dist/settings-confirmation.js +8 -5
- package/dist/settings-confirmation.js.map +1 -1
- package/dist/settings-effect.js +0 -2
- package/dist/settings-effect.js.map +1 -1
- package/dist/settings-http-confirmation.js +31 -1
- package/dist/settings-http-confirmation.js.map +1 -1
- package/dist/setup-wizard.d.ts +3 -0
- package/dist/setup-wizard.js +4 -2
- package/dist/setup-wizard.js.map +1 -1
- package/dist/task-board-waker.d.ts +43 -1
- package/dist/task-board-waker.js +121 -9
- package/dist/task-board-waker.js.map +1 -1
- package/dist/tmux-control.d.ts +1 -1
- package/dist/tmux-control.js +3 -2
- package/dist/tmux-control.js.map +1 -1
- package/dist/tmux-manager.js +18 -16
- package/dist/tmux-manager.js.map +1 -1
- package/dist/tmux-read.d.ts +2 -0
- package/dist/tmux-read.js +7 -1
- package/dist/tmux-read.js.map +1 -1
- package/dist/tool-permissions.js +3 -10
- package/dist/tool-permissions.js.map +1 -1
- package/dist/topic-commands.d.ts +29 -7
- package/dist/topic-commands.js +97 -37
- package/dist/topic-commands.js.map +1 -1
- package/dist/transcript-monitor.d.ts +7 -0
- package/dist/transcript-monitor.js +48 -3
- package/dist/transcript-monitor.js.map +1 -1
- package/dist/tunnel/cloudflared.d.ts +5 -0
- package/dist/tunnel/cloudflared.js +32 -1
- package/dist/tunnel/cloudflared.js.map +1 -1
- package/dist/tunnel/named-diagnostics.d.ts +2 -1
- package/dist/tunnel/named-diagnostics.js +4 -1
- package/dist/tunnel/named-diagnostics.js.map +1 -1
- package/dist/tunnel/named-link-test.d.ts +90 -0
- package/dist/tunnel/named-link-test.js +270 -0
- package/dist/tunnel/named-link-test.js.map +1 -0
- package/dist/tunnel/purpose-lane.d.ts +3 -1
- package/dist/tunnel/purpose-lane.js +2 -0
- package/dist/tunnel/purpose-lane.js.map +1 -1
- package/dist/types.d.ts +9 -11
- package/dist/ui/chat-ambient.js +4 -4
- package/dist/ui/chat-commands.js +3 -2
- package/dist/ui/chat-store.js +4 -1
- package/dist/ui/chat-strings.js +12 -46
- package/dist/ui/chat-thread.js +51 -59
- package/dist/ui/fleet-office-skin.js +37 -14
- package/dist/ui/fleet-office.js +31 -7
- package/dist/ui/html-attachment.js +22 -8
- package/dist/ui/panel-chat.js +21 -50
- package/dist/ui/panel-log.js +2 -2
- package/dist/ui/panel-needs.js +11 -9
- package/dist/ui/panel-settings.js +5 -3
- package/dist/ui/preview-panel.js +12 -21
- package/dist/ui/preview.js +10 -3
- package/dist/ui/search-dialog.js +30 -14
- package/dist/ui/settings-appearance.js +3 -37
- package/dist/ui/settings-confirm.js +18 -0
- package/dist/ui/settings-guests.js +13 -4
- package/dist/ui/settings-learn.js +1 -1
- package/dist/ui/settings-mods.js +5 -12
- package/dist/ui/settings-named-test.js +144 -0
- package/dist/ui/settings-registry.js +0 -2
- package/dist/ui/settings-strings.js +16 -16
- package/dist/ui/settings-web-authority.js +4 -3
- package/dist/ui/shared/app-i18n.js +15 -4
- package/dist/ui/shared/app-needs.js +5 -1
- package/dist/ui/shared/app-prefs.js +17 -17
- package/dist/ui/shared/app-shell.js +47 -9
- package/dist/ui/shared/app-store.js +6 -2
- package/dist/ui/shared/app.css +33 -39
- package/dist/ui/shared/app.js +5 -4
- package/dist/ui/shared/instance-nav.js +9 -9
- package/dist/ui/shared/instance-switch.js +8 -2
- package/dist/ui/shared/panel-view.js +22 -8
- package/dist/ui/shared/view-strings.js +6 -0
- package/dist/ui/shared/web-authorize.js +35 -13
- package/dist/update-check.d.ts +13 -4
- package/dist/update-check.js +17 -4
- package/dist/update-check.js.map +1 -1
- package/dist/usage/usage-api.d.ts +3 -0
- package/dist/usage/usage-api.js +5 -1
- package/dist/usage/usage-api.js.map +1 -1
- package/dist/view-api.d.ts +2 -0
- package/dist/view-api.js +64 -0
- package/dist/view-api.js.map +1 -1
- package/dist/web-api.d.ts +9 -17
- package/dist/web-api.js +257 -371
- package/dist/web-api.js.map +1 -1
- package/dist/web-appearance-tools.d.ts +0 -2
- package/dist/web-appearance-tools.js +2 -5
- package/dist/web-appearance-tools.js.map +1 -1
- package/dist/web-appearance-view.d.ts +0 -6
- package/dist/web-appearance-view.js +0 -1
- package/dist/web-appearance-view.js.map +1 -1
- package/dist/web-appearance.d.ts +14 -7
- package/dist/web-appearance.js +5 -6
- package/dist/web-appearance.js.map +1 -1
- package/dist/web-asset-parts.d.ts +1 -17
- package/dist/web-asset-parts.js +1 -15
- package/dist/web-asset-parts.js.map +1 -1
- package/dist/web-auth.js +1 -7
- package/dist/web-auth.js.map +1 -1
- package/dist/web-chat-history.d.ts +3 -7
- package/dist/web-chat-history.js +10 -17
- package/dist/web-chat-history.js.map +1 -1
- package/dist/web-commands.d.ts +9 -1
- package/dist/web-commands.js +13 -0
- package/dist/web-commands.js.map +1 -1
- package/dist/web-experimental.d.ts +3 -8
- package/dist/web-experimental.js +9 -33
- package/dist/web-experimental.js.map +1 -1
- package/dist/web-guest-access.d.ts +40 -2
- package/dist/web-guest-access.js +50 -14
- package/dist/web-guest-access.js.map +1 -1
- package/dist/web-mod-bundle.d.ts +2 -45
- package/dist/web-mod-bundle.js +15 -63
- package/dist/web-mod-bundle.js.map +1 -1
- package/dist/web-mod-store.d.ts +3 -48
- package/dist/web-mod-store.js +30 -97
- package/dist/web-mod-store.js.map +1 -1
- package/dist/web-prefs.d.ts +13 -0
- package/dist/web-prefs.js +38 -0
- package/dist/web-prefs.js.map +1 -1
- package/dist/web-preview.d.ts +6 -13
- package/dist/web-preview.js +12 -23
- package/dist/web-preview.js.map +1 -1
- package/dist/web-session.d.ts +11 -3
- package/dist/web-session.js +22 -11
- package/dist/web-session.js.map +1 -1
- package/dist/web-settings-patch.d.ts +1 -1
- package/dist/web-settings-patch.js +9 -7
- package/dist/web-settings-patch.js.map +1 -1
- package/dist/web-settings-tools.d.ts +0 -13
- package/dist/web-settings-tools.js +12 -84
- package/dist/web-settings-tools.js.map +1 -1
- package/dist/workflow-templates/default.md +2 -2
- package/dist/working-recovery.d.ts +0 -2
- package/dist/working-recovery.js +2 -23
- package/dist/working-recovery.js.map +1 -1
- package/launcher/agend-install.cjs +7 -1
- package/launcher/fleet-service-owner.cjs +150 -0
- package/package.json +1 -1
- package/dist/general-knowledge/skills/web-appearance/SKILL.canvas-worker-off.md +0 -376
- package/dist/general-knowledge/skills/web-dashboard/SKILL.canvas-worker-off.md +0 -673
- package/dist/task-board-summary.d.ts +0 -101
- package/dist/task-board-summary.js +0 -177
- package/dist/task-board-summary.js.map +0 -1
- package/dist/ui/app-effects.js +0 -251
- package/dist/ui/chat-effect-posters.js +0 -42
- package/dist/ui/chat-effects.js +0 -167
- package/dist/ui/effect-trial-controller.js +0 -124
- package/dist/ui/effect-trial-offer.js +0 -2
- package/dist/ui/effect-trial-panel.js +0 -40
- package/dist/ui/effects-waker.js +0 -2
- package/dist/ui/settings-effects.js +0 -202
- package/dist/ui/settings-owner-effects.js +0 -82
- package/dist/ui/shared/effect-app-runtime.js +0 -299
- package/dist/ui/shared/effect-baseline.js +0 -64
- package/dist/ui/shared/effect-chat-runtime.js +0 -162
- package/dist/ui/shared/effect-cursor.js +0 -126
- package/dist/ui/shared/effect-display-metadata.js +0 -39
- package/dist/ui/shared/effect-frame.js +0 -146
- package/dist/ui/shared/effect-geometry.js +0 -137
- package/dist/ui/shared/effect-host-style.js +0 -10
- package/dist/ui/shared/effect-owner-regions.js +0 -74
- package/dist/ui/shared/effect-owner-source.js +0 -122
- package/dist/ui/shared/effect-policy.js +0 -151
- package/dist/ui/shared/effect-poster-reader.js +0 -98
- package/dist/ui/shared/effect-posters.js +0 -117
- package/dist/ui/shared/effect-profiler.js +0 -184
- package/dist/ui/shared/effect-profiles.js +0 -65
- package/dist/ui/shared/effect-registry.js +0 -545
- package/dist/ui/shared/effect-runtime-loader.js +0 -236
- package/dist/ui/shared/effect-safety.js +0 -153
- package/dist/ui/shared/effect-stock-snapshot.js +0 -43
- package/dist/ui/shared/effect-stock-trust.js +0 -217
- package/dist/ui/shared/effect-trial-shadow.js +0 -62
- package/dist/ui/shared/effect-trial-source.js +0 -103
- package/dist/ui/shared/effect-trial-stage.js +0 -170
- package/dist/ui/shared/effect-trial.css +0 -40
- package/dist/ui/shared/feature-flags.js +0 -127
- package/dist/ui/shared/owner-effect-prefs.js +0 -117
- package/dist/upgrade-notices.d.ts +0 -17
- package/dist/upgrade-notices.js +0 -93
- package/dist/upgrade-notices.js.map +0 -1
- package/dist/web-effect-bootstrap.d.ts +0 -12
- package/dist/web-effect-bootstrap.js +0 -49
- package/dist/web-effect-bootstrap.js.map +0 -1
- package/dist/web-effect-bundle.d.ts +0 -28
- package/dist/web-effect-bundle.js +0 -171
- package/dist/web-effect-bundle.js.map +0 -1
- package/dist/web-effect-canonical.d.ts +0 -8
- package/dist/web-effect-canonical.js +0 -27
- package/dist/web-effect-canonical.js.map +0 -1
- package/dist/web-effect-library.d.ts +0 -114
- package/dist/web-effect-library.js +0 -530
- package/dist/web-effect-library.js.map +0 -1
- package/dist/web-effect-playback.d.ts +0 -30
- package/dist/web-effect-playback.js +0 -71
- package/dist/web-effect-playback.js.map +0 -1
- package/dist/web-effect-poster.d.ts +0 -8
- package/dist/web-effect-poster.js +0 -52
- package/dist/web-effect-poster.js.map +0 -1
- package/dist/web-effect-profiles.d.ts +0 -118
- package/dist/web-effect-profiles.js +0 -181
- package/dist/web-effect-profiles.js.map +0 -1
- package/dist/web-effect-service.d.ts +0 -93
- package/dist/web-effect-service.js +0 -335
- package/dist/web-effect-service.js.map +0 -1
- package/dist/web-effect-tools.d.ts +0 -48
- package/dist/web-effect-tools.js +0 -129
- package/dist/web-effect-tools.js.map +0 -1
- package/dist/web-effect-trials.d.ts +0 -86
- package/dist/web-effect-trials.js +0 -204
- package/dist/web-effect-trials.js.map +0 -1
- package/dist/web-effect-upload.d.ts +0 -27
- package/dist/web-effect-upload.js +0 -185
- package/dist/web-effect-upload.js.map +0 -1
- package/dist/web-effect-worker.d.ts +0 -8
- package/dist/web-effect-worker.js +0 -170
- package/dist/web-effect-worker.js.map +0 -1
- package/dist/web-effect.d.ts +0 -103
- package/dist/web-effect.js +0 -153
- package/dist/web-effect.js.map +0 -1
- package/dist/web-experimental-http.d.ts +0 -2
- package/dist/web-experimental-http.js +0 -12
- package/dist/web-experimental-http.js.map +0 -1
- package/dist/web-mod-agent.d.ts +0 -50
- package/dist/web-mod-agent.js +0 -207
- package/dist/web-mod-agent.js.map +0 -1
|
@@ -24,6 +24,7 @@ var childProcess = require("child_process");
|
|
|
24
24
|
|
|
25
25
|
var LOCK = ".agend-install.lock";
|
|
26
26
|
var MARKER = "update-in-progress.json";
|
|
27
|
+
var fleetServiceOwner = require("./fleet-service-owner.cjs");
|
|
27
28
|
var ensurePrivateHome = require("./private-home.cjs").ensurePrivateHome;
|
|
28
29
|
|
|
29
30
|
function defaultDeps() {
|
|
@@ -670,6 +671,8 @@ function main(argv, injected) {
|
|
|
670
671
|
catch (error) { return fail("install", error.message); }
|
|
671
672
|
|
|
672
673
|
log(" AgEnD installer v" + version + (upgrade ? " (upgrade)" : ""));
|
|
674
|
+
var ownerRefusal = fleetServiceOwner.updateRefusal(home, { env: deps.env, uid: deps.uid, run: deps.run });
|
|
675
|
+
if (ownerRefusal) return fail("install", ownerRefusal);
|
|
673
676
|
var root = last(deps.run("npm", ["root", "-g"], { timeoutMs: 30000 }).stdout);
|
|
674
677
|
var prefix = last(deps.run("npm", ["prefix", "-g"], { timeoutMs: 30000 }).stdout);
|
|
675
678
|
if (!root || !prefix) {
|
|
@@ -688,6 +691,9 @@ function main(argv, injected) {
|
|
|
688
691
|
try {
|
|
689
692
|
claimed = claimMarker(home, deps, {});
|
|
690
693
|
setStage(home, claimed, "downloading", { version: version }, deps);
|
|
694
|
+
// Recheck before any package repair/global install, including old update callers.
|
|
695
|
+
var ownerRecheck = fleetServiceOwner.updateRefusal(home, { env: deps.env, uid: deps.uid, run: deps.run });
|
|
696
|
+
if (ownerRecheck) return fail("install", ownerRecheck);
|
|
691
697
|
var fixed = repair(root, prefix, deps);
|
|
692
698
|
fixed.notes.forEach(function (n) { log(" ↺ " + n); });
|
|
693
699
|
pruneStale(prefix, deps).forEach(function (n) { log(" ↺ " + n); });
|
|
@@ -785,7 +791,7 @@ function main(argv, injected) {
|
|
|
785
791
|
var what = "the previous package (v" + preimage.version + ") and " + name + " were restored";
|
|
786
792
|
if (back !== preimage.version) restored.push(bin + " reports " + (back || "nothing") + ", not v" + preimage.version);
|
|
787
793
|
var outcome;
|
|
788
|
-
if (untouched) outcome = what + ";
|
|
794
|
+
if (untouched) outcome = what + "; " + fleetServiceOwner.message("survivor", { pid: fleetBefore }, fleetServiceOwner.locale(home));
|
|
789
795
|
else if (fleetBefore > 0) {
|
|
790
796
|
var started = startService(svc, home, deps);
|
|
791
797
|
outcome = started.running ? what + "; the previous service is running (pid " + started.pid + ")"
|
|
@@ -0,0 +1,150 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
// Shared by the installed CLI and the TARGET release's installer (#2823).
|
|
3
|
+
// Read-only classification: unknown ownership always refuses; this module never stops a process.
|
|
4
|
+
var fs = require("fs"), path = require("path"), os = require("os"), cp = require("child_process");
|
|
5
|
+
function defaults(options) {
|
|
6
|
+
var o = options || {}, env = o.env || process.env;
|
|
7
|
+
return Object.assign({
|
|
8
|
+
platform: process.platform, env: env, uid: process.getuid ? process.getuid() : -1,
|
|
9
|
+
read: function (p) { return fs.readFileSync(p, "utf8"); },
|
|
10
|
+
stat: function (p) { return fs.statSync(p); },
|
|
11
|
+
real: function (p) { return fs.realpathSync(p); },
|
|
12
|
+
link: function (p) { return fs.readlinkSync(p); },
|
|
13
|
+
lstat: function (p) { return fs.lstatSync(p); },
|
|
14
|
+
alive: function (pid) { try { process.kill(pid, 0); return true; } catch (e) { if (e.code === "ESRCH") return false; throw e; } },
|
|
15
|
+
run: function (cmd, args, opts) {
|
|
16
|
+
var r = cp.spawnSync(cmd, args, { encoding: "utf8", timeout: 5000, env: opts.env, stdio: ["ignore", "pipe", "pipe"] });
|
|
17
|
+
return { status: r.status, stdout: r.stdout || "" };
|
|
18
|
+
}
|
|
19
|
+
}, o);
|
|
20
|
+
}
|
|
21
|
+
function selectedService(options) {
|
|
22
|
+
var d = defaults(options);
|
|
23
|
+
if (d.platform !== "linux") return null;
|
|
24
|
+
var system = ["/etc/systemd/system/agend.service", "/usr/lib/systemd/system/agend.service", "/lib/systemd/system/agend.service"];
|
|
25
|
+
for (var i = 0; i < system.length; i++) if (present(system[i], d)) return { unit: "agend.service", user: false };
|
|
26
|
+
if (present(path.join(d.env.HOME || os.homedir(), ".config/systemd/user/com.agend.fleet.service"), d)) return { unit: "com.agend.fleet.service", user: true };
|
|
27
|
+
return null;
|
|
28
|
+
}
|
|
29
|
+
// existsSync also returns false for access errors and loops. Only ENOENT proves absence.
|
|
30
|
+
function present(p, d) {
|
|
31
|
+
try { return d.lstat(p); } catch (e) { if (e.code === "ENOENT") return null; throw e; }
|
|
32
|
+
}
|
|
33
|
+
function record(p, d) {
|
|
34
|
+
var st = present(p, d);
|
|
35
|
+
if (!st) return null;
|
|
36
|
+
if (!st.isFile()) throw Error("not a regular record"); // includes dangling/self symlinks
|
|
37
|
+
return d.read(p); // disappearance after lstat is unknown, not proven absence
|
|
38
|
+
}
|
|
39
|
+
function processBirth(pid, d) {
|
|
40
|
+
var stat = d.read("/proc/" + pid + "/stat"), end = stat.lastIndexOf(")"), parts = stat.slice(end + 2).trim().split(/\s+/);
|
|
41
|
+
if (stat.indexOf(pid + " (") !== 0 || end < 0 || !/^\d+$/.test(parts[19] || "")) throw Error("unknown birth");
|
|
42
|
+
return { birth: parts[19], exited: parts[0] === "Z" || parts[0] === "X" };
|
|
43
|
+
}
|
|
44
|
+
function fingerprint(proof) { return JSON.stringify([proof.pid, proof.birth, proof.argv, proof.group]); }
|
|
45
|
+
function fields(text) {
|
|
46
|
+
var out = Object.create(null);
|
|
47
|
+
text.split("\n").forEach(function (line) { var at = line.indexOf("="); if (at > 0) out[line.slice(0, at)] = line.slice(at + 1); });
|
|
48
|
+
return out;
|
|
49
|
+
}
|
|
50
|
+
// The process's systemd cgroup. Pure cgroup v2 lists one `0::` row; a hybrid host (WSL, older distros) lists both the
|
|
51
|
+
// unified `0::` row and the v1 `N:name=systemd:` row, with the same path — the 0:: one is what systemd reports as the
|
|
52
|
+
// unit's ControlGroup there too. A pure-v1 host has only the name=systemd row, or a bare `0::/` beside it (cgroup2
|
|
53
|
+
// mounted but unused). Two rows of the same kind, or no usable path, stay unknown.
|
|
54
|
+
function cgroup(text) {
|
|
55
|
+
var unified = null, named = null;
|
|
56
|
+
text.trim().split("\n").forEach(function (r) {
|
|
57
|
+
var m = /^(\d+):([^:]*):(.*)$/.exec(r);
|
|
58
|
+
if (!m) return;
|
|
59
|
+
if (m[1] === "0" && m[2] === "") { if (unified !== null) throw Error("unknown cgroup"); unified = m[3]; }
|
|
60
|
+
else if (m[2].split(",").indexOf("name=systemd") >= 0) { if (named !== null) throw Error("unknown cgroup"); named = m[3]; }
|
|
61
|
+
});
|
|
62
|
+
var p = unified !== null && unified !== "/" ? unified : named !== null ? named : unified;
|
|
63
|
+
if (!p || p[0] !== "/") throw Error("unknown cgroup");
|
|
64
|
+
return p;
|
|
65
|
+
}
|
|
66
|
+
function inside(p, group) { return !!group && group !== "/" && (p === group || p.indexOf(group + "/") === 0); }
|
|
67
|
+
function processProof(pid, home, d) {
|
|
68
|
+
if (!d.alive(pid)) return null;
|
|
69
|
+
var proc = "/proc/" + pid, start = processBirth(pid, d);
|
|
70
|
+
if (start.exited) return null;
|
|
71
|
+
if (d.stat(proc).uid !== d.uid) throw Error("foreign uid");
|
|
72
|
+
var argv = d.read(proc + "/cmdline").split("\0").filter(Boolean);
|
|
73
|
+
// Concrete shipped CLI, not an arbitrary process with 'fleet start' in its title.
|
|
74
|
+
if (argv.length < 4 || argv.length > 5 || argv[2] !== "fleet" || argv[3] !== "start" || (argv.length === 5 && argv[4] !== "--direct")) throw Error("not a fleet command");
|
|
75
|
+
var entry = d.real(argv[1]);
|
|
76
|
+
if (path.basename(entry) !== "cli.js" || path.basename(path.dirname(entry)) !== "dist" || JSON.parse(d.read(path.join(path.dirname(entry), "../package.json"))).name !== "@songsid/agend") throw Error("not an AgEnD CLI");
|
|
77
|
+
// The kernel's exe link is already resolved. An update replaces the package dir that holds the private runtime,
|
|
78
|
+
// so the link then ends in " (deleted)" and realpath would throw on the old path.
|
|
79
|
+
if (!/^node(?:js)?$/.test(path.basename(d.link(proc + "/exe").replace(/ \(deleted\)$/, "")))) throw Error("not node");
|
|
80
|
+
var env = Object.create(null);
|
|
81
|
+
d.read(proc + "/environ").split("\0").forEach(function (v) { var at = v.indexOf("="); if (at > 0) env[v.slice(0, at)] = v.slice(at + 1); });
|
|
82
|
+
var declared = env.AGEND_HOME || (env.HOME ? path.join(env.HOME, ".agend") : null);
|
|
83
|
+
if (!declared || d.real(path.resolve(d.real(proc + "/cwd"), declared)) !== d.real(home)) throw Error("foreign or unreadable home");
|
|
84
|
+
var group = cgroup(d.read(proc + "/cgroup"));
|
|
85
|
+
var end = processBirth(pid, d);
|
|
86
|
+
if (start.birth !== end.birth || end.exited) throw Error("process changed during proof");
|
|
87
|
+
return { pid: pid, birth: start.birth, argv: argv, group: group };
|
|
88
|
+
}
|
|
89
|
+
function inspect(home, service, options) {
|
|
90
|
+
var d = defaults(options), raw, owner;
|
|
91
|
+
if (d.platform !== "linux" || !service) return { kind: "none" };
|
|
92
|
+
try {
|
|
93
|
+
var lock = path.join(home, "fleet.lock");
|
|
94
|
+
raw = record(lock, d);
|
|
95
|
+
if (raw === null) {
|
|
96
|
+
var pidText = record(path.join(home, "fleet.pid"), d);
|
|
97
|
+
if (pidText !== null) {
|
|
98
|
+
var recorded = Number(pidText.trim());
|
|
99
|
+
if (!Number.isSafeInteger(recorded) || recorded <= 1 || d.alive(recorded)) return { kind: "unknown" };
|
|
100
|
+
}
|
|
101
|
+
return { kind: "none" };
|
|
102
|
+
}
|
|
103
|
+
owner = JSON.parse(raw);
|
|
104
|
+
if (!owner || !Number.isSafeInteger(owner.pid) || owner.pid <= 1 || (owner.role !== undefined && owner.role !== "fleet") || typeof owner.nonce !== "string" || !owner.nonce) return { kind: "unknown" };
|
|
105
|
+
var proof = processProof(owner.pid, home, d);
|
|
106
|
+
if (!proof) return { kind: "none" };
|
|
107
|
+
var env = Object.assign({}, d.env);
|
|
108
|
+
if (service.user && !env.XDG_RUNTIME_DIR) env.XDG_RUNTIME_DIR = "/run/user/" + d.uid;
|
|
109
|
+
var r = d.run("systemctl", (service.user ? ["--user"] : []).concat(["show", service.unit, "--property=MainPID,ControlGroup,ActiveState,SubState,WorkingDirectory"]), { env: env, timeoutMs: 5000 });
|
|
110
|
+
if (r.status !== 0) return { kind: "unknown" };
|
|
111
|
+
// systemctl can block. Recheck the process and lock before trusting its ownership answer.
|
|
112
|
+
var after = processProof(owner.pid, home, d);
|
|
113
|
+
if (!after || fingerprint(after) !== fingerprint(proof) || record(lock, d) !== raw) return { kind: "unknown" };
|
|
114
|
+
var unit = fields(r.stdout), main = Number(unit.MainPID);
|
|
115
|
+
if (!/^\d+$/.test(unit.MainPID || "") || !unit.ActiveState || !unit.SubState || d.real(unit.WorkingDirectory) !== d.real(home)) return { kind: "unknown" };
|
|
116
|
+
// Require both the service MainPID and its cgroup to match.
|
|
117
|
+
if (main === owner.pid && inside(proof.group, unit.ControlGroup)) return { kind: "managed", pid: owner.pid, mainPid: main };
|
|
118
|
+
if (main !== 0 || !/^(?:inactive|failed)$/.test(unit.ActiveState)) return { kind: "unknown" };
|
|
119
|
+
return { kind: "outside", pid: owner.pid, unit: service.unit };
|
|
120
|
+
} catch (e) { return { kind: "unknown" }; }
|
|
121
|
+
}
|
|
122
|
+
var messages = {
|
|
123
|
+
en: {
|
|
124
|
+
update_outside: "Update not started: fleet PID {pid} is running outside {unit}. Run kill {pid} to request a normal stop, confirm that process has exited, then run agend start and retry agend update. No package or service definition was changed.",
|
|
125
|
+
update_unknown: "Update not started: fleet ownership could not be verified. Check fleet.lock and systemctl status to identify the fleet PID; only then stop that fleet with kill PID and confirm it has exited. Run agend start, then retry agend update. No package or service definition was changed.",
|
|
126
|
+
restart_outside: "Restart not started: fleet PID {pid} is running outside {unit}. Run kill {pid} to request a normal stop, confirm that process has exited, then run agend start. Nothing was signalled or started.",
|
|
127
|
+
restart_unknown: "Restart not started: fleet ownership could not be verified. Check fleet.lock and systemctl status to identify the fleet PID; only then stop that fleet with kill PID and confirm it has exited. Run agend start. Nothing was signalled or started.",
|
|
128
|
+
survivor: "the previously recorded fleet PID {pid} is still alive; this check does not establish which service owns it"
|
|
129
|
+
},
|
|
130
|
+
"zh-TW": {
|
|
131
|
+
update_outside: "尚未開始更新:Fleet(PID {pid})正在 {unit} 之外執行。請執行 kill {pid} 要求正常停止,確認該程序已結束,再執行 agend start 並重試 agend update。套件與服務設定均未變更。",
|
|
132
|
+
update_unknown: "尚未開始更新:無法確認 Fleet 歸屬。請先檢查 fleet.lock 與 systemctl status,確認 Fleet 的 PID 後才執行 kill PID,並確認該程序已結束。再執行 agend start,然後重試 agend update。套件與服務設定均未變更。",
|
|
133
|
+
restart_outside: "尚未開始重新啟動:Fleet(PID {pid})正在 {unit} 之外執行。請執行 kill {pid} 要求正常停止,確認該程序已結束,再執行 agend start。未傳送任何訊號,也未啟動任何程序。",
|
|
134
|
+
restart_unknown: "尚未開始重新啟動:無法確認 Fleet 歸屬。請先檢查 fleet.lock 與 systemctl status,確認 Fleet 的 PID 後才執行 kill PID,並確認該程序已結束。再執行 agend start。未傳送任何訊號,也未啟動任何程序。",
|
|
135
|
+
survivor: "先前記錄的 Fleet PID {pid} 仍存活;此檢查無法確認它由哪個服務管理"
|
|
136
|
+
}
|
|
137
|
+
};
|
|
138
|
+
function locale(home) {
|
|
139
|
+
try { var value = require("js-yaml").load(fs.readFileSync(path.join(home, "fleet.yaml"), "utf8")); if (value && value.defaults && messages[value.defaults.locale]) return value.defaults.locale; } catch (e) { /* zone fallback */ }
|
|
140
|
+
return new Date().getTimezoneOffset() === -480 ? "zh-TW" : "en";
|
|
141
|
+
}
|
|
142
|
+
function message(key, state, language) { return messages[language === "zh-TW" ? language : "en"][key].replace(/\{(pid|unit)\}/g, function (_, k) { return String(state[k]); }); }
|
|
143
|
+
function refusal(action, home, service, options) {
|
|
144
|
+
var state;
|
|
145
|
+
try { state = inspect(home, service === undefined ? selectedService(options) : service, options); } catch (e) { state = { kind: "unknown" }; }
|
|
146
|
+
return state.kind === "outside" || state.kind === "unknown" ? message(action + "_" + state.kind, state, (options || {}).locale || locale(home)) : null;
|
|
147
|
+
}
|
|
148
|
+
function updateRefusal(home, options) { return refusal("update", home, undefined, options); }
|
|
149
|
+
function restartRefusal(home, service, options) { return refusal("restart", home, service, options); }
|
|
150
|
+
module.exports = { selectedService: selectedService, inspect: inspect, updateRefusal: updateRefusal, restartRefusal: restartRefusal, message: message, locale: locale };
|
package/package.json
CHANGED
|
@@ -1,376 +0,0 @@
|
|
|
1
|
-
---
|
|
2
|
-
name: web-appearance
|
|
3
|
-
description: How you look on the AgEnD web dashboard — check it, change your own theme, identity card, identity colour and widgets, set an ambient effect (falling petals, click stars), and preview the result; and, for General, changing Settings → Look for the user
|
|
4
|
-
roles: [general, worker, classic]
|
|
5
|
-
---
|
|
6
|
-
|
|
7
|
-
## What it is
|
|
8
|
-
|
|
9
|
-
People see you on the web dashboard: in the sidebar, at the top of your chat, on your Details page and in View. You
|
|
10
|
-
can shape how you look there — **only your own look, and only on the surfaces that are yours**:
|
|
11
|
-
|
|
12
|
-
| Surface | What you set | Tools |
|
|
13
|
-
|---|---|---|
|
|
14
|
-
| Your name and role line | display name, description | `set_display_name`, `set_description` |
|
|
15
|
-
| Your status stamp | persona emoji | `set_persona_emoji` (see the `persona-emoji` skill) |
|
|
16
|
-
| Your chat | theme: colours, accent, bubbles, font, background picture, working label | `set_web_theme`, `set_web_theme_asset` |
|
|
17
|
-
| The whole page, while your chat is open | your theme's colours on the sidebar, the header, the usage rail (a phone: the drawer, the header, the tabs) — colours only | `set_web_theme` (`page`) |
|
|
18
|
-
| Your face and ring | theme picture and accent | `set_web_theme`, `set_web_theme_asset` |
|
|
19
|
-
| Your identity card | portrait, banner, tagline, bio | `set_web_theme` (`card.*`), `set_web_theme_asset` |
|
|
20
|
-
| Your identity colour | the colour people find you by in the sidebar, and where it shows (name, bar, ring) | `set_web_theme` (`identity`) |
|
|
21
|
-
| Your chat header strip and Details page | widgets: small panels of facts the dashboard draws | `set_web_widget`, `remove_web_widget` |
|
|
22
|
-
| An ambient effect in your chat | falling petals, snow, rising lanterns, twinkles, stars where a person clicks — data only, drawn by the dashboard | `set_web_ambient`, `clear_web_ambient` |
|
|
23
|
-
| Your character in Fleet → Org chart → Office | walk to a seat, a spot or a person, say a short line, hold a pose — for a few seconds (off until a person switches it on) | `office_view`, `office_set` |
|
|
24
|
-
|
|
25
|
-
None of these tools takes a target: they always act on you. You can't change another instance, the dashboard's own
|
|
26
|
-
chrome (beyond your colours on it while your chat is open), a person's sidebar widget, or a person's custom CSS.
|
|
27
|
-
|
|
28
|
-
## For the user: Settings → Look (General, coordinators, full)
|
|
29
|
-
|
|
30
|
-
If you are General (or a coordinator or full profile), you can change the user's **Settings → Look** for
|
|
31
|
-
them, exactly as the page changes it: the same checks, the same refusals. Custom CSS keeps its safe rules: no remote
|
|
32
|
-
URLs, assets only as `url("asset:<id>")`, at most 64 KiB. Other instances can't; they shape only their own look (the rest
|
|
33
|
-
of this skill).
|
|
34
|
-
|
|
35
|
-
1. **Read first:** `get_web_settings` returns a `summary` in plain words (tell the user from it), the values, and
|
|
36
|
-
`people`: the host operator and everyone who has signed in. Host settings are everyone's on this host. Custom CSS is one person's own: pass `person` as the entry whose id is the user's (`person:<adapter>:<their id>`),
|
|
37
|
-
else the host operator's are changed.
|
|
38
|
-
2. **One change per call:** `set_web_settings({ person?, change })`, where `change.what` is one of:
|
|
39
|
-
|
|
40
|
-
| `what` | Changes | Example |
|
|
41
|
-
|---|---|---|
|
|
42
|
-
| `host` | `themes_shown`, `card_size` (s/m/l), `card_sizes` ({instance: s/m/l}), `page_colours` ({instance: page/chat}), `colour_places` (name/bar/ring), `colours_off`, `sidebar_widget` ({spec, data}) — null puts one back to its default | `{ what: "host", set: { colour_places: ["name","ring"] } }` |
|
|
43
|
-
| `agent_colour` | one agent's colour (`preset:<name>` or `#rrggbb`) and places; null resets each | `{ what: "agent_colour", instance: "atlas", colour: "preset:teal" }` |
|
|
44
|
-
| `page_colours` | where one agent's theme colours go: `page` (the whole page), `chat` (only its chat) or `agent` (its own `page.on`) — as ⋯ → Page colours sets it | `{ what: "page_colours", instance: "atlas", choice: "chat" }` |
|
|
45
|
-
| `banner_focus` | which part of one agent's cropped card banner stays in view: `focus` 0 (top) … 100 (bottom), 50 the centre; it wins over the agent's own `card.bannerFocus`; null follows the agent's again | `{ what: "banner_focus", instance: "atlas", focus: 20 }` |
|
|
46
|
-
| `custom_css` | `save` (with `text`): goes **on trial**. It waits until they open the dashboard (up to 10 minutes; never opened, it goes back unseen), then goes back by itself 20 s after it is on their screen unless kept (#2198). `keep` (with `trial`: the id `save` returned — a different trial on now, say one they saved on their page since, is refused with `trial_mismatch`, never kept instead; or, kept after that 20 s ran out, it is put back in force as `use` of it), `revert` (the trial), `use` (with `version`: an earlier saved one, at once), `off` | `{ what: "custom_css", action: "save", text: "…" }`; tell them to open the dashboard and look, then `keep` (with that `trial`) only when they say so — a `keep` that comes too late (`not_on_trial`) means use `use` with the version from `get_web_settings` |
|
|
47
|
-
| `ambient` | one agent's ambient effect, set for the user: `ambient` is the same spec as `set_web_ambient`'s (it replaces the one of its kind, and the agent can't change it after); `ambient: null` clears (`which`: `loop` or `click`, default both) | `{ what: "ambient", instance: "atlas", ambient: { preset: "fall", glyphs: ["🌸","❀","✿"] } }` |
|
|
48
|
-
| `restore_defaults` | the host settings back to their defaults, and the person's custom CSS off | |
|
|
49
|
-
|
|
50
|
-
3. **Say what changed** in the user's words (read again if unsure). A refusal says why: the same words the page would
|
|
51
|
-
show.
|
|
52
|
-
|
|
53
|
-
**Only the person can do these, on the page:**
|
|
54
|
-
- choose a file from their computer: add a CSS asset or a card picture;
|
|
55
|
-
- this browser's own switches: custom CSS off on this device, pausing effect playback;
|
|
56
|
-
- the card upload limits (fleet configuration; a raise waits for an admin's confirmation).
|
|
57
|
-
|
|
58
|
-
## Look first
|
|
59
|
-
|
|
60
|
-
- `get_web_appearance` — how you appear **now**, resolved exactly as the dashboard resolves it: your face and where it
|
|
61
|
-
comes from (`profile`, `theme`, `bot`, `emoji` or `initial`), your ring colour, your **identity colour**
|
|
62
|
-
(`identity_color`: the colour people find you by in the sidebar, its `source` — `person`, `agent` (your theme's
|
|
63
|
-
`identity.color`, else its `accent`), `role` (your own bot's Discord role) or `auto` — its `light` / `dark` values,
|
|
64
|
-
where it shows (`show`: `name`, `bar`, `ring`) and whose choice that is (`show_source`: `person`, `agent` or `host`),
|
|
65
|
-
and `off` when the host turned colours off), your card field by field
|
|
66
|
-
(each marked `human` or `agent`), your theme per light/dark mode after the defaults, whether a person locked it, and
|
|
67
|
-
your limits.
|
|
68
|
-
- `preview_web_appearance` (`modes`: `["light"]`, `["dark"]` or both) — draws that as an SVG per mode into
|
|
69
|
-
`.agend/appearance/<mode>.svg` in your working directory, with the pictures it shows written beside it
|
|
70
|
-
(`avatar.png`, `portrait.png`, …), and returns both lists of paths. Read the SVGs for exact colours, geometry and
|
|
71
|
-
text, and the pictures as images. Only your own pictures are there.
|
|
72
|
-
- `get_web_theme` — your stored theme, the token defaults it is drawn over, your uploaded pictures (`id`, `slot`), and
|
|
73
|
-
`limits` (changes left, each picture slot's size limits, your picture quota).
|
|
74
|
-
|
|
75
|
-
## What wins over what
|
|
76
|
-
|
|
77
|
-
- **A person's choices win.** A picture uploaded for you in View beats your theme picture. A person's card field (from
|
|
78
|
-
View's Edit profile) beats yours, field by field — leave it to them. A person can **Lock** your theme (every change
|
|
79
|
-
you try is refused with `locked`) or **Reset** it (your theme, card and pictures go; a lock stays).
|
|
80
|
-
- A widget **a person placed** in one of your slots takes your values (`data`), but you can't replace or remove it
|
|
81
|
-
(`person_placed`).
|
|
82
|
-
- **Each viewer decides what they see.** Anyone can turn agents' themes and widgets off for their own screens, and
|
|
83
|
-
`?safe=1` loads a page without them; they then see the default look, no widgets, and your face follows the usual order without your theme
|
|
84
|
-
picture — a picture a person uploaded for you, else your bot's avatar, your persona emoji or your first letter.
|
|
85
|
-
Don't rely on your theme to say something important.
|
|
86
|
-
- The fleet can turn agent changes off entirely (`web.themes.agent_edit: false`): every change is refused with
|
|
87
|
-
`theme_editing_off`; what you stored stays.
|
|
88
|
-
- A person can switch these tools off for you (`dashboard.appearance: false`; the person's web settings tools with
|
|
89
|
-
`dashboard.web_settings: false`): a call is refused saying so. Do not retry; tell them if you need it.
|
|
90
|
-
|
|
91
|
-
## Change your theme
|
|
92
|
-
|
|
93
|
-
`set_web_theme { set?, clear? }` — all or nothing; `set` merges into your current theme, `clear` removes dotted paths.
|
|
94
|
-
Typed values only; anything else is refused with `{ errors: [{ path, problem }] }`:
|
|
95
|
-
|
|
96
|
-
- `colors.light` / `colors.dark`: any of `bg`, `surface`, `text`, `text2`, `accent`, `userBubble`, `agentBubble` as
|
|
97
|
-
`#rrggbb` (or `#rgb`). **Contrast is checked per mode**: `text` at least 4.5:1 on `bg`, `surface` and both bubbles;
|
|
98
|
-
`text2` at least 4.5:1 on `bg` and `surface`; `accent` at least 3:1 on `bg` — a palette that fails is refused, naming
|
|
99
|
-
the pair.
|
|
100
|
-
- `accent`: `#rrggbb` for both modes (a mode's own `accent` wins). Without `identity.color`, it is also your identity
|
|
101
|
-
colour.
|
|
102
|
-
- `identity`: `{ color?, show? }`: your identity colour and where it shows.
|
|
103
|
-
- `color` is a preset (`red`, `orange`, `amber`, `lime`, `green`, `teal`, `cyan`, `blue`, `indigo`, `violet`, `pink`,
|
|
104
|
-
`slate`, each readable in light and dark) or `#rrggbb`.
|
|
105
|
-
- `show` is a list of `name`, `bar` and `ring` (`[]` for nowhere). Left out, the host's default applies (name, bar and ring).
|
|
106
|
-
- A person's choice for you in the dashboard always wins, field by field, and their Reset brings yours back.
|
|
107
|
-
`get_web_appearance` says which is in force.
|
|
108
|
-
- `page` (#2196): `{ on?: true | false, sidebar?: { light?, dark? } }` — `on: true` puts your colours (bg, surface, text,
|
|
109
|
-
text2, accent; the sidebar's own colour per mode in `sidebar`, else your `bg`) on **the whole page while your chat,
|
|
110
|
-
View, Log or Details is open**: the sidebar, the header, the usage rail; on a phone the drawer, the header and the
|
|
111
|
-
tabs. Colours only: never fonts, pictures or layout, and **AgEnD's status colours** (the Needs you count, the state
|
|
112
|
-
dots, errors, the focus ring — `get_web_theme`'s `status_colors`) are never yours to change. With `on: true` the
|
|
113
|
-
contrast check adds: `text` and `text2` 4.5:1 and `accent` 3:1 on the sidebar, and every status colour 3:1 on the
|
|
114
|
-
sidebar and on `bg`. A person's choice for you (⋯ → **Page colours**: your choice, the whole page, only your chat)
|
|
115
|
-
wins; viewers with agents' themes off or `?safe=1` see the page's own look.
|
|
116
|
-
- For a person's **custom CSS** (#2199): while an agent's Chat, View, Log or Details is open, `<body>` has
|
|
117
|
-
`data-agent="<instance name>"` (none elsewhere), set in the same render as the page — so a person's stylesheet can
|
|
118
|
-
follow the open agent: `body[data-agent="atlas"] { --bg-sidebar: … }`. It is the person's, not yours to set.
|
|
119
|
-
- `bubble`: `{ radius: 0..24, border: "none" | "thin" | "accent" }`.
|
|
120
|
-
- `font`: `"inter"`, `"system"` or `"mono"`.
|
|
121
|
-
- `background`: `{ image: <asset id>, fit: "cover" | "contain", opacity: 0.05..1 }`.
|
|
122
|
-
- `avatar`: an asset id — your face (below a person's upload).
|
|
123
|
-
- `workingLabel`: 1..24 characters on one line, shown while you work instead of "is working…".
|
|
124
|
-
- `card`: `{ portrait?, banner?, tagline?, bio?, bannerFocus? }` — see below.
|
|
125
|
-
|
|
126
|
-
Example:
|
|
127
|
-
|
|
128
|
-
```json
|
|
129
|
-
{ "set": { "accent": "#7c3aed", "colors": { "dark": { "bg": "#14121f" } }, "bubble": { "radius": 12, "border": "accent" },
|
|
130
|
-
"font": "inter", "workingLabel": "Reviewing" } }
|
|
131
|
-
```
|
|
132
|
-
|
|
133
|
-
`reset_web_theme` puts your theme back to the default (it counts as a change).
|
|
134
|
-
|
|
135
|
-
## Pictures
|
|
136
|
-
|
|
137
|
-
`set_web_theme_asset { slot, file }` — `file` is a picture in **your working directory** (no symlinks; read on your side,
|
|
138
|
-
never by path on the fleet). It returns `{ id }`; name that id in `set_web_theme`. Metadata such as GPS is removed, and
|
|
139
|
-
the id is the hash of what is kept, so the same picture is the same id.
|
|
140
|
-
|
|
141
|
-
| Slot | Types | Limits |
|
|
142
|
-
|---|---|---|
|
|
143
|
-
| `background` | png, jpeg, webp, gif | 512 KiB, 4096 px a side |
|
|
144
|
-
| `avatar` | png, jpeg, webp, gif | 256 KiB, 4096 px a side |
|
|
145
|
-
| `portrait` | png, jpeg, webp | set by the fleet (default 1024×1536, 1.5 MiB) |
|
|
146
|
-
| `banner` | png, jpeg, webp | set by the fleet (default 1600×600, 768 KiB) |
|
|
147
|
-
| `glyph` | png, webp, gif | 64 KiB, 128 px a side; at most 4 (for `set_web_ambient`'s `glyphs`) |
|
|
148
|
-
|
|
149
|
-
A picture holds one slot: upload it again for another slot only if it is a different picture. `get_web_theme`'s
|
|
150
|
-
`limits.asset_slots` has the limits in force and `limits.asset_quota` how many pictures you may keep. A picture your
|
|
151
|
-
theme stops naming is deleted.
|
|
152
|
-
|
|
153
|
-
## Your identity card
|
|
154
|
-
|
|
155
|
-
`card.tagline` (one line, 1..60 characters), `card.bio` (1..280 characters, at most 3 line breaks), `card.portrait` and
|
|
156
|
-
`card.banner` (asset ids uploaded for those slots). Text is shown as text — never markup or links. A person may set
|
|
157
|
-
their own version of any field; theirs is shown instead of yours.
|
|
158
|
-
|
|
159
|
-
The card goes **inside `set`**: `set_web_theme({ set: { card: { tagline, bio, portrait, banner } } })` (a top-level
|
|
160
|
-
`card` argument is refused).
|
|
161
|
-
|
|
162
|
-
**Your banner is cropped: never drawn wider than 5 : 1** (on a wider screen it is centred over a blurred copy) **nor
|
|
163
|
-
narrower than 9 : 4** (which crops the sides). Make it **1600×600** (the default limit) and keep faces and text
|
|
164
|
-
inside the **safe area: the middle 84% of the width × 53% of the height — 1350×320** — which every card shows on every
|
|
165
|
-
screen and layout. `card.bannerFocus` (0 top … 100 bottom; default 50, the centre) moves that area up or down: put a face
|
|
166
|
-
near the top at `bannerFocus: 0`. A person's focus (Edit profile, or General's `set_web_settings { what: "banner_focus" }`)
|
|
167
|
-
wins over yours. `preview_web_appearance` draws the banner cropped at its focus, as the page does (an M card).
|
|
168
|
-
|
|
169
|
-
**In your chat** the card is hidden until the person shows it (the card menu in the chat header: Show card, Show picture
|
|
170
|
-
and bio). Shown, the banner sits right under the header and they can fold your portrait, tagline and bio away, keeping
|
|
171
|
-
only the banner. Their choice,
|
|
172
|
-
kept on their device; you cannot change it. So a banner that says who you are on its own reads well in your chat too.
|
|
173
|
-
|
|
174
|
-
## Your identity colour
|
|
175
|
-
|
|
176
|
-
The colour people find you by in the sidebar, drawn on your name, a bar at your row's left edge and/or the ring around
|
|
177
|
-
your picture. Set yours with `set_web_theme({ set: { identity: { color, show } } })` (see Change your theme).
|
|
178
|
-
|
|
179
|
-
- **Which colour shows**, first match wins: a **person's** pick for you (⋯ → Colour… or View's Edit profile, also from a
|
|
180
|
-
temporary public link) > **yours** (`identity.color`, else your theme's `accent`; only for a viewer who shows agents'
|
|
181
|
-
themes) > your own bot's Discord **role** colour > an **automatic** soft colour chosen from your name (two instances
|
|
182
|
-
may share one).
|
|
183
|
-
- **Where it shows**: a person's choice for you > yours (`identity.show`; again only while themes are shown) > the
|
|
184
|
-
host's default (Settings → Look; name, bar and ring unless changed).
|
|
185
|
-
- The host can **turn colours off** for everyone: nothing is drawn, and every pick, yours included, is kept for when
|
|
186
|
-
they come back.
|
|
187
|
-
- `get_web_appearance`'s `identity_color` shows what is in force: `color`, `source` (`person`, `agent`, `role`, `auto`),
|
|
188
|
-
`light` / `dark`, `show`, `show_source` (`person`, `agent`, `host`) and `off`.
|
|
189
|
-
|
|
190
|
-
## Widgets
|
|
191
|
-
|
|
192
|
-
A widget is a small panel of facts the dashboard draws **with its own components**: you send what to show and the
|
|
193
|
-
values, never HTML, script, links or CSS. It takes your theme's colours and always carries a `✦ <title>` chip. Nothing
|
|
194
|
-
in it can be clicked or focused.
|
|
195
|
-
|
|
196
|
-
`set_web_widget { slot, spec?, data? }`:
|
|
197
|
-
|
|
198
|
-
- `slot`: `chat_header` (a strip under your chat header: at most **4** items, of `stat`, `progress`, `text`, `badge`)
|
|
199
|
-
or `details` (a card on your Details page: at most **8** items, any type). `sidebar` is a person's: `owner_slot`.
|
|
200
|
-
- `spec` places or replaces the widget (a change):
|
|
201
|
-
`{ v: 1, title: 1..24 characters, items: [item, …] }`, where each item is `{ type, label?, key | bind, … }`:
|
|
202
|
-
|
|
203
|
-
| Type | Shows | Value | Extra |
|
|
204
|
-
|---|---|---|---|
|
|
205
|
-
| `stat` | a label and a number or short word | number, or 1..24 characters | `unit` (1..8 characters) |
|
|
206
|
-
| `progress` | a bar and its percentage | number, 0..`max` | `max` (default 100) |
|
|
207
|
-
| `text` | one line | 1..120 characters | |
|
|
208
|
-
| `list` | a short list | 1..6 lines of 1..60 characters | |
|
|
209
|
-
| `badge` | a coloured word | 1..24 characters | `tone`, or `tones: { word: tone }` (`ok`, `warn`, `bad`, `info`, `muted`) |
|
|
210
|
-
| `spark` | a sparkline and its last number | 2..48 numbers | |
|
|
211
|
-
|
|
212
|
-
`label` (1..24 characters) is required for `stat`, `progress` and `spark`. `key` (`a-z`, `0-9`, `_`) names a value
|
|
213
|
-
in your `data`. `bind` shows a value the page already has: `state` (`working`, `idle`, `needs`, `stopped`,
|
|
214
|
-
`crashed`) on `text` or `badge`, `context_pct` on `stat` or `progress`, `cost_usd` on `stat`. Exactly one of the
|
|
215
|
-
two. A missing value shows `—`.
|
|
216
|
-
- `data` alone updates the placed widget's values: merged, `null` removes a key. Values must fit every item that shows
|
|
217
|
-
them; a key no item shows is refused. Data has **its own budget**, separate from theme changes: at least **10 s**
|
|
218
|
-
apart, at most **180 an hour**.
|
|
219
|
-
- The spec is at most 2048 bytes and the data at most 4096.
|
|
220
|
-
|
|
221
|
-
`remove_web_widget { slot? }` takes your widget out of one slot, or both (a change). `get_web_theme` and
|
|
222
|
-
`get_web_appearance` list your widgets.
|
|
223
|
-
|
|
224
|
-
```json
|
|
225
|
-
{ "slot": "chat_header", "spec": { "v": 1, "title": "Build", "items": [
|
|
226
|
-
{ "type": "progress", "label": "Tests", "key": "tests" },
|
|
227
|
-
{ "type": "badge", "label": "State", "bind": "state", "tones": { "working": "info", "needs": "warn" } },
|
|
228
|
-
{ "type": "text", "key": "step" } ] },
|
|
229
|
-
"data": { "tests": 40, "step": "Running unit tests" } }
|
|
230
|
-
```
|
|
231
|
-
|
|
232
|
-
Then, as you go: `set_web_widget { "slot": "chat_header", "data": { "tests": 75 } }`.
|
|
233
|
-
|
|
234
|
-
## Ambient effects
|
|
235
|
-
|
|
236
|
-
An ambient effect is **data only**: you choose a preset and its glyphs, the dashboard draws them. No code runs, so it
|
|
237
|
-
needs no Try, no preview consent and no measurement — use it for petals, snow, lanterns, sparkles and stars on a click.
|
|
238
|
-
|
|
239
|
-
`set_web_ambient { preset, glyphs, colors?, count?, duration?, size?, sway?, spread?, rotate?, opacity? }`:
|
|
240
|
-
|
|
241
|
-
| `preset` | What it draws | `count` | `duration` (seconds, [min, max]) |
|
|
242
|
-
|---|---|---|---|
|
|
243
|
-
| `fall` | glyphs drifting down behind your chat, endlessly | 1..24 particles (default 12) | 4..30 (default [9, 19]) |
|
|
244
|
-
| `rise` | the same, drifting up | 1..24 (12) | 4..30 ([9, 19]) |
|
|
245
|
-
| `twinkle` | glyphs pulsing in place | 1..24 (12) | 1..10 ([2, 5]) |
|
|
246
|
-
| `burst-on-click` | glyphs scattering from where a person clicks or taps in your chat | 4..16 per click (10) | 0.3..2 ([0.5, 0.9]) |
|
|
247
|
-
|
|
248
|
-
- `glyphs`: 1..4, picked at random per particle — a string of 1..2 characters (an emoji, `✦`, `❀`), or `{ "asset": id }`,
|
|
249
|
-
a picture you uploaded with `set_web_theme_asset` to the `glyph` slot.
|
|
250
|
-
- `colors`: 0..5 `#rrggbb` for text glyphs (default: your accent). `size`: [min, max] px, 10..40 (default [14, 22]).
|
|
251
|
-
`sway`: sideways drift for fall and rise, 0..80 px (40). `spread`: how far a burst scatters, [min, max] 20..120 px
|
|
252
|
-
([34, 90]). `rotate`: 0..720 degrees over a run (300). `opacity`: [start, peak, end], each 0..1 ([0, 0.85, 0.15]).
|
|
253
|
-
- Your chat holds **one looping ambient** (`fall`, `rise` or `twinkle`) **and one `burst-on-click`**: setting one
|
|
254
|
-
replaces only its own kind. `clear_web_ambient { which? }` clears `loop`, `click`, or both.
|
|
255
|
-
- It is drawn **behind your messages** and never takes a click (a burst shows over them for a moment, then is gone).
|
|
256
|
-
- Who sees it: everyone who shows agents' looks, the public link included. Not with "Show agents' themes, effects and
|
|
257
|
-
widgets" off, `?safe=1`, or on a device that chose to follow the system's reduced-motion setting while
|
|
258
|
-
the system asks for it. A hidden tab pauses it.
|
|
259
|
-
- Like a theme: a change for the rate limit, refused while a person locked your look; one a person set is theirs
|
|
260
|
-
(`person_placed`). A person's Reset of your theme clears it. `get_web_appearance` shows it, and
|
|
261
|
-
`preview_web_appearance` draws the looping one, still, behind the bubbles.
|
|
262
|
-
|
|
263
|
-
```json
|
|
264
|
-
{ "preset": "fall", "glyphs": ["🌸", "❀", "✿"], "colors": ["#f4a7b9", "#ffd1dc"], "count": 12, "duration": [9, 19] }
|
|
265
|
-
```
|
|
266
|
-
|
|
267
|
-
Then stars on a click, alongside: `set_web_ambient { "preset": "burst-on-click", "glyphs": ["✦", "✧"] }`.
|
|
268
|
-
|
|
269
|
-
## Your character in the Office view
|
|
270
|
-
|
|
271
|
-
Fleet → Org chart → **Office** draws the fleet as an office, with a little character per agent placed by its state.
|
|
272
|
-
When a person switches the **office** dashboard feature on for you (`office_access: true`; off until then — the tools
|
|
273
|
-
are not in your list), you can direct your own character for a moment:
|
|
274
|
-
|
|
275
|
-
- `office_view { office? }`: the stored offices you are in — each `{ id, name, skin, members: [{ name, display_name?,
|
|
276
|
-
state }], spots: { seats: [{ area, index, x, y }], waypoints: [{ id, x, y }], npcs: [{ id, label, x, y }], door } }` —
|
|
277
|
-
your current `act` (or null) and `cooldown_ms` (0: you may act now). `walks: false`: the office is drawn as desks (a
|
|
278
|
-
built-in style such as pixel or studio, or a pack without zones) — no spots; `say` and `pose` show, `go` is refused.
|
|
279
|
-
- `office_set { office?, go?, say?, pose?, seconds?, clear? }`: `go` is exactly one of `seat` (`"area:index"`, as
|
|
280
|
-
office_view lists it), `waypoint` (an id) or `person` (a member of the same office); `say` a line of 1..40 characters
|
|
281
|
-
(a speech bubble); `pose` one of idle, working, needs, paused; `seconds` 5..120 (default 30). `clear: true`, alone,
|
|
282
|
-
ends your act. `office` is needed only when you are in more than one.
|
|
283
|
-
- Each call replaces your act. It ends when its seconds are up or you begin new work (the turn you set it in, and being
|
|
284
|
-
idle after, keep it; working again after that, or after setting it while idle, ends it); it is not shown while you
|
|
285
|
-
need a person (needs, crashed, stuck), are paused or stopped, or are asleep at bedtime — real work always shows. At most **6 calls a minute** and **60 an hour**: a refusal says `cooldown_ms`.
|
|
286
|
-
|
|
287
|
-
```json
|
|
288
|
-
{ "go": { "person": "atlas" }, "say": "Review's ready", "seconds": 20 }
|
|
289
|
-
```
|
|
290
|
-
|
|
291
|
-
## Office skin packs (everyone's)
|
|
292
|
-
|
|
293
|
-
The Office view draws offices in **skin packs**, which every viewer on the fleet sees. When a person switches the
|
|
294
|
-
**office_packs** dashboard feature on for you (`office_pack_access: true`, its own switch — off until then, and the
|
|
295
|
-
tools are not in your list), you can publish them yourself instead of asking a person to upload each fix by hand:
|
|
296
|
-
|
|
297
|
-
- `office_pack_list {}` first: each pack's `id`, `name`, `files`, `bytes`, `version`, `previous` (a kept previous
|
|
298
|
-
version you can restore, or null) and the `offices` drawn in it; the stored offices and their style; the fleet's
|
|
299
|
-
`approval` (`"apply"`: at once; `"approve"`: a fleet admin's yes first — the default); your `pending` changes; the
|
|
300
|
-
`limits` and what is `left` of your hour.
|
|
301
|
-
- `office_pack_check { dir }` runs the host's own checks and stores nothing: `{ result: "PACK OK", packs: [...] }` or the
|
|
302
|
-
first refusal. `dir` is a folder with its `manifest.json` and the PNGs at the paths the manifest names, in your working
|
|
303
|
-
directory or the fleet's shared folder (`~/.agend/shared`); a symlink is followed and must stay inside. Only those
|
|
304
|
-
files are read. Or `manifest` (the object) + `files` (`{ "<name it uses>": "<path>" }`); `packs: [...]` for several.
|
|
305
|
-
- `office_pack_upload` (the same inputs) keeps it — an id the fleet keeps is **replaced** at once (no delete first; on
|
|
306
|
-
any failure the old one stays) and its previous version is kept. If a stored office's layout overrides would no
|
|
307
|
-
longer fit (a seat count changed, a seat left its area, an item is gone), check and upload refuse with the office
|
|
308
|
-
and the rule: fix the pack, or send `drop_invalid_overrides: true` to drop exactly those entries (the result names
|
|
309
|
-
them). With `"approve"` the answer is `{ pending }`: it waits for an admin's yes — say so; do not upload it again. A pending change that drops layout entries is applied
|
|
310
|
-
only if it still drops exactly the entries its notice named: if an office was edited meanwhile, the approval is
|
|
311
|
-
refused and you send the change again (#2695).
|
|
312
|
-
- `office_pack_restore { id }` brings back the previous version (the replaced one becomes the previous);
|
|
313
|
-
`office_pack_delete { id, keep_previous? }`; `office_set_style { office, pack }` points a stored office at a pack or a
|
|
314
|
-
built-in style (pixel, studio, cozy).
|
|
315
|
-
- Every change is logged with each picture's sha256 and told to the fleet's admins. At most **20 batches and 200 MiB an
|
|
316
|
-
hour**: one call is one batch (up to 16 packs), so send a whole set of fixes in one `packs: [...]`.
|
|
317
|
-
- `office_pack_check` has its own allowance: at most **60 checks and 1 GiB (as sent) an hour**. Every check counts,
|
|
318
|
-
passed or refused, so fix what a refusal names before checking again. `office_pack_list` shows `check_left`.
|
|
319
|
-
|
|
320
|
-
The skin-pack manifest format — every key, its ranges, a minimal example — and the limits are in the Office guide:
|
|
321
|
-
[docs/office.md → Make a skin pack](https://github.com/songsid/AgEnD/blob/main/docs/office.md#make-a-skin-pack). Point people there too when they ask how the Office works.
|
|
322
|
-
|
|
323
|
-
## Limits
|
|
324
|
-
|
|
325
|
-
- At least **30 s** between changes, at most **10 changes an hour** — refused with `rate_limited` and
|
|
326
|
-
`retry_after_s`. Only an accepted change counts; a refused or invalid one costs nothing.
|
|
327
|
-
- Picture uploads are not counted. Each picture slot's size limits, your picture quota and
|
|
328
|
-
each file's own caps still apply; using a picture in your theme is a change.
|
|
329
|
-
- Widget values (`set_web_widget` with `data` only): at least **10 s** apart, at most **180 an hour**, apart from the
|
|
330
|
-
above.
|
|
331
|
-
- `set_web_ambient` and `clear_web_ambient` are changes.
|
|
332
|
-
- Plan the whole look, check it in one `set_web_theme`, then preview — don't iterate change by change.
|
|
333
|
-
|
|
334
|
-
## A good workflow
|
|
335
|
-
|
|
336
|
-
1. `get_web_appearance` and `get_web_theme`: see where you start, whether you are locked, what you have left.
|
|
337
|
-
2. Upload the pictures you need (`set_web_theme_asset`), one per slot.
|
|
338
|
-
3. One `set_web_theme` with everything; fix any `errors` it names.
|
|
339
|
-
4. `preview_web_appearance` and Read the SVGs for both modes. Check contrast and that your card reads well.
|
|
340
|
-
|
|
341
|
-
From a shell: `agend-agent theme get|set key=value…|set --json '<patch>'|clear <path>…|asset <slot> <file>|reset`,
|
|
342
|
-
`agend-agent appearance`, `agend-agent appearance preview [light|dark]`, and
|
|
343
|
-
`agend-agent widget set <slot> '<spec json>' ['<data json>']|data <slot> '<data json>'|remove [slot]`,
|
|
344
|
-
`agend-agent ambient set '<spec json>'|clear [loop|click]`, `agend-agent office view [office]|set '<json>'`.
|
|
345
|
-
|
|
346
|
-
## Files in your working directory
|
|
347
|
-
|
|
348
|
-
Asset uploads must be inside your working directory. For an external project,
|
|
349
|
-
use files there as before. For your own AgEnD-managed workspace under `~/.agend/workspaces/`, ordinary files there
|
|
350
|
-
also work; no staging folder is required. This includes the standard `<your-instance-name>` folder (ClassicBot and
|
|
351
|
-
instances without a project directory) and an exclusively configured folder with another name, such as instance
|
|
352
|
-
`alpha` with `working_directory: ~/.agend/workspaces/alpha-home` in `fleet.yaml`. Its canonical configured path must
|
|
353
|
-
not overlap another instance's configured or standard workspace, including persisted ClassicBot peers that are
|
|
354
|
-
stopped or paused. The `workspaces/` root itself is not a workspace.
|
|
355
|
-
|
|
356
|
-
General, adapter-specific General (such as `general-telegram`), and other configured working directories elsewhere
|
|
357
|
-
inside the AgEnD state directory must stage inputs under **`web-assets/`**. For example, put a banner at
|
|
358
|
-
`web-assets/banner.png`, relative to that working directory. Its root
|
|
359
|
-
and backend configuration folders are not upload areas. Generated previews use the fixed
|
|
360
|
-
`.agend/appearance/` directory and can be read back there.
|
|
361
|
-
|
|
362
|
-
The daemon uses its launch identity and configuration; the CLI resolves `AGEND_INSTANCE_NAME` against `fleet.yaml`.
|
|
363
|
-
These checks require a canonical, exclusively owned directory: the state root, shared or overlapping configured
|
|
364
|
-
working directories, another instance's directory, and the host's state stores never qualify. No tool argument can
|
|
365
|
-
select an identity or working directory. Missing or unreadable ownership evidence refuses in-state access.
|
|
366
|
-
|
|
367
|
-
Inside all admitted in-state areas, `.env`, databases and their WAL/SHM/journal files, `instances/`,
|
|
368
|
-
`credential-profiles/`, `inbox/`, `web-files/`, `web-chat.json`, `chat-logs/`, backend credential/session/config files,
|
|
369
|
-
and hidden files or folders are refused. The only hidden-directory exception is the generated `.agend/`
|
|
370
|
-
output directory above; their contents still undergo the sensitive-name checks. Hard-linked state files are also
|
|
371
|
-
refused. Copy an intended asset into staging as a new regular file; do not link a private state file there.
|
|
372
|
-
|
|
373
|
-
Paths are checked after resolving symlinks. A symlink named after General or a workspace, or in its managed parent
|
|
374
|
-
path, cannot widen access; uploaded files themselves must not be symlinks. Containment still applies to relative and
|
|
375
|
-
absolute paths and to each uploaded file. The CLI name and current directory are controlled by its shell:
|
|
376
|
-
these local checks prevent accidental uploads, but do not isolate shells running as the same OS user.
|