@celljs/ta 4.10.0 → 4.11.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.en.md +3 -1
- package/README.md +3 -1
- package/dist/cli.mjs +1675 -51
- package/dist/gateway.mjs +167 -5
- package/dist/pi/CHANGELOG.md +23 -0
- package/dist/pi/package.json +1 -1
- package/dist/pi/packages/ta-agents/extension/index.mjs +166 -139
- package/dist/pi/packages/ta-agents/lib/acp-agent.js +30 -10
- package/dist/pi/packages/ta-agents/lib/agent-catalog.d.ts +2 -2
- package/dist/pi/packages/ta-agents/lib/agent-catalog.js +4 -4
- package/dist/pi/packages/ta-agents/lib/agent-prompt.d.ts +6 -0
- package/dist/pi/packages/ta-agents/lib/agent-prompt.js +19 -0
- package/dist/pi/packages/ta-agents/lib/agent-session.d.ts +2 -0
- package/dist/pi/packages/ta-agents/lib/agent-session.js +2 -0
- package/dist/pi/packages/ta-agents/lib/agent-streamer.js +7 -0
- package/dist/pi/packages/ta-agents/lib/agent-tool.js +3 -2
- package/dist/pi/packages/ta-agents/package.json +1 -1
- package/dist/pi/packages/ta-bots/extension/index.mjs +31 -299
- package/dist/pi/packages/ta-bots/host/index.mjs +143 -1
- package/dist/pi/packages/ta-bots/lib/bots-protocol.d.ts +2 -0
- package/dist/pi/packages/ta-bots/lib/bots-protocol.js +3 -1
- package/dist/pi/packages/ta-bots/lib/bots-view.js +24 -12
- package/dist/pi/packages/ta-bots/lib/composer.js +1 -0
- package/dist/pi/packages/ta-bots/lib/extension.js +10 -17
- package/dist/pi/packages/ta-bots/lib/i18n.d.ts +1 -0
- package/dist/pi/packages/ta-bots/lib/i18n.js +2 -0
- package/dist/pi/packages/ta-bots/lib/index.js +2 -0
- package/dist/pi/packages/ta-bots/lib/style.d.ts +1 -1
- package/dist/pi/packages/ta-bots/lib/style.js +1 -0
- package/dist/pi/packages/ta-bots/lib/text-util.js +8 -1
- package/dist/pi/packages/ta-bots/lib/tool-line.d.ts +8 -0
- package/dist/pi/packages/ta-bots/lib/tool-line.js +19 -0
- package/dist/pi/packages/ta-bots/package.json +1 -1
- package/dist/pi/packages/ta-bots/web/index.js +47 -16
- package/dist/pi/packages/ta-changes/extension/index.mjs +23 -13
- package/dist/pi/packages/ta-changes/lib/card.js +18 -4
- package/dist/pi/packages/ta-changes/lib/changes-protocol.d.ts +0 -4
- package/dist/pi/packages/ta-changes/lib/changes-protocol.js +1 -5
- package/dist/pi/packages/ta-changes/lib/extension.js +5 -13
- package/dist/pi/packages/ta-changes/package.json +1 -1
- package/dist/pi/packages/ta-changes/web/index.js +16 -3
- package/dist/pi/packages/ta-channels/README.en.md +4 -3
- package/dist/pi/packages/ta-channels/README.md +4 -3
- package/dist/pi/packages/ta-channels/extension/index.mjs +350 -28
- package/dist/pi/packages/ta-channels/host/index.mjs +588 -43
- package/dist/pi/packages/ta-channels/lib/agent-cards.d.ts +19 -0
- package/dist/pi/packages/ta-channels/lib/agent-cards.js +58 -0
- package/dist/pi/packages/ta-channels/lib/agent-menu.d.ts +2 -2
- package/dist/pi/packages/ta-channels/lib/agent-menu.js +20 -6
- package/dist/pi/packages/ta-channels/lib/card.d.ts +27 -0
- package/dist/pi/packages/ta-channels/lib/card.js +178 -0
- package/dist/pi/packages/ta-channels/lib/channels-model.d.ts +65 -13
- package/dist/pi/packages/ta-channels/lib/channels-model.js +15 -6
- package/dist/pi/packages/ta-channels/lib/channels-util.d.ts +31 -2
- package/dist/pi/packages/ta-channels/lib/channels-util.js +100 -6
- package/dist/pi/packages/ta-channels/lib/channels.d.ts +28 -18
- package/dist/pi/packages/ta-channels/lib/channels.js +65 -65
- package/dist/pi/packages/ta-channels/lib/create.js +3 -1
- package/dist/pi/packages/ta-channels/lib/extension.d.ts +8 -0
- package/dist/pi/packages/ta-channels/lib/extension.js +104 -18
- package/dist/pi/packages/ta-channels/lib/faces.d.ts +2 -0
- package/dist/pi/packages/ta-channels/lib/faces.js +6 -0
- package/dist/pi/packages/ta-channels/lib/handoff-view.d.ts +19 -0
- package/dist/pi/packages/ta-channels/lib/handoff-view.js +113 -0
- package/dist/pi/packages/ta-channels/lib/handoff.d.ts +67 -0
- package/dist/pi/packages/ta-channels/lib/handoff.js +114 -0
- package/dist/pi/packages/ta-channels/lib/host.d.ts +1 -1
- package/dist/pi/packages/ta-channels/lib/host.js +1 -1
- package/dist/pi/packages/ta-channels/lib/i18n.d.ts +45 -0
- package/dist/pi/packages/ta-channels/lib/i18n.js +90 -0
- package/dist/pi/packages/ta-channels/lib/index.js +10 -1
- package/dist/pi/packages/ta-channels/lib/member-tools.d.ts +23 -0
- package/dist/pi/packages/ta-channels/lib/member-tools.js +56 -0
- package/dist/pi/packages/ta-channels/lib/members.js +6 -2
- package/dist/pi/packages/ta-channels/lib/notice.d.ts +25 -0
- package/dist/pi/packages/ta-channels/lib/notice.js +101 -0
- package/dist/pi/packages/ta-channels/lib/room.js +13 -2
- package/dist/pi/packages/ta-channels/lib/sidebar.d.ts +1 -6
- package/dist/pi/packages/ta-channels/lib/sidebar.js +132 -69
- package/dist/pi/packages/ta-channels/lib/style.d.ts +1 -1
- package/dist/pi/packages/ta-channels/lib/style.js +69 -4
- package/dist/pi/packages/ta-channels/lib/team.d.ts +58 -10
- package/dist/pi/packages/ta-channels/lib/team.js +159 -38
- package/dist/pi/packages/ta-channels/lib/tool-lines.d.ts +22 -0
- package/dist/pi/packages/ta-channels/lib/tool-lines.js +113 -0
- package/dist/pi/packages/ta-channels/lib/views.d.ts +21 -16
- package/dist/pi/packages/ta-channels/lib/views.js +60 -31
- package/dist/pi/packages/ta-channels/package.json +2 -1
- package/dist/pi/packages/ta-channels/web/index.js +1507 -309
- package/dist/pi/packages/ta-computer-use/package.json +6 -1
- package/dist/pi/packages/ta-cron/README.en.md +4 -2
- package/dist/pi/packages/ta-cron/README.md +4 -2
- package/dist/pi/packages/ta-cron/extension/index.mjs +416 -44
- package/dist/pi/packages/ta-cron/host/index.mjs +24 -3
- package/dist/pi/packages/ta-cron/lib/chat-task.d.ts +48 -0
- package/dist/pi/packages/ta-cron/lib/chat-task.js +133 -0
- package/dist/pi/packages/ta-cron/lib/commands.d.ts +2 -1
- package/dist/pi/packages/ta-cron/lib/commands.js +10 -4
- package/dist/pi/packages/ta-cron/lib/composer.d.ts +11 -0
- package/dist/pi/packages/ta-cron/lib/composer.js +58 -0
- package/dist/pi/packages/ta-cron/lib/cron-protocol.d.ts +10 -3
- package/dist/pi/packages/ta-cron/lib/cron-protocol.js +6 -3
- package/dist/pi/packages/ta-cron/lib/editor.js +5 -3
- package/dist/pi/packages/ta-cron/lib/extension.d.ts +2 -0
- package/dist/pi/packages/ta-cron/lib/extension.js +33 -13
- package/dist/pi/packages/ta-cron/lib/i18n.d.ts +18 -0
- package/dist/pi/packages/ta-cron/lib/i18n.js +36 -0
- package/dist/pi/packages/ta-cron/lib/index.js +4 -0
- package/dist/pi/packages/ta-cron/lib/page.d.ts +5 -1
- package/dist/pi/packages/ta-cron/lib/page.js +12 -0
- package/dist/pi/packages/ta-cron/lib/react.d.ts +3 -0
- package/dist/pi/packages/ta-cron/lib/react.js +8 -0
- package/dist/pi/packages/ta-cron/lib/scheduler.js +3 -2
- package/dist/pi/packages/ta-cron/lib/style.d.ts +1 -1
- package/dist/pi/packages/ta-cron/lib/style.js +11 -13
- package/dist/pi/packages/ta-cron/lib/task-util.d.ts +2 -0
- package/dist/pi/packages/ta-cron/lib/task-util.js +20 -1
- package/dist/pi/packages/ta-cron/lib/tasks-view.js +6 -2
- package/dist/pi/packages/ta-cron/lib/tool-line.d.ts +9 -0
- package/dist/pi/packages/ta-cron/lib/tool-line.js +40 -0
- package/dist/pi/packages/ta-cron/lib/tool.d.ts +5 -1
- package/dist/pi/packages/ta-cron/lib/tool.js +6 -3
- package/dist/pi/packages/ta-cron/package.json +12 -1
- package/dist/pi/packages/ta-cron/web/index.js +661 -254
- package/dist/pi/packages/ta-extensions/README.en.md +1 -1
- package/dist/pi/packages/ta-extensions/README.md +1 -1
- package/dist/pi/packages/ta-extensions/host/index.mjs +3 -2
- package/dist/pi/packages/ta-extensions/lib/actions.d.ts +4 -0
- package/dist/pi/packages/ta-extensions/lib/actions.js +13 -4
- package/dist/pi/packages/ta-extensions/lib/extensions-util.d.ts +5 -0
- package/dist/pi/packages/ta-extensions/lib/extensions-util.js +10 -0
- package/dist/pi/packages/ta-extensions/lib/market-parts.js +8 -2
- package/dist/pi/packages/ta-extensions/lib/market-style.d.ts +1 -1
- package/dist/pi/packages/ta-extensions/lib/market-style.js +4 -5
- package/dist/pi/packages/ta-extensions/lib/market-util.d.ts +2 -2
- package/dist/pi/packages/ta-extensions/lib/market-util.js +2 -2
- package/dist/pi/packages/ta-extensions/lib/page.js +12 -7
- package/dist/pi/packages/ta-extensions/lib/react.d.ts +3 -0
- package/dist/pi/packages/ta-extensions/lib/react.js +8 -0
- package/dist/pi/packages/ta-extensions/lib/style.d.ts +1 -1
- package/dist/pi/packages/ta-extensions/lib/style.js +3 -2
- package/dist/pi/packages/ta-extensions/package.json +6 -1
- package/dist/pi/packages/ta-extensions/skills/ta-package/SKILL.md +19 -8
- package/dist/pi/packages/ta-extensions/web/index.js +191 -22
- package/dist/pi/packages/ta-games/README.en.md +47 -0
- package/dist/pi/packages/ta-games/README.md +47 -0
- package/dist/pi/packages/ta-games/host/index.mjs +65 -0
- package/dist/pi/packages/ta-games/lib/games-view.d.ts +16 -0
- package/dist/pi/packages/ta-games/lib/games-view.js +77 -0
- package/dist/pi/packages/ta-games/lib/host.d.ts +36 -0
- package/dist/pi/packages/ta-games/lib/host.js +83 -0
- package/dist/pi/packages/ta-games/lib/i18n.d.ts +35 -0
- package/dist/pi/packages/ta-games/lib/i18n.js +71 -0
- package/dist/pi/packages/ta-games/lib/ideas.d.ts +6 -0
- package/dist/pi/packages/ta-games/lib/ideas.js +62 -0
- package/dist/pi/packages/ta-games/lib/index.d.ts +7 -0
- package/dist/pi/packages/ta-games/lib/index.js +24 -0
- package/dist/pi/packages/ta-games/lib/make-game.d.ts +23 -0
- package/dist/pi/packages/ta-games/lib/make-game.js +67 -0
- package/dist/pi/packages/ta-games/lib/react.d.ts +11 -0
- package/dist/pi/packages/ta-games/lib/react.js +16 -0
- package/dist/pi/packages/ta-games/lib/style.d.ts +4 -0
- package/dist/pi/packages/ta-games/lib/style.js +33 -0
- package/dist/pi/packages/ta-games/package.json +60 -0
- package/dist/pi/packages/ta-games/skills/ta-game/SKILL.md +127 -0
- package/dist/pi/packages/ta-games/skills/ta-game/examples/dino-run/package.json +22 -0
- package/dist/pi/packages/ta-games/skills/ta-game/examples/dino-run/web.js +389 -0
- package/dist/pi/packages/ta-games/skills/ta-game/examples/stack/package.json +22 -0
- package/dist/pi/packages/ta-games/skills/ta-game/examples/stack/web.js +423 -0
- package/dist/pi/packages/ta-games/skills/ta-game/phaser/LICENSE.md +22 -0
- package/dist/pi/packages/ta-games/skills/ta-game/phaser/actions-and-utilities/SKILL.md +343 -0
- package/dist/pi/packages/ta-games/skills/ta-game/phaser/animations/SKILL.md +481 -0
- package/dist/pi/packages/ta-games/skills/ta-game/phaser/audio-and-sound/SKILL.md +453 -0
- package/dist/pi/packages/ta-games/skills/ta-game/phaser/cameras/SKILL.md +497 -0
- package/dist/pi/packages/ta-games/skills/ta-game/phaser/cameras/references/REFERENCE.md +128 -0
- package/dist/pi/packages/ta-games/skills/ta-game/phaser/curves-and-paths/SKILL.md +359 -0
- package/dist/pi/packages/ta-games/skills/ta-game/phaser/data-manager/SKILL.md +406 -0
- package/dist/pi/packages/ta-games/skills/ta-game/phaser/events-system/SKILL.md +497 -0
- package/dist/pi/packages/ta-games/skills/ta-game/phaser/filters-and-postfx/SKILL.md +449 -0
- package/dist/pi/packages/ta-games/skills/ta-game/phaser/game-object-components/SKILL.md +478 -0
- package/dist/pi/packages/ta-games/skills/ta-game/phaser/game-object-components/references/REFERENCE.md +76 -0
- package/dist/pi/packages/ta-games/skills/ta-game/phaser/game-setup-and-config/SKILL.md +485 -0
- package/dist/pi/packages/ta-games/skills/ta-game/phaser/geometry-and-math/SKILL.md +497 -0
- package/dist/pi/packages/ta-games/skills/ta-game/phaser/graphics-and-shapes/SKILL.md +473 -0
- package/dist/pi/packages/ta-games/skills/ta-game/phaser/groups-and-containers/SKILL.md +418 -0
- package/dist/pi/packages/ta-games/skills/ta-game/phaser/input-keyboard-mouse-touch/SKILL.md +500 -0
- package/dist/pi/packages/ta-games/skills/ta-game/phaser/input-keyboard-mouse-touch/references/REFERENCE.md +372 -0
- package/dist/pi/packages/ta-games/skills/ta-game/phaser/loading-assets/SKILL.md +474 -0
- package/dist/pi/packages/ta-games/skills/ta-game/phaser/loading-assets/references/REFERENCE.md +148 -0
- package/dist/pi/packages/ta-games/skills/ta-game/phaser/particles/SKILL.md +499 -0
- package/dist/pi/packages/ta-games/skills/ta-game/phaser/particles/references/REFERENCE.md +17 -0
- package/dist/pi/packages/ta-games/skills/ta-game/phaser/physics-arcade/SKILL.md +468 -0
- package/dist/pi/packages/ta-games/skills/ta-game/phaser/physics-matter/SKILL.md +499 -0
- package/dist/pi/packages/ta-games/skills/ta-game/phaser/render-textures/SKILL.md +441 -0
- package/dist/pi/packages/ta-games/skills/ta-game/phaser/scale-and-responsive/SKILL.md +371 -0
- package/dist/pi/packages/ta-games/skills/ta-game/phaser/scenes/SKILL.md +450 -0
- package/dist/pi/packages/ta-games/skills/ta-game/phaser/scenes/references/REFERENCE.md +78 -0
- package/dist/pi/packages/ta-games/skills/ta-game/phaser/sprites-and-images/SKILL.md +417 -0
- package/dist/pi/packages/ta-games/skills/ta-game/phaser/sprites-and-images/references/REFERENCE.md +160 -0
- package/dist/pi/packages/ta-games/skills/ta-game/phaser/text-and-bitmaptext/SKILL.md +460 -0
- package/dist/pi/packages/ta-games/skills/ta-game/phaser/tilemaps/SKILL.md +440 -0
- package/dist/pi/packages/ta-games/skills/ta-game/phaser/time-and-timers/SKILL.md +496 -0
- package/dist/pi/packages/ta-games/skills/ta-game/phaser/tweens/SKILL.md +414 -0
- package/dist/pi/packages/ta-games/skills/ta-game/phaser/v3-to-v4-migration/SKILL.md +430 -0
- package/dist/pi/packages/ta-games/skills/ta-game/phaser/v4-new-features/SKILL.md +384 -0
- package/dist/pi/packages/ta-games/skills/ta-game/phaser/v4-new-features/references/REFERENCE.md +69 -0
- package/dist/pi/packages/ta-games/web/index.js +431 -0
- package/dist/pi/packages/ta-glance/README.en.md +11 -0
- package/dist/pi/packages/ta-glance/README.md +11 -0
- package/dist/pi/packages/ta-glance/extension/index.mjs +67 -0
- package/dist/pi/packages/ta-glance/lib/card.d.ts +8 -0
- package/dist/pi/packages/ta-glance/lib/card.js +268 -0
- package/dist/pi/packages/ta-glance/lib/extension.d.ts +15 -0
- package/dist/pi/packages/ta-glance/lib/extension.js +24 -0
- package/dist/pi/packages/ta-glance/lib/glance-json.d.ts +9 -0
- package/dist/pi/packages/ta-glance/lib/glance-json.js +85 -0
- package/dist/pi/packages/ta-glance/lib/glance-prompt.d.ts +7 -0
- package/dist/pi/packages/ta-glance/lib/glance-prompt.js +34 -0
- package/dist/pi/packages/ta-glance/lib/glance-protocol.d.ts +98 -0
- package/dist/pi/packages/ta-glance/lib/glance-protocol.js +8 -0
- package/dist/pi/packages/ta-glance/lib/glance-spec.d.ts +6 -0
- package/dist/pi/packages/ta-glance/lib/glance-spec.js +204 -0
- package/dist/pi/packages/ta-glance/lib/glance-util.d.ts +3 -0
- package/dist/pi/packages/ta-glance/lib/glance-util.js +12 -0
- package/dist/pi/packages/ta-glance/lib/i18n.d.ts +22 -0
- package/dist/pi/packages/ta-glance/lib/i18n.js +41 -0
- package/dist/pi/packages/ta-glance/lib/index.d.ts +7 -0
- package/dist/pi/packages/ta-glance/lib/index.js +22 -0
- package/dist/pi/packages/ta-glance/lib/react.d.ts +8 -0
- package/dist/pi/packages/ta-glance/lib/react.js +8 -0
- package/dist/pi/packages/ta-glance/lib/style.d.ts +4 -0
- package/dist/pi/packages/ta-glance/lib/style.js +164 -0
- package/dist/pi/packages/ta-glance/package.json +53 -0
- package/dist/pi/packages/ta-glance/web/index.js +933 -0
- package/dist/pi/packages/ta-launcher/lib/actions.d.ts +4 -4
- package/dist/pi/packages/ta-launcher/lib/actions.js +7 -3
- package/dist/pi/packages/ta-launcher/lib/launcher-util.d.ts +7 -7
- package/dist/pi/packages/ta-launcher/lib/launcher-util.js +11 -8
- package/dist/pi/packages/ta-launcher/lib/launcher-view.js +13 -7
- package/dist/pi/packages/ta-launcher/lib/react.d.ts +3 -0
- package/dist/pi/packages/ta-launcher/lib/react.js +8 -0
- package/dist/pi/packages/ta-launcher/lib/style.d.ts +1 -1
- package/dist/pi/packages/ta-launcher/lib/style.js +6 -4
- package/dist/pi/packages/ta-launcher/package.json +1 -1
- package/dist/pi/packages/ta-launcher/web/index.js +34 -17
- package/dist/pi/packages/ta-manual/README.en.md +10 -0
- package/dist/pi/packages/ta-manual/README.md +10 -0
- package/dist/pi/packages/ta-manual/lib/i18n.d.ts +15 -0
- package/dist/pi/packages/ta-manual/lib/i18n.js +31 -0
- package/dist/pi/packages/ta-manual/lib/index.d.ts +7 -0
- package/dist/pi/packages/ta-manual/lib/index.js +24 -0
- package/dist/pi/packages/ta-manual/lib/manual-util.d.ts +18 -0
- package/dist/pi/packages/ta-manual/lib/manual-util.js +40 -0
- package/dist/pi/packages/ta-manual/lib/manual-view.d.ts +9 -0
- package/dist/pi/packages/ta-manual/lib/manual-view.js +81 -0
- package/dist/pi/packages/ta-manual/lib/pictures-a.d.ts +2 -0
- package/dist/pi/packages/ta-manual/lib/pictures-a.js +263 -0
- package/dist/pi/packages/ta-manual/lib/pictures-b.d.ts +2 -0
- package/dist/pi/packages/ta-manual/lib/pictures-b.js +216 -0
- package/dist/pi/packages/ta-manual/lib/pictures.d.ts +9 -0
- package/dist/pi/packages/ta-manual/lib/pictures.js +16 -0
- package/dist/pi/packages/ta-manual/lib/react.d.ts +8 -0
- package/dist/pi/packages/ta-manual/lib/react.js +8 -0
- package/dist/pi/packages/ta-manual/lib/scene.d.ts +68 -0
- package/dist/pi/packages/ta-manual/lib/scene.js +115 -0
- package/dist/pi/packages/ta-manual/lib/style.d.ts +4 -0
- package/dist/pi/packages/ta-manual/lib/style.js +47 -0
- package/dist/pi/packages/ta-manual/lib/topics.d.ts +42 -0
- package/dist/pi/packages/ta-manual/lib/topics.js +354 -0
- package/dist/pi/packages/ta-manual/package.json +54 -0
- package/dist/pi/packages/ta-manual/skills/ta-manual/SKILL.md +119 -0
- package/dist/pi/packages/ta-manual/web/index.js +2223 -0
- package/dist/pi/packages/ta-notify/README.en.md +29 -0
- package/dist/pi/packages/ta-notify/README.md +29 -0
- package/dist/pi/packages/ta-notify/extension/index.mjs +259 -0
- package/dist/pi/packages/ta-notify/host/index.mjs +163 -0
- package/dist/pi/packages/ta-notify/lib/ask-card.d.ts +9 -0
- package/dist/pi/packages/ta-notify/lib/ask-card.js +40 -0
- package/dist/pi/packages/ta-notify/lib/extension.d.ts +24 -0
- package/dist/pi/packages/ta-notify/lib/extension.js +102 -0
- package/dist/pi/packages/ta-notify/lib/host.d.ts +4 -0
- package/dist/pi/packages/ta-notify/lib/host.js +9 -0
- package/dist/pi/packages/ta-notify/lib/i18n.d.ts +31 -0
- package/dist/pi/packages/ta-notify/lib/i18n.js +63 -0
- package/dist/pi/packages/ta-notify/lib/index.d.ts +8 -0
- package/dist/pi/packages/ta-notify/lib/index.js +29 -0
- package/dist/pi/packages/ta-notify/lib/notify-protocol.d.ts +74 -0
- package/dist/pi/packages/ta-notify/lib/notify-protocol.js +23 -0
- package/dist/pi/packages/ta-notify/lib/notify-service.d.ts +21 -0
- package/dist/pi/packages/ta-notify/lib/notify-service.js +75 -0
- package/dist/pi/packages/ta-notify/lib/notify-util.d.ts +39 -0
- package/dist/pi/packages/ta-notify/lib/notify-util.js +119 -0
- package/dist/pi/packages/ta-notify/lib/react.d.ts +8 -0
- package/dist/pi/packages/ta-notify/lib/react.js +8 -0
- package/dist/pi/packages/ta-notify/lib/server-texts.d.ts +9 -0
- package/dist/pi/packages/ta-notify/lib/server-texts.js +22 -0
- package/dist/pi/packages/ta-notify/lib/settings.d.ts +8 -0
- package/dist/pi/packages/ta-notify/lib/settings.js +85 -0
- package/dist/pi/packages/ta-notify/lib/style.d.ts +4 -0
- package/dist/pi/packages/ta-notify/lib/style.js +29 -0
- package/dist/pi/packages/ta-notify/lib/tool-line.d.ts +9 -0
- package/dist/pi/packages/ta-notify/lib/tool-line.js +20 -0
- package/dist/pi/packages/ta-notify/lib/tool.d.ts +37 -0
- package/dist/pi/packages/ta-notify/lib/tool.js +46 -0
- package/dist/pi/packages/ta-notify/lib/watcher.d.ts +15 -0
- package/dist/pi/packages/ta-notify/lib/watcher.js +81 -0
- package/dist/pi/packages/ta-notify/package.json +55 -0
- package/dist/pi/packages/ta-notify/web/index.js +436 -0
- package/dist/pi/packages/ta-recall/README.en.md +19 -0
- package/dist/pi/packages/ta-recall/README.md +19 -0
- package/dist/pi/packages/ta-recall/extension/index.mjs +614 -0
- package/dist/pi/packages/ta-recall/host/index.mjs +820 -0
- package/dist/pi/packages/ta-recall/lib/brief-card.d.ts +21 -0
- package/dist/pi/packages/ta-recall/lib/brief-card.js +67 -0
- package/dist/pi/packages/ta-recall/lib/brief-home.d.ts +49 -0
- package/dist/pi/packages/ta-recall/lib/brief-home.js +143 -0
- package/dist/pi/packages/ta-recall/lib/brief-seen.d.ts +9 -0
- package/dist/pi/packages/ta-recall/lib/brief-seen.js +26 -0
- package/dist/pi/packages/ta-recall/lib/brief-util.d.ts +64 -0
- package/dist/pi/packages/ta-recall/lib/brief-util.js +179 -0
- package/dist/pi/packages/ta-recall/lib/chat-icons.d.ts +8 -0
- package/dist/pi/packages/ta-recall/lib/chat-icons.js +56 -0
- package/dist/pi/packages/ta-recall/lib/composer.d.ts +7 -0
- package/dist/pi/packages/ta-recall/lib/composer.js +38 -0
- package/dist/pi/packages/ta-recall/lib/conversation-index.d.ts +25 -0
- package/dist/pi/packages/ta-recall/lib/conversation-index.js +72 -0
- package/dist/pi/packages/ta-recall/lib/conversation-util.d.ts +16 -0
- package/dist/pi/packages/ta-recall/lib/conversation-util.js +109 -0
- package/dist/pi/packages/ta-recall/lib/conversations.d.ts +11 -0
- package/dist/pi/packages/ta-recall/lib/conversations.js +46 -0
- package/dist/pi/packages/ta-recall/lib/extension.d.ts +24 -0
- package/dist/pi/packages/ta-recall/lib/extension.js +131 -0
- package/dist/pi/packages/ta-recall/lib/host.d.ts +4 -0
- package/dist/pi/packages/ta-recall/lib/host.js +11 -0
- package/dist/pi/packages/ta-recall/lib/i18n.d.ts +41 -0
- package/dist/pi/packages/ta-recall/lib/i18n.js +83 -0
- package/dist/pi/packages/ta-recall/lib/index.d.ts +9 -0
- package/dist/pi/packages/ta-recall/lib/index.js +45 -0
- package/dist/pi/packages/ta-recall/lib/react.d.ts +11 -0
- package/dist/pi/packages/ta-recall/lib/react.js +16 -0
- package/dist/pi/packages/ta-recall/lib/recall-protocol.d.ts +186 -0
- package/dist/pi/packages/ta-recall/lib/recall-protocol.js +60 -0
- package/dist/pi/packages/ta-recall/lib/recall-service.d.ts +42 -0
- package/dist/pi/packages/ta-recall/lib/recall-service.js +241 -0
- package/dist/pi/packages/ta-recall/lib/search-source.d.ts +7 -0
- package/dist/pi/packages/ta-recall/lib/search-source.js +49 -0
- package/dist/pi/packages/ta-recall/lib/search-util.d.ts +30 -0
- package/dist/pi/packages/ta-recall/lib/search-util.js +167 -0
- package/dist/pi/packages/ta-recall/lib/server-texts.d.ts +7 -0
- package/dist/pi/packages/ta-recall/lib/server-texts.js +17 -0
- package/dist/pi/packages/ta-recall/lib/settings.d.ts +4 -0
- package/dist/pi/packages/ta-recall/lib/settings.js +77 -0
- package/dist/pi/packages/ta-recall/lib/skill-card.d.ts +9 -0
- package/dist/pi/packages/ta-recall/lib/skill-card.js +51 -0
- package/dist/pi/packages/ta-recall/lib/skill-util.d.ts +19 -0
- package/dist/pi/packages/ta-recall/lib/skill-util.js +110 -0
- package/dist/pi/packages/ta-recall/lib/stored.d.ts +5 -0
- package/dist/pi/packages/ta-recall/lib/stored.js +28 -0
- package/dist/pi/packages/ta-recall/lib/style.d.ts +4 -0
- package/dist/pi/packages/ta-recall/lib/style.js +48 -0
- package/dist/pi/packages/ta-recall/lib/tool-line.d.ts +10 -0
- package/dist/pi/packages/ta-recall/lib/tool-line.js +23 -0
- package/dist/pi/packages/ta-recall/lib/tool.d.ts +63 -0
- package/dist/pi/packages/ta-recall/lib/tool.js +71 -0
- package/dist/pi/packages/ta-recall/package.json +55 -0
- package/dist/pi/packages/ta-recall/web/index.js +1038 -0
- package/dist/pi/packages/ta-rooms/README.en.md +23 -0
- package/dist/pi/packages/ta-rooms/README.md +23 -0
- package/dist/pi/packages/ta-rooms/lib/dialogs.d.ts +39 -0
- package/dist/pi/packages/ta-rooms/lib/dialogs.js +235 -0
- package/dist/pi/packages/ta-rooms/lib/i18n.d.ts +101 -0
- package/dist/pi/packages/ta-rooms/lib/i18n.js +203 -0
- package/dist/pi/packages/ta-rooms/lib/index.d.ts +9 -0
- package/dist/pi/packages/ta-rooms/lib/index.js +85 -0
- package/dist/pi/packages/ta-rooms/lib/members-view.d.ts +3 -0
- package/dist/pi/packages/ta-rooms/lib/members-view.js +64 -0
- package/dist/pi/packages/ta-rooms/lib/page.d.ts +105 -0
- package/dist/pi/packages/ta-rooms/lib/page.js +306 -0
- package/dist/pi/packages/ta-rooms/lib/react.d.ts +8 -0
- package/dist/pi/packages/ta-rooms/lib/react.js +8 -0
- package/dist/pi/packages/ta-rooms/lib/room-view.d.ts +17 -0
- package/dist/pi/packages/ta-rooms/lib/room-view.js +150 -0
- package/dist/pi/packages/ta-rooms/lib/rooms-page.d.ts +8 -0
- package/dist/pi/packages/ta-rooms/lib/rooms-page.js +174 -0
- package/dist/pi/packages/ta-rooms/lib/style.d.ts +4 -0
- package/dist/pi/packages/ta-rooms/lib/style.js +154 -0
- package/dist/pi/packages/ta-rooms/package.json +50 -0
- package/dist/pi/packages/ta-rooms/web/index.js +1932 -0
- package/dist/pi/packages/ta-share/README.en.md +27 -0
- package/dist/pi/packages/ta-share/README.md +27 -0
- package/dist/pi/packages/ta-share/extension/index.mjs +184 -0
- package/dist/pi/packages/ta-share/host/index.mjs +364 -0
- package/dist/pi/packages/ta-share/lib/extension.d.ts +15 -0
- package/dist/pi/packages/ta-share/lib/extension.js +115 -0
- package/dist/pi/packages/ta-share/lib/host.d.ts +4 -0
- package/dist/pi/packages/ta-share/lib/host.js +9 -0
- package/dist/pi/packages/ta-share/lib/i18n.d.ts +106 -0
- package/dist/pi/packages/ta-share/lib/i18n.js +213 -0
- package/dist/pi/packages/ta-share/lib/index.d.ts +9 -0
- package/dist/pi/packages/ta-share/lib/index.js +77 -0
- package/dist/pi/packages/ta-share/lib/page.d.ts +48 -0
- package/dist/pi/packages/ta-share/lib/page.js +105 -0
- package/dist/pi/packages/ta-share/lib/react.d.ts +8 -0
- package/dist/pi/packages/ta-share/lib/react.js +8 -0
- package/dist/pi/packages/ta-share/lib/server-texts.d.ts +14 -0
- package/dist/pi/packages/ta-share/lib/server-texts.js +52 -0
- package/dist/pi/packages/ta-share/lib/share-dialog.d.ts +18 -0
- package/dist/pi/packages/ta-share/lib/share-dialog.js +233 -0
- package/dist/pi/packages/ta-share/lib/share-protocol.d.ts +86 -0
- package/dist/pi/packages/ta-share/lib/share-protocol.js +30 -0
- package/dist/pi/packages/ta-share/lib/share-service.d.ts +50 -0
- package/dist/pi/packages/ta-share/lib/share-service.js +130 -0
- package/dist/pi/packages/ta-share/lib/shared-view.d.ts +18 -0
- package/dist/pi/packages/ta-share/lib/shared-view.js +225 -0
- package/dist/pi/packages/ta-share/lib/shares-page.d.ts +3 -0
- package/dist/pi/packages/ta-share/lib/shares-page.js +54 -0
- package/dist/pi/packages/ta-share/lib/snapshot.d.ts +30 -0
- package/dist/pi/packages/ta-share/lib/snapshot.js +195 -0
- package/dist/pi/packages/ta-share/lib/style.d.ts +4 -0
- package/dist/pi/packages/ta-share/lib/style.js +111 -0
- package/dist/pi/packages/ta-share/package.json +56 -0
- package/dist/pi/packages/ta-share/web/index.js +1197 -0
- package/dist/pi/packages/ta-workspace/README.md +1 -1
- package/dist/pi/packages/ta-workspace/README.zh-cn.md +1 -1
- package/dist/pi/packages/ta-workspace/lib/browser-common.d.ts +1 -1
- package/dist/pi/packages/ta-workspace/lib/browser-common.js +29 -30
- package/dist/pi/packages/ta-workspace/lib/browser-tool-line.d.ts +15 -0
- package/dist/pi/packages/ta-workspace/lib/browser-tool-line.js +70 -0
- package/dist/pi/packages/ta-workspace/lib/editors.js +29 -2
- package/dist/pi/packages/ta-workspace/lib/i18n.d.ts +13 -2
- package/dist/pi/packages/ta-workspace/lib/i18n.js +29 -7
- package/dist/pi/packages/ta-workspace/lib/index.js +2 -0
- package/dist/pi/packages/ta-workspace/lib/preview.d.ts +10 -1
- package/dist/pi/packages/ta-workspace/lib/preview.js +136 -11
- package/dist/pi/packages/ta-workspace/lib/style.d.ts +1 -1
- package/dist/pi/packages/ta-workspace/lib/style.js +56 -40
- package/dist/pi/packages/ta-workspace/lib/terminal-sessions.d.ts +15 -4
- package/dist/pi/packages/ta-workspace/lib/terminal-sessions.js +31 -9
- package/dist/pi/packages/ta-workspace/lib/terminal.d.ts +3 -2
- package/dist/pi/packages/ta-workspace/lib/terminal.js +51 -21
- package/dist/pi/packages/ta-workspace/lib/util/preview.d.ts +27 -0
- package/dist/pi/packages/ta-workspace/lib/util/preview.js +74 -0
- package/dist/pi/packages/ta-workspace/lib/util/terminal.d.ts +5 -0
- package/dist/pi/packages/ta-workspace/lib/util/terminal.js +14 -0
- package/dist/pi/packages/ta-workspace/package.json +1 -1
- package/dist/pi/packages/ta-workspace/web/index.js +823 -341
- package/dist/public/assets/OrbitControls-DVf70a7w.js +1 -0
- package/dist/public/assets/{abnfDiagram-S7VZAUFO-BmIko5tV.js → abnfDiagram-S7VZAUFO-D9uU0Tx2.js} +1 -1
- package/dist/public/assets/{architecture-WOLXFQ4H-XgsdQ7ul.js → architecture-WOLXFQ4H-f7Nm7EIo.js} +1 -1
- package/dist/public/assets/{architectureDiagram-YGSQEFNW--sVhMS03.js → architectureDiagram-YGSQEFNW-DSAqlcms.js} +1 -1
- package/dist/public/assets/{blockDiagram-APKKGZFW-8f9b-9k2.js → blockDiagram-APKKGZFW-C0lPIW9g.js} +1 -1
- package/dist/public/assets/{browser-DOHZ0JCf.js → browser-WLpgVYno.js} +1 -1
- package/dist/public/assets/{c4Diagram-KJ2TOQU5-CwYQ0Jfy.js → c4Diagram-KJ2TOQU5-CDcZ7mJq.js} +1 -1
- package/dist/public/assets/{chunk-6MUBBAK2-7Y9ezehi.js → chunk-6MUBBAK2-CXPuyqPL.js} +1 -1
- package/dist/public/assets/{chunk-AXFCVDMN-CZIH4pWz.js → chunk-AXFCVDMN-Du6JRX1x.js} +1 -1
- package/dist/public/assets/{chunk-BG4553SI-DsNATY2m.js → chunk-BG4553SI-D592E55X.js} +1 -1
- package/dist/public/assets/{chunk-DQASFODM-CoXkfYE-.js → chunk-DQASFODM-BW2r2SL4.js} +1 -1
- package/dist/public/assets/{chunk-HFQBQIA3-C5OLqki8.js → chunk-HFQBQIA3-C3yoe54R.js} +1 -1
- package/dist/public/assets/{chunk-KQLB2F66-DMHuYGEF.js → chunk-KQLB2F66-DF8gfYCy.js} +1 -1
- package/dist/public/assets/{chunk-KS47KZWR-BKeOttO1.js → chunk-KS47KZWR-C8CRMTv1.js} +1 -1
- package/dist/public/assets/{chunk-LEVMRMFU-D6zCwkk7.js → chunk-LEVMRMFU-BDcMKiwj.js} +1 -1
- package/dist/public/assets/{chunk-M57EVK23-B5-QqcZg.js → chunk-M57EVK23-CKJPBygc.js} +1 -1
- package/dist/public/assets/{chunk-OY52VR5R-DQrq3n0T.js → chunk-OY52VR5R-B3ZWH07L.js} +1 -1
- package/dist/public/assets/{chunk-QB3YPZ4I-j6ZT7EDR.js → chunk-QB3YPZ4I-DI-z4UPL.js} +1 -1
- package/dist/public/assets/{chunk-R3KSYZAL-D5MXUO36.js → chunk-R3KSYZAL-Bg4-haAc.js} +1 -1
- package/dist/public/assets/{chunk-STOXU5M4-DaBkw4dD.js → chunk-STOXU5M4-l_SHib3p.js} +1 -1
- package/dist/public/assets/{chunk-TU62E6Q5-vXcRfGci.js → chunk-TU62E6Q5-BINu9tIm.js} +1 -1
- package/dist/public/assets/{chunk-X4PVCEUW-CIh6H4Y2.js → chunk-X4PVCEUW-BQn-mvV5.js} +1 -1
- package/dist/public/assets/{chunk-XXDRQBXY-C_Vwv1FM.js → chunk-XXDRQBXY-uvpAu0Ys.js} +1 -1
- package/dist/public/assets/{classDiagram-v2-L25IHNXF-DccDWEJn.js → classDiagram-v2-L25IHNXF-BIowooW1.js} +1 -1
- package/dist/public/assets/{cose-bilkent-JH36ORCC-BX47lumZ.js → cose-bilkent-JH36ORCC-BTyx1Mh2.js} +1 -1
- package/dist/public/assets/cynefin-EF2NZ3EQ-Dg54eFzZ.js +1 -0
- package/dist/public/assets/{cynefinDiagram-L36ESFBY-BE6WOGxW.js → cynefinDiagram-L36ESFBY-D64EU9I0.js} +1 -1
- package/dist/public/assets/{d3-selection-ZcE6yRN5.js → d3-selection-CN9k6_B9.js} +1 -1
- package/dist/public/assets/{dagre-SPEB5RXH-CE6SOOcN.js → dagre-SPEB5RXH-FCbz2-Kk.js} +1 -1
- package/dist/public/assets/{diagram-3B7GL73J-xC8VtiYL.js → diagram-3B7GL73J-OhHUSI7j.js} +1 -1
- package/dist/public/assets/{diagram-DNEMPZML-4dmcBbjL.js → diagram-DNEMPZML-Be4xMtp6.js} +1 -1
- package/dist/public/assets/{diagram-L3MUGCDN-D14Yn3sQ.js → diagram-L3MUGCDN-CmKSs3aG.js} +1 -1
- package/dist/public/assets/{diagram-LA4NIPWU-GxSXIhsK.js → diagram-LA4NIPWU-D1C32rMN.js} +1 -1
- package/dist/public/assets/{diagram-MHCOC4E2-Cm7Prlpc.js → diagram-MHCOC4E2-BjoE6JXs.js} +1 -1
- package/dist/public/assets/{diagram-XPFHEONP-mkUnnKFu.js → diagram-XPFHEONP-B22k4v8R.js} +1 -1
- package/dist/public/assets/{dist-acJS-BlA.js → dist-DcBP8Cf6.js} +1 -1
- package/dist/public/assets/{ebnfDiagram-UZSYDL2S-m77ua3UQ.js → ebnfDiagram-UZSYDL2S-Tn-K8-X7.js} +1 -1
- package/dist/public/assets/{editor.api-CljTm-EQ.js → editor.api-Bz4sjRz_.js} +1 -1
- package/dist/public/assets/{elk-XV6XMXQE-DsQY1hw9.js → elk-XV6XMXQE-COnQsWlN.js} +1 -1
- package/dist/public/assets/{erDiagram-EYBAPDEH-CV8gJM0P.js → erDiagram-EYBAPDEH-c53dJilq.js} +1 -1
- package/dist/public/assets/{eventmodeling-K75KTNOO-C1pymbUr.js → eventmodeling-K75KTNOO-DaFpPPks.js} +1 -1
- package/dist/public/assets/flowDiagram-MALGAFMO-V5qkYWIO.js +1 -0
- package/dist/public/assets/{freemarker2-DYJXaMHN.js → freemarker2-BLxfRHsw.js} +1 -1
- package/dist/public/assets/{ganttDiagram-23REXITY-CppxOWRh.js → ganttDiagram-23REXITY-Md-SavIS.js} +1 -1
- package/dist/public/assets/gitGraph-VSP46ZUC-1q8ldRXU.js +1 -0
- package/dist/public/assets/{gitGraphDiagram-STJD7YCW-CrQrZhcP.js → gitGraphDiagram-STJD7YCW-CMSwTghO.js} +1 -1
- package/dist/public/assets/{handlebars-DZCnH9e2.js → handlebars-sNpu01kP.js} +1 -1
- package/dist/public/assets/{html-DuzouNES.js → html-C_tKd-uP.js} +1 -1
- package/dist/public/assets/{index-B7OYKvCE.js → index-Bn86rI4n.js} +2 -2
- package/dist/public/assets/info-OHQRW6UA-Crere6sx.js +1 -0
- package/dist/public/assets/{infoDiagram-KBXO4MBG-6pby19tQ.js → infoDiagram-KBXO4MBG-CwgNj-7i.js} +1 -1
- package/dist/public/assets/{ishikawaDiagram-M35NCXHK-Duf8c8rQ.js → ishikawaDiagram-M35NCXHK-BSlzQNMN.js} +1 -1
- package/dist/public/assets/{javascript-2d_L6cVd.js → javascript-l3qKw0L-.js} +1 -1
- package/dist/public/assets/{journeyDiagram-OPLOXDXO-Dvv-xzNo.js → journeyDiagram-OPLOXDXO-B09LPEnF.js} +1 -1
- package/dist/public/assets/{jsonMode-CFadYXyI.js → jsonMode-5SQQn1EX.js} +1 -1
- package/dist/public/assets/{kanban-definition-BZKZHSQY-Dsk6F-TT.js → kanban-definition-BZKZHSQY-BiW4aJ29.js} +1 -1
- package/dist/public/assets/{liquid-Din4CF34.js → liquid-BGyTIIUt.js} +1 -1
- package/dist/public/assets/{mdx-DivDuCWI.js → mdx-8tGjz4em.js} +1 -1
- package/dist/public/assets/{mermaid-parser.core-BfCv4CYZ.js → mermaid-parser.core-CctN5b0z.js} +3 -3
- package/dist/public/assets/{mermaid.core-DC20ZwJj.js → mermaid.core-7ERSdZ4-.js} +4 -4
- package/dist/public/assets/{mindmap-definition-I2QAS2VK-DRZRrJU_.js → mindmap-definition-I2QAS2VK-D-GOUwW1.js} +1 -1
- package/dist/public/assets/module-DEqsdd00.js +1 -0
- package/dist/public/assets/module-TWc52XwT.js +2244 -0
- package/dist/public/assets/{monaco-D1d6MOPe.js → monaco-B_9hlk78.js} +3 -3
- package/dist/public/assets/packet-JDAUHWVQ-qMf5LkHT.js +1 -0
- package/dist/public/assets/{pegDiagram-FD4XPPHP-DcGr3Tbk.js → pegDiagram-FD4XPPHP-Dmy1fWB3.js} +1 -1
- package/dist/public/assets/phaser.esm-BxCDEWDb.js +3202 -0
- package/dist/public/assets/pie-XZMESJXO-BjqLn4qm.js +1 -0
- package/dist/public/assets/{pieDiagram-J4AKIIQI-GF7pu6ch.js → pieDiagram-J4AKIIQI-CXFHLYTg.js} +1 -1
- package/dist/public/assets/{python-BQbTTTT5.js → python-e-JK0s5M.js} +1 -1
- package/dist/public/assets/{quadrantDiagram-XTYBLID2-D-bcu7Ey.js → quadrantDiagram-XTYBLID2-RQvEpGWO.js} +1 -1
- package/dist/public/assets/radar-ABXABTNO-DWO6t_4C.js +1 -0
- package/dist/public/assets/railroad-I3PHUGI6-D1XOJPWy.js +1 -0
- package/dist/public/assets/{railroad-abnf-LNEFI6M7-BiBHsI-K.js → railroad-abnf-LNEFI6M7-CDOSPZwX.js} +1 -1
- package/dist/public/assets/{railroad-ebnf-DWYD2UWJ-zKjrfkHs.js → railroad-ebnf-DWYD2UWJ-BTrNQ0DX.js} +1 -1
- package/dist/public/assets/{railroad-peg-JR7BVNR7-DKuVn0GT.js → railroad-peg-JR7BVNR7-B7NtVofS.js} +1 -1
- package/dist/public/assets/{railroadDiagram-MRQ6NCDL-Cyn-16mJ.js → railroadDiagram-MRQ6NCDL-DsDrT0Jf.js} +1 -1
- package/dist/public/assets/{razor-DiLk54O0.js → razor-DtSPwumi.js} +1 -1
- package/dist/public/assets/{requirementDiagram-Y7LWUY3S-CwU2EBkW.js → requirementDiagram-Y7LWUY3S-BQh0hFuA.js} +1 -1
- package/dist/public/assets/{sankeyDiagram-WGJFYUXA-ajf00HyW.js → sankeyDiagram-WGJFYUXA-BUXNAQEF.js} +1 -1
- package/dist/public/assets/{sequenceDiagram-5NDRBG5M-DiX_OIAw.js → sequenceDiagram-5NDRBG5M-05f-N5V_.js} +1 -1
- package/dist/public/assets/{stateDiagram-v2-FJ4FJNEA-CV5bRqB7.js → stateDiagram-v2-FJ4FJNEA-D6V1fGWV.js} +1 -1
- package/dist/public/assets/{swimlanes-UMQ2AFYF-BGQKSlj7.js → swimlanes-UMQ2AFYF-DWhlPvKs.js} +1 -1
- package/dist/public/assets/swimlanesDiagram-OMPLPG4O-CRn5uHsY.js +8 -0
- package/dist/public/assets/three.module-CeVBJVoU.js +4225 -0
- package/dist/public/assets/{timeline-definition-SEUHKTQE-DhQoApff.js → timeline-definition-SEUHKTQE-CMdocOui.js} +1 -1
- package/dist/public/assets/treeView-D4JQ5SDB-D09wHNzT.js +1 -0
- package/dist/public/assets/treemap-SAJKECNS-ChxAT7Fq.js +1 -0
- package/dist/public/assets/{typescript-COQ1g-up.js → typescript-65jNyipU.js} +1 -1
- package/dist/public/assets/{usecaseDiagram-AFA6YXN4-CmLFzjie.js → usecaseDiagram-AFA6YXN4-BQTHUX1f.js} +1 -1
- package/dist/public/assets/{vennDiagram-NNMJR3RB-DOa6JR5K.js → vennDiagram-NNMJR3RB-BULkVTfA.js} +1 -1
- package/dist/public/assets/wardley-7MLQ67FV-DfSjKzbJ.js +1 -0
- package/dist/public/assets/{wardleyDiagram-S7YFUSEH-BV7EEShp.js → wardleyDiagram-S7YFUSEH-Cek6l8lz.js} +1 -1
- package/dist/public/assets/{xml-BbvtjuaG.js → xml-DWBejfu-.js} +1 -1
- package/dist/public/assets/{xychartDiagram-GGNKY7IX-DtMpPbsq.js → xychartDiagram-GGNKY7IX-ujnZQTWA.js} +1 -1
- package/dist/public/assets/{yaml-Bw8NFga9.js → yaml-CwRCT7q1.js} +1 -1
- package/dist/public/index.html +1 -1
- package/dist/serve/index.mjs +5853 -2164
- package/package.json +32 -25
- package/dist/public/assets/cynefin-EF2NZ3EQ-MaI-3dMQ.js +0 -1
- package/dist/public/assets/flowDiagram-MALGAFMO-shBnAQFk.js +0 -1
- package/dist/public/assets/gitGraph-VSP46ZUC-BtQWboBz.js +0 -1
- package/dist/public/assets/info-OHQRW6UA-CDSLjba_.js +0 -1
- package/dist/public/assets/module-BAQaY56j.js +0 -1
- package/dist/public/assets/module-DxRGg3ED.js +0 -1947
- package/dist/public/assets/packet-JDAUHWVQ-dYb4P9eU.js +0 -1
- package/dist/public/assets/pie-XZMESJXO-CIompBnc.js +0 -1
- package/dist/public/assets/radar-ABXABTNO-DiJl7BtK.js +0 -1
- package/dist/public/assets/railroad-I3PHUGI6-B5cRBukM.js +0 -1
- package/dist/public/assets/swimlanesDiagram-OMPLPG4O-DxXlavVT.js +0 -8
- package/dist/public/assets/treeView-D4JQ5SDB-BOP6mkZC.js +0 -1
- package/dist/public/assets/treemap-SAJKECNS-BJxuPMz3.js +0 -1
- package/dist/public/assets/wardley-7MLQ67FV-jqlowjVL.js +0 -1
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
// web-src/cron-protocol.ts
|
|
2
2
|
var NAME = "@celljs/ta-cron";
|
|
3
3
|
var REPLY_TYPE = "ta-cron";
|
|
4
|
+
var TOOL_NAME = "schedule_task";
|
|
4
5
|
var RUN_MARK = "<ta-cron-run>";
|
|
5
6
|
var Keys;
|
|
6
7
|
((Keys) => {
|
|
@@ -17,6 +18,8 @@ var Limits;
|
|
|
17
18
|
Limits.SUMMARY_MAX = 4000;
|
|
18
19
|
Limits.MIN_INTERVAL_MS = 60000;
|
|
19
20
|
Limits.RUN_TIMEOUT_MS = 30 * 60000;
|
|
21
|
+
Limits.RUN_TIMEOUT_MIN_MS = 5 * 60000;
|
|
22
|
+
Limits.RUN_TIMEOUT_MAX_MS = 4 * 60 * 60000;
|
|
20
23
|
Limits.GRACE_MS = 5 * 60000;
|
|
21
24
|
Limits.PARALLEL_RUNS = 3;
|
|
22
25
|
})(Limits ||= {});
|
|
@@ -110,7 +113,25 @@ var EN = {
|
|
|
110
113
|
lastRun: "Last {time}",
|
|
111
114
|
moreOptions: "More options",
|
|
112
115
|
shortcut: "{key} + Enter to {action}",
|
|
113
|
-
modelFailed: "The model for making extensions ({model}) cannot be used, so the default one is: {message}"
|
|
116
|
+
modelFailed: "The model for making extensions ({model}) cannot be used, so the default one is: {message}",
|
|
117
|
+
fromChat: "Make a scheduled task",
|
|
118
|
+
fromChatDetail: "Do this again on a schedule",
|
|
119
|
+
fromChatWhen: "How often",
|
|
120
|
+
fromChatOther: "Another time",
|
|
121
|
+
fromChatOtherDetail: "Ta asks you",
|
|
122
|
+
fromChatAsk: "Make what this conversation did a scheduled task: {when}",
|
|
123
|
+
fromChatAskWhen: "Make what this conversation did a scheduled task; ask me how often first",
|
|
124
|
+
toolAdd: "Schedule",
|
|
125
|
+
toolUpdate: "Change scheduled task",
|
|
126
|
+
toolList: "List scheduled tasks",
|
|
127
|
+
toolShow: "Look at scheduled task",
|
|
128
|
+
toolEnable: "Turn on scheduled task",
|
|
129
|
+
toolDisable: "Pause scheduled task",
|
|
130
|
+
toolDelete: "Delete scheduled task",
|
|
131
|
+
toolRun: "Run scheduled task",
|
|
132
|
+
toolRuns: "Look at the runs of",
|
|
133
|
+
toolClear: "Clear scheduled tasks",
|
|
134
|
+
toolOther: "Scheduled tasks"
|
|
114
135
|
};
|
|
115
136
|
var ZH = {
|
|
116
137
|
title: "定时任务",
|
|
@@ -200,7 +221,25 @@ var ZH = {
|
|
|
200
221
|
lastRun: "上次 {time}",
|
|
201
222
|
moreOptions: "更多选项",
|
|
202
223
|
shortcut: "{key} + 回车{action}",
|
|
203
|
-
modelFailed: "做扩展的模型({model})现在用不了,已改用默认模型:{message}"
|
|
224
|
+
modelFailed: "做扩展的模型({model})现在用不了,已改用默认模型:{message}",
|
|
225
|
+
fromChat: "做成定时任务",
|
|
226
|
+
fromChatDetail: "定期再做一遍这次的事",
|
|
227
|
+
fromChatWhen: "多久运行一次",
|
|
228
|
+
fromChatOther: "其他时间",
|
|
229
|
+
fromChatOtherDetail: "让 Ta 问我",
|
|
230
|
+
fromChatAsk: "把这次对话做的事做成定时任务,{when} 运行",
|
|
231
|
+
fromChatAskWhen: "把这次对话做的事做成定时任务,先问我多久运行一次",
|
|
232
|
+
toolAdd: "新建定时任务",
|
|
233
|
+
toolUpdate: "修改定时任务",
|
|
234
|
+
toolList: "查看定时任务",
|
|
235
|
+
toolShow: "查看定时任务",
|
|
236
|
+
toolEnable: "开启定时任务",
|
|
237
|
+
toolDisable: "暂停定时任务",
|
|
238
|
+
toolDelete: "删除定时任务",
|
|
239
|
+
toolRun: "立即运行定时任务",
|
|
240
|
+
toolRuns: "查看运行记录",
|
|
241
|
+
toolClear: "清空定时任务",
|
|
242
|
+
toolOther: "定时任务"
|
|
204
243
|
};
|
|
205
244
|
var CronWords;
|
|
206
245
|
((CronWords) => {
|
|
@@ -548,6 +587,486 @@ var ScheduleUtil;
|
|
|
548
587
|
}
|
|
549
588
|
})(ScheduleUtil ||= {});
|
|
550
589
|
|
|
590
|
+
// web-src/commands.ts
|
|
591
|
+
var FLAG_NAMES = ["name", "notify", "model", "thinking", "cwd", "timeout"];
|
|
592
|
+
var TRAILING_FLAG = new RegExp(`(?:^|\\s)--(${FLAG_NAMES.join("|")})(?:=|\\s+)("[^"]*"|'[^']*'|\\S*)\\s*$`);
|
|
593
|
+
var ACTIONS = ["add", "list", "show", "runs", "run", "enable", "disable", "set", "remove", "clear", "help"];
|
|
594
|
+
var HELP = `Scheduled tasks: each run is a conversation of its own in the Ta service, which runs them while it runs.
|
|
595
|
+
|
|
596
|
+
/loop <when> <prompt> repeat: 30m, 2h, @daily, @hourly, or a cron expression in quotes ("0 9 * * 1-5")
|
|
597
|
+
/remind in <duration> <prompt> once, after a while: in 45m
|
|
598
|
+
/remind at <time> <prompt> once, at a time: at 15:30, at 2026-11-12 09:00
|
|
599
|
+
/schedule add <when> <prompt> as /loop
|
|
600
|
+
/schedule list the tasks
|
|
601
|
+
/schedule show <task> a task and its last runs
|
|
602
|
+
/schedule run <task> run it now; its schedule stays
|
|
603
|
+
/schedule enable|disable <task>
|
|
604
|
+
/schedule set <task> [flags] change it; a value of - clears the flag
|
|
605
|
+
/schedule remove <task>
|
|
606
|
+
/schedule clear remove the tasks of this directory
|
|
607
|
+
|
|
608
|
+
A task is its id, the start of it, or its name. Flags at the end of a prompt:
|
|
609
|
+
--name <name> --notify always|error|never --model <provider/model> --thinking <level> --cwd <directory>
|
|
610
|
+
--timeout <duration> how long a run may take before it is stopped, 5m to 4h; default 30m`;
|
|
611
|
+
var CommandParser;
|
|
612
|
+
((CommandParser) => {
|
|
613
|
+
function splitFlags(text) {
|
|
614
|
+
const flags = {};
|
|
615
|
+
let rest = text.trim();
|
|
616
|
+
for (let match = TRAILING_FLAG.exec(rest);match; match = TRAILING_FLAG.exec(rest)) {
|
|
617
|
+
const key = match[1];
|
|
618
|
+
if (flags[key] === undefined) {
|
|
619
|
+
flags[key] = unquote(match[2]);
|
|
620
|
+
}
|
|
621
|
+
rest = rest.slice(0, match.index).trimEnd();
|
|
622
|
+
}
|
|
623
|
+
return { rest, flags };
|
|
624
|
+
}
|
|
625
|
+
CommandParser.splitFlags = splitFlags;
|
|
626
|
+
function repeating(text) {
|
|
627
|
+
const { rest, flags } = splitFlags(text);
|
|
628
|
+
const { schedule, remainder } = leadingSchedule(rest);
|
|
629
|
+
return input(schedule, remainder, flags);
|
|
630
|
+
}
|
|
631
|
+
CommandParser.repeating = repeating;
|
|
632
|
+
function reminder(text, now) {
|
|
633
|
+
const { rest, flags } = splitFlags(text);
|
|
634
|
+
const words = rest.split(/\s+/);
|
|
635
|
+
let at;
|
|
636
|
+
let used = 0;
|
|
637
|
+
if (words[0] === "at") {
|
|
638
|
+
const time = clockTime(words.slice(1, 3), now);
|
|
639
|
+
at = time?.date;
|
|
640
|
+
used = 1 + (time?.words ?? 0);
|
|
641
|
+
} else {
|
|
642
|
+
const offset = words[0] === "in" ? 1 : 0;
|
|
643
|
+
const ms = Duration.parse(words[offset] ?? "");
|
|
644
|
+
at = ms === undefined ? undefined : new Date(now.getTime() + ms);
|
|
645
|
+
used = offset + 1;
|
|
646
|
+
}
|
|
647
|
+
if (!at) {
|
|
648
|
+
throw new Error("Say when: /remind in 45m <prompt>, or /remind at 15:30 <prompt>.");
|
|
649
|
+
}
|
|
650
|
+
return input({ kind: "once", at: at.toISOString() }, words.slice(used).join(" "), flags);
|
|
651
|
+
}
|
|
652
|
+
CommandParser.reminder = reminder;
|
|
653
|
+
function action(text) {
|
|
654
|
+
const trimmed = text.trim();
|
|
655
|
+
const first = trimmed.split(/\s+/, 1)[0] || "list";
|
|
656
|
+
const action2 = first === "delete" ? "remove" : first === "ls" ? "list" : first;
|
|
657
|
+
if (!ACTIONS.includes(action2)) {
|
|
658
|
+
throw new Error(`/schedule does not know ${JSON.stringify(first)}. It takes: ${ACTIONS.join(", ")}.`);
|
|
659
|
+
}
|
|
660
|
+
return { action: action2, rest: trimmed.slice(trimmed ? first.length : 0).trim() };
|
|
661
|
+
}
|
|
662
|
+
CommandParser.action = action;
|
|
663
|
+
function patch(text) {
|
|
664
|
+
const { rest, flags } = splitFlags(text);
|
|
665
|
+
if (!rest) {
|
|
666
|
+
throw new Error("Name the task: /schedule set <task> --model <provider/model>.");
|
|
667
|
+
}
|
|
668
|
+
const value = (flag) => flag === undefined ? undefined : flag === "-" ? "" : flag;
|
|
669
|
+
const patch2 = {};
|
|
670
|
+
if (flags.name !== undefined) {
|
|
671
|
+
patch2.name = value(flags.name);
|
|
672
|
+
}
|
|
673
|
+
if (flags.cwd !== undefined) {
|
|
674
|
+
patch2.cwd = value(flags.cwd);
|
|
675
|
+
}
|
|
676
|
+
if (flags.model !== undefined) {
|
|
677
|
+
patch2.model = value(flags.model);
|
|
678
|
+
}
|
|
679
|
+
if (flags.thinking !== undefined) {
|
|
680
|
+
patch2.thinking = value(flags.thinking);
|
|
681
|
+
}
|
|
682
|
+
if (flags.notify !== undefined) {
|
|
683
|
+
patch2.notify = value(flags.notify);
|
|
684
|
+
}
|
|
685
|
+
if (flags.timeout !== undefined) {
|
|
686
|
+
patch2.timeout = value(flags.timeout);
|
|
687
|
+
}
|
|
688
|
+
if (Object.keys(patch2).length === 0) {
|
|
689
|
+
throw new Error("Say what changes: --name, --notify, --model, --thinking, --cwd or --timeout.");
|
|
690
|
+
}
|
|
691
|
+
return { ref: rest, patch: patch2 };
|
|
692
|
+
}
|
|
693
|
+
CommandParser.patch = patch;
|
|
694
|
+
function leadingSchedule(text) {
|
|
695
|
+
const trimmed = text.trim();
|
|
696
|
+
const quote = trimmed[0];
|
|
697
|
+
if (quote === '"' || quote === "'") {
|
|
698
|
+
const end = trimmed.indexOf(quote, 1);
|
|
699
|
+
if (end < 0) {
|
|
700
|
+
throw new Error("The cron expression has no closing quote.");
|
|
701
|
+
}
|
|
702
|
+
return { schedule: ScheduleUtil.check({ kind: "cron", expression: trimmed.slice(1, end) }), remainder: trimmed.slice(end + 1) };
|
|
703
|
+
}
|
|
704
|
+
const [first = ""] = trimmed.split(/\s+/, 1);
|
|
705
|
+
const remainder = trimmed.slice(first.length);
|
|
706
|
+
if (first.startsWith("@")) {
|
|
707
|
+
return { schedule: ScheduleUtil.check({ kind: "cron", expression: first }), remainder };
|
|
708
|
+
}
|
|
709
|
+
if (Duration.parse(first) !== undefined) {
|
|
710
|
+
return { schedule: ScheduleUtil.check({ kind: "interval", every: first }), remainder };
|
|
711
|
+
}
|
|
712
|
+
throw new Error('Start with when: 30m, 2h, @daily, or a cron expression in quotes such as "0 9 * * 1-5".');
|
|
713
|
+
}
|
|
714
|
+
CommandParser.leadingSchedule = leadingSchedule;
|
|
715
|
+
function clockTime(words, now) {
|
|
716
|
+
const [first = "", second = ""] = words;
|
|
717
|
+
const hm = /^(\d{1,2}):(\d{2})$/;
|
|
718
|
+
const day = /^(\d{4})-(\d{1,2})-(\d{1,2})$/;
|
|
719
|
+
const time = hm.exec(first);
|
|
720
|
+
if (time) {
|
|
721
|
+
const date2 = new Date(now.getTime());
|
|
722
|
+
date2.setHours(Number(time[1]), Number(time[2]), 0, 0);
|
|
723
|
+
if (date2.getTime() <= now.getTime()) {
|
|
724
|
+
date2.setDate(date2.getDate() + 1);
|
|
725
|
+
}
|
|
726
|
+
return valid(date2, Number(time[1]) < 24 && Number(time[2]) < 60) ? { date: date2, words: 1 } : undefined;
|
|
727
|
+
}
|
|
728
|
+
const date = day.exec(first);
|
|
729
|
+
const later = hm.exec(second);
|
|
730
|
+
if (date) {
|
|
731
|
+
const at = new Date(Number(date[1]), Number(date[2]) - 1, Number(date[3]), later ? Number(later[1]) : 9, later ? Number(later[2]) : 0);
|
|
732
|
+
return valid(at, true) ? { date: at, words: later ? 2 : 1 } : undefined;
|
|
733
|
+
}
|
|
734
|
+
const iso = /^\d{4}-\d{2}-\d{2}T/.test(first) ? new Date(first) : undefined;
|
|
735
|
+
return iso && valid(iso, true) ? { date: iso, words: 1 } : undefined;
|
|
736
|
+
}
|
|
737
|
+
CommandParser.clockTime = clockTime;
|
|
738
|
+
function valid(date, ok) {
|
|
739
|
+
return ok && !Number.isNaN(date.getTime());
|
|
740
|
+
}
|
|
741
|
+
function input(schedule, prompt, flags) {
|
|
742
|
+
const text = prompt.trim();
|
|
743
|
+
if (!text) {
|
|
744
|
+
throw new Error("Then say what Ta should do: the prompt of the task.");
|
|
745
|
+
}
|
|
746
|
+
return {
|
|
747
|
+
schedule,
|
|
748
|
+
prompt: text,
|
|
749
|
+
...flags.name ? { name: flags.name } : {},
|
|
750
|
+
...flags.cwd ? { cwd: flags.cwd } : {},
|
|
751
|
+
...flags.model ? { model: flags.model } : {},
|
|
752
|
+
...flags.thinking ? { thinking: flags.thinking } : {},
|
|
753
|
+
...flags.notify ? { notify: flags.notify } : {},
|
|
754
|
+
...flags.timeout ? { timeout: flags.timeout } : {}
|
|
755
|
+
};
|
|
756
|
+
}
|
|
757
|
+
function unquote(value) {
|
|
758
|
+
return /^(["']).*\1$/.test(value) ? value.slice(1, -1) : value;
|
|
759
|
+
}
|
|
760
|
+
function completions(prefix, tasks) {
|
|
761
|
+
const parts = prefix.split(/\s+/);
|
|
762
|
+
if (parts.length <= 1) {
|
|
763
|
+
return ACTIONS.filter((action3) => action3.startsWith(parts[0] ?? "")).map((action3) => ({ value: `${action3} `, label: action3 }));
|
|
764
|
+
}
|
|
765
|
+
const [action2, ref] = parts;
|
|
766
|
+
if (!["show", "runs", "run", "enable", "disable", "set", "remove"].includes(action2) || parts.length > 2) {
|
|
767
|
+
return [];
|
|
768
|
+
}
|
|
769
|
+
return tasks.filter((task) => task.id.startsWith(ref) || task.name.startsWith(ref)).map((task) => ({ value: `${action2} ${task.id} `, label: task.id, description: task.name }));
|
|
770
|
+
}
|
|
771
|
+
CommandParser.completions = completions;
|
|
772
|
+
function loopCompletions(prefix) {
|
|
773
|
+
if (/\s/.test(prefix)) {
|
|
774
|
+
return [];
|
|
775
|
+
}
|
|
776
|
+
return [...Object.keys(NICKNAMES), "5m", "30m", "1h", "1d"].filter((item) => item.startsWith(prefix)).map((item) => ({ value: `${item} `, label: item }));
|
|
777
|
+
}
|
|
778
|
+
CommandParser.loopCompletions = loopCompletions;
|
|
779
|
+
})(CommandParser ||= {});
|
|
780
|
+
var CronText;
|
|
781
|
+
((CronText) => {
|
|
782
|
+
function task(task2, now = new Date) {
|
|
783
|
+
const state = !task2.enabled ? "off" : task2.lastStatus === "running" ? "running" : task2.nextRunAt ? `next ${ScheduleUtil.clock(new Date(task2.nextRunAt), now)}` : "done";
|
|
784
|
+
const last = task2.lastStatus && task2.lastStatus !== "running" ? `, last ${task2.lastStatus}` : "";
|
|
785
|
+
const timeout = task2.timeout ? `, stops after ${task2.timeout}` : "";
|
|
786
|
+
return `${task2.id} ${task2.name} (${ScheduleUtil.describe(task2.schedule, "en", now)}; ${state}${last}${timeout}) in ${task2.cwd}`;
|
|
787
|
+
}
|
|
788
|
+
CronText.task = task;
|
|
789
|
+
function run(run2, now = new Date) {
|
|
790
|
+
const time = ScheduleUtil.clock(new Date(run2.startedAt), now);
|
|
791
|
+
const took = run2.endedAt ? ` in ${Duration.format(new Date(run2.endedAt).getTime() - new Date(run2.startedAt).getTime())}` : "";
|
|
792
|
+
const what = run2.error ?? run2.summary ?? "";
|
|
793
|
+
const file = run2.sessionFile ? `
|
|
794
|
+
conversation: ${run2.sessionFile}` : "";
|
|
795
|
+
return `${run2.id} ${time} ${run2.status}${took}${run2.trigger === "manual" ? " (by hand)" : ""}${what ? `
|
|
796
|
+
${what.replace(/\n/g, `
|
|
797
|
+
`)}` : ""}${file}`;
|
|
798
|
+
}
|
|
799
|
+
CronText.run = run;
|
|
800
|
+
function reply(reply2) {
|
|
801
|
+
switch (reply2.kind) {
|
|
802
|
+
case "task":
|
|
803
|
+
return `${capital(reply2.event)}: ${task(reply2.task)}`;
|
|
804
|
+
case "removed":
|
|
805
|
+
return reply2.tasks.length ? `Removed ${reply2.tasks.map((item) => item.name).join(", ")}.` : "No tasks to remove.";
|
|
806
|
+
case "started":
|
|
807
|
+
return `Started ${reply2.task.name} (${reply2.run.id}); it runs in a conversation of its own.`;
|
|
808
|
+
case "list":
|
|
809
|
+
return reply2.tasks.length ? reply2.tasks.map((item) => task(item)).join(`
|
|
810
|
+
`) : "No scheduled tasks. Make one with /loop or /remind.";
|
|
811
|
+
case "show":
|
|
812
|
+
return `${task(reply2.task)}
|
|
813
|
+
prompt: ${reply2.task.prompt}
|
|
814
|
+
${reply2.runs.length ? reply2.runs.map((item) => run(item)).join(`
|
|
815
|
+
`) : "No runs yet."}`;
|
|
816
|
+
case "help":
|
|
817
|
+
return HELP;
|
|
818
|
+
case "error":
|
|
819
|
+
return reply2.message;
|
|
820
|
+
}
|
|
821
|
+
}
|
|
822
|
+
CronText.reply = reply;
|
|
823
|
+
function capital(text) {
|
|
824
|
+
return text[0].toUpperCase() + text.slice(1);
|
|
825
|
+
}
|
|
826
|
+
})(CronText ||= {});
|
|
827
|
+
|
|
828
|
+
// web-src/server-texts.ts
|
|
829
|
+
var CronServerTexts;
|
|
830
|
+
((CronServerTexts) => {
|
|
831
|
+
function zh(env = process.env) {
|
|
832
|
+
return /^zh/i.test(env.TA_LANGUAGE || env.LC_ALL || env.LC_MESSAGES || env.LANG || "");
|
|
833
|
+
}
|
|
834
|
+
CronServerTexts.zh = zh;
|
|
835
|
+
function removeTask(name) {
|
|
836
|
+
return zh() ? ["删除这个任务?", `${name} 和它的运行记录会被删除,运行产生的对话会保留。`] : ["Delete the scheduled task?", `${name} and its runs go; their conversations stay.`];
|
|
837
|
+
}
|
|
838
|
+
CronServerTexts.removeTask = removeTask;
|
|
839
|
+
function removeTasks(count) {
|
|
840
|
+
return zh() ? ["删除这个目录的所有定时任务?", `${count} 个任务和它们的运行记录会被删除。`] : ["Delete the scheduled tasks of this directory?", `${count} tasks and their runs go.`];
|
|
841
|
+
}
|
|
842
|
+
CronServerTexts.removeTasks = removeTasks;
|
|
843
|
+
})(CronServerTexts ||= {});
|
|
844
|
+
|
|
845
|
+
// web-src/tool.ts
|
|
846
|
+
var SCHEDULE = {
|
|
847
|
+
type: "object",
|
|
848
|
+
description: 'When it runs, in the local time of the Ta service: { "kind": "once", "at": "2026-11-12T09:00" }, { "kind": "interval", "every": "30m" } (at least 1m), or { "kind": "cron", "expression": "0 9 * * 1-5" } (five fields, or @daily, @hourly, @weekly, @monthly).',
|
|
849
|
+
properties: {
|
|
850
|
+
kind: { type: "string", enum: ["once", "interval", "cron"] },
|
|
851
|
+
at: { type: "string" },
|
|
852
|
+
every: { type: "string" },
|
|
853
|
+
expression: { type: "string" }
|
|
854
|
+
},
|
|
855
|
+
required: ["kind"]
|
|
856
|
+
};
|
|
857
|
+
var CronTool;
|
|
858
|
+
((CronTool) => {
|
|
859
|
+
CronTool.NAME = TOOL_NAME;
|
|
860
|
+
CronTool.DEFINITION = {
|
|
861
|
+
name: CronTool.NAME,
|
|
862
|
+
label: "Schedule task",
|
|
863
|
+
description: `Schedules a prompt for Ta to run later, once or again and again (reminders, checks, reports), and manages those tasks. Each run is a new conversation of its own in the Ta service, in the task's directory, with no user watching; its last answer is the summary the user sees. Actions: add (prompt and schedule; name, cwd, model, thinking, notify, timeout optional), update (id and the fields to change; "" clears model, thinking, notify or timeout), list, show (with its last runs), enable, disable, delete, run (now, by hand), runs, clear (the tasks of this directory). Deleting and clearing ask the user first.`,
|
|
864
|
+
parameters: {
|
|
865
|
+
type: "object",
|
|
866
|
+
properties: {
|
|
867
|
+
action: { type: "string", enum: ["add", "update", "list", "show", "enable", "disable", "delete", "run", "runs", "clear"] },
|
|
868
|
+
id: { type: "string", description: "The task: its id, the start of it, or its name." },
|
|
869
|
+
name: { type: "string", description: "Short, for the list." },
|
|
870
|
+
prompt: { type: "string", description: "What Ta does each run, complete in itself: the run does not see this conversation." },
|
|
871
|
+
schedule: SCHEDULE,
|
|
872
|
+
cwd: { type: "string", description: "The directory it runs in; default: this conversation's." },
|
|
873
|
+
model: { type: "string", description: "<provider>/<model id>; default: the settings." },
|
|
874
|
+
thinking: { type: "string", enum: [...THINKING_LEVELS, ""] },
|
|
875
|
+
notify: {
|
|
876
|
+
type: "string",
|
|
877
|
+
enum: [...NOTIFY_LEVELS, ""],
|
|
878
|
+
description: "When the pages of Ta tell the user a run ended; default always for once, error for repeating."
|
|
879
|
+
},
|
|
880
|
+
timeout: { type: "string", description: "How long a run may take before it is stopped, as 90m or 2h (5m to 4h); default 30m." },
|
|
881
|
+
enabled: { type: "boolean" },
|
|
882
|
+
limit: { type: "number", description: "How many runs to list; default 10." }
|
|
883
|
+
},
|
|
884
|
+
required: ["action"]
|
|
885
|
+
}
|
|
886
|
+
};
|
|
887
|
+
async function run(service, params, context) {
|
|
888
|
+
const id = typeof params.id === "string" ? params.id : "";
|
|
889
|
+
switch (params.action) {
|
|
890
|
+
case "add": {
|
|
891
|
+
const cwd = typeof params.cwd === "string" && params.cwd ? params.cwd : await context.cwd();
|
|
892
|
+
const task = await service.add({
|
|
893
|
+
prompt: String(params.prompt ?? ""),
|
|
894
|
+
schedule: params.schedule,
|
|
895
|
+
name: optional(params.name),
|
|
896
|
+
cwd,
|
|
897
|
+
model: optional(params.model),
|
|
898
|
+
thinking: optional(params.thinking),
|
|
899
|
+
notify: optional(params.notify),
|
|
900
|
+
timeout: optional(params.timeout),
|
|
901
|
+
enabled: params.enabled === false ? false : undefined
|
|
902
|
+
});
|
|
903
|
+
return `Scheduled: ${CronText.task(task)}`;
|
|
904
|
+
}
|
|
905
|
+
case "update": {
|
|
906
|
+
const patch = {};
|
|
907
|
+
for (const key of ["name", "prompt", "cwd", "model", "thinking", "notify", "timeout"]) {
|
|
908
|
+
if (typeof params[key] === "string") {
|
|
909
|
+
patch[key] = params[key];
|
|
910
|
+
}
|
|
911
|
+
}
|
|
912
|
+
if (params.schedule !== undefined) {
|
|
913
|
+
patch.schedule = params.schedule;
|
|
914
|
+
}
|
|
915
|
+
if (typeof params.enabled === "boolean") {
|
|
916
|
+
patch.enabled = params.enabled;
|
|
917
|
+
}
|
|
918
|
+
return `Updated: ${CronText.task(await service.update(id, patch))}`;
|
|
919
|
+
}
|
|
920
|
+
case "list": {
|
|
921
|
+
const tasks = await service.list();
|
|
922
|
+
return tasks.length ? tasks.map((task) => CronText.task(task)).join(`
|
|
923
|
+
`) : "No scheduled tasks.";
|
|
924
|
+
}
|
|
925
|
+
case "show":
|
|
926
|
+
case "runs": {
|
|
927
|
+
const task = await service.get(id);
|
|
928
|
+
const runs = await service.runs(task.id, typeof params.limit === "number" ? params.limit : 10);
|
|
929
|
+
return CronText.reply({ kind: "show", task, runs });
|
|
930
|
+
}
|
|
931
|
+
case "enable":
|
|
932
|
+
case "disable":
|
|
933
|
+
return `${params.action === "enable" ? "Enabled" : "Disabled"}: ${CronText.task(await service.setEnabled(id, params.action === "enable"))}`;
|
|
934
|
+
case "run": {
|
|
935
|
+
const task = await service.get(id);
|
|
936
|
+
const run2 = await service.run(task.id);
|
|
937
|
+
return `Started ${task.name} (${run2.id}). It runs in a conversation of its own; see its result later with action "show".`;
|
|
938
|
+
}
|
|
939
|
+
case "delete": {
|
|
940
|
+
const task = await service.get(id);
|
|
941
|
+
if (!await context.confirm(...CronServerTexts.removeTask(task.name))) {
|
|
942
|
+
return "The user kept the task.";
|
|
943
|
+
}
|
|
944
|
+
await service.remove(task.id);
|
|
945
|
+
return `Deleted ${task.name}.`;
|
|
946
|
+
}
|
|
947
|
+
case "clear": {
|
|
948
|
+
const cwd = await context.cwd();
|
|
949
|
+
const tasks = (await service.list()).filter((task) => task.cwd === cwd);
|
|
950
|
+
if (tasks.length === 0) {
|
|
951
|
+
return "This directory has no scheduled tasks.";
|
|
952
|
+
}
|
|
953
|
+
if (!await context.confirm(...CronServerTexts.removeTasks(tasks.length))) {
|
|
954
|
+
return "The user kept the tasks.";
|
|
955
|
+
}
|
|
956
|
+
return `Deleted ${(await service.clear(cwd)).length} tasks.`;
|
|
957
|
+
}
|
|
958
|
+
default:
|
|
959
|
+
throw new Error("action is one of add, update, list, show, enable, disable, delete, run, runs, clear.");
|
|
960
|
+
}
|
|
961
|
+
}
|
|
962
|
+
CronTool.run = run;
|
|
963
|
+
function optional(value) {
|
|
964
|
+
return typeof value === "string" && value ? value : undefined;
|
|
965
|
+
}
|
|
966
|
+
})(CronTool ||= {});
|
|
967
|
+
|
|
968
|
+
// web-src/chat-task.ts
|
|
969
|
+
var TASK_BLOCK = "ta-cron-task";
|
|
970
|
+
var MARK = /\[ta-cron:from-chat(?: (\{[^}]*\}))?\]/;
|
|
971
|
+
var ChatTask;
|
|
972
|
+
((ChatTask) => {
|
|
973
|
+
function message(language, schedule2) {
|
|
974
|
+
const words = CronWords.of(language);
|
|
975
|
+
const ask = schedule2 ? CronWords.format(words.fromChatAsk, { when: ScheduleUtil.describe(schedule2, language) }) : words.fromChatAskWhen;
|
|
976
|
+
return `<context>
|
|
977
|
+
${context(schedule2)}
|
|
978
|
+
</context>
|
|
979
|
+
${ask}`;
|
|
980
|
+
}
|
|
981
|
+
ChatTask.message = message;
|
|
982
|
+
function context(schedule2) {
|
|
983
|
+
const fence = "```";
|
|
984
|
+
return [
|
|
985
|
+
schedule2 ? `[ta-cron:from-chat ${JSON.stringify(schedule2)}]` : "[ta-cron:from-chat]",
|
|
986
|
+
schedule2 ? `The user wants what was done in this conversation made a scheduled task of Ta that does it again and again, ${ScheduleUtil.describe(schedule2, "en-US")}.` : "The user wants what was done in this conversation made a scheduled task of Ta that does it again and again, and has not said how often: unless the conversation says it, ask, with two or three choices that suit the work, and write the task once you know.",
|
|
987
|
+
"- Each run is a new conversation in this directory with nobody watching, and it does not see this one: write a prompt complete in itself, with the goal, the repository, branch, files, commands, links and other specifics found here, the steps that worked, and what its last answer should report (short: what it found, what changed since the run before, what needs the user).",
|
|
988
|
+
'- Leave out what was only tried and dropped, and what holds only this once: say "since the last run" or "yesterday" rather than a date.',
|
|
989
|
+
`- Say in a line or two what the task does, then end your answer with it in a fenced block of the language ${TASK_BLOCK}, which Ta reads to create the task: do not create it with ${CronTool.NAME} or a command. A longer fence when the prompt has one of its own:`,
|
|
990
|
+
`${fence}${TASK_BLOCK}`,
|
|
991
|
+
"name: <short, for the list>",
|
|
992
|
+
schedule2 ? "when: <only when the user asked for another time since: 30m, 2h, @daily, or five fields of cron>" : "when: <30m, 2h, @daily, or five fields of cron, as 0 9 * * 1-5>",
|
|
993
|
+
"---",
|
|
994
|
+
"<the prompt>",
|
|
995
|
+
fence,
|
|
996
|
+
"- When the conversation holds nothing worth doing again, say so, ask what the task should do, and leave the block out until you know."
|
|
997
|
+
].join(`
|
|
998
|
+
`);
|
|
999
|
+
}
|
|
1000
|
+
ChatTask.context = context;
|
|
1001
|
+
function find(text2) {
|
|
1002
|
+
const lines = text2.split(/\r?\n/);
|
|
1003
|
+
let found;
|
|
1004
|
+
for (let index = 0;index < lines.length; index++) {
|
|
1005
|
+
const open = /^\s*(`{3,})\s*([\w-]+)\s*$/.exec(lines[index]);
|
|
1006
|
+
if (open?.[2] !== TASK_BLOCK) {
|
|
1007
|
+
continue;
|
|
1008
|
+
}
|
|
1009
|
+
const close = new RegExp(`^\\s*${open[1]}\`*\\s*$`);
|
|
1010
|
+
const end = lines.findIndex((line, at) => at > index && close.test(line));
|
|
1011
|
+
found = lines.slice(index + 1, end < 0 ? lines.length : end);
|
|
1012
|
+
index = end < 0 ? lines.length : end;
|
|
1013
|
+
}
|
|
1014
|
+
return found && parse(found);
|
|
1015
|
+
}
|
|
1016
|
+
ChatTask.find = find;
|
|
1017
|
+
function parse(lines) {
|
|
1018
|
+
const rule = lines.findIndex((line) => line.trim() === "---");
|
|
1019
|
+
const head = rule < 0 ? [] : lines.slice(0, rule);
|
|
1020
|
+
const prompt = lines.slice(rule + 1).join(`
|
|
1021
|
+
`).trim();
|
|
1022
|
+
if (!prompt) {
|
|
1023
|
+
return;
|
|
1024
|
+
}
|
|
1025
|
+
const field = (key) => head.map((line) => new RegExp(`^\\s*${key}\\s*:\\s*(.*)$`, "i").exec(line)?.[1].trim()).find((value) => value !== undefined);
|
|
1026
|
+
const name = field("name") ?? "";
|
|
1027
|
+
const when = field("when");
|
|
1028
|
+
return { name, prompt, schedule: when ? schedule(when) : undefined };
|
|
1029
|
+
}
|
|
1030
|
+
function schedule(text2) {
|
|
1031
|
+
const when = text2.replace(/^["'`]|["'`]$/g, "").trim();
|
|
1032
|
+
if (Duration.parse(when) !== undefined) {
|
|
1033
|
+
return ScheduleUtil.check({ kind: "interval", every: when });
|
|
1034
|
+
}
|
|
1035
|
+
return ScheduleUtil.check({ kind: "cron", expression: when });
|
|
1036
|
+
}
|
|
1037
|
+
ChatTask.schedule = schedule;
|
|
1038
|
+
function pending(entries) {
|
|
1039
|
+
for (let index = entries.length - 1;index >= 0; index--) {
|
|
1040
|
+
const entry = entries[index];
|
|
1041
|
+
const custom = entry.type === "custom_message" ? entry : entry.message?.role === "custom" ? entry.message : undefined;
|
|
1042
|
+
if (custom?.customType === REPLY_TYPE && created(custom.details)) {
|
|
1043
|
+
return;
|
|
1044
|
+
}
|
|
1045
|
+
if (entry.type !== "message" || entry.message?.role !== "user") {
|
|
1046
|
+
continue;
|
|
1047
|
+
}
|
|
1048
|
+
const mark = MARK.exec(text(entry.message.content));
|
|
1049
|
+
if (mark) {
|
|
1050
|
+
return { schedule: mark[1] ? ScheduleUtil.check(JSON.parse(mark[1])) : undefined };
|
|
1051
|
+
}
|
|
1052
|
+
}
|
|
1053
|
+
return;
|
|
1054
|
+
}
|
|
1055
|
+
ChatTask.pending = pending;
|
|
1056
|
+
function text(content) {
|
|
1057
|
+
if (typeof content === "string") {
|
|
1058
|
+
return content;
|
|
1059
|
+
}
|
|
1060
|
+
return Array.isArray(content) ? content.filter((part) => part?.type === "text" && typeof part.text === "string").map((part) => part.text).join(`
|
|
1061
|
+
`) : "";
|
|
1062
|
+
}
|
|
1063
|
+
ChatTask.text = text;
|
|
1064
|
+
function created(details) {
|
|
1065
|
+
const reply = details;
|
|
1066
|
+
return reply?.kind === "task" && reply.event === "created";
|
|
1067
|
+
}
|
|
1068
|
+
})(ChatTask ||= {});
|
|
1069
|
+
|
|
551
1070
|
// web-src/task-extension.ts
|
|
552
1071
|
var PROMPT_MAX = 4000;
|
|
553
1072
|
var ANSWER_MAX = 2000;
|
|
@@ -704,6 +1223,16 @@ class CronClient {
|
|
|
704
1223
|
call(method, ...params) {
|
|
705
1224
|
return this.api.callHost(method, ...params);
|
|
706
1225
|
}
|
|
1226
|
+
async add(input) {
|
|
1227
|
+
const task = await this.call("add", input);
|
|
1228
|
+
await this.load();
|
|
1229
|
+
return task;
|
|
1230
|
+
}
|
|
1231
|
+
async update(id, patch) {
|
|
1232
|
+
const task = await this.call("update", id, patch);
|
|
1233
|
+
await this.load();
|
|
1234
|
+
return task;
|
|
1235
|
+
}
|
|
707
1236
|
setEnabled(id, enabled) {
|
|
708
1237
|
return this.change(id, (task) => ({ ...task, enabled }), () => this.call("setEnabled", id, enabled));
|
|
709
1238
|
}
|
|
@@ -786,6 +1315,53 @@ var React;
|
|
|
786
1315
|
function bind(react) {
|
|
787
1316
|
React = react;
|
|
788
1317
|
}
|
|
1318
|
+
var idle = () => [false, async (action) => await action()];
|
|
1319
|
+
function useBusy(ui) {
|
|
1320
|
+
return (ui.useBusy ?? idle)();
|
|
1321
|
+
}
|
|
1322
|
+
|
|
1323
|
+
// web-src/composer.tsx
|
|
1324
|
+
var PRESETS = [
|
|
1325
|
+
{ kind: "cron", expression: "0 * * * *" },
|
|
1326
|
+
{ kind: "cron", expression: "0 9 * * *" },
|
|
1327
|
+
{ kind: "cron", expression: "0 9 * * 1-5" },
|
|
1328
|
+
{ kind: "cron", expression: "0 9 * * 1" }
|
|
1329
|
+
];
|
|
1330
|
+
function composerAddon() {
|
|
1331
|
+
const send = (conversation, schedule) => void pi.server.prompt(conversation.sessionId, {
|
|
1332
|
+
clientMessageId: `ta-cron-chat:${Date.now()}`,
|
|
1333
|
+
message: ChatTask.message(pi.ui.language, schedule),
|
|
1334
|
+
streamingBehavior: "followUp"
|
|
1335
|
+
}).catch((error) => pi.ui.notify(t("failedAction", { message: message(error) }), "error"));
|
|
1336
|
+
return {
|
|
1337
|
+
actions: (conversation) => {
|
|
1338
|
+
if (conversation.group === NAME) {
|
|
1339
|
+
return [];
|
|
1340
|
+
}
|
|
1341
|
+
const AlarmClock = icon("AlarmClock");
|
|
1342
|
+
const group = t("fromChatWhen");
|
|
1343
|
+
return [
|
|
1344
|
+
{
|
|
1345
|
+
key: "make-task",
|
|
1346
|
+
label: t("fromChat"),
|
|
1347
|
+
detail: t("fromChatDetail"),
|
|
1348
|
+
icon: /* @__PURE__ */ React.createElement(AlarmClock, {
|
|
1349
|
+
size: 16
|
|
1350
|
+
}),
|
|
1351
|
+
items: [
|
|
1352
|
+
...PRESETS.map((schedule) => ({
|
|
1353
|
+
key: `make-task:${schedule.kind === "cron" ? schedule.expression : ""}`,
|
|
1354
|
+
label: ScheduleUtil.describe(schedule, pi.ui.language),
|
|
1355
|
+
group,
|
|
1356
|
+
run: () => send(conversation, schedule)
|
|
1357
|
+
})),
|
|
1358
|
+
{ key: "make-task:ask", label: t("fromChatOther"), detail: t("fromChatOtherDetail"), group, run: () => send(conversation) }
|
|
1359
|
+
]
|
|
1360
|
+
}
|
|
1361
|
+
];
|
|
1362
|
+
}
|
|
1363
|
+
};
|
|
1364
|
+
}
|
|
789
1365
|
|
|
790
1366
|
// web-src/next-card.tsx
|
|
791
1367
|
var SHOWN = 3;
|
|
@@ -868,238 +1444,6 @@ function watchRuns() {
|
|
|
868
1444
|
});
|
|
869
1445
|
}
|
|
870
1446
|
|
|
871
|
-
// web-src/commands.ts
|
|
872
|
-
var FLAG_NAMES = ["name", "notify", "model", "thinking", "cwd"];
|
|
873
|
-
var TRAILING_FLAG = new RegExp(`(?:^|\\s)--(${FLAG_NAMES.join("|")})(?:=|\\s+)("[^"]*"|'[^']*'|\\S*)\\s*$`);
|
|
874
|
-
var ACTIONS = ["add", "list", "show", "runs", "run", "enable", "disable", "set", "remove", "clear", "help"];
|
|
875
|
-
var HELP = `Scheduled tasks: each run is a conversation of its own in the Ta service, which runs them while it runs.
|
|
876
|
-
|
|
877
|
-
/loop <when> <prompt> repeat: 30m, 2h, @daily, @hourly, or a cron expression in quotes ("0 9 * * 1-5")
|
|
878
|
-
/remind in <duration> <prompt> once, after a while: in 45m
|
|
879
|
-
/remind at <time> <prompt> once, at a time: at 15:30, at 2026-11-12 09:00
|
|
880
|
-
/schedule add <when> <prompt> as /loop
|
|
881
|
-
/schedule list the tasks
|
|
882
|
-
/schedule show <task> a task and its last runs
|
|
883
|
-
/schedule run <task> run it now; its schedule stays
|
|
884
|
-
/schedule enable|disable <task>
|
|
885
|
-
/schedule set <task> [flags] change it; a value of - clears the flag
|
|
886
|
-
/schedule remove <task>
|
|
887
|
-
/schedule clear remove the tasks of this directory
|
|
888
|
-
|
|
889
|
-
A task is its id, the start of it, or its name. Flags at the end of a prompt:
|
|
890
|
-
--name <name> --notify always|error|never --model <provider/model> --thinking <level> --cwd <directory>`;
|
|
891
|
-
var CommandParser;
|
|
892
|
-
((CommandParser) => {
|
|
893
|
-
function splitFlags(text) {
|
|
894
|
-
const flags = {};
|
|
895
|
-
let rest = text.trim();
|
|
896
|
-
for (let match = TRAILING_FLAG.exec(rest);match; match = TRAILING_FLAG.exec(rest)) {
|
|
897
|
-
const key = match[1];
|
|
898
|
-
if (flags[key] === undefined) {
|
|
899
|
-
flags[key] = unquote(match[2]);
|
|
900
|
-
}
|
|
901
|
-
rest = rest.slice(0, match.index).trimEnd();
|
|
902
|
-
}
|
|
903
|
-
return { rest, flags };
|
|
904
|
-
}
|
|
905
|
-
CommandParser.splitFlags = splitFlags;
|
|
906
|
-
function repeating(text) {
|
|
907
|
-
const { rest, flags } = splitFlags(text);
|
|
908
|
-
const { schedule, remainder } = leadingSchedule(rest);
|
|
909
|
-
return input(schedule, remainder, flags);
|
|
910
|
-
}
|
|
911
|
-
CommandParser.repeating = repeating;
|
|
912
|
-
function reminder(text, now) {
|
|
913
|
-
const { rest, flags } = splitFlags(text);
|
|
914
|
-
const words = rest.split(/\s+/);
|
|
915
|
-
let at;
|
|
916
|
-
let used = 0;
|
|
917
|
-
if (words[0] === "at") {
|
|
918
|
-
const time = clockTime(words.slice(1, 3), now);
|
|
919
|
-
at = time?.date;
|
|
920
|
-
used = 1 + (time?.words ?? 0);
|
|
921
|
-
} else {
|
|
922
|
-
const offset = words[0] === "in" ? 1 : 0;
|
|
923
|
-
const ms = Duration.parse(words[offset] ?? "");
|
|
924
|
-
at = ms === undefined ? undefined : new Date(now.getTime() + ms);
|
|
925
|
-
used = offset + 1;
|
|
926
|
-
}
|
|
927
|
-
if (!at) {
|
|
928
|
-
throw new Error("Say when: /remind in 45m <prompt>, or /remind at 15:30 <prompt>.");
|
|
929
|
-
}
|
|
930
|
-
return input({ kind: "once", at: at.toISOString() }, words.slice(used).join(" "), flags);
|
|
931
|
-
}
|
|
932
|
-
CommandParser.reminder = reminder;
|
|
933
|
-
function action(text) {
|
|
934
|
-
const trimmed = text.trim();
|
|
935
|
-
const first = trimmed.split(/\s+/, 1)[0] || "list";
|
|
936
|
-
const action2 = first === "delete" ? "remove" : first === "ls" ? "list" : first;
|
|
937
|
-
if (!ACTIONS.includes(action2)) {
|
|
938
|
-
throw new Error(`/schedule does not know ${JSON.stringify(first)}. It takes: ${ACTIONS.join(", ")}.`);
|
|
939
|
-
}
|
|
940
|
-
return { action: action2, rest: trimmed.slice(trimmed ? first.length : 0).trim() };
|
|
941
|
-
}
|
|
942
|
-
CommandParser.action = action;
|
|
943
|
-
function patch(text) {
|
|
944
|
-
const { rest, flags } = splitFlags(text);
|
|
945
|
-
if (!rest) {
|
|
946
|
-
throw new Error("Name the task: /schedule set <task> --model <provider/model>.");
|
|
947
|
-
}
|
|
948
|
-
const value = (flag) => flag === undefined ? undefined : flag === "-" ? "" : flag;
|
|
949
|
-
const patch2 = {};
|
|
950
|
-
if (flags.name !== undefined) {
|
|
951
|
-
patch2.name = value(flags.name);
|
|
952
|
-
}
|
|
953
|
-
if (flags.cwd !== undefined) {
|
|
954
|
-
patch2.cwd = value(flags.cwd);
|
|
955
|
-
}
|
|
956
|
-
if (flags.model !== undefined) {
|
|
957
|
-
patch2.model = value(flags.model);
|
|
958
|
-
}
|
|
959
|
-
if (flags.thinking !== undefined) {
|
|
960
|
-
patch2.thinking = value(flags.thinking);
|
|
961
|
-
}
|
|
962
|
-
if (flags.notify !== undefined) {
|
|
963
|
-
patch2.notify = value(flags.notify);
|
|
964
|
-
}
|
|
965
|
-
if (Object.keys(patch2).length === 0) {
|
|
966
|
-
throw new Error("Say what changes: --name, --notify, --model, --thinking or --cwd.");
|
|
967
|
-
}
|
|
968
|
-
return { ref: rest, patch: patch2 };
|
|
969
|
-
}
|
|
970
|
-
CommandParser.patch = patch;
|
|
971
|
-
function leadingSchedule(text) {
|
|
972
|
-
const trimmed = text.trim();
|
|
973
|
-
const quote = trimmed[0];
|
|
974
|
-
if (quote === '"' || quote === "'") {
|
|
975
|
-
const end = trimmed.indexOf(quote, 1);
|
|
976
|
-
if (end < 0) {
|
|
977
|
-
throw new Error("The cron expression has no closing quote.");
|
|
978
|
-
}
|
|
979
|
-
return { schedule: ScheduleUtil.check({ kind: "cron", expression: trimmed.slice(1, end) }), remainder: trimmed.slice(end + 1) };
|
|
980
|
-
}
|
|
981
|
-
const [first = ""] = trimmed.split(/\s+/, 1);
|
|
982
|
-
const remainder = trimmed.slice(first.length);
|
|
983
|
-
if (first.startsWith("@")) {
|
|
984
|
-
return { schedule: ScheduleUtil.check({ kind: "cron", expression: first }), remainder };
|
|
985
|
-
}
|
|
986
|
-
if (Duration.parse(first) !== undefined) {
|
|
987
|
-
return { schedule: ScheduleUtil.check({ kind: "interval", every: first }), remainder };
|
|
988
|
-
}
|
|
989
|
-
throw new Error('Start with when: 30m, 2h, @daily, or a cron expression in quotes such as "0 9 * * 1-5".');
|
|
990
|
-
}
|
|
991
|
-
CommandParser.leadingSchedule = leadingSchedule;
|
|
992
|
-
function clockTime(words, now) {
|
|
993
|
-
const [first = "", second = ""] = words;
|
|
994
|
-
const hm = /^(\d{1,2}):(\d{2})$/;
|
|
995
|
-
const day = /^(\d{4})-(\d{1,2})-(\d{1,2})$/;
|
|
996
|
-
const time = hm.exec(first);
|
|
997
|
-
if (time) {
|
|
998
|
-
const date2 = new Date(now.getTime());
|
|
999
|
-
date2.setHours(Number(time[1]), Number(time[2]), 0, 0);
|
|
1000
|
-
if (date2.getTime() <= now.getTime()) {
|
|
1001
|
-
date2.setDate(date2.getDate() + 1);
|
|
1002
|
-
}
|
|
1003
|
-
return valid(date2, Number(time[1]) < 24 && Number(time[2]) < 60) ? { date: date2, words: 1 } : undefined;
|
|
1004
|
-
}
|
|
1005
|
-
const date = day.exec(first);
|
|
1006
|
-
const later = hm.exec(second);
|
|
1007
|
-
if (date) {
|
|
1008
|
-
const at = new Date(Number(date[1]), Number(date[2]) - 1, Number(date[3]), later ? Number(later[1]) : 9, later ? Number(later[2]) : 0);
|
|
1009
|
-
return valid(at, true) ? { date: at, words: later ? 2 : 1 } : undefined;
|
|
1010
|
-
}
|
|
1011
|
-
const iso = /^\d{4}-\d{2}-\d{2}T/.test(first) ? new Date(first) : undefined;
|
|
1012
|
-
return iso && valid(iso, true) ? { date: iso, words: 1 } : undefined;
|
|
1013
|
-
}
|
|
1014
|
-
CommandParser.clockTime = clockTime;
|
|
1015
|
-
function valid(date, ok) {
|
|
1016
|
-
return ok && !Number.isNaN(date.getTime());
|
|
1017
|
-
}
|
|
1018
|
-
function input(schedule, prompt, flags) {
|
|
1019
|
-
const text = prompt.trim();
|
|
1020
|
-
if (!text) {
|
|
1021
|
-
throw new Error("Then say what Ta should do: the prompt of the task.");
|
|
1022
|
-
}
|
|
1023
|
-
return {
|
|
1024
|
-
schedule,
|
|
1025
|
-
prompt: text,
|
|
1026
|
-
...flags.name ? { name: flags.name } : {},
|
|
1027
|
-
...flags.cwd ? { cwd: flags.cwd } : {},
|
|
1028
|
-
...flags.model ? { model: flags.model } : {},
|
|
1029
|
-
...flags.thinking ? { thinking: flags.thinking } : {},
|
|
1030
|
-
...flags.notify ? { notify: flags.notify } : {}
|
|
1031
|
-
};
|
|
1032
|
-
}
|
|
1033
|
-
function unquote(value) {
|
|
1034
|
-
return /^(["']).*\1$/.test(value) ? value.slice(1, -1) : value;
|
|
1035
|
-
}
|
|
1036
|
-
function completions(prefix, tasks) {
|
|
1037
|
-
const parts = prefix.split(/\s+/);
|
|
1038
|
-
if (parts.length <= 1) {
|
|
1039
|
-
return ACTIONS.filter((action3) => action3.startsWith(parts[0] ?? "")).map((action3) => ({ value: `${action3} `, label: action3 }));
|
|
1040
|
-
}
|
|
1041
|
-
const [action2, ref] = parts;
|
|
1042
|
-
if (!["show", "runs", "run", "enable", "disable", "set", "remove"].includes(action2) || parts.length > 2) {
|
|
1043
|
-
return [];
|
|
1044
|
-
}
|
|
1045
|
-
return tasks.filter((task) => task.id.startsWith(ref) || task.name.startsWith(ref)).map((task) => ({ value: `${action2} ${task.id} `, label: task.id, description: task.name }));
|
|
1046
|
-
}
|
|
1047
|
-
CommandParser.completions = completions;
|
|
1048
|
-
function loopCompletions(prefix) {
|
|
1049
|
-
if (/\s/.test(prefix)) {
|
|
1050
|
-
return [];
|
|
1051
|
-
}
|
|
1052
|
-
return [...Object.keys(NICKNAMES), "5m", "30m", "1h", "1d"].filter((item) => item.startsWith(prefix)).map((item) => ({ value: `${item} `, label: item }));
|
|
1053
|
-
}
|
|
1054
|
-
CommandParser.loopCompletions = loopCompletions;
|
|
1055
|
-
})(CommandParser ||= {});
|
|
1056
|
-
var CronText;
|
|
1057
|
-
((CronText) => {
|
|
1058
|
-
function task(task2, now = new Date) {
|
|
1059
|
-
const state = !task2.enabled ? "off" : task2.lastStatus === "running" ? "running" : task2.nextRunAt ? `next ${ScheduleUtil.clock(new Date(task2.nextRunAt), now)}` : "done";
|
|
1060
|
-
const last = task2.lastStatus && task2.lastStatus !== "running" ? `, last ${task2.lastStatus}` : "";
|
|
1061
|
-
return `${task2.id} ${task2.name} (${ScheduleUtil.describe(task2.schedule, "en", now)}; ${state}${last}) in ${task2.cwd}`;
|
|
1062
|
-
}
|
|
1063
|
-
CronText.task = task;
|
|
1064
|
-
function run(run2, now = new Date) {
|
|
1065
|
-
const time = ScheduleUtil.clock(new Date(run2.startedAt), now);
|
|
1066
|
-
const took = run2.endedAt ? ` in ${Duration.format(new Date(run2.endedAt).getTime() - new Date(run2.startedAt).getTime())}` : "";
|
|
1067
|
-
const what = run2.error ?? run2.summary ?? "";
|
|
1068
|
-
const file = run2.sessionFile ? `
|
|
1069
|
-
conversation: ${run2.sessionFile}` : "";
|
|
1070
|
-
return `${run2.id} ${time} ${run2.status}${took}${run2.trigger === "manual" ? " (by hand)" : ""}${what ? `
|
|
1071
|
-
${what.replace(/\n/g, `
|
|
1072
|
-
`)}` : ""}${file}`;
|
|
1073
|
-
}
|
|
1074
|
-
CronText.run = run;
|
|
1075
|
-
function reply(reply2) {
|
|
1076
|
-
switch (reply2.kind) {
|
|
1077
|
-
case "task":
|
|
1078
|
-
return `${capital(reply2.event)}: ${task(reply2.task)}`;
|
|
1079
|
-
case "removed":
|
|
1080
|
-
return reply2.tasks.length ? `Removed ${reply2.tasks.map((item) => item.name).join(", ")}.` : "No tasks to remove.";
|
|
1081
|
-
case "started":
|
|
1082
|
-
return `Started ${reply2.task.name} (${reply2.run.id}); it runs in a conversation of its own.`;
|
|
1083
|
-
case "list":
|
|
1084
|
-
return reply2.tasks.length ? reply2.tasks.map((item) => task(item)).join(`
|
|
1085
|
-
`) : "No scheduled tasks. Make one with /loop or /remind.";
|
|
1086
|
-
case "show":
|
|
1087
|
-
return `${task(reply2.task)}
|
|
1088
|
-
prompt: ${reply2.task.prompt}
|
|
1089
|
-
${reply2.runs.length ? reply2.runs.map((item) => run(item)).join(`
|
|
1090
|
-
`) : "No runs yet."}`;
|
|
1091
|
-
case "help":
|
|
1092
|
-
return HELP;
|
|
1093
|
-
case "error":
|
|
1094
|
-
return reply2.message;
|
|
1095
|
-
}
|
|
1096
|
-
}
|
|
1097
|
-
CronText.reply = reply;
|
|
1098
|
-
function capital(text) {
|
|
1099
|
-
return text[0].toUpperCase() + text.slice(1);
|
|
1100
|
-
}
|
|
1101
|
-
})(CronText ||= {});
|
|
1102
|
-
|
|
1103
1447
|
// web-src/reply.tsx
|
|
1104
1448
|
function TaskLine({ task }) {
|
|
1105
1449
|
const now = new Date;
|
|
@@ -1196,10 +1540,12 @@ var STYLE = `
|
|
|
1196
1540
|
.tcr-title-bar { flex: 1; min-width: 0; display: flex; align-items: center; gap: 4px; padding-left: 36px; }
|
|
1197
1541
|
|
|
1198
1542
|
/* Buttons and what is written quietly */
|
|
1199
|
-
|
|
1543
|
+
/* As the buttons of the page (.ta-button). */
|
|
1544
|
+
.tcr-button { display: inline-flex; align-items: center; justify-content: center; gap: 6px; height: 32px; padding: 0 12px; border: 1px solid var(--ta-border); border-radius: 8px; background: transparent; color: var(--ta-text); font: inherit; font-size: calc(13px * var(--ta-font-scale)); font-weight: 500; white-space: nowrap; cursor: pointer; transition: background 120ms, border-color 120ms, opacity 120ms, transform 120ms var(--ta-ease); }
|
|
1200
1545
|
.tcr-button:hover:not(:disabled) { background: var(--ta-hover); }
|
|
1201
1546
|
.tcr-button:active:not(:disabled) { transform: scale(.97); }
|
|
1202
|
-
.tcr-button:disabled { opacity: .45; cursor: default; }
|
|
1547
|
+
.tcr-button:disabled:not(.ta-busy) { opacity: .45; cursor: default; }
|
|
1548
|
+
.tcr-button.ta-busy { position: relative; }
|
|
1203
1549
|
.tcr-button > svg { flex: none; color: var(--ta-secondary); }
|
|
1204
1550
|
.tcr-primary { background: var(--ta-brand); border-color: var(--ta-brand); color: var(--ta-brand-text); }
|
|
1205
1551
|
.tcr-primary:hover:not(:disabled) { background: var(--ta-brand); opacity: .88; }
|
|
@@ -1252,13 +1598,8 @@ var STYLE = `
|
|
|
1252
1598
|
@keyframes tcr-fade { 50% { opacity: .45; } }
|
|
1253
1599
|
|
|
1254
1600
|
/* The switch of a task: as the switches of the page */
|
|
1255
|
-
|
|
1256
|
-
.tcr-switch
|
|
1257
|
-
.tcr-switch span { position: absolute; inset: 0; border-radius: 999px; background: var(--ta-hover-strong, var(--ta-border)); transition: background 160ms; pointer-events: none; }
|
|
1258
|
-
.tcr-switch span::after { content: ''; position: absolute; top: 2px; left: 2px; width: 16px; height: 16px; border-radius: 50%; background: #fff; box-shadow: 0 1px 3px rgba(0,0,0,.3); transition: transform 180ms var(--ta-ease); }
|
|
1259
|
-
.tcr-switch input:checked + span { background: var(--ta-green); }
|
|
1260
|
-
.tcr-switch input:checked + span::after { transform: translateX(16px); }
|
|
1261
|
-
.tcr-switch input:focus-visible + span { outline: 2px solid var(--ta-border-focus); outline-offset: 2px; }
|
|
1601
|
+
/* The switch of the page (ta-switch), in a label that a finger has room around. */
|
|
1602
|
+
.tcr-switch { position: relative; flex: none; display: flex; cursor: pointer; }
|
|
1262
1603
|
|
|
1263
1604
|
/* What a task holds, opened: what can be done with it, its prompt and its runs */
|
|
1264
1605
|
.tcr-detail { display: flex; flex-direction: column; margin: 0 16px; padding: 14px 0 16px; border-top: 1px solid var(--ta-border-muted); animation: tcr-in 160ms var(--ta-ease); }
|
|
@@ -1319,10 +1660,11 @@ var STYLE = `
|
|
|
1319
1660
|
.tcr-mono { font-family: var(--ta-mono); }
|
|
1320
1661
|
.tcr-amount { width: 90px; flex: none; }
|
|
1321
1662
|
.tcr-row { display: flex; gap: 8px; }
|
|
1322
|
-
.tcr-segments { display: flex; gap: 2px; padding: 3px; border-radius: 10px; background: var(--ta-
|
|
1323
|
-
.tcr-segment { flex: 1 0 auto; height: 28px; padding: 0 12px; border: 0; border-radius: 7px; background: none; color: var(--ta-secondary); font: inherit; font-size: calc(
|
|
1663
|
+
.tcr-segments { display: flex; gap: 2px; padding: 3px; border-radius: 10px; background: var(--ta-raised); align-self: stretch; max-width: 100%; overflow-x: auto; scrollbar-width: none; }
|
|
1664
|
+
.tcr-segment { flex: 1 0 auto; height: 28px; padding: 0 12px; border: 0; border-radius: 7px; background: none; color: var(--ta-secondary); font: inherit; font-size: calc(12.5px * var(--ta-font-scale)); font-weight: 500; white-space: nowrap; cursor: pointer; transition: background 140ms, color 140ms, box-shadow 140ms; }
|
|
1324
1665
|
.tcr-segment:hover:not([aria-pressed='true']) { color: var(--ta-text); }
|
|
1325
|
-
|
|
1666
|
+
/* As the segmented controls of the page (its settings). */
|
|
1667
|
+
.tcr-segment[aria-pressed='true'] { background: var(--ta-segment, var(--ta-card)); color: var(--ta-text); box-shadow: 0 1px 2px rgba(0, 0, 0, 0.2), 0 0 0 1px var(--ta-border); }
|
|
1326
1668
|
.tcr-preview { display: inline-flex; align-items: center; gap: 6px; align-self: flex-start; padding: 3px 10px; border-radius: 999px; background: color-mix(in srgb, var(--ta-green) 11%, transparent); color: var(--ta-green); font-size: calc(12.5px * var(--ta-font-scale)); font-variant-numeric: tabular-nums; }
|
|
1327
1669
|
.tcr-preview.tcr-bad { background: color-mix(in srgb, var(--ta-red) 11%, transparent); color: var(--ta-red); }
|
|
1328
1670
|
.tcr-folder { display: flex; align-items: center; gap: 8px; text-align: left; cursor: pointer; }
|
|
@@ -1339,7 +1681,7 @@ var STYLE = `
|
|
|
1339
1681
|
.tcr-options.tcr-open .tcr-more-toggle .tcr-chevron { transform: none; }
|
|
1340
1682
|
.tcr-options .tcr-grid { animation: tcr-in 140ms var(--ta-ease); }
|
|
1341
1683
|
.tcr-actions { display: flex; align-items: center; justify-content: flex-end; gap: 8px; padding: 12px 18px 16px; border-top: 1px solid var(--ta-border-muted); }
|
|
1342
|
-
.tcr-actions .tcr-button {
|
|
1684
|
+
.tcr-actions .tcr-button { padding: 0 14px; }
|
|
1343
1685
|
.tcr-shortcut { margin-right: auto; color: var(--ta-muted); font-size: calc(12px * var(--ta-font-scale)); }
|
|
1344
1686
|
|
|
1345
1687
|
/* A task in a conversation, as a command or the tool answers */
|
|
@@ -1695,9 +2037,9 @@ function TaskEditor({ client, editing, onClose }) {
|
|
|
1695
2037
|
try {
|
|
1696
2038
|
const input = FormUtil.input(form);
|
|
1697
2039
|
if (editing.task) {
|
|
1698
|
-
await client.
|
|
2040
|
+
await client.update(editing.task.id, { ...input, name: form.name, model: form.model, thinking: form.thinking, notify: form.notify });
|
|
1699
2041
|
} else {
|
|
1700
|
-
await client.
|
|
2042
|
+
await client.add(input);
|
|
1701
2043
|
if (typeof Notification !== "undefined" && Notification.permission === "default") {
|
|
1702
2044
|
Notification.requestPermission().catch(() => {
|
|
1703
2045
|
return;
|
|
@@ -1799,10 +2141,13 @@ function TaskEditor({ client, editing, onClose }) {
|
|
|
1799
2141
|
onClick: onClose
|
|
1800
2142
|
}, t("cancel")), /* @__PURE__ */ React.createElement("button", {
|
|
1801
2143
|
type: "button",
|
|
1802
|
-
className: "tcr-button tcr-primary",
|
|
2144
|
+
className: saving ? "tcr-button tcr-primary ta-busy" : "tcr-button tcr-primary",
|
|
2145
|
+
"aria-busy": saving || undefined,
|
|
1803
2146
|
disabled: !valid || saving,
|
|
1804
2147
|
onClick: () => void save()
|
|
1805
|
-
}, editing.task ? t("save") : t("create")
|
|
2148
|
+
}, editing.task ? t("save") : t("create"), saving && /* @__PURE__ */ React.createElement("span", {
|
|
2149
|
+
className: "ta-spinner ta-busy-mark ta-on-brand"
|
|
2150
|
+
})))), picking && /* @__PURE__ */ React.createElement(FolderPicker, {
|
|
1806
2151
|
initial: form.cwd || cwd,
|
|
1807
2152
|
onPick: (path) => {
|
|
1808
2153
|
set({ cwd: path });
|
|
@@ -2014,7 +2359,10 @@ var TaskUtil;
|
|
|
2014
2359
|
if (input.notify !== undefined) {
|
|
2015
2360
|
task.notify = checkNotify(input.notify);
|
|
2016
2361
|
}
|
|
2017
|
-
|
|
2362
|
+
if (input.timeout !== undefined) {
|
|
2363
|
+
task.timeout = checkTimeout(input.timeout);
|
|
2364
|
+
}
|
|
2365
|
+
for (const key of ["model", "thinking", "notify", "timeout"]) {
|
|
2018
2366
|
if (task[key] === undefined) {
|
|
2019
2367
|
delete task[key];
|
|
2020
2368
|
}
|
|
@@ -2053,6 +2401,21 @@ var TaskUtil;
|
|
|
2053
2401
|
}
|
|
2054
2402
|
return level || undefined;
|
|
2055
2403
|
}
|
|
2404
|
+
function timeoutMs(task, fallback) {
|
|
2405
|
+
return task.timeout && Duration.parse(task.timeout) || fallback;
|
|
2406
|
+
}
|
|
2407
|
+
TaskUtil.timeoutMs = timeoutMs;
|
|
2408
|
+
function checkTimeout(value) {
|
|
2409
|
+
const text = typeof value === "string" ? value.trim() : "";
|
|
2410
|
+
if (!text) {
|
|
2411
|
+
return;
|
|
2412
|
+
}
|
|
2413
|
+
const ms = Duration.parse(text);
|
|
2414
|
+
if (ms === undefined || ms < Limits.RUN_TIMEOUT_MIN_MS || ms > Limits.RUN_TIMEOUT_MAX_MS) {
|
|
2415
|
+
throw new Error(`A timeout is a duration from 5m to 4h, as 90m or 2h; not ${JSON.stringify(text)}.`);
|
|
2416
|
+
}
|
|
2417
|
+
return Duration.format(ms);
|
|
2418
|
+
}
|
|
2056
2419
|
function checkNotify(value) {
|
|
2057
2420
|
if (value === "" || value === null) {
|
|
2058
2421
|
return;
|
|
@@ -2311,6 +2674,7 @@ function TaskRow({ client, task, now, onEdit }) {
|
|
|
2311
2674
|
const running = task.lastStatus === "running";
|
|
2312
2675
|
const state = running ? t("running") : !task.enabled ? task.nextRunAt || ScheduleUtil.repeats(task.schedule) ? t("paused") : t("done") : task.nextRunAt ? t("next", { time: until(new Date(task.nextRunAt).getTime(), now) }) : t("done");
|
|
2313
2676
|
const tone = running ? "running" : !task.enabled ? "off" : task.lastStatus ?? "idle";
|
|
2677
|
+
const [switching, run] = useBusy(pi.ui);
|
|
2314
2678
|
const remove = async () => {
|
|
2315
2679
|
if (await pi.ui.confirm(t("confirmDelete", { name: task.name }), t("confirmDeleteMessage"), { confirmLabel: t("delete"), danger: true })) {
|
|
2316
2680
|
await guard(() => client.remove(task.id));
|
|
@@ -2365,10 +2729,17 @@ function TaskRow({ client, task, now, onEdit }) {
|
|
|
2365
2729
|
title: t("enable")
|
|
2366
2730
|
}, /* @__PURE__ */ React.createElement("input", {
|
|
2367
2731
|
type: "checkbox",
|
|
2732
|
+
role: "switch",
|
|
2733
|
+
className: switching ? "ta-switch ta-busy" : "ta-switch",
|
|
2368
2734
|
checked: task.enabled,
|
|
2369
2735
|
"aria-label": t("enable"),
|
|
2370
|
-
|
|
2371
|
-
|
|
2736
|
+
"aria-checked": task.enabled,
|
|
2737
|
+
"aria-busy": switching || undefined,
|
|
2738
|
+
onChange: (event) => {
|
|
2739
|
+
const on = event.target.checked;
|
|
2740
|
+
run(() => guard(() => client.setEnabled(task.id, on)));
|
|
2741
|
+
}
|
|
2742
|
+
})), /* @__PURE__ */ React.createElement("button", {
|
|
2372
2743
|
type: "button",
|
|
2373
2744
|
className: "tcr-icon tcr-more",
|
|
2374
2745
|
"aria-label": t("more"),
|
|
@@ -2436,6 +2807,40 @@ function TasksPage({ client }) {
|
|
|
2436
2807
|
}));
|
|
2437
2808
|
}
|
|
2438
2809
|
|
|
2810
|
+
// web-src/tool-line.ts
|
|
2811
|
+
var VERBS = {
|
|
2812
|
+
add: "toolAdd",
|
|
2813
|
+
update: "toolUpdate",
|
|
2814
|
+
list: "toolList",
|
|
2815
|
+
show: "toolShow",
|
|
2816
|
+
enable: "toolEnable",
|
|
2817
|
+
disable: "toolDisable",
|
|
2818
|
+
delete: "toolDelete",
|
|
2819
|
+
run: "toolRun",
|
|
2820
|
+
runs: "toolRuns",
|
|
2821
|
+
clear: "toolClear"
|
|
2822
|
+
};
|
|
2823
|
+
function text(value) {
|
|
2824
|
+
return typeof value === "string" ? value.trim() : "";
|
|
2825
|
+
}
|
|
2826
|
+
var CronToolLine;
|
|
2827
|
+
((CronToolLine) => {
|
|
2828
|
+
function renderCall(args, t2) {
|
|
2829
|
+
const action = text(args.action);
|
|
2830
|
+
const verb = t2(VERBS[action] ?? "toolOther");
|
|
2831
|
+
if (action === "add") {
|
|
2832
|
+
return { verb, target: text(args.name) || text(args.prompt).split(`
|
|
2833
|
+
`)[0] };
|
|
2834
|
+
}
|
|
2835
|
+
return { verb, target: action === "list" || action === "clear" ? "" : text(args.name) || text(args.id) };
|
|
2836
|
+
}
|
|
2837
|
+
CronToolLine.renderCall = renderCall;
|
|
2838
|
+
function register(pi2, t2) {
|
|
2839
|
+
pi2.registerToolRenderer?.((name, next) => name === TOOL_NAME ? { renderCall: (args) => renderCall(args, t2) } : next());
|
|
2840
|
+
}
|
|
2841
|
+
CronToolLine.register = register;
|
|
2842
|
+
})(CronToolLine ||= {});
|
|
2843
|
+
|
|
2439
2844
|
// web-src/index.tsx
|
|
2440
2845
|
function activate(pi2) {
|
|
2441
2846
|
bind(pi2.React);
|
|
@@ -2465,6 +2870,8 @@ function activate(pi2) {
|
|
|
2465
2870
|
})
|
|
2466
2871
|
});
|
|
2467
2872
|
pi2.registerMessageRenderer(REPLY_TYPE, ReplyMessage);
|
|
2873
|
+
pi2.registerComposerAddon(composerAddon());
|
|
2874
|
+
CronToolLine.register(pi2, (key) => t(key));
|
|
2468
2875
|
const stopWatching = watchRuns();
|
|
2469
2876
|
return () => {
|
|
2470
2877
|
stopWatching();
|