@sixb/app 0.2.1 → 0.2.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/agent/activity-label.d.ts.map +1 -1
- package/dist/agent/agent-chat.d.ts +9 -2
- package/dist/agent/agent-chat.d.ts.map +1 -1
- package/dist/agent/agent-panel.d.ts +9 -1
- package/dist/agent/agent-panel.d.ts.map +1 -1
- package/dist/agent/agent-surface.d.ts.map +1 -1
- package/dist/agent/artifact-card.d.ts +3 -1
- package/dist/agent/artifact-card.d.ts.map +1 -1
- package/dist/agent/artifact-panel.d.ts +7 -1
- package/dist/agent/artifact-panel.d.ts.map +1 -1
- package/dist/agent/background/background-tool-row.d.ts.map +1 -1
- package/dist/agent/background/interpret.d.ts +1 -1
- package/dist/agent/background/interpret.d.ts.map +1 -1
- package/dist/agent/components/composer-place.d.ts +3 -1
- package/dist/agent/components/composer-place.d.ts.map +1 -1
- package/dist/agent/components/composer.d.ts +20 -1
- package/dist/agent/components/composer.d.ts.map +1 -1
- package/dist/agent/components/context-chips.d.ts.map +1 -1
- package/dist/agent/components/context-meter.d.ts +1 -1
- package/dist/agent/components/conversation-panel.d.ts +7 -2
- package/dist/agent/components/conversation-panel.d.ts.map +1 -1
- package/dist/agent/components/message-parts.d.ts +3 -1
- package/dist/agent/components/message-parts.d.ts.map +1 -1
- package/dist/agent/components/thread-artifacts-menu.d.ts.map +1 -1
- package/dist/agent/components/transcript.d.ts +5 -0
- package/dist/agent/components/transcript.d.ts.map +1 -1
- package/dist/agent/composer-insertion.d.ts +24 -0
- package/dist/agent/composer-insertion.d.ts.map +1 -0
- package/dist/agent/delegation/agent-exchange.d.ts +16 -0
- package/dist/agent/delegation/agent-exchange.d.ts.map +1 -0
- package/dist/agent/delegation/child-card.d.ts +3 -3
- package/dist/agent/delegation/child-card.d.ts.map +1 -1
- package/dist/agent/delegation/child-parts.d.ts +1 -10
- package/dist/agent/delegation/child-parts.d.ts.map +1 -1
- package/dist/agent/delegation/child-work.d.ts.map +1 -1
- package/dist/agent/delegation/interpret.d.ts +4 -10
- package/dist/agent/delegation/interpret.d.ts.map +1 -1
- package/dist/agent/delegation/use-children.d.ts +5 -5
- package/dist/agent/delegation/use-children.d.ts.map +1 -1
- package/dist/agent/file-edits/file-edit-tool-view.d.ts +10 -0
- package/dist/agent/file-edits/file-edit-tool-view.d.ts.map +1 -0
- package/dist/agent/file-edits/interpret.d.ts +25 -0
- package/dist/agent/file-edits/interpret.d.ts.map +1 -0
- package/dist/agent/hooks/use-agent-conversation.d.ts +16 -4
- package/dist/agent/hooks/use-agent-conversation.d.ts.map +1 -1
- package/dist/agent/hooks/use-new-thread-place.d.ts +39 -17
- package/dist/agent/hooks/use-new-thread-place.d.ts.map +1 -1
- package/dist/agent/hooks/use-thread-lists.d.ts.map +1 -1
- package/dist/agent/i18n/en.d.ts +59 -4
- package/dist/agent/i18n/en.d.ts.map +1 -1
- package/dist/agent/i18n/fr.d.ts.map +1 -1
- package/dist/agent/i18n/index.d.ts +96 -8
- package/dist/agent/i18n/index.d.ts.map +1 -1
- package/dist/agent/message-agent/interpret.d.ts +2 -2
- package/dist/agent/message-agent/interpret.d.ts.map +1 -1
- package/dist/agent/publish-artifact/interpret.d.ts +8 -2
- package/dist/agent/publish-artifact/interpret.d.ts.map +1 -1
- package/dist/agent/publish-artifact/open-artifact-tool-view.d.ts +9 -0
- package/dist/agent/publish-artifact/open-artifact-tool-view.d.ts.map +1 -0
- package/dist/agent/publish-artifact/publish-artifact-tool-view.d.ts +4 -2
- package/dist/agent/publish-artifact/publish-artifact-tool-view.d.ts.map +1 -1
- package/dist/agent/publish-artifact/use-live-publishes.d.ts +3 -3
- package/dist/agent/publish-artifact/use-live-publishes.d.ts.map +1 -1
- package/dist/agent/questions/interpret.d.ts +31 -0
- package/dist/agent/questions/interpret.d.ts.map +1 -0
- package/dist/agent/questions/question-card.d.ts +16 -0
- package/dist/agent/questions/question-card.d.ts.map +1 -0
- package/dist/agent/questions/question-composer.d.ts +15 -0
- package/dist/agent/questions/question-composer.d.ts.map +1 -0
- package/dist/agent/read/interpret.d.ts +8 -1
- package/dist/agent/read/interpret.d.ts.map +1 -1
- package/dist/agent/read/read-tool-view.d.ts.map +1 -1
- package/dist/agent/tool-views/built-in.d.ts.map +1 -1
- package/dist/agent/types.d.ts +3 -1
- package/dist/agent/types.d.ts.map +1 -1
- package/dist/agent/waits.d.ts +14 -0
- package/dist/agent/waits.d.ts.map +1 -0
- package/dist/artifacts/artifact-page.d.ts.map +1 -1
- package/dist/artifacts/artifact-viewer.d.ts +16 -0
- package/dist/artifacts/artifact-viewer.d.ts.map +1 -0
- package/dist/artifacts/card-details.d.ts +1 -1
- package/dist/artifacts/card-details.d.ts.map +1 -1
- package/dist/artifacts/card-preview.d.ts.map +1 -1
- package/dist/artifacts/comments-context.d.ts +48 -0
- package/dist/artifacts/comments-context.d.ts.map +1 -0
- package/dist/artifacts/edit-session.d.ts +17 -7
- package/dist/artifacts/edit-session.d.ts.map +1 -1
- package/dist/artifacts/file-source.d.ts.map +1 -1
- package/dist/artifacts/frame.d.ts +10 -2
- package/dist/artifacts/frame.d.ts.map +1 -1
- package/dist/artifacts/guest-badge.d.ts +8 -0
- package/dist/artifacts/guest-badge.d.ts.map +1 -0
- package/dist/artifacts/held-artifact.d.ts +19 -0
- package/dist/artifacts/held-artifact.d.ts.map +1 -0
- package/dist/artifacts/holders.d.ts +10 -0
- package/dist/artifacts/holders.d.ts.map +1 -0
- package/dist/artifacts/live/boards.d.ts +15 -0
- package/dist/artifacts/live/boards.d.ts.map +1 -0
- package/dist/artifacts/live/canvas.d.ts +79 -0
- package/dist/artifacts/live/canvas.d.ts.map +1 -0
- package/dist/artifacts/live/header.d.ts +29 -0
- package/dist/artifacts/live/header.d.ts.map +1 -0
- package/dist/artifacts/live/hooks.d.ts +21 -0
- package/dist/artifacts/live/hooks.d.ts.map +1 -0
- package/dist/artifacts/live/presence.d.ts +32 -0
- package/dist/artifacts/live/presence.d.ts.map +1 -0
- package/dist/artifacts/live/session.d.ts +130 -0
- package/dist/artifacts/live/session.d.ts.map +1 -0
- package/dist/artifacts/live/view.d.ts +28 -0
- package/dist/artifacts/live/view.d.ts.map +1 -0
- package/dist/artifacts/messages.d.ts +476 -14
- package/dist/artifacts/messages.d.ts.map +1 -1
- package/dist/artifacts/page-queries.d.ts +2 -2
- package/dist/artifacts/page-queries.d.ts.map +1 -1
- package/dist/artifacts/page-state.d.ts.map +1 -1
- package/dist/artifacts/publish-edit.d.ts +24 -14
- package/dist/artifacts/publish-edit.d.ts.map +1 -1
- package/dist/artifacts/queries.d.ts +490 -9
- package/dist/artifacts/queries.d.ts.map +1 -1
- package/dist/artifacts/references/references.d.ts.map +1 -1
- package/dist/artifacts/renderers/canvas/arrows.d.ts +0 -18
- package/dist/artifacts/renderers/canvas/arrows.d.ts.map +1 -1
- package/dist/artifacts/renderers/canvas/board-editor.d.ts +50 -0
- package/dist/artifacts/renderers/canvas/board-editor.d.ts.map +1 -0
- package/dist/artifacts/renderers/canvas/board-properties.d.ts +37 -0
- package/dist/artifacts/renderers/canvas/board-properties.d.ts.map +1 -0
- package/dist/artifacts/renderers/canvas/board-source.d.ts +18 -0
- package/dist/artifacts/renderers/canvas/board-source.d.ts.map +1 -0
- package/dist/artifacts/renderers/canvas/board.d.ts +77 -20
- package/dist/artifacts/renderers/canvas/board.d.ts.map +1 -1
- package/dist/artifacts/renderers/canvas/canvas.d.ts +14 -4
- package/dist/artifacts/renderers/canvas/canvas.d.ts.map +1 -1
- package/dist/artifacts/renderers/canvas/comment-pins.d.ts +84 -0
- package/dist/artifacts/renderers/canvas/comment-pins.d.ts.map +1 -0
- package/dist/artifacts/renderers/canvas/commenting.d.ts +58 -0
- package/dist/artifacts/renderers/canvas/commenting.d.ts.map +1 -0
- package/dist/artifacts/renderers/canvas/comments-panel.d.ts +27 -0
- package/dist/artifacts/renderers/canvas/comments-panel.d.ts.map +1 -0
- package/dist/artifacts/renderers/canvas/comments.d.ts +56 -0
- package/dist/artifacts/renderers/canvas/comments.d.ts.map +1 -0
- package/dist/artifacts/renderers/canvas/controls.d.ts +15 -4
- package/dist/artifacts/renderers/canvas/controls.d.ts.map +1 -1
- package/dist/artifacts/renderers/canvas/draft.d.ts +7 -6
- package/dist/artifacts/renderers/canvas/draft.d.ts.map +1 -1
- package/dist/artifacts/renderers/canvas/edit-mode.d.ts +19 -2
- package/dist/artifacts/renderers/canvas/edit-mode.d.ts.map +1 -1
- package/dist/artifacts/renderers/canvas/focus.d.ts +54 -5
- package/dist/artifacts/renderers/canvas/focus.d.ts.map +1 -1
- package/dist/artifacts/renderers/canvas/gestures.d.ts +46 -0
- package/dist/artifacts/renderers/canvas/gestures.d.ts.map +1 -0
- package/dist/artifacts/renderers/canvas/items.d.ts +47 -4
- package/dist/artifacts/renderers/canvas/items.d.ts.map +1 -1
- package/dist/artifacts/renderers/canvas/layout.d.ts +5 -8
- package/dist/artifacts/renderers/canvas/layout.d.ts.map +1 -1
- package/dist/artifacts/renderers/canvas/page-resize.d.ts +21 -0
- package/dist/artifacts/renderers/canvas/page-resize.d.ts.map +1 -0
- package/dist/artifacts/renderers/canvas/page-size-controls.d.ts +21 -0
- package/dist/artifacts/renderers/canvas/page-size-controls.d.ts.map +1 -0
- package/dist/artifacts/renderers/canvas/page-size.d.ts +93 -0
- package/dist/artifacts/renderers/canvas/page-size.d.ts.map +1 -0
- package/dist/artifacts/renderers/canvas/page-zoom.d.ts +64 -0
- package/dist/artifacts/renderers/canvas/page-zoom.d.ts.map +1 -0
- package/dist/artifacts/renderers/canvas/presence.d.ts +21 -0
- package/dist/artifacts/renderers/canvas/presence.d.ts.map +1 -0
- package/dist/artifacts/renderers/canvas/previews.d.ts +54 -0
- package/dist/artifacts/renderers/canvas/previews.d.ts.map +1 -0
- package/dist/artifacts/renderers/canvas/renderer.d.ts +11 -2
- package/dist/artifacts/renderers/canvas/renderer.d.ts.map +1 -1
- package/dist/artifacts/renderers/canvas/shown-size.d.ts +26 -0
- package/dist/artifacts/renderers/canvas/shown-size.d.ts.map +1 -0
- package/dist/artifacts/renderers/canvas/thumbnail.d.ts +5 -2
- package/dist/artifacts/renderers/canvas/thumbnail.d.ts.map +1 -1
- package/dist/artifacts/version-menu.d.ts +19 -0
- package/dist/artifacts/version-menu.d.ts.map +1 -0
- package/dist/artifacts/view-context.d.ts +43 -0
- package/dist/artifacts/view-context.d.ts.map +1 -0
- package/dist/artifacts/viewer.d.ts.map +1 -1
- package/dist/build.d.ts +5 -0
- package/dist/build.d.ts.map +1 -1
- package/dist/chunk-00wggsst.js +7 -0
- package/dist/chunk-00wggsst.js.map +10 -0
- package/dist/{chunk-q69001w3.js → chunk-694m74s7.js} +7 -1
- package/dist/{chunk-q69001w3.js.map → chunk-694m74s7.js.map} +3 -3
- package/dist/{chunk-7fj9cfkw.js → chunk-970s5nkn.js} +1 -1
- package/dist/{chunk-4mprsd2n.js → chunk-fg6thecb.js} +25 -1
- package/dist/chunk-fg6thecb.js.map +10 -0
- package/dist/{chunk-ytadd0b5.js → chunk-kymx9y5e.js} +8126 -4257
- package/dist/chunk-kymx9y5e.js.map +211 -0
- package/dist/{chunk-j8g956dt.js → chunk-pxd07kvx.js} +1 -1
- package/dist/{chunk-kwbw4dyk.js → chunk-ryed2jq8.js} +1 -1
- package/dist/chunk-yrcm1pbg.js +5975 -0
- package/dist/chunk-yrcm1pbg.js.map +34 -0
- package/dist/codegen.d.ts.map +1 -1
- package/dist/createCustomApp.d.ts.map +1 -1
- package/dist/index.d.ts +9 -1
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +932 -309
- package/dist/index.js.map +15 -10
- package/dist/locale-messages.d.ts +12 -0
- package/dist/locale-messages.d.ts.map +1 -1
- package/dist/locale.d.ts +12 -0
- package/dist/locale.d.ts.map +1 -1
- package/dist/locale.js +1 -1
- package/dist/metadata.d.ts +8 -0
- package/dist/metadata.d.ts.map +1 -1
- package/dist/pages/console/action-run.d.ts.map +1 -1
- package/dist/pages/console/data/connectors.d.ts.map +1 -1
- package/dist/pages/console/data/datasets.d.ts.map +1 -1
- package/dist/pages/console/data/lake-health.d.ts +3 -0
- package/dist/pages/console/data/lake-health.d.ts.map +1 -0
- package/dist/pages/console/data/messages.d.ts +98 -2
- package/dist/pages/console/data/messages.d.ts.map +1 -1
- package/dist/pages/console/data/pipelines.d.ts.map +1 -1
- package/dist/pages/console/data/projections.d.ts.map +1 -1
- package/dist/pages/console/data/syncs.d.ts.map +1 -1
- package/dist/pages/console/ontology/action-runs.d.ts.map +1 -1
- package/dist/pages/console/ontology/actions.d.ts.map +1 -1
- package/dist/pages/console/ontology/components/action-button.d.ts.map +1 -1
- package/dist/pages/console/ontology/components/artifact-picker.d.ts +36 -0
- package/dist/pages/console/ontology/components/artifact-picker.d.ts.map +1 -0
- package/dist/pages/console/ontology/components/object-query-bar.d.ts.map +1 -1
- package/dist/pages/console/ontology/lib/action-params.d.ts +2 -0
- package/dist/pages/console/ontology/lib/action-params.d.ts.map +1 -1
- package/dist/pages/console/ontology/lineage/properties-panel.d.ts +2 -1
- package/dist/pages/console/ontology/lineage/properties-panel.d.ts.map +1 -1
- package/dist/pages/console/ontology/object-page.d.ts.map +1 -1
- package/dist/pages/console/ontology/object-type.d.ts.map +1 -1
- package/dist/pages/console/ontology/object-types.d.ts.map +1 -1
- package/dist/pages/console/ontology/objects.d.ts.map +1 -1
- package/dist/pages/console/ontology/rules.d.ts.map +1 -1
- package/dist/pages/console/ontology/workflow.d.ts.map +1 -1
- package/dist/pages/console/ontology/workflows/run-input-form.d.ts.map +1 -1
- package/dist/pages/console/ontology/workflows/schema-shape.d.ts.map +1 -1
- package/dist/pages/console/ontology/workflows.d.ts.map +1 -1
- package/dist/pages/console/skeletons.d.ts +30 -0
- package/dist/pages/console/skeletons.d.ts.map +1 -0
- package/dist/pages/console/workflow-run.d.ts.map +1 -1
- package/dist/pages/section-page.d.ts +11 -1
- package/dist/pages/section-page.d.ts.map +1 -1
- package/dist/pages/section-ui.d.ts +25 -3
- package/dist/pages/section-ui.d.ts.map +1 -1
- package/dist/pages/settings/activity/calendar.d.ts.map +1 -1
- package/dist/pages/settings/activity/connections.d.ts.map +1 -1
- package/dist/pages/settings/activity/page.d.ts.map +1 -1
- package/dist/pages/settings/activity/thread.d.ts.map +1 -1
- package/dist/pages/settings/activity/timeline.d.ts +2 -0
- package/dist/pages/settings/activity/timeline.d.ts.map +1 -1
- package/dist/pages/settings/controls.d.ts +4 -0
- package/dist/pages/settings/controls.d.ts.map +1 -1
- package/dist/pages/settings/members.d.ts.map +1 -1
- package/dist/pages/settings/memory-history.d.ts +2 -0
- package/dist/pages/settings/memory-history.d.ts.map +1 -1
- package/dist/pages/settings/memory.d.ts.map +1 -1
- package/dist/pages/settings/service-accounts.d.ts.map +1 -1
- package/dist/pages/settings/sessions.d.ts.map +1 -1
- package/dist/pages/settings/usage/breakdown.d.ts.map +1 -1
- package/dist/pages/settings/usage/limits.d.ts.map +1 -1
- package/dist/pages/settings/usage/messages.d.ts +0 -2
- package/dist/pages/settings/usage/messages.d.ts.map +1 -1
- package/dist/pages/settings/usage/runs.d.ts +8 -2
- package/dist/pages/settings/usage/runs.d.ts.map +1 -1
- package/dist/pages/settings/usage/spend-chart.d.ts.map +1 -1
- package/dist/pages/settings/usage/spend-model.d.ts +5 -0
- package/dist/pages/settings/usage/spend-model.d.ts.map +1 -1
- package/dist/pages/values.d.ts +6 -0
- package/dist/pages/values.d.ts.map +1 -1
- package/dist/pages.d.ts +4 -0
- package/dist/pages.d.ts.map +1 -1
- package/dist/pages.js +8188 -4841
- package/dist/pages.js.map +56 -47
- package/dist/sections/catalog.d.ts.map +1 -1
- package/dist/sections/sections.d.ts.map +1 -1
- package/dist/server.js +294 -23
- package/dist/server.js.map +8 -7
- package/dist/service-worker.d.ts +39 -0
- package/dist/service-worker.d.ts.map +1 -0
- package/dist/shared-session.d.ts +25 -0
- package/dist/shared-session.d.ts.map +1 -0
- package/dist/shell/app-return.d.ts +35 -0
- package/dist/shell/app-return.d.ts.map +1 -0
- package/dist/shell/app-shell.d.ts +1 -1
- package/dist/shell/app-shell.d.ts.map +1 -1
- package/dist/shell/nav-items.d.ts +2 -0
- package/dist/shell/nav-items.d.ts.map +1 -1
- package/dist/shell/phone/back.d.ts +6 -0
- package/dist/shell/phone/back.d.ts.map +1 -0
- package/dist/shell/phone/launch.d.ts +7 -0
- package/dist/shell/phone/launch.d.ts.map +1 -0
- package/dist/shell/phone/more-sheet.d.ts +36 -0
- package/dist/shell/phone/more-sheet.d.ts.map +1 -0
- package/dist/shell/phone/phone-foundations.d.ts +9 -0
- package/dist/shell/phone/phone-foundations.d.ts.map +1 -0
- package/dist/shell/phone/pull-to-refresh.d.ts +9 -0
- package/dist/shell/phone/pull-to-refresh.d.ts.map +1 -0
- package/dist/shell/phone/routes.d.ts +12 -0
- package/dist/shell/phone/routes.d.ts.map +1 -0
- package/dist/shell/phone/screen-motion.d.ts +11 -0
- package/dist/shell/phone/screen-motion.d.ts.map +1 -0
- package/dist/shell/phone/scroll-restoration.d.ts +7 -0
- package/dist/shell/phone/scroll-restoration.d.ts.map +1 -0
- package/dist/shell/phone/startup-image.d.ts +17 -0
- package/dist/shell/phone/startup-image.d.ts.map +1 -0
- package/dist/shell/phone/tab-bar.d.ts +14 -0
- package/dist/shell/phone/tab-bar.d.ts.map +1 -0
- package/dist/shell/phone/top-bar.d.ts +24 -0
- package/dist/shell/phone/top-bar.d.ts.map +1 -0
- package/dist/shell/search-command.d.ts +3 -1
- package/dist/shell/search-command.d.ts.map +1 -1
- package/dist/shell/user-menu.d.ts +2 -0
- package/dist/shell/user-menu.d.ts.map +1 -1
- package/package.json +8 -5
- package/src/agent/activity-label.ts +6 -1
- package/src/agent/agent-chat.tsx +52 -8
- package/src/agent/agent-panel.tsx +12 -0
- package/src/agent/agent-surface.tsx +4 -0
- package/src/agent/artifact-card.tsx +84 -16
- package/src/agent/artifact-panel.tsx +63 -43
- package/src/agent/background/background-tool-row.tsx +24 -10
- package/src/agent/background/interpret.ts +60 -51
- package/src/agent/components/agent-message-body.tsx +1 -1
- package/src/agent/components/composer-place.tsx +77 -53
- package/src/agent/components/composer.tsx +92 -7
- package/src/agent/components/context-chips.tsx +72 -2
- package/src/agent/components/conversation-panel.tsx +30 -10
- package/src/agent/components/message-parts.tsx +29 -6
- package/src/agent/components/thread-artifacts-menu.tsx +22 -5
- package/src/agent/components/transcript.tsx +45 -27
- package/src/agent/composer-insertion.ts +36 -0
- package/src/agent/delegation/agent-exchange.tsx +53 -0
- package/src/agent/delegation/child-card.tsx +6 -40
- package/src/agent/delegation/child-parts.tsx +1 -84
- package/src/agent/delegation/child-work.tsx +19 -5
- package/src/agent/delegation/interpret.ts +33 -54
- package/src/agent/delegation/model.ts +1 -1
- package/src/agent/file-edits/file-edit-tool-view.tsx +126 -0
- package/src/agent/file-edits/interpret.ts +120 -0
- package/src/agent/hooks/use-agent-conversation.ts +61 -10
- package/src/agent/hooks/use-new-thread-place.ts +149 -25
- package/src/agent/i18n/en.ts +60 -4
- package/src/agent/i18n/fr.ts +51 -4
- package/src/agent/message-agent/interpret.ts +4 -3
- package/src/agent/publish-artifact/interpret.ts +37 -6
- package/src/agent/publish-artifact/open-artifact-tool-view.tsx +49 -0
- package/src/agent/publish-artifact/publish-artifact-tool-view.tsx +14 -8
- package/src/agent/publish-artifact/use-live-publishes.ts +7 -11
- package/src/agent/questions/interpret.ts +90 -0
- package/src/agent/questions/question-card.tsx +57 -0
- package/src/agent/questions/question-composer.tsx +257 -0
- package/src/agent/react-router.tsx +2 -2
- package/src/agent/read/interpret.ts +34 -1
- package/src/agent/read/read-tool-view.tsx +20 -4
- package/src/agent/tool-views/built-in.tsx +22 -8
- package/src/agent/types.ts +4 -0
- package/src/agent/waits.ts +50 -0
- package/src/artifacts/artifact-page.tsx +42 -17
- package/src/artifacts/artifact-viewer.tsx +56 -0
- package/src/artifacts/artifacts.css +116 -0
- package/src/artifacts/card-details.ts +2 -2
- package/src/artifacts/card-preview.tsx +17 -3
- package/src/artifacts/comments-context.ts +125 -0
- package/src/artifacts/edit-session.tsx +21 -7
- package/src/artifacts/file-source.ts +10 -3
- package/src/artifacts/frame.tsx +53 -14
- package/src/artifacts/gallery.tsx +9 -11
- package/src/artifacts/guest-badge.tsx +21 -0
- package/src/artifacts/held-artifact.tsx +241 -0
- package/src/artifacts/holders.tsx +170 -0
- package/src/artifacts/live/boards.ts +95 -0
- package/src/artifacts/live/canvas.ts +402 -0
- package/src/artifacts/live/header.tsx +137 -0
- package/src/artifacts/live/hooks.ts +94 -0
- package/src/artifacts/live/presence.ts +147 -0
- package/src/artifacts/live/session.ts +520 -0
- package/src/artifacts/live/view.ts +81 -0
- package/src/artifacts/messages.ts +469 -24
- package/src/artifacts/page-queries.ts +2 -3
- package/src/artifacts/page-state.ts +16 -7
- package/src/artifacts/publish-edit.ts +50 -22
- package/src/artifacts/queries.ts +108 -10
- package/src/artifacts/references/references.tsx +6 -9
- package/src/artifacts/renderers/canvas/arrows.tsx +12 -39
- package/src/artifacts/renderers/canvas/board-editor.tsx +839 -0
- package/src/artifacts/renderers/canvas/board-properties.tsx +488 -0
- package/src/artifacts/renderers/canvas/board-source.ts +110 -0
- package/src/artifacts/renderers/canvas/board.tsx +373 -35
- package/src/artifacts/renderers/canvas/canvas.tsx +441 -75
- package/src/artifacts/renderers/canvas/comment-pins.tsx +465 -0
- package/src/artifacts/renderers/canvas/commenting.tsx +319 -0
- package/src/artifacts/renderers/canvas/comments-panel.tsx +574 -0
- package/src/artifacts/renderers/canvas/comments.ts +225 -0
- package/src/artifacts/renderers/canvas/controls.tsx +64 -30
- package/src/artifacts/renderers/canvas/draft.ts +41 -50
- package/src/artifacts/renderers/canvas/edit-mode.tsx +145 -20
- package/src/artifacts/renderers/canvas/focus.tsx +321 -26
- package/src/artifacts/renderers/canvas/gestures.ts +265 -0
- package/src/artifacts/renderers/canvas/items.tsx +179 -52
- package/src/artifacts/renderers/canvas/layout.ts +99 -47
- package/src/artifacts/renderers/canvas/page-resize.tsx +542 -0
- package/src/artifacts/renderers/canvas/page-size-controls.tsx +193 -0
- package/src/artifacts/renderers/canvas/page-size.ts +218 -0
- package/src/artifacts/renderers/canvas/page-zoom.ts +280 -0
- package/src/artifacts/renderers/canvas/presence.tsx +184 -0
- package/src/artifacts/renderers/canvas/previews.ts +127 -0
- package/src/artifacts/renderers/canvas/renderer.tsx +87 -22
- package/src/artifacts/renderers/canvas/shown-size.ts +105 -0
- package/src/artifacts/renderers/canvas/thumbnail.tsx +56 -15
- package/src/artifacts/renderers/canvas/toolbar.tsx +1 -1
- package/src/artifacts/renderers/slides/slides.tsx +1 -1
- package/src/artifacts/version-menu.tsx +438 -0
- package/src/artifacts/view-context.ts +102 -0
- package/src/artifacts/viewer.tsx +219 -147
- package/src/build.ts +96 -11
- package/src/codegen.ts +83 -5
- package/src/createCustomApp.ts +20 -7
- package/src/index.ts +14 -0
- package/src/locale-messages.ts +24 -0
- package/src/metadata.ts +12 -0
- package/src/pages/console/action-run.tsx +20 -0
- package/src/pages/console/data/connectors.tsx +27 -3
- package/src/pages/console/data/datasets.tsx +30 -1
- package/src/pages/console/data/lake-health.tsx +299 -0
- package/src/pages/console/data/messages.ts +143 -2
- package/src/pages/console/data/pipelines.tsx +91 -3
- package/src/pages/console/data/projections.tsx +23 -4
- package/src/pages/console/data/syncs.tsx +39 -2
- package/src/pages/console/ontology/action-runs.tsx +8 -2
- package/src/pages/console/ontology/actions.tsx +39 -15
- package/src/pages/console/ontology/components/action-button.tsx +10 -0
- package/src/pages/console/ontology/components/artifact-picker.tsx +522 -0
- package/src/pages/console/ontology/components/object-query-bar.tsx +21 -5
- package/src/pages/console/ontology/lib/action-params.ts +10 -0
- package/src/pages/console/ontology/lineage/properties-panel.tsx +32 -24
- package/src/pages/console/ontology/object-page.tsx +2 -0
- package/src/pages/console/ontology/object-type.tsx +73 -14
- package/src/pages/console/ontology/object-types.tsx +56 -7
- package/src/pages/console/ontology/objects.tsx +167 -19
- package/src/pages/console/ontology/rules.tsx +186 -30
- package/src/pages/console/ontology/workflow.tsx +130 -74
- package/src/pages/console/ontology/workflows/run-input-form.tsx +21 -2
- package/src/pages/console/ontology/workflows/schema-shape.tsx +3 -0
- package/src/pages/console/ontology/workflows.tsx +34 -21
- package/src/pages/console/skeletons.tsx +99 -0
- package/src/pages/console/workflow-run.tsx +20 -0
- package/src/pages/section-page.tsx +37 -7
- package/src/pages/section-ui.tsx +96 -13
- package/src/pages/settings/activity/calendar.tsx +13 -6
- package/src/pages/settings/activity/connections.tsx +26 -9
- package/src/pages/settings/activity/page.tsx +31 -4
- package/src/pages/settings/activity/thread.tsx +32 -18
- package/src/pages/settings/activity/timeline.tsx +39 -0
- package/src/pages/settings/controls.tsx +19 -1
- package/src/pages/settings/developers.tsx +2 -2
- package/src/pages/settings/members.tsx +42 -9
- package/src/pages/settings/memory-history.tsx +76 -10
- package/src/pages/settings/memory.tsx +47 -5
- package/src/pages/settings/service-accounts.tsx +7 -2
- package/src/pages/settings/sessions.tsx +6 -2
- package/src/pages/settings/usage/breakdown.tsx +62 -2
- package/src/pages/settings/usage/limits.tsx +45 -3
- package/src/pages/settings/usage/messages.ts +0 -2
- package/src/pages/settings/usage/page.tsx +99 -52
- package/src/pages/settings/usage/runs.tsx +105 -8
- package/src/pages/settings/usage/spend-chart.tsx +79 -45
- package/src/pages/settings/usage/spend-model.ts +16 -0
- package/src/pages/values.tsx +72 -6
- package/src/pages.ts +4 -0
- package/src/sections/catalog.ts +6 -0
- package/src/sections/sections.tsx +2 -0
- package/src/service-worker.ts +176 -0
- package/src/shared-session.ts +73 -0
- package/src/shell/app-return.ts +115 -0
- package/src/shell/app-shell.tsx +125 -27
- package/src/shell/nav-items.tsx +2 -0
- package/src/shell/phone/back.ts +16 -0
- package/src/shell/phone/launch.ts +6 -0
- package/src/shell/phone/more-sheet.tsx +249 -0
- package/src/shell/phone/phone-foundations.tsx +43 -0
- package/src/shell/phone/phone.css +660 -0
- package/src/shell/phone/pull-to-refresh.tsx +201 -0
- package/src/shell/phone/routes.ts +34 -0
- package/src/shell/phone/screen-motion.ts +292 -0
- package/src/shell/phone/scroll-restoration.tsx +70 -0
- package/src/shell/phone/startup-image.ts +119 -0
- package/src/shell/phone/tab-bar.tsx +95 -0
- package/src/shell/phone/top-bar.tsx +195 -0
- package/src/shell/search-command.tsx +30 -14
- package/src/shell/user-menu.tsx +2 -1
- package/dist/chunk-4j3c3p72.js +0 -1487
- package/dist/chunk-4j3c3p72.js.map +0 -18
- package/dist/chunk-4mprsd2n.js.map +0 -10
- package/dist/chunk-ytadd0b5.js.map +0 -188
- /package/dist/{chunk-7fj9cfkw.js.map → chunk-970s5nkn.js.map} +0 -0
- /package/dist/{chunk-j8g956dt.js.map → chunk-pxd07kvx.js.map} +0 -0
- /package/dist/{chunk-kwbw4dyk.js.map → chunk-ryed2jq8.js.map} +0 -0
|
@@ -245,6 +245,8 @@ export function AgentSurface({
|
|
|
245
245
|
type="button"
|
|
246
246
|
size="icon"
|
|
247
247
|
className="fixed right-5 bottom-5 z-40 size-11 rounded-full shadow-lg max-sm:right-3 max-sm:bottom-3"
|
|
248
|
+
// A phone's shell hides it: it would sit on the tab bar, so the top bar opens the agent.
|
|
249
|
+
data-agent-launcher=""
|
|
248
250
|
aria-label={launcher}
|
|
249
251
|
title={launcher}
|
|
250
252
|
onClick={() => changeMode("dock")}
|
|
@@ -268,6 +270,8 @@ export function AgentSurface({
|
|
|
268
270
|
<aside
|
|
269
271
|
data-agent-surface={presentation}
|
|
270
272
|
data-agent-surface-resizing={resizing ? "" : undefined}
|
|
273
|
+
// On a phone the dock rests on the keyboard, rising into place as it opens (TouchViewport).
|
|
274
|
+
data-keyboard-overlay={presentation === "dock" ? "" : undefined}
|
|
271
275
|
aria-label={surfaceTitle}
|
|
272
276
|
aria-hidden={!visible}
|
|
273
277
|
inert={!visible}
|
|
@@ -1,4 +1,8 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import {
|
|
2
|
+
getArtifactOptions,
|
|
3
|
+
getArtifactRestorePointOptions,
|
|
4
|
+
listArtifactRestorePointsOptions,
|
|
5
|
+
} from "@sixb/client/hooks"
|
|
2
6
|
import { cn } from "@sixb/ui/lib/utils"
|
|
3
7
|
import { useQuery } from "@tanstack/react-query"
|
|
4
8
|
import { ChevronRight } from "lucide-react"
|
|
@@ -7,6 +11,7 @@ import { versionChanges } from "../artifacts/card-details"
|
|
|
7
11
|
import { ArtifactCardFace, ArtifactLabel } from "../artifacts/card-preview"
|
|
8
12
|
import { ArtifactKindIcon } from "../artifacts/kind-icon"
|
|
9
13
|
import { useArtifactMessages } from "../artifacts/messages"
|
|
14
|
+
import { useArtifactVersion } from "../artifacts/queries"
|
|
10
15
|
import { artifactHref } from "../pages/routes"
|
|
11
16
|
import { useArtifactPanel } from "./artifact-panel"
|
|
12
17
|
import { useAgentMessages } from "./i18n"
|
|
@@ -15,8 +20,15 @@ import type { PublishedArtifact, TurnArtifact } from "./publish-artifact/interpr
|
|
|
15
20
|
/**
|
|
16
21
|
* What one response published, on the answer's reading path: a card for each artifact it created,
|
|
17
22
|
* side by side, and a line for each one it revised, since its card is already in the conversation.
|
|
23
|
+
* `runId` is the response's run, whose restore points say what it changed.
|
|
18
24
|
*/
|
|
19
|
-
export function ArtifactCards({
|
|
25
|
+
export function ArtifactCards({
|
|
26
|
+
artifacts,
|
|
27
|
+
runId,
|
|
28
|
+
}: {
|
|
29
|
+
readonly artifacts: readonly TurnArtifact[]
|
|
30
|
+
readonly runId: string | null
|
|
31
|
+
}) {
|
|
20
32
|
const messages = useAgentMessages().artifacts
|
|
21
33
|
if (artifacts.length === 0) return null
|
|
22
34
|
const created = artifacts.filter((artifact) => artifact.created)
|
|
@@ -36,7 +48,7 @@ export function ArtifactCards({ artifacts }: { readonly artifacts: readonly Turn
|
|
|
36
48
|
<ul className="flex flex-col gap-2">
|
|
37
49
|
{revised.map((artifact) => (
|
|
38
50
|
<li key={artifact.artifactId} className="min-w-0">
|
|
39
|
-
<ArtifactRevision artifact={artifact} />
|
|
51
|
+
<ArtifactRevision artifact={artifact} runId={runId} />
|
|
40
52
|
</li>
|
|
41
53
|
))}
|
|
42
54
|
</ul>
|
|
@@ -68,15 +80,25 @@ function ArtifactCard({ artifact }: { readonly artifact: PublishedArtifact }) {
|
|
|
68
80
|
)
|
|
69
81
|
}
|
|
70
82
|
|
|
71
|
-
/**
|
|
72
|
-
|
|
83
|
+
/**
|
|
84
|
+
* An artifact this response revised, and what it changed: its structure before the response, as
|
|
85
|
+
* its restore point keeps it, against its structure after. A response from before restore points
|
|
86
|
+
* published a version, compared with the one before it.
|
|
87
|
+
*/
|
|
88
|
+
function ArtifactRevision({
|
|
89
|
+
artifact,
|
|
90
|
+
runId,
|
|
91
|
+
}: {
|
|
92
|
+
readonly artifact: PublishedArtifact
|
|
93
|
+
readonly runId: string | null
|
|
94
|
+
}) {
|
|
73
95
|
const artifactMessages = useArtifactMessages()
|
|
96
|
+
const messages = useAgentMessages().artifacts
|
|
74
97
|
const selected = useIsOpen(artifact)
|
|
75
|
-
const
|
|
76
|
-
const previous = useVersion(artifact.artifactId, artifact.version - 1)
|
|
98
|
+
const change = useTurnChange(artifact, runId)
|
|
77
99
|
const changes =
|
|
78
|
-
|
|
79
|
-
? versionChanges(
|
|
100
|
+
change.before && change.after
|
|
101
|
+
? versionChanges(change.before, change.after, artifactMessages)
|
|
80
102
|
: []
|
|
81
103
|
return (
|
|
82
104
|
<OpenArtifact
|
|
@@ -86,10 +108,15 @@ function ArtifactRevision({ artifact }: { readonly artifact: PublishedArtifact }
|
|
|
86
108
|
>
|
|
87
109
|
<ArtifactLabel
|
|
88
110
|
title={artifact.title}
|
|
89
|
-
detail={
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
111
|
+
detail={
|
|
112
|
+
artifact.open === undefined
|
|
113
|
+
? [artifactMessages.viewer.versionLabel(artifact.version), ...changes.slice(0, 2)].join(
|
|
114
|
+
" · "
|
|
115
|
+
)
|
|
116
|
+
: changes.length > 0
|
|
117
|
+
? changes.slice(0, 2).join(" · ")
|
|
118
|
+
: messages.changed
|
|
119
|
+
}
|
|
93
120
|
icon={
|
|
94
121
|
<span className="flex size-9 shrink-0 items-center justify-center rounded-lg bg-muted text-muted-foreground">
|
|
95
122
|
<ArtifactKindIcon kind={artifact.kind} className="size-4" />
|
|
@@ -161,11 +188,52 @@ function OpenArtifact({
|
|
|
161
188
|
)
|
|
162
189
|
}
|
|
163
190
|
|
|
164
|
-
/** A version of an artifact
|
|
191
|
+
/** A version of an artifact, read again while it is open and changes. */
|
|
165
192
|
function useVersion(artifactId: string, version: number) {
|
|
193
|
+
return useArtifactVersion(artifactId, version, { enabled: version >= 1 })
|
|
194
|
+
}
|
|
195
|
+
|
|
196
|
+
type Outlined = Parameters<typeof versionChanges>[0]
|
|
197
|
+
|
|
198
|
+
/**
|
|
199
|
+
* What a response changed in an artifact: `before`, the restore point taken before its first
|
|
200
|
+
* write, and `after`, the next one taken, before the turn that followed, else the version as it
|
|
201
|
+
* is now. A response from before restore points published a version: the one before it is
|
|
202
|
+
* `before`. Either is undefined until read, or when the restore point is gone, as the oldest are,
|
|
203
|
+
* or the reader may not list them.
|
|
204
|
+
*/
|
|
205
|
+
function useTurnChange(
|
|
206
|
+
artifact: PublishedArtifact,
|
|
207
|
+
runId: string | null
|
|
208
|
+
): { readonly before?: Outlined; readonly after?: Outlined } {
|
|
209
|
+
const { artifactId } = artifact
|
|
210
|
+
const legacy = artifact.open === undefined
|
|
211
|
+
|
|
212
|
+
const points = useQuery({
|
|
213
|
+
...listArtifactRestorePointsOptions({ path: { artifactId } }),
|
|
214
|
+
enabled: !legacy && runId !== null,
|
|
215
|
+
retry: false,
|
|
216
|
+
})
|
|
217
|
+
const list = points.data?.restorePoints ?? []
|
|
218
|
+
// Newest first: the one after the turn's is the one before it in the list.
|
|
219
|
+
const index = list.findIndex((point) => point.reason === "turn" && point.turnRunId === runId)
|
|
220
|
+
const turn = index >= 0 ? list[index] : undefined
|
|
221
|
+
const next = index > 0 ? list[index - 1] : undefined
|
|
222
|
+
|
|
223
|
+
const before = useRestorePoint(artifactId, turn?.revision)
|
|
224
|
+
const afterPoint = useRestorePoint(artifactId, next?.revision)
|
|
225
|
+
const current = useVersion(artifactId, legacy || turn ? artifact.version : 0)
|
|
226
|
+
const previous = useVersion(artifactId, legacy ? artifact.version - 1 : 0)
|
|
227
|
+
|
|
228
|
+
if (legacy) return { before: previous.data, after: current.data }
|
|
229
|
+
return { before: before.data, after: next ? afterPoint.data : current.data }
|
|
230
|
+
}
|
|
231
|
+
|
|
232
|
+
/** A restore point's content, which never changes; nothing when `revision` is undefined. */
|
|
233
|
+
function useRestorePoint(artifactId: string, revision: number | undefined) {
|
|
166
234
|
return useQuery({
|
|
167
|
-
...
|
|
168
|
-
enabled:
|
|
235
|
+
...getArtifactRestorePointOptions({ path: { artifactId, revision: String(revision ?? 0) } }),
|
|
236
|
+
enabled: revision !== undefined,
|
|
169
237
|
staleTime: Number.POSITIVE_INFINITY,
|
|
170
238
|
retry: false,
|
|
171
239
|
})
|
|
@@ -32,6 +32,7 @@ import {
|
|
|
32
32
|
type ViewerTarget,
|
|
33
33
|
viewerTargetKey,
|
|
34
34
|
} from "../artifacts/target"
|
|
35
|
+
import { type AgentDraft, AgentDraftContext } from "../artifacts/view-context"
|
|
35
36
|
import { Viewer } from "../artifacts/viewer"
|
|
36
37
|
import {
|
|
37
38
|
type ArtifactPanelPresentation,
|
|
@@ -102,6 +103,11 @@ export interface ArtifactPanelRootProps {
|
|
|
102
103
|
readonly onRouteTargetChange?: (target: ArtifactTarget | null) => void
|
|
103
104
|
/** Offer each artifact's own page, to open or to copy a link to. Off for an observer. */
|
|
104
105
|
readonly pageLinks?: boolean
|
|
106
|
+
/**
|
|
107
|
+
* Puts words in the conversation's input, as an artifact asks the Agent something: the panel
|
|
108
|
+
* closes when it covers the conversation, so the reader sees them there. None for an observer.
|
|
109
|
+
*/
|
|
110
|
+
readonly onAgentDraft?: (draft: AgentDraft) => void
|
|
105
111
|
}
|
|
106
112
|
|
|
107
113
|
/**
|
|
@@ -118,6 +124,7 @@ export function ArtifactPanelRoot({
|
|
|
118
124
|
routeTarget = null,
|
|
119
125
|
onRouteTargetChange,
|
|
120
126
|
pageLinks = true,
|
|
127
|
+
onAgentDraft,
|
|
121
128
|
}: ArtifactPanelRootProps) {
|
|
122
129
|
const messages = useAgentMessages().artifacts
|
|
123
130
|
const idPrefix = useId()
|
|
@@ -219,52 +226,65 @@ export function ArtifactPanelRoot({
|
|
|
219
226
|
/>
|
|
220
227
|
) : null
|
|
221
228
|
|
|
229
|
+
const agentDraft = useMemo(
|
|
230
|
+
() =>
|
|
231
|
+
onAgentDraft
|
|
232
|
+
? (draft: AgentDraft) => {
|
|
233
|
+
onAgentDraft(draft)
|
|
234
|
+
if (presentation !== "panel") close()
|
|
235
|
+
}
|
|
236
|
+
: null,
|
|
237
|
+
[onAgentDraft, presentation, close]
|
|
238
|
+
)
|
|
239
|
+
|
|
222
240
|
return (
|
|
223
241
|
<ArtifactPanelContext.Provider value={value}>
|
|
224
|
-
|
|
225
|
-
|
|
226
|
-
|
|
227
|
-
|
|
228
|
-
|
|
229
|
-
|
|
230
|
-
|
|
231
|
-
|
|
232
|
-
|
|
233
|
-
|
|
234
|
-
|
|
235
|
-
|
|
236
|
-
|
|
237
|
-
|
|
238
|
-
|
|
239
|
-
|
|
240
|
-
|
|
241
|
-
<DialogContent
|
|
242
|
-
showCloseButton={false}
|
|
243
|
-
onEscapeKeyDown={leaveEscapeToDeck}
|
|
244
|
-
className="flex h-[calc(100dvh-1rem)] max-h-none w-[calc(100vw-1rem)] max-w-none flex-col gap-0 overflow-hidden rounded-xl p-0 sm:h-[min(88vh,56rem)] sm:w-[min(92vw,72rem)] sm:max-w-[min(92vw,72rem)]"
|
|
242
|
+
<AgentDraftContext.Provider value={agentDraft}>
|
|
243
|
+
{/* A stable parent keeps composer drafts and scroll position across dock and page. */}
|
|
244
|
+
<ArtifactWorkspace
|
|
245
|
+
idPrefix={idPrefix}
|
|
246
|
+
revealKey={
|
|
247
|
+
presentation === "panel" && target ? `${panelTargetKey(target)}:${revealCount}` : null
|
|
248
|
+
}
|
|
249
|
+
viewer={presentation === "panel" ? viewer : null}
|
|
250
|
+
>
|
|
251
|
+
{/* An artifact a reply shows or links to opens here, beside the conversation. */}
|
|
252
|
+
<ArtifactReferencesProvider open={open}>{children}</ArtifactReferencesProvider>
|
|
253
|
+
</ArtifactWorkspace>
|
|
254
|
+
<Dialog
|
|
255
|
+
open={presentation === "dialog" && target !== null}
|
|
256
|
+
onOpenChange={(nextOpen) => {
|
|
257
|
+
if (!nextOpen) close()
|
|
258
|
+
}}
|
|
245
259
|
>
|
|
246
|
-
<
|
|
247
|
-
|
|
248
|
-
|
|
249
|
-
|
|
250
|
-
|
|
251
|
-
|
|
252
|
-
|
|
253
|
-
|
|
254
|
-
|
|
255
|
-
|
|
256
|
-
|
|
257
|
-
|
|
258
|
-
|
|
259
|
-
|
|
260
|
-
|
|
261
|
-
{messages.
|
|
262
|
-
|
|
263
|
-
|
|
264
|
-
|
|
265
|
-
|
|
266
|
-
|
|
267
|
-
|
|
260
|
+
<DialogContent
|
|
261
|
+
showCloseButton={false}
|
|
262
|
+
onEscapeKeyDown={leaveEscapeToDeck}
|
|
263
|
+
className="flex h-[calc(100dvh-1rem)] max-h-none w-[calc(100vw-1rem)] max-w-none flex-col gap-0 overflow-hidden rounded-xl p-0 sm:h-[min(88vh,56rem)] sm:w-[min(92vw,72rem)] sm:max-w-[min(92vw,72rem)]"
|
|
264
|
+
>
|
|
265
|
+
<DialogTitle className="sr-only">{messages.dialogTitle}</DialogTitle>
|
|
266
|
+
<DialogDescription className="sr-only">{messages.dialogDescription}</DialogDescription>
|
|
267
|
+
{presentation === "dialog" ? viewer : null}
|
|
268
|
+
</DialogContent>
|
|
269
|
+
</Dialog>
|
|
270
|
+
{presentation === "canvas" && overlayHost && viewer
|
|
271
|
+
? createPortal(
|
|
272
|
+
<section
|
|
273
|
+
role="dialog"
|
|
274
|
+
aria-modal="false"
|
|
275
|
+
aria-label={messages.dialogTitle}
|
|
276
|
+
aria-describedby={`${idPrefix}-canvas-description`}
|
|
277
|
+
className="pointer-events-auto flex h-full min-h-0 w-full min-w-0 flex-col overflow-hidden rounded-xl border border-border bg-background shadow-2xl motion-safe:animate-in motion-safe:fade-in motion-safe:slide-in-from-right-2 motion-safe:duration-200"
|
|
278
|
+
>
|
|
279
|
+
<p id={`${idPrefix}-canvas-description`} className="sr-only">
|
|
280
|
+
{messages.canvasDescription}
|
|
281
|
+
</p>
|
|
282
|
+
{viewer}
|
|
283
|
+
</section>,
|
|
284
|
+
overlayHost
|
|
285
|
+
)
|
|
286
|
+
: null}
|
|
287
|
+
</AgentDraftContext.Provider>
|
|
268
288
|
</ArtifactPanelContext.Provider>
|
|
269
289
|
)
|
|
270
290
|
}
|
|
@@ -3,6 +3,7 @@ import { ActivityStatusText } from "../components/activity-status"
|
|
|
3
3
|
import { useAgentMessages } from "../i18n"
|
|
4
4
|
import type { NormalizedTool } from "../parts"
|
|
5
5
|
import { toolResultValue } from "../parts"
|
|
6
|
+
import { namedIds } from "../waits"
|
|
6
7
|
import { useBackgroundCards } from "./context"
|
|
7
8
|
import { backgroundRowLabel } from "./interpret"
|
|
8
9
|
|
|
@@ -35,22 +36,35 @@ export function BackgroundToolRow({ tool }: { readonly tool: NormalizedTool }) {
|
|
|
35
36
|
)
|
|
36
37
|
}
|
|
37
38
|
|
|
38
|
-
/**
|
|
39
|
+
/**
|
|
40
|
+
* The commands a call names: its own input, what it returned, or the starts of those ids. `wait`
|
|
41
|
+
* names several by id and returns them in `commands`; the tools before it named one.
|
|
42
|
+
*/
|
|
39
43
|
function commandNamed(
|
|
40
44
|
tool: NormalizedTool,
|
|
41
45
|
commands: ReadonlyMap<string, { readonly id: string; readonly command: string }> | undefined
|
|
42
46
|
): string {
|
|
43
47
|
const input = isRecord(tool.input) ? tool.input : {}
|
|
48
|
+
if (typeof input.command === "string") return firstLine(input.command)
|
|
44
49
|
const output = toolResultValue(tool.output)
|
|
45
|
-
const
|
|
46
|
-
|
|
47
|
-
?
|
|
48
|
-
:
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
50
|
+
const returned = isRecord(output)
|
|
51
|
+
? Array.isArray(output.commands)
|
|
52
|
+
? output.commands.filter(isRecord)
|
|
53
|
+
: [output]
|
|
54
|
+
: []
|
|
55
|
+
const started = [...(commands?.values() ?? [])].reverse()
|
|
56
|
+
return namedIds(tool)
|
|
57
|
+
.map((id) => {
|
|
58
|
+
const named =
|
|
59
|
+
returned.find((command) => command.id === id)?.command ??
|
|
60
|
+
started.find((command) => command.id === id)?.command
|
|
61
|
+
return (typeof named === "string" && firstLine(named)) || id
|
|
62
|
+
})
|
|
63
|
+
.join(", ")
|
|
64
|
+
}
|
|
65
|
+
|
|
66
|
+
function firstLine(value: string): string {
|
|
67
|
+
return value.trim().split("\n")[0] ?? ""
|
|
54
68
|
}
|
|
55
69
|
|
|
56
70
|
function isRecord(value: unknown): value is Record<string, unknown> {
|
|
@@ -2,16 +2,17 @@ import type { AgentConversationMessage } from "../conversation"
|
|
|
2
2
|
import type { AgentMessages } from "../i18n/en"
|
|
3
3
|
import type { NormalizedTool } from "../parts"
|
|
4
4
|
import { toolResultValue } from "../parts"
|
|
5
|
+
import { COMMAND_TOOLS, isStop, namedIds } from "../waits"
|
|
5
6
|
|
|
6
|
-
// A command the agent runs in the background outlives the call that started it: later calls
|
|
7
|
-
// it (`
|
|
7
|
+
// A command the agent runs in the background outlives the call that started it: later calls wait
|
|
8
|
+
// for it (`wait`) or stop it (`stop`), maybe turns later, and on the owner's computer the
|
|
8
9
|
// open `sixb` reports how it stands between turns. The chat shows it as one card in the work's
|
|
9
10
|
// steps, in place of its start, merging all of these: only a reader who opens the steps sees it.
|
|
10
11
|
|
|
11
12
|
export type BackgroundCommandStatus = "running" | "exited" | "stopped"
|
|
12
13
|
|
|
13
|
-
/** The tools that start, read and stop a background command. */
|
|
14
|
-
export const BACKGROUND_TOOLS: ReadonlySet<string> = new Set(["bash",
|
|
14
|
+
/** The tools that start, read and stop a background command, earlier threads' included. */
|
|
15
|
+
export const BACKGROUND_TOOLS: ReadonlySet<string> = new Set(["bash", ...COMMAND_TOOLS])
|
|
15
16
|
|
|
16
17
|
/** How much of what the agent read of a command the card keeps: its newest characters. */
|
|
17
18
|
const OUTPUT_TAIL_CHARS = 8_000
|
|
@@ -169,50 +170,46 @@ export function readThreadBackground(
|
|
|
169
170
|
continue
|
|
170
171
|
}
|
|
171
172
|
|
|
172
|
-
// A read or a stop on its way names the
|
|
173
|
+
// A read or a stop on its way names the commands it is for.
|
|
173
174
|
if (tool.state === "input-streaming" || tool.state === "input-available") {
|
|
174
|
-
const
|
|
175
|
-
const
|
|
176
|
-
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
? "stopping"
|
|
180
|
-
: typeof input.wait === "number" && input.wait > 0
|
|
181
|
-
? "waiting"
|
|
182
|
-
: "reading"
|
|
183
|
-
merge(key, { pending })
|
|
175
|
+
const pending = isStop(tool) ? "stopping" : waits(tool) ? "waiting" : "reading"
|
|
176
|
+
for (const id of namedIds(tool)) {
|
|
177
|
+
const key = byId.get(id)
|
|
178
|
+
if (key) merge(key, { pending })
|
|
179
|
+
}
|
|
184
180
|
continue
|
|
185
181
|
}
|
|
186
182
|
if (tool.state !== "output-available") continue
|
|
187
183
|
|
|
188
|
-
const
|
|
189
|
-
|
|
190
|
-
|
|
191
|
-
|
|
192
|
-
|
|
193
|
-
|
|
194
|
-
|
|
195
|
-
|
|
196
|
-
|
|
197
|
-
|
|
184
|
+
for (const report of reportsOf(tool)) {
|
|
185
|
+
const read = commandState(report)
|
|
186
|
+
if (!read) continue
|
|
187
|
+
const key = backgroundKey(read)
|
|
188
|
+
const known = commands.get(key)
|
|
189
|
+
// Its start is beyond what the conversation shows: the read stands for it.
|
|
190
|
+
const current: CommandFromCalls = known ?? {
|
|
191
|
+
...read,
|
|
192
|
+
runId: message.runId,
|
|
193
|
+
output: "",
|
|
194
|
+
truncated: false,
|
|
195
|
+
}
|
|
196
|
+
byId.set(read.id, key)
|
|
197
|
+
|
|
198
|
+
const written = typeof outputOf(report)?.output === "string" ? outputOf(report)?.output : ""
|
|
199
|
+
const skipped = Number(outputOf(report)?.skippedBytes ?? 0) > 0
|
|
200
|
+
const joined = current.output + (written ?? "")
|
|
201
|
+
// An end is final: a later read never says it runs again.
|
|
202
|
+
const ended = current.status !== "running" ? current : read
|
|
203
|
+
const { pending: _pending, ...rest } = current
|
|
204
|
+
commands.set(key, {
|
|
205
|
+
...rest,
|
|
206
|
+
status: ended.status,
|
|
207
|
+
...(ended.exitCode === undefined ? {} : { exitCode: ended.exitCode }),
|
|
208
|
+
...(ended.endedAt === undefined ? {} : { endedAt: ended.endedAt }),
|
|
209
|
+
output: joined.slice(-OUTPUT_TAIL_CHARS),
|
|
210
|
+
truncated: current.truncated || skipped || joined.length > OUTPUT_TAIL_CHARS,
|
|
211
|
+
})
|
|
198
212
|
}
|
|
199
|
-
byId.set(read.id, key)
|
|
200
|
-
|
|
201
|
-
const written =
|
|
202
|
-
typeof outputOf(tool.output)?.output === "string" ? outputOf(tool.output)?.output : ""
|
|
203
|
-
const skipped = Number(outputOf(tool.output)?.skippedBytes ?? 0) > 0
|
|
204
|
-
const joined = current.output + (written ?? "")
|
|
205
|
-
// An end is final: a later read never says it runs again.
|
|
206
|
-
const ended = current.status !== "running" ? current : read
|
|
207
|
-
const { pending: _pending, ...rest } = current
|
|
208
|
-
commands.set(key, {
|
|
209
|
-
...rest,
|
|
210
|
-
status: ended.status,
|
|
211
|
-
...(ended.exitCode === undefined ? {} : { exitCode: ended.exitCode }),
|
|
212
|
-
...(ended.endedAt === undefined ? {} : { endedAt: ended.endedAt }),
|
|
213
|
-
output: joined.slice(-OUTPUT_TAIL_CHARS),
|
|
214
|
-
truncated: current.truncated || skipped || joined.length > OUTPUT_TAIL_CHARS,
|
|
215
|
-
})
|
|
216
213
|
}
|
|
217
214
|
}
|
|
218
215
|
|
|
@@ -297,15 +294,13 @@ export function backgroundCardState(input: {
|
|
|
297
294
|
/** What a background call reads as, in the work and as the live label of a turn at work. */
|
|
298
295
|
export function backgroundRowLabel(tool: NormalizedTool, messages: AgentMessages): string {
|
|
299
296
|
const rows = messages.background.rows
|
|
300
|
-
const
|
|
301
|
-
|
|
302
|
-
tool.toolName
|
|
303
|
-
?
|
|
304
|
-
|
|
305
|
-
|
|
306
|
-
|
|
307
|
-
: rows.read
|
|
308
|
-
: rows.start
|
|
297
|
+
const row = isStop(tool)
|
|
298
|
+
? rows.stop
|
|
299
|
+
: COMMAND_TOOLS.has(tool.toolName)
|
|
300
|
+
? waits(tool)
|
|
301
|
+
? rows.wait
|
|
302
|
+
: rows.read
|
|
303
|
+
: rows.start
|
|
309
304
|
return tool.state === "input-streaming" || tool.state === "input-available"
|
|
310
305
|
? row.running
|
|
311
306
|
: row.title
|
|
@@ -346,6 +341,20 @@ function commandState(output: unknown): {
|
|
|
346
341
|
}
|
|
347
342
|
}
|
|
348
343
|
|
|
344
|
+
/** Whether a call waits for its commands to end: `wait` unless told 0, `bash_output` when told. */
|
|
345
|
+
function waits(tool: NormalizedTool): boolean {
|
|
346
|
+
const input = isRecord(tool.input) ? tool.input : {}
|
|
347
|
+
if (tool.toolName === "wait") return input.timeoutMs !== 0
|
|
348
|
+
return typeof input.wait === "number" && input.wait > 0
|
|
349
|
+
}
|
|
350
|
+
|
|
351
|
+
/** What a call reports of each command: `wait` and `stop` list theirs, earlier tools one. */
|
|
352
|
+
function reportsOf(tool: NormalizedTool): readonly unknown[] {
|
|
353
|
+
if (tool.toolName !== "wait" && tool.toolName !== "stop") return [tool.output]
|
|
354
|
+
const value = toolResultValue(tool.output)
|
|
355
|
+
return isRecord(value) && Array.isArray(value.commands) ? value.commands : []
|
|
356
|
+
}
|
|
357
|
+
|
|
349
358
|
function outputOf(output: unknown): Record<string, unknown> | null {
|
|
350
359
|
const value = toolResultValue(output)
|
|
351
360
|
return isRecord(value) ? value : null
|
|
@@ -27,7 +27,7 @@ export function AgentMessageBody({ message }: AgentMessageBodyProps) {
|
|
|
27
27
|
return (
|
|
28
28
|
<>
|
|
29
29
|
{message.id === null ? <LivePublishes runId={message.runId} parts={parts} /> : null}
|
|
30
|
-
<AssistantBody parts={parts} live={message.status === "streaming"} />
|
|
30
|
+
<AssistantBody parts={parts} live={message.status === "streaming"} runId={message.runId} />
|
|
31
31
|
</>
|
|
32
32
|
)
|
|
33
33
|
}
|