@rubytech/create-maxy-code 0.1.592 → 0.1.594
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/package.json +2 -2
- package/payload/platform/package.json +1 -0
- package/payload/platform/plugins/admin/skills/platform-architecture/SKILL.md +11 -5
- package/payload/platform/plugins/admin/skills/whats-new/SKILL.md +11 -0
- package/payload/platform/plugins/cloudflare/PLUGIN.md +2 -0
- package/payload/platform/plugins/docs/references/internals.md +5 -3
- package/payload/platform/plugins/docs/references/telegram-guide.md +5 -1
- package/payload/platform/plugins/scheduling/PLUGIN.md +1 -1
- package/payload/platform/plugins/scheduling/mcp/dist/scripts/__tests__/agent-turn-dispatch.test.js +15 -2
- package/payload/platform/plugins/scheduling/mcp/dist/scripts/__tests__/agent-turn-dispatch.test.js.map +1 -1
- package/payload/platform/plugins/scheduling/mcp/dist/scripts/agent-turn-dispatch.d.ts.map +1 -1
- package/payload/platform/plugins/scheduling/mcp/dist/scripts/agent-turn-dispatch.js +7 -2
- package/payload/platform/plugins/scheduling/mcp/dist/scripts/agent-turn-dispatch.js.map +1 -1
- package/payload/platform/plugins/scheduling/mcp/dist/tools/__tests__/scheduling-gate.test.js +125 -1
- package/payload/platform/plugins/scheduling/mcp/dist/tools/__tests__/scheduling-gate.test.js.map +1 -1
- package/payload/platform/plugins/scheduling/mcp/dist/tools/scheduling-gate.d.ts +28 -0
- package/payload/platform/plugins/scheduling/mcp/dist/tools/scheduling-gate.d.ts.map +1 -1
- package/payload/platform/plugins/scheduling/mcp/dist/tools/scheduling-gate.js +72 -12
- package/payload/platform/plugins/scheduling/mcp/dist/tools/scheduling-gate.js.map +1 -1
- package/payload/platform/plugins/telegram/PLUGIN.md +12 -5
- package/payload/platform/plugins/telegram/mcp/dist/__tests__/ask-tool.test.js +31 -0
- package/payload/platform/plugins/telegram/mcp/dist/__tests__/ask-tool.test.js.map +1 -1
- package/payload/platform/plugins/telegram/mcp/dist/__tests__/card-tool.test.js +30 -0
- package/payload/platform/plugins/telegram/mcp/dist/__tests__/card-tool.test.js.map +1 -1
- package/payload/platform/plugins/telegram/mcp/dist/__tests__/media-fetch-tool.test.js +24 -0
- package/payload/platform/plugins/telegram/mcp/dist/__tests__/media-fetch-tool.test.js.map +1 -1
- package/payload/platform/plugins/telegram/mcp/dist/__tests__/media-send-tool.test.js +31 -0
- package/payload/platform/plugins/telegram/mcp/dist/__tests__/media-send-tool.test.js.map +1 -1
- package/payload/platform/plugins/telegram/mcp/dist/__tests__/public-pin-registry.test.d.ts +2 -0
- package/payload/platform/plugins/telegram/mcp/dist/__tests__/public-pin-registry.test.d.ts.map +1 -0
- package/payload/platform/plugins/telegram/mcp/dist/__tests__/public-pin-registry.test.js +55 -0
- package/payload/platform/plugins/telegram/mcp/dist/__tests__/public-pin-registry.test.js.map +1 -0
- package/payload/platform/plugins/telegram/mcp/dist/__tests__/public-pin.test.d.ts +2 -0
- package/payload/platform/plugins/telegram/mcp/dist/__tests__/public-pin.test.d.ts.map +1 -0
- package/payload/platform/plugins/telegram/mcp/dist/__tests__/public-pin.test.js +89 -0
- package/payload/platform/plugins/telegram/mcp/dist/__tests__/public-pin.test.js.map +1 -0
- package/payload/platform/plugins/telegram/mcp/dist/index.js +13 -42
- package/payload/platform/plugins/telegram/mcp/dist/index.js.map +1 -1
- package/payload/platform/plugins/telegram/mcp/dist/lib/public-pin.d.ts +80 -0
- package/payload/platform/plugins/telegram/mcp/dist/lib/public-pin.d.ts.map +1 -0
- package/payload/platform/plugins/telegram/mcp/dist/lib/public-pin.js +96 -0
- package/payload/platform/plugins/telegram/mcp/dist/lib/public-pin.js.map +1 -0
- package/payload/platform/plugins/telegram/mcp/dist/tools/ask.d.ts +5 -0
- package/payload/platform/plugins/telegram/mcp/dist/tools/ask.d.ts.map +1 -1
- package/payload/platform/plugins/telegram/mcp/dist/tools/ask.js.map +1 -1
- package/payload/platform/plugins/telegram/mcp/dist/tools/card.d.ts +5 -0
- package/payload/platform/plugins/telegram/mcp/dist/tools/card.d.ts.map +1 -1
- package/payload/platform/plugins/telegram/mcp/dist/tools/card.js.map +1 -1
- package/payload/platform/plugins/telegram/mcp/dist/tools/media-fetch.d.ts +5 -0
- package/payload/platform/plugins/telegram/mcp/dist/tools/media-fetch.d.ts.map +1 -1
- package/payload/platform/plugins/telegram/mcp/dist/tools/media-fetch.js.map +1 -1
- package/payload/platform/plugins/telegram/mcp/dist/tools/media-send.d.ts +5 -0
- package/payload/platform/plugins/telegram/mcp/dist/tools/media-send.d.ts.map +1 -1
- package/payload/platform/plugins/telegram/mcp/dist/tools/media-send.js.map +1 -1
- package/payload/platform/plugins/telegram/mcp/dist/tools/thread.d.ts +5 -0
- package/payload/platform/plugins/telegram/mcp/dist/tools/thread.d.ts.map +1 -1
- package/payload/platform/plugins/telegram/mcp/dist/tools/thread.js.map +1 -1
- package/payload/platform/scripts/__tests__/agent-identity-reconcile.test.sh +110 -0
- package/payload/platform/scripts/__tests__/check-orphan-dist.test.sh +87 -0
- package/payload/platform/scripts/check-orphan-dist.mjs +143 -0
- package/payload/platform/scripts/lib/agent-identity-reconcile.sh +122 -0
- package/payload/platform/scripts/lib/provision-account-dir.sh +8 -26
- package/payload/platform/scripts/setup-account.sh +15 -0
- package/payload/platform/services/claude-session-manager/dist/http-server.d.ts +37 -0
- package/payload/platform/services/claude-session-manager/dist/http-server.d.ts.map +1 -1
- package/payload/platform/services/claude-session-manager/dist/http-server.js +178 -13
- package/payload/platform/services/claude-session-manager/dist/http-server.js.map +1 -1
- package/payload/platform/services/claude-session-manager/dist/index.js +5 -0
- package/payload/platform/services/claude-session-manager/dist/index.js.map +1 -1
- package/payload/platform/services/claude-session-manager/dist/public-agent-reachability.d.ts +5 -0
- package/payload/platform/services/claude-session-manager/dist/public-agent-reachability.d.ts.map +1 -1
- package/payload/platform/services/claude-session-manager/dist/public-agent-reachability.js +42 -1
- package/payload/platform/services/claude-session-manager/dist/public-agent-reachability.js.map +1 -1
- package/payload/platform/services/claude-session-manager/dist/rc-public-lockdown.d.ts +13 -5
- package/payload/platform/services/claude-session-manager/dist/rc-public-lockdown.d.ts.map +1 -1
- package/payload/platform/services/claude-session-manager/dist/rc-public-lockdown.js +23 -9
- package/payload/platform/services/claude-session-manager/dist/rc-public-lockdown.js.map +1 -1
- package/payload/platform/services/claude-session-manager/dist/telegram-channel-mcp.d.ts +7 -4
- package/payload/platform/services/claude-session-manager/dist/telegram-channel-mcp.d.ts.map +1 -1
- package/payload/platform/services/claude-session-manager/dist/telegram-channel-mcp.js +5 -3
- package/payload/platform/services/claude-session-manager/dist/telegram-channel-mcp.js.map +1 -1
- package/payload/platform/services/claude-session-manager/dist/telegram-channel-store.d.ts +15 -1
- package/payload/platform/services/claude-session-manager/dist/telegram-channel-store.d.ts.map +1 -1
- package/payload/platform/services/claude-session-manager/dist/telegram-channel-store.js +16 -7
- package/payload/platform/services/claude-session-manager/dist/telegram-channel-store.js.map +1 -1
- package/payload/platform/services/claude-session-manager/dist/telegram-plugin-mcp.d.ts +28 -0
- package/payload/platform/services/claude-session-manager/dist/telegram-plugin-mcp.d.ts.map +1 -0
- package/payload/platform/services/claude-session-manager/dist/telegram-plugin-mcp.js +53 -0
- package/payload/platform/services/claude-session-manager/dist/telegram-plugin-mcp.js.map +1 -0
- package/payload/platform/services/claude-session-manager/dist/wa-channel-mcp.d.ts +9 -5
- package/payload/platform/services/claude-session-manager/dist/wa-channel-mcp.d.ts.map +1 -1
- package/payload/platform/services/claude-session-manager/dist/wa-channel-mcp.js +12 -6
- package/payload/platform/services/claude-session-manager/dist/wa-channel-mcp.js.map +1 -1
- package/payload/platform/services/claude-session-manager/dist/webchat-channel-mcp.d.ts +7 -3
- package/payload/platform/services/claude-session-manager/dist/webchat-channel-mcp.d.ts.map +1 -1
- package/payload/platform/services/claude-session-manager/dist/webchat-channel-mcp.js +5 -1
- package/payload/platform/services/claude-session-manager/dist/webchat-channel-mcp.js.map +1 -1
- package/payload/platform/services/telegram-channel/dist/instructions.d.ts +14 -2
- package/payload/platform/services/telegram-channel/dist/instructions.d.ts.map +1 -1
- package/payload/platform/services/telegram-channel/dist/instructions.js +34 -3
- package/payload/platform/services/telegram-channel/dist/instructions.js.map +1 -1
- package/payload/platform/templates/agents/public/IDENTITY.md +3 -3
- package/payload/server/server.js +74 -9
- package/payload/platform/lib/anthropic-key/dist/index.d.ts +0 -22
- package/payload/platform/lib/anthropic-key/dist/index.d.ts.map +0 -1
- package/payload/platform/lib/anthropic-key/dist/index.js +0 -232
- package/payload/platform/lib/anthropic-key/dist/index.js.map +0 -1
- package/payload/platform/lib/graph-search/dist/query-expansion.d.ts +0 -37
- package/payload/platform/lib/graph-search/dist/query-expansion.d.ts.map +0 -1
- package/payload/platform/lib/graph-search/dist/query-expansion.js +0 -101
- package/payload/platform/lib/graph-search/dist/query-expansion.js.map +0 -1
- package/payload/platform/lib/oauth-llm/dist/index.d.ts +0 -116
- package/payload/platform/lib/oauth-llm/dist/index.d.ts.map +0 -1
- package/payload/platform/lib/oauth-llm/dist/index.js +0 -386
- package/payload/platform/lib/oauth-llm/dist/index.js.map +0 -1
- package/payload/platform/lib/screening-patterns/dist/index.d.ts +0 -29
- package/payload/platform/lib/screening-patterns/dist/index.d.ts.map +0 -1
- package/payload/platform/lib/screening-patterns/dist/index.js +0 -48
- package/payload/platform/lib/screening-patterns/dist/index.js.map +0 -1
- package/payload/platform/plugins/admin/mcp/dist/__tests__/admin-identity-authenticate.test.d.ts +0 -2
- package/payload/platform/plugins/admin/mcp/dist/__tests__/admin-identity-authenticate.test.d.ts.map +0 -1
- package/payload/platform/plugins/admin/mcp/dist/__tests__/admin-identity-authenticate.test.js +0 -34
- package/payload/platform/plugins/admin/mcp/dist/__tests__/admin-identity-authenticate.test.js.map +0 -1
- package/payload/platform/plugins/admin/mcp/dist/lib/onboarding.d.ts +0 -39
- package/payload/platform/plugins/admin/mcp/dist/lib/onboarding.d.ts.map +0 -1
- package/payload/platform/plugins/admin/mcp/dist/lib/onboarding.js +0 -249
- package/payload/platform/plugins/admin/mcp/dist/lib/onboarding.js.map +0 -1
- package/payload/platform/plugins/admin/mcp/dist/tools/admin-identity-authenticate.d.ts +0 -6
- package/payload/platform/plugins/admin/mcp/dist/tools/admin-identity-authenticate.d.ts.map +0 -1
- package/payload/platform/plugins/admin/mcp/dist/tools/admin-identity-authenticate.js +0 -32
- package/payload/platform/plugins/admin/mcp/dist/tools/admin-identity-authenticate.js.map +0 -1
- package/payload/platform/plugins/cloudflare/mcp/dist/lib/cloudflared.d.ts +0 -283
- package/payload/platform/plugins/cloudflare/mcp/dist/lib/cloudflared.d.ts.map +0 -1
- package/payload/platform/plugins/cloudflare/mcp/dist/lib/cloudflared.js +0 -1155
- package/payload/platform/plugins/cloudflare/mcp/dist/lib/cloudflared.js.map +0 -1
- package/payload/platform/plugins/cloudflare/mcp/dist/lib/setup-orchestrator.d.ts +0 -90
- package/payload/platform/plugins/cloudflare/mcp/dist/lib/setup-orchestrator.d.ts.map +0 -1
- package/payload/platform/plugins/cloudflare/mcp/dist/lib/setup-orchestrator.js +0 -551
- package/payload/platform/plugins/cloudflare/mcp/dist/lib/setup-orchestrator.js.map +0 -1
- package/payload/platform/plugins/email/mcp/dist/lib/claude-bridge.d.ts +0 -17
- package/payload/platform/plugins/email/mcp/dist/lib/claude-bridge.d.ts.map +0 -1
- package/payload/platform/plugins/email/mcp/dist/lib/claude-bridge.js +0 -186
- package/payload/platform/plugins/email/mcp/dist/lib/claude-bridge.js.map +0 -1
- package/payload/platform/plugins/email/mcp/dist/lib/screening.d.ts +0 -29
- package/payload/platform/plugins/email/mcp/dist/lib/screening.d.ts.map +0 -1
- package/payload/platform/plugins/email/mcp/dist/lib/screening.js +0 -105
- package/payload/platform/plugins/email/mcp/dist/lib/screening.js.map +0 -1
- package/payload/platform/plugins/email/mcp/dist/scripts/email-auto-respond.d.ts +0 -38
- package/payload/platform/plugins/email/mcp/dist/scripts/email-auto-respond.d.ts.map +0 -1
- package/payload/platform/plugins/email/mcp/dist/scripts/email-auto-respond.js +0 -817
- package/payload/platform/plugins/email/mcp/dist/scripts/email-auto-respond.js.map +0 -1
- package/payload/platform/plugins/email/mcp/dist/scripts/email-fetch.d.ts +0 -30
- package/payload/platform/plugins/email/mcp/dist/scripts/email-fetch.d.ts.map +0 -1
- package/payload/platform/plugins/email/mcp/dist/scripts/email-fetch.js +0 -215
- package/payload/platform/plugins/email/mcp/dist/scripts/email-fetch.js.map +0 -1
- package/payload/platform/plugins/email/mcp/dist/tools/email-auto-respond-config.d.ts +0 -19
- package/payload/platform/plugins/email/mcp/dist/tools/email-auto-respond-config.d.ts.map +0 -1
- package/payload/platform/plugins/email/mcp/dist/tools/email-auto-respond-config.js +0 -151
- package/payload/platform/plugins/email/mcp/dist/tools/email-auto-respond-config.js.map +0 -1
- package/payload/platform/plugins/email/mcp/dist/tools/email-classify.d.ts +0 -6
- package/payload/platform/plugins/email/mcp/dist/tools/email-classify.d.ts.map +0 -1
- package/payload/platform/plugins/email/mcp/dist/tools/email-classify.js +0 -89
- package/payload/platform/plugins/email/mcp/dist/tools/email-classify.js.map +0 -1
- package/payload/platform/plugins/memory/mcp/dist/lib/__tests__/compiled-truth-rewriter-operator-hint.test.d.ts +0 -2
- package/payload/platform/plugins/memory/mcp/dist/lib/__tests__/compiled-truth-rewriter-operator-hint.test.d.ts.map +0 -1
- package/payload/platform/plugins/memory/mcp/dist/lib/__tests__/compiled-truth-rewriter-operator-hint.test.js +0 -90
- package/payload/platform/plugins/memory/mcp/dist/lib/__tests__/compiled-truth-rewriter-operator-hint.test.js.map +0 -1
- package/payload/platform/plugins/memory/mcp/dist/lib/__tests__/llm-classifier.test.d.ts +0 -2
- package/payload/platform/plugins/memory/mcp/dist/lib/__tests__/llm-classifier.test.d.ts.map +0 -1
- package/payload/platform/plugins/memory/mcp/dist/lib/__tests__/llm-classifier.test.js +0 -226
- package/payload/platform/plugins/memory/mcp/dist/lib/__tests__/llm-classifier.test.js.map +0 -1
- package/payload/platform/plugins/memory/mcp/dist/lib/compiled-truth-rewriter.d.ts +0 -60
- package/payload/platform/plugins/memory/mcp/dist/lib/compiled-truth-rewriter.d.ts.map +0 -1
- package/payload/platform/plugins/memory/mcp/dist/lib/compiled-truth-rewriter.js +0 -169
- package/payload/platform/plugins/memory/mcp/dist/lib/compiled-truth-rewriter.js.map +0 -1
- package/payload/platform/plugins/memory/mcp/dist/lib/llm-classifier.d.ts +0 -248
- package/payload/platform/plugins/memory/mcp/dist/lib/llm-classifier.d.ts.map +0 -1
- package/payload/platform/plugins/memory/mcp/dist/lib/llm-classifier.js +0 -824
- package/payload/platform/plugins/memory/mcp/dist/lib/llm-classifier.js.map +0 -1
- package/payload/platform/plugins/memory/mcp/dist/lib/llm-ranker.d.ts +0 -63
- package/payload/platform/plugins/memory/mcp/dist/lib/llm-ranker.d.ts.map +0 -1
- package/payload/platform/plugins/memory/mcp/dist/lib/llm-ranker.js +0 -210
- package/payload/platform/plugins/memory/mcp/dist/lib/llm-ranker.js.map +0 -1
- package/payload/platform/plugins/memory/mcp/dist/lib/typed-edge-pass.d.ts +0 -35
- package/payload/platform/plugins/memory/mcp/dist/lib/typed-edge-pass.d.ts.map +0 -1
- package/payload/platform/plugins/memory/mcp/dist/lib/typed-edge-pass.js +0 -28
- package/payload/platform/plugins/memory/mcp/dist/lib/typed-edge-pass.js.map +0 -1
- package/payload/platform/plugins/memory/mcp/dist/tools/__tests__/conversation-archive-derive-insights-emit.test.d.ts +0 -2
- package/payload/platform/plugins/memory/mcp/dist/tools/__tests__/conversation-archive-derive-insights-emit.test.d.ts.map +0 -1
- package/payload/platform/plugins/memory/mcp/dist/tools/__tests__/conversation-archive-derive-insights-emit.test.js +0 -68
- package/payload/platform/plugins/memory/mcp/dist/tools/__tests__/conversation-archive-derive-insights-emit.test.js.map +0 -1
- package/payload/platform/plugins/memory/mcp/dist/tools/__tests__/memory-archive-write-emit.test.d.ts +0 -2
- package/payload/platform/plugins/memory/mcp/dist/tools/__tests__/memory-archive-write-emit.test.d.ts.map +0 -1
- package/payload/platform/plugins/memory/mcp/dist/tools/__tests__/memory-archive-write-emit.test.js +0 -88
- package/payload/platform/plugins/memory/mcp/dist/tools/__tests__/memory-archive-write-emit.test.js.map +0 -1
- package/payload/platform/plugins/memory/mcp/dist/tools/__tests__/memory-classify-emit.test.d.ts +0 -2
- package/payload/platform/plugins/memory/mcp/dist/tools/__tests__/memory-classify-emit.test.d.ts.map +0 -1
- package/payload/platform/plugins/memory/mcp/dist/tools/__tests__/memory-classify-emit.test.js +0 -58
- package/payload/platform/plugins/memory/mcp/dist/tools/__tests__/memory-classify-emit.test.js.map +0 -1
- package/payload/platform/plugins/memory/mcp/dist/tools/__tests__/memory-delete-emit.test.d.ts +0 -2
- package/payload/platform/plugins/memory/mcp/dist/tools/__tests__/memory-delete-emit.test.d.ts.map +0 -1
- package/payload/platform/plugins/memory/mcp/dist/tools/__tests__/memory-delete-emit.test.js +0 -64
- package/payload/platform/plugins/memory/mcp/dist/tools/__tests__/memory-delete-emit.test.js.map +0 -1
- package/payload/platform/plugins/memory/mcp/dist/tools/__tests__/memory-edit-attachment-emit.test.d.ts +0 -2
- package/payload/platform/plugins/memory/mcp/dist/tools/__tests__/memory-edit-attachment-emit.test.d.ts.map +0 -1
- package/payload/platform/plugins/memory/mcp/dist/tools/__tests__/memory-edit-attachment-emit.test.js +0 -70
- package/payload/platform/plugins/memory/mcp/dist/tools/__tests__/memory-edit-attachment-emit.test.js.map +0 -1
- package/payload/platform/plugins/memory/mcp/dist/tools/__tests__/memory-empty-trash-emit.test.d.ts +0 -2
- package/payload/platform/plugins/memory/mcp/dist/tools/__tests__/memory-empty-trash-emit.test.d.ts.map +0 -1
- package/payload/platform/plugins/memory/mcp/dist/tools/__tests__/memory-empty-trash-emit.test.js +0 -48
- package/payload/platform/plugins/memory/mcp/dist/tools/__tests__/memory-empty-trash-emit.test.js.map +0 -1
- package/payload/platform/plugins/memory/mcp/dist/tools/__tests__/memory-ingest-emit.test.d.ts +0 -2
- package/payload/platform/plugins/memory/mcp/dist/tools/__tests__/memory-ingest-emit.test.d.ts.map +0 -1
- package/payload/platform/plugins/memory/mcp/dist/tools/__tests__/memory-ingest-emit.test.js +0 -74
- package/payload/platform/plugins/memory/mcp/dist/tools/__tests__/memory-ingest-emit.test.js.map +0 -1
- package/payload/platform/plugins/memory/mcp/dist/tools/__tests__/memory-ingest-extract-emit.test.d.ts +0 -2
- package/payload/platform/plugins/memory/mcp/dist/tools/__tests__/memory-ingest-extract-emit.test.d.ts.map +0 -1
- package/payload/platform/plugins/memory/mcp/dist/tools/__tests__/memory-ingest-extract-emit.test.js +0 -47
- package/payload/platform/plugins/memory/mcp/dist/tools/__tests__/memory-ingest-extract-emit.test.js.map +0 -1
- package/payload/platform/plugins/memory/mcp/dist/tools/__tests__/memory-ingest-web-emit.test.d.ts +0 -2
- package/payload/platform/plugins/memory/mcp/dist/tools/__tests__/memory-ingest-web-emit.test.d.ts.map +0 -1
- package/payload/platform/plugins/memory/mcp/dist/tools/__tests__/memory-ingest-web-emit.test.js +0 -65
- package/payload/platform/plugins/memory/mcp/dist/tools/__tests__/memory-ingest-web-emit.test.js.map +0 -1
- package/payload/platform/plugins/memory/mcp/dist/tools/__tests__/memory-reindex-emit.test.d.ts +0 -2
- package/payload/platform/plugins/memory/mcp/dist/tools/__tests__/memory-reindex-emit.test.d.ts.map +0 -1
- package/payload/platform/plugins/memory/mcp/dist/tools/__tests__/memory-reindex-emit.test.js +0 -43
- package/payload/platform/plugins/memory/mcp/dist/tools/__tests__/memory-reindex-emit.test.js.map +0 -1
- package/payload/platform/plugins/memory/mcp/dist/tools/__tests__/memory-rename-attachment-emit.test.d.ts +0 -2
- package/payload/platform/plugins/memory/mcp/dist/tools/__tests__/memory-rename-attachment-emit.test.d.ts.map +0 -1
- package/payload/platform/plugins/memory/mcp/dist/tools/__tests__/memory-rename-attachment-emit.test.js +0 -65
- package/payload/platform/plugins/memory/mcp/dist/tools/__tests__/memory-rename-attachment-emit.test.js.map +0 -1
- package/payload/platform/plugins/memory/mcp/dist/tools/__tests__/memory-restore-emit.test.d.ts +0 -2
- package/payload/platform/plugins/memory/mcp/dist/tools/__tests__/memory-restore-emit.test.d.ts.map +0 -1
- package/payload/platform/plugins/memory/mcp/dist/tools/__tests__/memory-restore-emit.test.js +0 -49
- package/payload/platform/plugins/memory/mcp/dist/tools/__tests__/memory-restore-emit.test.js.map +0 -1
- package/payload/platform/plugins/memory/mcp/dist/tools/__tests__/memory-update-emit.test.d.ts +0 -2
- package/payload/platform/plugins/memory/mcp/dist/tools/__tests__/memory-update-emit.test.d.ts.map +0 -1
- package/payload/platform/plugins/memory/mcp/dist/tools/__tests__/memory-update-emit.test.js +0 -79
- package/payload/platform/plugins/memory/mcp/dist/tools/__tests__/memory-update-emit.test.js.map +0 -1
- package/payload/platform/plugins/memory/mcp/dist/tools/__tests__/memory-update-operator-hint.test.d.ts +0 -2
- package/payload/platform/plugins/memory/mcp/dist/tools/__tests__/memory-update-operator-hint.test.d.ts.map +0 -1
- package/payload/platform/plugins/memory/mcp/dist/tools/__tests__/memory-update-operator-hint.test.js +0 -329
- package/payload/platform/plugins/memory/mcp/dist/tools/__tests__/memory-update-operator-hint.test.js.map +0 -1
- package/payload/platform/plugins/memory/mcp/dist/tools/__tests__/memory-write-emit.test.d.ts +0 -2
- package/payload/platform/plugins/memory/mcp/dist/tools/__tests__/memory-write-emit.test.d.ts.map +0 -1
- package/payload/platform/plugins/memory/mcp/dist/tools/__tests__/memory-write-emit.test.js +0 -81
- package/payload/platform/plugins/memory/mcp/dist/tools/__tests__/memory-write-emit.test.js.map +0 -1
- package/payload/platform/plugins/memory/mcp/dist/tools/memory-classify.d.ts +0 -34
- package/payload/platform/plugins/memory/mcp/dist/tools/memory-classify.d.ts.map +0 -1
- package/payload/platform/plugins/memory/mcp/dist/tools/memory-classify.js +0 -62
- package/payload/platform/plugins/memory/mcp/dist/tools/memory-classify.js.map +0 -1
- package/payload/platform/plugins/memory/mcp/dist/tools/memory-rank.d.ts +0 -61
- package/payload/platform/plugins/memory/mcp/dist/tools/memory-rank.d.ts.map +0 -1
- package/payload/platform/plugins/memory/mcp/dist/tools/memory-rank.js +0 -102
- package/payload/platform/plugins/memory/mcp/dist/tools/memory-rank.js.map +0 -1
- package/payload/platform/plugins/memory/mcp/dist/tools/memory-signals-recent.d.ts +0 -35
- package/payload/platform/plugins/memory/mcp/dist/tools/memory-signals-recent.d.ts.map +0 -1
- package/payload/platform/plugins/memory/mcp/dist/tools/memory-signals-recent.js +0 -73
- package/payload/platform/plugins/memory/mcp/dist/tools/memory-signals-recent.js.map +0 -1
- package/payload/platform/plugins/memory/mcp/dist/tools/memory-typed-edge-pass.d.ts +0 -29
- package/payload/platform/plugins/memory/mcp/dist/tools/memory-typed-edge-pass.d.ts.map +0 -1
- package/payload/platform/plugins/memory/mcp/dist/tools/memory-typed-edge-pass.js +0 -22
- package/payload/platform/plugins/memory/mcp/dist/tools/memory-typed-edge-pass.js.map +0 -1
- package/payload/platform/plugins/memory/mcp/dist/tools/session-retrospective-skip-rate.d.ts +0 -30
- package/payload/platform/plugins/memory/mcp/dist/tools/session-retrospective-skip-rate.d.ts.map +0 -1
- package/payload/platform/plugins/memory/mcp/dist/tools/session-retrospective-skip-rate.js +0 -130
- package/payload/platform/plugins/memory/mcp/dist/tools/session-retrospective-skip-rate.js.map +0 -1
- package/payload/platform/plugins/outlook/mcp/dist/auth/pkce-flow.d.ts +0 -65
- package/payload/platform/plugins/outlook/mcp/dist/auth/pkce-flow.d.ts.map +0 -1
- package/payload/platform/plugins/outlook/mcp/dist/auth/pkce-flow.js +0 -262
- package/payload/platform/plugins/outlook/mcp/dist/auth/pkce-flow.js.map +0 -1
- package/payload/platform/plugins/scheduling/mcp/dist/lib/__tests__/normalise-start-date.test.d.ts +0 -2
- package/payload/platform/plugins/scheduling/mcp/dist/lib/__tests__/normalise-start-date.test.d.ts.map +0 -1
- package/payload/platform/plugins/scheduling/mcp/dist/lib/__tests__/normalise-start-date.test.js +0 -100
- package/payload/platform/plugins/scheduling/mcp/dist/lib/__tests__/normalise-start-date.test.js.map +0 -1
- package/payload/platform/plugins/scheduling/mcp/dist/lib/__tests__/scheduled-seat-id.test.d.ts +0 -2
- package/payload/platform/plugins/scheduling/mcp/dist/lib/__tests__/scheduled-seat-id.test.d.ts.map +0 -1
- package/payload/platform/plugins/scheduling/mcp/dist/lib/__tests__/scheduled-seat-id.test.js +0 -22
- package/payload/platform/plugins/scheduling/mcp/dist/lib/__tests__/scheduled-seat-id.test.js.map +0 -1
- package/payload/platform/plugins/scheduling/mcp/dist/lib/scheduled-seat-id.d.ts +0 -11
- package/payload/platform/plugins/scheduling/mcp/dist/lib/scheduled-seat-id.d.ts.map +0 -1
- package/payload/platform/plugins/scheduling/mcp/dist/lib/scheduled-seat-id.js +0 -19
- package/payload/platform/plugins/scheduling/mcp/dist/lib/scheduled-seat-id.js.map +0 -1
- package/payload/platform/plugins/telegram/mcp/dist/__tests__/invoice-tool.test.d.ts +0 -2
- package/payload/platform/plugins/telegram/mcp/dist/__tests__/invoice-tool.test.d.ts.map +0 -1
- package/payload/platform/plugins/telegram/mcp/dist/__tests__/invoice-tool.test.js +0 -196
- package/payload/platform/plugins/telegram/mcp/dist/__tests__/invoice-tool.test.js.map +0 -1
- package/payload/platform/plugins/telegram/mcp/dist/tools/invoice.d.ts +0 -70
- package/payload/platform/plugins/telegram/mcp/dist/tools/invoice.d.ts.map +0 -1
- package/payload/platform/plugins/telegram/mcp/dist/tools/invoice.js +0 -247
- package/payload/platform/plugins/telegram/mcp/dist/tools/invoice.js.map +0 -1
- package/payload/platform/plugins/telegram/mcp/dist/tools/message.d.ts +0 -21
- package/payload/platform/plugins/telegram/mcp/dist/tools/message.d.ts.map +0 -1
- package/payload/platform/plugins/telegram/mcp/dist/tools/message.js +0 -40
- package/payload/platform/plugins/telegram/mcp/dist/tools/message.js.map +0 -1
- package/payload/platform/plugins/url-get/mcp/dist/lib/summarise.d.ts +0 -8
- package/payload/platform/plugins/url-get/mcp/dist/lib/summarise.d.ts.map +0 -1
- package/payload/platform/plugins/url-get/mcp/dist/lib/summarise.js +0 -83
- package/payload/platform/plugins/url-get/mcp/dist/lib/summarise.js.map +0 -1
- package/payload/platform/plugins/workflows/mcp/dist/lib/llm-call.d.ts +0 -151
- package/payload/platform/plugins/workflows/mcp/dist/lib/llm-call.d.ts.map +0 -1
- package/payload/platform/plugins/workflows/mcp/dist/lib/llm-call.js +0 -299
- package/payload/platform/plugins/workflows/mcp/dist/lib/llm-call.js.map +0 -1
- package/payload/platform/services/claude-session-manager/dist/account-admin-census.d.ts +0 -39
- package/payload/platform/services/claude-session-manager/dist/account-admin-census.d.ts.map +0 -1
- package/payload/platform/services/claude-session-manager/dist/account-admin-census.js +0 -122
- package/payload/platform/services/claude-session-manager/dist/account-admin-census.js.map +0 -1
- package/payload/platform/services/claude-session-manager/dist/admin-identity-audit.d.ts +0 -39
- package/payload/platform/services/claude-session-manager/dist/admin-identity-audit.d.ts.map +0 -1
- package/payload/platform/services/claude-session-manager/dist/admin-identity-audit.js +0 -133
- package/payload/platform/services/claude-session-manager/dist/admin-identity-audit.js.map +0 -1
- package/payload/platform/services/claude-session-manager/dist/input-postcondition.d.ts +0 -22
- package/payload/platform/services/claude-session-manager/dist/input-postcondition.d.ts.map +0 -1
- package/payload/platform/services/claude-session-manager/dist/input-postcondition.js +0 -50
- package/payload/platform/services/claude-session-manager/dist/input-postcondition.js.map +0 -1
- package/payload/platform/services/claude-session-manager/dist/jsonl-observer.d.ts +0 -30
- package/payload/platform/services/claude-session-manager/dist/jsonl-observer.d.ts.map +0 -1
- package/payload/platform/services/claude-session-manager/dist/jsonl-observer.js +0 -204
- package/payload/platform/services/claude-session-manager/dist/jsonl-observer.js.map +0 -1
- package/payload/platform/services/claude-session-manager/dist/rc-script-spawn.d.ts +0 -80
- package/payload/platform/services/claude-session-manager/dist/rc-script-spawn.d.ts.map +0 -1
- package/payload/platform/services/claude-session-manager/dist/rc-script-spawn.js +0 -306
- package/payload/platform/services/claude-session-manager/dist/rc-script-spawn.js.map +0 -1
- package/payload/platform/services/claude-session-manager/dist/session-store.d.ts +0 -49
- package/payload/platform/services/claude-session-manager/dist/session-store.d.ts.map +0 -1
- package/payload/platform/services/claude-session-manager/dist/session-store.js +0 -52
- package/payload/platform/services/claude-session-manager/dist/session-store.js.map +0 -1
- package/payload/platform/services/claude-session-manager/dist/systemd-spawn.d.ts +0 -83
- package/payload/platform/services/claude-session-manager/dist/systemd-spawn.d.ts.map +0 -1
- package/payload/platform/services/claude-session-manager/dist/systemd-spawn.js +0 -345
- package/payload/platform/services/claude-session-manager/dist/systemd-spawn.js.map +0 -1
- package/payload/platform/services/telegram-channel/dist/turn-follow.d.ts +0 -104
- package/payload/platform/services/telegram-channel/dist/turn-follow.d.ts.map +0 -1
- package/payload/platform/services/telegram-channel/dist/turn-follow.js +0 -408
- package/payload/platform/services/telegram-channel/dist/turn-follow.js.map +0 -1
- package/payload/platform/services/whatsapp-channel/dist/turn-follow.d.ts +0 -104
- package/payload/platform/services/whatsapp-channel/dist/turn-follow.d.ts.map +0 -1
- package/payload/platform/services/whatsapp-channel/dist/turn-follow.js +0 -393
- package/payload/platform/services/whatsapp-channel/dist/turn-follow.js.map +0 -1
|
@@ -0,0 +1,143 @@
|
|
|
1
|
+
#!/usr/bin/env node
|
|
2
|
+
// Reconciles every compiled output tree under platform/ against its sources.
|
|
3
|
+
//
|
|
4
|
+
// Why this is a standing check and not a log line: `tsc` never removes output
|
|
5
|
+
// for a source that was deleted, and the bundler copies each tree — `dist`
|
|
6
|
+
// included — into the payload that `npm publish` ships. The deletion emits no
|
|
7
|
+
// event, and rebuilding does not surface the leftover, so nothing short of an
|
|
8
|
+
// independent reconcile can see it.
|
|
9
|
+
//
|
|
10
|
+
// Every project compiles `rootDir: src` to `outDir: dist`, so `dist/<rel>.js`
|
|
11
|
+
// maps to exactly one source, `src/<rel>.ts`. Two shapes of orphan exist:
|
|
12
|
+
// file — the .ts was deleted, the project still exists. `tsc -b --clean`
|
|
13
|
+
// would remove it.
|
|
14
|
+
// project — the whole project was deleted; `dist` survives with no `src` and
|
|
15
|
+
// no tsconfig, so no tsc invocation can ever reach it. Reported
|
|
16
|
+
// once per directory rather than once per file.
|
|
17
|
+
//
|
|
18
|
+
// Usage: node check-orphan-dist.mjs [platformRoot] [--remove]
|
|
19
|
+
// Exit 0 when every .js has a source. Exit 1 on any orphan, and exit 1 when no
|
|
20
|
+
// dist tree was found at all — a zero-orphan pass must never be
|
|
21
|
+
// indistinguishable from having measured nothing.
|
|
22
|
+
//
|
|
23
|
+
// With --remove it deletes exactly the set it just reported (each orphan .js
|
|
24
|
+
// plus its .js.map/.d.ts/.d.ts.map sidecars; a project orphan's whole dist
|
|
25
|
+
// directory) and then re-scans, so the exit code reflects the state on disk
|
|
26
|
+
// afterwards rather than the fact that a delete was called. Sharing one rule
|
|
27
|
+
// between the detector and the repair is what stops the two drifting apart.
|
|
28
|
+
|
|
29
|
+
import { existsSync, readdirSync, rmSync } from "node:fs";
|
|
30
|
+
import { join, resolve, relative, dirname } from "node:path";
|
|
31
|
+
import { fileURLToPath } from "node:url";
|
|
32
|
+
|
|
33
|
+
const args = process.argv.slice(2);
|
|
34
|
+
const remove = args.includes("--remove");
|
|
35
|
+
const rootArg = args.find((a) => !a.startsWith("--"));
|
|
36
|
+
const scriptDir = dirname(fileURLToPath(import.meta.url));
|
|
37
|
+
const platformRoot = resolve(rootArg ?? join(scriptDir, ".."));
|
|
38
|
+
|
|
39
|
+
// Each family maps a project directory to its dist/src pair. `sub` is the
|
|
40
|
+
// directory between the project and its dist/src, empty where there is none.
|
|
41
|
+
const FAMILIES = [
|
|
42
|
+
{ dir: "plugins", sub: "mcp" },
|
|
43
|
+
{ dir: "lib", sub: "" },
|
|
44
|
+
{ dir: "services", sub: "" },
|
|
45
|
+
];
|
|
46
|
+
|
|
47
|
+
function subdirs(dir) {
|
|
48
|
+
if (!existsSync(dir)) return [];
|
|
49
|
+
return readdirSync(dir, { withFileTypes: true })
|
|
50
|
+
.filter((e) => e.isDirectory())
|
|
51
|
+
.map((e) => e.name)
|
|
52
|
+
.sort();
|
|
53
|
+
}
|
|
54
|
+
|
|
55
|
+
function walkJs(dir, out) {
|
|
56
|
+
for (const entry of readdirSync(dir, { withFileTypes: true })) {
|
|
57
|
+
const full = join(dir, entry.name);
|
|
58
|
+
if (entry.isDirectory()) walkJs(full, out);
|
|
59
|
+
else if (entry.name.endsWith(".js")) out.push(full);
|
|
60
|
+
}
|
|
61
|
+
return out;
|
|
62
|
+
}
|
|
63
|
+
|
|
64
|
+
function scan() {
|
|
65
|
+
let trees = 0;
|
|
66
|
+
let files = 0;
|
|
67
|
+
const fileOrphans = [];
|
|
68
|
+
const projectOrphans = [];
|
|
69
|
+
|
|
70
|
+
for (const family of FAMILIES) {
|
|
71
|
+
const familyDir = join(platformRoot, family.dir);
|
|
72
|
+
for (const project of subdirs(familyDir)) {
|
|
73
|
+
const base = family.sub
|
|
74
|
+
? join(familyDir, project, family.sub)
|
|
75
|
+
: join(familyDir, project);
|
|
76
|
+
const distDir = join(base, "dist");
|
|
77
|
+
if (!existsSync(distDir)) continue;
|
|
78
|
+
trees += 1;
|
|
79
|
+
const srcDir = join(base, "src");
|
|
80
|
+
if (!existsSync(srcDir)) {
|
|
81
|
+
projectOrphans.push(distDir);
|
|
82
|
+
files += walkJs(distDir, []).length;
|
|
83
|
+
continue;
|
|
84
|
+
}
|
|
85
|
+
for (const js of walkJs(distDir, [])) {
|
|
86
|
+
files += 1;
|
|
87
|
+
const rel = js.slice(distDir.length + 1);
|
|
88
|
+
if (!existsSync(join(srcDir, `${rel.slice(0, -3)}.ts`))) fileOrphans.push(js);
|
|
89
|
+
}
|
|
90
|
+
}
|
|
91
|
+
}
|
|
92
|
+
return { trees, files, fileOrphans, projectOrphans, total: fileOrphans.length + projectOrphans.length };
|
|
93
|
+
}
|
|
94
|
+
|
|
95
|
+
const rel = (p) => relative(platformRoot, p);
|
|
96
|
+
|
|
97
|
+
function report(r) {
|
|
98
|
+
console.log(`[orphan-dist] trees=${r.trees} files=${r.files} orphans=${r.total}`);
|
|
99
|
+
for (const p of r.projectOrphans) console.log(`[orphan-dist] orphan-project=${rel(p)}`);
|
|
100
|
+
for (const f of r.fileOrphans) console.log(`[orphan-dist] orphan=${rel(f)}`);
|
|
101
|
+
}
|
|
102
|
+
|
|
103
|
+
const first = scan();
|
|
104
|
+
report(first);
|
|
105
|
+
|
|
106
|
+
if (first.trees === 0) {
|
|
107
|
+
console.error(
|
|
108
|
+
"[orphan-dist] FATAL: no dist tree found under platform/{plugins,lib,services} — " +
|
|
109
|
+
"the check measured nothing rather than finding nothing. Build platform first.",
|
|
110
|
+
);
|
|
111
|
+
process.exit(1);
|
|
112
|
+
}
|
|
113
|
+
|
|
114
|
+
if (remove && first.total > 0) {
|
|
115
|
+
for (const dir of first.projectOrphans) rmSync(dir, { recursive: true, force: true });
|
|
116
|
+
for (const js of first.fileOrphans) {
|
|
117
|
+
const stem = js.slice(0, -3);
|
|
118
|
+
for (const ext of [".js", ".js.map", ".d.ts", ".d.ts.map"]) {
|
|
119
|
+
rmSync(`${stem}${ext}`, { force: true });
|
|
120
|
+
}
|
|
121
|
+
}
|
|
122
|
+
// Re-scan rather than trust the delete. The exit code must reflect what is
|
|
123
|
+
// on disk now, not the fact that rmSync was called.
|
|
124
|
+
const after = scan();
|
|
125
|
+
console.log(`[orphan-dist] removed=${first.total - after.total} remaining=${after.total}`);
|
|
126
|
+
if (after.total > 0) {
|
|
127
|
+
console.error(
|
|
128
|
+
`[orphan-dist] FATAL: ${after.total} orphan(s) survived removal. Check permissions on the ` +
|
|
129
|
+
"paths listed above.",
|
|
130
|
+
);
|
|
131
|
+
process.exit(1);
|
|
132
|
+
}
|
|
133
|
+
process.exit(0);
|
|
134
|
+
}
|
|
135
|
+
|
|
136
|
+
if (first.total > 0) {
|
|
137
|
+
console.error(
|
|
138
|
+
`[orphan-dist] FATAL: ${first.total} compiled output(s) have no source. Their .ts was deleted and ` +
|
|
139
|
+
"the compiler left the .js behind, where the bundler copies it into the published payload. " +
|
|
140
|
+
"Run `npm run clean:dist` in platform/ to remove exactly this set.",
|
|
141
|
+
);
|
|
142
|
+
process.exit(1);
|
|
143
|
+
}
|
|
@@ -0,0 +1,122 @@
|
|
|
1
|
+
# agent-identity-reconcile.sh — converge every account's public-agent IDENTITY.md
|
|
2
|
+
# against the shipped template, and state the divergence count.
|
|
3
|
+
#
|
|
4
|
+
# Task 2671. The re-sync this replaces lived inside provision_account_dir, and
|
|
5
|
+
# setup-account.sh calls that for the house account and no other, so an agent
|
|
6
|
+
# created on a client sub-account keeps whatever identity text it was seeded
|
|
7
|
+
# with for ever. Measured on laptop 192.168.88.10 on 2026-08-11: the house
|
|
8
|
+
# account's agents were refreshed by that morning's install while
|
|
9
|
+
# `5bc2c0e2/agents/beagle` still carried the 2026-07-31 text and
|
|
10
|
+
# `.../fares` the 2026-08-04 one, both of them telling a spawn that now holds
|
|
11
|
+
# five tools that it holds none.
|
|
12
|
+
#
|
|
13
|
+
# This is the identity twin of account-settings-reconcile.sh, written the same
|
|
14
|
+
# way and for the same reason, and it is the file's only writer: the in-place
|
|
15
|
+
# loop was deleted when this landed.
|
|
16
|
+
#
|
|
17
|
+
# IDENTITY.md is Rubytech-controlled and copied verbatim (agent-write.ts:113), so
|
|
18
|
+
# an operator edit here is drift to be corrected, not content to preserve. That
|
|
19
|
+
# is the one place this diverges from the settings reconciler, which leaves an
|
|
20
|
+
# unparseable file alone because it may carry an operator edit worth keeping.
|
|
21
|
+
#
|
|
22
|
+
# Idempotent. Never creates an agent dir, never writes SOUL/KNOWLEDGE/config,
|
|
23
|
+
# never echoes file contents.
|
|
24
|
+
#
|
|
25
|
+
# Sourced by setup-account.sh; also runnable standalone for a manual repair.
|
|
26
|
+
|
|
27
|
+
# ensure_agent_identity <identity_file> <template_file> <account_id> <agent_slug>
|
|
28
|
+
# Returns 0 when the file already matched the template, 1 when it diverged, and
|
|
29
|
+
# 2 when the copy landed empty. Logs exactly one
|
|
30
|
+
# [identity-reconcile] account=<id> agent=<slug> status=<already-current|updated|rewrite-failed|empty-after-copy|no-template>
|
|
31
|
+
ensure_agent_identity() {
|
|
32
|
+
local f="$1" tpl="$2" acct="$3" slug="$4"
|
|
33
|
+
|
|
34
|
+
if [ ! -s "$tpl" ]; then
|
|
35
|
+
echo "[identity-reconcile] account=$acct agent=$slug status=no-template"
|
|
36
|
+
return 1
|
|
37
|
+
fi
|
|
38
|
+
|
|
39
|
+
if cmp -s "$f" "$tpl"; then
|
|
40
|
+
echo "[identity-reconcile] account=$acct agent=$slug status=already-current"
|
|
41
|
+
return 0
|
|
42
|
+
fi
|
|
43
|
+
|
|
44
|
+
if ! cp "$tpl" "$f" 2>/dev/null; then
|
|
45
|
+
echo "[identity-reconcile] account=$acct agent=$slug status=rewrite-failed"
|
|
46
|
+
return 1
|
|
47
|
+
fi
|
|
48
|
+
|
|
49
|
+
# A 0-byte cp traps the brand server in STARTING: the reachability auditor
|
|
50
|
+
# then reports `reachable=false reason=files-missing IDENTITY.md:empty` every
|
|
51
|
+
# minute and the operator sees the splash for ever. Observed on
|
|
52
|
+
# 192.168.88.16 after a re-install, source 1655 bytes and destination 0. This
|
|
53
|
+
# is the one condition the pass refuses to continue past, carried over from
|
|
54
|
+
# the loop it replaces.
|
|
55
|
+
if [ ! -s "$f" ]; then
|
|
56
|
+
echo "[identity-reconcile] account=$acct agent=$slug status=empty-after-copy" >&2
|
|
57
|
+
return 2
|
|
58
|
+
fi
|
|
59
|
+
|
|
60
|
+
# Divergent, like every other non-matching outcome: `divergent=` counts files
|
|
61
|
+
# this pass had to act on, so a run that rewrote one and a run that rewrote
|
|
62
|
+
# none are distinguishable in the summary line.
|
|
63
|
+
echo "[identity-reconcile] account=$acct agent=$slug status=updated"
|
|
64
|
+
return 1
|
|
65
|
+
}
|
|
66
|
+
|
|
67
|
+
# reconcile_all_accounts_identities <accounts_dir>
|
|
68
|
+
# Standing check + durable backfill across every account carrying an
|
|
69
|
+
# account.json. Emits one status line per agent plus one summary line on every
|
|
70
|
+
# run, including a zero count — silence is not evidence of convergence, and
|
|
71
|
+
# `agents=0` on an install that has accounts is a stopped counter rather than a
|
|
72
|
+
# clean pass.
|
|
73
|
+
#
|
|
74
|
+
# Returns 1 only when a copy landed empty, so the caller aborts before the brand
|
|
75
|
+
# server starts. Every other failure is reported and stepped over.
|
|
76
|
+
reconcile_all_accounts_identities() {
|
|
77
|
+
local accts="$1"
|
|
78
|
+
local tpl="${MAXY_PUBLIC_IDENTITY_TEMPLATE:-${TEMPLATES_DIR:-}/agents/public/IDENTITY.md}"
|
|
79
|
+
local n=0 agents=0 divergent=0 fatal=0
|
|
80
|
+
local acct acct_id agent_dir slug rc
|
|
81
|
+
|
|
82
|
+
if [ -d "$accts" ]; then
|
|
83
|
+
for acct in "$accts"/*/; do
|
|
84
|
+
[ -f "$acct/account.json" ] || continue
|
|
85
|
+
n=$((n + 1))
|
|
86
|
+
acct_id="$(basename "$acct")"
|
|
87
|
+
for agent_dir in "$acct/agents"/*/; do
|
|
88
|
+
[ -d "$agent_dir" ] || continue
|
|
89
|
+
slug="$(basename "$agent_dir")"
|
|
90
|
+
# admin has its own Rubytech identity; passive has a third (Task 1483),
|
|
91
|
+
# and re-syncing either from the public visitor template would replace a
|
|
92
|
+
# correct prompt with the wrong one.
|
|
93
|
+
[ "$slug" = "admin" ] && continue
|
|
94
|
+
[ "$slug" = "passive" ] && continue
|
|
95
|
+
# Never create. An agent dir with no IDENTITY.md is a half-made agent,
|
|
96
|
+
# which agent-create's rollback already prevents; seeding one here would
|
|
97
|
+
# make it look whole.
|
|
98
|
+
[ -f "$agent_dir/IDENTITY.md" ] || continue
|
|
99
|
+
agents=$((agents + 1))
|
|
100
|
+
# `|| rc=$?` rather than a bare call followed by `rc=$?`: setup-account.sh
|
|
101
|
+
# runs under `set -e`, and a bare call returning non-zero kills the
|
|
102
|
+
# install the first time any agent diverges — which is every upgrade
|
|
103
|
+
# that has work to do. The `||` puts the call in a tested context, the
|
|
104
|
+
# same shape account-settings-reconcile.sh uses for the same reason.
|
|
105
|
+
rc=0
|
|
106
|
+
ensure_agent_identity "$agent_dir/IDENTITY.md" "$tpl" "$acct_id" "$slug" || rc=$?
|
|
107
|
+
# if-blocks rather than `[ … ] && …` lists: an AND-list whose test fails
|
|
108
|
+
# returns non-zero, and as the last command in this loop body that is
|
|
109
|
+
# another way `set -e` kills the install.
|
|
110
|
+
if [ "$rc" -ne 0 ]; then divergent=$((divergent + 1)); fi
|
|
111
|
+
if [ "$rc" -eq 2 ]; then fatal=1; fi
|
|
112
|
+
done
|
|
113
|
+
done
|
|
114
|
+
fi
|
|
115
|
+
|
|
116
|
+
echo "[identity-reconcile] accounts=$n agents=$agents divergent=$divergent"
|
|
117
|
+
if [ "$fatal" -eq 1 ]; then
|
|
118
|
+
echo " [setup] FATAL a public IDENTITY.md is empty after copy from $tpl ($(wc -c < "$tpl" 2>/dev/null || echo 0) bytes); aborting before the brand server starts" >&2
|
|
119
|
+
return 1
|
|
120
|
+
fi
|
|
121
|
+
return 0
|
|
122
|
+
}
|
|
@@ -87,34 +87,16 @@ provision_account_dir() {
|
|
|
87
87
|
cp "$TEMPLATES_DIR/agents/admin/IDENTITY.md" "$ACCOUNT_DIR/agents/admin/IDENTITY.md"
|
|
88
88
|
# Task 1483 — the WhatsApp passive requirement-intake identity. Rubytech-
|
|
89
89
|
# controlled and uniform (like admin), so it is re-seeded from the template on
|
|
90
|
-
# every provision
|
|
91
|
-
# otherwise clobber it with the public visitor IDENTITY).
|
|
90
|
+
# every provision.
|
|
92
91
|
cp "$TEMPLATES_DIR/agents/passive/IDENTITY.md" "$ACCOUNT_DIR/agents/passive/IDENTITY.md"
|
|
93
92
|
|
|
94
|
-
#
|
|
95
|
-
#
|
|
96
|
-
#
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
[ "$_AGENT_NAME" = "admin" ] && continue
|
|
102
|
-
# Task 1483 — passive has its own Rubytech IDENTITY (seeded above); it must
|
|
103
|
-
# NOT be re-synced from the public visitor template.
|
|
104
|
-
[ "$_AGENT_NAME" = "passive" ] && continue
|
|
105
|
-
[ -f "$_AGENT_DIR/IDENTITY.md" ] || continue
|
|
106
|
-
cp "$TEMPLATES_DIR/agents/public/IDENTITY.md" "$_AGENT_DIR/IDENTITY.md"
|
|
107
|
-
# Defensive verify — a 0-byte cp traps the brand server in STARTING (the
|
|
108
|
-
# reachability auditor reports `reachable=false reason=files-missing
|
|
109
|
-
# IDENTITY.md:empty` every minute). Observed on 192.168.88.16 after a
|
|
110
|
-
# re-install: source 1655 bytes, dest 0 bytes. Loud-fail here so the
|
|
111
|
-
# operator sees the bad write at install time, not the splash forever.
|
|
112
|
-
if [ ! -s "$_AGENT_DIR/IDENTITY.md" ]; then
|
|
113
|
-
echo " [setup] FATAL agents/$_AGENT_NAME/IDENTITY.md is empty after copy from $TEMPLATES_DIR/agents/public/IDENTITY.md ($(wc -c < "$TEMPLATES_DIR/agents/public/IDENTITY.md") bytes); aborting before the brand server starts" >&2
|
|
114
|
-
return 1
|
|
115
|
-
fi
|
|
116
|
-
echo " agents/$_AGENT_NAME/IDENTITY.md re-synced"
|
|
117
|
-
done
|
|
93
|
+
# Task 2671 — the public-agent IDENTITY.md re-sync that used to run here now
|
|
94
|
+
# lives in lib/agent-identity-reconcile.sh, called by setup-account.sh across
|
|
95
|
+
# EVERY account. It ran here for whichever single account was being
|
|
96
|
+
# provisioned, and setup-account.sh provisions the house account alone, so an
|
|
97
|
+
# agent on a client sub-account kept a stale prompt indefinitely. That
|
|
98
|
+
# reconciler is now the only writer of the file; re-adding a copy here would
|
|
99
|
+
# make it two.
|
|
118
100
|
|
|
119
101
|
cp "$TEMPLATES_DIR/specialists/.claude-plugin/plugin.json" "$ACCOUNT_DIR/specialists/.claude-plugin/plugin.json"
|
|
120
102
|
|
|
@@ -77,3 +77,18 @@ reconcile_all_accounts_owned_dirs "$ACCOUNTS_DIR"
|
|
|
77
77
|
# (Task 2475 retired the four one-hook backfill libs this replaced.)
|
|
78
78
|
. "$SCRIPT_DIR/lib/account-settings-reconcile.sh"
|
|
79
79
|
reconcile_all_accounts_settings "$ACCOUNTS_DIR"
|
|
80
|
+
|
|
81
|
+
# ------------------------------------------------------------------
|
|
82
|
+
# 5. Converge every public agent's IDENTITY.md on every account
|
|
83
|
+
# ------------------------------------------------------------------
|
|
84
|
+
# Task 2671. Same shape and same reason as step 4: the identity re-sync used to
|
|
85
|
+
# live inside provision_account_dir, which this script calls for the house
|
|
86
|
+
# account and no other, so an agent created on a client sub-account kept the
|
|
87
|
+
# text it was seeded with for ever. Measured on 2026-08-11: a sub-account's
|
|
88
|
+
# agents still carried a July prompt telling a five-tool Telegram spawn it held
|
|
89
|
+
# none. This is now the single writer of a public agent's IDENTITY.md — the
|
|
90
|
+
# in-place loop was deleted when it landed. Returns non-zero only when a copy
|
|
91
|
+
# lands empty, which `set -e` turns into an abort before the brand server
|
|
92
|
+
# starts, because that state traps the server in STARTING.
|
|
93
|
+
. "$SCRIPT_DIR/lib/agent-identity-reconcile.sh"
|
|
94
|
+
reconcile_all_accounts_identities "$ACCOUNTS_DIR"
|
|
@@ -23,6 +23,43 @@ import { TelegramChannelStore } from './telegram-channel-store.js';
|
|
|
23
23
|
* named agent's IDENTITY/SOUL/KNOWLEDGE via composeAppendSystemPrompt, the same
|
|
24
24
|
* composer /public-spawn uses. An admin spawn is unchanged and still composes
|
|
25
25
|
* only reseat / voice / specialist-domains / authenticated-identity fragments. */
|
|
26
|
+
/** Task 2666 — the framing a channel server may be given, or null when the
|
|
27
|
+
* spawn does not carry one.
|
|
28
|
+
*
|
|
29
|
+
* A channel server has exactly two framings, and `admin` is the
|
|
30
|
+
* higher-privilege one: its instruction block tells the agent the message "is
|
|
31
|
+
* a message the operator has typed to you directly" and to act on it as their
|
|
32
|
+
* instruction. Every site that reached it by exclusion — anything not
|
|
33
|
+
* `'public'` becomes admin — turned each way of getting the role wrong into a
|
|
34
|
+
* privilege elevation that emitted nothing, because a spawn that silently
|
|
35
|
+
* became admin is byte-identical to a correct admin spawn.
|
|
36
|
+
*
|
|
37
|
+
* So this answers the question and never invents an answer. `passive` is not a
|
|
38
|
+
* channel framing and null means the role was never resolved; both return null
|
|
39
|
+
* and the caller refuses the spawn. */
|
|
40
|
+
export declare function channelFramingRole(role: AgentRole | null): 'admin' | 'public' | null;
|
|
41
|
+
/** Task 2666 — the same value at the point of use, where null is unreachable
|
|
42
|
+
* because the caller refused the spawn already.
|
|
43
|
+
*
|
|
44
|
+
* A throw rather than a `!` assertion or a default. The compiler cannot narrow
|
|
45
|
+
* through the `channelBound && framing === null` conjunction that guards the
|
|
46
|
+
* attach blocks, and the two ways of silencing it are both worse than a crash:
|
|
47
|
+
* `!` asserts an invariant it cannot check, and a default reintroduces exactly
|
|
48
|
+
* the admin-by-exclusion this task removed. If the guard is ever conditioned
|
|
49
|
+
* away, this is loud on the first spawn instead of quiet for ever. */
|
|
50
|
+
export declare function requireChannelFraming(role: 'admin' | 'public' | null): 'admin' | 'public';
|
|
51
|
+
/** Task 2666 — the telegram plugin's own public tools, out of the install-wide
|
|
52
|
+
* public surface `loadToolSurface` built from every PLUGIN.md at boot.
|
|
53
|
+
*
|
|
54
|
+
* Filtered to this one plugin rather than passed whole: a pinned public
|
|
55
|
+
* telegram spawn registers only the telegram servers, so a public tool
|
|
56
|
+
* declared on any other plugin would name a server that is not there — the
|
|
57
|
+
* granted-but-uncallable failure this task's `op=mcp-registered` line exists
|
|
58
|
+
* to make visible. Filtering states that boundary instead of relying on no
|
|
59
|
+
* other plugin ever declaring one.
|
|
60
|
+
*
|
|
61
|
+
* Sorted so the emitted argv is stable and the audit test can compare. */
|
|
62
|
+
export declare function telegramPublicToolsFrom(publicSurface: ReadonlySet<string>): string[];
|
|
26
63
|
export declare function parseRcSpawnRole(body: {
|
|
27
64
|
role?: unknown;
|
|
28
65
|
}): Extract<AgentRole, 'admin' | 'public'> | null;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"http-server.d.ts","sourceRoot":"","sources":["../src/http-server.ts"],"names":[],"mappings":"AAqBA,OAAO,EAAE,IAAI,EAAE,MAAM,MAAM,CAAA;
|
|
1
|
+
{"version":3,"file":"http-server.d.ts","sourceRoot":"","sources":["../src/http-server.ts"],"names":[],"mappings":"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"}
|