@elizaos/agent 0.25.8 → 2.0.0-alpha.144
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/LICENSE +1 -1
- package/apps/app-companion/src/actions/emote.d.ts +10 -0
- package/apps/app-companion/src/actions/emote.d.ts.map +1 -0
- package/apps/app-companion/src/actions/emote.js +79 -0
- package/apps/app-companion/src/emotes/catalog.d.ts +31 -0
- package/apps/app-companion/src/emotes/catalog.d.ts.map +1 -0
- package/apps/app-companion/src/emotes/catalog.js +402 -0
- package/apps/app-companion/src/plugin.d.ts +9 -0
- package/apps/app-companion/src/plugin.d.ts.map +1 -0
- package/apps/app-companion/src/plugin.js +15 -0
- package/apps/app-knowledge/src/routes.d.ts +23 -0
- package/apps/app-knowledge/src/routes.d.ts.map +1 -0
- package/apps/app-knowledge/src/routes.js +956 -0
- package/apps/app-knowledge/src/service-loader.d.ts +51 -0
- package/apps/app-knowledge/src/service-loader.d.ts.map +1 -0
- package/apps/app-knowledge/src/service-loader.js +34 -0
- package/apps/app-lifeops/src/action.d.ts +3 -0
- package/apps/app-lifeops/src/action.d.ts.map +1 -0
- package/apps/app-lifeops/src/action.js +332 -0
- package/apps/app-lifeops/src/actions/calendar.d.ts +19 -0
- package/apps/app-lifeops/src/actions/calendar.d.ts.map +1 -0
- package/apps/app-lifeops/src/actions/calendar.js +3143 -0
- package/apps/app-lifeops/src/actions/gmail.d.ts +33 -0
- package/apps/app-lifeops/src/actions/gmail.d.ts.map +1 -0
- package/apps/app-lifeops/src/actions/gmail.js +1734 -0
- package/apps/app-lifeops/src/actions/life-goal-extractor.d.ts +69 -0
- package/apps/app-lifeops/src/actions/life-goal-extractor.d.ts.map +1 -0
- package/apps/app-lifeops/src/actions/life-goal-extractor.js +354 -0
- package/apps/app-lifeops/src/actions/life-param-extractor.d.ts +78 -0
- package/apps/app-lifeops/src/actions/life-param-extractor.d.ts.map +1 -0
- package/apps/app-lifeops/src/actions/life-param-extractor.js +423 -0
- package/apps/app-lifeops/src/actions/life-recent-context.d.ts +9 -0
- package/apps/app-lifeops/src/actions/life-recent-context.d.ts.map +1 -0
- package/apps/app-lifeops/src/actions/life-recent-context.js +84 -0
- package/apps/app-lifeops/src/actions/life-update-extractor.d.ts +27 -0
- package/apps/app-lifeops/src/actions/life-update-extractor.d.ts.map +1 -0
- package/apps/app-lifeops/src/actions/life-update-extractor.js +195 -0
- package/apps/app-lifeops/src/actions/life.d.ts +9 -0
- package/apps/app-lifeops/src/actions/life.d.ts.map +1 -0
- package/apps/app-lifeops/src/actions/life.extractor.d.ts +18 -0
- package/apps/app-lifeops/src/actions/life.extractor.d.ts.map +1 -0
- package/apps/app-lifeops/src/actions/life.extractor.js +264 -0
- package/apps/app-lifeops/src/actions/life.js +3379 -0
- package/apps/app-lifeops/src/actions/lifeops-extraction-config.d.ts +16 -0
- package/apps/app-lifeops/src/actions/lifeops-extraction-config.d.ts.map +1 -0
- package/apps/app-lifeops/src/actions/lifeops-extraction-config.js +25 -0
- package/apps/app-lifeops/src/actions/lifeops-google-helpers.d.ts +62 -0
- package/apps/app-lifeops/src/actions/lifeops-google-helpers.d.ts.map +1 -0
- package/apps/app-lifeops/src/actions/lifeops-google-helpers.js +607 -0
- package/apps/app-lifeops/src/actions/timezone-normalization.d.ts +3 -0
- package/apps/app-lifeops/src/actions/timezone-normalization.d.ts.map +1 -0
- package/apps/app-lifeops/src/actions/timezone-normalization.js +105 -0
- package/apps/app-lifeops/src/lifeops/app-state.d.ts +11 -0
- package/apps/app-lifeops/src/lifeops/app-state.d.ts.map +1 -0
- package/apps/app-lifeops/src/lifeops/app-state.js +32 -0
- package/apps/app-lifeops/src/lifeops/apple-reminders.d.ts +58 -0
- package/apps/app-lifeops/src/lifeops/apple-reminders.d.ts.map +1 -0
- package/apps/app-lifeops/src/lifeops/apple-reminders.js +325 -0
- package/apps/app-lifeops/src/lifeops/defaults.d.ts +24 -0
- package/apps/app-lifeops/src/lifeops/defaults.d.ts.map +1 -0
- package/apps/app-lifeops/src/lifeops/defaults.js +205 -0
- package/apps/app-lifeops/src/lifeops/engine.d.ts +8 -0
- package/apps/app-lifeops/src/lifeops/engine.d.ts.map +1 -0
- package/apps/app-lifeops/src/lifeops/engine.js +389 -0
- package/apps/app-lifeops/src/lifeops/goal-grounding.d.ts +54 -0
- package/apps/app-lifeops/src/lifeops/goal-grounding.d.ts.map +1 -0
- package/apps/app-lifeops/src/lifeops/goal-grounding.js +147 -0
- package/apps/app-lifeops/src/lifeops/goal-semantic-evaluator.d.ts +12 -0
- package/apps/app-lifeops/src/lifeops/goal-semantic-evaluator.d.ts.map +1 -0
- package/apps/app-lifeops/src/lifeops/goal-semantic-evaluator.js +154 -0
- package/apps/app-lifeops/src/lifeops/google-api-error.d.ts +7 -0
- package/apps/app-lifeops/src/lifeops/google-api-error.d.ts.map +1 -0
- package/apps/app-lifeops/src/lifeops/google-api-error.js +35 -0
- package/apps/app-lifeops/src/lifeops/google-calendar.d.ts +53 -0
- package/apps/app-lifeops/src/lifeops/google-calendar.d.ts.map +1 -0
- package/apps/app-lifeops/src/lifeops/google-calendar.js +268 -0
- package/apps/app-lifeops/src/lifeops/google-connector-gateway.d.ts +19 -0
- package/apps/app-lifeops/src/lifeops/google-connector-gateway.d.ts.map +1 -0
- package/apps/app-lifeops/src/lifeops/google-connector-gateway.js +65 -0
- package/apps/app-lifeops/src/lifeops/google-fetch.d.ts +11 -0
- package/apps/app-lifeops/src/lifeops/google-fetch.d.ts.map +1 -0
- package/apps/app-lifeops/src/lifeops/google-fetch.js +85 -0
- package/apps/app-lifeops/src/lifeops/google-gmail.d.ts +54 -0
- package/apps/app-lifeops/src/lifeops/google-gmail.d.ts.map +1 -0
- package/apps/app-lifeops/src/lifeops/google-gmail.js +471 -0
- package/apps/app-lifeops/src/lifeops/google-managed-client.d.ts +127 -0
- package/apps/app-lifeops/src/lifeops/google-managed-client.d.ts.map +1 -0
- package/apps/app-lifeops/src/lifeops/google-managed-client.js +294 -0
- package/apps/app-lifeops/src/lifeops/google-oauth.d.ts +61 -0
- package/apps/app-lifeops/src/lifeops/google-oauth.d.ts.map +1 -0
- package/apps/app-lifeops/src/lifeops/google-oauth.js +491 -0
- package/apps/app-lifeops/src/lifeops/google-scopes.d.ts +13 -0
- package/apps/app-lifeops/src/lifeops/google-scopes.d.ts.map +1 -0
- package/apps/app-lifeops/src/lifeops/google-scopes.js +96 -0
- package/apps/app-lifeops/src/lifeops/owner-profile.d.ts +15 -0
- package/apps/app-lifeops/src/lifeops/owner-profile.d.ts.map +1 -0
- package/apps/app-lifeops/src/lifeops/owner-profile.js +194 -0
- package/apps/app-lifeops/src/lifeops/repository.d.ts +209 -0
- package/apps/app-lifeops/src/lifeops/repository.d.ts.map +1 -0
- package/apps/app-lifeops/src/lifeops/repository.js +3187 -0
- package/apps/app-lifeops/src/lifeops/runtime.d.ts +14 -0
- package/apps/app-lifeops/src/lifeops/runtime.d.ts.map +1 -0
- package/apps/app-lifeops/src/lifeops/runtime.js +120 -0
- package/apps/app-lifeops/src/lifeops/seed-routines.d.ts +20 -0
- package/apps/app-lifeops/src/lifeops/seed-routines.d.ts.map +1 -0
- package/apps/app-lifeops/src/lifeops/seed-routines.js +111 -0
- package/apps/app-lifeops/src/lifeops/service.d.ts +275 -0
- package/apps/app-lifeops/src/lifeops/service.d.ts.map +1 -0
- package/apps/app-lifeops/src/lifeops/service.js +9260 -0
- package/apps/app-lifeops/src/lifeops/sql.d.ts +31 -0
- package/apps/app-lifeops/src/lifeops/sql.d.ts.map +1 -0
- package/apps/app-lifeops/src/lifeops/sql.js +247 -0
- package/apps/app-lifeops/src/lifeops/time.d.ts +17 -0
- package/apps/app-lifeops/src/lifeops/time.d.ts.map +1 -0
- package/apps/app-lifeops/src/lifeops/time.js +132 -0
- package/apps/app-lifeops/src/lifeops/twilio.d.ts +25 -0
- package/apps/app-lifeops/src/lifeops/twilio.d.ts.map +1 -0
- package/apps/app-lifeops/src/lifeops/twilio.js +157 -0
- package/apps/app-lifeops/src/lifeops/x-poster.d.ts +19 -0
- package/apps/app-lifeops/src/lifeops/x-poster.d.ts.map +1 -0
- package/apps/app-lifeops/src/lifeops/x-poster.js +148 -0
- package/apps/app-lifeops/src/plugin.d.ts +19 -0
- package/apps/app-lifeops/src/plugin.d.ts.map +1 -0
- package/apps/app-lifeops/src/plugin.js +79 -0
- package/apps/app-lifeops/src/provider.d.ts +3 -0
- package/apps/app-lifeops/src/provider.d.ts.map +1 -0
- package/apps/app-lifeops/src/provider.js +75 -0
- package/apps/app-lifeops/src/providers/lifeops.d.ts +3 -0
- package/apps/app-lifeops/src/providers/lifeops.d.ts.map +1 -0
- package/apps/app-lifeops/src/providers/lifeops.js +157 -0
- package/apps/app-lifeops/src/routes/lifeops-browser-packaging.d.ts +16 -0
- package/apps/app-lifeops/src/routes/lifeops-browser-packaging.d.ts.map +1 -0
- package/apps/app-lifeops/src/routes/lifeops-browser-packaging.js +305 -0
- package/apps/app-lifeops/src/routes/lifeops-routes.d.ts +20 -0
- package/apps/app-lifeops/src/routes/lifeops-routes.d.ts.map +1 -0
- package/apps/app-lifeops/src/routes/lifeops-routes.js +1173 -0
- package/apps/app-lifeops/src/routes/website-blocker-routes.d.ts +7 -0
- package/apps/app-lifeops/src/routes/website-blocker-routes.d.ts.map +1 -0
- package/apps/app-lifeops/src/routes/website-blocker-routes.js +175 -0
- package/apps/app-lifeops/src/selfcontrol/access.d.ts +8 -0
- package/apps/app-lifeops/src/selfcontrol/access.d.ts.map +1 -0
- package/apps/app-lifeops/src/selfcontrol/access.js +16 -0
- package/apps/app-lifeops/src/selfcontrol/action.d.ts +10 -0
- package/apps/app-lifeops/src/selfcontrol/action.d.ts.map +1 -0
- package/apps/app-lifeops/src/selfcontrol/action.js +506 -0
- package/apps/app-lifeops/src/selfcontrol/index.d.ts +13 -0
- package/apps/app-lifeops/src/selfcontrol/index.d.ts.map +1 -0
- package/apps/app-lifeops/src/selfcontrol/index.js +10 -0
- package/apps/app-lifeops/src/selfcontrol/permissions.d.ts +9 -0
- package/apps/app-lifeops/src/selfcontrol/permissions.d.ts.map +1 -0
- package/apps/app-lifeops/src/selfcontrol/permissions.js +1 -0
- package/apps/app-lifeops/src/selfcontrol/provider.d.ts +4 -0
- package/apps/app-lifeops/src/selfcontrol/provider.d.ts.map +1 -0
- package/apps/app-lifeops/src/selfcontrol/provider.js +116 -0
- package/apps/app-lifeops/src/selfcontrol/roles.d.ts +13 -0
- package/apps/app-lifeops/src/selfcontrol/roles.d.ts.map +1 -0
- package/apps/app-lifeops/src/selfcontrol/roles.js +228 -0
- package/apps/app-lifeops/src/selfcontrol/selfcontrol.d.ts +97 -0
- package/apps/app-lifeops/src/selfcontrol/selfcontrol.d.ts.map +1 -0
- package/apps/app-lifeops/src/selfcontrol/selfcontrol.js +949 -0
- package/apps/app-lifeops/src/selfcontrol/service.d.ts +21 -0
- package/apps/app-lifeops/src/selfcontrol/service.d.ts.map +1 -0
- package/apps/app-lifeops/src/selfcontrol/service.js +268 -0
- package/apps/app-lifeops/src/service.d.ts +8 -0
- package/apps/app-lifeops/src/service.d.ts.map +1 -0
- package/apps/app-lifeops/src/service.js +11 -0
- package/apps/app-steward/src/api/wallet-capability.d.ts +28 -0
- package/apps/app-steward/src/api/wallet-capability.d.ts.map +1 -0
- package/apps/app-steward/src/api/wallet-capability.js +94 -0
- package/apps/app-steward/src/api/wallet-dex-prices.d.ts +43 -0
- package/apps/app-steward/src/api/wallet-dex-prices.d.ts.map +1 -0
- package/apps/app-steward/src/api/wallet-dex-prices.js +149 -0
- package/apps/app-steward/src/api/wallet-evm-balance.d.ts +66 -0
- package/apps/app-steward/src/api/wallet-evm-balance.d.ts.map +1 -0
- package/apps/app-steward/src/api/wallet-evm-balance.js +666 -0
- package/apps/app-steward/src/api/wallet-routes.d.ts +35 -0
- package/apps/app-steward/src/api/wallet-routes.d.ts.map +1 -0
- package/apps/app-steward/src/api/wallet-routes.js +470 -0
- package/apps/app-steward/src/api/wallet-rpc.d.ts +67 -0
- package/apps/app-steward/src/api/wallet-rpc.d.ts.map +1 -0
- package/apps/app-steward/src/api/wallet-rpc.js +453 -0
- package/apps/app-steward/src/api/wallet.d.ts +60 -0
- package/apps/app-steward/src/api/wallet.d.ts.map +1 -0
- package/apps/app-steward/src/api/wallet.js +639 -0
- package/apps/app-steward/src/routes/server-wallet-trade.d.ts +27 -0
- package/apps/app-steward/src/routes/server-wallet-trade.d.ts.map +1 -0
- package/apps/app-steward/src/routes/server-wallet-trade.js +69 -0
- package/apps/app-steward/src/routes/wallet-core-routes.d.ts +16 -0
- package/apps/app-steward/src/routes/wallet-core-routes.d.ts.map +1 -0
- package/apps/app-steward/src/routes/wallet-core-routes.js +46 -0
- package/apps/app-steward/src/routes/wallet-export-guard.d.ts +51 -0
- package/apps/app-steward/src/routes/wallet-export-guard.d.ts.map +1 -0
- package/apps/app-steward/src/routes/wallet-export-guard.js +248 -0
- package/apps/app-steward/src/services/steward-evm-account.d.ts +58 -0
- package/apps/app-steward/src/services/steward-evm-account.d.ts.map +1 -0
- package/apps/app-steward/src/services/steward-evm-account.js +302 -0
- package/apps/app-steward/src/services/steward-evm-bridge.d.ts +35 -0
- package/apps/app-steward/src/services/steward-evm-bridge.d.ts.map +1 -0
- package/apps/app-steward/src/services/steward-evm-bridge.js +99 -0
- package/apps/app-training/src/core/cli.d.ts +11 -0
- package/apps/app-training/src/core/cli.d.ts.map +1 -0
- package/apps/app-training/src/core/cli.js +302 -0
- package/apps/app-training/src/core/context-audit.d.ts +51 -0
- package/apps/app-training/src/core/context-audit.d.ts.map +1 -0
- package/apps/app-training/src/core/context-audit.js +141 -0
- package/apps/app-training/src/core/context-catalog.d.ts +47 -0
- package/apps/app-training/src/core/context-catalog.d.ts.map +1 -0
- package/apps/app-training/src/core/context-catalog.js +259 -0
- package/apps/app-training/src/core/context-types.d.ts +3 -0
- package/apps/app-training/src/core/context-types.d.ts.map +1 -0
- package/apps/app-training/src/core/context-types.js +11 -0
- package/apps/app-training/src/core/dataset-generator.d.ts +135 -0
- package/apps/app-training/src/core/dataset-generator.d.ts.map +1 -0
- package/apps/app-training/src/core/dataset-generator.js +703 -0
- package/apps/app-training/src/core/replay-validator.d.ts +96 -0
- package/apps/app-training/src/core/replay-validator.d.ts.map +1 -0
- package/apps/app-training/src/core/replay-validator.js +265 -0
- package/apps/app-training/src/core/roleplay-executor.d.ts +123 -0
- package/apps/app-training/src/core/roleplay-executor.d.ts.map +1 -0
- package/apps/app-training/src/core/roleplay-executor.js +645 -0
- package/apps/app-training/src/core/roleplay-trajectories.d.ts +54 -0
- package/apps/app-training/src/core/roleplay-trajectories.d.ts.map +1 -0
- package/apps/app-training/src/core/roleplay-trajectories.js +73 -0
- package/apps/app-training/src/core/scenario-blueprints.d.ts +62 -0
- package/apps/app-training/src/core/scenario-blueprints.d.ts.map +1 -0
- package/apps/app-training/src/core/scenario-blueprints.js +790 -0
- package/apps/app-training/src/core/trajectory-task-datasets.d.ts +38 -0
- package/apps/app-training/src/core/trajectory-task-datasets.d.ts.map +1 -0
- package/apps/app-training/src/core/trajectory-task-datasets.js +281 -0
- package/apps/app-training/src/core/vertex-tuning.d.ts +139 -0
- package/apps/app-training/src/core/vertex-tuning.d.ts.map +1 -0
- package/apps/app-training/src/core/vertex-tuning.js +234 -0
- package/apps/app-training/src/services/index.d.ts +3 -0
- package/apps/app-training/src/services/index.d.ts.map +1 -0
- package/apps/app-training/src/services/index.js +1 -0
- package/apps/app-training/src/services/training-backend-check.d.ts +8 -0
- package/apps/app-training/src/services/training-backend-check.d.ts.map +1 -0
- package/apps/app-training/src/services/training-backend-check.js +28 -0
- package/apps/app-training/src/services/training-service-like.d.ts +38 -0
- package/apps/app-training/src/services/training-service-like.d.ts.map +1 -0
- package/apps/app-training/src/services/training-service-like.js +1 -0
- package/package.json +489 -34
- package/packages/agent/src/actions/app-control.d.ts +17 -0
- package/packages/agent/src/actions/app-control.d.ts.map +1 -0
- package/packages/agent/src/actions/app-control.js +212 -0
- package/packages/agent/src/actions/calendar.d.ts +19 -0
- package/packages/agent/src/actions/calendar.d.ts.map +1 -0
- package/packages/agent/src/actions/calendar.js +3143 -0
- package/packages/agent/src/actions/context-signal-lexicon.d.ts +17 -0
- package/packages/agent/src/actions/context-signal-lexicon.d.ts.map +1 -0
- package/packages/agent/src/actions/context-signal-lexicon.js +201 -0
- package/packages/agent/src/actions/context-signal.d.ts +46 -0
- package/packages/agent/src/actions/context-signal.d.ts.map +1 -0
- package/packages/agent/src/actions/context-signal.js +134 -0
- package/packages/agent/src/actions/entity-actions.d.ts +4 -0
- package/packages/agent/src/actions/entity-actions.d.ts.map +1 -0
- package/packages/agent/src/actions/entity-actions.js +344 -0
- package/packages/agent/src/actions/gmail.d.ts +33 -0
- package/packages/agent/src/actions/gmail.d.ts.map +1 -0
- package/packages/agent/src/actions/gmail.js +1734 -0
- package/packages/agent/src/actions/grounded-action-reply.d.ts +22 -0
- package/packages/agent/src/actions/grounded-action-reply.d.ts.map +1 -0
- package/packages/agent/src/actions/grounded-action-reply.js +309 -0
- package/packages/agent/src/actions/inbox-digest.d.ts +2 -0
- package/packages/agent/src/actions/inbox-digest.d.ts.map +1 -0
- package/packages/agent/src/actions/inbox-digest.js +1 -0
- package/packages/agent/src/actions/inbox-respond.d.ts +2 -0
- package/packages/agent/src/actions/inbox-respond.d.ts.map +1 -0
- package/packages/agent/src/actions/inbox-respond.js +1 -0
- package/packages/agent/src/actions/inbox-triage.d.ts +2 -0
- package/packages/agent/src/actions/inbox-triage.d.ts.map +1 -0
- package/packages/agent/src/actions/inbox-triage.js +1 -0
- package/packages/agent/src/actions/inbox.d.ts +3 -0
- package/packages/agent/src/actions/inbox.d.ts.map +1 -0
- package/packages/agent/src/actions/inbox.js +856 -0
- package/packages/agent/src/actions/index.d.ts +11 -0
- package/packages/agent/src/actions/index.d.ts.map +1 -0
- package/packages/agent/src/actions/index.js +10 -0
- package/packages/agent/src/actions/life-goal-extractor.d.ts +69 -0
- package/packages/agent/src/actions/life-goal-extractor.d.ts.map +1 -0
- package/packages/agent/src/actions/life-goal-extractor.js +354 -0
- package/packages/agent/src/actions/life-param-extractor.d.ts +78 -0
- package/packages/agent/src/actions/life-param-extractor.d.ts.map +1 -0
- package/packages/agent/src/actions/life-param-extractor.js +423 -0
- package/packages/agent/src/actions/life-recent-context.d.ts +9 -0
- package/packages/agent/src/actions/life-recent-context.d.ts.map +1 -0
- package/packages/agent/src/actions/life-recent-context.js +84 -0
- package/packages/agent/src/actions/life-update-extractor.d.ts +27 -0
- package/packages/agent/src/actions/life-update-extractor.d.ts.map +1 -0
- package/packages/agent/src/actions/life-update-extractor.js +195 -0
- package/packages/agent/src/actions/life.d.ts +9 -0
- package/packages/agent/src/actions/life.d.ts.map +1 -0
- package/packages/agent/src/actions/life.extractor.d.ts +18 -0
- package/packages/agent/src/actions/life.extractor.d.ts.map +1 -0
- package/packages/agent/src/actions/life.extractor.js +264 -0
- package/packages/agent/src/actions/life.js +3379 -0
- package/packages/agent/src/actions/lifeops-extraction-config.d.ts +16 -0
- package/packages/agent/src/actions/lifeops-extraction-config.d.ts.map +1 -0
- package/packages/agent/src/actions/lifeops-extraction-config.js +25 -0
- package/packages/agent/src/actions/lifeops-google-helpers.d.ts +62 -0
- package/packages/agent/src/actions/lifeops-google-helpers.d.ts.map +1 -0
- package/packages/agent/src/actions/lifeops-google-helpers.js +607 -0
- package/packages/agent/src/actions/manage-tasks.d.ts +8 -0
- package/packages/agent/src/actions/manage-tasks.d.ts.map +1 -0
- package/packages/agent/src/actions/manage-tasks.js +253 -0
- package/packages/agent/src/actions/read-channel.d.ts +3 -0
- package/packages/agent/src/actions/read-channel.d.ts.map +1 -0
- package/packages/agent/src/actions/read-channel.js +224 -0
- package/packages/agent/src/actions/restart.d.ts +19 -0
- package/packages/agent/src/actions/restart.d.ts.map +1 -0
- package/packages/agent/src/actions/restart.js +109 -0
- package/packages/agent/src/actions/search-conversations.d.ts +3 -0
- package/packages/agent/src/actions/search-conversations.d.ts.map +1 -0
- package/packages/agent/src/actions/search-conversations.js +181 -0
- package/packages/agent/src/actions/send-admin-message.d.ts +3 -0
- package/packages/agent/src/actions/send-admin-message.d.ts.map +1 -0
- package/packages/agent/src/actions/send-admin-message.js +106 -0
- package/packages/agent/src/actions/send-message.d.ts +11 -0
- package/packages/agent/src/actions/send-message.d.ts.map +1 -0
- package/packages/agent/src/actions/send-message.js +243 -0
- package/packages/agent/src/actions/set-user-name.d.ts +13 -0
- package/packages/agent/src/actions/set-user-name.d.ts.map +1 -0
- package/packages/agent/src/actions/set-user-name.js +82 -0
- package/packages/agent/src/actions/skill-command.d.ts +20 -0
- package/packages/agent/src/actions/skill-command.d.ts.map +1 -0
- package/packages/agent/src/actions/skill-command.js +141 -0
- package/packages/agent/src/actions/stream-control.d.ts +11 -0
- package/packages/agent/src/actions/stream-control.d.ts.map +1 -0
- package/packages/agent/src/actions/stream-control.js +112 -0
- package/packages/agent/src/actions/terminal.d.ts +15 -0
- package/packages/agent/src/actions/terminal.d.ts.map +1 -0
- package/packages/agent/src/actions/terminal.js +453 -0
- package/packages/agent/src/actions/timezone-normalization.d.ts +3 -0
- package/packages/agent/src/actions/timezone-normalization.d.ts.map +1 -0
- package/packages/agent/src/actions/timezone-normalization.js +107 -0
- package/packages/agent/src/actions/update-owner-profile.d.ts +3 -0
- package/packages/agent/src/actions/update-owner-profile.d.ts.map +1 -0
- package/packages/agent/src/actions/update-owner-profile.js +131 -0
- package/packages/agent/src/actions/web-search.d.ts +16 -0
- package/packages/agent/src/actions/web-search.d.ts.map +1 -0
- package/packages/agent/src/actions/web-search.js +196 -0
- package/packages/agent/src/activity-profile/analyzer.d.ts +23 -0
- package/packages/agent/src/activity-profile/analyzer.d.ts.map +1 -0
- package/packages/agent/src/activity-profile/analyzer.js +531 -0
- package/packages/agent/src/activity-profile/proactive-planner.d.ts +49 -0
- package/packages/agent/src/activity-profile/proactive-planner.d.ts.map +1 -0
- package/packages/agent/src/activity-profile/proactive-planner.js +455 -0
- package/packages/agent/src/activity-profile/proactive-worker.d.ts +32 -0
- package/packages/agent/src/activity-profile/proactive-worker.d.ts.map +1 -0
- package/packages/agent/src/activity-profile/proactive-worker.js +523 -0
- package/packages/agent/src/activity-profile/profile-metadata.d.ts +10 -0
- package/packages/agent/src/activity-profile/profile-metadata.d.ts.map +1 -0
- package/packages/agent/src/activity-profile/profile-metadata.js +25 -0
- package/packages/agent/src/activity-profile/service.d.ts +11 -0
- package/packages/agent/src/activity-profile/service.d.ts.map +1 -0
- package/packages/agent/src/activity-profile/service.js +226 -0
- package/packages/agent/src/activity-profile/types.d.ts +89 -0
- package/packages/agent/src/activity-profile/types.d.ts.map +1 -0
- package/packages/agent/src/activity-profile/types.js +29 -0
- package/packages/agent/src/api/agent-admin-routes.d.ts +39 -0
- package/packages/agent/src/api/agent-admin-routes.d.ts.map +1 -0
- package/packages/agent/src/api/agent-admin-routes.js +155 -0
- package/packages/agent/src/api/agent-lifecycle-routes.d.ts +16 -0
- package/packages/agent/src/api/agent-lifecycle-routes.d.ts.map +1 -0
- package/packages/agent/src/api/agent-lifecycle-routes.js +94 -0
- package/packages/agent/src/api/agent-model.d.ts +5 -0
- package/packages/agent/src/api/agent-model.d.ts.map +1 -0
- package/packages/agent/src/api/agent-model.js +154 -0
- package/packages/agent/src/api/agent-status-routes.d.ts +96 -0
- package/packages/agent/src/api/agent-status-routes.d.ts.map +1 -0
- package/packages/agent/src/api/agent-status-routes.js +274 -0
- package/packages/agent/src/api/agent-transfer-routes.d.ts +16 -0
- package/packages/agent/src/api/agent-transfer-routes.d.ts.map +1 -0
- package/packages/agent/src/api/agent-transfer-routes.js +124 -0
- package/packages/agent/src/api/app-package-routes.d.ts +7 -0
- package/packages/agent/src/api/app-package-routes.d.ts.map +1 -0
- package/packages/agent/src/api/app-package-routes.js +59 -0
- package/packages/agent/src/api/apps-routes.d.ts +24 -0
- package/packages/agent/src/api/apps-routes.d.ts.map +1 -0
- package/packages/agent/src/api/apps-routes.js +477 -0
- package/packages/agent/src/api/auth-routes.d.ts +11 -0
- package/packages/agent/src/api/auth-routes.d.ts.map +1 -0
- package/packages/agent/src/api/auth-routes.js +74 -0
- package/packages/agent/src/api/avatar-routes.d.ts +11 -0
- package/packages/agent/src/api/avatar-routes.d.ts.map +1 -0
- package/packages/agent/src/api/avatar-routes.js +205 -0
- package/packages/agent/src/api/binance-skill-helpers.d.ts +26 -0
- package/packages/agent/src/api/binance-skill-helpers.d.ts.map +1 -0
- package/packages/agent/src/api/binance-skill-helpers.js +776 -0
- package/packages/agent/src/api/bluebubbles-routes.d.ts +10 -0
- package/packages/agent/src/api/bluebubbles-routes.d.ts.map +1 -0
- package/packages/agent/src/api/bluebubbles-routes.js +129 -0
- package/packages/agent/src/api/browser-workspace-routes.d.ts +5 -0
- package/packages/agent/src/api/browser-workspace-routes.d.ts.map +1 -0
- package/packages/agent/src/api/browser-workspace-routes.js +100 -0
- package/packages/agent/src/api/bsc-trade.d.ts +40 -0
- package/packages/agent/src/api/bsc-trade.d.ts.map +1 -0
- package/packages/agent/src/api/bsc-trade.js +786 -0
- package/packages/agent/src/api/bug-report-routes.d.ts +10 -0
- package/packages/agent/src/api/bug-report-routes.d.ts.map +1 -0
- package/packages/agent/src/api/bug-report-routes.js +264 -0
- package/packages/agent/src/api/character-routes.d.ts +51 -0
- package/packages/agent/src/api/character-routes.d.ts.map +1 -0
- package/packages/agent/src/api/character-routes.js +367 -0
- package/packages/agent/src/api/chat-augmentation.d.ts +89 -0
- package/packages/agent/src/api/chat-augmentation.d.ts.map +1 -0
- package/packages/agent/src/api/chat-augmentation.js +396 -0
- package/packages/agent/src/api/chat-routes.d.ts +106 -0
- package/packages/agent/src/api/chat-routes.d.ts.map +1 -0
- package/packages/agent/src/api/chat-routes.js +1485 -0
- package/packages/agent/src/api/chat-text-helpers.d.ts +11 -0
- package/packages/agent/src/api/chat-text-helpers.d.ts.map +1 -0
- package/packages/agent/src/api/chat-text-helpers.js +183 -0
- package/packages/agent/src/api/cloud-billing-routes.d.ts +9 -0
- package/packages/agent/src/api/cloud-billing-routes.d.ts.map +1 -0
- package/packages/agent/src/api/cloud-billing-routes.js +388 -0
- package/packages/agent/src/api/cloud-compat-routes.d.ts +10 -0
- package/packages/agent/src/api/cloud-compat-routes.d.ts.map +1 -0
- package/packages/agent/src/api/cloud-compat-routes.js +212 -0
- package/packages/agent/src/api/cloud-provisioning.d.ts +14 -0
- package/packages/agent/src/api/cloud-provisioning.d.ts.map +1 -0
- package/packages/agent/src/api/cloud-provisioning.js +30 -0
- package/packages/agent/src/api/cloud-relay-routes.d.ts +22 -0
- package/packages/agent/src/api/cloud-relay-routes.d.ts.map +1 -0
- package/packages/agent/src/api/cloud-relay-routes.js +52 -0
- package/packages/agent/src/api/cloud-routes.d.ts +80 -0
- package/packages/agent/src/api/cloud-routes.d.ts.map +1 -0
- package/packages/agent/src/api/cloud-routes.js +582 -0
- package/packages/agent/src/api/cloud-status-routes.d.ts +15 -0
- package/packages/agent/src/api/cloud-status-routes.d.ts.map +1 -0
- package/packages/agent/src/api/cloud-status-routes.js +143 -0
- package/packages/agent/src/api/coding-agents-auth-sanitize.d.ts +23 -0
- package/packages/agent/src/api/coding-agents-auth-sanitize.d.ts.map +1 -0
- package/packages/agent/src/api/coding-agents-auth-sanitize.js +39 -0
- package/packages/agent/src/api/coding-agents-preflight-normalize.d.ts +29 -0
- package/packages/agent/src/api/coding-agents-preflight-normalize.d.ts.map +1 -0
- package/packages/agent/src/api/coding-agents-preflight-normalize.js +45 -0
- package/packages/agent/src/api/compat-utils.d.ts +49 -0
- package/packages/agent/src/api/compat-utils.d.ts.map +1 -0
- package/packages/agent/src/api/compat-utils.js +126 -0
- package/packages/agent/src/api/config-env.d.ts +43 -0
- package/packages/agent/src/api/config-env.d.ts.map +1 -0
- package/packages/agent/src/api/config-env.js +284 -0
- package/packages/agent/src/api/config-routes.d.ts +33 -0
- package/packages/agent/src/api/config-routes.d.ts.map +1 -0
- package/packages/agent/src/api/config-routes.js +253 -0
- package/packages/agent/src/api/connector-health.d.ts +42 -0
- package/packages/agent/src/api/connector-health.d.ts.map +1 -0
- package/packages/agent/src/api/connector-health.js +132 -0
- package/packages/agent/src/api/connector-routes.d.ts +21 -0
- package/packages/agent/src/api/connector-routes.d.ts.map +1 -0
- package/packages/agent/src/api/connector-routes.js +79 -0
- package/packages/agent/src/api/conversation-routes.d.ts +42 -0
- package/packages/agent/src/api/conversation-routes.d.ts.map +1 -0
- package/packages/agent/src/api/conversation-routes.js +1128 -0
- package/packages/agent/src/api/coordinator-types.d.ts +47 -0
- package/packages/agent/src/api/coordinator-types.d.ts.map +1 -0
- package/packages/agent/src/api/coordinator-types.js +1 -0
- package/packages/agent/src/api/coordinator-wiring.d.ts +46 -0
- package/packages/agent/src/api/coordinator-wiring.d.ts.map +1 -0
- package/packages/agent/src/api/coordinator-wiring.js +108 -0
- package/packages/agent/src/api/credit-detection.d.ts +9 -0
- package/packages/agent/src/api/credit-detection.d.ts.map +1 -0
- package/packages/agent/src/api/credit-detection.js +41 -0
- package/packages/agent/src/api/database.d.ts +33 -0
- package/packages/agent/src/api/database.d.ts.map +1 -0
- package/packages/agent/src/api/database.js +1020 -0
- package/packages/agent/src/api/diagnostics-routes.d.ts +53 -0
- package/packages/agent/src/api/diagnostics-routes.d.ts.map +1 -0
- package/packages/agent/src/api/diagnostics-routes.js +250 -0
- package/packages/agent/src/api/discord-avatar-cache.d.ts +10 -0
- package/packages/agent/src/api/discord-avatar-cache.d.ts.map +1 -0
- package/packages/agent/src/api/discord-avatar-cache.js +149 -0
- package/packages/agent/src/api/discord-local-routes.d.ts +12 -0
- package/packages/agent/src/api/discord-local-routes.d.ts.map +1 -0
- package/packages/agent/src/api/discord-local-routes.js +145 -0
- package/packages/agent/src/api/discord-profiles.d.ts +26 -0
- package/packages/agent/src/api/discord-profiles.d.ts.map +1 -0
- package/packages/agent/src/api/discord-profiles.js +282 -0
- package/packages/agent/src/api/drop-routes.d.ts +22 -0
- package/packages/agent/src/api/drop-routes.d.ts.map +1 -0
- package/packages/agent/src/api/drop-routes.js +155 -0
- package/packages/agent/src/api/drop-service.d.ts +26 -0
- package/packages/agent/src/api/drop-service.d.ts.map +1 -0
- package/packages/agent/src/api/drop-service.js +134 -0
- package/packages/agent/src/api/early-logs.d.ts +29 -0
- package/packages/agent/src/api/early-logs.d.ts.map +1 -0
- package/packages/agent/src/api/early-logs.js +96 -0
- package/packages/agent/src/api/health-routes.d.ts +44 -0
- package/packages/agent/src/api/health-routes.d.ts.map +1 -0
- package/packages/agent/src/api/health-routes.js +449 -0
- package/packages/agent/src/api/http-helpers.d.ts +50 -0
- package/packages/agent/src/api/http-helpers.d.ts.map +1 -0
- package/packages/agent/src/api/http-helpers.js +148 -0
- package/packages/agent/src/api/imessage-routes.d.ts +55 -0
- package/packages/agent/src/api/imessage-routes.d.ts.map +1 -0
- package/packages/agent/src/api/imessage-routes.js +231 -0
- package/packages/agent/src/api/inbox-routes.d.ts +48 -0
- package/packages/agent/src/api/inbox-routes.d.ts.map +1 -0
- package/packages/agent/src/api/inbox-routes.js +1547 -0
- package/packages/agent/src/api/index.d.ts +63 -0
- package/packages/agent/src/api/index.d.ts.map +1 -0
- package/packages/agent/src/api/index.js +62 -0
- package/packages/agent/src/api/knowledge-routes.d.ts +2 -0
- package/packages/agent/src/api/knowledge-routes.d.ts.map +1 -0
- package/packages/agent/src/api/knowledge-routes.js +2 -0
- package/packages/agent/src/api/knowledge-service-loader.d.ts +2 -0
- package/packages/agent/src/api/knowledge-service-loader.d.ts.map +1 -0
- package/packages/agent/src/api/knowledge-service-loader.js +2 -0
- package/packages/agent/src/api/lifeops-browser-packaging.d.ts +16 -0
- package/packages/agent/src/api/lifeops-browser-packaging.d.ts.map +1 -0
- package/packages/agent/src/api/lifeops-browser-packaging.js +305 -0
- package/packages/agent/src/api/lifeops-routes.d.ts +20 -0
- package/packages/agent/src/api/lifeops-routes.d.ts.map +1 -0
- package/packages/agent/src/api/lifeops-routes.js +1173 -0
- package/packages/agent/src/api/mcp-routes.d.ts +33 -0
- package/packages/agent/src/api/mcp-routes.d.ts.map +1 -0
- package/packages/agent/src/api/mcp-routes.js +186 -0
- package/packages/agent/src/api/memory-bounds.d.ts +51 -0
- package/packages/agent/src/api/memory-bounds.d.ts.map +1 -0
- package/packages/agent/src/api/memory-bounds.js +81 -0
- package/packages/agent/src/api/memory-routes.d.ts +9 -0
- package/packages/agent/src/api/memory-routes.d.ts.map +1 -0
- package/packages/agent/src/api/memory-routes.js +420 -0
- package/packages/agent/src/api/merkle-tree.d.ts +90 -0
- package/packages/agent/src/api/merkle-tree.d.ts.map +1 -0
- package/packages/agent/src/api/merkle-tree.js +174 -0
- package/packages/agent/src/api/misc-routes.d.ts +64 -0
- package/packages/agent/src/api/misc-routes.d.ts.map +1 -0
- package/packages/agent/src/api/misc-routes.js +557 -0
- package/packages/agent/src/api/model-provider-helpers.d.ts +84 -0
- package/packages/agent/src/api/model-provider-helpers.d.ts.map +1 -0
- package/packages/agent/src/api/model-provider-helpers.js +588 -0
- package/packages/agent/src/api/models-routes.d.ts +14 -0
- package/packages/agent/src/api/models-routes.d.ts.map +1 -0
- package/packages/agent/src/api/models-routes.js +37 -0
- package/packages/agent/src/api/music-player-route-fallback.d.ts +16 -0
- package/packages/agent/src/api/music-player-route-fallback.d.ts.map +1 -0
- package/packages/agent/src/api/music-player-route-fallback.js +65 -0
- package/packages/agent/src/api/nfa-routes.d.ts +5 -0
- package/packages/agent/src/api/nfa-routes.d.ts.map +1 -0
- package/packages/agent/src/api/nfa-routes.js +133 -0
- package/packages/agent/src/api/nft-verify.d.ts +16 -0
- package/packages/agent/src/api/nft-verify.d.ts.map +1 -0
- package/packages/agent/src/api/nft-verify.js +81 -0
- package/packages/agent/src/api/og-tracker.d.ts +28 -0
- package/packages/agent/src/api/og-tracker.d.ts.map +1 -0
- package/packages/agent/src/api/og-tracker.js +60 -0
- package/packages/agent/src/api/onboarding-routes.d.ts +50 -0
- package/packages/agent/src/api/onboarding-routes.d.ts.map +1 -0
- package/packages/agent/src/api/onboarding-routes.js +561 -0
- package/packages/agent/src/api/owner-contact-helpers.d.ts +39 -0
- package/packages/agent/src/api/owner-contact-helpers.d.ts.map +1 -0
- package/packages/agent/src/api/owner-contact-helpers.js +47 -0
- package/packages/agent/src/api/parse-action-block.d.ts +35 -0
- package/packages/agent/src/api/parse-action-block.d.ts.map +1 -0
- package/packages/agent/src/api/parse-action-block.js +110 -0
- package/packages/agent/src/api/permissions-routes-extra.d.ts +30 -0
- package/packages/agent/src/api/permissions-routes-extra.d.ts.map +1 -0
- package/packages/agent/src/api/permissions-routes-extra.js +78 -0
- package/packages/agent/src/api/permissions-routes.d.ts +28 -0
- package/packages/agent/src/api/permissions-routes.d.ts.map +1 -0
- package/packages/agent/src/api/permissions-routes.js +180 -0
- package/packages/agent/src/api/plugin-discovery-helpers.d.ts +147 -0
- package/packages/agent/src/api/plugin-discovery-helpers.d.ts.map +1 -0
- package/packages/agent/src/api/plugin-discovery-helpers.js +1015 -0
- package/packages/agent/src/api/plugin-routes.d.ts +127 -0
- package/packages/agent/src/api/plugin-routes.d.ts.map +1 -0
- package/packages/agent/src/api/plugin-routes.js +1140 -0
- package/packages/agent/src/api/plugin-runtime-apply.d.ts +31 -0
- package/packages/agent/src/api/plugin-runtime-apply.d.ts.map +1 -0
- package/packages/agent/src/api/plugin-runtime-apply.js +217 -0
- package/packages/agent/src/api/plugin-validation.d.ts +86 -0
- package/packages/agent/src/api/plugin-validation.d.ts.map +1 -0
- package/packages/agent/src/api/plugin-validation.js +259 -0
- package/packages/agent/src/api/provider-switch-config.d.ts +60 -0
- package/packages/agent/src/api/provider-switch-config.d.ts.map +1 -0
- package/packages/agent/src/api/provider-switch-config.js +718 -0
- package/packages/agent/src/api/provider-switch-routes.d.ts +22 -0
- package/packages/agent/src/api/provider-switch-routes.d.ts.map +1 -0
- package/packages/agent/src/api/provider-switch-routes.js +92 -0
- package/packages/agent/src/api/rate-limiter.d.ts +29 -0
- package/packages/agent/src/api/rate-limiter.d.ts.map +1 -0
- package/packages/agent/src/api/rate-limiter.js +54 -0
- package/packages/agent/src/api/registry-routes.d.ts +29 -0
- package/packages/agent/src/api/registry-routes.d.ts.map +1 -0
- package/packages/agent/src/api/registry-routes.js +98 -0
- package/packages/agent/src/api/registry-service.d.ts +77 -0
- package/packages/agent/src/api/registry-service.d.ts.map +1 -0
- package/packages/agent/src/api/registry-service.js +190 -0
- package/packages/agent/src/api/relationships-routes.d.ts +7 -0
- package/packages/agent/src/api/relationships-routes.d.ts.map +1 -0
- package/packages/agent/src/api/relationships-routes.js +181 -0
- package/packages/agent/src/api/route-helpers.d.ts +16 -0
- package/packages/agent/src/api/route-helpers.d.ts.map +1 -0
- package/packages/agent/src/api/route-helpers.js +1 -0
- package/packages/agent/src/api/runtime-plugin-routes.d.ts +21 -0
- package/packages/agent/src/api/runtime-plugin-routes.d.ts.map +1 -0
- package/packages/agent/src/api/runtime-plugin-routes.js +132 -0
- package/packages/agent/src/api/sandbox-routes.d.ts +12 -0
- package/packages/agent/src/api/sandbox-routes.d.ts.map +1 -0
- package/packages/agent/src/api/sandbox-routes.js +1334 -0
- package/packages/agent/src/api/server-auth.d.ts +52 -0
- package/packages/agent/src/api/server-auth.d.ts.map +1 -0
- package/packages/agent/src/api/server-auth.js +332 -0
- package/packages/agent/src/api/server-helpers.d.ts +95 -0
- package/packages/agent/src/api/server-helpers.d.ts.map +1 -0
- package/packages/agent/src/api/server-helpers.js +708 -0
- package/packages/agent/src/api/server-startup.d.ts +16 -0
- package/packages/agent/src/api/server-startup.d.ts.map +1 -0
- package/packages/agent/src/api/server-startup.js +14 -0
- package/packages/agent/src/api/server-types.d.ts +216 -0
- package/packages/agent/src/api/server-types.d.ts.map +1 -0
- package/packages/agent/src/api/server-types.js +6 -0
- package/packages/agent/src/api/server.d.ts +144 -0
- package/packages/agent/src/api/server.d.ts.map +1 -0
- package/packages/agent/src/api/server.js +5304 -0
- package/packages/agent/src/api/signal-routes.d.ts +42 -0
- package/packages/agent/src/api/signal-routes.d.ts.map +1 -0
- package/packages/agent/src/api/signal-routes.js +232 -0
- package/packages/agent/src/api/skill-discovery-helpers.d.ts +80 -0
- package/packages/agent/src/api/skill-discovery-helpers.d.ts.map +1 -0
- package/packages/agent/src/api/skill-discovery-helpers.js +381 -0
- package/packages/agent/src/api/skills-routes.d.ts +32 -0
- package/packages/agent/src/api/skills-routes.d.ts.map +1 -0
- package/packages/agent/src/api/skills-routes.js +947 -0
- package/packages/agent/src/api/static-file-server.d.ts +19 -0
- package/packages/agent/src/api/static-file-server.d.ts.map +1 -0
- package/packages/agent/src/api/static-file-server.js +233 -0
- package/packages/agent/src/api/stream-persistence.d.ts +64 -0
- package/packages/agent/src/api/stream-persistence.d.ts.map +1 -0
- package/packages/agent/src/api/stream-persistence.js +231 -0
- package/packages/agent/src/api/stream-route-state.d.ts +56 -0
- package/packages/agent/src/api/stream-route-state.d.ts.map +1 -0
- package/packages/agent/src/api/stream-route-state.js +1 -0
- package/packages/agent/src/api/stream-routes.d.ts +43 -0
- package/packages/agent/src/api/stream-routes.d.ts.map +1 -0
- package/packages/agent/src/api/stream-routes.js +728 -0
- package/packages/agent/src/api/streaming-text.d.ts +9 -0
- package/packages/agent/src/api/streaming-text.d.ts.map +1 -0
- package/packages/agent/src/api/streaming-text.js +85 -0
- package/packages/agent/src/api/streaming-types.d.ts +30 -0
- package/packages/agent/src/api/streaming-types.d.ts.map +1 -0
- package/packages/agent/src/api/streaming-types.js +1 -0
- package/packages/agent/src/api/subscription-routes.d.ts +20 -0
- package/packages/agent/src/api/subscription-routes.d.ts.map +1 -0
- package/packages/agent/src/api/subscription-routes.js +213 -0
- package/packages/agent/src/api/task-agent-message-routing.d.ts +10 -0
- package/packages/agent/src/api/task-agent-message-routing.d.ts.map +1 -0
- package/packages/agent/src/api/task-agent-message-routing.js +62 -0
- package/packages/agent/src/api/telegram-account-routes.d.ts +26 -0
- package/packages/agent/src/api/telegram-account-routes.d.ts.map +1 -0
- package/packages/agent/src/api/telegram-account-routes.js +229 -0
- package/packages/agent/src/api/telegram-setup-routes.d.ts +27 -0
- package/packages/agent/src/api/telegram-setup-routes.d.ts.map +1 -0
- package/packages/agent/src/api/telegram-setup-routes.js +125 -0
- package/packages/agent/src/api/terminal-run-limits.d.ts +5 -0
- package/packages/agent/src/api/terminal-run-limits.d.ts.map +1 -0
- package/packages/agent/src/api/terminal-run-limits.js +22 -0
- package/packages/agent/src/api/trade-safety.d.ts +39 -0
- package/packages/agent/src/api/trade-safety.d.ts.map +1 -0
- package/packages/agent/src/api/trade-safety.js +66 -0
- package/packages/agent/src/api/training-backend-check.d.ts +2 -0
- package/packages/agent/src/api/training-backend-check.d.ts.map +1 -0
- package/packages/agent/src/api/training-backend-check.js +2 -0
- package/packages/agent/src/api/training-routes.d.ts +2 -0
- package/packages/agent/src/api/training-routes.d.ts.map +1 -0
- package/packages/agent/src/api/training-routes.js +2 -0
- package/packages/agent/src/api/training-service-like.d.ts +2 -0
- package/packages/agent/src/api/training-service-like.d.ts.map +1 -0
- package/packages/agent/src/api/training-service-like.js +1 -0
- package/packages/agent/src/api/trajectory-routes.d.ts +3 -0
- package/packages/agent/src/api/trajectory-routes.d.ts.map +1 -0
- package/packages/agent/src/api/trajectory-routes.js +2 -0
- package/packages/agent/src/api/trigger-routes.d.ts +73 -0
- package/packages/agent/src/api/trigger-routes.d.ts.map +1 -0
- package/packages/agent/src/api/trigger-routes.js +308 -0
- package/packages/agent/src/api/tts-routes.d.ts +24 -0
- package/packages/agent/src/api/tts-routes.d.ts.map +1 -0
- package/packages/agent/src/api/tts-routes.js +200 -0
- package/packages/agent/src/api/twitter-verify.d.ts +25 -0
- package/packages/agent/src/api/twitter-verify.d.ts.map +1 -0
- package/packages/agent/src/api/twitter-verify.js +168 -0
- package/packages/agent/src/api/tx-service.d.ts +51 -0
- package/packages/agent/src/api/tx-service.d.ts.map +1 -0
- package/packages/agent/src/api/tx-service.js +160 -0
- package/packages/agent/src/api/update-routes.d.ts +19 -0
- package/packages/agent/src/api/update-routes.d.ts.map +1 -0
- package/packages/agent/src/api/update-routes.js +54 -0
- package/packages/agent/src/api/wallet-bsc-routes.d.ts +67 -0
- package/packages/agent/src/api/wallet-bsc-routes.d.ts.map +1 -0
- package/packages/agent/src/api/wallet-bsc-routes.js +322 -0
- package/packages/agent/src/api/wallet-capability.d.ts +33 -0
- package/packages/agent/src/api/wallet-capability.d.ts.map +1 -0
- package/packages/agent/src/api/wallet-capability.js +124 -0
- package/packages/agent/src/api/wallet-dex-prices.d.ts +43 -0
- package/packages/agent/src/api/wallet-dex-prices.d.ts.map +1 -0
- package/packages/agent/src/api/wallet-dex-prices.js +153 -0
- package/packages/agent/src/api/wallet-env-sync.d.ts +2 -0
- package/packages/agent/src/api/wallet-env-sync.d.ts.map +1 -0
- package/packages/agent/src/api/wallet-env-sync.js +104 -0
- package/packages/agent/src/api/wallet-evm-balance.d.ts +66 -0
- package/packages/agent/src/api/wallet-evm-balance.d.ts.map +1 -0
- package/packages/agent/src/api/wallet-evm-balance.js +667 -0
- package/packages/agent/src/api/wallet-routes.d.ts +55 -0
- package/packages/agent/src/api/wallet-routes.d.ts.map +1 -0
- package/packages/agent/src/api/wallet-routes.js +833 -0
- package/packages/agent/src/api/wallet-rpc.d.ts +78 -0
- package/packages/agent/src/api/wallet-rpc.d.ts.map +1 -0
- package/packages/agent/src/api/wallet-rpc.js +476 -0
- package/packages/agent/src/api/wallet-trade-routes.d.ts +110 -0
- package/packages/agent/src/api/wallet-trade-routes.d.ts.map +1 -0
- package/packages/agent/src/api/wallet-trade-routes.js +353 -0
- package/packages/agent/src/api/wallet-trading-profile.d.ts +56 -0
- package/packages/agent/src/api/wallet-trading-profile.d.ts.map +1 -0
- package/packages/agent/src/api/wallet-trading-profile.js +565 -0
- package/packages/agent/src/api/wallet.d.ts +64 -0
- package/packages/agent/src/api/wallet.d.ts.map +1 -0
- package/packages/agent/src/api/wallet.js +674 -0
- package/packages/agent/src/api/website-blocker-routes.d.ts +7 -0
- package/packages/agent/src/api/website-blocker-routes.d.ts.map +1 -0
- package/packages/agent/src/api/website-blocker-routes.js +174 -0
- package/packages/agent/src/api/whatsapp-routes.d.ts +39 -0
- package/packages/agent/src/api/whatsapp-routes.d.ts.map +1 -0
- package/packages/agent/src/api/whatsapp-routes.js +226 -0
- package/packages/agent/src/api/workbench-helpers.d.ts +39 -0
- package/packages/agent/src/api/workbench-helpers.d.ts.map +1 -0
- package/packages/agent/src/api/workbench-helpers.js +133 -0
- package/packages/agent/src/api/workbench-routes.d.ts +53 -0
- package/packages/agent/src/api/workbench-routes.d.ts.map +1 -0
- package/packages/agent/src/api/workbench-routes.js +405 -0
- package/packages/agent/src/api/zip-utils.d.ts +8 -0
- package/packages/agent/src/api/zip-utils.d.ts.map +1 -0
- package/packages/agent/src/api/zip-utils.js +115 -0
- package/packages/agent/src/auth/anthropic.d.ts +29 -0
- package/packages/agent/src/auth/anthropic.d.ts.map +1 -0
- package/packages/agent/src/auth/anthropic.js +43 -0
- package/packages/agent/src/auth/claude-code-stealth.d.ts +2 -0
- package/packages/agent/src/auth/claude-code-stealth.d.ts.map +1 -0
- package/packages/agent/src/auth/claude-code-stealth.js +114 -0
- package/packages/agent/src/auth/credentials.d.ts +74 -0
- package/packages/agent/src/auth/credentials.d.ts.map +1 -0
- package/packages/agent/src/auth/credentials.js +379 -0
- package/packages/agent/src/auth/index.d.ts +6 -0
- package/packages/agent/src/auth/index.d.ts.map +1 -0
- package/packages/agent/src/auth/index.js +5 -0
- package/packages/agent/src/auth/openai-codex.d.ts +32 -0
- package/packages/agent/src/auth/openai-codex.d.ts.map +1 -0
- package/packages/agent/src/auth/openai-codex.js +81 -0
- package/packages/agent/src/auth/types.d.ts +18 -0
- package/packages/agent/src/auth/types.d.ts.map +1 -0
- package/packages/agent/src/auth/types.js +8 -0
- package/packages/agent/src/auth/vendor/pi-oauth/anthropic-login.d.ts +16 -0
- package/packages/agent/src/auth/vendor/pi-oauth/anthropic-login.d.ts.map +1 -0
- package/packages/agent/src/auth/vendor/pi-oauth/anthropic-login.js +78 -0
- package/packages/agent/src/auth/vendor/pi-oauth/openai-codex-login.d.ts +26 -0
- package/packages/agent/src/auth/vendor/pi-oauth/openai-codex-login.d.ts.map +1 -0
- package/packages/agent/src/auth/vendor/pi-oauth/openai-codex-login.js +342 -0
- package/packages/agent/src/auth/vendor/pi-oauth/pkce.d.ts +9 -0
- package/packages/agent/src/auth/vendor/pi-oauth/pkce.d.ts.map +1 -0
- package/packages/agent/src/auth/vendor/pi-oauth/pkce.js +21 -0
- package/packages/agent/src/autonomy/index.d.ts +48 -0
- package/packages/agent/src/autonomy/index.d.ts.map +1 -0
- package/packages/agent/src/autonomy/index.js +330 -0
- package/packages/agent/src/awareness/index.d.ts +2 -0
- package/packages/agent/src/awareness/index.d.ts.map +1 -0
- package/packages/agent/src/awareness/index.js +1 -0
- package/packages/agent/src/awareness/registry.d.ts +27 -0
- package/packages/agent/src/awareness/registry.d.ts.map +1 -0
- package/packages/agent/src/awareness/registry.js +161 -0
- package/packages/agent/src/bin.d.ts +3 -0
- package/packages/agent/src/bin.d.ts.map +1 -0
- package/packages/agent/src/bin.js +6 -0
- package/packages/agent/src/cli/benchmark.d.ts +10 -0
- package/packages/agent/src/cli/benchmark.d.ts.map +1 -0
- package/packages/agent/src/cli/benchmark.js +293 -0
- package/packages/agent/src/cli/index.d.ts +2 -0
- package/packages/agent/src/cli/index.d.ts.map +1 -0
- package/packages/agent/src/cli/index.js +70 -0
- package/packages/agent/src/cli/parse-duration.d.ts +5 -0
- package/packages/agent/src/cli/parse-duration.d.ts.map +1 -0
- package/packages/agent/src/cli/parse-duration.js +27 -0
- package/packages/agent/src/cloud/auth.d.ts +19 -0
- package/packages/agent/src/cloud/auth.d.ts.map +1 -0
- package/packages/agent/src/cloud/auth.js +110 -0
- package/packages/agent/src/cloud/backup.d.ts +18 -0
- package/packages/agent/src/cloud/backup.d.ts.map +1 -0
- package/packages/agent/src/cloud/backup.js +42 -0
- package/packages/agent/src/cloud/base-url.d.ts +3 -0
- package/packages/agent/src/cloud/base-url.d.ts.map +1 -0
- package/packages/agent/src/cloud/base-url.js +52 -0
- package/packages/agent/src/cloud/bridge-client.d.ts +126 -0
- package/packages/agent/src/cloud/bridge-client.d.ts.map +1 -0
- package/packages/agent/src/cloud/bridge-client.js +380 -0
- package/packages/agent/src/cloud/cloud-manager.d.ts +32 -0
- package/packages/agent/src/cloud/cloud-manager.d.ts.map +1 -0
- package/packages/agent/src/cloud/cloud-manager.js +121 -0
- package/packages/agent/src/cloud/cloud-proxy.d.ts +20 -0
- package/packages/agent/src/cloud/cloud-proxy.d.ts.map +1 -0
- package/packages/agent/src/cloud/cloud-proxy.js +34 -0
- package/packages/agent/src/cloud/cloud-wallet.d.ts +94 -0
- package/packages/agent/src/cloud/cloud-wallet.d.ts.map +1 -0
- package/packages/agent/src/cloud/cloud-wallet.js +199 -0
- package/packages/agent/src/cloud/index.d.ts +7 -0
- package/packages/agent/src/cloud/index.d.ts.map +1 -0
- package/packages/agent/src/cloud/index.js +6 -0
- package/packages/agent/src/cloud/reconnect.d.ts +26 -0
- package/packages/agent/src/cloud/reconnect.d.ts.map +1 -0
- package/packages/agent/src/cloud/reconnect.js +89 -0
- package/packages/agent/src/cloud/validate-url.d.ts +2 -0
- package/packages/agent/src/cloud/validate-url.d.ts.map +1 -0
- package/packages/agent/src/cloud/validate-url.js +162 -0
- package/packages/agent/src/config/character-schema.d.ts +25 -0
- package/packages/agent/src/config/character-schema.d.ts.map +1 -0
- package/packages/agent/src/config/character-schema.js +39 -0
- package/packages/agent/src/config/config.d.ts +6 -0
- package/packages/agent/src/config/config.d.ts.map +1 -0
- package/packages/agent/src/config/config.js +277 -0
- package/packages/agent/src/config/env-vars.d.ts +9 -0
- package/packages/agent/src/config/env-vars.d.ts.map +1 -0
- package/packages/agent/src/config/env-vars.js +282 -0
- package/packages/agent/src/config/feature-flags.d.ts +17 -0
- package/packages/agent/src/config/feature-flags.d.ts.map +1 -0
- package/packages/agent/src/config/feature-flags.js +37 -0
- package/packages/agent/src/config/includes.d.ts +26 -0
- package/packages/agent/src/config/includes.d.ts.map +1 -0
- package/packages/agent/src/config/includes.js +148 -0
- package/packages/agent/src/config/index.d.ts +19 -0
- package/packages/agent/src/config/index.d.ts.map +1 -0
- package/packages/agent/src/config/index.js +18 -0
- package/packages/agent/src/config/object-utils.d.ts +2 -0
- package/packages/agent/src/config/object-utils.d.ts.map +1 -0
- package/packages/agent/src/config/object-utils.js +6 -0
- package/packages/agent/src/config/owner-contacts.d.ts +42 -0
- package/packages/agent/src/config/owner-contacts.d.ts.map +1 -0
- package/packages/agent/src/config/owner-contacts.js +223 -0
- package/packages/agent/src/config/paths.d.ts +13 -0
- package/packages/agent/src/config/paths.d.ts.map +1 -0
- package/packages/agent/src/config/paths.js +106 -0
- package/packages/agent/src/config/plugin-auto-enable.d.ts +36 -0
- package/packages/agent/src/config/plugin-auto-enable.d.ts.map +1 -0
- package/packages/agent/src/config/plugin-auto-enable.js +519 -0
- package/packages/agent/src/config/plugin-widgets.d.ts +29 -0
- package/packages/agent/src/config/plugin-widgets.d.ts.map +1 -0
- package/packages/agent/src/config/plugin-widgets.js +70 -0
- package/packages/agent/src/config/runtime-env.d.ts +2 -0
- package/packages/agent/src/config/runtime-env.d.ts.map +1 -0
- package/packages/agent/src/config/runtime-env.js +1 -0
- package/packages/agent/src/config/schema.d.ts +87 -0
- package/packages/agent/src/config/schema.d.ts.map +1 -0
- package/packages/agent/src/config/schema.js +922 -0
- package/packages/agent/src/config/telegram-custom-commands.d.ts +25 -0
- package/packages/agent/src/config/telegram-custom-commands.d.ts.map +1 -0
- package/packages/agent/src/config/telegram-custom-commands.js +71 -0
- package/packages/agent/src/config/types.agent-defaults.d.ts +362 -0
- package/packages/agent/src/config/types.agent-defaults.d.ts.map +1 -0
- package/packages/agent/src/config/types.agent-defaults.js +1 -0
- package/packages/agent/src/config/types.agents.d.ts +114 -0
- package/packages/agent/src/config/types.agents.d.ts.map +1 -0
- package/packages/agent/src/config/types.agents.js +1 -0
- package/packages/agent/src/config/types.d.ts +8 -0
- package/packages/agent/src/config/types.d.ts.map +1 -0
- package/packages/agent/src/config/types.eliza.d.ts +670 -0
- package/packages/agent/src/config/types.eliza.d.ts.map +1 -0
- package/packages/agent/src/config/types.eliza.js +1 -0
- package/packages/agent/src/config/types.gateway.d.ts +216 -0
- package/packages/agent/src/config/types.gateway.d.ts.map +1 -0
- package/packages/agent/src/config/types.gateway.js +1 -0
- package/packages/agent/src/config/types.hooks.d.ts +107 -0
- package/packages/agent/src/config/types.hooks.d.ts.map +1 -0
- package/packages/agent/src/config/types.hooks.js +1 -0
- package/packages/agent/src/config/types.js +7 -0
- package/packages/agent/src/config/types.messages.d.ts +176 -0
- package/packages/agent/src/config/types.messages.d.ts.map +1 -0
- package/packages/agent/src/config/types.messages.js +1 -0
- package/packages/agent/src/config/types.tools.d.ts +400 -0
- package/packages/agent/src/config/types.tools.d.ts.map +1 -0
- package/packages/agent/src/config/types.tools.js +1 -0
- package/packages/agent/src/config/zod-schema.agent-runtime.d.ts +1137 -0
- package/packages/agent/src/config/zod-schema.agent-runtime.d.ts.map +1 -0
- package/packages/agent/src/config/zod-schema.agent-runtime.js +782 -0
- package/packages/agent/src/config/zod-schema.core.d.ts +1021 -0
- package/packages/agent/src/config/zod-schema.core.d.ts.map +1 -0
- package/packages/agent/src/config/zod-schema.core.js +694 -0
- package/packages/agent/src/config/zod-schema.d.ts +3185 -0
- package/packages/agent/src/config/zod-schema.d.ts.map +1 -0
- package/packages/agent/src/config/zod-schema.hooks.d.ts +88 -0
- package/packages/agent/src/config/zod-schema.hooks.d.ts.map +1 -0
- package/packages/agent/src/config/zod-schema.hooks.js +133 -0
- package/packages/agent/src/config/zod-schema.js +850 -0
- package/packages/agent/src/config/zod-schema.providers-core.d.ts +2746 -0
- package/packages/agent/src/config/zod-schema.providers-core.d.ts.map +1 -0
- package/packages/agent/src/config/zod-schema.providers-core.js +961 -0
- package/packages/agent/src/config/zod-schema.session.d.ts +183 -0
- package/packages/agent/src/config/zod-schema.session.d.ts.map +1 -0
- package/packages/agent/src/config/zod-schema.session.js +86 -0
- package/packages/agent/src/contracts/apps.d.ts +2 -0
- package/packages/agent/src/contracts/apps.d.ts.map +1 -0
- package/packages/agent/src/contracts/apps.js +1 -0
- package/packages/agent/src/contracts/awareness.d.ts +38 -0
- package/packages/agent/src/contracts/awareness.d.ts.map +1 -0
- package/packages/agent/src/contracts/awareness.js +7 -0
- package/packages/agent/src/contracts/config.d.ts +148 -0
- package/packages/agent/src/contracts/config.d.ts.map +1 -0
- package/packages/agent/src/contracts/config.js +4 -0
- package/packages/agent/src/contracts/drop.d.ts +2 -0
- package/packages/agent/src/contracts/drop.d.ts.map +1 -0
- package/packages/agent/src/contracts/drop.js +1 -0
- package/packages/agent/src/contracts/index.d.ts +11 -0
- package/packages/agent/src/contracts/index.d.ts.map +1 -0
- package/packages/agent/src/contracts/index.js +10 -0
- package/packages/agent/src/contracts/lifeops.d.ts +2 -0
- package/packages/agent/src/contracts/lifeops.d.ts.map +1 -0
- package/packages/agent/src/contracts/lifeops.js +1 -0
- package/packages/agent/src/contracts/onboarding.d.ts +2 -0
- package/packages/agent/src/contracts/onboarding.d.ts.map +1 -0
- package/packages/agent/src/contracts/onboarding.js +1 -0
- package/packages/agent/src/contracts/permissions.d.ts +2 -0
- package/packages/agent/src/contracts/permissions.d.ts.map +1 -0
- package/packages/agent/src/contracts/permissions.js +1 -0
- package/packages/agent/src/contracts/service-routing.d.ts +2 -0
- package/packages/agent/src/contracts/service-routing.d.ts.map +1 -0
- package/packages/agent/src/contracts/service-routing.js +1 -0
- package/packages/agent/src/contracts/verification.d.ts +2 -0
- package/packages/agent/src/contracts/verification.d.ts.map +1 -0
- package/packages/agent/src/contracts/verification.js +1 -0
- package/packages/agent/src/contracts/wallet.d.ts +2 -0
- package/packages/agent/src/contracts/wallet.d.ts.map +1 -0
- package/packages/agent/src/contracts/wallet.js +1 -0
- package/packages/agent/src/diagnostics/index.d.ts +2 -0
- package/packages/agent/src/diagnostics/index.d.ts.map +1 -0
- package/packages/agent/src/diagnostics/index.js +1 -0
- package/packages/agent/src/diagnostics/integration-observability.d.ts +40 -0
- package/packages/agent/src/diagnostics/integration-observability.d.ts.map +1 -0
- package/packages/agent/src/diagnostics/integration-observability.js +75 -0
- package/packages/agent/src/evals/coordinator-eval-client.d.ts +39 -0
- package/packages/agent/src/evals/coordinator-eval-client.d.ts.map +1 -0
- package/packages/agent/src/evals/coordinator-eval-client.js +138 -0
- package/packages/agent/src/evals/coordinator-live-runner.d.ts +57 -0
- package/packages/agent/src/evals/coordinator-live-runner.d.ts.map +1 -0
- package/packages/agent/src/evals/coordinator-live-runner.js +546 -0
- package/packages/agent/src/evals/coordinator-preflight.d.ts +32 -0
- package/packages/agent/src/evals/coordinator-preflight.d.ts.map +1 -0
- package/packages/agent/src/evals/coordinator-preflight.js +296 -0
- package/packages/agent/src/evals/coordinator-scenarios.d.ts +24 -0
- package/packages/agent/src/evals/coordinator-scenarios.d.ts.map +1 -0
- package/packages/agent/src/evals/coordinator-scenarios.js +1141 -0
- package/packages/agent/src/evaluators/late-join-whitelist.d.ts +16 -0
- package/packages/agent/src/evaluators/late-join-whitelist.d.ts.map +1 -0
- package/packages/agent/src/evaluators/late-join-whitelist.js +67 -0
- package/packages/agent/src/hooks/discovery.d.ts +13 -0
- package/packages/agent/src/hooks/discovery.d.ts.map +1 -0
- package/packages/agent/src/hooks/discovery.js +191 -0
- package/packages/agent/src/hooks/eligibility.d.ts +12 -0
- package/packages/agent/src/hooks/eligibility.d.ts.map +1 -0
- package/packages/agent/src/hooks/eligibility.js +105 -0
- package/packages/agent/src/hooks/index.d.ts +3 -0
- package/packages/agent/src/hooks/index.d.ts.map +1 -0
- package/packages/agent/src/hooks/index.js +2 -0
- package/packages/agent/src/hooks/loader.d.ts +34 -0
- package/packages/agent/src/hooks/loader.d.ts.map +1 -0
- package/packages/agent/src/hooks/loader.js +214 -0
- package/packages/agent/src/hooks/registry.d.ts +11 -0
- package/packages/agent/src/hooks/registry.d.ts.map +1 -0
- package/packages/agent/src/hooks/registry.js +58 -0
- package/packages/agent/src/hooks/types.d.ts +104 -0
- package/packages/agent/src/hooks/types.d.ts.map +1 -0
- package/packages/agent/src/hooks/types.js +8 -0
- package/packages/agent/src/inbox/channel-deep-links.d.ts +20 -0
- package/packages/agent/src/inbox/channel-deep-links.d.ts.map +1 -0
- package/packages/agent/src/inbox/channel-deep-links.js +185 -0
- package/packages/agent/src/inbox/config.d.ts +7 -0
- package/packages/agent/src/inbox/config.d.ts.map +1 -0
- package/packages/agent/src/inbox/config.js +59 -0
- package/packages/agent/src/inbox/message-fetcher.d.ts +33 -0
- package/packages/agent/src/inbox/message-fetcher.d.ts.map +1 -0
- package/packages/agent/src/inbox/message-fetcher.js +252 -0
- package/packages/agent/src/inbox/reflection.d.ts +45 -0
- package/packages/agent/src/inbox/reflection.d.ts.map +1 -0
- package/packages/agent/src/inbox/reflection.js +157 -0
- package/packages/agent/src/inbox/repository.d.ts +53 -0
- package/packages/agent/src/inbox/repository.d.ts.map +1 -0
- package/packages/agent/src/inbox/repository.js +362 -0
- package/packages/agent/src/inbox/triage-classifier.d.ts +17 -0
- package/packages/agent/src/inbox/triage-classifier.d.ts.map +1 -0
- package/packages/agent/src/inbox/triage-classifier.js +209 -0
- package/packages/agent/src/inbox/types.d.ts +130 -0
- package/packages/agent/src/inbox/types.d.ts.map +1 -0
- package/packages/agent/src/inbox/types.js +1 -0
- package/packages/agent/src/index.d.ts +22 -0
- package/packages/agent/src/index.d.ts.map +1 -0
- package/packages/agent/src/index.js +20 -0
- package/packages/agent/src/lifeops/app-state.d.ts +11 -0
- package/packages/agent/src/lifeops/app-state.d.ts.map +1 -0
- package/packages/agent/src/lifeops/app-state.js +32 -0
- package/packages/agent/src/lifeops/apple-reminders.d.ts +58 -0
- package/packages/agent/src/lifeops/apple-reminders.d.ts.map +1 -0
- package/packages/agent/src/lifeops/apple-reminders.js +325 -0
- package/packages/agent/src/lifeops/defaults.d.ts +24 -0
- package/packages/agent/src/lifeops/defaults.d.ts.map +1 -0
- package/packages/agent/src/lifeops/defaults.js +205 -0
- package/packages/agent/src/lifeops/engine.d.ts +8 -0
- package/packages/agent/src/lifeops/engine.d.ts.map +1 -0
- package/packages/agent/src/lifeops/engine.js +389 -0
- package/packages/agent/src/lifeops/goal-grounding.d.ts +54 -0
- package/packages/agent/src/lifeops/goal-grounding.d.ts.map +1 -0
- package/packages/agent/src/lifeops/goal-grounding.js +147 -0
- package/packages/agent/src/lifeops/goal-semantic-evaluator.d.ts +12 -0
- package/packages/agent/src/lifeops/goal-semantic-evaluator.d.ts.map +1 -0
- package/packages/agent/src/lifeops/goal-semantic-evaluator.js +154 -0
- package/packages/agent/src/lifeops/google-api-error.d.ts +7 -0
- package/packages/agent/src/lifeops/google-api-error.d.ts.map +1 -0
- package/packages/agent/src/lifeops/google-api-error.js +35 -0
- package/packages/agent/src/lifeops/google-calendar.d.ts +53 -0
- package/packages/agent/src/lifeops/google-calendar.d.ts.map +1 -0
- package/packages/agent/src/lifeops/google-calendar.js +268 -0
- package/packages/agent/src/lifeops/google-connector-gateway.d.ts +19 -0
- package/packages/agent/src/lifeops/google-connector-gateway.d.ts.map +1 -0
- package/packages/agent/src/lifeops/google-connector-gateway.js +65 -0
- package/packages/agent/src/lifeops/google-fetch.d.ts +11 -0
- package/packages/agent/src/lifeops/google-fetch.d.ts.map +1 -0
- package/packages/agent/src/lifeops/google-fetch.js +85 -0
- package/packages/agent/src/lifeops/google-gmail.d.ts +54 -0
- package/packages/agent/src/lifeops/google-gmail.d.ts.map +1 -0
- package/packages/agent/src/lifeops/google-gmail.js +471 -0
- package/packages/agent/src/lifeops/google-managed-client.d.ts +127 -0
- package/packages/agent/src/lifeops/google-managed-client.d.ts.map +1 -0
- package/packages/agent/src/lifeops/google-managed-client.js +294 -0
- package/packages/agent/src/lifeops/google-oauth.d.ts +61 -0
- package/packages/agent/src/lifeops/google-oauth.d.ts.map +1 -0
- package/packages/agent/src/lifeops/google-oauth.js +494 -0
- package/packages/agent/src/lifeops/google-scopes.d.ts +13 -0
- package/packages/agent/src/lifeops/google-scopes.d.ts.map +1 -0
- package/packages/agent/src/lifeops/google-scopes.js +96 -0
- package/packages/agent/src/lifeops/index.d.ts +3 -0
- package/packages/agent/src/lifeops/index.d.ts.map +1 -0
- package/packages/agent/src/lifeops/index.js +2 -0
- package/packages/agent/src/lifeops/owner-profile.d.ts +15 -0
- package/packages/agent/src/lifeops/owner-profile.d.ts.map +1 -0
- package/packages/agent/src/lifeops/owner-profile.js +194 -0
- package/packages/agent/src/lifeops/repository.d.ts +209 -0
- package/packages/agent/src/lifeops/repository.d.ts.map +1 -0
- package/packages/agent/src/lifeops/repository.js +3187 -0
- package/packages/agent/src/lifeops/runtime.d.ts +14 -0
- package/packages/agent/src/lifeops/runtime.d.ts.map +1 -0
- package/packages/agent/src/lifeops/runtime.js +120 -0
- package/packages/agent/src/lifeops/screen-context.d.ts +52 -0
- package/packages/agent/src/lifeops/screen-context.d.ts.map +1 -0
- package/packages/agent/src/lifeops/screen-context.js +332 -0
- package/packages/agent/src/lifeops/seed-routines.d.ts +20 -0
- package/packages/agent/src/lifeops/seed-routines.d.ts.map +1 -0
- package/packages/agent/src/lifeops/seed-routines.js +111 -0
- package/packages/agent/src/lifeops/service.d.ts +275 -0
- package/packages/agent/src/lifeops/service.d.ts.map +1 -0
- package/packages/agent/src/lifeops/service.js +9260 -0
- package/packages/agent/src/lifeops/sql.d.ts +31 -0
- package/packages/agent/src/lifeops/sql.d.ts.map +1 -0
- package/packages/agent/src/lifeops/sql.js +247 -0
- package/packages/agent/src/lifeops/time.d.ts +17 -0
- package/packages/agent/src/lifeops/time.d.ts.map +1 -0
- package/packages/agent/src/lifeops/time.js +132 -0
- package/packages/agent/src/lifeops/twilio.d.ts +25 -0
- package/packages/agent/src/lifeops/twilio.d.ts.map +1 -0
- package/packages/agent/src/lifeops/twilio.js +157 -0
- package/packages/agent/src/lifeops/x-poster.d.ts +19 -0
- package/packages/agent/src/lifeops/x-poster.d.ts.map +1 -0
- package/packages/agent/src/lifeops/x-poster.js +148 -0
- package/packages/agent/src/onboarding-presets.d.ts +2 -0
- package/packages/agent/src/onboarding-presets.d.ts.map +1 -0
- package/packages/agent/src/onboarding-presets.js +1 -0
- package/packages/agent/src/plugins/custom-rtmp/index.d.ts +12 -0
- package/packages/agent/src/plugins/custom-rtmp/index.d.ts.map +1 -0
- package/packages/agent/src/plugins/custom-rtmp/index.js +26 -0
- package/packages/agent/src/plugins/discord-voice-capability.d.ts +35 -0
- package/packages/agent/src/plugins/discord-voice-capability.d.ts.map +1 -0
- package/packages/agent/src/plugins/discord-voice-capability.js +97 -0
- package/packages/agent/src/providers/activity-profile.d.ts +3 -0
- package/packages/agent/src/providers/activity-profile.d.ts.map +1 -0
- package/packages/agent/src/providers/activity-profile.js +140 -0
- package/packages/agent/src/providers/admin-panel.d.ts +4 -0
- package/packages/agent/src/providers/admin-panel.d.ts.map +1 -0
- package/packages/agent/src/providers/admin-panel.js +83 -0
- package/packages/agent/src/providers/admin-trust.d.ts +4 -0
- package/packages/agent/src/providers/admin-trust.d.ts.map +1 -0
- package/packages/agent/src/providers/admin-trust.js +34 -0
- package/packages/agent/src/providers/conversation-utils.d.ts +11 -0
- package/packages/agent/src/providers/conversation-utils.d.ts.map +1 -0
- package/packages/agent/src/providers/conversation-utils.js +79 -0
- package/packages/agent/src/providers/escalation-trigger.d.ts +15 -0
- package/packages/agent/src/providers/escalation-trigger.d.ts.map +1 -0
- package/packages/agent/src/providers/escalation-trigger.js +165 -0
- package/packages/agent/src/providers/inbox-triage.d.ts +3 -0
- package/packages/agent/src/providers/inbox-triage.d.ts.map +1 -0
- package/packages/agent/src/providers/inbox-triage.js +89 -0
- package/packages/agent/src/providers/index.d.ts +15 -0
- package/packages/agent/src/providers/index.d.ts.map +1 -0
- package/packages/agent/src/providers/index.js +14 -0
- package/packages/agent/src/providers/lifeops.d.ts +3 -0
- package/packages/agent/src/providers/lifeops.d.ts.map +1 -0
- package/packages/agent/src/providers/lifeops.js +157 -0
- package/packages/agent/src/providers/recent-conversations.d.ts +3 -0
- package/packages/agent/src/providers/recent-conversations.d.ts.map +1 -0
- package/packages/agent/src/providers/recent-conversations.js +87 -0
- package/packages/agent/src/providers/relevant-conversations.d.ts +3 -0
- package/packages/agent/src/providers/relevant-conversations.d.ts.map +1 -0
- package/packages/agent/src/providers/relevant-conversations.js +88 -0
- package/packages/agent/src/providers/role-backfill.d.ts +18 -0
- package/packages/agent/src/providers/role-backfill.d.ts.map +1 -0
- package/packages/agent/src/providers/role-backfill.js +84 -0
- package/packages/agent/src/providers/rolodex.d.ts +3 -0
- package/packages/agent/src/providers/rolodex.d.ts.map +1 -0
- package/packages/agent/src/providers/rolodex.js +77 -0
- package/packages/agent/src/providers/session-bridge.d.ts +24 -0
- package/packages/agent/src/providers/session-bridge.d.ts.map +1 -0
- package/packages/agent/src/providers/session-bridge.js +85 -0
- package/packages/agent/src/providers/session-utils.d.ts +20 -0
- package/packages/agent/src/providers/session-utils.d.ts.map +1 -0
- package/packages/agent/src/providers/session-utils.js +33 -0
- package/packages/agent/src/providers/simple-mode.d.ts +4 -0
- package/packages/agent/src/providers/simple-mode.d.ts.map +1 -0
- package/packages/agent/src/providers/simple-mode.js +85 -0
- package/packages/agent/src/providers/skill-provider.d.ts +16 -0
- package/packages/agent/src/providers/skill-provider.d.ts.map +1 -0
- package/packages/agent/src/providers/skill-provider.js +336 -0
- package/packages/agent/src/providers/tasks.d.ts +9 -0
- package/packages/agent/src/providers/tasks.d.ts.map +1 -0
- package/packages/agent/src/providers/tasks.js +113 -0
- package/packages/agent/src/providers/ui-catalog.d.ts +3 -0
- package/packages/agent/src/providers/ui-catalog.d.ts.map +1 -0
- package/packages/agent/src/providers/ui-catalog.js +95 -0
- package/packages/agent/src/providers/user-name.d.ts +11 -0
- package/packages/agent/src/providers/user-name.d.ts.map +1 -0
- package/packages/agent/src/providers/user-name.js +40 -0
- package/packages/agent/src/providers/workspace-provider.d.ts +22 -0
- package/packages/agent/src/providers/workspace-provider.d.ts.map +1 -0
- package/packages/agent/src/providers/workspace-provider.js +177 -0
- package/packages/agent/src/providers/workspace.d.ts +54 -0
- package/packages/agent/src/providers/workspace.d.ts.map +1 -0
- package/packages/agent/src/providers/workspace.js +481 -0
- package/packages/agent/src/runtime/agent-event-service.d.ts +35 -0
- package/packages/agent/src/runtime/agent-event-service.d.ts.map +1 -0
- package/packages/agent/src/runtime/agent-event-service.js +16 -0
- package/packages/agent/src/runtime/cloud-onboarding.d.ts +35 -0
- package/packages/agent/src/runtime/cloud-onboarding.d.ts.map +1 -0
- package/packages/agent/src/runtime/cloud-onboarding.js +279 -0
- package/packages/agent/src/runtime/core-plugins.d.ts +19 -0
- package/packages/agent/src/runtime/core-plugins.d.ts.map +1 -0
- package/packages/agent/src/runtime/core-plugins.js +62 -0
- package/packages/agent/src/runtime/custom-actions.d.ts +43 -0
- package/packages/agent/src/runtime/custom-actions.d.ts.map +1 -0
- package/packages/agent/src/runtime/custom-actions.js +507 -0
- package/packages/agent/src/runtime/default-knowledge.d.ts +20 -0
- package/packages/agent/src/runtime/default-knowledge.d.ts.map +1 -0
- package/packages/agent/src/runtime/default-knowledge.js +256 -0
- package/packages/agent/src/runtime/discord-local-plugin.d.ts +86 -0
- package/packages/agent/src/runtime/discord-local-plugin.d.ts.map +1 -0
- package/packages/agent/src/runtime/discord-local-plugin.js +884 -0
- package/packages/agent/src/runtime/eliza-plugin.d.ts +16 -0
- package/packages/agent/src/runtime/eliza-plugin.d.ts.map +1 -0
- package/packages/agent/src/runtime/eliza-plugin.js +218 -0
- package/packages/agent/src/runtime/eliza.d.ts +181 -0
- package/packages/agent/src/runtime/eliza.d.ts.map +1 -0
- package/packages/agent/src/runtime/eliza.js +3286 -0
- package/packages/agent/src/runtime/embedding-presets.d.ts +19 -0
- package/packages/agent/src/runtime/embedding-presets.d.ts.map +1 -0
- package/packages/agent/src/runtime/embedding-presets.js +60 -0
- package/packages/agent/src/runtime/first-time-setup.d.ts +25 -0
- package/packages/agent/src/runtime/first-time-setup.d.ts.map +1 -0
- package/packages/agent/src/runtime/first-time-setup.js +697 -0
- package/packages/agent/src/runtime/index.d.ts +13 -0
- package/packages/agent/src/runtime/index.d.ts.map +1 -0
- package/packages/agent/src/runtime/index.js +12 -0
- package/packages/agent/src/runtime/native-runtime-features.d.ts +4 -0
- package/packages/agent/src/runtime/native-runtime-features.d.ts.map +1 -0
- package/packages/agent/src/runtime/native-runtime-features.js +10 -0
- package/packages/agent/src/runtime/onboarding-names.d.ts +11 -0
- package/packages/agent/src/runtime/onboarding-names.d.ts.map +1 -0
- package/packages/agent/src/runtime/onboarding-names.js +74 -0
- package/packages/agent/src/runtime/owner-entity.d.ts +4 -0
- package/packages/agent/src/runtime/owner-entity.d.ts.map +1 -0
- package/packages/agent/src/runtime/owner-entity.js +30 -0
- package/packages/agent/src/runtime/pglite-error-compat.d.ts +28 -0
- package/packages/agent/src/runtime/pglite-error-compat.d.ts.map +1 -0
- package/packages/agent/src/runtime/pglite-error-compat.js +54 -0
- package/packages/agent/src/runtime/plugin-collector.d.ts +38 -0
- package/packages/agent/src/runtime/plugin-collector.d.ts.map +1 -0
- package/packages/agent/src/runtime/plugin-collector.js +397 -0
- package/packages/agent/src/runtime/plugin-lifecycle.d.ts +44 -0
- package/packages/agent/src/runtime/plugin-lifecycle.d.ts.map +1 -0
- package/packages/agent/src/runtime/plugin-lifecycle.js +584 -0
- package/packages/agent/src/runtime/plugin-resolver.d.ts +31 -0
- package/packages/agent/src/runtime/plugin-resolver.d.ts.map +1 -0
- package/packages/agent/src/runtime/plugin-resolver.js +828 -0
- package/packages/agent/src/runtime/plugin-role-gating.d.ts +34 -0
- package/packages/agent/src/runtime/plugin-role-gating.d.ts.map +1 -0
- package/packages/agent/src/runtime/plugin-role-gating.js +232 -0
- package/packages/agent/src/runtime/plugin-types.d.ts +71 -0
- package/packages/agent/src/runtime/plugin-types.d.ts.map +1 -0
- package/packages/agent/src/runtime/plugin-types.js +318 -0
- package/packages/agent/src/runtime/prompt-compaction.d.ts +80 -0
- package/packages/agent/src/runtime/prompt-compaction.d.ts.map +1 -0
- package/packages/agent/src/runtime/prompt-compaction.js +307 -0
- package/packages/agent/src/runtime/prompt-optimization.d.ts +11 -0
- package/packages/agent/src/runtime/prompt-optimization.d.ts.map +1 -0
- package/packages/agent/src/runtime/prompt-optimization.js +421 -0
- package/packages/agent/src/runtime/release-plugin-policy.d.ts +20 -0
- package/packages/agent/src/runtime/release-plugin-policy.d.ts.map +1 -0
- package/packages/agent/src/runtime/release-plugin-policy.js +85 -0
- package/packages/agent/src/runtime/restart.d.ts +45 -0
- package/packages/agent/src/runtime/restart.d.ts.map +1 -0
- package/packages/agent/src/runtime/restart.js +45 -0
- package/packages/agent/src/runtime/roles/src/action.d.ts +11 -0
- package/packages/agent/src/runtime/roles/src/action.d.ts.map +1 -0
- package/packages/agent/src/runtime/roles/src/action.js +676 -0
- package/packages/agent/src/runtime/roles/src/index.d.ts +24 -0
- package/packages/agent/src/runtime/roles/src/index.d.ts.map +1 -0
- package/packages/agent/src/runtime/roles/src/index.js +243 -0
- package/packages/agent/src/runtime/roles/src/intent.d.ts +18 -0
- package/packages/agent/src/runtime/roles/src/intent.d.ts.map +1 -0
- package/packages/agent/src/runtime/roles/src/intent.js +299 -0
- package/packages/agent/src/runtime/roles/src/provider.d.ts +7 -0
- package/packages/agent/src/runtime/roles/src/provider.d.ts.map +1 -0
- package/packages/agent/src/runtime/roles/src/provider.js +133 -0
- package/packages/agent/src/runtime/roles/src/types.d.ts +3 -0
- package/packages/agent/src/runtime/roles/src/types.d.ts.map +1 -0
- package/packages/agent/src/runtime/roles/src/types.js +1 -0
- package/packages/agent/src/runtime/roles/src/utils.d.ts +2 -0
- package/packages/agent/src/runtime/roles/src/utils.d.ts.map +1 -0
- package/packages/agent/src/runtime/roles/src/utils.js +1 -0
- package/packages/agent/src/runtime/roles.d.ts +3 -0
- package/packages/agent/src/runtime/roles.d.ts.map +1 -0
- package/packages/agent/src/runtime/roles.js +5 -0
- package/packages/agent/src/runtime/trajectory-export.d.ts +8 -0
- package/packages/agent/src/runtime/trajectory-export.d.ts.map +1 -0
- package/packages/agent/src/runtime/trajectory-export.js +7 -0
- package/packages/agent/src/runtime/trajectory-internals.d.ts +217 -0
- package/packages/agent/src/runtime/trajectory-internals.d.ts.map +1 -0
- package/packages/agent/src/runtime/trajectory-internals.js +1298 -0
- package/packages/agent/src/runtime/trajectory-persistence.d.ts +15 -0
- package/packages/agent/src/runtime/trajectory-persistence.d.ts.map +1 -0
- package/packages/agent/src/runtime/trajectory-persistence.js +29 -0
- package/packages/agent/src/runtime/trajectory-query.d.ts +8 -0
- package/packages/agent/src/runtime/trajectory-query.d.ts.map +1 -0
- package/packages/agent/src/runtime/trajectory-query.js +27 -0
- package/packages/agent/src/runtime/trajectory-storage.d.ts +65 -0
- package/packages/agent/src/runtime/trajectory-storage.d.ts.map +1 -0
- package/packages/agent/src/runtime/trajectory-storage.js +1026 -0
- package/packages/agent/src/runtime/version.d.ts +2 -0
- package/packages/agent/src/runtime/version.d.ts.map +1 -0
- package/packages/agent/src/runtime/version.js +5 -0
- package/packages/agent/src/runtime/web-search-tools.d.ts +22 -0
- package/packages/agent/src/runtime/web-search-tools.d.ts.map +1 -0
- package/packages/agent/src/runtime/web-search-tools.js +149 -0
- package/packages/agent/src/security/access.d.ts +17 -0
- package/packages/agent/src/security/access.d.ts.map +1 -0
- package/packages/agent/src/security/access.js +149 -0
- package/packages/agent/src/security/audit-log.d.ts +49 -0
- package/packages/agent/src/security/audit-log.d.ts.map +1 -0
- package/packages/agent/src/security/audit-log.js +161 -0
- package/packages/agent/src/security/index.d.ts +3 -0
- package/packages/agent/src/security/index.d.ts.map +1 -0
- package/packages/agent/src/security/index.js +2 -0
- package/packages/agent/src/security/network-policy.d.ts +6 -0
- package/packages/agent/src/security/network-policy.d.ts.map +1 -0
- package/packages/agent/src/security/network-policy.js +85 -0
- package/packages/agent/src/server/index.d.ts +3 -0
- package/packages/agent/src/server/index.d.ts.map +1 -0
- package/packages/agent/src/server/index.js +1 -0
- package/packages/agent/src/services/agent-export.d.ts +100 -0
- package/packages/agent/src/services/agent-export.d.ts.map +1 -0
- package/packages/agent/src/services/agent-export.js +729 -0
- package/packages/agent/src/services/app-manager.d.ts +56 -0
- package/packages/agent/src/services/app-manager.d.ts.map +1 -0
- package/packages/agent/src/services/app-manager.js +2019 -0
- package/packages/agent/src/services/app-package-modules.d.ts +30 -0
- package/packages/agent/src/services/app-package-modules.d.ts.map +1 -0
- package/packages/agent/src/services/app-package-modules.js +348 -0
- package/packages/agent/src/services/app-run-store.d.ts +6 -0
- package/packages/agent/src/services/app-run-store.d.ts.map +1 -0
- package/packages/agent/src/services/app-run-store.js +490 -0
- package/packages/agent/src/services/app-session-gate.d.ts +15 -0
- package/packages/agent/src/services/app-session-gate.d.ts.map +1 -0
- package/packages/agent/src/services/app-session-gate.js +71 -0
- package/packages/agent/src/services/browser-capture.d.ts +41 -0
- package/packages/agent/src/services/browser-capture.d.ts.map +1 -0
- package/packages/agent/src/services/browser-capture.js +173 -0
- package/packages/agent/src/services/browser-workspace.d.ts +179 -0
- package/packages/agent/src/services/browser-workspace.d.ts.map +1 -0
- package/packages/agent/src/services/browser-workspace.js +4589 -0
- package/packages/agent/src/services/built-in-app-routes/2004scape.d.ts +28 -0
- package/packages/agent/src/services/built-in-app-routes/2004scape.d.ts.map +1 -0
- package/packages/agent/src/services/built-in-app-routes/2004scape.js +1343 -0
- package/packages/agent/src/services/built-in-app-routes/hyperscape.d.ts +5 -0
- package/packages/agent/src/services/built-in-app-routes/hyperscape.d.ts.map +1 -0
- package/packages/agent/src/services/built-in-app-routes/hyperscape.js +189 -0
- package/packages/agent/src/services/character-persistence.d.ts +39 -0
- package/packages/agent/src/services/character-persistence.d.ts.map +1 -0
- package/packages/agent/src/services/character-persistence.js +159 -0
- package/packages/agent/src/services/client-chat-sender.d.ts +19 -0
- package/packages/agent/src/services/client-chat-sender.d.ts.map +1 -0
- package/packages/agent/src/services/client-chat-sender.js +88 -0
- package/packages/agent/src/services/coding-agent-context.d.ts +310 -0
- package/packages/agent/src/services/coding-agent-context.d.ts.map +1 -0
- package/packages/agent/src/services/coding-agent-context.js +281 -0
- package/packages/agent/src/services/coding-task-executor.d.ts +20 -0
- package/packages/agent/src/services/coding-task-executor.d.ts.map +1 -0
- package/packages/agent/src/services/coding-task-executor.js +141 -0
- package/packages/agent/src/services/config-plugin-manager.d.ts +6 -0
- package/packages/agent/src/services/config-plugin-manager.d.ts.map +1 -0
- package/packages/agent/src/services/config-plugin-manager.js +53 -0
- package/packages/agent/src/services/connector-setup-service.d.ts +48 -0
- package/packages/agent/src/services/connector-setup-service.d.ts.map +1 -0
- package/packages/agent/src/services/connector-setup-service.js +60 -0
- package/packages/agent/src/services/conversation-proximity.d.ts +27 -0
- package/packages/agent/src/services/conversation-proximity.d.ts.map +1 -0
- package/packages/agent/src/services/conversation-proximity.js +124 -0
- package/packages/agent/src/services/credential-words.d.ts +26 -0
- package/packages/agent/src/services/credential-words.d.ts.map +1 -0
- package/packages/agent/src/services/credential-words.js +116 -0
- package/packages/agent/src/services/escalation.d.ts +46 -0
- package/packages/agent/src/services/escalation.d.ts.map +1 -0
- package/packages/agent/src/services/escalation.js +415 -0
- package/packages/agent/src/services/executor-registry.d.ts +4 -0
- package/packages/agent/src/services/executor-registry.d.ts.map +1 -0
- package/packages/agent/src/services/executor-registry.js +10 -0
- package/packages/agent/src/services/index.d.ts +25 -0
- package/packages/agent/src/services/index.d.ts.map +1 -0
- package/packages/agent/src/services/index.js +24 -0
- package/packages/agent/src/services/mcp-marketplace.d.ts +89 -0
- package/packages/agent/src/services/mcp-marketplace.d.ts.map +1 -0
- package/packages/agent/src/services/mcp-marketplace.js +200 -0
- package/packages/agent/src/services/overlay-app-presence.d.ts +9 -0
- package/packages/agent/src/services/overlay-app-presence.d.ts.map +1 -0
- package/packages/agent/src/services/overlay-app-presence.js +18 -0
- package/packages/agent/src/services/plugin-manager-types.d.ts +113 -0
- package/packages/agent/src/services/plugin-manager-types.d.ts.map +1 -0
- package/packages/agent/src/services/plugin-manager-types.js +18 -0
- package/packages/agent/src/services/privy-wallets.d.ts +23 -0
- package/packages/agent/src/services/privy-wallets.d.ts.map +1 -0
- package/packages/agent/src/services/privy-wallets.js +230 -0
- package/packages/agent/src/services/registry-client-app-meta.d.ts +6 -0
- package/packages/agent/src/services/registry-client-app-meta.d.ts.map +1 -0
- package/packages/agent/src/services/registry-client-app-meta.js +225 -0
- package/packages/agent/src/services/registry-client-endpoints.d.ts +7 -0
- package/packages/agent/src/services/registry-client-endpoints.d.ts.map +1 -0
- package/packages/agent/src/services/registry-client-endpoints.js +190 -0
- package/packages/agent/src/services/registry-client-local.d.ts +4 -0
- package/packages/agent/src/services/registry-client-local.d.ts.map +1 -0
- package/packages/agent/src/services/registry-client-local.js +545 -0
- package/packages/agent/src/services/registry-client-network.d.ts +9 -0
- package/packages/agent/src/services/registry-client-network.d.ts.map +1 -0
- package/packages/agent/src/services/registry-client-network.js +119 -0
- package/packages/agent/src/services/registry-client-queries.d.ts +15 -0
- package/packages/agent/src/services/registry-client-queries.d.ts.map +1 -0
- package/packages/agent/src/services/registry-client-queries.js +172 -0
- package/packages/agent/src/services/registry-client-types.d.ts +125 -0
- package/packages/agent/src/services/registry-client-types.d.ts.map +1 -0
- package/packages/agent/src/services/registry-client-types.js +1 -0
- package/packages/agent/src/services/registry-client.d.ts +39 -0
- package/packages/agent/src/services/registry-client.d.ts.map +1 -0
- package/packages/agent/src/services/registry-client.js +332 -0
- package/packages/agent/src/services/relationships-graph.d.ts +134 -0
- package/packages/agent/src/services/relationships-graph.d.ts.map +1 -0
- package/packages/agent/src/services/relationships-graph.js +1332 -0
- package/packages/agent/src/services/remote-signing-service.d.ts +58 -0
- package/packages/agent/src/services/remote-signing-service.d.ts.map +1 -0
- package/packages/agent/src/services/remote-signing-service.js +185 -0
- package/packages/agent/src/services/research-task-executor.d.ts +14 -0
- package/packages/agent/src/services/research-task-executor.d.ts.map +1 -0
- package/packages/agent/src/services/research-task-executor.js +136 -0
- package/packages/agent/src/services/sandbox-engine.d.ts +96 -0
- package/packages/agent/src/services/sandbox-engine.d.ts.map +1 -0
- package/packages/agent/src/services/sandbox-engine.js +604 -0
- package/packages/agent/src/services/sandbox-manager.d.ts +106 -0
- package/packages/agent/src/services/sandbox-manager.d.ts.map +1 -0
- package/packages/agent/src/services/sandbox-manager.js +380 -0
- package/packages/agent/src/services/self-updater.d.ts +21 -0
- package/packages/agent/src/services/self-updater.d.ts.map +1 -0
- package/packages/agent/src/services/self-updater.js +162 -0
- package/packages/agent/src/services/send-handler-availability.d.ts +5 -0
- package/packages/agent/src/services/send-handler-availability.d.ts.map +1 -0
- package/packages/agent/src/services/send-handler-availability.js +20 -0
- package/packages/agent/src/services/signal-pairing.d.ts +57 -0
- package/packages/agent/src/services/signal-pairing.d.ts.map +1 -0
- package/packages/agent/src/services/signal-pairing.js +393 -0
- package/packages/agent/src/services/signing-policy.d.ts +44 -0
- package/packages/agent/src/services/signing-policy.d.ts.map +1 -0
- package/packages/agent/src/services/signing-policy.js +165 -0
- package/packages/agent/src/services/skill-catalog-client.d.ts +47 -0
- package/packages/agent/src/services/skill-catalog-client.d.ts.map +1 -0
- package/packages/agent/src/services/skill-catalog-client.js +130 -0
- package/packages/agent/src/services/skill-marketplace.d.ts +42 -0
- package/packages/agent/src/services/skill-marketplace.d.ts.map +1 -0
- package/packages/agent/src/services/skill-marketplace.js +689 -0
- package/packages/agent/src/services/steward-evm-account.d.ts +62 -0
- package/packages/agent/src/services/steward-evm-account.d.ts.map +1 -0
- package/packages/agent/src/services/steward-evm-account.js +308 -0
- package/packages/agent/src/services/steward-evm-bridge.d.ts +39 -0
- package/packages/agent/src/services/steward-evm-bridge.d.ts.map +1 -0
- package/packages/agent/src/services/steward-evm-bridge.js +103 -0
- package/packages/agent/src/services/steward-wallet.d.ts +30 -0
- package/packages/agent/src/services/steward-wallet.d.ts.map +1 -0
- package/packages/agent/src/services/steward-wallet.js +334 -0
- package/packages/agent/src/services/stream-manager.d.ts +121 -0
- package/packages/agent/src/services/stream-manager.d.ts.map +1 -0
- package/packages/agent/src/services/stream-manager.js +609 -0
- package/packages/agent/src/services/task-executor.d.ts +47 -0
- package/packages/agent/src/services/task-executor.d.ts.map +1 -0
- package/packages/agent/src/services/task-executor.js +31 -0
- package/packages/agent/src/services/telegram-account-auth.d.ts +99 -0
- package/packages/agent/src/services/telegram-account-auth.d.ts.map +1 -0
- package/packages/agent/src/services/telegram-account-auth.js +611 -0
- package/packages/agent/src/services/tts-stream-bridge.d.ts +83 -0
- package/packages/agent/src/services/tts-stream-bridge.d.ts.map +1 -0
- package/packages/agent/src/services/tts-stream-bridge.js +360 -0
- package/packages/agent/src/services/update-checker.d.ts +29 -0
- package/packages/agent/src/services/update-checker.d.ts.map +1 -0
- package/packages/agent/src/services/update-checker.js +134 -0
- package/packages/agent/src/services/version-compat.d.ts +99 -0
- package/packages/agent/src/services/version-compat.d.ts.map +1 -0
- package/packages/agent/src/services/version-compat.js +203 -0
- package/packages/agent/src/services/whatsapp-pairing.d.ts +41 -0
- package/packages/agent/src/services/whatsapp-pairing.d.ts.map +1 -0
- package/packages/agent/src/services/whatsapp-pairing.js +209 -0
- package/packages/agent/src/shared/index.d.ts +2 -0
- package/packages/agent/src/shared/index.d.ts.map +1 -0
- package/packages/agent/src/shared/index.js +1 -0
- package/packages/agent/src/shared/ui-catalog-prompt.d.ts +52 -0
- package/packages/agent/src/shared/ui-catalog-prompt.d.ts.map +1 -0
- package/packages/agent/src/shared/ui-catalog-prompt.js +1028 -0
- package/packages/agent/src/test-support/index.d.ts +4 -0
- package/packages/agent/src/test-support/index.d.ts.map +1 -0
- package/packages/agent/src/test-support/index.js +3 -0
- package/packages/agent/src/test-support/process-helpers.d.ts +13 -0
- package/packages/agent/src/test-support/process-helpers.d.ts.map +1 -0
- package/packages/agent/src/test-support/process-helpers.js +23 -0
- package/packages/agent/src/test-support/route-test-helpers.d.ts +37 -0
- package/packages/agent/src/test-support/route-test-helpers.d.ts.map +1 -0
- package/packages/agent/src/test-support/route-test-helpers.js +54 -0
- package/packages/agent/src/test-support/test-helpers.d.ts +77 -0
- package/packages/agent/src/test-support/test-helpers.d.ts.map +1 -0
- package/packages/agent/src/test-support/test-helpers.js +217 -0
- package/packages/agent/src/test-utils/sqlite-compat.d.ts +17 -0
- package/packages/agent/src/test-utils/sqlite-compat.d.ts.map +1 -0
- package/packages/agent/src/test-utils/sqlite-compat.js +48 -0
- package/packages/agent/src/testing/index.d.ts +4 -0
- package/packages/agent/src/testing/index.d.ts.map +1 -0
- package/packages/agent/src/testing/index.js +3 -0
- package/packages/agent/src/training/cli.d.ts +2 -0
- package/packages/agent/src/training/cli.d.ts.map +1 -0
- package/packages/agent/src/training/cli.js +2 -0
- package/packages/agent/src/training/context-audit.d.ts +2 -0
- package/packages/agent/src/training/context-audit.d.ts.map +1 -0
- package/packages/agent/src/training/context-audit.js +2 -0
- package/packages/agent/src/training/context-catalog.d.ts +2 -0
- package/packages/agent/src/training/context-catalog.d.ts.map +1 -0
- package/packages/agent/src/training/context-catalog.js +2 -0
- package/packages/agent/src/training/context-types.d.ts +2 -0
- package/packages/agent/src/training/context-types.d.ts.map +1 -0
- package/packages/agent/src/training/context-types.js +2 -0
- package/packages/agent/src/training/dataset-generator.d.ts +2 -0
- package/packages/agent/src/training/dataset-generator.d.ts.map +1 -0
- package/packages/agent/src/training/dataset-generator.js +2 -0
- package/packages/agent/src/training/replay-validator.d.ts +2 -0
- package/packages/agent/src/training/replay-validator.d.ts.map +1 -0
- package/packages/agent/src/training/replay-validator.js +2 -0
- package/packages/agent/src/training/roleplay-executor.d.ts +2 -0
- package/packages/agent/src/training/roleplay-executor.d.ts.map +1 -0
- package/packages/agent/src/training/roleplay-executor.js +2 -0
- package/packages/agent/src/training/roleplay-trajectories.d.ts +2 -0
- package/packages/agent/src/training/roleplay-trajectories.d.ts.map +1 -0
- package/packages/agent/src/training/roleplay-trajectories.js +2 -0
- package/packages/agent/src/training/scenario-blueprints.d.ts +2 -0
- package/packages/agent/src/training/scenario-blueprints.d.ts.map +1 -0
- package/packages/agent/src/training/scenario-blueprints.js +2 -0
- package/packages/agent/src/training/trajectory-task-datasets.d.ts +2 -0
- package/packages/agent/src/training/trajectory-task-datasets.d.ts.map +1 -0
- package/packages/agent/src/training/trajectory-task-datasets.js +2 -0
- package/packages/agent/src/training/vertex-tuning.d.ts +2 -0
- package/packages/agent/src/training/vertex-tuning.d.ts.map +1 -0
- package/packages/agent/src/training/vertex-tuning.js +2 -0
- package/packages/agent/src/triggers/action.d.ts +4 -0
- package/packages/agent/src/triggers/action.d.ts.map +1 -0
- package/packages/agent/src/triggers/action.js +316 -0
- package/packages/agent/src/triggers/index.d.ts +5 -0
- package/packages/agent/src/triggers/index.d.ts.map +1 -0
- package/packages/agent/src/triggers/index.js +4 -0
- package/packages/agent/src/triggers/runtime.d.ts +25 -0
- package/packages/agent/src/triggers/runtime.d.ts.map +1 -0
- package/packages/agent/src/triggers/runtime.js +456 -0
- package/packages/agent/src/triggers/scheduling.d.ts +71 -0
- package/packages/agent/src/triggers/scheduling.d.ts.map +1 -0
- package/packages/agent/src/triggers/scheduling.js +355 -0
- package/packages/agent/src/triggers/types.d.ts +115 -0
- package/packages/agent/src/triggers/types.d.ts.map +1 -0
- package/packages/agent/src/triggers/types.js +1 -0
- package/packages/agent/src/types/agent-skills.d.ts +19 -0
- package/packages/agent/src/types/agent-skills.d.ts.map +1 -0
- package/packages/agent/src/types/agent-skills.js +7 -0
- package/packages/agent/src/types/config-like.d.ts +17 -0
- package/packages/agent/src/types/config-like.d.ts.map +1 -0
- package/packages/agent/src/types/config-like.js +7 -0
- package/packages/agent/src/types/trajectory.d.ts +106 -0
- package/packages/agent/src/types/trajectory.d.ts.map +1 -0
- package/packages/agent/src/types/trajectory.js +7 -0
- package/packages/agent/src/utils/exec-safety.d.ts +2 -0
- package/packages/agent/src/utils/exec-safety.d.ts.map +1 -0
- package/packages/agent/src/utils/exec-safety.js +21 -0
- package/packages/agent/src/utils/index.d.ts +3 -0
- package/packages/agent/src/utils/index.d.ts.map +1 -0
- package/packages/agent/src/utils/index.js +2 -0
- package/packages/agent/src/utils/number-parsing.d.ts +26 -0
- package/packages/agent/src/utils/number-parsing.d.ts.map +1 -0
- package/packages/agent/src/utils/number-parsing.js +52 -0
- package/packages/agent/src/utils/spoken-text.d.ts +2 -0
- package/packages/agent/src/utils/spoken-text.d.ts.map +1 -0
- package/packages/agent/src/utils/spoken-text.js +1 -0
- package/packages/agent/src/version-resolver.d.ts +2 -0
- package/packages/agent/src/version-resolver.d.ts.map +1 -0
- package/packages/agent/src/version-resolver.js +50 -0
- package/packages/app-core/src/api/cloud-secrets.d.ts +23 -0
- package/packages/app-core/src/api/cloud-secrets.d.ts.map +1 -0
- package/packages/app-core/src/api/cloud-secrets.js +50 -0
- package/packages/app-core/src/api/compat-route-shared.d.ts +16 -0
- package/packages/app-core/src/api/compat-route-shared.d.ts.map +1 -0
- package/packages/app-core/src/api/compat-route-shared.js +99 -0
- package/packages/app-core/src/api/response.d.ts +12 -0
- package/packages/app-core/src/api/response.d.ts.map +1 -0
- package/packages/app-core/src/api/response.js +18 -0
- package/packages/app-core/src/api/server-cloud-tts.d.ts +41 -0
- package/packages/app-core/src/api/server-cloud-tts.d.ts.map +1 -0
- package/packages/app-core/src/api/server-cloud-tts.js +469 -0
- package/packages/app-core/src/config/boot-config-store.d.ts +117 -0
- package/packages/app-core/src/config/boot-config-store.d.ts.map +1 -0
- package/packages/app-core/src/config/boot-config-store.js +135 -0
- package/packages/app-core/src/config/boot-config.d.ts +6 -0
- package/packages/app-core/src/config/boot-config.d.ts.map +1 -0
- package/packages/app-core/src/config/boot-config.js +5 -0
- package/packages/app-core/src/config/branding.d.ts +55 -0
- package/packages/app-core/src/config/branding.d.ts.map +1 -0
- package/packages/app-core/src/config/branding.js +23 -0
- package/packages/app-core/src/config/config.d.ts +12 -0
- package/packages/app-core/src/config/config.d.ts.map +1 -0
- package/packages/app-core/src/config/config.js +23 -0
- package/packages/app-core/src/navigation/index.d.ts +52 -0
- package/packages/app-core/src/navigation/index.d.ts.map +1 -0
- package/packages/app-core/src/navigation/index.js +354 -0
- package/packages/app-core/src/state/action-notice.d.ts +7 -0
- package/packages/app-core/src/state/action-notice.d.ts.map +1 -0
- package/packages/app-core/src/state/action-notice.js +1 -0
- package/packages/app-core/src/types/index.d.ts +649 -0
- package/packages/app-core/src/types/index.d.ts.map +1 -0
- package/packages/app-core/src/types/index.js +1 -0
- package/packages/app-core/src/types/lifeops-ui.d.ts +10 -0
- package/packages/app-core/src/types/lifeops-ui.d.ts.map +1 -0
- package/packages/app-core/src/types/lifeops-ui.js +1 -0
- package/packages/app-core/src/utils/env.d.ts +31 -0
- package/packages/app-core/src/utils/env.d.ts.map +1 -0
- package/packages/app-core/src/utils/env.js +51 -0
- package/packages/app-core/src/utils/tts-debug.d.ts +9 -0
- package/packages/app-core/src/utils/tts-debug.d.ts.map +1 -0
- package/packages/app-core/src/utils/tts-debug.js +68 -0
- package/packages/shared/src/connectors.d.ts +13 -0
- package/packages/shared/src/connectors.d.ts.map +1 -0
- package/packages/shared/src/connectors.js +91 -0
- package/packages/shared/src/contracts/apps.d.ts +204 -0
- package/packages/shared/src/contracts/apps.d.ts.map +1 -0
- package/packages/shared/src/contracts/apps.js +188 -0
- package/packages/shared/src/contracts/awareness.d.ts +38 -0
- package/packages/shared/src/contracts/awareness.d.ts.map +1 -0
- package/packages/shared/src/contracts/awareness.js +7 -0
- package/packages/shared/src/contracts/cloud-topology.d.ts +13 -0
- package/packages/shared/src/contracts/cloud-topology.d.ts.map +1 -0
- package/packages/shared/src/contracts/cloud-topology.js +73 -0
- package/packages/shared/src/contracts/config.d.ts +146 -0
- package/packages/shared/src/contracts/config.d.ts.map +1 -0
- package/packages/shared/src/contracts/config.js +4 -0
- package/packages/shared/src/contracts/content-pack.d.ts +131 -0
- package/packages/shared/src/contracts/content-pack.d.ts.map +1 -0
- package/packages/shared/src/contracts/content-pack.js +102 -0
- package/packages/shared/src/contracts/drop.d.ts +20 -0
- package/packages/shared/src/contracts/drop.d.ts.map +1 -0
- package/packages/shared/src/contracts/drop.js +4 -0
- package/packages/shared/src/contracts/index.d.ts +13 -0
- package/packages/shared/src/contracts/index.d.ts.map +1 -0
- package/packages/shared/src/contracts/index.js +12 -0
- package/packages/shared/src/contracts/lifeops.d.ts +1337 -0
- package/packages/shared/src/contracts/lifeops.d.ts.map +1 -0
- package/packages/shared/src/contracts/lifeops.js +278 -0
- package/packages/shared/src/contracts/onboarding.d.ts +443 -0
- package/packages/shared/src/contracts/onboarding.d.ts.map +1 -0
- package/packages/shared/src/contracts/onboarding.js +1020 -0
- package/packages/shared/src/contracts/permissions.d.ts +38 -0
- package/packages/shared/src/contracts/permissions.d.ts.map +1 -0
- package/packages/shared/src/contracts/permissions.js +4 -0
- package/packages/shared/src/contracts/service-routing.d.ts +77 -0
- package/packages/shared/src/contracts/service-routing.d.ts.map +1 -0
- package/packages/shared/src/contracts/service-routing.js +227 -0
- package/packages/shared/src/contracts/theme.d.ts +136 -0
- package/packages/shared/src/contracts/theme.d.ts.map +1 -0
- package/packages/shared/src/contracts/theme.js +133 -0
- package/packages/shared/src/contracts/verification.d.ts +9 -0
- package/packages/shared/src/contracts/verification.d.ts.map +1 -0
- package/packages/shared/src/contracts/verification.js +4 -0
- package/packages/shared/src/contracts/wallet.d.ts +626 -0
- package/packages/shared/src/contracts/wallet.d.ts.map +1 -0
- package/packages/shared/src/contracts/wallet.js +60 -0
- package/packages/shared/src/env-utils.d.ts +5 -0
- package/packages/shared/src/env-utils.d.ts.map +1 -0
- package/packages/shared/src/env-utils.impl.d.ts +2 -0
- package/packages/shared/src/env-utils.impl.d.ts.map +1 -0
- package/packages/shared/src/env-utils.impl.js +16 -0
- package/packages/shared/src/env-utils.js +4 -0
- package/packages/shared/src/i18n/generated/validation-keyword-data.d.ts +1030 -0
- package/packages/shared/src/i18n/generated/validation-keyword-data.d.ts.map +1 -0
- package/packages/shared/src/i18n/generated/validation-keyword-data.js +1033 -0
- package/packages/shared/src/i18n/keyword-matching.d.ts +23 -0
- package/packages/shared/src/i18n/keyword-matching.d.ts.map +1 -0
- package/packages/shared/src/i18n/keyword-matching.js +112 -0
- package/packages/shared/src/i18n/validation-keywords.d.ts +13 -0
- package/packages/shared/src/i18n/validation-keywords.d.ts.map +1 -0
- package/packages/shared/src/i18n/validation-keywords.js +12 -0
- package/packages/shared/src/index.d.ts +13 -0
- package/packages/shared/src/index.d.ts.map +1 -0
- package/packages/shared/src/index.js +12 -0
- package/packages/shared/src/onboarding-presets.characters.d.ts +22 -0
- package/packages/shared/src/onboarding-presets.characters.d.ts.map +1 -0
- package/packages/shared/src/onboarding-presets.characters.js +2606 -0
- package/packages/shared/src/onboarding-presets.d.ts +40 -0
- package/packages/shared/src/onboarding-presets.d.ts.map +1 -0
- package/packages/shared/src/onboarding-presets.js +176 -0
- package/packages/shared/src/onboarding-presets.shared.d.ts +2 -0
- package/packages/shared/src/onboarding-presets.shared.d.ts.map +1 -0
- package/packages/shared/src/onboarding-presets.shared.js +7 -0
- package/packages/shared/src/restart.d.ts +27 -0
- package/packages/shared/src/restart.d.ts.map +1 -0
- package/packages/shared/src/restart.js +28 -0
- package/packages/shared/src/runtime-env.d.ts +82 -0
- package/packages/shared/src/runtime-env.d.ts.map +1 -0
- package/packages/shared/src/runtime-env.js +242 -0
- package/packages/shared/src/settings-debug.d.ts +20 -0
- package/packages/shared/src/settings-debug.d.ts.map +1 -0
- package/packages/shared/src/settings-debug.js +116 -0
- package/packages/shared/src/spoken-text.d.ts +2 -0
- package/packages/shared/src/spoken-text.d.ts.map +1 -0
- package/packages/shared/src/spoken-text.js +56 -0
- package/packages/shared/src/types.d.ts +27 -0
- package/packages/shared/src/types.d.ts.map +1 -0
- package/packages/shared/src/types.js +1 -0
- package/packages/shared/src/validation-keywords.d.ts +2 -0
- package/packages/shared/src/validation-keywords.d.ts.map +1 -0
- package/packages/shared/src/validation-keywords.js +1 -0
- package/packages/typescript/src/action-docs.d.ts +22 -0
- package/packages/typescript/src/action-docs.d.ts.map +1 -0
- package/packages/typescript/src/action-docs.js +93 -0
- package/packages/typescript/src/actions.d.ts +29 -0
- package/packages/typescript/src/actions.d.ts.map +1 -0
- package/packages/typescript/src/actions.js +456 -0
- package/packages/typescript/src/advanced-capabilities/clipboard/actions/append.d.ts +4 -0
- package/packages/typescript/src/advanced-capabilities/clipboard/actions/append.d.ts.map +1 -0
- package/packages/typescript/src/advanced-capabilities/clipboard/actions/append.js +150 -0
- package/packages/typescript/src/advanced-capabilities/clipboard/actions/delete.d.ts +4 -0
- package/packages/typescript/src/advanced-capabilities/clipboard/actions/delete.d.ts.map +1 -0
- package/packages/typescript/src/advanced-capabilities/clipboard/actions/delete.js +136 -0
- package/packages/typescript/src/advanced-capabilities/clipboard/actions/list.d.ts +4 -0
- package/packages/typescript/src/advanced-capabilities/clipboard/actions/list.d.ts.map +1 -0
- package/packages/typescript/src/advanced-capabilities/clipboard/actions/list.js +84 -0
- package/packages/typescript/src/advanced-capabilities/clipboard/actions/read-attachment.d.ts +4 -0
- package/packages/typescript/src/advanced-capabilities/clipboard/actions/read-attachment.d.ts.map +1 -0
- package/packages/typescript/src/advanced-capabilities/clipboard/actions/read-attachment.js +107 -0
- package/packages/typescript/src/advanced-capabilities/clipboard/actions/read-file.d.ts +16 -0
- package/packages/typescript/src/advanced-capabilities/clipboard/actions/read-file.d.ts.map +1 -0
- package/packages/typescript/src/advanced-capabilities/clipboard/actions/read-file.js +187 -0
- package/packages/typescript/src/advanced-capabilities/clipboard/actions/read.d.ts +4 -0
- package/packages/typescript/src/advanced-capabilities/clipboard/actions/read.d.ts.map +1 -0
- package/packages/typescript/src/advanced-capabilities/clipboard/actions/read.js +138 -0
- package/packages/typescript/src/advanced-capabilities/clipboard/actions/remove-from-clipboard.d.ts +4 -0
- package/packages/typescript/src/advanced-capabilities/clipboard/actions/remove-from-clipboard.d.ts.map +1 -0
- package/packages/typescript/src/advanced-capabilities/clipboard/actions/remove-from-clipboard.js +96 -0
- package/packages/typescript/src/advanced-capabilities/clipboard/actions/search.d.ts +4 -0
- package/packages/typescript/src/advanced-capabilities/clipboard/actions/search.d.ts.map +1 -0
- package/packages/typescript/src/advanced-capabilities/clipboard/actions/search.js +139 -0
- package/packages/typescript/src/advanced-capabilities/clipboard/actions/write.d.ts +4 -0
- package/packages/typescript/src/advanced-capabilities/clipboard/actions/write.d.ts.map +1 -0
- package/packages/typescript/src/advanced-capabilities/clipboard/actions/write.js +138 -0
- package/packages/typescript/src/advanced-capabilities/clipboard/index.d.ts +39 -0
- package/packages/typescript/src/advanced-capabilities/clipboard/index.d.ts.map +1 -0
- package/packages/typescript/src/advanced-capabilities/clipboard/index.js +78 -0
- package/packages/typescript/src/advanced-capabilities/clipboard/providers/clipboard.d.ts +4 -0
- package/packages/typescript/src/advanced-capabilities/clipboard/providers/clipboard.d.ts.map +1 -0
- package/packages/typescript/src/advanced-capabilities/clipboard/providers/clipboard.js +62 -0
- package/packages/typescript/src/advanced-capabilities/clipboard/services/attachmentContext.d.ts +16 -0
- package/packages/typescript/src/advanced-capabilities/clipboard/services/attachmentContext.d.ts.map +1 -0
- package/packages/typescript/src/advanced-capabilities/clipboard/services/attachmentContext.js +162 -0
- package/packages/typescript/src/advanced-capabilities/clipboard/services/clipboardService.d.ts +65 -0
- package/packages/typescript/src/advanced-capabilities/clipboard/services/clipboardService.d.ts.map +1 -0
- package/packages/typescript/src/advanced-capabilities/clipboard/services/clipboardService.js +352 -0
- package/packages/typescript/src/advanced-capabilities/clipboard/services/taskClipboardPersistence.d.ts +24 -0
- package/packages/typescript/src/advanced-capabilities/clipboard/services/taskClipboardPersistence.d.ts.map +1 -0
- package/packages/typescript/src/advanced-capabilities/clipboard/services/taskClipboardPersistence.js +63 -0
- package/packages/typescript/src/advanced-capabilities/clipboard/services/taskClipboardService.d.ts +29 -0
- package/packages/typescript/src/advanced-capabilities/clipboard/services/taskClipboardService.d.ts.map +1 -0
- package/packages/typescript/src/advanced-capabilities/clipboard/services/taskClipboardService.js +195 -0
- package/packages/typescript/src/advanced-capabilities/clipboard/specs.d.ts +15 -0
- package/packages/typescript/src/advanced-capabilities/clipboard/specs.d.ts.map +1 -0
- package/packages/typescript/src/advanced-capabilities/clipboard/specs.js +164 -0
- package/packages/typescript/src/advanced-capabilities/clipboard/types.d.ts +92 -0
- package/packages/typescript/src/advanced-capabilities/clipboard/types.d.ts.map +1 -0
- package/packages/typescript/src/advanced-capabilities/clipboard/types.js +4 -0
- package/packages/typescript/src/character-utils.d.ts +138 -0
- package/packages/typescript/src/character-utils.d.ts.map +1 -0
- package/packages/typescript/src/character-utils.js +271 -0
- package/packages/typescript/src/character.d.ts +68 -0
- package/packages/typescript/src/character.d.ts.map +1 -0
- package/packages/typescript/src/character.js +155 -0
- package/packages/typescript/src/connection.d.ts +45 -0
- package/packages/typescript/src/connection.d.ts.map +1 -0
- package/packages/typescript/src/connection.js +149 -0
- package/packages/typescript/src/constants/index.d.ts +7 -0
- package/packages/typescript/src/constants/index.d.ts.map +1 -0
- package/packages/typescript/src/constants/index.js +6 -0
- package/packages/typescript/src/constants/secrets.d.ts +99 -0
- package/packages/typescript/src/constants/secrets.d.ts.map +1 -0
- package/packages/typescript/src/constants/secrets.js +239 -0
- package/packages/typescript/src/database/inMemoryAdapter.d.ts +285 -0
- package/packages/typescript/src/database/inMemoryAdapter.d.ts.map +1 -0
- package/packages/typescript/src/database/inMemoryAdapter.js +1149 -0
- package/packages/typescript/src/database.d.ts +426 -0
- package/packages/typescript/src/database.d.ts.map +1 -0
- package/packages/typescript/src/database.js +24 -0
- package/packages/typescript/src/entities.d.ts +11 -0
- package/packages/typescript/src/entities.d.ts.map +1 -0
- package/packages/typescript/src/entities.js +437 -0
- package/packages/typescript/src/features/advanced-capabilities/actions/addContact.d.ts +3 -0
- package/packages/typescript/src/features/advanced-capabilities/actions/addContact.d.ts.map +1 -0
- package/packages/typescript/src/features/advanced-capabilities/actions/addContact.js +142 -0
- package/packages/typescript/src/features/advanced-capabilities/actions/followRoom.d.ts +3 -0
- package/packages/typescript/src/features/advanced-capabilities/actions/followRoom.d.ts.map +1 -0
- package/packages/typescript/src/features/advanced-capabilities/actions/followRoom.js +183 -0
- package/packages/typescript/src/features/advanced-capabilities/actions/imageGeneration.d.ts +3 -0
- package/packages/typescript/src/features/advanced-capabilities/actions/imageGeneration.d.ts.map +1 -0
- package/packages/typescript/src/features/advanced-capabilities/actions/imageGeneration.js +148 -0
- package/packages/typescript/src/features/advanced-capabilities/actions/index.d.ts +21 -0
- package/packages/typescript/src/features/advanced-capabilities/actions/index.d.ts.map +1 -0
- package/packages/typescript/src/features/advanced-capabilities/actions/index.js +20 -0
- package/packages/typescript/src/features/advanced-capabilities/actions/muteRoom.d.ts +3 -0
- package/packages/typescript/src/features/advanced-capabilities/actions/muteRoom.d.ts.map +1 -0
- package/packages/typescript/src/features/advanced-capabilities/actions/muteRoom.js +181 -0
- package/packages/typescript/src/features/advanced-capabilities/actions/removeContact.d.ts +3 -0
- package/packages/typescript/src/features/advanced-capabilities/actions/removeContact.d.ts.map +1 -0
- package/packages/typescript/src/features/advanced-capabilities/actions/removeContact.js +102 -0
- package/packages/typescript/src/features/advanced-capabilities/actions/roles.d.ts +13 -0
- package/packages/typescript/src/features/advanced-capabilities/actions/roles.d.ts.map +1 -0
- package/packages/typescript/src/features/advanced-capabilities/actions/roles.js +317 -0
- package/packages/typescript/src/features/advanced-capabilities/actions/scheduleFollowUp.d.ts +3 -0
- package/packages/typescript/src/features/advanced-capabilities/actions/scheduleFollowUp.d.ts.map +1 -0
- package/packages/typescript/src/features/advanced-capabilities/actions/scheduleFollowUp.js +129 -0
- package/packages/typescript/src/features/advanced-capabilities/actions/searchContacts.d.ts +3 -0
- package/packages/typescript/src/features/advanced-capabilities/actions/searchContacts.d.ts.map +1 -0
- package/packages/typescript/src/features/advanced-capabilities/actions/searchContacts.js +176 -0
- package/packages/typescript/src/features/advanced-capabilities/actions/sendMessage.d.ts +15 -0
- package/packages/typescript/src/features/advanced-capabilities/actions/sendMessage.d.ts.map +1 -0
- package/packages/typescript/src/features/advanced-capabilities/actions/sendMessage.js +476 -0
- package/packages/typescript/src/features/advanced-capabilities/actions/settings.d.ts +22 -0
- package/packages/typescript/src/features/advanced-capabilities/actions/settings.d.ts.map +1 -0
- package/packages/typescript/src/features/advanced-capabilities/actions/settings.js +823 -0
- package/packages/typescript/src/features/advanced-capabilities/actions/think.d.ts +3 -0
- package/packages/typescript/src/features/advanced-capabilities/actions/think.d.ts.map +1 -0
- package/packages/typescript/src/features/advanced-capabilities/actions/think.js +84 -0
- package/packages/typescript/src/features/advanced-capabilities/actions/unfollowRoom.d.ts +3 -0
- package/packages/typescript/src/features/advanced-capabilities/actions/unfollowRoom.d.ts.map +1 -0
- package/packages/typescript/src/features/advanced-capabilities/actions/unfollowRoom.js +134 -0
- package/packages/typescript/src/features/advanced-capabilities/actions/unmuteRoom.d.ts +3 -0
- package/packages/typescript/src/features/advanced-capabilities/actions/unmuteRoom.d.ts.map +1 -0
- package/packages/typescript/src/features/advanced-capabilities/actions/unmuteRoom.js +193 -0
- package/packages/typescript/src/features/advanced-capabilities/actions/updateContact.d.ts +3 -0
- package/packages/typescript/src/features/advanced-capabilities/actions/updateContact.d.ts.map +1 -0
- package/packages/typescript/src/features/advanced-capabilities/actions/updateContact.js +199 -0
- package/packages/typescript/src/features/advanced-capabilities/actions/updateEntity.d.ts +43 -0
- package/packages/typescript/src/features/advanced-capabilities/actions/updateEntity.d.ts.map +1 -0
- package/packages/typescript/src/features/advanced-capabilities/actions/updateEntity.js +372 -0
- package/packages/typescript/src/features/advanced-capabilities/clipboard/actions/append.d.ts +4 -0
- package/packages/typescript/src/features/advanced-capabilities/clipboard/actions/append.d.ts.map +1 -0
- package/packages/typescript/src/features/advanced-capabilities/clipboard/actions/append.js +150 -0
- package/packages/typescript/src/features/advanced-capabilities/clipboard/actions/delete.d.ts +4 -0
- package/packages/typescript/src/features/advanced-capabilities/clipboard/actions/delete.d.ts.map +1 -0
- package/packages/typescript/src/features/advanced-capabilities/clipboard/actions/delete.js +136 -0
- package/packages/typescript/src/features/advanced-capabilities/clipboard/actions/list.d.ts +4 -0
- package/packages/typescript/src/features/advanced-capabilities/clipboard/actions/list.d.ts.map +1 -0
- package/packages/typescript/src/features/advanced-capabilities/clipboard/actions/list.js +84 -0
- package/packages/typescript/src/features/advanced-capabilities/clipboard/actions/read-attachment.d.ts +4 -0
- package/packages/typescript/src/features/advanced-capabilities/clipboard/actions/read-attachment.d.ts.map +1 -0
- package/packages/typescript/src/features/advanced-capabilities/clipboard/actions/read-attachment.js +112 -0
- package/packages/typescript/src/features/advanced-capabilities/clipboard/actions/read-file.d.ts +16 -0
- package/packages/typescript/src/features/advanced-capabilities/clipboard/actions/read-file.d.ts.map +1 -0
- package/packages/typescript/src/features/advanced-capabilities/clipboard/actions/read-file.js +192 -0
- package/packages/typescript/src/features/advanced-capabilities/clipboard/actions/read.d.ts +4 -0
- package/packages/typescript/src/features/advanced-capabilities/clipboard/actions/read.d.ts.map +1 -0
- package/packages/typescript/src/features/advanced-capabilities/clipboard/actions/read.js +138 -0
- package/packages/typescript/src/features/advanced-capabilities/clipboard/actions/remove-from-clipboard.d.ts +4 -0
- package/packages/typescript/src/features/advanced-capabilities/clipboard/actions/remove-from-clipboard.d.ts.map +1 -0
- package/packages/typescript/src/features/advanced-capabilities/clipboard/actions/remove-from-clipboard.js +96 -0
- package/packages/typescript/src/features/advanced-capabilities/clipboard/actions/search.d.ts +4 -0
- package/packages/typescript/src/features/advanced-capabilities/clipboard/actions/search.d.ts.map +1 -0
- package/packages/typescript/src/features/advanced-capabilities/clipboard/actions/search.js +139 -0
- package/packages/typescript/src/features/advanced-capabilities/clipboard/actions/write.d.ts +4 -0
- package/packages/typescript/src/features/advanced-capabilities/clipboard/actions/write.d.ts.map +1 -0
- package/packages/typescript/src/features/advanced-capabilities/clipboard/actions/write.js +138 -0
- package/packages/typescript/src/features/advanced-capabilities/clipboard/index.d.ts +39 -0
- package/packages/typescript/src/features/advanced-capabilities/clipboard/index.d.ts.map +1 -0
- package/packages/typescript/src/features/advanced-capabilities/clipboard/index.js +78 -0
- package/packages/typescript/src/features/advanced-capabilities/clipboard/providers/clipboard.d.ts +4 -0
- package/packages/typescript/src/features/advanced-capabilities/clipboard/providers/clipboard.d.ts.map +1 -0
- package/packages/typescript/src/features/advanced-capabilities/clipboard/providers/clipboard.js +62 -0
- package/packages/typescript/src/features/advanced-capabilities/clipboard/services/attachmentContext.d.ts +16 -0
- package/packages/typescript/src/features/advanced-capabilities/clipboard/services/attachmentContext.d.ts.map +1 -0
- package/packages/typescript/src/features/advanced-capabilities/clipboard/services/attachmentContext.js +162 -0
- package/packages/typescript/src/features/advanced-capabilities/clipboard/services/clipboardService.d.ts +65 -0
- package/packages/typescript/src/features/advanced-capabilities/clipboard/services/clipboardService.d.ts.map +1 -0
- package/packages/typescript/src/features/advanced-capabilities/clipboard/services/clipboardService.js +352 -0
- package/packages/typescript/src/features/advanced-capabilities/clipboard/services/taskClipboardPersistence.d.ts +24 -0
- package/packages/typescript/src/features/advanced-capabilities/clipboard/services/taskClipboardPersistence.d.ts.map +1 -0
- package/packages/typescript/src/features/advanced-capabilities/clipboard/services/taskClipboardPersistence.js +63 -0
- package/packages/typescript/src/features/advanced-capabilities/clipboard/services/taskClipboardService.d.ts +29 -0
- package/packages/typescript/src/features/advanced-capabilities/clipboard/services/taskClipboardService.d.ts.map +1 -0
- package/packages/typescript/src/features/advanced-capabilities/clipboard/services/taskClipboardService.js +195 -0
- package/packages/typescript/src/features/advanced-capabilities/clipboard/specs.d.ts +15 -0
- package/packages/typescript/src/features/advanced-capabilities/clipboard/specs.d.ts.map +1 -0
- package/packages/typescript/src/features/advanced-capabilities/clipboard/specs.js +164 -0
- package/packages/typescript/src/features/advanced-capabilities/clipboard/types.d.ts +92 -0
- package/packages/typescript/src/features/advanced-capabilities/clipboard/types.d.ts.map +1 -0
- package/packages/typescript/src/features/advanced-capabilities/clipboard/types.js +4 -0
- package/packages/typescript/src/features/advanced-capabilities/evaluators/index.d.ts +8 -0
- package/packages/typescript/src/features/advanced-capabilities/evaluators/index.d.ts.map +1 -0
- package/packages/typescript/src/features/advanced-capabilities/evaluators/index.js +7 -0
- package/packages/typescript/src/features/advanced-capabilities/evaluators/reflection.d.ts +3 -0
- package/packages/typescript/src/features/advanced-capabilities/evaluators/reflection.d.ts.map +1 -0
- package/packages/typescript/src/features/advanced-capabilities/evaluators/reflection.js +633 -0
- package/packages/typescript/src/features/advanced-capabilities/evaluators/relationshipExtraction.d.ts +3 -0
- package/packages/typescript/src/features/advanced-capabilities/evaluators/relationshipExtraction.d.ts.map +1 -0
- package/packages/typescript/src/features/advanced-capabilities/evaluators/relationshipExtraction.js +619 -0
- package/packages/typescript/src/features/advanced-capabilities/evaluators/task-completion.d.ts +12 -0
- package/packages/typescript/src/features/advanced-capabilities/evaluators/task-completion.d.ts.map +1 -0
- package/packages/typescript/src/features/advanced-capabilities/evaluators/task-completion.js +14 -0
- package/packages/typescript/src/features/advanced-capabilities/experience/actions/record-experience.d.ts +3 -0
- package/packages/typescript/src/features/advanced-capabilities/experience/actions/record-experience.d.ts.map +1 -0
- package/packages/typescript/src/features/advanced-capabilities/experience/actions/record-experience.js +70 -0
- package/packages/typescript/src/features/advanced-capabilities/experience/evaluators/experienceEvaluator.d.ts +3 -0
- package/packages/typescript/src/features/advanced-capabilities/experience/evaluators/experienceEvaluator.d.ts.map +1 -0
- package/packages/typescript/src/features/advanced-capabilities/experience/evaluators/experienceEvaluator.js +256 -0
- package/packages/typescript/src/features/advanced-capabilities/experience/generated/prompts/typescript/prompts.d.ts +12 -0
- package/packages/typescript/src/features/advanced-capabilities/experience/generated/prompts/typescript/prompts.d.ts.map +1 -0
- package/packages/typescript/src/features/advanced-capabilities/experience/generated/prompts/typescript/prompts.js +41 -0
- package/packages/typescript/src/features/advanced-capabilities/experience/generated/specs/spec-helpers.d.ts +49 -0
- package/packages/typescript/src/features/advanced-capabilities/experience/generated/specs/spec-helpers.d.ts.map +1 -0
- package/packages/typescript/src/features/advanced-capabilities/experience/generated/specs/spec-helpers.js +78 -0
- package/packages/typescript/src/features/advanced-capabilities/experience/generated/specs/specs.d.ts +159 -0
- package/packages/typescript/src/features/advanced-capabilities/experience/generated/specs/specs.d.ts.map +1 -0
- package/packages/typescript/src/features/advanced-capabilities/experience/generated/specs/specs.js +192 -0
- package/packages/typescript/src/features/advanced-capabilities/experience/index.d.ts +10 -0
- package/packages/typescript/src/features/advanced-capabilities/experience/index.d.ts.map +1 -0
- package/packages/typescript/src/features/advanced-capabilities/experience/index.js +8 -0
- package/packages/typescript/src/features/advanced-capabilities/experience/providers/experienceProvider.d.ts +3 -0
- package/packages/typescript/src/features/advanced-capabilities/experience/providers/experienceProvider.d.ts.map +1 -0
- package/packages/typescript/src/features/advanced-capabilities/experience/providers/experienceProvider.js +51 -0
- package/packages/typescript/src/features/advanced-capabilities/experience/service.d.ts +46 -0
- package/packages/typescript/src/features/advanced-capabilities/experience/service.d.ts.map +1 -0
- package/packages/typescript/src/features/advanced-capabilities/experience/service.js +569 -0
- package/packages/typescript/src/features/advanced-capabilities/experience/types.d.ts +95 -0
- package/packages/typescript/src/features/advanced-capabilities/experience/types.d.ts.map +1 -0
- package/packages/typescript/src/features/advanced-capabilities/experience/types.js +22 -0
- package/packages/typescript/src/features/advanced-capabilities/experience/utils/confidenceDecay.d.ts +34 -0
- package/packages/typescript/src/features/advanced-capabilities/experience/utils/confidenceDecay.d.ts.map +1 -0
- package/packages/typescript/src/features/advanced-capabilities/experience/utils/confidenceDecay.js +106 -0
- package/packages/typescript/src/features/advanced-capabilities/experience/utils/experienceRelationships.d.ts +25 -0
- package/packages/typescript/src/features/advanced-capabilities/experience/utils/experienceRelationships.d.ts.map +1 -0
- package/packages/typescript/src/features/advanced-capabilities/experience/utils/experienceRelationships.js +116 -0
- package/packages/typescript/src/features/advanced-capabilities/form/actions/restore.d.ts +13 -0
- package/packages/typescript/src/features/advanced-capabilities/form/actions/restore.d.ts.map +1 -0
- package/packages/typescript/src/features/advanced-capabilities/form/actions/restore.js +152 -0
- package/packages/typescript/src/features/advanced-capabilities/form/builder.d.ts +101 -0
- package/packages/typescript/src/features/advanced-capabilities/form/builder.d.ts.map +1 -0
- package/packages/typescript/src/features/advanced-capabilities/form/builder.js +362 -0
- package/packages/typescript/src/features/advanced-capabilities/form/builtins.d.ts +16 -0
- package/packages/typescript/src/features/advanced-capabilities/form/builtins.d.ts.map +1 -0
- package/packages/typescript/src/features/advanced-capabilities/form/builtins.js +245 -0
- package/packages/typescript/src/features/advanced-capabilities/form/defaults.d.ts +32 -0
- package/packages/typescript/src/features/advanced-capabilities/form/defaults.d.ts.map +1 -0
- package/packages/typescript/src/features/advanced-capabilities/form/defaults.js +98 -0
- package/packages/typescript/src/features/advanced-capabilities/form/evaluators/extractor.d.ts +12 -0
- package/packages/typescript/src/features/advanced-capabilities/form/evaluators/extractor.d.ts.map +1 -0
- package/packages/typescript/src/features/advanced-capabilities/form/evaluators/extractor.js +231 -0
- package/packages/typescript/src/features/advanced-capabilities/form/extraction.d.ts +24 -0
- package/packages/typescript/src/features/advanced-capabilities/form/extraction.d.ts.map +1 -0
- package/packages/typescript/src/features/advanced-capabilities/form/extraction.js +319 -0
- package/packages/typescript/src/features/advanced-capabilities/form/index.d.ts +22 -0
- package/packages/typescript/src/features/advanced-capabilities/form/index.d.ts.map +1 -0
- package/packages/typescript/src/features/advanced-capabilities/form/index.js +52 -0
- package/packages/typescript/src/features/advanced-capabilities/form/intent.d.ts +41 -0
- package/packages/typescript/src/features/advanced-capabilities/form/intent.d.ts.map +1 -0
- package/packages/typescript/src/features/advanced-capabilities/form/intent.js +119 -0
- package/packages/typescript/src/features/advanced-capabilities/form/providers/context.d.ts +11 -0
- package/packages/typescript/src/features/advanced-capabilities/form/providers/context.d.ts.map +1 -0
- package/packages/typescript/src/features/advanced-capabilities/form/providers/context.js +166 -0
- package/packages/typescript/src/features/advanced-capabilities/form/service.d.ts +70 -0
- package/packages/typescript/src/features/advanced-capabilities/form/service.d.ts.map +1 -0
- package/packages/typescript/src/features/advanced-capabilities/form/service.js +924 -0
- package/packages/typescript/src/features/advanced-capabilities/form/storage.d.ts +26 -0
- package/packages/typescript/src/features/advanced-capabilities/form/storage.d.ts.map +1 -0
- package/packages/typescript/src/features/advanced-capabilities/form/storage.js +228 -0
- package/packages/typescript/src/features/advanced-capabilities/form/template.d.ts +10 -0
- package/packages/typescript/src/features/advanced-capabilities/form/template.d.ts.map +1 -0
- package/packages/typescript/src/features/advanced-capabilities/form/template.js +56 -0
- package/packages/typescript/src/features/advanced-capabilities/form/ttl.d.ts +40 -0
- package/packages/typescript/src/features/advanced-capabilities/form/ttl.d.ts.map +1 -0
- package/packages/typescript/src/features/advanced-capabilities/form/ttl.js +107 -0
- package/packages/typescript/src/features/advanced-capabilities/form/types.d.ts +588 -0
- package/packages/typescript/src/features/advanced-capabilities/form/types.d.ts.map +1 -0
- package/packages/typescript/src/features/advanced-capabilities/form/types.js +71 -0
- package/packages/typescript/src/features/advanced-capabilities/form/validation.d.ts +24 -0
- package/packages/typescript/src/features/advanced-capabilities/form/validation.d.ts.map +1 -0
- package/packages/typescript/src/features/advanced-capabilities/form/validation.js +311 -0
- package/packages/typescript/src/features/advanced-capabilities/index.d.ts +47 -0
- package/packages/typescript/src/features/advanced-capabilities/index.d.ts.map +1 -0
- package/packages/typescript/src/features/advanced-capabilities/index.js +114 -0
- package/packages/typescript/src/features/advanced-capabilities/personality/actions/modify-character.d.ts +7 -0
- package/packages/typescript/src/features/advanced-capabilities/personality/actions/modify-character.d.ts.map +1 -0
- package/packages/typescript/src/features/advanced-capabilities/personality/actions/modify-character.js +1299 -0
- package/packages/typescript/src/features/advanced-capabilities/personality/evaluators/character-evolution.d.ts +53 -0
- package/packages/typescript/src/features/advanced-capabilities/personality/evaluators/character-evolution.d.ts.map +1 -0
- package/packages/typescript/src/features/advanced-capabilities/personality/evaluators/character-evolution.js +429 -0
- package/packages/typescript/src/features/advanced-capabilities/personality/index.d.ts +10 -0
- package/packages/typescript/src/features/advanced-capabilities/personality/index.d.ts.map +1 -0
- package/packages/typescript/src/features/advanced-capabilities/personality/index.js +8 -0
- package/packages/typescript/src/features/advanced-capabilities/personality/providers/user-personality.d.ts +8 -0
- package/packages/typescript/src/features/advanced-capabilities/personality/providers/user-personality.d.ts.map +1 -0
- package/packages/typescript/src/features/advanced-capabilities/personality/providers/user-personality.js +57 -0
- package/packages/typescript/src/features/advanced-capabilities/personality/services/character-file-manager.d.ts +71 -0
- package/packages/typescript/src/features/advanced-capabilities/personality/services/character-file-manager.d.ts.map +1 -0
- package/packages/typescript/src/features/advanced-capabilities/personality/services/character-file-manager.js +498 -0
- package/packages/typescript/src/features/advanced-capabilities/personality/types.d.ts +18 -0
- package/packages/typescript/src/features/advanced-capabilities/personality/types.d.ts.map +1 -0
- package/packages/typescript/src/features/advanced-capabilities/personality/types.js +8 -0
- package/packages/typescript/src/features/advanced-capabilities/providers/contacts.d.ts +3 -0
- package/packages/typescript/src/features/advanced-capabilities/providers/contacts.d.ts.map +1 -0
- package/packages/typescript/src/features/advanced-capabilities/providers/contacts.js +77 -0
- package/packages/typescript/src/features/advanced-capabilities/providers/facts.d.ts +11 -0
- package/packages/typescript/src/features/advanced-capabilities/providers/facts.d.ts.map +1 -0
- package/packages/typescript/src/features/advanced-capabilities/providers/facts.js +108 -0
- package/packages/typescript/src/features/advanced-capabilities/providers/followUps.d.ts +3 -0
- package/packages/typescript/src/features/advanced-capabilities/providers/followUps.d.ts.map +1 -0
- package/packages/typescript/src/features/advanced-capabilities/providers/followUps.js +112 -0
- package/packages/typescript/src/features/advanced-capabilities/providers/index.d.ts +13 -0
- package/packages/typescript/src/features/advanced-capabilities/providers/index.d.ts.map +1 -0
- package/packages/typescript/src/features/advanced-capabilities/providers/index.js +12 -0
- package/packages/typescript/src/features/advanced-capabilities/providers/knowledge.d.ts +9 -0
- package/packages/typescript/src/features/advanced-capabilities/providers/knowledge.d.ts.map +1 -0
- package/packages/typescript/src/features/advanced-capabilities/providers/knowledge.js +83 -0
- package/packages/typescript/src/features/advanced-capabilities/providers/relationships.d.ts +15 -0
- package/packages/typescript/src/features/advanced-capabilities/providers/relationships.d.ts.map +1 -0
- package/packages/typescript/src/features/advanced-capabilities/providers/relationships.js +125 -0
- package/packages/typescript/src/features/advanced-capabilities/providers/roles.d.ts +19 -0
- package/packages/typescript/src/features/advanced-capabilities/providers/roles.d.ts.map +1 -0
- package/packages/typescript/src/features/advanced-capabilities/providers/roles.js +180 -0
- package/packages/typescript/src/features/advanced-capabilities/providers/settings.d.ts +7 -0
- package/packages/typescript/src/features/advanced-capabilities/providers/settings.d.ts.map +1 -0
- package/packages/typescript/src/features/advanced-capabilities/providers/settings.js +286 -0
- package/packages/typescript/src/features/advanced-memory/evaluators/index.d.ts +3 -0
- package/packages/typescript/src/features/advanced-memory/evaluators/index.d.ts.map +1 -0
- package/packages/typescript/src/features/advanced-memory/evaluators/index.js +2 -0
- package/packages/typescript/src/features/advanced-memory/evaluators/long-term-extraction.d.ts +3 -0
- package/packages/typescript/src/features/advanced-memory/evaluators/long-term-extraction.d.ts.map +1 -0
- package/packages/typescript/src/features/advanced-memory/evaluators/long-term-extraction.js +198 -0
- package/packages/typescript/src/features/advanced-memory/evaluators/summarization.d.ts +3 -0
- package/packages/typescript/src/features/advanced-memory/evaluators/summarization.d.ts.map +1 -0
- package/packages/typescript/src/features/advanced-memory/evaluators/summarization.js +240 -0
- package/packages/typescript/src/features/advanced-memory/index.d.ts +16 -0
- package/packages/typescript/src/features/advanced-memory/index.d.ts.map +1 -0
- package/packages/typescript/src/features/advanced-memory/index.js +26 -0
- package/packages/typescript/src/features/advanced-memory/prompts.d.ts +2 -0
- package/packages/typescript/src/features/advanced-memory/prompts.d.ts.map +1 -0
- package/packages/typescript/src/features/advanced-memory/prompts.js +1 -0
- package/packages/typescript/src/features/advanced-memory/providers/context-summary.d.ts +3 -0
- package/packages/typescript/src/features/advanced-memory/providers/context-summary.d.ts.map +1 -0
- package/packages/typescript/src/features/advanced-memory/providers/context-summary.js +85 -0
- package/packages/typescript/src/features/advanced-memory/providers/index.d.ts +3 -0
- package/packages/typescript/src/features/advanced-memory/providers/index.d.ts.map +1 -0
- package/packages/typescript/src/features/advanced-memory/providers/index.js +2 -0
- package/packages/typescript/src/features/advanced-memory/providers/long-term-memory.d.ts +3 -0
- package/packages/typescript/src/features/advanced-memory/providers/long-term-memory.d.ts.map +1 -0
- package/packages/typescript/src/features/advanced-memory/providers/long-term-memory.js +92 -0
- package/packages/typescript/src/features/advanced-memory/schemas/index.d.ts +5 -0
- package/packages/typescript/src/features/advanced-memory/schemas/index.d.ts.map +1 -0
- package/packages/typescript/src/features/advanced-memory/schemas/index.js +3 -0
- package/packages/typescript/src/features/advanced-memory/schemas/long-term-memories.d.ts +10 -0
- package/packages/typescript/src/features/advanced-memory/schemas/long-term-memories.d.ts.map +1 -0
- package/packages/typescript/src/features/advanced-memory/schemas/long-term-memories.js +65 -0
- package/packages/typescript/src/features/advanced-memory/schemas/memory-access-logs.d.ts +10 -0
- package/packages/typescript/src/features/advanced-memory/schemas/memory-access-logs.d.ts.map +1 -0
- package/packages/typescript/src/features/advanced-memory/schemas/memory-access-logs.js +45 -0
- package/packages/typescript/src/features/advanced-memory/schemas/session-summaries.d.ts +10 -0
- package/packages/typescript/src/features/advanced-memory/schemas/session-summaries.d.ts.map +1 -0
- package/packages/typescript/src/features/advanced-memory/schemas/session-summaries.js +66 -0
- package/packages/typescript/src/features/advanced-memory/services/memory-service.d.ts +37 -0
- package/packages/typescript/src/features/advanced-memory/services/memory-service.d.ts.map +1 -0
- package/packages/typescript/src/features/advanced-memory/services/memory-service.js +347 -0
- package/packages/typescript/src/features/advanced-memory/trajectory.d.ts +10 -0
- package/packages/typescript/src/features/advanced-memory/trajectory.d.ts.map +1 -0
- package/packages/typescript/src/features/advanced-memory/trajectory.js +33 -0
- package/packages/typescript/src/features/advanced-memory/types.d.ts +68 -0
- package/packages/typescript/src/features/advanced-memory/types.d.ts.map +1 -0
- package/packages/typescript/src/features/advanced-memory/types.js +6 -0
- package/packages/typescript/src/features/advanced-planning/actions/chain-example.d.ts +6 -0
- package/packages/typescript/src/features/advanced-planning/actions/chain-example.d.ts.map +1 -0
- package/packages/typescript/src/features/advanced-planning/actions/chain-example.js +181 -0
- package/packages/typescript/src/features/advanced-planning/index.d.ts +5 -0
- package/packages/typescript/src/features/advanced-planning/index.d.ts.map +1 -0
- package/packages/typescript/src/features/advanced-planning/index.js +20 -0
- package/packages/typescript/src/features/advanced-planning/providers/message-classifier.d.ts +3 -0
- package/packages/typescript/src/features/advanced-planning/providers/message-classifier.d.ts.map +1 -0
- package/packages/typescript/src/features/advanced-planning/providers/message-classifier.js +105 -0
- package/packages/typescript/src/features/advanced-planning/services/planning-service.d.ts +77 -0
- package/packages/typescript/src/features/advanced-planning/services/planning-service.d.ts.map +1 -0
- package/packages/typescript/src/features/advanced-planning/services/planning-service.js +875 -0
- package/packages/typescript/src/features/advanced-planning/types.d.ts +78 -0
- package/packages/typescript/src/features/advanced-planning/types.d.ts.map +1 -0
- package/packages/typescript/src/features/advanced-planning/types.js +1 -0
- package/packages/typescript/src/features/autonomy/action.d.ts +14 -0
- package/packages/typescript/src/features/autonomy/action.d.ts.map +1 -0
- package/packages/typescript/src/features/autonomy/action.js +177 -0
- package/packages/typescript/src/features/autonomy/execution-facade.d.ts +22 -0
- package/packages/typescript/src/features/autonomy/execution-facade.d.ts.map +1 -0
- package/packages/typescript/src/features/autonomy/execution-facade.js +132 -0
- package/packages/typescript/src/features/autonomy/index.d.ts +11 -0
- package/packages/typescript/src/features/autonomy/index.d.ts.map +1 -0
- package/packages/typescript/src/features/autonomy/index.js +13 -0
- package/packages/typescript/src/features/autonomy/providers.d.ts +21 -0
- package/packages/typescript/src/features/autonomy/providers.d.ts.map +1 -0
- package/packages/typescript/src/features/autonomy/providers.js +154 -0
- package/packages/typescript/src/features/autonomy/routes.d.ts +11 -0
- package/packages/typescript/src/features/autonomy/routes.d.ts.map +1 -0
- package/packages/typescript/src/features/autonomy/routes.js +158 -0
- package/packages/typescript/src/features/autonomy/service.d.ts +138 -0
- package/packages/typescript/src/features/autonomy/service.d.ts.map +1 -0
- package/packages/typescript/src/features/autonomy/service.js +813 -0
- package/packages/typescript/src/features/autonomy/types.d.ts +31 -0
- package/packages/typescript/src/features/autonomy/types.d.ts.map +1 -0
- package/packages/typescript/src/features/autonomy/types.js +6 -0
- package/packages/typescript/src/features/basic-capabilities/actions/choice.d.ts +4 -0
- package/packages/typescript/src/features/basic-capabilities/actions/choice.d.ts.map +1 -0
- package/packages/typescript/src/features/basic-capabilities/actions/choice.js +278 -0
- package/packages/typescript/src/features/basic-capabilities/actions/ignore.d.ts +3 -0
- package/packages/typescript/src/features/basic-capabilities/actions/ignore.d.ts.map +1 -0
- package/packages/typescript/src/features/basic-capabilities/actions/ignore.js +23 -0
- package/packages/typescript/src/features/basic-capabilities/actions/index.d.ts +10 -0
- package/packages/typescript/src/features/basic-capabilities/actions/index.d.ts.map +1 -0
- package/packages/typescript/src/features/basic-capabilities/actions/index.js +9 -0
- package/packages/typescript/src/features/basic-capabilities/actions/none.d.ts +3 -0
- package/packages/typescript/src/features/basic-capabilities/actions/none.d.ts.map +1 -0
- package/packages/typescript/src/features/basic-capabilities/actions/none.js +26 -0
- package/packages/typescript/src/features/basic-capabilities/actions/reply.d.ts +3 -0
- package/packages/typescript/src/features/basic-capabilities/actions/reply.d.ts.map +1 -0
- package/packages/typescript/src/features/basic-capabilities/actions/reply.js +80 -0
- package/packages/typescript/src/features/basic-capabilities/index.d.ts +108 -0
- package/packages/typescript/src/features/basic-capabilities/index.d.ts.map +1 -0
- package/packages/typescript/src/features/basic-capabilities/index.js +1020 -0
- package/packages/typescript/src/features/basic-capabilities/providers/actionState.d.ts +7 -0
- package/packages/typescript/src/features/basic-capabilities/providers/actionState.d.ts.map +1 -0
- package/packages/typescript/src/features/basic-capabilities/providers/actionState.js +232 -0
- package/packages/typescript/src/features/basic-capabilities/providers/actions.d.ts +35 -0
- package/packages/typescript/src/features/basic-capabilities/providers/actions.d.ts.map +1 -0
- package/packages/typescript/src/features/basic-capabilities/providers/actions.js +82 -0
- package/packages/typescript/src/features/basic-capabilities/providers/attachments.d.ts +20 -0
- package/packages/typescript/src/features/basic-capabilities/providers/attachments.d.ts.map +1 -0
- package/packages/typescript/src/features/basic-capabilities/providers/attachments.js +94 -0
- package/packages/typescript/src/features/basic-capabilities/providers/character.d.ts +17 -0
- package/packages/typescript/src/features/basic-capabilities/providers/character.d.ts.map +1 -0
- package/packages/typescript/src/features/basic-capabilities/providers/character.js +190 -0
- package/packages/typescript/src/features/basic-capabilities/providers/choice.d.ts +11 -0
- package/packages/typescript/src/features/basic-capabilities/providers/choice.d.ts.map +1 -0
- package/packages/typescript/src/features/basic-capabilities/providers/choice.js +86 -0
- package/packages/typescript/src/features/basic-capabilities/providers/contextBench.d.ts +12 -0
- package/packages/typescript/src/features/basic-capabilities/providers/contextBench.d.ts.map +1 -0
- package/packages/typescript/src/features/basic-capabilities/providers/contextBench.js +50 -0
- package/packages/typescript/src/features/basic-capabilities/providers/currentTime.d.ts +11 -0
- package/packages/typescript/src/features/basic-capabilities/providers/currentTime.d.ts.map +1 -0
- package/packages/typescript/src/features/basic-capabilities/providers/currentTime.js +56 -0
- package/packages/typescript/src/features/basic-capabilities/providers/entities.d.ts +7 -0
- package/packages/typescript/src/features/basic-capabilities/providers/entities.d.ts.map +1 -0
- package/packages/typescript/src/features/basic-capabilities/providers/entities.js +39 -0
- package/packages/typescript/src/features/basic-capabilities/providers/evaluators.d.ts +27 -0
- package/packages/typescript/src/features/basic-capabilities/providers/evaluators.d.ts.map +1 -0
- package/packages/typescript/src/features/basic-capabilities/providers/evaluators.js +107 -0
- package/packages/typescript/src/features/basic-capabilities/providers/index.d.ts +19 -0
- package/packages/typescript/src/features/basic-capabilities/providers/index.d.ts.map +1 -0
- package/packages/typescript/src/features/basic-capabilities/providers/index.js +18 -0
- package/packages/typescript/src/features/basic-capabilities/providers/providers.d.ts +18 -0
- package/packages/typescript/src/features/basic-capabilities/providers/providers.d.ts.map +1 -0
- package/packages/typescript/src/features/basic-capabilities/providers/providers.js +70 -0
- package/packages/typescript/src/features/basic-capabilities/providers/recentMessages.d.ts +14 -0
- package/packages/typescript/src/features/basic-capabilities/providers/recentMessages.d.ts.map +1 -0
- package/packages/typescript/src/features/basic-capabilities/providers/recentMessages.js +323 -0
- package/packages/typescript/src/features/basic-capabilities/providers/time.d.ts +12 -0
- package/packages/typescript/src/features/basic-capabilities/providers/time.d.ts.map +1 -0
- package/packages/typescript/src/features/basic-capabilities/providers/time.js +36 -0
- package/packages/typescript/src/features/basic-capabilities/providers/world.d.ts +8 -0
- package/packages/typescript/src/features/basic-capabilities/providers/world.d.ts.map +1 -0
- package/packages/typescript/src/features/basic-capabilities/providers/world.js +212 -0
- package/packages/typescript/src/features/index.d.ts +58 -0
- package/packages/typescript/src/features/index.d.ts.map +1 -0
- package/packages/typescript/src/features/index.js +155 -0
- package/packages/typescript/src/features/knowledge/actions.d.ts +5 -0
- package/packages/typescript/src/features/knowledge/actions.d.ts.map +1 -0
- package/packages/typescript/src/features/knowledge/actions.js +269 -0
- package/packages/typescript/src/features/knowledge/config.d.ts +5 -0
- package/packages/typescript/src/features/knowledge/config.d.ts.map +1 -0
- package/packages/typescript/src/features/knowledge/config.js +147 -0
- package/packages/typescript/src/features/knowledge/ctx-embeddings.d.ts +53 -0
- package/packages/typescript/src/features/knowledge/ctx-embeddings.d.ts.map +1 -0
- package/packages/typescript/src/features/knowledge/ctx-embeddings.js +412 -0
- package/packages/typescript/src/features/knowledge/docs-loader.d.ts +9 -0
- package/packages/typescript/src/features/knowledge/docs-loader.d.ts.map +1 -0
- package/packages/typescript/src/features/knowledge/docs-loader.js +202 -0
- package/packages/typescript/src/features/knowledge/document-processor.d.ts +26 -0
- package/packages/typescript/src/features/knowledge/document-processor.d.ts.map +1 -0
- package/packages/typescript/src/features/knowledge/document-processor.js +618 -0
- package/packages/typescript/src/features/knowledge/documents-provider.d.ts +3 -0
- package/packages/typescript/src/features/knowledge/documents-provider.d.ts.map +1 -0
- package/packages/typescript/src/features/knowledge/documents-provider.js +106 -0
- package/packages/typescript/src/features/knowledge/index.d.ts +16 -0
- package/packages/typescript/src/features/knowledge/index.d.ts.map +1 -0
- package/packages/typescript/src/features/knowledge/index.js +29 -0
- package/packages/typescript/src/features/knowledge/llm.d.ts +27 -0
- package/packages/typescript/src/features/knowledge/llm.d.ts.map +1 -0
- package/packages/typescript/src/features/knowledge/llm.js +444 -0
- package/packages/typescript/src/features/knowledge/provider.d.ts +3 -0
- package/packages/typescript/src/features/knowledge/provider.d.ts.map +1 -0
- package/packages/typescript/src/features/knowledge/provider.js +62 -0
- package/packages/typescript/src/features/knowledge/service.d.ts +76 -0
- package/packages/typescript/src/features/knowledge/service.d.ts.map +1 -0
- package/packages/typescript/src/features/knowledge/service.js +511 -0
- package/packages/typescript/src/features/knowledge/types.d.ts +144 -0
- package/packages/typescript/src/features/knowledge/types.d.ts.map +1 -0
- package/packages/typescript/src/features/knowledge/types.js +57 -0
- package/packages/typescript/src/features/knowledge/utils.d.ts +17 -0
- package/packages/typescript/src/features/knowledge/utils.d.ts.map +1 -0
- package/packages/typescript/src/features/knowledge/utils.js +313 -0
- package/packages/typescript/src/features/orchestrator/actions/coding-task-handlers.d.ts +41 -0
- package/packages/typescript/src/features/orchestrator/actions/coding-task-handlers.d.ts.map +1 -0
- package/packages/typescript/src/features/orchestrator/actions/coding-task-handlers.js +443 -0
- package/packages/typescript/src/features/orchestrator/actions/coding-task-helpers.d.ts +34 -0
- package/packages/typescript/src/features/orchestrator/actions/coding-task-helpers.d.ts.map +1 -0
- package/packages/typescript/src/features/orchestrator/actions/coding-task-helpers.js +171 -0
- package/packages/typescript/src/features/orchestrator/actions/eval-metadata.d.ts +11 -0
- package/packages/typescript/src/features/orchestrator/actions/eval-metadata.d.ts.map +1 -0
- package/packages/typescript/src/features/orchestrator/actions/eval-metadata.js +55 -0
- package/packages/typescript/src/features/orchestrator/actions/finalize-workspace.d.ts +11 -0
- package/packages/typescript/src/features/orchestrator/actions/finalize-workspace.d.ts.map +1 -0
- package/packages/typescript/src/features/orchestrator/actions/finalize-workspace.js +214 -0
- package/packages/typescript/src/features/orchestrator/actions/list-agents.d.ts +13 -0
- package/packages/typescript/src/features/orchestrator/actions/list-agents.d.ts.map +1 -0
- package/packages/typescript/src/features/orchestrator/actions/list-agents.js +174 -0
- package/packages/typescript/src/features/orchestrator/actions/manage-issues.d.ts +11 -0
- package/packages/typescript/src/features/orchestrator/actions/manage-issues.d.ts.map +1 -0
- package/packages/typescript/src/features/orchestrator/actions/manage-issues.js +428 -0
- package/packages/typescript/src/features/orchestrator/actions/provision-workspace.d.ts +11 -0
- package/packages/typescript/src/features/orchestrator/actions/provision-workspace.d.ts.map +1 -0
- package/packages/typescript/src/features/orchestrator/actions/provision-workspace.js +189 -0
- package/packages/typescript/src/features/orchestrator/actions/send-to-agent.d.ts +12 -0
- package/packages/typescript/src/features/orchestrator/actions/send-to-agent.d.ts.map +1 -0
- package/packages/typescript/src/features/orchestrator/actions/send-to-agent.js +265 -0
- package/packages/typescript/src/features/orchestrator/actions/spawn-agent.d.ts +12 -0
- package/packages/typescript/src/features/orchestrator/actions/spawn-agent.d.ts.map +1 -0
- package/packages/typescript/src/features/orchestrator/actions/spawn-agent.js +356 -0
- package/packages/typescript/src/features/orchestrator/actions/start-coding-task.d.ts +22 -0
- package/packages/typescript/src/features/orchestrator/actions/start-coding-task.d.ts.map +1 -0
- package/packages/typescript/src/features/orchestrator/actions/start-coding-task.js +270 -0
- package/packages/typescript/src/features/orchestrator/actions/stop-agent.d.ts +12 -0
- package/packages/typescript/src/features/orchestrator/actions/stop-agent.d.ts.map +1 -0
- package/packages/typescript/src/features/orchestrator/actions/stop-agent.js +192 -0
- package/packages/typescript/src/features/orchestrator/actions/task-control.d.ts +3 -0
- package/packages/typescript/src/features/orchestrator/actions/task-control.d.ts.map +1 -0
- package/packages/typescript/src/features/orchestrator/actions/task-control.js +217 -0
- package/packages/typescript/src/features/orchestrator/actions/task-history.d.ts +3 -0
- package/packages/typescript/src/features/orchestrator/actions/task-history.d.ts.map +1 -0
- package/packages/typescript/src/features/orchestrator/actions/task-history.js +323 -0
- package/packages/typescript/src/features/orchestrator/actions/task-share.d.ts +3 -0
- package/packages/typescript/src/features/orchestrator/actions/task-share.d.ts.map +1 -0
- package/packages/typescript/src/features/orchestrator/actions/task-share.js +168 -0
- package/packages/typescript/src/features/orchestrator/actions/task-thread-target.d.ts +11 -0
- package/packages/typescript/src/features/orchestrator/actions/task-thread-target.d.ts.map +1 -0
- package/packages/typescript/src/features/orchestrator/actions/task-thread-target.js +68 -0
- package/packages/typescript/src/features/orchestrator/api/agent-routes.d.ts +18 -0
- package/packages/typescript/src/features/orchestrator/api/agent-routes.d.ts.map +1 -0
- package/packages/typescript/src/features/orchestrator/api/agent-routes.js +654 -0
- package/packages/typescript/src/features/orchestrator/api/coordinator-routes.d.ts +22 -0
- package/packages/typescript/src/features/orchestrator/api/coordinator-routes.d.ts.map +1 -0
- package/packages/typescript/src/features/orchestrator/api/coordinator-routes.js +403 -0
- package/packages/typescript/src/features/orchestrator/api/hook-routes.d.ts +18 -0
- package/packages/typescript/src/features/orchestrator/api/hook-routes.d.ts.map +1 -0
- package/packages/typescript/src/features/orchestrator/api/hook-routes.js +164 -0
- package/packages/typescript/src/features/orchestrator/api/issue-routes.d.ts +17 -0
- package/packages/typescript/src/features/orchestrator/api/issue-routes.d.ts.map +1 -0
- package/packages/typescript/src/features/orchestrator/api/issue-routes.js +132 -0
- package/packages/typescript/src/features/orchestrator/api/routes.d.ts +37 -0
- package/packages/typescript/src/features/orchestrator/api/routes.d.ts.map +1 -0
- package/packages/typescript/src/features/orchestrator/api/routes.js +96 -0
- package/packages/typescript/src/features/orchestrator/api/workspace-routes.d.ts +17 -0
- package/packages/typescript/src/features/orchestrator/api/workspace-routes.d.ts.map +1 -0
- package/packages/typescript/src/features/orchestrator/api/workspace-routes.js +149 -0
- package/packages/typescript/src/features/orchestrator/base-plugin.d.ts +19 -0
- package/packages/typescript/src/features/orchestrator/base-plugin.d.ts.map +1 -0
- package/packages/typescript/src/features/orchestrator/base-plugin.js +75 -0
- package/packages/typescript/src/features/orchestrator/claude-jsonl-completion-watcher.d.ts +101 -0
- package/packages/typescript/src/features/orchestrator/claude-jsonl-completion-watcher.d.ts.map +1 -0
- package/packages/typescript/src/features/orchestrator/claude-jsonl-completion-watcher.js +310 -0
- package/packages/typescript/src/features/orchestrator/index.d.ts +33 -0
- package/packages/typescript/src/features/orchestrator/index.d.ts.map +1 -0
- package/packages/typescript/src/features/orchestrator/index.js +30 -0
- package/packages/typescript/src/features/orchestrator/patch-agent-orchestrator-plugin.d.ts +15 -0
- package/packages/typescript/src/features/orchestrator/patch-agent-orchestrator-plugin.d.ts.map +1 -0
- package/packages/typescript/src/features/orchestrator/patch-agent-orchestrator-plugin.js +1449 -0
- package/packages/typescript/src/features/orchestrator/providers/action-examples.d.ts +14 -0
- package/packages/typescript/src/features/orchestrator/providers/action-examples.d.ts.map +1 -0
- package/packages/typescript/src/features/orchestrator/providers/action-examples.js +151 -0
- package/packages/typescript/src/features/orchestrator/providers/active-workspace-context.d.ts +13 -0
- package/packages/typescript/src/features/orchestrator/providers/active-workspace-context.d.ts.map +1 -0
- package/packages/typescript/src/features/orchestrator/providers/active-workspace-context.js +142 -0
- package/packages/typescript/src/features/orchestrator/services/agent-credentials.d.ts +6 -0
- package/packages/typescript/src/features/orchestrator/services/agent-credentials.d.ts.map +1 -0
- package/packages/typescript/src/features/orchestrator/services/agent-credentials.js +91 -0
- package/packages/typescript/src/features/orchestrator/services/agent-metrics.d.ts +30 -0
- package/packages/typescript/src/features/orchestrator/services/agent-metrics.d.ts.map +1 -0
- package/packages/typescript/src/features/orchestrator/services/agent-metrics.js +54 -0
- package/packages/typescript/src/features/orchestrator/services/agent-selection.d.ts +53 -0
- package/packages/typescript/src/features/orchestrator/services/agent-selection.d.ts.map +1 -0
- package/packages/typescript/src/features/orchestrator/services/agent-selection.js +70 -0
- package/packages/typescript/src/features/orchestrator/services/ansi-utils.d.ts +61 -0
- package/packages/typescript/src/features/orchestrator/services/ansi-utils.d.ts.map +1 -0
- package/packages/typescript/src/features/orchestrator/services/ansi-utils.js +252 -0
- package/packages/typescript/src/features/orchestrator/services/config-env.d.ts +13 -0
- package/packages/typescript/src/features/orchestrator/services/config-env.d.ts.map +1 -0
- package/packages/typescript/src/features/orchestrator/services/config-env.js +37 -0
- package/packages/typescript/src/features/orchestrator/services/coordinator-event-normalizer.d.ts +50 -0
- package/packages/typescript/src/features/orchestrator/services/coordinator-event-normalizer.d.ts.map +1 -0
- package/packages/typescript/src/features/orchestrator/services/coordinator-event-normalizer.js +184 -0
- package/packages/typescript/src/features/orchestrator/services/debug-capture.d.ts +38 -0
- package/packages/typescript/src/features/orchestrator/services/debug-capture.d.ts.map +1 -0
- package/packages/typescript/src/features/orchestrator/services/debug-capture.js +113 -0
- package/packages/typescript/src/features/orchestrator/services/pty-auto-response.d.ts +30 -0
- package/packages/typescript/src/features/orchestrator/services/pty-auto-response.d.ts.map +1 -0
- package/packages/typescript/src/features/orchestrator/services/pty-auto-response.js +146 -0
- package/packages/typescript/src/features/orchestrator/services/pty-init.d.ts +54 -0
- package/packages/typescript/src/features/orchestrator/services/pty-init.d.ts.map +1 -0
- package/packages/typescript/src/features/orchestrator/services/pty-init.js +315 -0
- package/packages/typescript/src/features/orchestrator/services/pty-service.d.ts +175 -0
- package/packages/typescript/src/features/orchestrator/services/pty-service.d.ts.map +1 -0
- package/packages/typescript/src/features/orchestrator/services/pty-service.js +1469 -0
- package/packages/typescript/src/features/orchestrator/services/pty-session-io.d.ts +49 -0
- package/packages/typescript/src/features/orchestrator/services/pty-session-io.d.ts.map +1 -0
- package/packages/typescript/src/features/orchestrator/services/pty-session-io.js +180 -0
- package/packages/typescript/src/features/orchestrator/services/pty-spawn.d.ts +53 -0
- package/packages/typescript/src/features/orchestrator/services/pty-spawn.d.ts.map +1 -0
- package/packages/typescript/src/features/orchestrator/services/pty-spawn.js +280 -0
- package/packages/typescript/src/features/orchestrator/services/pty-types.d.ts +80 -0
- package/packages/typescript/src/features/orchestrator/services/pty-types.d.ts.map +1 -0
- package/packages/typescript/src/features/orchestrator/services/pty-types.js +51 -0
- package/packages/typescript/src/features/orchestrator/services/repo-input.d.ts +16 -0
- package/packages/typescript/src/features/orchestrator/services/repo-input.d.ts.map +1 -0
- package/packages/typescript/src/features/orchestrator/services/repo-input.js +88 -0
- package/packages/typescript/src/features/orchestrator/services/stall-classifier.d.ts +69 -0
- package/packages/typescript/src/features/orchestrator/services/stall-classifier.d.ts.map +1 -0
- package/packages/typescript/src/features/orchestrator/services/stall-classifier.js +446 -0
- package/packages/typescript/src/features/orchestrator/services/swarm-coordinator-prompts.d.ts +97 -0
- package/packages/typescript/src/features/orchestrator/services/swarm-coordinator-prompts.d.ts.map +1 -0
- package/packages/typescript/src/features/orchestrator/services/swarm-coordinator-prompts.js +342 -0
- package/packages/typescript/src/features/orchestrator/services/swarm-coordinator.d.ts +421 -0
- package/packages/typescript/src/features/orchestrator/services/swarm-coordinator.d.ts.map +1 -0
- package/packages/typescript/src/features/orchestrator/services/swarm-coordinator.js +2356 -0
- package/packages/typescript/src/features/orchestrator/services/swarm-decision-loop.d.ts +52 -0
- package/packages/typescript/src/features/orchestrator/services/swarm-decision-loop.d.ts.map +1 -0
- package/packages/typescript/src/features/orchestrator/services/swarm-decision-loop.js +1538 -0
- package/packages/typescript/src/features/orchestrator/services/swarm-event-triage.d.ts +49 -0
- package/packages/typescript/src/features/orchestrator/services/swarm-event-triage.d.ts.map +1 -0
- package/packages/typescript/src/features/orchestrator/services/swarm-event-triage.js +171 -0
- package/packages/typescript/src/features/orchestrator/services/swarm-history.d.ts +27 -0
- package/packages/typescript/src/features/orchestrator/services/swarm-history.d.ts.map +1 -0
- package/packages/typescript/src/features/orchestrator/services/swarm-history.js +148 -0
- package/packages/typescript/src/features/orchestrator/services/swarm-idle-watchdog.d.ts +22 -0
- package/packages/typescript/src/features/orchestrator/services/swarm-idle-watchdog.d.ts.map +1 -0
- package/packages/typescript/src/features/orchestrator/services/swarm-idle-watchdog.js +265 -0
- package/packages/typescript/src/features/orchestrator/services/task-acceptance.d.ts +8 -0
- package/packages/typescript/src/features/orchestrator/services/task-acceptance.d.ts.map +1 -0
- package/packages/typescript/src/features/orchestrator/services/task-acceptance.js +114 -0
- package/packages/typescript/src/features/orchestrator/services/task-agent-auth.d.ts +68 -0
- package/packages/typescript/src/features/orchestrator/services/task-agent-auth.d.ts.map +1 -0
- package/packages/typescript/src/features/orchestrator/services/task-agent-auth.js +559 -0
- package/packages/typescript/src/features/orchestrator/services/task-agent-frameworks.d.ts +82 -0
- package/packages/typescript/src/features/orchestrator/services/task-agent-frameworks.d.ts.map +1 -0
- package/packages/typescript/src/features/orchestrator/services/task-agent-frameworks.js +738 -0
- package/packages/typescript/src/features/orchestrator/services/task-kind.d.ts +3 -0
- package/packages/typescript/src/features/orchestrator/services/task-kind.d.ts.map +1 -0
- package/packages/typescript/src/features/orchestrator/services/task-kind.js +40 -0
- package/packages/typescript/src/features/orchestrator/services/task-policy.d.ts +17 -0
- package/packages/typescript/src/features/orchestrator/services/task-policy.d.ts.map +1 -0
- package/packages/typescript/src/features/orchestrator/services/task-policy.js +226 -0
- package/packages/typescript/src/features/orchestrator/services/task-registry.d.ts +550 -0
- package/packages/typescript/src/features/orchestrator/services/task-registry.d.ts.map +1 -0
- package/packages/typescript/src/features/orchestrator/services/task-registry.js +2182 -0
- package/packages/typescript/src/features/orchestrator/services/task-share.d.ts +18 -0
- package/packages/typescript/src/features/orchestrator/services/task-share.d.ts.map +1 -0
- package/packages/typescript/src/features/orchestrator/services/task-share.js +159 -0
- package/packages/typescript/src/features/orchestrator/services/task-validation.d.ts +69 -0
- package/packages/typescript/src/features/orchestrator/services/task-validation.d.ts.map +1 -0
- package/packages/typescript/src/features/orchestrator/services/task-validation.js +587 -0
- package/packages/typescript/src/features/orchestrator/services/task-verifier-runner.d.ts +5 -0
- package/packages/typescript/src/features/orchestrator/services/task-verifier-runner.d.ts.map +1 -0
- package/packages/typescript/src/features/orchestrator/services/task-verifier-runner.js +372 -0
- package/packages/typescript/src/features/orchestrator/services/trajectory-context.d.ts +73 -0
- package/packages/typescript/src/features/orchestrator/services/trajectory-context.d.ts.map +1 -0
- package/packages/typescript/src/features/orchestrator/services/trajectory-context.js +64 -0
- package/packages/typescript/src/features/orchestrator/services/trajectory-feedback.d.ts +53 -0
- package/packages/typescript/src/features/orchestrator/services/trajectory-feedback.d.ts.map +1 -0
- package/packages/typescript/src/features/orchestrator/services/trajectory-feedback.js +260 -0
- package/packages/typescript/src/features/orchestrator/services/workspace-git-ops.d.ts +28 -0
- package/packages/typescript/src/features/orchestrator/services/workspace-git-ops.d.ts.map +1 -0
- package/packages/typescript/src/features/orchestrator/services/workspace-git-ops.js +105 -0
- package/packages/typescript/src/features/orchestrator/services/workspace-github.d.ts +58 -0
- package/packages/typescript/src/features/orchestrator/services/workspace-github.d.ts.map +1 -0
- package/packages/typescript/src/features/orchestrator/services/workspace-github.js +139 -0
- package/packages/typescript/src/features/orchestrator/services/workspace-lifecycle.d.ts +18 -0
- package/packages/typescript/src/features/orchestrator/services/workspace-lifecycle.d.ts.map +1 -0
- package/packages/typescript/src/features/orchestrator/services/workspace-lifecycle.js +86 -0
- package/packages/typescript/src/features/orchestrator/services/workspace-service.d.ts +118 -0
- package/packages/typescript/src/features/orchestrator/services/workspace-service.d.ts.map +1 -0
- package/packages/typescript/src/features/orchestrator/services/workspace-service.js +533 -0
- package/packages/typescript/src/features/orchestrator/services/workspace-types.d.ts +81 -0
- package/packages/typescript/src/features/orchestrator/services/workspace-types.d.ts.map +1 -0
- package/packages/typescript/src/features/orchestrator/services/workspace-types.js +8 -0
- package/packages/typescript/src/features/orchestrator/task-progress-streamer.d.ts +38 -0
- package/packages/typescript/src/features/orchestrator/task-progress-streamer.d.ts.map +1 -0
- package/packages/typescript/src/features/orchestrator/task-progress-streamer.js +293 -0
- package/packages/typescript/src/features/plugin-manager/actions/coreStatusAction.d.ts +3 -0
- package/packages/typescript/src/features/plugin-manager/actions/coreStatusAction.d.ts.map +1 -0
- package/packages/typescript/src/features/plugin-manager/actions/coreStatusAction.js +65 -0
- package/packages/typescript/src/features/plugin-manager/actions/listEjectedPluginsAction.d.ts +3 -0
- package/packages/typescript/src/features/plugin-manager/actions/listEjectedPluginsAction.d.ts.map +1 -0
- package/packages/typescript/src/features/plugin-manager/actions/listEjectedPluginsAction.js +63 -0
- package/packages/typescript/src/features/plugin-manager/actions/searchPluginAction.d.ts +4 -0
- package/packages/typescript/src/features/plugin-manager/actions/searchPluginAction.d.ts.map +1 -0
- package/packages/typescript/src/features/plugin-manager/actions/searchPluginAction.js +232 -0
- package/packages/typescript/src/features/plugin-manager/coreExtensions.d.ts +35 -0
- package/packages/typescript/src/features/plugin-manager/coreExtensions.d.ts.map +1 -0
- package/packages/typescript/src/features/plugin-manager/coreExtensions.js +77 -0
- package/packages/typescript/src/features/plugin-manager/index.d.ts +25 -0
- package/packages/typescript/src/features/plugin-manager/index.d.ts.map +1 -0
- package/packages/typescript/src/features/plugin-manager/index.js +53 -0
- package/packages/typescript/src/features/plugin-manager/providers/pluginConfigurationStatus.d.ts +5 -0
- package/packages/typescript/src/features/plugin-manager/providers/pluginConfigurationStatus.d.ts.map +1 -0
- package/packages/typescript/src/features/plugin-manager/providers/pluginConfigurationStatus.js +104 -0
- package/packages/typescript/src/features/plugin-manager/providers/pluginStateProvider.d.ts +5 -0
- package/packages/typescript/src/features/plugin-manager/providers/pluginStateProvider.d.ts.map +1 -0
- package/packages/typescript/src/features/plugin-manager/providers/pluginStateProvider.js +105 -0
- package/packages/typescript/src/features/plugin-manager/providers/registryPluginsProvider.d.ts +5 -0
- package/packages/typescript/src/features/plugin-manager/providers/registryPluginsProvider.d.ts.map +1 -0
- package/packages/typescript/src/features/plugin-manager/providers/registryPluginsProvider.js +93 -0
- package/packages/typescript/src/features/plugin-manager/providers/relevance.d.ts +9 -0
- package/packages/typescript/src/features/plugin-manager/providers/relevance.d.ts.map +1 -0
- package/packages/typescript/src/features/plugin-manager/providers/relevance.js +226 -0
- package/packages/typescript/src/features/plugin-manager/services/coreManagerService.d.ts +76 -0
- package/packages/typescript/src/features/plugin-manager/services/coreManagerService.d.ts.map +1 -0
- package/packages/typescript/src/features/plugin-manager/services/coreManagerService.js +479 -0
- package/packages/typescript/src/features/plugin-manager/services/pluginConfigurationService.d.ts +31 -0
- package/packages/typescript/src/features/plugin-manager/services/pluginConfigurationService.d.ts.map +1 -0
- package/packages/typescript/src/features/plugin-manager/services/pluginConfigurationService.js +57 -0
- package/packages/typescript/src/features/plugin-manager/services/pluginManagerService.d.ts +68 -0
- package/packages/typescript/src/features/plugin-manager/services/pluginManagerService.d.ts.map +1 -0
- package/packages/typescript/src/features/plugin-manager/services/pluginManagerService.js +1007 -0
- package/packages/typescript/src/features/plugin-manager/services/pluginRegistryService.d.ts +84 -0
- package/packages/typescript/src/features/plugin-manager/services/pluginRegistryService.d.ts.map +1 -0
- package/packages/typescript/src/features/plugin-manager/services/pluginRegistryService.js +402 -0
- package/packages/typescript/src/features/plugin-manager/types.d.ts +142 -0
- package/packages/typescript/src/features/plugin-manager/types.d.ts.map +1 -0
- package/packages/typescript/src/features/plugin-manager/types.js +13 -0
- package/packages/typescript/src/features/plugin-manager/utils/paths.d.ts +4 -0
- package/packages/typescript/src/features/plugin-manager/utils/paths.d.ts.map +1 -0
- package/packages/typescript/src/features/plugin-manager/utils/paths.js +32 -0
- package/packages/typescript/src/features/secrets/actions/index.d.ts +7 -0
- package/packages/typescript/src/features/secrets/actions/index.d.ts.map +1 -0
- package/packages/typescript/src/features/secrets/actions/index.js +6 -0
- package/packages/typescript/src/features/secrets/actions/manage-secret.d.ts +12 -0
- package/packages/typescript/src/features/secrets/actions/manage-secret.d.ts.map +1 -0
- package/packages/typescript/src/features/secrets/actions/manage-secret.js +278 -0
- package/packages/typescript/src/features/secrets/actions/request-secret.d.ts +3 -0
- package/packages/typescript/src/features/secrets/actions/request-secret.d.ts.map +1 -0
- package/packages/typescript/src/features/secrets/actions/request-secret.js +105 -0
- package/packages/typescript/src/features/secrets/actions/set-secret.d.ts +12 -0
- package/packages/typescript/src/features/secrets/actions/set-secret.d.ts.map +1 -0
- package/packages/typescript/src/features/secrets/actions/set-secret.js +223 -0
- package/packages/typescript/src/features/secrets/crypto/encryption.d.ts +184 -0
- package/packages/typescript/src/features/secrets/crypto/encryption.d.ts.map +1 -0
- package/packages/typescript/src/features/secrets/crypto/encryption.js +373 -0
- package/packages/typescript/src/features/secrets/crypto/index.d.ts +5 -0
- package/packages/typescript/src/features/secrets/crypto/index.d.ts.map +1 -0
- package/packages/typescript/src/features/secrets/crypto/index.js +16 -0
- package/packages/typescript/src/features/secrets/onboarding/action.d.ts +12 -0
- package/packages/typescript/src/features/secrets/onboarding/action.d.ts.map +1 -0
- package/packages/typescript/src/features/secrets/onboarding/action.js +337 -0
- package/packages/typescript/src/features/secrets/onboarding/config.d.ts +99 -0
- package/packages/typescript/src/features/secrets/onboarding/config.d.ts.map +1 -0
- package/packages/typescript/src/features/secrets/onboarding/config.js +240 -0
- package/packages/typescript/src/features/secrets/onboarding/index.d.ts +13 -0
- package/packages/typescript/src/features/secrets/onboarding/index.d.ts.map +1 -0
- package/packages/typescript/src/features/secrets/onboarding/index.js +12 -0
- package/packages/typescript/src/features/secrets/onboarding/provider.d.ts +16 -0
- package/packages/typescript/src/features/secrets/onboarding/provider.d.ts.map +1 -0
- package/packages/typescript/src/features/secrets/onboarding/provider.js +231 -0
- package/packages/typescript/src/features/secrets/onboarding/service.d.ts +134 -0
- package/packages/typescript/src/features/secrets/onboarding/service.d.ts.map +1 -0
- package/packages/typescript/src/features/secrets/onboarding/service.js +436 -0
- package/packages/typescript/src/features/secrets/providers/index.d.ts +5 -0
- package/packages/typescript/src/features/secrets/providers/index.d.ts.map +1 -0
- package/packages/typescript/src/features/secrets/providers/index.js +4 -0
- package/packages/typescript/src/features/secrets/providers/secrets-status.d.ts +22 -0
- package/packages/typescript/src/features/secrets/providers/secrets-status.d.ts.map +1 -0
- package/packages/typescript/src/features/secrets/providers/secrets-status.js +160 -0
- package/packages/typescript/src/features/secrets/services/plugin-activator.d.ts +182 -0
- package/packages/typescript/src/features/secrets/services/plugin-activator.d.ts.map +1 -0
- package/packages/typescript/src/features/secrets/services/plugin-activator.js +617 -0
- package/packages/typescript/src/features/secrets/services/secrets.d.ts +183 -0
- package/packages/typescript/src/features/secrets/services/secrets.d.ts.map +1 -0
- package/packages/typescript/src/features/secrets/services/secrets.js +566 -0
- package/packages/typescript/src/features/secrets/storage/character-store.d.ts +63 -0
- package/packages/typescript/src/features/secrets/storage/character-store.d.ts.map +1 -0
- package/packages/typescript/src/features/secrets/storage/character-store.js +265 -0
- package/packages/typescript/src/features/secrets/storage/component-store.d.ts +47 -0
- package/packages/typescript/src/features/secrets/storage/component-store.d.ts.map +1 -0
- package/packages/typescript/src/features/secrets/storage/component-store.js +264 -0
- package/packages/typescript/src/features/secrets/storage/index.d.ts +10 -0
- package/packages/typescript/src/features/secrets/storage/index.d.ts.map +1 -0
- package/packages/typescript/src/features/secrets/storage/index.js +8 -0
- package/packages/typescript/src/features/secrets/storage/interface.d.ts +52 -0
- package/packages/typescript/src/features/secrets/storage/interface.d.ts.map +1 -0
- package/packages/typescript/src/features/secrets/storage/interface.js +92 -0
- package/packages/typescript/src/features/secrets/storage/memory-store.d.ts +44 -0
- package/packages/typescript/src/features/secrets/storage/memory-store.d.ts.map +1 -0
- package/packages/typescript/src/features/secrets/storage/memory-store.js +142 -0
- package/packages/typescript/src/features/secrets/storage/world-store.d.ts +52 -0
- package/packages/typescript/src/features/secrets/storage/world-store.d.ts.map +1 -0
- package/packages/typescript/src/features/secrets/storage/world-store.js +292 -0
- package/packages/typescript/src/features/secrets/types.d.ts +438 -0
- package/packages/typescript/src/features/secrets/types.d.ts.map +1 -0
- package/packages/typescript/src/features/secrets/types.js +57 -0
- package/packages/typescript/src/features/secrets/validation.d.ts +33 -0
- package/packages/typescript/src/features/secrets/validation.d.ts.map +1 -0
- package/packages/typescript/src/features/secrets/validation.js +389 -0
- package/packages/typescript/src/features/trajectories/TrajectoriesService.d.ts +275 -0
- package/packages/typescript/src/features/trajectories/TrajectoriesService.d.ts.map +1 -0
- package/packages/typescript/src/features/trajectories/TrajectoriesService.js +1401 -0
- package/packages/typescript/src/features/trajectories/action-interceptor.d.ts +23 -0
- package/packages/typescript/src/features/trajectories/action-interceptor.d.ts.map +1 -0
- package/packages/typescript/src/features/trajectories/action-interceptor.js +178 -0
- package/packages/typescript/src/features/trajectories/art-format.d.ts +32 -0
- package/packages/typescript/src/features/trajectories/art-format.d.ts.map +1 -0
- package/packages/typescript/src/features/trajectories/art-format.js +221 -0
- package/packages/typescript/src/features/trajectories/export.d.ts +40 -0
- package/packages/typescript/src/features/trajectories/export.d.ts.map +1 -0
- package/packages/typescript/src/features/trajectories/export.js +99 -0
- package/packages/typescript/src/features/trajectories/game-rewards.d.ts +14 -0
- package/packages/typescript/src/features/trajectories/game-rewards.d.ts.map +1 -0
- package/packages/typescript/src/features/trajectories/game-rewards.js +20 -0
- package/packages/typescript/src/features/trajectories/index.d.ts +24 -0
- package/packages/typescript/src/features/trajectories/index.d.ts.map +1 -0
- package/packages/typescript/src/features/trajectories/index.js +253 -0
- package/packages/typescript/src/features/trajectories/integration.d.ts +59 -0
- package/packages/typescript/src/features/trajectories/integration.d.ts.map +1 -0
- package/packages/typescript/src/features/trajectories/integration.js +83 -0
- package/packages/typescript/src/features/trajectories/reward-service.d.ts +24 -0
- package/packages/typescript/src/features/trajectories/reward-service.d.ts.map +1 -0
- package/packages/typescript/src/features/trajectories/reward-service.js +89 -0
- package/packages/typescript/src/features/trajectories/types.d.ts +243 -0
- package/packages/typescript/src/features/trajectories/types.d.ts.map +1 -0
- package/packages/typescript/src/features/trajectories/types.js +1 -0
- package/packages/typescript/src/features/trust/actions/evaluateTrust.d.ts +3 -0
- package/packages/typescript/src/features/trust/actions/evaluateTrust.d.ts.map +1 -0
- package/packages/typescript/src/features/trust/actions/evaluateTrust.js +225 -0
- package/packages/typescript/src/features/trust/actions/hasTrustEngine.d.ts +3 -0
- package/packages/typescript/src/features/trust/actions/hasTrustEngine.d.ts.map +1 -0
- package/packages/typescript/src/features/trust/actions/hasTrustEngine.js +3 -0
- package/packages/typescript/src/features/trust/actions/index.d.ts +6 -0
- package/packages/typescript/src/features/trust/actions/index.d.ts.map +1 -0
- package/packages/typescript/src/features/trust/actions/index.js +5 -0
- package/packages/typescript/src/features/trust/actions/recordTrustInteraction.d.ts +3 -0
- package/packages/typescript/src/features/trust/actions/recordTrustInteraction.d.ts.map +1 -0
- package/packages/typescript/src/features/trust/actions/recordTrustInteraction.js +189 -0
- package/packages/typescript/src/features/trust/actions/requestElevation.d.ts +3 -0
- package/packages/typescript/src/features/trust/actions/requestElevation.d.ts.map +1 -0
- package/packages/typescript/src/features/trust/actions/requestElevation.js +165 -0
- package/packages/typescript/src/features/trust/actions/roles.d.ts +3 -0
- package/packages/typescript/src/features/trust/actions/roles.d.ts.map +1 -0
- package/packages/typescript/src/features/trust/actions/roles.js +295 -0
- package/packages/typescript/src/features/trust/actions/settings.d.ts +5 -0
- package/packages/typescript/src/features/trust/actions/settings.d.ts.map +1 -0
- package/packages/typescript/src/features/trust/actions/settings.js +603 -0
- package/packages/typescript/src/features/trust/evaluators/index.d.ts +4 -0
- package/packages/typescript/src/features/trust/evaluators/index.d.ts.map +1 -0
- package/packages/typescript/src/features/trust/evaluators/index.js +3 -0
- package/packages/typescript/src/features/trust/evaluators/reflection.d.ts +3 -0
- package/packages/typescript/src/features/trust/evaluators/reflection.d.ts.map +1 -0
- package/packages/typescript/src/features/trust/evaluators/reflection.js +290 -0
- package/packages/typescript/src/features/trust/evaluators/securityEvaluator.d.ts +3 -0
- package/packages/typescript/src/features/trust/evaluators/securityEvaluator.d.ts.map +1 -0
- package/packages/typescript/src/features/trust/evaluators/securityEvaluator.js +270 -0
- package/packages/typescript/src/features/trust/evaluators/trustChangeEvaluator.d.ts +3 -0
- package/packages/typescript/src/features/trust/evaluators/trustChangeEvaluator.d.ts.map +1 -0
- package/packages/typescript/src/features/trust/evaluators/trustChangeEvaluator.js +201 -0
- package/packages/typescript/src/features/trust/index.d.ts +72 -0
- package/packages/typescript/src/features/trust/index.d.ts.map +1 -0
- package/packages/typescript/src/features/trust/index.js +213 -0
- package/packages/typescript/src/features/trust/providers/adminTrust.d.ts +3 -0
- package/packages/typescript/src/features/trust/providers/adminTrust.d.ts.map +1 -0
- package/packages/typescript/src/features/trust/providers/adminTrust.js +49 -0
- package/packages/typescript/src/features/trust/providers/index.d.ts +6 -0
- package/packages/typescript/src/features/trust/providers/index.d.ts.map +1 -0
- package/packages/typescript/src/features/trust/providers/index.js +5 -0
- package/packages/typescript/src/features/trust/providers/roles.d.ts +4 -0
- package/packages/typescript/src/features/trust/providers/roles.d.ts.map +1 -0
- package/packages/typescript/src/features/trust/providers/roles.js +142 -0
- package/packages/typescript/src/features/trust/providers/securityStatus.d.ts +3 -0
- package/packages/typescript/src/features/trust/providers/securityStatus.d.ts.map +1 -0
- package/packages/typescript/src/features/trust/providers/securityStatus.js +110 -0
- package/packages/typescript/src/features/trust/providers/settings.d.ts +3 -0
- package/packages/typescript/src/features/trust/providers/settings.d.ts.map +1 -0
- package/packages/typescript/src/features/trust/providers/settings.js +212 -0
- package/packages/typescript/src/features/trust/providers/trustProfile.d.ts +3 -0
- package/packages/typescript/src/features/trust/providers/trustProfile.d.ts.map +1 -0
- package/packages/typescript/src/features/trust/providers/trustProfile.js +68 -0
- package/packages/typescript/src/features/trust/schema.d.ts +1170 -0
- package/packages/typescript/src/features/trust/schema.d.ts.map +1 -0
- package/packages/typescript/src/features/trust/schema.js +108 -0
- package/packages/typescript/src/features/trust/services/ContextualPermissionSystem.d.ts +40 -0
- package/packages/typescript/src/features/trust/services/ContextualPermissionSystem.d.ts.map +1 -0
- package/packages/typescript/src/features/trust/services/ContextualPermissionSystem.js +317 -0
- package/packages/typescript/src/features/trust/services/CredentialProtector.d.ts +62 -0
- package/packages/typescript/src/features/trust/services/CredentialProtector.d.ts.map +1 -0
- package/packages/typescript/src/features/trust/services/CredentialProtector.js +417 -0
- package/packages/typescript/src/features/trust/services/SecurityModule.d.ts +142 -0
- package/packages/typescript/src/features/trust/services/SecurityModule.d.ts.map +1 -0
- package/packages/typescript/src/features/trust/services/SecurityModule.js +1057 -0
- package/packages/typescript/src/features/trust/services/SecurityStore.d.ts +53 -0
- package/packages/typescript/src/features/trust/services/SecurityStore.d.ts.map +1 -0
- package/packages/typescript/src/features/trust/services/SecurityStore.js +123 -0
- package/packages/typescript/src/features/trust/services/TrustEngine.d.ts +81 -0
- package/packages/typescript/src/features/trust/services/TrustEngine.d.ts.map +1 -0
- package/packages/typescript/src/features/trust/services/TrustEngine.js +621 -0
- package/packages/typescript/src/features/trust/services/adminContext.d.ts +3 -0
- package/packages/typescript/src/features/trust/services/adminContext.d.ts.map +1 -0
- package/packages/typescript/src/features/trust/services/adminContext.js +32 -0
- package/packages/typescript/src/features/trust/services/db.d.ts +12 -0
- package/packages/typescript/src/features/trust/services/db.d.ts.map +1 -0
- package/packages/typescript/src/features/trust/services/db.js +10 -0
- package/packages/typescript/src/features/trust/types/permissions.d.ts +185 -0
- package/packages/typescript/src/features/trust/types/permissions.d.ts.map +1 -0
- package/packages/typescript/src/features/trust/types/permissions.js +58 -0
- package/packages/typescript/src/features/trust/types/security.d.ts +114 -0
- package/packages/typescript/src/features/trust/types/security.d.ts.map +1 -0
- package/packages/typescript/src/features/trust/types/security.js +15 -0
- package/packages/typescript/src/features/trust/types/trust.d.ts +179 -0
- package/packages/typescript/src/features/trust/types/trust.d.ts.map +1 -0
- package/packages/typescript/src/features/trust/types/trust.js +25 -0
- package/packages/typescript/src/generated/action-docs.d.ts +2470 -0
- package/packages/typescript/src/generated/action-docs.d.ts.map +1 -0
- package/packages/typescript/src/generated/action-docs.js +3549 -0
- package/packages/typescript/src/generated/spec-helpers.d.ts +49 -0
- package/packages/typescript/src/generated/spec-helpers.d.ts.map +1 -0
- package/packages/typescript/src/generated/spec-helpers.js +78 -0
- package/packages/typescript/src/i18n/generated/validation-keyword-data.d.ts +1032 -0
- package/packages/typescript/src/i18n/generated/validation-keyword-data.d.ts.map +1 -0
- package/packages/typescript/src/i18n/generated/validation-keyword-data.js +1032 -0
- package/packages/typescript/src/i18n/validation-keywords.d.ts +25 -0
- package/packages/typescript/src/i18n/validation-keywords.d.ts.map +1 -0
- package/packages/typescript/src/i18n/validation-keywords.js +112 -0
- package/packages/typescript/src/index.d.ts +12 -0
- package/packages/typescript/src/index.d.ts.map +1 -0
- package/packages/typescript/src/index.js +13 -0
- package/packages/typescript/src/index.node.d.ts +78 -0
- package/packages/typescript/src/index.node.d.ts.map +1 -0
- package/packages/typescript/src/index.node.js +106 -0
- package/packages/typescript/src/logger.d.ts +121 -0
- package/packages/typescript/src/logger.d.ts.map +1 -0
- package/packages/typescript/src/logger.js +1023 -0
- package/packages/typescript/src/markdown/chunk.d.ts +50 -0
- package/packages/typescript/src/markdown/chunk.d.ts.map +1 -0
- package/packages/typescript/src/markdown/chunk.js +268 -0
- package/packages/typescript/src/markdown/code-spans.d.ts +42 -0
- package/packages/typescript/src/markdown/code-spans.d.ts.map +1 -0
- package/packages/typescript/src/markdown/code-spans.js +89 -0
- package/packages/typescript/src/markdown/fences.d.ts +50 -0
- package/packages/typescript/src/markdown/fences.d.ts.map +1 -0
- package/packages/typescript/src/markdown/fences.js +90 -0
- package/packages/typescript/src/markdown/frontmatter.d.ts +24 -0
- package/packages/typescript/src/markdown/frontmatter.d.ts.map +1 -0
- package/packages/typescript/src/markdown/frontmatter.js +151 -0
- package/packages/typescript/src/markdown/index.d.ts +18 -0
- package/packages/typescript/src/markdown/index.d.ts.map +1 -0
- package/packages/typescript/src/markdown/index.js +17 -0
- package/packages/typescript/src/markdown/ir.d.ts +101 -0
- package/packages/typescript/src/markdown/ir.d.ts.map +1 -0
- package/packages/typescript/src/markdown/ir.js +789 -0
- package/packages/typescript/src/media/fetch.d.ts +39 -0
- package/packages/typescript/src/media/fetch.d.ts.map +1 -0
- package/packages/typescript/src/media/fetch.js +205 -0
- package/packages/typescript/src/media/index.d.ts +8 -0
- package/packages/typescript/src/media/index.d.ts.map +1 -0
- package/packages/typescript/src/media/index.js +7 -0
- package/packages/typescript/src/media/mime.d.ts +51 -0
- package/packages/typescript/src/media/mime.d.ts.map +1 -0
- package/packages/typescript/src/media/mime.js +225 -0
- package/packages/typescript/src/memory.d.ts +40 -0
- package/packages/typescript/src/memory.d.ts.map +1 -0
- package/packages/typescript/src/memory.js +58 -0
- package/packages/typescript/src/network/fetch-guard.d.ts +34 -0
- package/packages/typescript/src/network/fetch-guard.d.ts.map +1 -0
- package/packages/typescript/src/network/fetch-guard.js +136 -0
- package/packages/typescript/src/network/index.d.ts +11 -0
- package/packages/typescript/src/network/index.d.ts.map +1 -0
- package/packages/typescript/src/network/index.js +10 -0
- package/packages/typescript/src/network/ssrf.d.ts +58 -0
- package/packages/typescript/src/network/ssrf.d.ts.map +1 -0
- package/packages/typescript/src/network/ssrf.js +252 -0
- package/packages/typescript/src/plugin-lifecycle.d.ts +16 -0
- package/packages/typescript/src/plugin-lifecycle.d.ts.map +1 -0
- package/packages/typescript/src/plugin-lifecycle.js +551 -0
- package/packages/typescript/src/plugin.d.ts +13 -0
- package/packages/typescript/src/plugin.d.ts.map +1 -0
- package/packages/typescript/src/plugin.js +334 -0
- package/packages/typescript/src/plugins/index.d.ts +9 -0
- package/packages/typescript/src/plugins/index.d.ts.map +1 -0
- package/packages/typescript/src/plugins/index.js +8 -0
- package/packages/typescript/src/plugins/native-features.d.ts +14 -0
- package/packages/typescript/src/plugins/native-features.d.ts.map +1 -0
- package/packages/typescript/src/plugins/native-features.js +59 -0
- package/packages/typescript/src/prompts.d.ts +88 -0
- package/packages/typescript/src/prompts.d.ts.map +1 -0
- package/packages/typescript/src/prompts.js +1123 -0
- package/packages/typescript/src/providers/onboarding-progress.d.ts +19 -0
- package/packages/typescript/src/providers/onboarding-progress.d.ts.map +1 -0
- package/packages/typescript/src/providers/onboarding-progress.js +268 -0
- package/packages/typescript/src/providers/skill-eligibility.d.ts +28 -0
- package/packages/typescript/src/providers/skill-eligibility.d.ts.map +1 -0
- package/packages/typescript/src/providers/skill-eligibility.js +179 -0
- package/packages/typescript/src/provisioning.d.ts +54 -0
- package/packages/typescript/src/provisioning.d.ts.map +1 -0
- package/packages/typescript/src/provisioning.js +209 -0
- package/packages/typescript/src/roles.d.ts +70 -0
- package/packages/typescript/src/roles.d.ts.map +1 -0
- package/packages/typescript/src/roles.js +544 -0
- package/packages/typescript/src/runtime-composition.d.ts +129 -0
- package/packages/typescript/src/runtime-composition.d.ts.map +1 -0
- package/packages/typescript/src/runtime-composition.js +335 -0
- package/packages/typescript/src/runtime.d.ts +877 -0
- package/packages/typescript/src/runtime.d.ts.map +1 -0
- package/packages/typescript/src/runtime.js +5277 -0
- package/packages/typescript/src/schemas/agent.d.ts +7 -0
- package/packages/typescript/src/schemas/agent.d.ts.map +1 -0
- package/packages/typescript/src/schemas/agent.js +112 -0
- package/packages/typescript/src/schemas/cache.d.ts +7 -0
- package/packages/typescript/src/schemas/cache.d.ts.map +1 -0
- package/packages/typescript/src/schemas/cache.js +55 -0
- package/packages/typescript/src/schemas/channel-participant.d.ts +7 -0
- package/packages/typescript/src/schemas/channel-participant.d.ts.map +1 -0
- package/packages/typescript/src/schemas/channel-participant.js +49 -0
- package/packages/typescript/src/schemas/channel.d.ts +7 -0
- package/packages/typescript/src/schemas/channel.d.ts.map +1 -0
- package/packages/typescript/src/schemas/channel.js +94 -0
- package/packages/typescript/src/schemas/character.d.ts +445 -0
- package/packages/typescript/src/schemas/character.d.ts.map +1 -0
- package/packages/typescript/src/schemas/character.js +309 -0
- package/packages/typescript/src/schemas/component.d.ts +7 -0
- package/packages/typescript/src/schemas/component.d.ts.map +1 -0
- package/packages/typescript/src/schemas/component.js +156 -0
- package/packages/typescript/src/schemas/embedding.d.ts +7 -0
- package/packages/typescript/src/schemas/embedding.d.ts.map +1 -0
- package/packages/typescript/src/schemas/embedding.js +89 -0
- package/packages/typescript/src/schemas/entity.d.ts +7 -0
- package/packages/typescript/src/schemas/entity.d.ts.map +1 -0
- package/packages/typescript/src/schemas/entity.js +69 -0
- package/packages/typescript/src/schemas/index.d.ts +75 -0
- package/packages/typescript/src/schemas/index.d.ts.map +1 -0
- package/packages/typescript/src/schemas/index.js +74 -0
- package/packages/typescript/src/schemas/log.d.ts +6 -0
- package/packages/typescript/src/schemas/log.d.ts.map +1 -0
- package/packages/typescript/src/schemas/log.js +93 -0
- package/packages/typescript/src/schemas/memory.d.ts +7 -0
- package/packages/typescript/src/schemas/memory.d.ts.map +1 -0
- package/packages/typescript/src/schemas/memory.js +167 -0
- package/packages/typescript/src/schemas/message-server-agent.d.ts +7 -0
- package/packages/typescript/src/schemas/message-server-agent.d.ts.map +1 -0
- package/packages/typescript/src/schemas/message-server-agent.js +58 -0
- package/packages/typescript/src/schemas/message-server.d.ts +6 -0
- package/packages/typescript/src/schemas/message-server.d.ts.map +1 -0
- package/packages/typescript/src/schemas/message-server.js +62 -0
- package/packages/typescript/src/schemas/message.d.ts +7 -0
- package/packages/typescript/src/schemas/message.d.ts.map +1 -0
- package/packages/typescript/src/schemas/message.js +106 -0
- package/packages/typescript/src/schemas/pairing-allowlist.d.ts +7 -0
- package/packages/typescript/src/schemas/pairing-allowlist.d.ts.map +1 -0
- package/packages/typescript/src/schemas/pairing-allowlist.js +76 -0
- package/packages/typescript/src/schemas/pairing-request.d.ts +7 -0
- package/packages/typescript/src/schemas/pairing-request.d.ts.map +1 -0
- package/packages/typescript/src/schemas/pairing-request.js +96 -0
- package/packages/typescript/src/schemas/participant.d.ts +6 -0
- package/packages/typescript/src/schemas/participant.d.ts.map +1 -0
- package/packages/typescript/src/schemas/participant.js +91 -0
- package/packages/typescript/src/schemas/relationship.d.ts +7 -0
- package/packages/typescript/src/schemas/relationship.d.ts.map +1 -0
- package/packages/typescript/src/schemas/relationship.js +102 -0
- package/packages/typescript/src/schemas/room.d.ts +6 -0
- package/packages/typescript/src/schemas/room.d.ts.map +1 -0
- package/packages/typescript/src/schemas/room.js +86 -0
- package/packages/typescript/src/schemas/server.d.ts +7 -0
- package/packages/typescript/src/schemas/server.d.ts.map +1 -0
- package/packages/typescript/src/schemas/server.js +33 -0
- package/packages/typescript/src/schemas/task.d.ts +6 -0
- package/packages/typescript/src/schemas/task.d.ts.map +1 -0
- package/packages/typescript/src/schemas/task.js +95 -0
- package/packages/typescript/src/schemas/world.d.ts +6 -0
- package/packages/typescript/src/schemas/world.d.ts.map +1 -0
- package/packages/typescript/src/schemas/world.js +64 -0
- package/packages/typescript/src/search.d.ts +381 -0
- package/packages/typescript/src/search.d.ts.map +1 -0
- package/packages/typescript/src/search.js +1580 -0
- package/packages/typescript/src/secrets.d.ts +6 -0
- package/packages/typescript/src/secrets.d.ts.map +1 -0
- package/packages/typescript/src/secrets.js +28 -0
- package/packages/typescript/src/security/external-content.d.ts +96 -0
- package/packages/typescript/src/security/external-content.d.ts.map +1 -0
- package/packages/typescript/src/security/external-content.js +252 -0
- package/packages/typescript/src/security/index.d.ts +12 -0
- package/packages/typescript/src/security/index.d.ts.map +1 -0
- package/packages/typescript/src/security/index.js +13 -0
- package/packages/typescript/src/security/redact.d.ts +111 -0
- package/packages/typescript/src/security/redact.d.ts.map +1 -0
- package/packages/typescript/src/security/redact.js +254 -0
- package/packages/typescript/src/services/agentEvent.d.ts +297 -0
- package/packages/typescript/src/services/agentEvent.d.ts.map +1 -0
- package/packages/typescript/src/services/agentEvent.js +422 -0
- package/packages/typescript/src/services/approval.d.ts +169 -0
- package/packages/typescript/src/services/approval.d.ts.map +1 -0
- package/packages/typescript/src/services/approval.js +399 -0
- package/packages/typescript/src/services/embedding.d.ts +29 -0
- package/packages/typescript/src/services/embedding.d.ts.map +1 -0
- package/packages/typescript/src/services/embedding.js +211 -0
- package/packages/typescript/src/services/followUp.d.ts +48 -0
- package/packages/typescript/src/services/followUp.d.ts.map +1 -0
- package/packages/typescript/src/services/followUp.js +333 -0
- package/packages/typescript/src/services/hook.d.ts +85 -0
- package/packages/typescript/src/services/hook.d.ts.map +1 -0
- package/packages/typescript/src/services/hook.js +396 -0
- package/packages/typescript/src/services/message.d.ts +93 -0
- package/packages/typescript/src/services/message.d.ts.map +1 -0
- package/packages/typescript/src/services/message.js +3131 -0
- package/packages/typescript/src/services/onboarding-cli.d.ts +240 -0
- package/packages/typescript/src/services/onboarding-cli.d.ts.map +1 -0
- package/packages/typescript/src/services/onboarding-cli.js +688 -0
- package/packages/typescript/src/services/onboarding-rpc.d.ts +225 -0
- package/packages/typescript/src/services/onboarding-rpc.d.ts.map +1 -0
- package/packages/typescript/src/services/onboarding-rpc.js +318 -0
- package/packages/typescript/src/services/onboarding-state.d.ts +155 -0
- package/packages/typescript/src/services/onboarding-state.d.ts.map +1 -0
- package/packages/typescript/src/services/onboarding-state.js +706 -0
- package/packages/typescript/src/services/pairing-integration.d.ts +96 -0
- package/packages/typescript/src/services/pairing-integration.d.ts.map +1 -0
- package/packages/typescript/src/services/pairing-integration.js +145 -0
- package/packages/typescript/src/services/pairing-migration.d.ts +105 -0
- package/packages/typescript/src/services/pairing-migration.d.ts.map +1 -0
- package/packages/typescript/src/services/pairing-migration.js +283 -0
- package/packages/typescript/src/services/pairing.d.ts +80 -0
- package/packages/typescript/src/services/pairing.d.ts.map +1 -0
- package/packages/typescript/src/services/pairing.js +253 -0
- package/packages/typescript/src/services/plugin-hooks.d.ts +112 -0
- package/packages/typescript/src/services/plugin-hooks.d.ts.map +1 -0
- package/packages/typescript/src/services/plugin-hooks.js +163 -0
- package/packages/typescript/src/services/relationships.d.ts +125 -0
- package/packages/typescript/src/services/relationships.d.ts.map +1 -0
- package/packages/typescript/src/services/relationships.js +637 -0
- package/packages/typescript/src/services/task-scheduler.d.ts +28 -0
- package/packages/typescript/src/services/task-scheduler.d.ts.map +1 -0
- package/packages/typescript/src/services/task-scheduler.js +89 -0
- package/packages/typescript/src/services/task.d.ts +130 -0
- package/packages/typescript/src/services/task.d.ts.map +1 -0
- package/packages/typescript/src/services/task.js +536 -0
- package/packages/typescript/src/services/tool-policy.d.ts +186 -0
- package/packages/typescript/src/services/tool-policy.d.ts.map +1 -0
- package/packages/typescript/src/services/tool-policy.js +332 -0
- package/packages/typescript/src/services/trajectories.d.ts +25 -0
- package/packages/typescript/src/services/trajectories.d.ts.map +1 -0
- package/packages/typescript/src/services/trajectories.js +1 -0
- package/packages/typescript/src/services.d.ts +61 -0
- package/packages/typescript/src/services.d.ts.map +1 -0
- package/packages/typescript/src/services.js +99 -0
- package/packages/typescript/src/sessions/index.d.ts +17 -0
- package/packages/typescript/src/sessions/index.d.ts.map +1 -0
- package/packages/typescript/src/sessions/index.js +29 -0
- package/packages/typescript/src/sessions/provider.d.ts +71 -0
- package/packages/typescript/src/sessions/provider.d.ts.map +1 -0
- package/packages/typescript/src/sessions/provider.js +243 -0
- package/packages/typescript/src/sessions/session-key.d.ts +201 -0
- package/packages/typescript/src/sessions/session-key.d.ts.map +1 -0
- package/packages/typescript/src/sessions/session-key.js +396 -0
- package/packages/typescript/src/sessions/types.d.ts +197 -0
- package/packages/typescript/src/sessions/types.d.ts.map +1 -0
- package/packages/typescript/src/sessions/types.js +68 -0
- package/packages/typescript/src/settings.d.ts +99 -0
- package/packages/typescript/src/settings.d.ts.map +1 -0
- package/packages/typescript/src/settings.js +409 -0
- package/packages/typescript/src/should-respond.d.ts +2 -0
- package/packages/typescript/src/should-respond.d.ts.map +1 -0
- package/packages/typescript/src/should-respond.js +16 -0
- package/packages/typescript/src/streaming-context.d.ts +79 -0
- package/packages/typescript/src/streaming-context.d.ts.map +1 -0
- package/packages/typescript/src/streaming-context.js +115 -0
- package/packages/typescript/src/trajectory-context.d.ts +26 -0
- package/packages/typescript/src/trajectory-context.d.ts.map +1 -0
- package/packages/typescript/src/trajectory-context.js +85 -0
- package/packages/typescript/src/trajectory-utils.d.ts +49 -0
- package/packages/typescript/src/trajectory-utils.d.ts.map +1 -0
- package/packages/typescript/src/trajectory-utils.js +105 -0
- package/packages/typescript/src/types/agent.d.ts +62 -0
- package/packages/typescript/src/types/agent.d.ts.map +1 -0
- package/packages/typescript/src/types/agent.js +5 -0
- package/packages/typescript/src/types/agentEvent.d.ts +258 -0
- package/packages/typescript/src/types/agentEvent.d.ts.map +1 -0
- package/packages/typescript/src/types/agentEvent.js +11 -0
- package/packages/typescript/src/types/channel-config.d.ts +167 -0
- package/packages/typescript/src/types/channel-config.d.ts.map +1 -0
- package/packages/typescript/src/types/channel-config.js +7 -0
- package/packages/typescript/src/types/components.d.ts +346 -0
- package/packages/typescript/src/types/components.d.ts.map +1 -0
- package/packages/typescript/src/types/components.js +1 -0
- package/packages/typescript/src/types/database.d.ts +1079 -0
- package/packages/typescript/src/types/database.d.ts.map +1 -0
- package/packages/typescript/src/types/database.js +9 -0
- package/packages/typescript/src/types/environment.d.ts +73 -0
- package/packages/typescript/src/types/environment.d.ts.map +1 -0
- package/packages/typescript/src/types/environment.js +16 -0
- package/packages/typescript/src/types/events.d.ts +386 -0
- package/packages/typescript/src/types/events.d.ts.map +1 -0
- package/packages/typescript/src/types/events.js +83 -0
- package/packages/typescript/src/types/generated/eliza/v1/agent_pb.d.ts +400 -0
- package/packages/typescript/src/types/generated/eliza/v1/agent_pb.d.ts.map +1 -0
- package/packages/typescript/src/types/generated/eliza/v1/agent_pb.js +72 -0
- package/packages/typescript/src/types/generated/eliza/v1/components_pb.d.ts +364 -0
- package/packages/typescript/src/types/generated/eliza/v1/components_pb.d.ts.map +1 -0
- package/packages/typescript/src/types/generated/eliza/v1/components_pb.js +68 -0
- package/packages/typescript/src/types/generated/eliza/v1/database_pb.d.ts +694 -0
- package/packages/typescript/src/types/generated/eliza/v1/database_pb.d.ts.map +1 -0
- package/packages/typescript/src/types/generated/eliza/v1/database_pb.js +172 -0
- package/packages/typescript/src/types/generated/eliza/v1/environment_pb.d.ts +299 -0
- package/packages/typescript/src/types/generated/eliza/v1/environment_pb.d.ts.map +1 -0
- package/packages/typescript/src/types/generated/eliza/v1/environment_pb.js +52 -0
- package/packages/typescript/src/types/generated/eliza/v1/events_pb.d.ts +746 -0
- package/packages/typescript/src/types/generated/eliza/v1/events_pb.d.ts.map +1 -0
- package/packages/typescript/src/types/generated/eliza/v1/events_pb.js +357 -0
- package/packages/typescript/src/types/generated/eliza/v1/ipc_pb.d.ts +799 -0
- package/packages/typescript/src/types/generated/eliza/v1/ipc_pb.d.ts.map +1 -0
- package/packages/typescript/src/types/generated/eliza/v1/ipc_pb.js +172 -0
- package/packages/typescript/src/types/generated/eliza/v1/knowledge_pb.d.ts +63 -0
- package/packages/typescript/src/types/generated/eliza/v1/knowledge_pb.d.ts.map +1 -0
- package/packages/typescript/src/types/generated/eliza/v1/knowledge_pb.js +18 -0
- package/packages/typescript/src/types/generated/eliza/v1/memory_pb.d.ts +290 -0
- package/packages/typescript/src/types/generated/eliza/v1/memory_pb.d.ts.map +1 -0
- package/packages/typescript/src/types/generated/eliza/v1/memory_pb.js +53 -0
- package/packages/typescript/src/types/generated/eliza/v1/message_service_pb.d.ts +160 -0
- package/packages/typescript/src/types/generated/eliza/v1/message_service_pb.d.ts.map +1 -0
- package/packages/typescript/src/types/generated/eliza/v1/message_service_pb.js +88 -0
- package/packages/typescript/src/types/generated/eliza/v1/messaging_pb.d.ts +214 -0
- package/packages/typescript/src/types/generated/eliza/v1/messaging_pb.d.ts.map +1 -0
- package/packages/typescript/src/types/generated/eliza/v1/messaging_pb.js +78 -0
- package/packages/typescript/src/types/generated/eliza/v1/model_pb.d.ts +653 -0
- package/packages/typescript/src/types/generated/eliza/v1/model_pb.d.ts.map +1 -0
- package/packages/typescript/src/types/generated/eliza/v1/model_pb.js +237 -0
- package/packages/typescript/src/types/generated/eliza/v1/payment_pb.d.ts +147 -0
- package/packages/typescript/src/types/generated/eliza/v1/payment_pb.d.ts.map +1 -0
- package/packages/typescript/src/types/generated/eliza/v1/payment_pb.js +27 -0
- package/packages/typescript/src/types/generated/eliza/v1/plugin_pb.d.ts +286 -0
- package/packages/typescript/src/types/generated/eliza/v1/plugin_pb.d.ts.map +1 -0
- package/packages/typescript/src/types/generated/eliza/v1/plugin_pb.js +86 -0
- package/packages/typescript/src/types/generated/eliza/v1/primitives_pb.d.ts +263 -0
- package/packages/typescript/src/types/generated/eliza/v1/primitives_pb.d.ts.map +1 -0
- package/packages/typescript/src/types/generated/eliza/v1/primitives_pb.js +38 -0
- package/packages/typescript/src/types/generated/eliza/v1/prompts_pb.d.ts +137 -0
- package/packages/typescript/src/types/generated/eliza/v1/prompts_pb.d.ts.map +1 -0
- package/packages/typescript/src/types/generated/eliza/v1/prompts_pb.js +27 -0
- package/packages/typescript/src/types/generated/eliza/v1/service_interfaces_pb.d.ts +2687 -0
- package/packages/typescript/src/types/generated/eliza/v1/service_interfaces_pb.d.ts.map +1 -0
- package/packages/typescript/src/types/generated/eliza/v1/service_interfaces_pb.js +392 -0
- package/packages/typescript/src/types/generated/eliza/v1/service_pb.d.ts +144 -0
- package/packages/typescript/src/types/generated/eliza/v1/service_pb.d.ts.map +1 -0
- package/packages/typescript/src/types/generated/eliza/v1/service_pb.js +99 -0
- package/packages/typescript/src/types/generated/eliza/v1/settings_pb.d.ts +146 -0
- package/packages/typescript/src/types/generated/eliza/v1/settings_pb.d.ts.map +1 -0
- package/packages/typescript/src/types/generated/eliza/v1/settings_pb.js +32 -0
- package/packages/typescript/src/types/generated/eliza/v1/state_pb.d.ts +259 -0
- package/packages/typescript/src/types/generated/eliza/v1/state_pb.d.ts.map +1 -0
- package/packages/typescript/src/types/generated/eliza/v1/state_pb.js +44 -0
- package/packages/typescript/src/types/generated/eliza/v1/task_pb.d.ts +120 -0
- package/packages/typescript/src/types/generated/eliza/v1/task_pb.d.ts.map +1 -0
- package/packages/typescript/src/types/generated/eliza/v1/task_pb.js +53 -0
- package/packages/typescript/src/types/generated/eliza/v1/tee_pb.d.ts +205 -0
- package/packages/typescript/src/types/generated/eliza/v1/tee_pb.d.ts.map +1 -0
- package/packages/typescript/src/types/generated/eliza/v1/tee_pb.js +89 -0
- package/packages/typescript/src/types/generated/eliza/v1/testing_pb.d.ts +47 -0
- package/packages/typescript/src/types/generated/eliza/v1/testing_pb.d.ts.map +1 -0
- package/packages/typescript/src/types/generated/eliza/v1/testing_pb.js +16 -0
- package/packages/typescript/src/types/hook.d.ts +338 -0
- package/packages/typescript/src/types/hook.d.ts.map +1 -0
- package/packages/typescript/src/types/hook.js +73 -0
- package/packages/typescript/src/types/index.d.ts +38 -0
- package/packages/typescript/src/types/index.d.ts.map +1 -0
- package/packages/typescript/src/types/index.js +46 -0
- package/packages/typescript/src/types/knowledge.d.ts +49 -0
- package/packages/typescript/src/types/knowledge.d.ts.map +1 -0
- package/packages/typescript/src/types/knowledge.js +1 -0
- package/packages/typescript/src/types/memory-storage.d.ts +28 -0
- package/packages/typescript/src/types/memory-storage.d.ts.map +1 -0
- package/packages/typescript/src/types/memory-storage.js +13 -0
- package/packages/typescript/src/types/memory.d.ts +438 -0
- package/packages/typescript/src/types/memory.d.ts.map +1 -0
- package/packages/typescript/src/types/memory.js +16 -0
- package/packages/typescript/src/types/message-service.d.ts +169 -0
- package/packages/typescript/src/types/message-service.d.ts.map +1 -0
- package/packages/typescript/src/types/message-service.js +1 -0
- package/packages/typescript/src/types/messaging.d.ts +358 -0
- package/packages/typescript/src/types/messaging.d.ts.map +1 -0
- package/packages/typescript/src/types/messaging.js +27 -0
- package/packages/typescript/src/types/model.d.ts +697 -0
- package/packages/typescript/src/types/model.d.ts.map +1 -0
- package/packages/typescript/src/types/model.js +247 -0
- package/packages/typescript/src/types/onboarding.d.ts +319 -0
- package/packages/typescript/src/types/onboarding.d.ts.map +1 -0
- package/packages/typescript/src/types/onboarding.js +97 -0
- package/packages/typescript/src/types/pairing.d.ts +124 -0
- package/packages/typescript/src/types/pairing.d.ts.map +1 -0
- package/packages/typescript/src/types/pairing.js +32 -0
- package/packages/typescript/src/types/payment.d.ts +45 -0
- package/packages/typescript/src/types/payment.d.ts.map +1 -0
- package/packages/typescript/src/types/payment.js +1 -0
- package/packages/typescript/src/types/plugin-manifest.d.ts +381 -0
- package/packages/typescript/src/types/plugin-manifest.d.ts.map +1 -0
- package/packages/typescript/src/types/plugin-manifest.js +10 -0
- package/packages/typescript/src/types/plugin-store.d.ts +173 -0
- package/packages/typescript/src/types/plugin-store.d.ts.map +1 -0
- package/packages/typescript/src/types/plugin-store.js +1 -0
- package/packages/typescript/src/types/plugin.d.ts +325 -0
- package/packages/typescript/src/types/plugin.d.ts.map +1 -0
- package/packages/typescript/src/types/plugin.js +1 -0
- package/packages/typescript/src/types/primitives.d.ts +176 -0
- package/packages/typescript/src/types/primitives.d.ts.map +1 -0
- package/packages/typescript/src/types/primitives.js +41 -0
- package/packages/typescript/src/types/prompt-batcher.d.ts +126 -0
- package/packages/typescript/src/types/prompt-batcher.d.ts.map +1 -0
- package/packages/typescript/src/types/prompt-batcher.js +6 -0
- package/packages/typescript/src/types/prompts.d.ts +39 -0
- package/packages/typescript/src/types/prompts.d.ts.map +1 -0
- package/packages/typescript/src/types/prompts.js +7 -0
- package/packages/typescript/src/types/proto.d.ts +60 -0
- package/packages/typescript/src/types/proto.d.ts.map +1 -0
- package/packages/typescript/src/types/proto.js +53 -0
- package/packages/typescript/src/types/runtime.d.ts +394 -0
- package/packages/typescript/src/types/runtime.d.ts.map +1 -0
- package/packages/typescript/src/types/runtime.js +1 -0
- package/packages/typescript/src/types/schema-builder.d.ts +43 -0
- package/packages/typescript/src/types/schema-builder.d.ts.map +1 -0
- package/packages/typescript/src/types/schema-builder.js +16 -0
- package/packages/typescript/src/types/schema.d.ts +99 -0
- package/packages/typescript/src/types/schema.d.ts.map +1 -0
- package/packages/typescript/src/types/schema.js +11 -0
- package/packages/typescript/src/types/service-interfaces.d.ts +1200 -0
- package/packages/typescript/src/types/service-interfaces.d.ts.map +1 -0
- package/packages/typescript/src/types/service-interfaces.js +81 -0
- package/packages/typescript/src/types/service.d.ts +173 -0
- package/packages/typescript/src/types/service.d.ts.map +1 -0
- package/packages/typescript/src/types/service.js +78 -0
- package/packages/typescript/src/types/settings.d.ts +36 -0
- package/packages/typescript/src/types/settings.d.ts.map +1 -0
- package/packages/typescript/src/types/settings.js +1 -0
- package/packages/typescript/src/types/state.d.ts +251 -0
- package/packages/typescript/src/types/state.d.ts.map +1 -0
- package/packages/typescript/src/types/state.js +1 -0
- package/packages/typescript/src/types/streaming.d.ts +93 -0
- package/packages/typescript/src/types/streaming.d.ts.map +1 -0
- package/packages/typescript/src/types/streaming.js +21 -0
- package/packages/typescript/src/types/task.d.ts +122 -0
- package/packages/typescript/src/types/task.d.ts.map +1 -0
- package/packages/typescript/src/types/task.js +1 -0
- package/packages/typescript/src/types/tee.d.ts +3 -0
- package/packages/typescript/src/types/tee.d.ts.map +1 -0
- package/packages/typescript/src/types/tee.js +1 -0
- package/packages/typescript/src/types/testing.d.ts +15 -0
- package/packages/typescript/src/types/testing.d.ts.map +1 -0
- package/packages/typescript/src/types/testing.js +1 -0
- package/packages/typescript/src/types/tools.d.ts +166 -0
- package/packages/typescript/src/types/tools.d.ts.map +1 -0
- package/packages/typescript/src/types/tools.js +380 -0
- package/packages/typescript/src/types/trigger.d.ts +38 -0
- package/packages/typescript/src/types/trigger.d.ts.map +1 -0
- package/packages/typescript/src/types/trigger.js +1 -0
- package/packages/typescript/src/utils/batch-queue/batch-processor.d.ts +53 -0
- package/packages/typescript/src/utils/batch-queue/batch-processor.d.ts.map +1 -0
- package/packages/typescript/src/utils/batch-queue/batch-processor.js +129 -0
- package/packages/typescript/src/utils/batch-queue/index.d.ts +97 -0
- package/packages/typescript/src/utils/batch-queue/index.d.ts.map +1 -0
- package/packages/typescript/src/utils/batch-queue/index.js +175 -0
- package/packages/typescript/src/utils/batch-queue/priority-queue.d.ts +53 -0
- package/packages/typescript/src/utils/batch-queue/priority-queue.d.ts.map +1 -0
- package/packages/typescript/src/utils/batch-queue/priority-queue.js +128 -0
- package/packages/typescript/src/utils/batch-queue/semaphore.d.ts +18 -0
- package/packages/typescript/src/utils/batch-queue/semaphore.d.ts.map +1 -0
- package/packages/typescript/src/utils/batch-queue/semaphore.js +34 -0
- package/packages/typescript/src/utils/batch-queue/task-drain.d.ts +57 -0
- package/packages/typescript/src/utils/batch-queue/task-drain.d.ts.map +1 -0
- package/packages/typescript/src/utils/batch-queue/task-drain.js +150 -0
- package/packages/typescript/src/utils/batch-queue.d.ts +20 -0
- package/packages/typescript/src/utils/batch-queue.d.ts.map +1 -0
- package/packages/typescript/src/utils/batch-queue.js +19 -0
- package/packages/typescript/src/utils/boolean.d.ts +50 -0
- package/packages/typescript/src/utils/boolean.d.ts.map +1 -0
- package/packages/typescript/src/utils/boolean.js +73 -0
- package/packages/typescript/src/utils/buffer.d.ts +107 -0
- package/packages/typescript/src/utils/buffer.d.ts.map +1 -0
- package/packages/typescript/src/utils/buffer.js +229 -0
- package/packages/typescript/src/utils/channel-utils.d.ts +274 -0
- package/packages/typescript/src/utils/channel-utils.d.ts.map +1 -0
- package/packages/typescript/src/utils/channel-utils.js +337 -0
- package/packages/typescript/src/utils/context-catalog.d.ts +6 -0
- package/packages/typescript/src/utils/context-catalog.d.ts.map +1 -0
- package/packages/typescript/src/utils/context-catalog.js +126 -0
- package/packages/typescript/src/utils/context-routing.d.ts +25 -0
- package/packages/typescript/src/utils/context-routing.d.ts.map +1 -0
- package/packages/typescript/src/utils/context-routing.js +160 -0
- package/packages/typescript/src/utils/crypto-compat.d.ts +83 -0
- package/packages/typescript/src/utils/crypto-compat.d.ts.map +1 -0
- package/packages/typescript/src/utils/crypto-compat.js +368 -0
- package/packages/typescript/src/utils/deterministic.d.ts +9 -0
- package/packages/typescript/src/utils/deterministic.d.ts.map +1 -0
- package/packages/typescript/src/utils/deterministic.js +70 -0
- package/packages/typescript/src/utils/environment.d.ts +125 -0
- package/packages/typescript/src/utils/environment.d.ts.map +1 -0
- package/packages/typescript/src/utils/environment.js +290 -0
- package/packages/typescript/src/utils/example-names.d.ts +3 -0
- package/packages/typescript/src/utils/example-names.d.ts.map +1 -0
- package/packages/typescript/src/utils/example-names.js +30 -0
- package/packages/typescript/src/utils/json-llm.d.ts +17 -0
- package/packages/typescript/src/utils/json-llm.d.ts.map +1 -0
- package/packages/typescript/src/utils/json-llm.js +32 -0
- package/packages/typescript/src/utils/model-errors.d.ts +3 -0
- package/packages/typescript/src/utils/model-errors.d.ts.map +1 -0
- package/packages/typescript/src/utils/model-errors.js +23 -0
- package/packages/typescript/src/utils/node.d.ts +8 -0
- package/packages/typescript/src/utils/node.d.ts.map +1 -0
- package/packages/typescript/src/utils/node.js +12 -0
- package/packages/typescript/src/utils/paths.d.ts +97 -0
- package/packages/typescript/src/utils/paths.d.ts.map +1 -0
- package/packages/typescript/src/utils/paths.js +204 -0
- package/packages/typescript/src/utils/prompt-batcher/batcher.d.ts +163 -0
- package/packages/typescript/src/utils/prompt-batcher/batcher.d.ts.map +1 -0
- package/packages/typescript/src/utils/prompt-batcher/batcher.js +896 -0
- package/packages/typescript/src/utils/prompt-batcher/dispatcher.d.ts +15 -0
- package/packages/typescript/src/utils/prompt-batcher/dispatcher.d.ts.map +1 -0
- package/packages/typescript/src/utils/prompt-batcher/dispatcher.js +230 -0
- package/packages/typescript/src/utils/prompt-batcher/shared.d.ts +66 -0
- package/packages/typescript/src/utils/prompt-batcher/shared.d.ts.map +1 -0
- package/packages/typescript/src/utils/prompt-batcher/shared.js +101 -0
- package/packages/typescript/src/utils/prompt-batcher.d.ts +5 -0
- package/packages/typescript/src/utils/prompt-batcher.d.ts.map +1 -0
- package/packages/typescript/src/utils/prompt-batcher.js +4 -0
- package/packages/typescript/src/utils/retry.d.ts +128 -0
- package/packages/typescript/src/utils/retry.d.ts.map +1 -0
- package/packages/typescript/src/utils/retry.js +190 -0
- package/packages/typescript/src/utils/server-health.d.ts +35 -0
- package/packages/typescript/src/utils/server-health.d.ts.map +1 -0
- package/packages/typescript/src/utils/server-health.js +76 -0
- package/packages/typescript/src/utils/slice-to-fit-budget.d.ts +12 -0
- package/packages/typescript/src/utils/slice-to-fit-budget.d.ts.map +1 -0
- package/packages/typescript/src/utils/slice-to-fit-budget.js +36 -0
- package/packages/typescript/src/utils/streaming.d.ts +275 -0
- package/packages/typescript/src/utils/streaming.d.ts.map +1 -0
- package/packages/typescript/src/utils/streaming.js +774 -0
- package/packages/typescript/src/utils/text-normalize.d.ts +23 -0
- package/packages/typescript/src/utils/text-normalize.d.ts.map +1 -0
- package/packages/typescript/src/utils/text-normalize.js +42 -0
- package/packages/typescript/src/utils/text-splitting.d.ts +14 -0
- package/packages/typescript/src/utils/text-splitting.d.ts.map +1 -0
- package/packages/typescript/src/utils/text-splitting.js +66 -0
- package/packages/typescript/src/utils/toon.d.ts +8 -0
- package/packages/typescript/src/utils/toon.d.ts.map +1 -0
- package/packages/typescript/src/utils/toon.js +325 -0
- package/packages/typescript/src/utils/type-guards.d.ts +25 -0
- package/packages/typescript/src/utils/type-guards.d.ts.map +1 -0
- package/packages/typescript/src/utils/type-guards.js +73 -0
- package/packages/typescript/src/utils.d.ts +190 -0
- package/packages/typescript/src/utils.d.ts.map +1 -0
- package/packages/typescript/src/utils.js +1115 -0
- package/packages/typescript/src/validation/index.d.ts +8 -0
- package/packages/typescript/src/validation/index.d.ts.map +1 -0
- package/packages/typescript/src/validation/index.js +7 -0
- package/packages/typescript/src/validation/keywords.d.ts +26 -0
- package/packages/typescript/src/validation/keywords.d.ts.map +1 -0
- package/packages/typescript/src/validation/keywords.js +76 -0
- package/packages/typescript/src/validation/secrets.d.ts +94 -0
- package/packages/typescript/src/validation/secrets.d.ts.map +1 -0
- package/packages/typescript/src/validation/secrets.js +399 -0
- package/jest.config.js +0 -17
- package/src/__tests__/client-type-identification.test.ts +0 -59
- package/src/defaultCharacter.ts +0 -530
- package/src/index.ts +0 -865
- package/tsconfig.json +0 -16
|
@@ -0,0 +1,2356 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Swarm Coordinator — Event Bridge & Autonomous Coordination Loop
|
|
3
|
+
*
|
|
4
|
+
* Bridges PTY session events to:
|
|
5
|
+
* 1. SSE clients (frontend dashboard) for real-time status
|
|
6
|
+
* 2. LLM coordination decisions for unhandled blocking prompts
|
|
7
|
+
*
|
|
8
|
+
* The coordinator subscribes to PTYService session events and:
|
|
9
|
+
* - Skips events already handled by auto-response rules (autoResponded=true)
|
|
10
|
+
* - Routes unhandled blocking prompts through supervision levels:
|
|
11
|
+
* - autonomous: LLM decides immediately
|
|
12
|
+
* - confirm: queued for human approval
|
|
13
|
+
* - notify: broadcast only (no action)
|
|
14
|
+
*
|
|
15
|
+
* Heavy logic is extracted into:
|
|
16
|
+
* - swarm-decision-loop.ts (blocked, turn-complete, LLM decisions)
|
|
17
|
+
* - swarm-idle-watchdog.ts (idle session scanning)
|
|
18
|
+
*
|
|
19
|
+
* @module services/swarm-coordinator
|
|
20
|
+
*/
|
|
21
|
+
import { logger } from "@elizaos/core";
|
|
22
|
+
import { buildAgentCredentials } from "./agent-credentials.js";
|
|
23
|
+
import { cleanForFailoverContext, extractDevServerUrl } from "./ansi-utils.js";
|
|
24
|
+
import { normalizeCoordinatorEvent, } from "./coordinator-event-normalizer.js";
|
|
25
|
+
import { normalizeAgentType } from "./pty-types.js";
|
|
26
|
+
import { checkAllTasksComplete, clearDeferredTurnCompleteTimers, executeDecision as execDecision, handleBlocked, handleTurnComplete, } from "./swarm-decision-loop.js";
|
|
27
|
+
import { SwarmHistory } from "./swarm-history.js";
|
|
28
|
+
import { scanIdleSessions } from "./swarm-idle-watchdog.js";
|
|
29
|
+
import { deriveTaskAcceptanceCriteria } from "./task-acceptance.js";
|
|
30
|
+
import { isUsageExhaustedTaskAgentError, markTaskAgentFrameworkHealthy, markTaskAgentFrameworkUnavailable, } from "./task-agent-frameworks.js";
|
|
31
|
+
import { inferTaskThreadKind } from "./task-kind.js";
|
|
32
|
+
import { TaskRegistry, } from "./task-registry.js";
|
|
33
|
+
// ─── Constants ───
|
|
34
|
+
/** Time to buffer events for unregistered sessions (ms). */
|
|
35
|
+
/** Exponential backoff delays for unregistered session buffer retries. */
|
|
36
|
+
const UNREGISTERED_RETRY_DELAYS = [2000, 4000, 8000, 16000];
|
|
37
|
+
/** Absolute maximum wait time before discarding unregistered events. */
|
|
38
|
+
const UNREGISTERED_MAX_TOTAL_MS = 30_000;
|
|
39
|
+
/** Coalesce rapid turn-complete events within this window (ms). */
|
|
40
|
+
const TURN_COMPLETE_COALESCE_MS = 500;
|
|
41
|
+
/** How often the idle watchdog scans for idle sessions (ms). */
|
|
42
|
+
const IDLE_SCAN_INTERVAL_MS = 60 * 1000; // 1 minute
|
|
43
|
+
/** How long to wait before auto-resuming a paused coordinator (ms). */
|
|
44
|
+
const PAUSE_TIMEOUT_MS = 30_000;
|
|
45
|
+
/** Max events to buffer before WS bridge is wired. */
|
|
46
|
+
const MAX_PRE_BRIDGE_BUFFER = 100;
|
|
47
|
+
/** Grace window where a late task_complete can recover a recently-stopped task. */
|
|
48
|
+
const STOPPED_RECOVERY_WINDOW_MS = 90_000;
|
|
49
|
+
const FAILOVER_OUTPUT_MAX_CHARS = 4_000;
|
|
50
|
+
const MAX_AUTOMATIC_ERROR_RECOVERIES = 2;
|
|
51
|
+
const ALTERNATE_FRAMEWORK_ERROR_RE = /\b(auth|login|credential|401|403|unauthorized|forbidden|token|api key|not found|enoent|missing executable|command not found)\b/i;
|
|
52
|
+
function inferProviderSource(framework) {
|
|
53
|
+
if (framework.subscriptionReady) {
|
|
54
|
+
return "subscription";
|
|
55
|
+
}
|
|
56
|
+
if (framework.id === "pi") {
|
|
57
|
+
return framework.installed ? "local-cli" : null;
|
|
58
|
+
}
|
|
59
|
+
return framework.authReady ? "credentials" : null;
|
|
60
|
+
}
|
|
61
|
+
// ─── Service ───
|
|
62
|
+
export class SwarmCoordinator {
|
|
63
|
+
static serviceType = "SWARM_COORDINATOR";
|
|
64
|
+
runtime;
|
|
65
|
+
taskRegistry;
|
|
66
|
+
ptyService = null;
|
|
67
|
+
unsubscribeEvents = null;
|
|
68
|
+
/** Per-session task context. */
|
|
69
|
+
tasks = new Map();
|
|
70
|
+
/** SSE clients receiving live events. */
|
|
71
|
+
sseClients = new Set();
|
|
72
|
+
/** Supervision level (default: autonomous). */
|
|
73
|
+
supervisionLevel = "autonomous";
|
|
74
|
+
/** Pending confirmations for "confirm" mode. */
|
|
75
|
+
pendingDecisions = new Map();
|
|
76
|
+
/** In-flight decision lock — prevents parallel LLM calls for same session. */
|
|
77
|
+
inFlightDecisions = new Set();
|
|
78
|
+
/** Buffered task_complete events that arrived while an in-flight decision was running. */
|
|
79
|
+
pendingTurnComplete = new Map();
|
|
80
|
+
/** Fingerprint of the last blocked prompt per session — for re-render dedup. */
|
|
81
|
+
lastBlockedPromptFingerprint = new Map();
|
|
82
|
+
/** Buffered blocked events that arrived while an in-flight decision was running. */
|
|
83
|
+
pendingBlocked = new Map();
|
|
84
|
+
/** Callback to send chat messages to the user's conversation UI. */
|
|
85
|
+
chatCallback = null;
|
|
86
|
+
/** Callback to relay coordinator events to WebSocket clients. */
|
|
87
|
+
wsBroadcast = null;
|
|
88
|
+
/** Callback to route coordinator events through Milaidy's full pipeline. */
|
|
89
|
+
agentDecisionCb = null;
|
|
90
|
+
/** Callback fired when all swarm tasks complete — for synthesis. */
|
|
91
|
+
swarmCompleteCb = null;
|
|
92
|
+
/** Buffer for events arriving before task registration. */
|
|
93
|
+
unregisteredBuffer = new Map();
|
|
94
|
+
/** Idle watchdog timer handle. */
|
|
95
|
+
idleWatchdogTimer = null;
|
|
96
|
+
/** Last-seen output snapshot per session — used by idle watchdog to detect data flow. */
|
|
97
|
+
lastSeenOutput = new Map();
|
|
98
|
+
/** Timestamp of last tool_running chat notification per session — for throttling. */
|
|
99
|
+
lastToolNotification = new Map();
|
|
100
|
+
/** Whether LLM decisions are paused (user sent a chat message). */
|
|
101
|
+
_paused = false;
|
|
102
|
+
/** Significant decisions shared across the swarm (Layer 2). */
|
|
103
|
+
sharedDecisions = [];
|
|
104
|
+
/** Shared context brief generated during swarm planning phase. */
|
|
105
|
+
_swarmContext = "";
|
|
106
|
+
/** @see SwarmCoordinatorContext.swarmCompleteNotified */
|
|
107
|
+
swarmCompleteNotified = false;
|
|
108
|
+
/** Buffered events during pause — replayed on resume. */
|
|
109
|
+
pauseBuffer = [];
|
|
110
|
+
/** Buffered broadcasts waiting for wsBroadcast to be wired. */
|
|
111
|
+
preBridgeBroadcastBuffer = [];
|
|
112
|
+
/** Auto-resume timeout handle. */
|
|
113
|
+
pauseTimeout = null;
|
|
114
|
+
/** Coordinator startup timestamp — ignore events from sessions created before this. */
|
|
115
|
+
startedAt = Date.now();
|
|
116
|
+
/** Active retry timers for unregistered session buffers. */
|
|
117
|
+
unregisteredRetryTimers = new Map();
|
|
118
|
+
/** Turn-complete coalescing timers — debounces rapid events per session. */
|
|
119
|
+
turnCompleteCoalesceTimers = new Map();
|
|
120
|
+
/** Persistent swarm history — JSONL log that survives restarts. */
|
|
121
|
+
history = new SwarmHistory();
|
|
122
|
+
constructor(runtime) {
|
|
123
|
+
this.runtime = runtime;
|
|
124
|
+
this.taskRegistry = new TaskRegistry(runtime);
|
|
125
|
+
}
|
|
126
|
+
// ─── Chat Callback ───
|
|
127
|
+
/** Inject a callback (from server.ts) to route messages to the user's chat UI. */
|
|
128
|
+
/** Track whether we've already wired the scratch decision callback. */
|
|
129
|
+
scratchDecisionWired = false;
|
|
130
|
+
setChatCallback(cb) {
|
|
131
|
+
this.chatCallback = cb;
|
|
132
|
+
this.log("Chat callback wired");
|
|
133
|
+
// Try wiring scratch decision callback now, retry lazily if service not ready
|
|
134
|
+
this.wireScratchDecisionCallback();
|
|
135
|
+
}
|
|
136
|
+
/**
|
|
137
|
+
* Wire the scratch workspace save prompt callback.
|
|
138
|
+
* Called eagerly from setChatCallback and lazily from handleSessionEvent
|
|
139
|
+
* in case the workspace service wasn't ready at chat-callback time.
|
|
140
|
+
*/
|
|
141
|
+
wireScratchDecisionCallback() {
|
|
142
|
+
if (this.scratchDecisionWired || !this.chatCallback)
|
|
143
|
+
return;
|
|
144
|
+
const wsService = this.runtime.getService("CODING_WORKSPACE_SERVICE");
|
|
145
|
+
if (wsService?.setScratchDecisionCallback) {
|
|
146
|
+
const chatCb = this.chatCallback;
|
|
147
|
+
wsService.setScratchDecisionCallback(async (record) => {
|
|
148
|
+
const ttlNote = record.expiresAt
|
|
149
|
+
? (() => {
|
|
150
|
+
const remainMs = record.expiresAt - Date.now();
|
|
151
|
+
const hours = Math.round(remainMs / (60 * 60 * 1000));
|
|
152
|
+
return hours >= 1
|
|
153
|
+
? `It will be automatically cleaned up in ~${hours} hour${hours === 1 ? "" : "s"}.`
|
|
154
|
+
: `It will be automatically cleaned up shortly.`;
|
|
155
|
+
})()
|
|
156
|
+
: "It will be automatically cleaned up after the configured retention period.";
|
|
157
|
+
await chatCb(`Task "${record.label}" finished. Code is at \`${record.path}\`.\n` +
|
|
158
|
+
`${ttlNote} To keep it, say "keep the workspace" or manage it in Settings -> Task Agents.`, "task-agent");
|
|
159
|
+
});
|
|
160
|
+
this.scratchDecisionWired = true;
|
|
161
|
+
this.log("Scratch decision callback wired");
|
|
162
|
+
}
|
|
163
|
+
}
|
|
164
|
+
/** Inject a callback (from server.ts) to relay events to WebSocket clients. */
|
|
165
|
+
setWsBroadcast(cb) {
|
|
166
|
+
this.wsBroadcast = cb;
|
|
167
|
+
// Replay any events that were broadcast before the bridge was wired
|
|
168
|
+
if (this.preBridgeBroadcastBuffer.length > 0) {
|
|
169
|
+
this.log(`WS broadcast callback wired — replaying ${this.preBridgeBroadcastBuffer.length} buffered event(s)`);
|
|
170
|
+
for (const event of this.preBridgeBroadcastBuffer) {
|
|
171
|
+
cb(event);
|
|
172
|
+
}
|
|
173
|
+
this.preBridgeBroadcastBuffer.length = 0;
|
|
174
|
+
}
|
|
175
|
+
else {
|
|
176
|
+
this.log("WS broadcast callback wired");
|
|
177
|
+
}
|
|
178
|
+
}
|
|
179
|
+
/** Inject a callback fired when all swarm tasks reach terminal state. */
|
|
180
|
+
setSwarmCompleteCallback(cb) {
|
|
181
|
+
this.swarmCompleteCb = cb;
|
|
182
|
+
this.log("Swarm complete callback wired");
|
|
183
|
+
}
|
|
184
|
+
/** Return the swarm complete callback (if wired). */
|
|
185
|
+
getSwarmCompleteCallback() {
|
|
186
|
+
return this.swarmCompleteCb;
|
|
187
|
+
}
|
|
188
|
+
/** Set the shared context brief for this swarm. */
|
|
189
|
+
setSwarmContext(context) {
|
|
190
|
+
this._swarmContext = context;
|
|
191
|
+
this.log(`Swarm context set (${context.length} chars)`);
|
|
192
|
+
}
|
|
193
|
+
/** Return the swarm planning context (if set). */
|
|
194
|
+
getSwarmContext() {
|
|
195
|
+
return this._swarmContext;
|
|
196
|
+
}
|
|
197
|
+
/** Inject a callback (from server.ts) to route events through Milaidy's pipeline. */
|
|
198
|
+
setAgentDecisionCallback(cb) {
|
|
199
|
+
this.agentDecisionCb = cb;
|
|
200
|
+
this.log("Agent decision callback wired — events will route through Milaidy");
|
|
201
|
+
}
|
|
202
|
+
/** Return the agent decision callback (if wired). */
|
|
203
|
+
getAgentDecisionCallback() {
|
|
204
|
+
return this.agentDecisionCb;
|
|
205
|
+
}
|
|
206
|
+
/** Null-safe wrapper — sends a message to the user's conversation if callback is set. */
|
|
207
|
+
sendChatMessage(text, source) {
|
|
208
|
+
if (!this.chatCallback)
|
|
209
|
+
return;
|
|
210
|
+
this.chatCallback(text, source).catch((err) => {
|
|
211
|
+
this.log(`Failed to send chat message: ${err}`);
|
|
212
|
+
});
|
|
213
|
+
}
|
|
214
|
+
// ─── Lifecycle ───
|
|
215
|
+
/**
|
|
216
|
+
* Initialize the coordinator by subscribing to PTY session events.
|
|
217
|
+
* Called from plugin init after services are ready.
|
|
218
|
+
*/
|
|
219
|
+
async start(ptyService) {
|
|
220
|
+
await this.taskRegistry.ensureSchema();
|
|
221
|
+
await this.taskRegistry.recoverInterruptedTasks();
|
|
222
|
+
await this.rehydratePendingDecisions();
|
|
223
|
+
this.ptyService = ptyService;
|
|
224
|
+
this.unsubscribeEvents = ptyService.onNormalizedSessionEvent((normalized) => {
|
|
225
|
+
this.handleNormalizedSessionEvent(normalized).catch((err) => {
|
|
226
|
+
this.log(`Error handling event: ${err}`);
|
|
227
|
+
});
|
|
228
|
+
});
|
|
229
|
+
// Start idle watchdog
|
|
230
|
+
this.idleWatchdogTimer = setInterval(() => {
|
|
231
|
+
scanIdleSessions(this).catch((err) => {
|
|
232
|
+
this.log(`Idle watchdog error: ${err}`);
|
|
233
|
+
});
|
|
234
|
+
}, IDLE_SCAN_INTERVAL_MS);
|
|
235
|
+
this.log("SwarmCoordinator started");
|
|
236
|
+
}
|
|
237
|
+
restorePendingTaskContext(record) {
|
|
238
|
+
const raw = record.taskContext;
|
|
239
|
+
const status = (() => {
|
|
240
|
+
switch (typeof raw.status === "string" ? raw.status : "") {
|
|
241
|
+
case "active":
|
|
242
|
+
case "blocked":
|
|
243
|
+
case "tool_running":
|
|
244
|
+
case "completed":
|
|
245
|
+
case "error":
|
|
246
|
+
case "stopped":
|
|
247
|
+
return raw.status;
|
|
248
|
+
default:
|
|
249
|
+
return "blocked";
|
|
250
|
+
}
|
|
251
|
+
})();
|
|
252
|
+
return {
|
|
253
|
+
threadId: typeof raw.threadId === "string" && raw.threadId.trim().length > 0
|
|
254
|
+
? raw.threadId
|
|
255
|
+
: record.threadId,
|
|
256
|
+
...(typeof raw.taskNodeId === "string" && raw.taskNodeId.trim().length > 0
|
|
257
|
+
? { taskNodeId: raw.taskNodeId }
|
|
258
|
+
: {}),
|
|
259
|
+
sessionId: record.sessionId,
|
|
260
|
+
agentType: typeof raw.agentType === "string" && raw.agentType.trim().length > 0
|
|
261
|
+
? raw.agentType
|
|
262
|
+
: "claude",
|
|
263
|
+
label: typeof raw.label === "string" && raw.label.trim().length > 0
|
|
264
|
+
? raw.label
|
|
265
|
+
: `agent-${record.sessionId.slice(-8)}`,
|
|
266
|
+
originalTask: typeof raw.originalTask === "string"
|
|
267
|
+
? raw.originalTask
|
|
268
|
+
: record.promptText,
|
|
269
|
+
workdir: typeof raw.workdir === "string" ? raw.workdir : "",
|
|
270
|
+
...(typeof raw.repo === "string" && raw.repo.trim().length > 0
|
|
271
|
+
? { repo: raw.repo }
|
|
272
|
+
: {}),
|
|
273
|
+
status,
|
|
274
|
+
decisions: Array.isArray(raw.decisions)
|
|
275
|
+
? raw.decisions.filter((entry) => Boolean(entry && typeof entry === "object"))
|
|
276
|
+
: [],
|
|
277
|
+
autoResolvedCount: typeof raw.autoResolvedCount === "number" ? raw.autoResolvedCount : 0,
|
|
278
|
+
registeredAt: typeof raw.registeredAt === "number"
|
|
279
|
+
? raw.registeredAt
|
|
280
|
+
: record.createdAt,
|
|
281
|
+
lastActivityAt: typeof raw.lastActivityAt === "number"
|
|
282
|
+
? raw.lastActivityAt
|
|
283
|
+
: record.createdAt,
|
|
284
|
+
idleCheckCount: typeof raw.idleCheckCount === "number" ? raw.idleCheckCount : 0,
|
|
285
|
+
taskDelivered: raw.taskDelivered === true,
|
|
286
|
+
...(typeof raw.completionSummary === "string"
|
|
287
|
+
? { completionSummary: raw.completionSummary }
|
|
288
|
+
: {}),
|
|
289
|
+
lastSeenDecisionIndex: typeof raw.lastSeenDecisionIndex === "number"
|
|
290
|
+
? raw.lastSeenDecisionIndex
|
|
291
|
+
: 0,
|
|
292
|
+
...(typeof raw.lastInputSentAt === "number"
|
|
293
|
+
? { lastInputSentAt: raw.lastInputSentAt }
|
|
294
|
+
: {}),
|
|
295
|
+
...(typeof raw.stoppedAt === "number"
|
|
296
|
+
? { stoppedAt: raw.stoppedAt }
|
|
297
|
+
: {}),
|
|
298
|
+
};
|
|
299
|
+
}
|
|
300
|
+
restorePendingLlmDecision(record) {
|
|
301
|
+
const raw = record.llmDecision;
|
|
302
|
+
const action = typeof raw.action === "string" &&
|
|
303
|
+
["respond", "escalate", "ignore", "complete"].includes(raw.action)
|
|
304
|
+
? raw.action
|
|
305
|
+
: "escalate";
|
|
306
|
+
return {
|
|
307
|
+
action,
|
|
308
|
+
...(typeof raw.response === "string" ? { response: raw.response } : {}),
|
|
309
|
+
...(raw.useKeys === true ? { useKeys: true } : {}),
|
|
310
|
+
...(Array.isArray(raw.keys)
|
|
311
|
+
? {
|
|
312
|
+
keys: raw.keys.filter((entry) => typeof entry === "string"),
|
|
313
|
+
}
|
|
314
|
+
: {}),
|
|
315
|
+
reasoning: typeof raw.reasoning === "string" && raw.reasoning.trim().length > 0
|
|
316
|
+
? raw.reasoning
|
|
317
|
+
: "Recovered pending confirmation from persisted coordinator state.",
|
|
318
|
+
};
|
|
319
|
+
}
|
|
320
|
+
async rehydratePendingDecisions() {
|
|
321
|
+
const records = await this.taskRegistry.listPendingDecisions();
|
|
322
|
+
for (const record of records) {
|
|
323
|
+
const taskContext = this.restorePendingTaskContext(record);
|
|
324
|
+
this.tasks.set(record.sessionId, taskContext);
|
|
325
|
+
this.pendingDecisions.set(record.sessionId, {
|
|
326
|
+
sessionId: record.sessionId,
|
|
327
|
+
promptText: record.promptText,
|
|
328
|
+
recentOutput: record.recentOutput,
|
|
329
|
+
llmDecision: this.restorePendingLlmDecision(record),
|
|
330
|
+
taskContext,
|
|
331
|
+
createdAt: record.createdAt,
|
|
332
|
+
});
|
|
333
|
+
}
|
|
334
|
+
}
|
|
335
|
+
async stop() {
|
|
336
|
+
const persistOnShutdown = Array.from(this.tasks.values())
|
|
337
|
+
.filter((task) => task.status === "active" ||
|
|
338
|
+
task.status === "blocked" ||
|
|
339
|
+
task.status === "tool_running")
|
|
340
|
+
.map(async (task) => {
|
|
341
|
+
task.status = "stopped";
|
|
342
|
+
task.stoppedAt = Date.now();
|
|
343
|
+
await this.taskRegistry.updateSession(task.sessionId, {
|
|
344
|
+
status: "interrupted",
|
|
345
|
+
lastActivityAt: task.lastActivityAt,
|
|
346
|
+
idleCheckCount: task.idleCheckCount,
|
|
347
|
+
taskDelivered: task.taskDelivered,
|
|
348
|
+
autoResolvedCount: task.autoResolvedCount,
|
|
349
|
+
decisionCount: task.decisions.length,
|
|
350
|
+
completionSummary: task.completionSummary ?? null,
|
|
351
|
+
lastSeenDecisionIndex: task.lastSeenDecisionIndex,
|
|
352
|
+
lastInputSentAt: task.lastInputSentAt,
|
|
353
|
+
stoppedAt: task.stoppedAt,
|
|
354
|
+
});
|
|
355
|
+
await this.taskRegistry.appendEvent({
|
|
356
|
+
threadId: task.threadId,
|
|
357
|
+
sessionId: task.sessionId,
|
|
358
|
+
eventType: "session_interrupted",
|
|
359
|
+
summary: "Session interrupted during coordinator shutdown",
|
|
360
|
+
data: { reason: "coordinator_shutdown" },
|
|
361
|
+
});
|
|
362
|
+
});
|
|
363
|
+
await Promise.allSettled(persistOnShutdown);
|
|
364
|
+
if (this.idleWatchdogTimer) {
|
|
365
|
+
clearInterval(this.idleWatchdogTimer);
|
|
366
|
+
this.idleWatchdogTimer = null;
|
|
367
|
+
}
|
|
368
|
+
if (this.unsubscribeEvents) {
|
|
369
|
+
this.unsubscribeEvents();
|
|
370
|
+
this.unsubscribeEvents = null;
|
|
371
|
+
}
|
|
372
|
+
// Close all SSE connections
|
|
373
|
+
for (const client of this.sseClients) {
|
|
374
|
+
if (!client.writableEnded) {
|
|
375
|
+
client.end();
|
|
376
|
+
}
|
|
377
|
+
}
|
|
378
|
+
this.sseClients.clear();
|
|
379
|
+
this.tasks.clear();
|
|
380
|
+
this.pendingDecisions.clear();
|
|
381
|
+
this.inFlightDecisions.clear();
|
|
382
|
+
this.pendingTurnComplete.clear();
|
|
383
|
+
clearDeferredTurnCompleteTimers();
|
|
384
|
+
this.lastBlockedPromptFingerprint.clear();
|
|
385
|
+
this.pendingBlocked.clear();
|
|
386
|
+
this.unregisteredBuffer.clear();
|
|
387
|
+
for (const timer of this.unregisteredRetryTimers.values()) {
|
|
388
|
+
clearTimeout(timer);
|
|
389
|
+
}
|
|
390
|
+
this.unregisteredRetryTimers.clear();
|
|
391
|
+
for (const timer of this.turnCompleteCoalesceTimers.values()) {
|
|
392
|
+
clearTimeout(timer);
|
|
393
|
+
}
|
|
394
|
+
this.turnCompleteCoalesceTimers.clear();
|
|
395
|
+
this.lastSeenOutput.clear();
|
|
396
|
+
this.lastToolNotification.clear();
|
|
397
|
+
this.agentDecisionCb = null;
|
|
398
|
+
this.sharedDecisions.length = 0;
|
|
399
|
+
this._swarmContext = "";
|
|
400
|
+
this.swarmCompleteNotified = false;
|
|
401
|
+
// Clear pause state
|
|
402
|
+
this._paused = false;
|
|
403
|
+
if (this.pauseTimeout) {
|
|
404
|
+
clearTimeout(this.pauseTimeout);
|
|
405
|
+
this.pauseTimeout = null;
|
|
406
|
+
}
|
|
407
|
+
this.pauseBuffer = [];
|
|
408
|
+
this.preBridgeBroadcastBuffer.length = 0;
|
|
409
|
+
this.log("SwarmCoordinator stopped");
|
|
410
|
+
}
|
|
411
|
+
// ─── Pause / Resume ───
|
|
412
|
+
/** Whether the coordinator is currently paused. */
|
|
413
|
+
get isPaused() {
|
|
414
|
+
return this._paused;
|
|
415
|
+
}
|
|
416
|
+
/** Pause LLM-based decisions. Auto-responses and broadcasts continue. */
|
|
417
|
+
pause() {
|
|
418
|
+
if (this._paused)
|
|
419
|
+
return;
|
|
420
|
+
this._paused = true;
|
|
421
|
+
this.log("Coordinator paused — buffering LLM decisions until user message is processed");
|
|
422
|
+
this.broadcast({
|
|
423
|
+
type: "coordinator_paused",
|
|
424
|
+
sessionId: "",
|
|
425
|
+
timestamp: Date.now(),
|
|
426
|
+
data: {},
|
|
427
|
+
});
|
|
428
|
+
// Safety: auto-resume after timeout
|
|
429
|
+
this.pauseTimeout = setTimeout(() => {
|
|
430
|
+
if (this._paused) {
|
|
431
|
+
this.log("Coordinator auto-resuming after timeout");
|
|
432
|
+
this.resume();
|
|
433
|
+
}
|
|
434
|
+
}, PAUSE_TIMEOUT_MS);
|
|
435
|
+
}
|
|
436
|
+
/** Resume LLM-based decisions and replay buffered events. */
|
|
437
|
+
resume() {
|
|
438
|
+
if (!this._paused)
|
|
439
|
+
return;
|
|
440
|
+
this._paused = false;
|
|
441
|
+
if (this.pauseTimeout) {
|
|
442
|
+
clearTimeout(this.pauseTimeout);
|
|
443
|
+
this.pauseTimeout = null;
|
|
444
|
+
}
|
|
445
|
+
this.log(`Coordinator resumed — replaying ${this.pauseBuffer.length} buffered events`);
|
|
446
|
+
this.broadcast({
|
|
447
|
+
type: "coordinator_resumed",
|
|
448
|
+
sessionId: "",
|
|
449
|
+
timestamp: Date.now(),
|
|
450
|
+
data: {},
|
|
451
|
+
});
|
|
452
|
+
// Replay buffered events
|
|
453
|
+
const buffered = [...this.pauseBuffer];
|
|
454
|
+
this.pauseBuffer = [];
|
|
455
|
+
for (const entry of buffered) {
|
|
456
|
+
this.handleNormalizedSessionEvent(entry).catch((err) => {
|
|
457
|
+
this.log(`Error replaying buffered event: ${err}`);
|
|
458
|
+
});
|
|
459
|
+
}
|
|
460
|
+
}
|
|
461
|
+
// ─── Task Registration ───
|
|
462
|
+
async registerTask(sessionId, context) {
|
|
463
|
+
const threadId = context.threadId?.trim() || sessionId;
|
|
464
|
+
// Reset swarm state when the first task of a new swarm is registered.
|
|
465
|
+
// Check for terminal-only tasks (all previous tasks in completed/stopped/error)
|
|
466
|
+
// rather than empty map, so reuse without stop() works.
|
|
467
|
+
const allPreviousTerminal = this.tasks.size === 0 ||
|
|
468
|
+
Array.from(this.tasks.values()).every((t) => t.status === "completed" ||
|
|
469
|
+
t.status === "stopped" ||
|
|
470
|
+
t.status === "error");
|
|
471
|
+
if (allPreviousTerminal) {
|
|
472
|
+
this.swarmCompleteNotified = false;
|
|
473
|
+
// Clear stale tasks and shared context from previous swarm
|
|
474
|
+
if (this.tasks.size > 0) {
|
|
475
|
+
this.tasks.clear();
|
|
476
|
+
this.sharedDecisions.length = 0;
|
|
477
|
+
this._swarmContext = "";
|
|
478
|
+
this.log("Cleared stale swarm state for new swarm");
|
|
479
|
+
}
|
|
480
|
+
}
|
|
481
|
+
const taskNodeId = context.taskNodeId?.trim() || `node-${sessionId}`;
|
|
482
|
+
this.tasks.set(sessionId, {
|
|
483
|
+
threadId,
|
|
484
|
+
taskNodeId,
|
|
485
|
+
sessionId,
|
|
486
|
+
agentType: context.agentType,
|
|
487
|
+
label: context.label,
|
|
488
|
+
originalTask: context.originalTask,
|
|
489
|
+
workdir: context.workdir,
|
|
490
|
+
repo: context.repo,
|
|
491
|
+
status: "active",
|
|
492
|
+
decisions: [],
|
|
493
|
+
autoResolvedCount: 0,
|
|
494
|
+
registeredAt: Date.now(),
|
|
495
|
+
lastActivityAt: Date.now(),
|
|
496
|
+
idleCheckCount: 0,
|
|
497
|
+
taskDelivered: false,
|
|
498
|
+
lastSeenDecisionIndex: 0,
|
|
499
|
+
});
|
|
500
|
+
// Persist last used repo so it survives task cleanup
|
|
501
|
+
if (context.repo) {
|
|
502
|
+
this._lastUsedRepo = context.repo;
|
|
503
|
+
}
|
|
504
|
+
// Log to persistent history (fire-and-forget)
|
|
505
|
+
this.history
|
|
506
|
+
.append({
|
|
507
|
+
timestamp: Date.now(),
|
|
508
|
+
type: "task_registered",
|
|
509
|
+
sessionId,
|
|
510
|
+
label: context.label,
|
|
511
|
+
agentType: context.agentType,
|
|
512
|
+
repo: context.repo,
|
|
513
|
+
workdir: context.workdir,
|
|
514
|
+
originalTask: context.originalTask,
|
|
515
|
+
})
|
|
516
|
+
.catch((err) => {
|
|
517
|
+
this.log(`Failed to append task registration history for ${sessionId}: ${err}`);
|
|
518
|
+
});
|
|
519
|
+
const taskCtx = this.tasks.get(sessionId);
|
|
520
|
+
const persistPromise = taskCtx
|
|
521
|
+
? (async () => {
|
|
522
|
+
const existingThread = await this.taskRegistry.getThreadRecord(threadId);
|
|
523
|
+
if (!existingThread) {
|
|
524
|
+
await this.createTaskThread({
|
|
525
|
+
id: threadId,
|
|
526
|
+
title: context.label,
|
|
527
|
+
originalRequest: context.originalTask,
|
|
528
|
+
metadata: {
|
|
529
|
+
repo: context.repo ?? null,
|
|
530
|
+
source: "register-task-fallback",
|
|
531
|
+
},
|
|
532
|
+
});
|
|
533
|
+
}
|
|
534
|
+
const existingNode = await this.taskRegistry.getTaskNode(taskNodeId);
|
|
535
|
+
if (!existingNode) {
|
|
536
|
+
await this.taskRegistry.createTaskNode({
|
|
537
|
+
id: taskNodeId,
|
|
538
|
+
threadId: taskCtx.threadId,
|
|
539
|
+
kind: "execution",
|
|
540
|
+
status: "running",
|
|
541
|
+
title: context.label,
|
|
542
|
+
instructions: context.originalTask,
|
|
543
|
+
requiredCapabilities: [context.agentType],
|
|
544
|
+
assignedSessionId: sessionId,
|
|
545
|
+
assignedLabel: context.label,
|
|
546
|
+
agentType: context.agentType,
|
|
547
|
+
workdir: context.workdir,
|
|
548
|
+
repo: context.repo,
|
|
549
|
+
createdFrom: context.taskNodeId
|
|
550
|
+
? "register-task-existing-node"
|
|
551
|
+
: "register-task-fallback",
|
|
552
|
+
metadata: {
|
|
553
|
+
providerSource: context.providerSource ?? null,
|
|
554
|
+
},
|
|
555
|
+
});
|
|
556
|
+
}
|
|
557
|
+
else if (existingNode.threadId !== taskCtx.threadId) {
|
|
558
|
+
throw new Error(`Task node ${taskNodeId} belongs to ${existingNode.threadId}, expected ${taskCtx.threadId}`);
|
|
559
|
+
}
|
|
560
|
+
await Promise.all([
|
|
561
|
+
this.taskRegistry.registerSession({
|
|
562
|
+
threadId: taskCtx.threadId,
|
|
563
|
+
sessionId,
|
|
564
|
+
framework: context.agentType,
|
|
565
|
+
providerSource: context.providerSource,
|
|
566
|
+
label: context.label,
|
|
567
|
+
originalTask: context.originalTask,
|
|
568
|
+
workdir: context.workdir,
|
|
569
|
+
repo: context.repo,
|
|
570
|
+
status: "active",
|
|
571
|
+
decisionCount: 0,
|
|
572
|
+
autoResolvedCount: 0,
|
|
573
|
+
registeredAt: taskCtx.registeredAt,
|
|
574
|
+
lastActivityAt: taskCtx.lastActivityAt,
|
|
575
|
+
idleCheckCount: taskCtx.idleCheckCount,
|
|
576
|
+
taskDelivered: false,
|
|
577
|
+
lastSeenDecisionIndex: 0,
|
|
578
|
+
metadata: {
|
|
579
|
+
...(context.metadata ?? {}),
|
|
580
|
+
taskNodeId,
|
|
581
|
+
},
|
|
582
|
+
}),
|
|
583
|
+
this.taskRegistry.updateTaskNode(taskNodeId, {
|
|
584
|
+
status: "running",
|
|
585
|
+
title: context.label,
|
|
586
|
+
instructions: context.originalTask,
|
|
587
|
+
assignedSessionId: sessionId,
|
|
588
|
+
assignedLabel: context.label,
|
|
589
|
+
agentType: context.agentType,
|
|
590
|
+
workdir: context.workdir,
|
|
591
|
+
repo: context.repo,
|
|
592
|
+
metadata: {
|
|
593
|
+
providerSource: context.providerSource ?? null,
|
|
594
|
+
},
|
|
595
|
+
}),
|
|
596
|
+
this.taskRegistry.createTaskClaim({
|
|
597
|
+
threadId,
|
|
598
|
+
nodeId: taskNodeId,
|
|
599
|
+
sessionId,
|
|
600
|
+
claimType: "execution",
|
|
601
|
+
status: "active",
|
|
602
|
+
metadata: {
|
|
603
|
+
label: context.label,
|
|
604
|
+
},
|
|
605
|
+
}),
|
|
606
|
+
this.taskRegistry.appendEvent({
|
|
607
|
+
threadId,
|
|
608
|
+
sessionId,
|
|
609
|
+
eventType: "task_registered",
|
|
610
|
+
timestamp: Date.now(),
|
|
611
|
+
summary: `Registered task "${context.label}"`,
|
|
612
|
+
data: {
|
|
613
|
+
label: context.label,
|
|
614
|
+
originalTask: context.originalTask,
|
|
615
|
+
repo: context.repo ?? null,
|
|
616
|
+
taskNodeId,
|
|
617
|
+
},
|
|
618
|
+
}),
|
|
619
|
+
]);
|
|
620
|
+
})()
|
|
621
|
+
: Promise.resolve();
|
|
622
|
+
void persistPromise.catch((err) => {
|
|
623
|
+
this.log(`Failed to persist task registration for ${sessionId}: ${err}`);
|
|
624
|
+
});
|
|
625
|
+
this.broadcast({
|
|
626
|
+
type: "task_registered",
|
|
627
|
+
sessionId,
|
|
628
|
+
timestamp: Date.now(),
|
|
629
|
+
data: {
|
|
630
|
+
agentType: context.agentType,
|
|
631
|
+
label: context.label,
|
|
632
|
+
originalTask: context.originalTask,
|
|
633
|
+
},
|
|
634
|
+
});
|
|
635
|
+
// Cancel any pending retry timer and flush buffered events
|
|
636
|
+
const retryTimer = this.unregisteredRetryTimers.get(sessionId);
|
|
637
|
+
if (retryTimer) {
|
|
638
|
+
clearTimeout(retryTimer);
|
|
639
|
+
this.unregisteredRetryTimers.delete(sessionId);
|
|
640
|
+
}
|
|
641
|
+
const buffered = this.unregisteredBuffer.get(sessionId);
|
|
642
|
+
if (buffered) {
|
|
643
|
+
this.unregisteredBuffer.delete(sessionId);
|
|
644
|
+
for (const entry of buffered) {
|
|
645
|
+
this.handleNormalizedSessionEvent(entry.normalized).catch((err) => {
|
|
646
|
+
this.log(`Error replaying buffered event: ${err}`);
|
|
647
|
+
});
|
|
648
|
+
}
|
|
649
|
+
}
|
|
650
|
+
await persistPromise;
|
|
651
|
+
}
|
|
652
|
+
/**
|
|
653
|
+
* Return the repo URL from the most recently registered task that had one.
|
|
654
|
+
* Useful as a fallback when the user says "in the same repo" without a URL.
|
|
655
|
+
*/
|
|
656
|
+
/**
|
|
657
|
+
* Persisted separately from tasks so it survives task cleanup.
|
|
658
|
+
* Updated whenever a task with a repo is registered.
|
|
659
|
+
*/
|
|
660
|
+
_lastUsedRepo;
|
|
661
|
+
getLastUsedRepo() {
|
|
662
|
+
// Check active tasks first (freshest), fall back to in-memory persisted value
|
|
663
|
+
let latest;
|
|
664
|
+
for (const task of this.tasks.values()) {
|
|
665
|
+
if (task.repo && (!latest || task.registeredAt > latest.registeredAt)) {
|
|
666
|
+
latest = task;
|
|
667
|
+
}
|
|
668
|
+
}
|
|
669
|
+
return latest?.repo ?? this._lastUsedRepo;
|
|
670
|
+
}
|
|
671
|
+
/**
|
|
672
|
+
* Async version that also checks disk history — survives process restarts.
|
|
673
|
+
* Callers that can await should prefer this over the sync version.
|
|
674
|
+
*/
|
|
675
|
+
async getLastUsedRepoAsync() {
|
|
676
|
+
const memoryRepo = this.getLastUsedRepo();
|
|
677
|
+
if (memoryRepo)
|
|
678
|
+
return memoryRepo;
|
|
679
|
+
try {
|
|
680
|
+
return ((await this.taskRegistry.getLastUsedRepo()) ??
|
|
681
|
+
(await this.history.getLastUsedRepo()));
|
|
682
|
+
}
|
|
683
|
+
catch {
|
|
684
|
+
return undefined;
|
|
685
|
+
}
|
|
686
|
+
}
|
|
687
|
+
getTaskContext(sessionId) {
|
|
688
|
+
return this.tasks.get(sessionId);
|
|
689
|
+
}
|
|
690
|
+
mapDecisionRecord(record) {
|
|
691
|
+
return {
|
|
692
|
+
timestamp: record.timestamp,
|
|
693
|
+
event: record.event,
|
|
694
|
+
promptText: record.promptText,
|
|
695
|
+
decision: record.decision,
|
|
696
|
+
...(record.response ? { response: record.response } : {}),
|
|
697
|
+
reasoning: record.reasoning,
|
|
698
|
+
};
|
|
699
|
+
}
|
|
700
|
+
mapSessionStatus(status) {
|
|
701
|
+
switch (status) {
|
|
702
|
+
case "blocked":
|
|
703
|
+
case "waiting_on_user":
|
|
704
|
+
return "blocked";
|
|
705
|
+
case "tool_running":
|
|
706
|
+
return "tool_running";
|
|
707
|
+
case "completed":
|
|
708
|
+
return "completed";
|
|
709
|
+
case "error":
|
|
710
|
+
return "error";
|
|
711
|
+
case "stopped":
|
|
712
|
+
case "interrupted":
|
|
713
|
+
return "stopped";
|
|
714
|
+
default:
|
|
715
|
+
return "active";
|
|
716
|
+
}
|
|
717
|
+
}
|
|
718
|
+
mapTaskContextStatusToNodeStatus(status) {
|
|
719
|
+
switch (status) {
|
|
720
|
+
case "blocked":
|
|
721
|
+
return "blocked";
|
|
722
|
+
case "completed":
|
|
723
|
+
return "completed";
|
|
724
|
+
case "error":
|
|
725
|
+
return "failed";
|
|
726
|
+
case "stopped":
|
|
727
|
+
return "interrupted";
|
|
728
|
+
case "tool_running":
|
|
729
|
+
return "running";
|
|
730
|
+
default:
|
|
731
|
+
return "running";
|
|
732
|
+
}
|
|
733
|
+
}
|
|
734
|
+
buildTaskContextFromSession(session, decisions) {
|
|
735
|
+
return {
|
|
736
|
+
threadId: session.threadId,
|
|
737
|
+
...(typeof session.metadata.taskNodeId === "string" &&
|
|
738
|
+
session.metadata.taskNodeId.trim().length > 0
|
|
739
|
+
? { taskNodeId: session.metadata.taskNodeId }
|
|
740
|
+
: {}),
|
|
741
|
+
sessionId: session.sessionId,
|
|
742
|
+
agentType: session.framework,
|
|
743
|
+
label: session.label,
|
|
744
|
+
originalTask: session.originalTask,
|
|
745
|
+
workdir: session.workdir,
|
|
746
|
+
...(session.repo ? { repo: session.repo } : {}),
|
|
747
|
+
status: this.mapSessionStatus(session.status),
|
|
748
|
+
decisions: decisions.map((decision) => this.mapDecisionRecord(decision)),
|
|
749
|
+
autoResolvedCount: session.autoResolvedCount,
|
|
750
|
+
registeredAt: session.registeredAt,
|
|
751
|
+
lastActivityAt: session.lastActivityAt,
|
|
752
|
+
idleCheckCount: session.idleCheckCount,
|
|
753
|
+
taskDelivered: session.taskDelivered,
|
|
754
|
+
...(session.completionSummary
|
|
755
|
+
? { completionSummary: session.completionSummary }
|
|
756
|
+
: {}),
|
|
757
|
+
lastSeenDecisionIndex: session.lastSeenDecisionIndex,
|
|
758
|
+
...(session.lastInputSentAt !== null
|
|
759
|
+
? { lastInputSentAt: session.lastInputSentAt }
|
|
760
|
+
: {}),
|
|
761
|
+
...(session.stoppedAt !== null ? { stoppedAt: session.stoppedAt } : {}),
|
|
762
|
+
};
|
|
763
|
+
}
|
|
764
|
+
async getTaskContextSnapshot(sessionId) {
|
|
765
|
+
const live = this.tasks.get(sessionId);
|
|
766
|
+
if (live)
|
|
767
|
+
return live;
|
|
768
|
+
const session = await this.taskRegistry.getSession(sessionId);
|
|
769
|
+
if (!session)
|
|
770
|
+
return null;
|
|
771
|
+
const decisions = await this.taskRegistry.listDecisionsForSession(sessionId);
|
|
772
|
+
return this.buildTaskContextFromSession(session, decisions);
|
|
773
|
+
}
|
|
774
|
+
getAllTaskContexts() {
|
|
775
|
+
return Array.from(this.tasks.values());
|
|
776
|
+
}
|
|
777
|
+
async createTaskThread(input) {
|
|
778
|
+
const normalizedInput = {
|
|
779
|
+
...input,
|
|
780
|
+
kind: inferTaskThreadKind(input),
|
|
781
|
+
};
|
|
782
|
+
const acceptance = await deriveTaskAcceptanceCriteria(this.runtime, normalizedInput);
|
|
783
|
+
const thread = await this.taskRegistry.createThread({
|
|
784
|
+
...normalizedInput,
|
|
785
|
+
acceptanceCriteria: acceptance.criteria,
|
|
786
|
+
metadata: {
|
|
787
|
+
...(normalizedInput.metadata ?? {}),
|
|
788
|
+
acceptanceCriteriaSource: acceptance.source,
|
|
789
|
+
},
|
|
790
|
+
});
|
|
791
|
+
const summary = await this.taskRegistry.getThreadSummary(thread.id);
|
|
792
|
+
if (!summary) {
|
|
793
|
+
throw new Error(`Failed to load task thread ${thread.id}`);
|
|
794
|
+
}
|
|
795
|
+
return summary;
|
|
796
|
+
}
|
|
797
|
+
async planTaskThreadGraph(input) {
|
|
798
|
+
const thread = await this.taskRegistry.getThreadRecord(input.threadId);
|
|
799
|
+
if (!thread) {
|
|
800
|
+
throw new Error(`Task thread ${input.threadId} not found`);
|
|
801
|
+
}
|
|
802
|
+
const rootNode = await this.taskRegistry.createTaskNode({
|
|
803
|
+
threadId: input.threadId,
|
|
804
|
+
parentNodeId: null,
|
|
805
|
+
kind: "goal",
|
|
806
|
+
status: "planned",
|
|
807
|
+
title: input.title,
|
|
808
|
+
instructions: input.originalRequest,
|
|
809
|
+
acceptanceCriteria: thread.acceptanceCriteria,
|
|
810
|
+
priority: 100,
|
|
811
|
+
depth: 0,
|
|
812
|
+
sequence: 0,
|
|
813
|
+
createdFrom: "planner",
|
|
814
|
+
metadata: {
|
|
815
|
+
threadKind: thread.kind,
|
|
816
|
+
source: "swarm-planner",
|
|
817
|
+
},
|
|
818
|
+
});
|
|
819
|
+
// The acceptance verifier is a code-completion safety check: it asks the
|
|
820
|
+
// LLM whether file/test evidence in the workspace matches the criteria,
|
|
821
|
+
// catching agents that lie about completing code work. It's only useful
|
|
822
|
+
// when there is real artifact evidence to verify (a repo) AND real
|
|
823
|
+
// criteria to check against (provided or model-generated, not the
|
|
824
|
+
// baseline placeholder fallback). For chat / question-answering tasks
|
|
825
|
+
// (no repo, response IS the deliverable) the verifier produces false
|
|
826
|
+
// failures because there are no files to inspect.
|
|
827
|
+
const acceptanceCriteriaSource = typeof thread.metadata?.acceptanceCriteriaSource === "string"
|
|
828
|
+
? thread.metadata.acceptanceCriteriaSource
|
|
829
|
+
: null;
|
|
830
|
+
const hasRepo = typeof thread.metadata?.repo === "string" &&
|
|
831
|
+
thread.metadata.repo.trim().length > 0;
|
|
832
|
+
if (thread.acceptanceCriteria.length > 0 &&
|
|
833
|
+
acceptanceCriteriaSource !== "baseline" &&
|
|
834
|
+
hasRepo) {
|
|
835
|
+
await this.taskRegistry.createTaskVerifierJob({
|
|
836
|
+
threadId: input.threadId,
|
|
837
|
+
nodeId: rootNode.id,
|
|
838
|
+
status: "pending",
|
|
839
|
+
verifierType: "acceptance_criteria",
|
|
840
|
+
title: `Verify acceptance criteria for ${input.title}`,
|
|
841
|
+
instructions: thread.acceptanceCriteria.join("\n"),
|
|
842
|
+
config: {
|
|
843
|
+
acceptanceCriteria: thread.acceptanceCriteria,
|
|
844
|
+
},
|
|
845
|
+
metadata: {
|
|
846
|
+
source: "thread-acceptance",
|
|
847
|
+
},
|
|
848
|
+
});
|
|
849
|
+
}
|
|
850
|
+
if (input.sharedContext?.trim()) {
|
|
851
|
+
await this.taskRegistry.appendTaskMailboxMessage({
|
|
852
|
+
threadId: input.threadId,
|
|
853
|
+
nodeId: rootNode.id,
|
|
854
|
+
sender: "planner",
|
|
855
|
+
recipient: "all-workers",
|
|
856
|
+
subject: "shared-context",
|
|
857
|
+
body: input.sharedContext.trim(),
|
|
858
|
+
deliveryState: "delivered",
|
|
859
|
+
deliveredAt: new Date().toISOString(),
|
|
860
|
+
metadata: {
|
|
861
|
+
source: "swarm-planner",
|
|
862
|
+
},
|
|
863
|
+
});
|
|
864
|
+
}
|
|
865
|
+
const workerNodes = [];
|
|
866
|
+
for (const [index, subtask] of input.subtasks.entries()) {
|
|
867
|
+
const node = await this.taskRegistry.createTaskNode({
|
|
868
|
+
threadId: input.threadId,
|
|
869
|
+
parentNodeId: rootNode.id,
|
|
870
|
+
kind: "execution",
|
|
871
|
+
status: "ready",
|
|
872
|
+
title: subtask.label,
|
|
873
|
+
instructions: subtask.originalTask,
|
|
874
|
+
requiredCapabilities: [subtask.agentType],
|
|
875
|
+
repo: subtask.repo,
|
|
876
|
+
priority: 10,
|
|
877
|
+
depth: 1,
|
|
878
|
+
sequence: index + 1,
|
|
879
|
+
createdFrom: "planner",
|
|
880
|
+
metadata: {
|
|
881
|
+
agentType: subtask.agentType,
|
|
882
|
+
source: "swarm-planner",
|
|
883
|
+
},
|
|
884
|
+
});
|
|
885
|
+
await this.taskRegistry.createTaskDependency({
|
|
886
|
+
threadId: input.threadId,
|
|
887
|
+
fromNodeId: node.id,
|
|
888
|
+
toNodeId: rootNode.id,
|
|
889
|
+
dependencyKind: "parent_child",
|
|
890
|
+
requiredStatus: "completed",
|
|
891
|
+
metadata: {
|
|
892
|
+
source: "swarm-planner",
|
|
893
|
+
},
|
|
894
|
+
});
|
|
895
|
+
if (input.sharedContext?.trim()) {
|
|
896
|
+
await this.taskRegistry.appendTaskMailboxMessage({
|
|
897
|
+
threadId: input.threadId,
|
|
898
|
+
nodeId: node.id,
|
|
899
|
+
sender: "planner",
|
|
900
|
+
recipient: subtask.label,
|
|
901
|
+
subject: "task-brief",
|
|
902
|
+
body: input.sharedContext.trim(),
|
|
903
|
+
deliveryState: "delivered",
|
|
904
|
+
deliveredAt: new Date().toISOString(),
|
|
905
|
+
metadata: {
|
|
906
|
+
task: subtask.originalTask,
|
|
907
|
+
agentType: subtask.agentType,
|
|
908
|
+
},
|
|
909
|
+
});
|
|
910
|
+
}
|
|
911
|
+
workerNodes.push(node);
|
|
912
|
+
}
|
|
913
|
+
await this.taskRegistry.updateThread(input.threadId, {
|
|
914
|
+
currentPlan: {
|
|
915
|
+
...thread.currentPlan,
|
|
916
|
+
rootTaskNodeId: rootNode.id,
|
|
917
|
+
taskNodeIds: workerNodes.map((node) => node.id),
|
|
918
|
+
taskNodeCount: workerNodes.length + 1,
|
|
919
|
+
},
|
|
920
|
+
});
|
|
921
|
+
return { rootNode, workerNodes };
|
|
922
|
+
}
|
|
923
|
+
async listTaskThreads(options) {
|
|
924
|
+
return this.taskRegistry.listThreads(options);
|
|
925
|
+
}
|
|
926
|
+
async getTaskThread(threadId) {
|
|
927
|
+
return this.taskRegistry.getThread(threadId);
|
|
928
|
+
}
|
|
929
|
+
async archiveTaskThread(threadId) {
|
|
930
|
+
await this.taskRegistry.archiveThread(threadId);
|
|
931
|
+
}
|
|
932
|
+
async reopenTaskThread(threadId) {
|
|
933
|
+
await this.taskRegistry.reopenThread(threadId);
|
|
934
|
+
}
|
|
935
|
+
async countTaskThreads(options) {
|
|
936
|
+
return this.taskRegistry.countThreads(options);
|
|
937
|
+
}
|
|
938
|
+
getLiveTaskContextsForThread(threadId) {
|
|
939
|
+
return Array.from(this.tasks.values())
|
|
940
|
+
.filter((task) => task.threadId === threadId)
|
|
941
|
+
.sort((left, right) => right.lastActivityAt - left.lastActivityAt);
|
|
942
|
+
}
|
|
943
|
+
async stopLiveThreadSessions(threadId, force) {
|
|
944
|
+
if (!this.ptyService) {
|
|
945
|
+
return [];
|
|
946
|
+
}
|
|
947
|
+
const sessionIds = this.getLiveTaskContextsForThread(threadId)
|
|
948
|
+
.filter((task) => task.status === "active" ||
|
|
949
|
+
task.status === "blocked" ||
|
|
950
|
+
task.status === "tool_running")
|
|
951
|
+
.map((task) => task.sessionId);
|
|
952
|
+
for (const sessionId of sessionIds) {
|
|
953
|
+
const taskCtx = this.tasks.get(sessionId);
|
|
954
|
+
if (taskCtx) {
|
|
955
|
+
taskCtx.status = "stopped";
|
|
956
|
+
taskCtx.stoppedAt = Date.now();
|
|
957
|
+
await this.syncTaskContext(taskCtx);
|
|
958
|
+
}
|
|
959
|
+
try {
|
|
960
|
+
await this.ptyService.stopSession(sessionId, force);
|
|
961
|
+
}
|
|
962
|
+
catch (error) {
|
|
963
|
+
this.log(`Failed to stop session ${sessionId} for thread ${threadId}: ${error instanceof Error ? error.message : String(error)}`);
|
|
964
|
+
}
|
|
965
|
+
}
|
|
966
|
+
return sessionIds;
|
|
967
|
+
}
|
|
968
|
+
clipText(value, limit) {
|
|
969
|
+
if (value.length <= limit)
|
|
970
|
+
return value;
|
|
971
|
+
return `${value.slice(0, limit)}…`;
|
|
972
|
+
}
|
|
973
|
+
formatResumePrompt(thread, instruction) {
|
|
974
|
+
const acceptanceCriteria = (thread.acceptanceCriteria ?? [])
|
|
975
|
+
.map((item) => `- ${item}`)
|
|
976
|
+
.join("\n");
|
|
977
|
+
const recentDecisions = (thread.decisions ?? [])
|
|
978
|
+
.slice(-6)
|
|
979
|
+
.map((decision, index) => `${index + 1}. ${decision.event}: ${decision.reasoning}${decision.response ? ` (response: ${decision.response})` : ""}`)
|
|
980
|
+
.join("\n");
|
|
981
|
+
const recentEvents = (thread.events ?? [])
|
|
982
|
+
.slice(-8)
|
|
983
|
+
.map((event, index) => `${index + 1}. ${event.eventType}: ${this.clipText(event.summary, 180)}`)
|
|
984
|
+
.join("\n");
|
|
985
|
+
const transcriptExcerpt = (thread.transcripts ?? [])
|
|
986
|
+
.slice(-20)
|
|
987
|
+
.map((entry) => `${entry.direction.toUpperCase()}: ${this.clipText(entry.content.trim(), 220)}`)
|
|
988
|
+
.filter((line) => line.length > 0)
|
|
989
|
+
.join("\n");
|
|
990
|
+
const latestSession = (thread.sessions ?? [])
|
|
991
|
+
.slice()
|
|
992
|
+
.sort((left, right) => right.lastActivityAt - left.lastActivityAt)[0];
|
|
993
|
+
return [
|
|
994
|
+
"Resume an existing Eliza coordinator task thread.",
|
|
995
|
+
"",
|
|
996
|
+
`Thread: ${thread.title}`,
|
|
997
|
+
`Original request: ${thread.originalRequest}`,
|
|
998
|
+
latestSession?.workdir ? `Workspace: ${latestSession.workdir}` : "",
|
|
999
|
+
latestSession?.repo ? `Repository: ${latestSession.repo}` : "",
|
|
1000
|
+
thread.summary ? `Current summary: ${thread.summary}` : "",
|
|
1001
|
+
acceptanceCriteria ? `Acceptance criteria:\n${acceptanceCriteria}` : "",
|
|
1002
|
+
instruction?.trim()
|
|
1003
|
+
? `Latest user instruction:\n${instruction.trim()}`
|
|
1004
|
+
: "Continue from the current workspace state without starting over.",
|
|
1005
|
+
recentDecisions
|
|
1006
|
+
? `Recent coordinator decisions:\n${recentDecisions}`
|
|
1007
|
+
: "",
|
|
1008
|
+
recentEvents ? `Recent task events:\n${recentEvents}` : "",
|
|
1009
|
+
transcriptExcerpt
|
|
1010
|
+
? `Recent transcript excerpt:\n${transcriptExcerpt}`
|
|
1011
|
+
: "",
|
|
1012
|
+
"Inspect the current workspace, continue the task, run the relevant verification, and summarize what changed.",
|
|
1013
|
+
]
|
|
1014
|
+
.filter(Boolean)
|
|
1015
|
+
.join("\n\n");
|
|
1016
|
+
}
|
|
1017
|
+
async pauseTaskThread(threadId, note) {
|
|
1018
|
+
const thread = await this.getTaskThread(threadId);
|
|
1019
|
+
if (!thread) {
|
|
1020
|
+
throw new Error(`Task thread ${threadId} not found`);
|
|
1021
|
+
}
|
|
1022
|
+
const stoppedSessionIds = await this.stopLiveThreadSessions(threadId, true);
|
|
1023
|
+
const nowIso = new Date().toISOString();
|
|
1024
|
+
await this.taskRegistry.updateThread(threadId, {
|
|
1025
|
+
status: "waiting_on_user",
|
|
1026
|
+
closedAt: null,
|
|
1027
|
+
lastCoordinatorTurnAt: nowIso,
|
|
1028
|
+
metadata: {
|
|
1029
|
+
controlState: "paused",
|
|
1030
|
+
pauseNote: note ?? null,
|
|
1031
|
+
pauseRequestedAt: nowIso,
|
|
1032
|
+
},
|
|
1033
|
+
});
|
|
1034
|
+
await this.taskRegistry.appendEvent({
|
|
1035
|
+
threadId,
|
|
1036
|
+
eventType: "task_paused",
|
|
1037
|
+
summary: note?.trim()
|
|
1038
|
+
? `Paused task thread: ${note.trim()}`
|
|
1039
|
+
: "Paused task thread for user review",
|
|
1040
|
+
data: {
|
|
1041
|
+
note: note ?? null,
|
|
1042
|
+
stoppedSessionIds,
|
|
1043
|
+
},
|
|
1044
|
+
});
|
|
1045
|
+
return { threadId, stoppedSessionIds };
|
|
1046
|
+
}
|
|
1047
|
+
async stopTaskThread(threadId, note) {
|
|
1048
|
+
const thread = await this.getTaskThread(threadId);
|
|
1049
|
+
if (!thread) {
|
|
1050
|
+
throw new Error(`Task thread ${threadId} not found`);
|
|
1051
|
+
}
|
|
1052
|
+
const stoppedSessionIds = await this.stopLiveThreadSessions(threadId, true);
|
|
1053
|
+
const nowIso = new Date().toISOString();
|
|
1054
|
+
await this.taskRegistry.updateThread(threadId, {
|
|
1055
|
+
status: "interrupted",
|
|
1056
|
+
closedAt: nowIso,
|
|
1057
|
+
lastCoordinatorTurnAt: nowIso,
|
|
1058
|
+
metadata: {
|
|
1059
|
+
controlState: "stopped",
|
|
1060
|
+
stopNote: note ?? null,
|
|
1061
|
+
stoppedByUserAt: nowIso,
|
|
1062
|
+
},
|
|
1063
|
+
});
|
|
1064
|
+
await this.taskRegistry.appendEvent({
|
|
1065
|
+
threadId,
|
|
1066
|
+
eventType: "task_stopped",
|
|
1067
|
+
summary: note?.trim()
|
|
1068
|
+
? `Stopped task thread: ${note.trim()}`
|
|
1069
|
+
: "Stopped task thread at user request",
|
|
1070
|
+
data: {
|
|
1071
|
+
note: note ?? null,
|
|
1072
|
+
stoppedSessionIds,
|
|
1073
|
+
},
|
|
1074
|
+
});
|
|
1075
|
+
return { threadId, stoppedSessionIds };
|
|
1076
|
+
}
|
|
1077
|
+
async resumeTaskThread(threadId, instruction, agentType) {
|
|
1078
|
+
const thread = await this.getTaskThread(threadId);
|
|
1079
|
+
if (!thread) {
|
|
1080
|
+
throw new Error(`Task thread ${threadId} not found`);
|
|
1081
|
+
}
|
|
1082
|
+
if (!this.ptyService) {
|
|
1083
|
+
throw new Error("PTY Service is not available");
|
|
1084
|
+
}
|
|
1085
|
+
const activeTask = this.getLiveTaskContextsForThread(threadId).find((task) => task.status !== "stopped" &&
|
|
1086
|
+
task.status !== "completed" &&
|
|
1087
|
+
task.status !== "error");
|
|
1088
|
+
if (activeTask) {
|
|
1089
|
+
if (instruction?.trim()) {
|
|
1090
|
+
await this.ptyService.sendToSession(activeTask.sessionId, instruction.trim());
|
|
1091
|
+
activeTask.lastInputSentAt = Date.now();
|
|
1092
|
+
activeTask.status = "active";
|
|
1093
|
+
await this.syncTaskContext(activeTask);
|
|
1094
|
+
}
|
|
1095
|
+
const nowIso = new Date().toISOString();
|
|
1096
|
+
await this.taskRegistry.updateThread(threadId, {
|
|
1097
|
+
status: "active",
|
|
1098
|
+
closedAt: null,
|
|
1099
|
+
lastCoordinatorTurnAt: nowIso,
|
|
1100
|
+
metadata: {
|
|
1101
|
+
controlState: null,
|
|
1102
|
+
resumedAt: nowIso,
|
|
1103
|
+
},
|
|
1104
|
+
});
|
|
1105
|
+
await this.taskRegistry.appendEvent({
|
|
1106
|
+
threadId,
|
|
1107
|
+
sessionId: activeTask.sessionId,
|
|
1108
|
+
eventType: "task_resumed",
|
|
1109
|
+
summary: "Continued the active task thread",
|
|
1110
|
+
data: {
|
|
1111
|
+
reusedSession: true,
|
|
1112
|
+
instruction: instruction ?? null,
|
|
1113
|
+
},
|
|
1114
|
+
});
|
|
1115
|
+
return {
|
|
1116
|
+
threadId,
|
|
1117
|
+
sessionId: activeTask.sessionId,
|
|
1118
|
+
reusedSession: true,
|
|
1119
|
+
framework: activeTask.agentType,
|
|
1120
|
+
};
|
|
1121
|
+
}
|
|
1122
|
+
const latestSession = (thread.sessions ?? [])
|
|
1123
|
+
.slice()
|
|
1124
|
+
.sort((left, right) => right.lastActivityAt - left.lastActivityAt)[0];
|
|
1125
|
+
const workdir = latestSession?.workdir ?? thread.latestWorkdir;
|
|
1126
|
+
if (!workdir) {
|
|
1127
|
+
throw new Error(`Task thread ${threadId} has no resumable workspace`);
|
|
1128
|
+
}
|
|
1129
|
+
const requestedFramework = agentType
|
|
1130
|
+
? normalizeAgentType(agentType)
|
|
1131
|
+
: latestSession?.framework
|
|
1132
|
+
? normalizeAgentType(latestSession.framework)
|
|
1133
|
+
: normalizeAgentType(await this.ptyService.resolveAgentType());
|
|
1134
|
+
const frameworkState = await this.ptyService.getFrameworkState();
|
|
1135
|
+
const framework = frameworkState.frameworks.find((entry) => entry.id === requestedFramework);
|
|
1136
|
+
const resolvedFramework = framework?.installed &&
|
|
1137
|
+
framework.authReady &&
|
|
1138
|
+
!framework.temporarilyDisabled
|
|
1139
|
+
? requestedFramework
|
|
1140
|
+
: normalizeAgentType(await this.ptyService.resolveAgentType());
|
|
1141
|
+
const resolvedAvailability = frameworkState.frameworks.find((entry) => entry.id === resolvedFramework);
|
|
1142
|
+
const session = await this.ptyService.spawnSession({
|
|
1143
|
+
name: `task-resume-${thread.id.slice(-8)}`,
|
|
1144
|
+
agentType: resolvedFramework,
|
|
1145
|
+
workdir,
|
|
1146
|
+
initialTask: this.formatResumePrompt(thread, instruction),
|
|
1147
|
+
credentials: buildAgentCredentials(this.runtime),
|
|
1148
|
+
approvalPreset: this.ptyService.defaultApprovalPreset,
|
|
1149
|
+
skipAdapterAutoResponse: true,
|
|
1150
|
+
metadata: {
|
|
1151
|
+
threadId,
|
|
1152
|
+
label: thread.title,
|
|
1153
|
+
requestedType: resolvedFramework,
|
|
1154
|
+
resumedFromThreadId: threadId,
|
|
1155
|
+
resumedFromSessionId: latestSession?.sessionId ?? null,
|
|
1156
|
+
resumeInstruction: instruction ?? null,
|
|
1157
|
+
resumedAt: Date.now(),
|
|
1158
|
+
},
|
|
1159
|
+
});
|
|
1160
|
+
await this.registerTask(session.id, {
|
|
1161
|
+
threadId,
|
|
1162
|
+
taskNodeId: typeof latestSession?.metadata.taskNodeId === "string"
|
|
1163
|
+
? latestSession.metadata.taskNodeId
|
|
1164
|
+
: undefined,
|
|
1165
|
+
agentType: resolvedFramework,
|
|
1166
|
+
label: latestSession?.label ?? thread.title,
|
|
1167
|
+
originalTask: instruction?.trim() || thread.originalRequest,
|
|
1168
|
+
workdir,
|
|
1169
|
+
repo: latestSession?.repo ?? thread.latestRepo ?? undefined,
|
|
1170
|
+
providerSource: resolvedAvailability
|
|
1171
|
+
? inferProviderSource(resolvedAvailability)
|
|
1172
|
+
: null,
|
|
1173
|
+
metadata: session.metadata &&
|
|
1174
|
+
typeof session.metadata === "object" &&
|
|
1175
|
+
!Array.isArray(session.metadata)
|
|
1176
|
+
? session.metadata
|
|
1177
|
+
: undefined,
|
|
1178
|
+
});
|
|
1179
|
+
const nowIso = new Date().toISOString();
|
|
1180
|
+
await this.taskRegistry.updateThread(threadId, {
|
|
1181
|
+
status: "active",
|
|
1182
|
+
closedAt: null,
|
|
1183
|
+
lastCoordinatorTurnAt: nowIso,
|
|
1184
|
+
metadata: {
|
|
1185
|
+
controlState: null,
|
|
1186
|
+
resumedAt: nowIso,
|
|
1187
|
+
lastResumedSessionId: session.id,
|
|
1188
|
+
},
|
|
1189
|
+
});
|
|
1190
|
+
await this.taskRegistry.appendEvent({
|
|
1191
|
+
threadId,
|
|
1192
|
+
sessionId: session.id,
|
|
1193
|
+
eventType: "task_resumed",
|
|
1194
|
+
summary: "Resumed the task thread on a new session",
|
|
1195
|
+
data: {
|
|
1196
|
+
reusedSession: false,
|
|
1197
|
+
fromSessionId: latestSession?.sessionId ?? null,
|
|
1198
|
+
toSessionId: session.id,
|
|
1199
|
+
instruction: instruction ?? null,
|
|
1200
|
+
framework: resolvedFramework,
|
|
1201
|
+
},
|
|
1202
|
+
});
|
|
1203
|
+
return {
|
|
1204
|
+
threadId,
|
|
1205
|
+
sessionId: session.id,
|
|
1206
|
+
reusedSession: false,
|
|
1207
|
+
framework: resolvedFramework,
|
|
1208
|
+
};
|
|
1209
|
+
}
|
|
1210
|
+
async continueTaskThread(threadId, instruction, agentType) {
|
|
1211
|
+
const latestLiveTask = this.getLiveTaskContextsForThread(threadId).find((task) => task.status === "active" ||
|
|
1212
|
+
task.status === "blocked" ||
|
|
1213
|
+
task.status === "tool_running");
|
|
1214
|
+
if (latestLiveTask && this.ptyService) {
|
|
1215
|
+
await this.ptyService.sendToSession(latestLiveTask.sessionId, instruction);
|
|
1216
|
+
latestLiveTask.lastInputSentAt = Date.now();
|
|
1217
|
+
latestLiveTask.status = "active";
|
|
1218
|
+
await this.syncTaskContext(latestLiveTask);
|
|
1219
|
+
const nowIso = new Date().toISOString();
|
|
1220
|
+
await this.taskRegistry.updateThread(threadId, {
|
|
1221
|
+
status: "active",
|
|
1222
|
+
closedAt: null,
|
|
1223
|
+
lastCoordinatorTurnAt: nowIso,
|
|
1224
|
+
metadata: {
|
|
1225
|
+
controlState: null,
|
|
1226
|
+
continuedAt: nowIso,
|
|
1227
|
+
},
|
|
1228
|
+
});
|
|
1229
|
+
await this.taskRegistry.appendEvent({
|
|
1230
|
+
threadId,
|
|
1231
|
+
sessionId: latestLiveTask.sessionId,
|
|
1232
|
+
eventType: "task_resumed",
|
|
1233
|
+
summary: "Sent follow-up instructions to the active task thread",
|
|
1234
|
+
data: {
|
|
1235
|
+
reusedSession: true,
|
|
1236
|
+
instruction,
|
|
1237
|
+
},
|
|
1238
|
+
});
|
|
1239
|
+
return {
|
|
1240
|
+
threadId,
|
|
1241
|
+
sessionId: latestLiveTask.sessionId,
|
|
1242
|
+
reusedSession: true,
|
|
1243
|
+
framework: latestLiveTask.agentType,
|
|
1244
|
+
};
|
|
1245
|
+
}
|
|
1246
|
+
return this.resumeTaskThread(threadId, instruction, agentType);
|
|
1247
|
+
}
|
|
1248
|
+
async syncTaskContext(taskCtx) {
|
|
1249
|
+
await this.taskRegistry.updateSession(taskCtx.sessionId, {
|
|
1250
|
+
status: taskCtx.status === "completed"
|
|
1251
|
+
? "completed"
|
|
1252
|
+
: taskCtx.status === "error"
|
|
1253
|
+
? "error"
|
|
1254
|
+
: taskCtx.status === "stopped"
|
|
1255
|
+
? "stopped"
|
|
1256
|
+
: taskCtx.status === "blocked"
|
|
1257
|
+
? "blocked"
|
|
1258
|
+
: taskCtx.status === "tool_running"
|
|
1259
|
+
? "tool_running"
|
|
1260
|
+
: "active",
|
|
1261
|
+
decisionCount: taskCtx.decisions.length,
|
|
1262
|
+
autoResolvedCount: taskCtx.autoResolvedCount,
|
|
1263
|
+
lastActivityAt: taskCtx.lastActivityAt,
|
|
1264
|
+
idleCheckCount: taskCtx.idleCheckCount,
|
|
1265
|
+
taskDelivered: taskCtx.taskDelivered,
|
|
1266
|
+
completionSummary: taskCtx.completionSummary ?? null,
|
|
1267
|
+
lastSeenDecisionIndex: taskCtx.lastSeenDecisionIndex,
|
|
1268
|
+
lastInputSentAt: taskCtx.lastInputSentAt,
|
|
1269
|
+
stoppedAt: taskCtx.stoppedAt,
|
|
1270
|
+
});
|
|
1271
|
+
if (!taskCtx.taskNodeId) {
|
|
1272
|
+
return;
|
|
1273
|
+
}
|
|
1274
|
+
const nodeStatus = this.mapTaskContextStatusToNodeStatus(taskCtx.status);
|
|
1275
|
+
await this.taskRegistry.updateTaskNode(taskCtx.taskNodeId, {
|
|
1276
|
+
status: nodeStatus,
|
|
1277
|
+
title: taskCtx.label,
|
|
1278
|
+
instructions: taskCtx.originalTask,
|
|
1279
|
+
assignedSessionId: taskCtx.sessionId,
|
|
1280
|
+
assignedLabel: taskCtx.label,
|
|
1281
|
+
agentType: taskCtx.agentType,
|
|
1282
|
+
workdir: taskCtx.workdir,
|
|
1283
|
+
repo: taskCtx.repo ?? null,
|
|
1284
|
+
metadata: {
|
|
1285
|
+
completionSummary: taskCtx.completionSummary ?? null,
|
|
1286
|
+
},
|
|
1287
|
+
});
|
|
1288
|
+
const activeClaim = await this.taskRegistry.findActiveTaskClaim(taskCtx.taskNodeId, taskCtx.sessionId);
|
|
1289
|
+
if (taskCtx.status === "completed" ||
|
|
1290
|
+
taskCtx.status === "error" ||
|
|
1291
|
+
taskCtx.status === "stopped") {
|
|
1292
|
+
if (activeClaim) {
|
|
1293
|
+
await this.taskRegistry.updateTaskClaim(activeClaim.id, {
|
|
1294
|
+
status: taskCtx.status === "completed"
|
|
1295
|
+
? "completed"
|
|
1296
|
+
: taskCtx.status === "error"
|
|
1297
|
+
? "failed"
|
|
1298
|
+
: "interrupted",
|
|
1299
|
+
releasedAt: new Date().toISOString(),
|
|
1300
|
+
metadata: {
|
|
1301
|
+
completionSummary: taskCtx.completionSummary ?? null,
|
|
1302
|
+
},
|
|
1303
|
+
});
|
|
1304
|
+
}
|
|
1305
|
+
return;
|
|
1306
|
+
}
|
|
1307
|
+
if (!activeClaim) {
|
|
1308
|
+
await this.taskRegistry.createTaskClaim({
|
|
1309
|
+
threadId: taskCtx.threadId,
|
|
1310
|
+
nodeId: taskCtx.taskNodeId,
|
|
1311
|
+
sessionId: taskCtx.sessionId,
|
|
1312
|
+
claimType: "execution",
|
|
1313
|
+
status: "active",
|
|
1314
|
+
metadata: {
|
|
1315
|
+
label: taskCtx.label,
|
|
1316
|
+
},
|
|
1317
|
+
});
|
|
1318
|
+
}
|
|
1319
|
+
}
|
|
1320
|
+
isAutomaticFailoverFramework(agentType) {
|
|
1321
|
+
return (agentType === "claude" ||
|
|
1322
|
+
agentType === "codex" ||
|
|
1323
|
+
agentType === "gemini" ||
|
|
1324
|
+
agentType === "aider");
|
|
1325
|
+
}
|
|
1326
|
+
getFailoverCandidates(frameworks, failedFramework, preferredFrameworkId) {
|
|
1327
|
+
const preferred = frameworks.find((framework) => framework.id === preferredFrameworkId);
|
|
1328
|
+
const remainder = frameworks.filter((framework) => framework.id !== preferredFrameworkId);
|
|
1329
|
+
return [preferred, ...remainder].filter((framework) => Boolean(framework &&
|
|
1330
|
+
framework.id !== failedFramework &&
|
|
1331
|
+
framework.installed &&
|
|
1332
|
+
framework.authReady &&
|
|
1333
|
+
!framework.temporarilyDisabled));
|
|
1334
|
+
}
|
|
1335
|
+
getRecoveryCandidates(frameworks, currentFramework, preferredFrameworkId, preferAlternative) {
|
|
1336
|
+
const healthy = frameworks.filter((framework) => framework.installed &&
|
|
1337
|
+
framework.authReady &&
|
|
1338
|
+
!framework.temporarilyDisabled);
|
|
1339
|
+
const byId = new Map(healthy.map((framework) => [framework.id, framework]));
|
|
1340
|
+
const orderedIds = [];
|
|
1341
|
+
if (!preferAlternative) {
|
|
1342
|
+
orderedIds.push(currentFramework);
|
|
1343
|
+
}
|
|
1344
|
+
orderedIds.push(preferredFrameworkId);
|
|
1345
|
+
for (const framework of healthy) {
|
|
1346
|
+
orderedIds.push(framework.id);
|
|
1347
|
+
}
|
|
1348
|
+
const seen = new Set();
|
|
1349
|
+
const candidates = [];
|
|
1350
|
+
for (const id of orderedIds) {
|
|
1351
|
+
if (seen.has(id)) {
|
|
1352
|
+
continue;
|
|
1353
|
+
}
|
|
1354
|
+
seen.add(id);
|
|
1355
|
+
if (preferAlternative && id === currentFramework) {
|
|
1356
|
+
continue;
|
|
1357
|
+
}
|
|
1358
|
+
const framework = byId.get(id);
|
|
1359
|
+
if (framework) {
|
|
1360
|
+
candidates.push(framework);
|
|
1361
|
+
}
|
|
1362
|
+
}
|
|
1363
|
+
return candidates;
|
|
1364
|
+
}
|
|
1365
|
+
shouldPreferAlternativeFrameworkForError(reason) {
|
|
1366
|
+
return ALTERNATE_FRAMEWORK_ERROR_RE.test(reason);
|
|
1367
|
+
}
|
|
1368
|
+
formatFailoverPrompt(taskCtx, failedFramework, reason, recentOutput) {
|
|
1369
|
+
const cleanedOutput = cleanForFailoverContext(recentOutput, taskCtx.workdir);
|
|
1370
|
+
const trimmedOutput = cleanedOutput.trim();
|
|
1371
|
+
const clippedOutput = trimmedOutput.length > FAILOVER_OUTPUT_MAX_CHARS
|
|
1372
|
+
? trimmedOutput.slice(-FAILOVER_OUTPUT_MAX_CHARS)
|
|
1373
|
+
: trimmedOutput;
|
|
1374
|
+
const recentDecisions = taskCtx.decisions
|
|
1375
|
+
.slice(-5)
|
|
1376
|
+
.map((decision, index) => `${index + 1}. ${decision.event}: ${decision.reasoning}${decision.response ? ` (response: ${decision.response})` : ""}`)
|
|
1377
|
+
.join("\n");
|
|
1378
|
+
return [
|
|
1379
|
+
`Continue an in-progress task after the previous ${failedFramework} session became unavailable because of a quota or credit failure.`,
|
|
1380
|
+
"",
|
|
1381
|
+
"Original task:",
|
|
1382
|
+
taskCtx.originalTask,
|
|
1383
|
+
"",
|
|
1384
|
+
`Failure reason: ${reason}`,
|
|
1385
|
+
`Workspace: ${taskCtx.workdir}`,
|
|
1386
|
+
"",
|
|
1387
|
+
recentDecisions
|
|
1388
|
+
? `Recent coordinator decisions:\n${recentDecisions}\n`
|
|
1389
|
+
: "",
|
|
1390
|
+
clippedOutput
|
|
1391
|
+
? `Recent terminal output from the failed session:\n${clippedOutput}\n`
|
|
1392
|
+
: "",
|
|
1393
|
+
"Use the existing workspace state instead of starting from scratch. Inspect the files, continue the task, run the needed validation, and then report what changed and how you verified it.",
|
|
1394
|
+
]
|
|
1395
|
+
.filter(Boolean)
|
|
1396
|
+
.join("\n");
|
|
1397
|
+
}
|
|
1398
|
+
formatErrorRecoveryPrompt(taskCtx, recoveryFramework, reason, recentOutput) {
|
|
1399
|
+
const cleanedOutput = cleanForFailoverContext(recentOutput, taskCtx.workdir);
|
|
1400
|
+
const trimmedOutput = cleanedOutput.trim();
|
|
1401
|
+
const clippedOutput = trimmedOutput.length > FAILOVER_OUTPUT_MAX_CHARS
|
|
1402
|
+
? trimmedOutput.slice(-FAILOVER_OUTPUT_MAX_CHARS)
|
|
1403
|
+
: trimmedOutput;
|
|
1404
|
+
const recentDecisions = taskCtx.decisions
|
|
1405
|
+
.slice(-5)
|
|
1406
|
+
.map((decision, index) => `${index + 1}. ${decision.event}: ${decision.reasoning}${decision.response ? ` (response: ${decision.response})` : ""}`)
|
|
1407
|
+
.join("\n");
|
|
1408
|
+
const recoveryMode = recoveryFramework === taskCtx.agentType
|
|
1409
|
+
? `a fresh ${recoveryFramework} session`
|
|
1410
|
+
: `a ${recoveryFramework} recovery session`;
|
|
1411
|
+
return [
|
|
1412
|
+
`Continue an in-progress task after the previous session terminated unexpectedly. Eliza started ${recoveryMode} for recovery.`,
|
|
1413
|
+
"",
|
|
1414
|
+
"Original task:",
|
|
1415
|
+
taskCtx.originalTask,
|
|
1416
|
+
"",
|
|
1417
|
+
`Failure reason: ${reason}`,
|
|
1418
|
+
`Workspace: ${taskCtx.workdir}`,
|
|
1419
|
+
"",
|
|
1420
|
+
recentDecisions
|
|
1421
|
+
? `Recent coordinator decisions:\n${recentDecisions}\n`
|
|
1422
|
+
: "",
|
|
1423
|
+
clippedOutput
|
|
1424
|
+
? `Recent terminal output from the failed session:\n${clippedOutput}\n`
|
|
1425
|
+
: "",
|
|
1426
|
+
"Use the existing workspace state instead of starting over. Inspect the current files, recover from the failure, continue the task, run the needed validation, and then report exactly what changed and how you verified it.",
|
|
1427
|
+
]
|
|
1428
|
+
.filter(Boolean)
|
|
1429
|
+
.join("\n");
|
|
1430
|
+
}
|
|
1431
|
+
async handleFrameworkDepletion(taskCtx, sessionId, reason) {
|
|
1432
|
+
if (!this.isAutomaticFailoverFramework(taskCtx.agentType) ||
|
|
1433
|
+
!isUsageExhaustedTaskAgentError(reason)) {
|
|
1434
|
+
return null;
|
|
1435
|
+
}
|
|
1436
|
+
markTaskAgentFrameworkUnavailable(taskCtx.agentType, reason);
|
|
1437
|
+
await this.taskRegistry.appendEvent({
|
|
1438
|
+
threadId: taskCtx.threadId,
|
|
1439
|
+
sessionId,
|
|
1440
|
+
eventType: "framework_unavailable",
|
|
1441
|
+
summary: `${taskCtx.agentType} temporarily disabled after provider depletion`,
|
|
1442
|
+
data: {
|
|
1443
|
+
framework: taskCtx.agentType,
|
|
1444
|
+
reason,
|
|
1445
|
+
},
|
|
1446
|
+
});
|
|
1447
|
+
let failoverResult = null;
|
|
1448
|
+
try {
|
|
1449
|
+
failoverResult = await this.attemptTaskFailover(taskCtx, reason);
|
|
1450
|
+
}
|
|
1451
|
+
catch (failoverError) {
|
|
1452
|
+
this.log(`Automatic failover failed for "${taskCtx.label}": ${failoverError instanceof Error ? failoverError.message : String(failoverError)}`);
|
|
1453
|
+
}
|
|
1454
|
+
if (failoverResult) {
|
|
1455
|
+
this.sendChatMessage(`"${taskCtx.label}" ran into a ${taskCtx.agentType} quota/credit failure. Eliza is continuing the same task on ${failoverResult.replacementFramework}.`, "coding-agent");
|
|
1456
|
+
}
|
|
1457
|
+
else {
|
|
1458
|
+
this.sendChatMessage(`"${taskCtx.label}" ran into a ${taskCtx.agentType} quota/credit failure. Eliza will prefer another task-agent framework until ${taskCtx.agentType} is healthy again.`, "coding-agent");
|
|
1459
|
+
}
|
|
1460
|
+
return failoverResult;
|
|
1461
|
+
}
|
|
1462
|
+
async attemptTaskFailover(taskCtx, errorMsg) {
|
|
1463
|
+
if (!this.ptyService ||
|
|
1464
|
+
!this.isAutomaticFailoverFramework(taskCtx.agentType)) {
|
|
1465
|
+
return null;
|
|
1466
|
+
}
|
|
1467
|
+
const frameworkState = await this.ptyService.getFrameworkState();
|
|
1468
|
+
const candidates = this.getFailoverCandidates(frameworkState.frameworks, taskCtx.agentType, frameworkState.preferred.id);
|
|
1469
|
+
const nextFramework = candidates[0];
|
|
1470
|
+
if (!nextFramework) {
|
|
1471
|
+
return null;
|
|
1472
|
+
}
|
|
1473
|
+
const failedSession = this.ptyService.getSession(taskCtx.sessionId);
|
|
1474
|
+
const priorMetadata = failedSession?.metadata &&
|
|
1475
|
+
typeof failedSession.metadata === "object" &&
|
|
1476
|
+
!Array.isArray(failedSession.metadata)
|
|
1477
|
+
? failedSession.metadata
|
|
1478
|
+
: {};
|
|
1479
|
+
const failoverOrdinal = typeof priorMetadata.failoverOrdinal === "number"
|
|
1480
|
+
? priorMetadata.failoverOrdinal + 1
|
|
1481
|
+
: 1;
|
|
1482
|
+
const priorOutput = await Promise.race([
|
|
1483
|
+
this.ptyService.getSessionOutput(taskCtx.sessionId, 200),
|
|
1484
|
+
new Promise((resolve) => setTimeout(() => resolve(""), 5_000)),
|
|
1485
|
+
]);
|
|
1486
|
+
const replacementLabel = `${taskCtx.label} (${nextFramework.id} failover ${failoverOrdinal})`;
|
|
1487
|
+
const replacementSession = await this.ptyService.spawnSession({
|
|
1488
|
+
name: failedSession?.name ??
|
|
1489
|
+
`task-failover-${Date.now()}-${nextFramework.id}`,
|
|
1490
|
+
agentType: nextFramework.id,
|
|
1491
|
+
workdir: taskCtx.workdir,
|
|
1492
|
+
initialTask: this.formatFailoverPrompt(taskCtx, taskCtx.agentType, errorMsg, priorOutput),
|
|
1493
|
+
approvalPreset: this.ptyService.defaultApprovalPreset,
|
|
1494
|
+
skipAdapterAutoResponse: true,
|
|
1495
|
+
metadata: {
|
|
1496
|
+
...priorMetadata,
|
|
1497
|
+
threadId: taskCtx.threadId,
|
|
1498
|
+
requestedType: nextFramework.id,
|
|
1499
|
+
label: replacementLabel,
|
|
1500
|
+
failoverOrdinal,
|
|
1501
|
+
failoverFromFramework: taskCtx.agentType,
|
|
1502
|
+
failoverFromSessionId: taskCtx.sessionId,
|
|
1503
|
+
failoverReason: errorMsg,
|
|
1504
|
+
failoverAt: Date.now(),
|
|
1505
|
+
},
|
|
1506
|
+
});
|
|
1507
|
+
await this.registerTask(replacementSession.id, {
|
|
1508
|
+
threadId: taskCtx.threadId,
|
|
1509
|
+
taskNodeId: taskCtx.taskNodeId,
|
|
1510
|
+
agentType: nextFramework.id,
|
|
1511
|
+
label: replacementLabel,
|
|
1512
|
+
originalTask: taskCtx.originalTask,
|
|
1513
|
+
workdir: taskCtx.workdir,
|
|
1514
|
+
repo: taskCtx.repo,
|
|
1515
|
+
providerSource: inferProviderSource(nextFramework),
|
|
1516
|
+
metadata: replacementSession.metadata &&
|
|
1517
|
+
typeof replacementSession.metadata === "object" &&
|
|
1518
|
+
!Array.isArray(replacementSession.metadata)
|
|
1519
|
+
? replacementSession.metadata
|
|
1520
|
+
: undefined,
|
|
1521
|
+
});
|
|
1522
|
+
await this.taskRegistry.appendEvent({
|
|
1523
|
+
threadId: taskCtx.threadId,
|
|
1524
|
+
sessionId: replacementSession.id,
|
|
1525
|
+
eventType: "framework_failover_started",
|
|
1526
|
+
summary: `Continuing "${taskCtx.label}" on ${nextFramework.label}`,
|
|
1527
|
+
data: {
|
|
1528
|
+
fromFramework: taskCtx.agentType,
|
|
1529
|
+
fromSessionId: taskCtx.sessionId,
|
|
1530
|
+
toFramework: nextFramework.id,
|
|
1531
|
+
toSessionId: replacementSession.id,
|
|
1532
|
+
reason: errorMsg,
|
|
1533
|
+
},
|
|
1534
|
+
});
|
|
1535
|
+
return {
|
|
1536
|
+
replacementSessionId: replacementSession.id,
|
|
1537
|
+
replacementFramework: nextFramework.id,
|
|
1538
|
+
replacementLabel,
|
|
1539
|
+
};
|
|
1540
|
+
}
|
|
1541
|
+
async attemptTaskRecovery(taskCtx, errorMsg) {
|
|
1542
|
+
if (!this.ptyService) {
|
|
1543
|
+
return null;
|
|
1544
|
+
}
|
|
1545
|
+
const failedSession = this.ptyService.getSession(taskCtx.sessionId);
|
|
1546
|
+
const priorMetadata = failedSession?.metadata &&
|
|
1547
|
+
typeof failedSession.metadata === "object" &&
|
|
1548
|
+
!Array.isArray(failedSession.metadata)
|
|
1549
|
+
? failedSession.metadata
|
|
1550
|
+
: {};
|
|
1551
|
+
const recoveryOrdinal = typeof priorMetadata.recoveryOrdinal === "number"
|
|
1552
|
+
? priorMetadata.recoveryOrdinal + 1
|
|
1553
|
+
: 1;
|
|
1554
|
+
if (recoveryOrdinal > MAX_AUTOMATIC_ERROR_RECOVERIES) {
|
|
1555
|
+
return null;
|
|
1556
|
+
}
|
|
1557
|
+
let recoveryFramework = taskCtx.agentType;
|
|
1558
|
+
let recoveryAvailability = null;
|
|
1559
|
+
if (this.isAutomaticFailoverFramework(taskCtx.agentType)) {
|
|
1560
|
+
const frameworkState = await this.ptyService.getFrameworkState();
|
|
1561
|
+
const candidates = this.getRecoveryCandidates(frameworkState.frameworks, taskCtx.agentType, frameworkState.preferred.id, this.shouldPreferAlternativeFrameworkForError(errorMsg));
|
|
1562
|
+
const selected = candidates[0];
|
|
1563
|
+
if (!selected) {
|
|
1564
|
+
return null;
|
|
1565
|
+
}
|
|
1566
|
+
recoveryFramework = selected.id;
|
|
1567
|
+
recoveryAvailability = selected;
|
|
1568
|
+
}
|
|
1569
|
+
const priorOutput = await Promise.race([
|
|
1570
|
+
this.ptyService.getSessionOutput(taskCtx.sessionId, 200),
|
|
1571
|
+
new Promise((resolve) => setTimeout(() => resolve(""), 5_000)),
|
|
1572
|
+
]);
|
|
1573
|
+
const replacementLabel = `${taskCtx.label} (${recoveryFramework} recovery ${recoveryOrdinal})`;
|
|
1574
|
+
const replacementSession = await this.ptyService.spawnSession({
|
|
1575
|
+
name: failedSession?.name ??
|
|
1576
|
+
`task-recovery-${Date.now()}-${recoveryFramework}`,
|
|
1577
|
+
agentType: recoveryFramework,
|
|
1578
|
+
workdir: taskCtx.workdir,
|
|
1579
|
+
initialTask: this.formatErrorRecoveryPrompt(taskCtx, recoveryFramework, errorMsg, priorOutput),
|
|
1580
|
+
credentials: buildAgentCredentials(this.runtime),
|
|
1581
|
+
approvalPreset: this.ptyService.defaultApprovalPreset,
|
|
1582
|
+
skipAdapterAutoResponse: true,
|
|
1583
|
+
metadata: {
|
|
1584
|
+
...priorMetadata,
|
|
1585
|
+
threadId: taskCtx.threadId,
|
|
1586
|
+
requestedType: recoveryFramework,
|
|
1587
|
+
label: replacementLabel,
|
|
1588
|
+
recoveryOrdinal,
|
|
1589
|
+
recoveredFromFramework: taskCtx.agentType,
|
|
1590
|
+
recoveredFromSessionId: taskCtx.sessionId,
|
|
1591
|
+
recoveryReason: errorMsg,
|
|
1592
|
+
recoveryAt: Date.now(),
|
|
1593
|
+
},
|
|
1594
|
+
});
|
|
1595
|
+
await this.registerTask(replacementSession.id, {
|
|
1596
|
+
threadId: taskCtx.threadId,
|
|
1597
|
+
taskNodeId: taskCtx.taskNodeId,
|
|
1598
|
+
agentType: recoveryFramework,
|
|
1599
|
+
label: replacementLabel,
|
|
1600
|
+
originalTask: taskCtx.originalTask,
|
|
1601
|
+
workdir: taskCtx.workdir,
|
|
1602
|
+
repo: taskCtx.repo,
|
|
1603
|
+
providerSource: recoveryAvailability
|
|
1604
|
+
? inferProviderSource(recoveryAvailability)
|
|
1605
|
+
: null,
|
|
1606
|
+
metadata: replacementSession.metadata &&
|
|
1607
|
+
typeof replacementSession.metadata === "object" &&
|
|
1608
|
+
!Array.isArray(replacementSession.metadata)
|
|
1609
|
+
? replacementSession.metadata
|
|
1610
|
+
: undefined,
|
|
1611
|
+
});
|
|
1612
|
+
await this.taskRegistry.appendEvent({
|
|
1613
|
+
threadId: taskCtx.threadId,
|
|
1614
|
+
sessionId: replacementSession.id,
|
|
1615
|
+
eventType: "task_error_recovery_started",
|
|
1616
|
+
summary: `Continuing "${taskCtx.label}" after an agent error`,
|
|
1617
|
+
data: {
|
|
1618
|
+
fromFramework: taskCtx.agentType,
|
|
1619
|
+
fromSessionId: taskCtx.sessionId,
|
|
1620
|
+
toFramework: recoveryFramework,
|
|
1621
|
+
toSessionId: replacementSession.id,
|
|
1622
|
+
reason: errorMsg,
|
|
1623
|
+
recoveryOrdinal,
|
|
1624
|
+
},
|
|
1625
|
+
});
|
|
1626
|
+
this.broadcast({
|
|
1627
|
+
type: "task_recovery_started",
|
|
1628
|
+
sessionId: replacementSession.id,
|
|
1629
|
+
timestamp: Date.now(),
|
|
1630
|
+
data: {
|
|
1631
|
+
fromSessionId: taskCtx.sessionId,
|
|
1632
|
+
fromFramework: taskCtx.agentType,
|
|
1633
|
+
toFramework: recoveryFramework,
|
|
1634
|
+
reason: errorMsg,
|
|
1635
|
+
},
|
|
1636
|
+
});
|
|
1637
|
+
return {
|
|
1638
|
+
replacementSessionId: replacementSession.id,
|
|
1639
|
+
replacementFramework: recoveryFramework,
|
|
1640
|
+
replacementLabel,
|
|
1641
|
+
};
|
|
1642
|
+
}
|
|
1643
|
+
async resumeTaskAfterProviderAuth(sessionId, reason) {
|
|
1644
|
+
const taskCtx = this.tasks.get(sessionId);
|
|
1645
|
+
if (!taskCtx) {
|
|
1646
|
+
return null;
|
|
1647
|
+
}
|
|
1648
|
+
if (taskCtx.status === "completed" ||
|
|
1649
|
+
taskCtx.status === "error" ||
|
|
1650
|
+
taskCtx.status === "stopped") {
|
|
1651
|
+
return null;
|
|
1652
|
+
}
|
|
1653
|
+
const replacement = await this.attemptTaskRecovery(taskCtx, reason);
|
|
1654
|
+
if (!replacement) {
|
|
1655
|
+
return null;
|
|
1656
|
+
}
|
|
1657
|
+
taskCtx.suppressStopNotice = true;
|
|
1658
|
+
taskCtx.status = "stopped";
|
|
1659
|
+
try {
|
|
1660
|
+
await this.ptyService?.stopSession(sessionId, true);
|
|
1661
|
+
}
|
|
1662
|
+
catch (error) {
|
|
1663
|
+
this.log(`Failed to stop superseded auth-blocked session ${sessionId}: ${error instanceof Error ? error.message : String(error)}`);
|
|
1664
|
+
}
|
|
1665
|
+
this.sendChatMessage(`"${taskCtx.label}" recovered after provider authentication and is continuing on ${replacement.replacementFramework}.`, "coding-agent");
|
|
1666
|
+
return replacement;
|
|
1667
|
+
}
|
|
1668
|
+
async markTaskResumedAfterProviderAuth(sessionId) {
|
|
1669
|
+
const taskCtx = this.tasks.get(sessionId);
|
|
1670
|
+
if (!taskCtx) {
|
|
1671
|
+
return false;
|
|
1672
|
+
}
|
|
1673
|
+
if (taskCtx.status === "completed" ||
|
|
1674
|
+
taskCtx.status === "error" ||
|
|
1675
|
+
taskCtx.status === "stopped") {
|
|
1676
|
+
return false;
|
|
1677
|
+
}
|
|
1678
|
+
taskCtx.status = "active";
|
|
1679
|
+
taskCtx.stoppedAt = undefined;
|
|
1680
|
+
taskCtx.lastActivityAt = Date.now();
|
|
1681
|
+
taskCtx.idleCheckCount = 0;
|
|
1682
|
+
if (taskCtx.agentType === "claude" ||
|
|
1683
|
+
taskCtx.agentType === "codex" ||
|
|
1684
|
+
taskCtx.agentType === "gemini" ||
|
|
1685
|
+
taskCtx.agentType === "aider") {
|
|
1686
|
+
markTaskAgentFrameworkHealthy(taskCtx.agentType);
|
|
1687
|
+
}
|
|
1688
|
+
this.broadcast({
|
|
1689
|
+
type: "ready",
|
|
1690
|
+
sessionId,
|
|
1691
|
+
timestamp: Date.now(),
|
|
1692
|
+
data: {
|
|
1693
|
+
reason: "provider_auth_recovered",
|
|
1694
|
+
source: "auth_recovery",
|
|
1695
|
+
},
|
|
1696
|
+
});
|
|
1697
|
+
await this.taskRegistry.appendEvent({
|
|
1698
|
+
threadId: taskCtx.threadId,
|
|
1699
|
+
sessionId,
|
|
1700
|
+
eventType: "task_status_changed",
|
|
1701
|
+
summary: `Task "${taskCtx.label}" resumed after provider authentication`,
|
|
1702
|
+
data: {
|
|
1703
|
+
status: "active",
|
|
1704
|
+
reason: "provider_auth_recovered",
|
|
1705
|
+
},
|
|
1706
|
+
});
|
|
1707
|
+
this.sendChatMessage(`"${taskCtx.label}" refreshed provider authentication and is continuing automatically.`, "coding-agent");
|
|
1708
|
+
return true;
|
|
1709
|
+
}
|
|
1710
|
+
async recordDecision(taskCtx, decision) {
|
|
1711
|
+
taskCtx.decisions.push(decision);
|
|
1712
|
+
await this.taskRegistry.recordDecision({
|
|
1713
|
+
threadId: taskCtx.threadId,
|
|
1714
|
+
sessionId: taskCtx.sessionId,
|
|
1715
|
+
timestamp: decision.timestamp,
|
|
1716
|
+
event: decision.event,
|
|
1717
|
+
promptText: decision.promptText,
|
|
1718
|
+
decision: decision.decision,
|
|
1719
|
+
response: decision.response,
|
|
1720
|
+
reasoning: decision.reasoning,
|
|
1721
|
+
});
|
|
1722
|
+
await this.syncTaskContext(taskCtx);
|
|
1723
|
+
}
|
|
1724
|
+
async setTaskDelivered(sessionId) {
|
|
1725
|
+
const taskCtx = this.tasks.get(sessionId);
|
|
1726
|
+
if (!taskCtx)
|
|
1727
|
+
return;
|
|
1728
|
+
taskCtx.taskDelivered = true;
|
|
1729
|
+
await this.syncTaskContext(taskCtx);
|
|
1730
|
+
}
|
|
1731
|
+
// ─── Unregistered Buffer Retry ───
|
|
1732
|
+
/**
|
|
1733
|
+
* Schedule a retry check for buffered events from an unregistered session.
|
|
1734
|
+
* Uses exponential backoff: 2s → 4s → 8s → 16s, max 30s total.
|
|
1735
|
+
*/
|
|
1736
|
+
scheduleUnregisteredRetry(sessionId, attempt) {
|
|
1737
|
+
const delay = UNREGISTERED_RETRY_DELAYS[Math.min(attempt, UNREGISTERED_RETRY_DELAYS.length - 1)];
|
|
1738
|
+
const timer = setTimeout(() => {
|
|
1739
|
+
this.unregisteredRetryTimers.delete(sessionId);
|
|
1740
|
+
const stillBuffered = this.unregisteredBuffer.get(sessionId);
|
|
1741
|
+
if (!stillBuffered || stillBuffered.length === 0)
|
|
1742
|
+
return;
|
|
1743
|
+
const ctx = this.tasks.get(sessionId);
|
|
1744
|
+
if (ctx) {
|
|
1745
|
+
// Task was registered — flush
|
|
1746
|
+
this.unregisteredBuffer.delete(sessionId);
|
|
1747
|
+
for (const entry of stillBuffered) {
|
|
1748
|
+
this.handleNormalizedSessionEvent(entry.normalized).catch((err) => {
|
|
1749
|
+
this.log(`Failed to replay buffered event for ${sessionId}: ${err}`);
|
|
1750
|
+
});
|
|
1751
|
+
}
|
|
1752
|
+
return;
|
|
1753
|
+
}
|
|
1754
|
+
// Check if we've exceeded the absolute max wait
|
|
1755
|
+
const oldest = stillBuffered[0].receivedAt;
|
|
1756
|
+
const totalElapsed = Date.now() - oldest;
|
|
1757
|
+
if (totalElapsed >= UNREGISTERED_MAX_TOTAL_MS) {
|
|
1758
|
+
this.unregisteredBuffer.delete(sessionId);
|
|
1759
|
+
this.log(`Discarding ${stillBuffered.length} buffered events for unregistered session ${sessionId} after ${Math.round(totalElapsed / 1000)}s`);
|
|
1760
|
+
return;
|
|
1761
|
+
}
|
|
1762
|
+
// Schedule next retry
|
|
1763
|
+
this.log(`Retry ${attempt + 1} for unregistered session ${sessionId} (next in ${delay}ms)`);
|
|
1764
|
+
this.scheduleUnregisteredRetry(sessionId, attempt + 1);
|
|
1765
|
+
}, delay);
|
|
1766
|
+
this.unregisteredRetryTimers.set(sessionId, timer);
|
|
1767
|
+
}
|
|
1768
|
+
// ─── SSE Client Management ───
|
|
1769
|
+
/**
|
|
1770
|
+
* Register an SSE client. Returns an unsubscribe function.
|
|
1771
|
+
* Sends a snapshot of current state on connect.
|
|
1772
|
+
*/
|
|
1773
|
+
addSseClient(res) {
|
|
1774
|
+
this.sseClients.add(res);
|
|
1775
|
+
// Send snapshot on connect
|
|
1776
|
+
const snapshot = {
|
|
1777
|
+
type: "snapshot",
|
|
1778
|
+
sessionId: "*",
|
|
1779
|
+
timestamp: Date.now(),
|
|
1780
|
+
data: {
|
|
1781
|
+
tasks: this.getAllTaskContexts(),
|
|
1782
|
+
supervisionLevel: this.supervisionLevel,
|
|
1783
|
+
pendingCount: this.pendingDecisions.size,
|
|
1784
|
+
},
|
|
1785
|
+
};
|
|
1786
|
+
this.writeSseEvent(res, snapshot);
|
|
1787
|
+
// Remove on close
|
|
1788
|
+
const cleanup = () => {
|
|
1789
|
+
this.sseClients.delete(res);
|
|
1790
|
+
};
|
|
1791
|
+
res.on("close", cleanup);
|
|
1792
|
+
return cleanup;
|
|
1793
|
+
}
|
|
1794
|
+
broadcast(event) {
|
|
1795
|
+
const dead = [];
|
|
1796
|
+
for (const client of this.sseClients) {
|
|
1797
|
+
if (client.writableEnded) {
|
|
1798
|
+
dead.push(client);
|
|
1799
|
+
continue;
|
|
1800
|
+
}
|
|
1801
|
+
this.writeSseEvent(client, event);
|
|
1802
|
+
}
|
|
1803
|
+
// Cleanup dead connections
|
|
1804
|
+
for (const d of dead) {
|
|
1805
|
+
this.sseClients.delete(d);
|
|
1806
|
+
}
|
|
1807
|
+
// Relay to WebSocket clients — buffer if bridge isn't wired yet
|
|
1808
|
+
if (this.wsBroadcast) {
|
|
1809
|
+
this.wsBroadcast(event);
|
|
1810
|
+
}
|
|
1811
|
+
else if (this.preBridgeBroadcastBuffer.length < MAX_PRE_BRIDGE_BUFFER) {
|
|
1812
|
+
this.preBridgeBroadcastBuffer.push(event);
|
|
1813
|
+
}
|
|
1814
|
+
}
|
|
1815
|
+
writeSseEvent(res, event) {
|
|
1816
|
+
try {
|
|
1817
|
+
res.write(`data: ${JSON.stringify(event)}\n\n`);
|
|
1818
|
+
}
|
|
1819
|
+
catch {
|
|
1820
|
+
// Connection may have closed
|
|
1821
|
+
}
|
|
1822
|
+
}
|
|
1823
|
+
// ─── Event Handling ───
|
|
1824
|
+
async handleSessionEvent(sessionId, event, data) {
|
|
1825
|
+
const normalized = normalizeCoordinatorEvent(sessionId, event, data);
|
|
1826
|
+
if (!normalized) {
|
|
1827
|
+
this.broadcast({
|
|
1828
|
+
type: event,
|
|
1829
|
+
sessionId,
|
|
1830
|
+
timestamp: Date.now(),
|
|
1831
|
+
data,
|
|
1832
|
+
});
|
|
1833
|
+
return;
|
|
1834
|
+
}
|
|
1835
|
+
await this.handleNormalizedSessionEvent(normalized);
|
|
1836
|
+
}
|
|
1837
|
+
async handleNormalizedSessionEvent(normalized) {
|
|
1838
|
+
const sessionId = normalized.sessionId;
|
|
1839
|
+
const event = normalized.name;
|
|
1840
|
+
const data = normalized.rawData;
|
|
1841
|
+
// Lazy-wire scratch decision callback if not yet connected
|
|
1842
|
+
if (!this.scratchDecisionWired) {
|
|
1843
|
+
this.wireScratchDecisionCallback();
|
|
1844
|
+
}
|
|
1845
|
+
// Ignore events from sessions created before this coordinator started.
|
|
1846
|
+
// Session IDs are formatted as "pty-{timestamp}-{hex}" — extract the timestamp.
|
|
1847
|
+
const tsMatch = sessionId.match(/^pty-(\d+)-/);
|
|
1848
|
+
if (tsMatch) {
|
|
1849
|
+
const sessionCreatedAt = Number(tsMatch[1]);
|
|
1850
|
+
if (sessionCreatedAt < this.startedAt - 60_000) {
|
|
1851
|
+
// Session is from before this coordinator's lifetime (with 1min grace)
|
|
1852
|
+
return;
|
|
1853
|
+
}
|
|
1854
|
+
}
|
|
1855
|
+
const taskCtx = this.tasks.get(sessionId);
|
|
1856
|
+
// Buffer events for unregistered sessions with exponential backoff retry.
|
|
1857
|
+
// Events arriving before registerTask() are buffered and retried at
|
|
1858
|
+
// 2s → 4s → 8s → 16s intervals (max 30s total) before being discarded.
|
|
1859
|
+
if (!taskCtx) {
|
|
1860
|
+
if (event === "blocked" ||
|
|
1861
|
+
event === "task_complete" ||
|
|
1862
|
+
event === "error") {
|
|
1863
|
+
let buffer = this.unregisteredBuffer.get(sessionId);
|
|
1864
|
+
if (!buffer) {
|
|
1865
|
+
buffer = [];
|
|
1866
|
+
this.unregisteredBuffer.set(sessionId, buffer);
|
|
1867
|
+
}
|
|
1868
|
+
buffer.push({ normalized, receivedAt: Date.now() });
|
|
1869
|
+
// Only schedule retry if not already retrying for this session
|
|
1870
|
+
if (!this.unregisteredRetryTimers.has(sessionId)) {
|
|
1871
|
+
this.scheduleUnregisteredRetry(sessionId, 0);
|
|
1872
|
+
}
|
|
1873
|
+
}
|
|
1874
|
+
return;
|
|
1875
|
+
}
|
|
1876
|
+
// Skip decision-making events for terminal states, but always allow
|
|
1877
|
+
// "stopped" and "error" through — they're definitive lifecycle signals
|
|
1878
|
+
// that the frontend needs to close consoles and clean up.
|
|
1879
|
+
// Exception: allow a late "task_complete" to recover a recently-stopped task.
|
|
1880
|
+
let recoveredFromStopped = false;
|
|
1881
|
+
if (taskCtx.status === "stopped" ||
|
|
1882
|
+
taskCtx.status === "error" ||
|
|
1883
|
+
taskCtx.status === "completed") {
|
|
1884
|
+
if (taskCtx.status === "stopped" && event === "task_complete") {
|
|
1885
|
+
const stoppedAt = taskCtx.stoppedAt ?? 0;
|
|
1886
|
+
const ageMs = Date.now() - stoppedAt;
|
|
1887
|
+
if (stoppedAt > 0 && ageMs <= STOPPED_RECOVERY_WINDOW_MS) {
|
|
1888
|
+
this.log(`Recovering "${taskCtx.label}" from stopped on late task_complete (${Math.round(ageMs / 1000)}s old)`);
|
|
1889
|
+
taskCtx.status = "active";
|
|
1890
|
+
taskCtx.stoppedAt = undefined;
|
|
1891
|
+
recoveredFromStopped = true;
|
|
1892
|
+
}
|
|
1893
|
+
else {
|
|
1894
|
+
this.log(`Ignoring "${event}" for ${taskCtx.label} (status: stopped, age=${Math.round(ageMs / 1000)}s)`);
|
|
1895
|
+
return;
|
|
1896
|
+
}
|
|
1897
|
+
}
|
|
1898
|
+
if (!recoveredFromStopped && event !== "stopped" && event !== "error") {
|
|
1899
|
+
this.log(`Ignoring "${event}" for ${taskCtx.label} (status: ${taskCtx.status})`);
|
|
1900
|
+
return;
|
|
1901
|
+
}
|
|
1902
|
+
}
|
|
1903
|
+
// Update activity timestamp — resets idle watchdog for this session.
|
|
1904
|
+
// This runs before buffering so buffered events still reset the idle timer.
|
|
1905
|
+
taskCtx.lastActivityAt = Date.now();
|
|
1906
|
+
taskCtx.idleCheckCount = 0;
|
|
1907
|
+
// Buffer decision-making events when paused (user sent a chat message).
|
|
1908
|
+
// Auto-responses still flow through handleBlocked — only LLM decisions are deferred.
|
|
1909
|
+
if (this._paused && (event === "blocked" || event === "task_complete")) {
|
|
1910
|
+
// Auto-responded blocked events don't need LLM — let them through
|
|
1911
|
+
const blockedAutoResponded = event === "blocked" &&
|
|
1912
|
+
normalized.autoResponded === true;
|
|
1913
|
+
if (!blockedAutoResponded) {
|
|
1914
|
+
// Broadcast buffered state for dashboard visibility
|
|
1915
|
+
this.broadcast({
|
|
1916
|
+
type: event === "blocked" ? "blocked_buffered" : "turn_complete_buffered",
|
|
1917
|
+
sessionId,
|
|
1918
|
+
timestamp: Date.now(),
|
|
1919
|
+
data,
|
|
1920
|
+
});
|
|
1921
|
+
this.pauseBuffer.push(normalized);
|
|
1922
|
+
this.log(`Buffered "${event}" for ${taskCtx.label} (coordinator paused)`);
|
|
1923
|
+
return;
|
|
1924
|
+
}
|
|
1925
|
+
// Auto-responded: fall through to normal handling below
|
|
1926
|
+
}
|
|
1927
|
+
// Route by event type
|
|
1928
|
+
switch (event) {
|
|
1929
|
+
case "blocked": {
|
|
1930
|
+
const blockedEvent = normalized;
|
|
1931
|
+
const blockedPrompt = blockedEvent.promptText;
|
|
1932
|
+
if (this.isAutomaticFailoverFramework(taskCtx.agentType) &&
|
|
1933
|
+
isUsageExhaustedTaskAgentError(blockedPrompt)) {
|
|
1934
|
+
const failoverResult = await this.handleFrameworkDepletion(taskCtx, sessionId, blockedPrompt);
|
|
1935
|
+
taskCtx.status = "error";
|
|
1936
|
+
taskCtx.stoppedAt = Date.now();
|
|
1937
|
+
this.broadcast({
|
|
1938
|
+
type: "error",
|
|
1939
|
+
sessionId,
|
|
1940
|
+
timestamp: Date.now(),
|
|
1941
|
+
data: {
|
|
1942
|
+
message: blockedPrompt,
|
|
1943
|
+
source: "blocked_prompt",
|
|
1944
|
+
},
|
|
1945
|
+
});
|
|
1946
|
+
await this.taskRegistry.appendEvent({
|
|
1947
|
+
threadId: taskCtx.threadId,
|
|
1948
|
+
sessionId,
|
|
1949
|
+
eventType: "task_status_changed",
|
|
1950
|
+
summary: `Task "${taskCtx.label}" errored`,
|
|
1951
|
+
data: {
|
|
1952
|
+
status: "error",
|
|
1953
|
+
message: blockedPrompt,
|
|
1954
|
+
source: "blocked_prompt",
|
|
1955
|
+
},
|
|
1956
|
+
});
|
|
1957
|
+
this.ptyService?.stopSession(sessionId, true).catch((err) => {
|
|
1958
|
+
this.log(`Failed to stop exhausted session "${taskCtx.label}": ${err}`);
|
|
1959
|
+
});
|
|
1960
|
+
if (!failoverResult) {
|
|
1961
|
+
checkAllTasksComplete(this);
|
|
1962
|
+
}
|
|
1963
|
+
break;
|
|
1964
|
+
}
|
|
1965
|
+
await handleBlocked(this, sessionId, taskCtx, data);
|
|
1966
|
+
break;
|
|
1967
|
+
}
|
|
1968
|
+
case "task_complete": {
|
|
1969
|
+
// Broadcast immediately for UI visibility, but coalesce the
|
|
1970
|
+
// expensive LLM assessment — rapid turn-complete events within
|
|
1971
|
+
// 500ms are debounced so only the last one triggers an LLM call.
|
|
1972
|
+
this.broadcast({
|
|
1973
|
+
type: "turn_complete",
|
|
1974
|
+
sessionId,
|
|
1975
|
+
timestamp: Date.now(),
|
|
1976
|
+
data,
|
|
1977
|
+
});
|
|
1978
|
+
const existingCoalesce = this.turnCompleteCoalesceTimers.get(sessionId);
|
|
1979
|
+
if (existingCoalesce)
|
|
1980
|
+
clearTimeout(existingCoalesce);
|
|
1981
|
+
const coalescedData = data;
|
|
1982
|
+
const coalesceTimer = setTimeout(() => {
|
|
1983
|
+
this.turnCompleteCoalesceTimers.delete(sessionId);
|
|
1984
|
+
const currentTask = this.tasks.get(sessionId);
|
|
1985
|
+
// Accept both "active" and "tool_running" as live pre-validation
|
|
1986
|
+
// states. Subagents that use tools (curl, file ops, etc.) sit in
|
|
1987
|
+
// "tool_running" almost continuously, so by the time task_complete
|
|
1988
|
+
// arrives the status is usually "tool_running" — the prior strict
|
|
1989
|
+
// "=== active" check meant validation never ran for tool-heavy
|
|
1990
|
+
// scratch tasks, leaving them stuck and propagating goal failure
|
|
1991
|
+
// through the watchdog.
|
|
1992
|
+
if (currentTask &&
|
|
1993
|
+
(currentTask.status === "active" ||
|
|
1994
|
+
currentTask.status === "tool_running")) {
|
|
1995
|
+
handleTurnComplete(this, sessionId, currentTask, coalescedData).catch((err) => {
|
|
1996
|
+
this.log(`Coalesced turn-complete failed: ${err}`);
|
|
1997
|
+
});
|
|
1998
|
+
}
|
|
1999
|
+
}, TURN_COMPLETE_COALESCE_MS);
|
|
2000
|
+
this.turnCompleteCoalesceTimers.set(sessionId, coalesceTimer);
|
|
2001
|
+
break;
|
|
2002
|
+
}
|
|
2003
|
+
case "error": {
|
|
2004
|
+
this.broadcast({
|
|
2005
|
+
type: "error",
|
|
2006
|
+
sessionId,
|
|
2007
|
+
timestamp: Date.now(),
|
|
2008
|
+
data,
|
|
2009
|
+
});
|
|
2010
|
+
// Send error message to chat UI
|
|
2011
|
+
const errorMsg = data.message ?? "unknown error";
|
|
2012
|
+
const failoverResult = await this.handleFrameworkDepletion(taskCtx, sessionId, errorMsg);
|
|
2013
|
+
let recoveryResult = null;
|
|
2014
|
+
if (!failoverResult) {
|
|
2015
|
+
try {
|
|
2016
|
+
recoveryResult = await this.attemptTaskRecovery(taskCtx, errorMsg);
|
|
2017
|
+
}
|
|
2018
|
+
catch (recoveryError) {
|
|
2019
|
+
this.log(`Automatic error recovery failed for "${taskCtx.label}": ${recoveryError instanceof Error ? recoveryError.message : String(recoveryError)}`);
|
|
2020
|
+
}
|
|
2021
|
+
}
|
|
2022
|
+
if (recoveryResult) {
|
|
2023
|
+
this.sendChatMessage(`"${taskCtx.label}" hit an error: ${errorMsg}. Eliza is continuing the same task on ${recoveryResult.replacementFramework}.`, "coding-agent");
|
|
2024
|
+
}
|
|
2025
|
+
else if (!failoverResult) {
|
|
2026
|
+
this.sendChatMessage(`"${taskCtx.label}" hit an error and needs your attention: ${errorMsg}`, "coding-agent");
|
|
2027
|
+
}
|
|
2028
|
+
taskCtx.status = "error";
|
|
2029
|
+
await this.taskRegistry.appendEvent({
|
|
2030
|
+
threadId: taskCtx.threadId,
|
|
2031
|
+
sessionId,
|
|
2032
|
+
eventType: "task_status_changed",
|
|
2033
|
+
summary: `Task "${taskCtx.label}" errored`,
|
|
2034
|
+
data: { status: "error", message: errorMsg },
|
|
2035
|
+
});
|
|
2036
|
+
if (!failoverResult && !recoveryResult) {
|
|
2037
|
+
checkAllTasksComplete(this);
|
|
2038
|
+
}
|
|
2039
|
+
break;
|
|
2040
|
+
}
|
|
2041
|
+
case "stopped": {
|
|
2042
|
+
const alreadyTerminal = taskCtx.status === "completed" || taskCtx.status === "error";
|
|
2043
|
+
// Don't downgrade "completed" or "error" to "stopped" — the async
|
|
2044
|
+
// stopSession fires after executeDecision already marked the task.
|
|
2045
|
+
if (taskCtx.status !== "completed" && taskCtx.status !== "error") {
|
|
2046
|
+
taskCtx.status = "stopped";
|
|
2047
|
+
taskCtx.stoppedAt = Date.now();
|
|
2048
|
+
}
|
|
2049
|
+
this.inFlightDecisions.delete(sessionId);
|
|
2050
|
+
this.broadcast({
|
|
2051
|
+
type: "stopped",
|
|
2052
|
+
sessionId,
|
|
2053
|
+
timestamp: Date.now(),
|
|
2054
|
+
data,
|
|
2055
|
+
});
|
|
2056
|
+
await this.taskRegistry.appendEvent({
|
|
2057
|
+
threadId: taskCtx.threadId,
|
|
2058
|
+
sessionId,
|
|
2059
|
+
eventType: "task_status_changed",
|
|
2060
|
+
summary: `Task "${taskCtx.label}" stopped`,
|
|
2061
|
+
data: { status: taskCtx.status },
|
|
2062
|
+
});
|
|
2063
|
+
if (!alreadyTerminal && !taskCtx.suppressStopNotice) {
|
|
2064
|
+
this.sendChatMessage(`"${taskCtx.label}" stopped before completion.`, "coding-agent");
|
|
2065
|
+
}
|
|
2066
|
+
checkAllTasksComplete(this);
|
|
2067
|
+
break;
|
|
2068
|
+
}
|
|
2069
|
+
case "ready":
|
|
2070
|
+
taskCtx.status = "active";
|
|
2071
|
+
if (taskCtx.agentType === "claude" ||
|
|
2072
|
+
taskCtx.agentType === "codex" ||
|
|
2073
|
+
taskCtx.agentType === "gemini" ||
|
|
2074
|
+
taskCtx.agentType === "aider") {
|
|
2075
|
+
markTaskAgentFrameworkHealthy(taskCtx.agentType);
|
|
2076
|
+
}
|
|
2077
|
+
this.broadcast({
|
|
2078
|
+
type: "ready",
|
|
2079
|
+
sessionId,
|
|
2080
|
+
timestamp: Date.now(),
|
|
2081
|
+
data,
|
|
2082
|
+
});
|
|
2083
|
+
await this.taskRegistry.appendEvent({
|
|
2084
|
+
threadId: taskCtx.threadId,
|
|
2085
|
+
sessionId,
|
|
2086
|
+
eventType: "session_updated",
|
|
2087
|
+
summary: `Session "${taskCtx.label}" ready`,
|
|
2088
|
+
data: { status: "ready" },
|
|
2089
|
+
});
|
|
2090
|
+
break;
|
|
2091
|
+
case "login_required": {
|
|
2092
|
+
const loginEvent = normalized;
|
|
2093
|
+
let recoveryResult = null;
|
|
2094
|
+
try {
|
|
2095
|
+
if (this.ptyService &&
|
|
2096
|
+
(taskCtx.agentType === "claude" ||
|
|
2097
|
+
taskCtx.agentType === "codex" ||
|
|
2098
|
+
taskCtx.agentType === "gemini" ||
|
|
2099
|
+
taskCtx.agentType === "aider")) {
|
|
2100
|
+
recoveryResult = await this.ptyService.startSessionAuthRecovery(sessionId, taskCtx.agentType, {
|
|
2101
|
+
instructions: loginEvent.instructions,
|
|
2102
|
+
url: loginEvent.url,
|
|
2103
|
+
deviceCode: loginEvent.deviceCode,
|
|
2104
|
+
method: loginEvent.method,
|
|
2105
|
+
promptSnippet: loginEvent.promptSnippet,
|
|
2106
|
+
});
|
|
2107
|
+
}
|
|
2108
|
+
}
|
|
2109
|
+
catch (error) {
|
|
2110
|
+
this.log(`Provider auth recovery failed for "${taskCtx.label}": ${error instanceof Error ? error.message : String(error)}`);
|
|
2111
|
+
}
|
|
2112
|
+
if (recoveryResult?.status === "recovered") {
|
|
2113
|
+
if (recoveryResult.recoveryTarget === "replacement_session") {
|
|
2114
|
+
break;
|
|
2115
|
+
}
|
|
2116
|
+
await this.markTaskResumedAfterProviderAuth(sessionId);
|
|
2117
|
+
break;
|
|
2118
|
+
}
|
|
2119
|
+
taskCtx.status = "blocked";
|
|
2120
|
+
this.broadcast({
|
|
2121
|
+
type: "login_required",
|
|
2122
|
+
sessionId,
|
|
2123
|
+
timestamp: Date.now(),
|
|
2124
|
+
data,
|
|
2125
|
+
});
|
|
2126
|
+
await this.taskRegistry.appendEvent({
|
|
2127
|
+
threadId: taskCtx.threadId,
|
|
2128
|
+
sessionId,
|
|
2129
|
+
eventType: "task_status_changed",
|
|
2130
|
+
summary: `Task "${taskCtx.label}" is waiting for login`,
|
|
2131
|
+
data: {
|
|
2132
|
+
status: "blocked",
|
|
2133
|
+
reason: "login_required",
|
|
2134
|
+
instructions: loginEvent.instructions ?? null,
|
|
2135
|
+
url: loginEvent.url ?? null,
|
|
2136
|
+
deviceCode: loginEvent.deviceCode ?? null,
|
|
2137
|
+
method: loginEvent.method ?? null,
|
|
2138
|
+
recoveryStatus: recoveryResult?.status ?? null,
|
|
2139
|
+
},
|
|
2140
|
+
});
|
|
2141
|
+
const loginParts = [
|
|
2142
|
+
recoveryResult?.status === "recovering"
|
|
2143
|
+
? `"${taskCtx.label}" needs provider authentication, and Eliza has started the recovery flow. It will continue automatically when sign-in completes.`
|
|
2144
|
+
: `"${taskCtx.label}" needs a provider login before it can continue.`,
|
|
2145
|
+
recoveryResult?.instructions?.trim() ||
|
|
2146
|
+
loginEvent.instructions?.trim() ||
|
|
2147
|
+
"",
|
|
2148
|
+
recoveryResult?.deviceCode || loginEvent.deviceCode
|
|
2149
|
+
? `Device code: ${recoveryResult?.deviceCode ?? loginEvent.deviceCode}`
|
|
2150
|
+
: "",
|
|
2151
|
+
recoveryResult?.browserDetail || "",
|
|
2152
|
+
loginEvent.url ? `Login link: ${loginEvent.url}` : "",
|
|
2153
|
+
recoveryResult?.url && recoveryResult.url !== loginEvent.url
|
|
2154
|
+
? `Login link: ${recoveryResult.url}`
|
|
2155
|
+
: "",
|
|
2156
|
+
].filter(Boolean);
|
|
2157
|
+
this.sendChatMessage(loginParts.join(" "), "coding-agent");
|
|
2158
|
+
break;
|
|
2159
|
+
}
|
|
2160
|
+
case "tool_running": {
|
|
2161
|
+
// Agent is actively working via an external tool — keep watchdog happy
|
|
2162
|
+
taskCtx.status = "tool_running";
|
|
2163
|
+
taskCtx.lastActivityAt = Date.now();
|
|
2164
|
+
taskCtx.idleCheckCount = 0;
|
|
2165
|
+
this.broadcast({
|
|
2166
|
+
type: "tool_running",
|
|
2167
|
+
sessionId,
|
|
2168
|
+
timestamp: Date.now(),
|
|
2169
|
+
data,
|
|
2170
|
+
});
|
|
2171
|
+
// Hook-sourced tool_running events fire for every tool call.
|
|
2172
|
+
// Only broadcast to SSE (for activity box) — skip chat messages.
|
|
2173
|
+
const toolData = data;
|
|
2174
|
+
if (toolData.source === "hook") {
|
|
2175
|
+
break;
|
|
2176
|
+
}
|
|
2177
|
+
// Throttle chat notifications: at most one per 30s per session.
|
|
2178
|
+
// Suppress during the first 10s after registration — startup status
|
|
2179
|
+
// lines (e.g. "Claude in Chrome enabled") can trigger tool_running
|
|
2180
|
+
// before the agent has actually begun working.
|
|
2181
|
+
const now = Date.now();
|
|
2182
|
+
const STARTUP_GRACE_MS = 10_000;
|
|
2183
|
+
if (now - taskCtx.registeredAt < STARTUP_GRACE_MS) {
|
|
2184
|
+
break;
|
|
2185
|
+
}
|
|
2186
|
+
const lastNotif = this.lastToolNotification.get(sessionId) ?? 0;
|
|
2187
|
+
if (now - lastNotif > 30_000) {
|
|
2188
|
+
this.lastToolNotification.set(sessionId, now);
|
|
2189
|
+
const toolDesc = toolData.description ?? toolData.toolName ?? "an external tool";
|
|
2190
|
+
// Try to extract a dev server URL from recent output
|
|
2191
|
+
let urlSuffix = "";
|
|
2192
|
+
if (this.ptyService) {
|
|
2193
|
+
try {
|
|
2194
|
+
const recentOutput = await this.ptyService.getSessionOutput(sessionId, 50);
|
|
2195
|
+
const devUrl = extractDevServerUrl(recentOutput);
|
|
2196
|
+
if (devUrl) {
|
|
2197
|
+
urlSuffix = ` Dev server running at ${devUrl}`;
|
|
2198
|
+
}
|
|
2199
|
+
}
|
|
2200
|
+
catch {
|
|
2201
|
+
// Best-effort — don't block on failure
|
|
2202
|
+
}
|
|
2203
|
+
}
|
|
2204
|
+
const message = `[${taskCtx.label}] Running ${toolDesc}.${urlSuffix} The agent is working outside the terminal.`;
|
|
2205
|
+
this.log(message);
|
|
2206
|
+
this.sendChatMessage(message, "coding-agent");
|
|
2207
|
+
}
|
|
2208
|
+
break;
|
|
2209
|
+
}
|
|
2210
|
+
default:
|
|
2211
|
+
// Broadcast unknown events for observability
|
|
2212
|
+
this.broadcast({
|
|
2213
|
+
type: event,
|
|
2214
|
+
sessionId,
|
|
2215
|
+
timestamp: Date.now(),
|
|
2216
|
+
data,
|
|
2217
|
+
});
|
|
2218
|
+
}
|
|
2219
|
+
await this.syncTaskContext(taskCtx);
|
|
2220
|
+
}
|
|
2221
|
+
// ─── LLM Decision (delegated) ───
|
|
2222
|
+
async makeCoordinationDecision(taskCtx, promptText, recentOutput) {
|
|
2223
|
+
// Re-export for backward compatibility — delegates to module function
|
|
2224
|
+
const { makeCoordinationDecision: mkDecision } = await import("./swarm-decision-loop.js");
|
|
2225
|
+
return mkDecision(this, taskCtx, promptText, recentOutput);
|
|
2226
|
+
}
|
|
2227
|
+
async executeDecision(sessionId, decision) {
|
|
2228
|
+
return execDecision(this, sessionId, decision);
|
|
2229
|
+
}
|
|
2230
|
+
/**
|
|
2231
|
+
* Public entry point for external callers (e.g. server.ts) to execute
|
|
2232
|
+
* a coordination decision on a session. Wraps the internal executeDecision.
|
|
2233
|
+
*/
|
|
2234
|
+
async executeEventDecision(sessionId, decision) {
|
|
2235
|
+
return execDecision(this, sessionId, decision);
|
|
2236
|
+
}
|
|
2237
|
+
// ─── Supervision ───
|
|
2238
|
+
setSupervisionLevel(level) {
|
|
2239
|
+
this.supervisionLevel = level;
|
|
2240
|
+
this.broadcast({
|
|
2241
|
+
type: "supervision_changed",
|
|
2242
|
+
sessionId: "*",
|
|
2243
|
+
timestamp: Date.now(),
|
|
2244
|
+
data: { level },
|
|
2245
|
+
});
|
|
2246
|
+
this.log(`Supervision level set to: ${level}`);
|
|
2247
|
+
}
|
|
2248
|
+
getSupervisionLevel() {
|
|
2249
|
+
return this.supervisionLevel;
|
|
2250
|
+
}
|
|
2251
|
+
// ─── Confirmation Queue ───
|
|
2252
|
+
getPendingConfirmations() {
|
|
2253
|
+
return Array.from(this.pendingDecisions.values());
|
|
2254
|
+
}
|
|
2255
|
+
async confirmDecision(sessionId, approved, override) {
|
|
2256
|
+
const pending = this.pendingDecisions.get(sessionId);
|
|
2257
|
+
if (!pending) {
|
|
2258
|
+
throw new Error(`No pending decision for session ${sessionId}`);
|
|
2259
|
+
}
|
|
2260
|
+
const taskCtx = this.tasks.get(sessionId);
|
|
2261
|
+
if (approved) {
|
|
2262
|
+
// Use override if provided, otherwise use LLM suggestion
|
|
2263
|
+
const decision = override
|
|
2264
|
+
? {
|
|
2265
|
+
action: "respond",
|
|
2266
|
+
response: override.response,
|
|
2267
|
+
useKeys: override.useKeys,
|
|
2268
|
+
keys: override.keys,
|
|
2269
|
+
reasoning: "Human-approved (with override)",
|
|
2270
|
+
}
|
|
2271
|
+
: pending.llmDecision;
|
|
2272
|
+
if (taskCtx) {
|
|
2273
|
+
taskCtx.status = "active";
|
|
2274
|
+
taskCtx.autoResolvedCount = 0;
|
|
2275
|
+
await this.recordDecision(taskCtx, {
|
|
2276
|
+
timestamp: Date.now(),
|
|
2277
|
+
event: "blocked",
|
|
2278
|
+
promptText: pending.promptText,
|
|
2279
|
+
decision: decision.action,
|
|
2280
|
+
response: decision.action === "respond"
|
|
2281
|
+
? decision.useKeys
|
|
2282
|
+
? `keys:${decision.keys?.join(",")}`
|
|
2283
|
+
: decision.response
|
|
2284
|
+
: undefined,
|
|
2285
|
+
reasoning: `Human-approved: ${decision.reasoning}`,
|
|
2286
|
+
});
|
|
2287
|
+
await this.syncTaskContext(taskCtx);
|
|
2288
|
+
}
|
|
2289
|
+
await this.executeDecision(sessionId, decision);
|
|
2290
|
+
this.pendingDecisions.delete(sessionId);
|
|
2291
|
+
await this.taskRegistry.deletePendingDecision(sessionId);
|
|
2292
|
+
if (taskCtx) {
|
|
2293
|
+
await this.taskRegistry.appendEvent({
|
|
2294
|
+
threadId: taskCtx.threadId,
|
|
2295
|
+
sessionId,
|
|
2296
|
+
eventType: "confirmation_approved",
|
|
2297
|
+
summary: `Approved pending confirmation for "${taskCtx.label}"`,
|
|
2298
|
+
data: {
|
|
2299
|
+
action: decision.action,
|
|
2300
|
+
response: decision.response ?? null,
|
|
2301
|
+
},
|
|
2302
|
+
});
|
|
2303
|
+
}
|
|
2304
|
+
this.broadcast({
|
|
2305
|
+
type: "confirmation_approved",
|
|
2306
|
+
sessionId,
|
|
2307
|
+
timestamp: Date.now(),
|
|
2308
|
+
data: {
|
|
2309
|
+
action: decision.action,
|
|
2310
|
+
response: decision.response,
|
|
2311
|
+
useKeys: decision.useKeys,
|
|
2312
|
+
keys: decision.keys,
|
|
2313
|
+
},
|
|
2314
|
+
});
|
|
2315
|
+
if (taskCtx) {
|
|
2316
|
+
this.sendChatMessage(`"${taskCtx.label}" was approved. Eliza is continuing the task now.`, "coding-agent");
|
|
2317
|
+
}
|
|
2318
|
+
}
|
|
2319
|
+
else {
|
|
2320
|
+
// Rejected — record and broadcast
|
|
2321
|
+
if (taskCtx) {
|
|
2322
|
+
taskCtx.status = "blocked";
|
|
2323
|
+
await this.recordDecision(taskCtx, {
|
|
2324
|
+
timestamp: Date.now(),
|
|
2325
|
+
event: "blocked",
|
|
2326
|
+
promptText: pending.promptText,
|
|
2327
|
+
decision: "escalate",
|
|
2328
|
+
reasoning: "Human rejected the suggested action",
|
|
2329
|
+
});
|
|
2330
|
+
await this.syncTaskContext(taskCtx);
|
|
2331
|
+
}
|
|
2332
|
+
this.pendingDecisions.delete(sessionId);
|
|
2333
|
+
await this.taskRegistry.deletePendingDecision(sessionId);
|
|
2334
|
+
if (pending.taskContext.threadId) {
|
|
2335
|
+
await this.taskRegistry.appendEvent({
|
|
2336
|
+
threadId: pending.taskContext.threadId,
|
|
2337
|
+
sessionId,
|
|
2338
|
+
eventType: "confirmation_rejected",
|
|
2339
|
+
summary: `Rejected pending confirmation for "${pending.taskContext.label}"`,
|
|
2340
|
+
data: { prompt: pending.promptText },
|
|
2341
|
+
});
|
|
2342
|
+
}
|
|
2343
|
+
this.broadcast({
|
|
2344
|
+
type: "confirmation_rejected",
|
|
2345
|
+
sessionId,
|
|
2346
|
+
timestamp: Date.now(),
|
|
2347
|
+
data: { prompt: pending.promptText },
|
|
2348
|
+
});
|
|
2349
|
+
this.sendChatMessage(`"${pending.taskContext.label}" remains blocked after the suggested action was rejected. Prompt: ${pending.promptText}`, "coding-agent");
|
|
2350
|
+
}
|
|
2351
|
+
}
|
|
2352
|
+
// ─── Internal ───
|
|
2353
|
+
log(message) {
|
|
2354
|
+
logger.info(`[SwarmCoordinator] ${message}`);
|
|
2355
|
+
}
|
|
2356
|
+
}
|