@zaip-ai/cli 3.3.0 → 3.5.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/dist/services/adapters.d.ts +1 -1
- package/dist/services/adapters.d.ts.map +1 -1
- package/dist/services/adapters.js +4 -3
- package/dist/services/adapters.js.map +1 -1
- package/dist/services/agent-catalog-upgrade.d.ts +3 -0
- package/dist/services/agent-catalog-upgrade.d.ts.map +1 -0
- package/dist/services/agent-catalog-upgrade.js +35 -0
- package/dist/services/agent-catalog-upgrade.js.map +1 -0
- package/dist/services/install-agents-template.d.ts.map +1 -1
- package/dist/services/install-agents-template.js +22 -22
- package/dist/services/install-agents-template.js.map +1 -1
- package/dist/services/install-template-policy.d.ts +3 -0
- package/dist/services/install-template-policy.d.ts.map +1 -0
- package/dist/services/install-template-policy.js +21 -0
- package/dist/services/install-template-policy.js.map +1 -0
- package/dist/services/logger.test.js +12 -2
- package/dist/services/logger.test.js.map +1 -1
- package/dist/services/sqlite-bootstrap.d.ts +1 -0
- package/dist/services/sqlite-bootstrap.d.ts.map +1 -1
- package/dist/services/sqlite-bootstrap.js +10 -1
- package/dist/services/sqlite-bootstrap.js.map +1 -1
- package/package.json +2 -2
- package/templates/.agents/config/agents/discovery.json +1 -1
- package/templates/.agents/dashboard/.zaip-managed.json +286 -126
- package/templates/.agents/dashboard/apps/frontend/dist/assets/{CostCalculationGuidePage-BBFDrn64.js → CostCalculationGuidePage-C5NgEcVh.js} +1 -1
- package/templates/.agents/dashboard/apps/frontend/dist/assets/{DashboardHelpDialog-Cd-qo9w7.js → DashboardHelpDialog-CCMVnkkI.js} +1 -1
- package/templates/.agents/dashboard/apps/frontend/dist/assets/{PricingSettingsDialog-J7L5m8lk.js → PricingSettingsDialog-CGYcJ5EB.js} +1 -1
- package/templates/.agents/dashboard/apps/frontend/dist/assets/{ProjectSettingsPage-B9GWkEyN.css → ProjectSettingsPage-CQMhvzvJ.css} +1 -1
- package/templates/.agents/dashboard/apps/frontend/dist/assets/ProjectSettingsPage-D46WWIKr.js +3 -0
- package/templates/.agents/dashboard/apps/frontend/dist/assets/{TraceabilityWorkspace-BzVtGLWS.js → TraceabilityWorkspace-BKBpJyLh.js} +1 -1
- package/templates/.agents/dashboard/apps/frontend/dist/assets/{cost-monitor-PoJA2PI1.css → cost-monitor-BsMfGfQi.css} +1 -1
- package/templates/.agents/dashboard/apps/frontend/dist/assets/cost-monitor-j3aUYH5G.js +68 -0
- package/templates/.agents/dashboard/apps/frontend/dist/assets/{icons-vendor-CWzf_RiP.js → icons-vendor-x8xxL9yW.js} +1 -1
- package/templates/.agents/dashboard/apps/frontend/dist/assets/index-Bas2TVju.js +2 -0
- package/templates/.agents/dashboard/apps/frontend/dist/assets/index-CxrG_wRI.css +1 -0
- package/templates/.agents/dashboard/apps/frontend/dist/assets/{react-vendor-CtHdbZk3.js → react-vendor-CNOXIJHN.js} +1 -1
- package/templates/.agents/dashboard/apps/frontend/dist/assets/{traceability-BKrDH2TR.js → traceability-CcpbpT1s.js} +1 -1
- package/templates/.agents/dashboard/apps/frontend/dist/index.html +7 -7
- package/templates/.agents/dashboard/apps/frontend/package.json +1 -1
- package/templates/.agents/dashboard/apps/frontend/src/App.tsx +12 -1
- package/templates/.agents/dashboard/apps/frontend/src/ProjectSettingsCard.tsx +5 -0
- package/templates/.agents/dashboard/apps/frontend/src/ProjectSettingsField.tsx +21 -0
- package/templates/.agents/dashboard/apps/frontend/src/ProjectSettingsPage.dom.test.ts +12 -1
- package/templates/.agents/dashboard/apps/frontend/src/ProjectSettingsPage.tsx +16 -28
- package/templates/.agents/dashboard/apps/frontend/src/ProjectStackEditor.tsx +25 -4
- package/templates/.agents/dashboard/apps/frontend/src/WorkspaceStatus.test.tsx +51 -0
- package/templates/.agents/dashboard/apps/frontend/src/WorkspaceStatus.tsx +39 -0
- package/templates/.agents/dashboard/apps/frontend/src/app-work-board-options.ts +41 -0
- package/templates/.agents/dashboard/apps/frontend/src/dashboard-runtime-status.ts +25 -0
- package/templates/.agents/dashboard/apps/frontend/src/project-settings-copy.ts +13 -4
- package/templates/.agents/dashboard/apps/frontend/src/project-settings-model.ts +25 -1
- package/templates/.agents/dashboard/apps/frontend/src/project-settings-workspace.css +28 -0
- package/templates/.agents/dashboard/apps/frontend/src/project-settings.test.ts +39 -0
- package/templates/.agents/dashboard/apps/frontend/src/snapshot-coherence.test.ts +1 -1
- package/templates/.agents/dashboard/apps/frontend/src/use-app-cost-loaders.ts +5 -1
- package/templates/.agents/dashboard/apps/frontend/src/use-app-work-board.test.ts +140 -0
- package/templates/.agents/dashboard/apps/frontend/src/use-app-work-board.ts +28 -41
- package/templates/.agents/dashboard/apps/frontend/src/use-runtime-status.ts +38 -0
- package/templates/.agents/dashboard/apps/frontend/src/workspace-status.css +20 -0
- package/templates/.agents/dashboard/modules/cost-monitor/package.json +1 -1
- package/templates/.agents/dashboard/modules/cost-monitor/src/react/CompactLifecycleCostTable.test.ts +25 -3
- package/templates/.agents/dashboard/modules/cost-monitor/src/react/CompactLifecycleCostTable.tsx +17 -19
- package/templates/.agents/dashboard/modules/cost-monitor/src/react/CostFilters.tsx +13 -167
- package/templates/.agents/dashboard/modules/cost-monitor/src/react/CostGroupsTable.tsx +2 -9
- package/templates/.agents/dashboard/modules/cost-monitor/src/react/CostMonitorPage.test.ts +8 -8
- package/templates/.agents/dashboard/modules/cost-monitor/src/react/CostMonitorPage.tsx +29 -52
- package/templates/.agents/dashboard/modules/cost-monitor/src/react/CostTableLoading.test.ts +1 -1
- package/templates/.agents/dashboard/modules/cost-monitor/src/react/CostTables-keeps-legacy-codex-identity-fields-blank.test.ts +2 -2
- package/templates/.agents/dashboard/modules/cost-monitor/src/react/CostTables.test.ts +4 -27
- package/templates/.agents/dashboard/modules/cost-monitor/src/react/MacroCostTable.test.ts +2 -2
- package/templates/.agents/dashboard/modules/cost-monitor/src/react/MacroCostTable.tsx +4 -3
- package/templates/.agents/dashboard/modules/cost-monitor/src/react/agent-model-presentation.test.ts +26 -0
- package/templates/.agents/dashboard/modules/cost-monitor/src/react/cost-monitor-embedded.css +7 -0
- package/templates/.agents/dashboard/modules/cost-monitor/src/react/cost-monitor-loaders.ts +173 -0
- package/templates/.agents/dashboard/modules/cost-monitor/src/react/cost-monitor-page-props.ts +47 -0
- package/templates/.agents/dashboard/modules/cost-monitor/src/react/cost-monitor-page-selectors.ts +1 -7
- package/templates/.agents/dashboard/modules/cost-monitor/src/react/cost-page-range.ts +3 -9
- package/templates/.agents/dashboard/modules/cost-monitor/src/server/build-cost-monitor-projection.test.ts +44 -83
- package/templates/.agents/dashboard/modules/cost-monitor/src/server/build-cost-monitor-projection.ts +11 -111
- package/templates/.agents/dashboard/modules/cost-monitor/src/server/build-cost-summary-projection.test.ts +47 -181
- package/templates/.agents/dashboard/modules/cost-monitor/src/server/build-cost-summary-projection.ts +63 -91
- package/templates/.agents/dashboard/modules/cost-monitor/src/server/cost-monitor-unavailable.test.ts +55 -0
- package/templates/.agents/dashboard/modules/cost-monitor/src/server/cost-summary-duration.test.ts +189 -0
- package/templates/.agents/dashboard/modules/operations/package.json +1 -1
- package/templates/.agents/dashboard/modules/operations/src/react/OperationsEntityFilters.tsx +82 -0
- package/templates/.agents/dashboard/modules/operations/src/react/OperationsPage.tsx +22 -31
- package/templates/.agents/dashboard/modules/operations/src/react/PagedWorkList.test.tsx +13 -1
- package/templates/.agents/dashboard/modules/operations/src/react/PagedWorkList.tsx +16 -3
- package/templates/.agents/dashboard/modules/operations/src/react/export/ExcelExportAction.test.ts +11 -27
- package/templates/.agents/dashboard/modules/operations/src/react/export/ExcelExportAction.tsx +44 -193
- package/templates/.agents/dashboard/modules/operations/src/react/export/ExcelExportColumns.ts +186 -0
- package/templates/.agents/dashboard/modules/operations/src/react/export/excel-agent-participations.test.ts +28 -0
- package/templates/.agents/dashboard/modules/operations/src/react/export/export-layout.test.ts +2 -1
- package/templates/.agents/dashboard/modules/operations/src/react/operations-export-duration.ts +13 -0
- package/templates/.agents/dashboard/modules/operations/src/react/operations-filter-panel.css +4 -0
- package/templates/.agents/dashboard/modules/operations/src/react/use-operation-filter-feedback.ts +18 -0
- package/templates/.agents/dashboard/modules/operations/src/react/work-board-model.test.ts +11 -0
- package/templates/.agents/dashboard/modules/operations/src/react/work-board-model.ts +10 -2
- package/templates/.agents/dashboard/modules/operations/src/work-board-model.ts +1 -1
- package/templates/.agents/dashboard/modules/traceability/package.json +1 -1
- package/templates/.agents/dashboard/packages/branding/package.json +1 -1
- package/templates/.agents/dashboard/packages/contracts/package.json +1 -1
- package/templates/.agents/dashboard/packages/data-export/package.json +1 -1
- package/templates/.agents/dashboard/packages/local-runtime/dist/server.cjs +395 -341
- package/templates/.agents/dashboard/packages/local-runtime/dist/sqlite-read-model.cjs +346 -294
- package/templates/.agents/dashboard/packages/local-runtime/package.json +1 -1
- package/templates/.agents/dashboard/packages/local-runtime/scripts/rebuild-sqlite-read-model.mjs +2 -1
- package/templates/.agents/dashboard/packages/local-runtime/scripts/validate-sqlite-read-model.mjs +42 -8
- package/templates/.agents/dashboard/packages/local-runtime/server.mjs +395 -341
- package/templates/.agents/dashboard/packages/local-runtime/src/active-codex-telemetry.test.ts +95 -0
- package/templates/.agents/dashboard/packages/local-runtime/src/active-codex-telemetry.ts +102 -12
- package/templates/.agents/dashboard/packages/local-runtime/src/project-settings.test.ts +2 -3
- package/templates/.agents/dashboard/packages/local-runtime/src/project-settings.ts +1 -1
- package/templates/.agents/dashboard/packages/local-runtime/src/server-board.test.ts +75 -1
- package/templates/.agents/dashboard/packages/local-runtime/src/server-costs-routes.ts +10 -0
- package/templates/.agents/dashboard/packages/local-runtime/src/server-lifecycle-diagnostics.ts +50 -0
- package/templates/.agents/dashboard/packages/local-runtime/src/server-macro-population.test.ts +165 -0
- package/templates/.agents/dashboard/packages/local-runtime/src/server-operations-page-filters.ts +65 -0
- package/templates/.agents/dashboard/packages/local-runtime/src/server-operations-pages.test.ts +111 -0
- package/templates/.agents/dashboard/packages/local-runtime/src/server-operations-pages.ts +53 -63
- package/templates/.agents/dashboard/packages/local-runtime/src/server-operations-runs-route.ts +19 -5
- package/templates/.agents/dashboard/packages/local-runtime/src/server-period-macro-metric.ts +11 -2
- package/templates/.agents/dashboard/packages/local-runtime/src/server-read-projections.ts +16 -9
- package/templates/.agents/dashboard/packages/local-runtime/src/server-snapshot-refresh.test.ts +46 -2
- package/templates/.agents/dashboard/packages/local-runtime/src/server-snapshot-synchronization.test.ts +10 -2
- package/templates/.agents/dashboard/packages/local-runtime/src/server-snapshot-synchronization.ts +4 -3
- package/templates/.agents/dashboard/packages/local-runtime/src/server.test.ts +43 -1
- package/templates/.agents/dashboard/packages/local-runtime/src/server.ts +46 -11
- package/templates/.agents/dashboard/packages/local-runtime/src/sqlite-cost-filter-matrix.test.ts +188 -0
- package/templates/.agents/dashboard/packages/local-runtime/src/sqlite-cost-summary-details.test.ts +85 -0
- package/templates/.agents/dashboard/packages/local-runtime/src/sqlite-cost-summary-details.ts +147 -0
- package/templates/.agents/dashboard/packages/local-runtime/src/sqlite-first-fold-cache.ts +64 -54
- package/templates/.agents/dashboard/packages/local-runtime/src/sqlite-macro-classification.test.ts +172 -0
- package/templates/.agents/dashboard/packages/local-runtime/src/sqlite-materialize-projections.ts +1 -1
- package/templates/.agents/dashboard/packages/local-runtime/src/sqlite-operations-projection.ts +2 -1
- package/templates/.agents/dashboard/packages/local-runtime/src/sqlite-operations-work-list.test.ts +7 -7
- package/templates/.agents/dashboard/packages/local-runtime/src/sqlite-operations-work-list.ts +2 -1
- package/templates/.agents/dashboard/packages/local-runtime/src/sqlite-period-averages.ts +10 -1
- package/templates/.agents/dashboard/packages/local-runtime/src/sqlite-pricing-provenance.test.ts +39 -0
- package/templates/.agents/dashboard/packages/local-runtime/src/sqlite-query-agent-dimension.ts +18 -82
- package/templates/.agents/dashboard/packages/local-runtime/src/sqlite-query-cached-cost-page.ts +169 -0
- package/templates/.agents/dashboard/packages/local-runtime/src/sqlite-query-developer.ts +205 -0
- package/templates/.agents/dashboard/packages/local-runtime/src/sqlite-query-entity-group.ts +13 -4
- package/templates/.agents/dashboard/packages/local-runtime/src/sqlite-query-filtered-dimension.ts +22 -23
- package/templates/.agents/dashboard/packages/local-runtime/src/sqlite-query-financial.ts +42 -209
- package/templates/.agents/dashboard/packages/local-runtime/src/sqlite-query-model-dimension.ts +18 -4
- package/templates/.agents/dashboard/packages/local-runtime/src/sqlite-query-provider-dimension.ts +9 -2
- package/templates/.agents/dashboard/packages/local-runtime/src/sqlite-query-summary.ts +76 -83
- package/templates/.agents/dashboard/packages/local-runtime/src/sqlite-query-view-page.ts +25 -161
- package/templates/.agents/dashboard/packages/local-runtime/src/sqlite-read-model-canonical.ts +20 -47
- package/templates/.agents/dashboard/packages/local-runtime/src/sqlite-read-model-counts-every-root-execution-day-returns.test.ts +2 -2
- package/templates/.agents/dashboard/packages/local-runtime/src/sqlite-read-model-filesystem.ts +16 -16
- package/templates/.agents/dashboard/packages/local-runtime/src/sqlite-read-model-multi-provider.test.ts +1 -1
- package/templates/.agents/dashboard/packages/local-runtime/src/sqlite-read-model-rebuild.ts +47 -22
- package/templates/.agents/dashboard/packages/local-runtime/src/sqlite-read-model-schema.ts +3 -2
- package/templates/.agents/dashboard/packages/local-runtime/src/sqlite-read-model.test.ts +11 -0
- package/templates/.agents/dashboard/packages/local-runtime/src/sqlite-rebuild-result.ts +15 -0
- package/templates/.agents/dashboard/packages/local-runtime/src/sqlite-schema-base-views.ts +4 -4
- package/templates/.agents/dashboard/packages/local-runtime/src/sqlite-schema-dashboard-views.ts +15 -56
- package/templates/.agents/dashboard/packages/local-runtime/src/sqlite-schema-macro-classification.ts +48 -0
- package/templates/.agents/dashboard/packages/local-runtime/src/sqlite-summary-cursor.ts +15 -0
- package/templates/.agents/dashboard/packages/local-runtime/src/sqlite-token-active-allocation.ts +46 -0
- package/templates/.agents/dashboard/packages/local-runtime/src/sqlite-work-stages.ts +60 -0
- package/templates/.agents/dashboard/packages/local-runtime/start-dashboard-history.mjs +5 -1
- package/templates/.agents/dashboard/packages/local-runtime/start-dashboard-launch-claims.test.mjs +7 -1
- package/templates/.agents/dashboard/packages/local-runtime/start-dashboard-launch-page.mjs +17 -2
- package/templates/.agents/dashboard/packages/local-runtime/start-dashboard-ownership.mjs +65 -0
- package/templates/.agents/dashboard/packages/local-runtime/start-dashboard-ownership.test.mjs +72 -0
- package/templates/.agents/dashboard/packages/local-runtime/start-dashboard-processes.mjs +32 -9
- package/templates/.agents/dashboard/packages/local-runtime/start-dashboard.mjs +39 -45
- package/templates/.agents/dashboard/packages/local-runtime/start-dashboard.test.mjs +5 -2
- package/templates/.agents/dashboard/packages/ui/package.json +1 -1
- package/templates/.agents/dashboard/tests/e2e/package.json +1 -1
- package/templates/.agents/dashboard/tests/e2e/specs/dashboard-performance-matrix.spec.ts +1 -18
- package/templates/.agents/dashboard/tests/e2e/specs/export-row-identity.spec.ts +20 -0
- package/templates/.agents/dashboard/tests/e2e/specs/export-row-identity.ts +20 -0
- package/templates/.agents/design/.zaip-managed.json +105 -69
- package/templates/.agents/design/apps/catalog/dist/assets/index-0W0Gj_Gs.css +1 -0
- package/templates/.agents/design/apps/catalog/dist/assets/index-32GZO95T.js +72 -0
- package/templates/.agents/design/apps/catalog/dist/assets/{index-D_lfqoyx.js → index-BP8IxOxt.js} +3 -3
- package/templates/.agents/design/apps/catalog/dist/assets/index-D1JaPXfV.css +1 -0
- package/templates/.agents/design/apps/catalog/dist/assets/index-D2miO4-O.js +72 -0
- package/templates/.agents/design/apps/catalog/dist/assets/{index-BOjCcUaU.js → index-QJsgr9Ht.js} +3 -3
- package/templates/.agents/design/apps/catalog/dist/assets/{index-CqtYXZfV.js → index-mvD5mwcC.js} +3 -3
- package/templates/.agents/design/apps/catalog/dist/index.html +2 -2
- package/templates/.agents/design/apps/catalog/dist/storybook/assets/CatalogShell-BJ8b4xZr.js +1 -0
- package/templates/.agents/design/apps/catalog/dist/storybook/assets/{Color-6AOWCN3U-Cm-yJJz_.js → Color-6AOWCN3U-CQLHzznn.js} +1 -1
- package/templates/.agents/design/apps/catalog/dist/storybook/assets/Components.stories-kxWwSKin.js +146 -0
- package/templates/.agents/design/apps/catalog/dist/storybook/assets/DashboardFilters.stories-Chm_dXV7.js +9 -0
- package/templates/.agents/design/apps/catalog/dist/storybook/assets/DashboardFiltersSpecimen-9CaCbGIZ.js +1 -0
- package/templates/.agents/design/apps/catalog/dist/storybook/assets/DesignSystem.stories-ED52wFjY.js +1 -0
- package/templates/.agents/design/apps/catalog/dist/storybook/assets/{DocsRenderer-JROSPFPF-Belk4jRr.js → DocsRenderer-JROSPFPF-BcLgM80v.js} +4 -4
- package/templates/.agents/design/apps/catalog/dist/storybook/assets/Primitives-DV6Bpudf.js +1 -0
- package/templates/.agents/design/apps/catalog/dist/storybook/assets/{WithTooltip-7X4HQR7L-DoPvjkS1.js → WithTooltip-7X4HQR7L-BKNiAz_E.js} +1 -1
- package/templates/.agents/design/apps/catalog/dist/storybook/assets/WorkspaceStatus.stories-BL19HGOo.js +17 -0
- package/templates/.agents/design/apps/catalog/dist/storybook/assets/WorkspaceStatusSpecimen-DQnSS6s9.js +1 -0
- package/templates/.agents/design/apps/catalog/dist/storybook/assets/{chunk-DRQKCCAG-B1itKXEN.js → chunk-DRQKCCAG-DZBcXL-p.js} +1 -1
- package/templates/.agents/design/apps/catalog/dist/storybook/assets/{chunk-W22LQPXL-C-Eb5SPY.js → chunk-W22LQPXL-CF3y2mfo.js} +1 -1
- package/templates/.agents/design/apps/catalog/dist/storybook/assets/{components-DnyKLwhj.js → components-BVjxMRGq.js} +5 -5
- package/templates/.agents/design/apps/catalog/dist/storybook/assets/formatter-L2YTDE3Q-Do9sjqiW.js +1 -0
- package/templates/.agents/design/apps/catalog/dist/storybook/assets/iframe-0W0Gj_Gs.css +1 -0
- package/templates/.agents/design/apps/catalog/dist/storybook/assets/{iframe-DcXBsFPz.js → iframe-CTWGZcEe.js} +4 -4
- package/templates/.agents/design/apps/catalog/dist/storybook/assets/{react-18-CRM89QRf.js → react-18-B9_a4mHb.js} +1 -1
- package/templates/.agents/design/apps/catalog/dist/storybook/assets/react-NrUxok8K.js +1 -0
- package/templates/.agents/design/apps/catalog/dist/storybook/assets/{syntaxhighlighter-YFXUGROL-B03jQGTF.js → syntaxhighlighter-YFXUGROL-F_p8E2xc.js} +1 -1
- package/templates/.agents/design/apps/catalog/dist/storybook/assets/{theming-4ZyufAga.js → theming-fbSD9ZLF.js} +1 -1
- package/templates/.agents/design/apps/catalog/dist/storybook/iframe.html +2 -2
- package/templates/.agents/design/apps/catalog/dist/storybook/index.json +1 -1
- package/templates/.agents/design/apps/catalog/dist/storybook/sb-addons/a11y-2/manager-bundle.js +3 -3
- package/templates/.agents/design/apps/catalog/dist/storybook/sb-addons/storybook-core-server-presets-0/common-manager-bundle.js +3 -3
- package/templates/.agents/design/apps/catalog/package.json +1 -1
- package/templates/.agents/design/apps/catalog/src/components/DashboardFiltersSpecimen.tsx +61 -0
- package/templates/.agents/design/apps/catalog/src/components/Primitives.tsx +24 -0
- package/templates/.agents/design/apps/catalog/src/components/StackVersionFieldSpecimen.tsx +70 -0
- package/templates/.agents/design/apps/catalog/src/components/WorkspaceStatusSpecimen.tsx +42 -0
- package/templates/.agents/design/apps/catalog/src/design-contract.test.ts +27 -13
- package/templates/.agents/design/apps/catalog/src/pages/ComponentsPage.tsx +52 -0
- package/templates/.agents/design/apps/catalog/src/pages/DesignSystemPage.tsx +15 -1
- package/templates/.agents/design/apps/catalog/src/stories/Components.stories.tsx +32 -0
- package/templates/.agents/design/apps/catalog/src/stories/DashboardFilters.stories.tsx +7 -0
- package/templates/.agents/design/apps/catalog/src/stories/WorkspaceStatus.stories.tsx +12 -0
- package/templates/.agents/design/apps/catalog/src/styles/components.css +84 -3
- package/templates/.agents/design/apps/catalog/src/styles/stack-version-field.css +17 -0
- package/templates/.agents/design/apps/catalog/src/styles.css +2 -0
- package/templates/.agents/design/packages/local-runtime/package.json +1 -1
- package/templates/.agents/design/tokens.json +32 -0
- package/templates/.agents/requirements/autonomous-assurance.md +1 -1
- package/templates/.agents/requirements/cloud-hostinger-autonomy.md +1 -1
- package/templates/.agents/requirements/comparative-audit.md +1 -1
- package/templates/.agents/requirements/context-engine.md +1 -1
- package/templates/.agents/requirements/cost-observability.md +1 -1
- package/templates/.agents/requirements/dashboard-launch.md +1 -1
- package/templates/.agents/requirements/data-export.md +1 -1
- package/templates/.agents/requirements/design-system.md +1 -1
- package/templates/.agents/requirements/execution-engine.md +1 -1
- package/templates/.agents/requirements/kanban-dashboard.md +1 -1
- package/templates/.agents/requirements/model-orchestration.md +1 -1
- package/templates/.agents/requirements/public-distribution.md +9 -3
- package/templates/.agents/requirements/software-architecture.md +1 -1
- package/templates/.agents/requirements/strategic-improvements.md +1 -1
- package/templates/.agents/requirements/work-lifecycle.md +1 -1
- package/templates/.agents/requirements/zaip-strategic-95.md +1 -1
- package/templates/.agents/rules/autonomy-decision.md +1 -0
- package/templates/.agents/rules/workflow.md +2 -2
- package/templates/.agents/runtime/VERSION +1 -1
- package/templates/.agents/runtime/bin/zaip.mjs +27 -26
- package/templates/.agents/runtime/checksums.sha256 +5 -5
- package/templates/.agents/runtime/manifest.json +1 -1
- package/templates/.agents/runtime/provenance.json +4 -4
- package/templates/.agents/runtime/sbom.cdx.json +1 -1
- package/templates/.agents/skills/zaip-skill-execution/SKILL.md +13 -0
- package/templates/.agents/skills/zaip-skill-execution/references/autonomous-continuation.md +17 -0
- package/templates/.agents/skills/zaip-skill-execution/references/correction-cycle.md +2 -2
- package/templates/.agents/skills/zaip-skill-github-deploy/SKILL.md +9 -6
- package/templates/.agents/skills/zaip-skill-github-deploy/agents/openai.yaml +1 -1
- package/templates/.agents/skills/zaip-skill-github-deploy/references/deployment-workflow.md +11 -9
- package/templates/.agents/skills/zaip-skill-github-deploy/references/release-identity.md +2 -2
- package/templates/.agents/skills/zaip-skill-github-deploy/scripts/consumer-release-preparation.mjs +1 -2
- package/templates/.agents/skills/zaip-skill-github-deploy/scripts/consumer-release-preparation.test.mjs +9 -1
- package/templates/.agents/skills/zaip-skill-github-deploy/scripts/github-deploy-contract.test.mjs +23 -0
- package/templates/.agents/skills/zaip-skill-github-deploy/scripts/preflight.mjs +2 -6
- package/templates/.agents/skills/zaip-skill-github-deploy/scripts/preflight.test.mjs +15 -1
- package/templates/.agents/skills/zaip-skill-move-prd/SKILL.md +4 -0
- package/templates/.agents/skills/zaip-skill-move-spec/SKILL.md +4 -0
- package/templates/.agents/skills/zaip-skill-prd/SKILL.md +3 -3
- package/templates/.agents/skills/zaip-skill-release-qualification/SKILL.md +11 -8
- package/templates/.agents/skills/zaip-skill-release-qualification/references/local-preparation.md +13 -12
- package/templates/.agents/skills/zaip-skill-setup/SKILL.md +17 -2
- package/templates/.agents/skills/zaip-skill-setup/agents/openai.yaml +1 -1
- package/templates/.agents/skills/zaip-skill-spec/SKILL.md +2 -2
- package/templates/.agents/zaip-aios/VERSION +1 -1
- package/templates/template-manifest.json +445 -245
- package/templates/.agents/dashboard/apps/frontend/dist/assets/ProjectSettingsPage-BpsAFy0g.js +0 -3
- package/templates/.agents/dashboard/apps/frontend/dist/assets/cost-monitor--iPcnZdx.js +0 -68
- package/templates/.agents/dashboard/apps/frontend/dist/assets/index-Cmlx8OYH.css +0 -1
- package/templates/.agents/dashboard/apps/frontend/dist/assets/index-DfdlGa7c.js +0 -2
- package/templates/.agents/design/apps/catalog/dist/assets/index-BEmIE7WE.css +0 -1
- package/templates/.agents/design/apps/catalog/dist/assets/index-BJV597iq.js +0 -72
- package/templates/.agents/design/apps/catalog/dist/assets/index-B_WhrCZe.js +0 -72
- package/templates/.agents/design/apps/catalog/dist/assets/index-CqqYWY2f.js +0 -9
- package/templates/.agents/design/apps/catalog/dist/assets/index-D9pj7Jlf.js +0 -9
- package/templates/.agents/design/apps/catalog/dist/assets/index-i_PO2k9R.js +0 -9
- package/templates/.agents/design/apps/catalog/dist/storybook/assets/CatalogShell-Cstn1UwA.js +0 -1
- package/templates/.agents/design/apps/catalog/dist/storybook/assets/Components.stories-D1WopB2L.js +0 -137
- package/templates/.agents/design/apps/catalog/dist/storybook/assets/DesignSystem.stories-DQ9PJ3N3.js +0 -1
- package/templates/.agents/design/apps/catalog/dist/storybook/assets/formatter-L2YTDE3Q-D0OSgxWz.js +0 -1
- package/templates/.agents/design/apps/catalog/dist/storybook/assets/iframe-BEmIE7WE.css +0 -1
- package/templates/.agents/design/apps/catalog/dist/storybook/assets/react-C3tkVMIp.js +0 -1
|
@@ -1,9 +1,21 @@
|
|
|
1
1
|
import { createElement } from "react";
|
|
2
2
|
import { renderToStaticMarkup } from "react-dom/server";
|
|
3
3
|
import { describe, expect, it } from "vitest";
|
|
4
|
-
import { PagedWorkList } from "./PagedWorkList.js";
|
|
4
|
+
import { PagedWorkList, pagedWorkStatusLabel } from "./PagedWorkList.js";
|
|
5
5
|
|
|
6
6
|
describe("PagedWorkList", () => {
|
|
7
|
+
it("displays the reconciled macro stage while preserving draft Task semantics", () => {
|
|
8
|
+
expect(pagedWorkStatusLabel({ status: "active", stage: "verifying" }, "pt-BR")).toBe(
|
|
9
|
+
"Verificação",
|
|
10
|
+
);
|
|
11
|
+
expect(pagedWorkStatusLabel({ status: "draft", stage: "planning" }, "pt-BR")).toBe(
|
|
12
|
+
"Planejamento (SPEC + Change)",
|
|
13
|
+
);
|
|
14
|
+
expect(pagedWorkStatusLabel({ status: "draft", stage: null }, "pt-BR")).toBe("Rascunho");
|
|
15
|
+
expect(pagedWorkStatusLabel({ status: "delivered", stage: "completed" }, "en-US")).toBe(
|
|
16
|
+
"Completed",
|
|
17
|
+
);
|
|
18
|
+
});
|
|
7
19
|
it("renders the factual developer column without object coercion", () => {
|
|
8
20
|
const markup = renderToStaticMarkup(
|
|
9
21
|
createElement(PagedWorkList, {
|
|
@@ -3,7 +3,12 @@ import { formatDeveloperIdentities } from "./developer-identities.js";
|
|
|
3
3
|
import { formatRoundedDuration } from "./format-rounded-duration.js";
|
|
4
4
|
import type { OperationsLocale } from "./status-labels.js";
|
|
5
5
|
import { WorkTypeFilters } from "./UnifiedWorkBoard.js";
|
|
6
|
-
import
|
|
6
|
+
import {
|
|
7
|
+
workStageLabel,
|
|
8
|
+
workStages,
|
|
9
|
+
type WorkStage,
|
|
10
|
+
type WorkTypeFilter,
|
|
11
|
+
} from "./work-board-model.js";
|
|
7
12
|
|
|
8
13
|
export type PagedWorkListRow = Record<string, unknown>;
|
|
9
14
|
export type PagedWorkListPage = {
|
|
@@ -25,6 +30,14 @@ function number(value: unknown): number | null {
|
|
|
25
30
|
return typeof value === "number" && Number.isFinite(value) ? value : null;
|
|
26
31
|
}
|
|
27
32
|
|
|
33
|
+
export function pagedWorkStatusLabel(row: PagedWorkListRow, locale: OperationsLocale): string {
|
|
34
|
+
const stage = row.stage ?? row.status;
|
|
35
|
+
if (stage === "draft") return locale === "pt-BR" ? "Rascunho" : "Draft";
|
|
36
|
+
return workStages.includes(stage as WorkStage)
|
|
37
|
+
? workStageLabel(stage as WorkStage, locale)
|
|
38
|
+
: text(stage);
|
|
39
|
+
}
|
|
40
|
+
|
|
28
41
|
function workKindLabel(value: unknown, locale: OperationsLocale) {
|
|
29
42
|
const kind = text(value, "");
|
|
30
43
|
const labels =
|
|
@@ -77,8 +90,8 @@ export function PagedWorkList({
|
|
|
77
90
|
{
|
|
78
91
|
key: "status",
|
|
79
92
|
label: "Status",
|
|
80
|
-
render: (row) =>
|
|
81
|
-
sortValue: (row) =>
|
|
93
|
+
render: (row) => pagedWorkStatusLabel(row, locale),
|
|
94
|
+
sortValue: (row) => pagedWorkStatusLabel(row, locale),
|
|
82
95
|
},
|
|
83
96
|
{
|
|
84
97
|
key: "type",
|
package/templates/.agents/dashboard/modules/operations/src/react/export/ExcelExportAction.test.ts
CHANGED
|
@@ -9,7 +9,6 @@ import {
|
|
|
9
9
|
EXPORT_SUCCESS_TOAST_MS,
|
|
10
10
|
exportAgentInvocationRows,
|
|
11
11
|
exportCompactLifecycleRows,
|
|
12
|
-
exportCostAgentRows,
|
|
13
12
|
exportCostGroupRows,
|
|
14
13
|
exportDeveloperRows,
|
|
15
14
|
exportExecutionRows,
|
|
@@ -466,6 +465,17 @@ it("exports compact Task, SPEC, PRD, and Conversation rows with entity columns",
|
|
|
466
465
|
]);
|
|
467
466
|
});
|
|
468
467
|
|
|
468
|
+
it("preserves unavailable compact timing and cost while exporting known tokens and real zero", () => {
|
|
469
|
+
const missing = { known_sum: 0, unknown: 1, complete: false, coverage_ratio: 0 };
|
|
470
|
+
const zero = { known_sum: 0, unknown: 0, complete: true, coverage_ratio: 1 };
|
|
471
|
+
const rows = exportCompactLifecycleRows([
|
|
472
|
+
{ metrics: { duration: missing, cost: missing, total_tokens: { ...zero, known_sum: 15 } } },
|
|
473
|
+
{ metrics: { duration: zero, cost: zero, total_tokens: zero } },
|
|
474
|
+
]);
|
|
475
|
+
expect(rows[0]).toMatchObject({ duration_hours: null, cost_brl: null, tokens: 15 });
|
|
476
|
+
expect(rows[1]).toMatchObject({ duration_hours: 0, cost_brl: 0, tokens: 0 });
|
|
477
|
+
});
|
|
478
|
+
|
|
469
479
|
it("keeps cost-executions headers and exported row keys in the compact lifecycle schema", () => {
|
|
470
480
|
const source = {
|
|
471
481
|
id: "RUN-42",
|
|
@@ -579,29 +589,3 @@ it("exports model analysis in table order with explicit numeric zeroes", () => {
|
|
|
579
589
|
it("clears pending success when a new export starts", () => {
|
|
580
590
|
expect("running").not.toBe("completed");
|
|
581
591
|
});
|
|
582
|
-
|
|
583
|
-
it("exports Agent tasks as participations and fills every missing numeric cell with zero", () => {
|
|
584
|
-
expect(COST_AGENT_EXPORT_COLUMNS).toEqual([
|
|
585
|
-
"Persona",
|
|
586
|
-
"Cargo",
|
|
587
|
-
"Zaip Agentes",
|
|
588
|
-
"PRDs",
|
|
589
|
-
"SPECs",
|
|
590
|
-
"Tarefas",
|
|
591
|
-
"Runs",
|
|
592
|
-
"Testes",
|
|
593
|
-
"Evidências",
|
|
594
|
-
"Tempo",
|
|
595
|
-
"Tokens",
|
|
596
|
-
"Custos",
|
|
597
|
-
]);
|
|
598
|
-
const rows = exportCostAgentRows([
|
|
599
|
-
{ key: "dave", task_count: 2 },
|
|
600
|
-
{ key: "leo", task_count: 2 },
|
|
601
|
-
{},
|
|
602
|
-
]);
|
|
603
|
-
expect(rows[0]?.Tarefas).toBe(2);
|
|
604
|
-
expect(rows[1]?.Tarefas).toBe(2);
|
|
605
|
-
for (const key of COST_AGENT_EXPORT_COLUMNS.slice(3)) expect(rows[2]?.[key]).toBe(0);
|
|
606
|
-
expect(rows[0]).not.toHaveProperty("tasks_created");
|
|
607
|
-
});
|
package/templates/.agents/dashboard/modules/operations/src/react/export/ExcelExportAction.tsx
CHANGED
|
@@ -5,6 +5,38 @@ import { formatDeveloperIdentities } from "../developer-identities.js";
|
|
|
5
5
|
import { ExportProgressToast, ExportSuccessToast } from "./ExportProgressToast.js";
|
|
6
6
|
import { ExportController, type ExportState } from "./export-session.js";
|
|
7
7
|
|
|
8
|
+
export {
|
|
9
|
+
AGENT_INVOCATION_EXPORT_COLUMNS,
|
|
10
|
+
CHANGE_EXPORT_COLUMNS,
|
|
11
|
+
COMPACT_LIFECYCLE_EXPORT_COLUMNS,
|
|
12
|
+
CONVERSATION_EXPORT_COLUMNS,
|
|
13
|
+
COST_AGENT_EXPORT_COLUMNS,
|
|
14
|
+
COST_GROUP_EXPORT_COLUMNS,
|
|
15
|
+
DECISION_EXPORT_COLUMNS,
|
|
16
|
+
DEVELOPER_EXPORT_COLUMNS,
|
|
17
|
+
EXECUTION_EXPORT_COLUMNS,
|
|
18
|
+
KANBAN_EXPORT_COLUMNS,
|
|
19
|
+
MODEL_COST_GROUP_EXPORT_COLUMNS,
|
|
20
|
+
PERIOD_EXPORT_COLUMNS,
|
|
21
|
+
WORK_EXPORT_COLUMNS,
|
|
22
|
+
} from "./ExcelExportColumns.js";
|
|
23
|
+
|
|
24
|
+
import {
|
|
25
|
+
AGENT_INVOCATION_EXPORT_COLUMNS,
|
|
26
|
+
CHANGE_EXPORT_COLUMNS,
|
|
27
|
+
COMPACT_LIFECYCLE_EXPORT_COLUMNS,
|
|
28
|
+
CONVERSATION_EXPORT_COLUMNS,
|
|
29
|
+
COST_AGENT_EXPORT_COLUMNS,
|
|
30
|
+
COST_GROUP_EXPORT_COLUMNS,
|
|
31
|
+
DECISION_EXPORT_COLUMNS,
|
|
32
|
+
DEVELOPER_EXPORT_COLUMNS,
|
|
33
|
+
EXECUTION_EXPORT_COLUMNS,
|
|
34
|
+
KANBAN_EXPORT_COLUMNS,
|
|
35
|
+
MODEL_COST_GROUP_EXPORT_COLUMNS,
|
|
36
|
+
PERIOD_EXPORT_COLUMNS,
|
|
37
|
+
WORK_EXPORT_COLUMNS,
|
|
38
|
+
} from "./ExcelExportColumns.js";
|
|
39
|
+
|
|
8
40
|
export type ExcelExportInput = {
|
|
9
41
|
view: string;
|
|
10
42
|
filters: Readonly<Record<string, unknown>>;
|
|
@@ -22,193 +54,6 @@ export type PreparedExportPageSource = {
|
|
|
22
54
|
};
|
|
23
55
|
export const EXPORT_SUCCESS_TOAST_MS = 4_000;
|
|
24
56
|
|
|
25
|
-
export const PERIOD_EXPORT_COLUMNS = [
|
|
26
|
-
"key",
|
|
27
|
-
"prds",
|
|
28
|
-
"specs",
|
|
29
|
-
"tasks",
|
|
30
|
-
"conversations",
|
|
31
|
-
"runs",
|
|
32
|
-
"tests",
|
|
33
|
-
"evidences",
|
|
34
|
-
"tokens",
|
|
35
|
-
"cost",
|
|
36
|
-
"duration_hours",
|
|
37
|
-
] as const;
|
|
38
|
-
|
|
39
|
-
// Work views contain PRDs, SPECs, and Tasks. Export the common, user-facing
|
|
40
|
-
// fields instead of the union of their internal lifecycle projections. The
|
|
41
|
-
// latter produces columns that are empty for an entire view (or nearly every
|
|
42
|
-
// row), which makes the workbook much harder to use.
|
|
43
|
-
export const WORK_EXPORT_COLUMNS = [
|
|
44
|
-
"type",
|
|
45
|
-
"id",
|
|
46
|
-
"title",
|
|
47
|
-
"status",
|
|
48
|
-
"risk",
|
|
49
|
-
"developers",
|
|
50
|
-
"occurred_at",
|
|
51
|
-
"duration_hours",
|
|
52
|
-
"tokens",
|
|
53
|
-
"cost_brl",
|
|
54
|
-
] as const;
|
|
55
|
-
|
|
56
|
-
// Execution rows are entities, not period summaries. Keep their schema
|
|
57
|
-
// aligned with the Execution table so the workbook never inherits the empty
|
|
58
|
-
// PRD/SPEC/period columns shown by a different tab.
|
|
59
|
-
export const EXECUTION_EXPORT_COLUMNS = [
|
|
60
|
-
"id",
|
|
61
|
-
"kind",
|
|
62
|
-
"status",
|
|
63
|
-
"origin",
|
|
64
|
-
"task_id",
|
|
65
|
-
"conversation_id",
|
|
66
|
-
"created_at",
|
|
67
|
-
"finished_at",
|
|
68
|
-
"duration_hours",
|
|
69
|
-
"tokens",
|
|
70
|
-
"cost_brl",
|
|
71
|
-
"invocations",
|
|
72
|
-
] as const;
|
|
73
|
-
|
|
74
|
-
export const AGENT_INVOCATION_EXPORT_COLUMNS = [
|
|
75
|
-
"run_id",
|
|
76
|
-
"execution_id",
|
|
77
|
-
"conversation_id",
|
|
78
|
-
"task_id",
|
|
79
|
-
"origin",
|
|
80
|
-
"run_role",
|
|
81
|
-
"run_purpose",
|
|
82
|
-
"phase",
|
|
83
|
-
"status",
|
|
84
|
-
"agent",
|
|
85
|
-
"provider",
|
|
86
|
-
"model",
|
|
87
|
-
"reasoning_effort",
|
|
88
|
-
"started_at",
|
|
89
|
-
"finished_at",
|
|
90
|
-
"duration_hours",
|
|
91
|
-
"input_tokens",
|
|
92
|
-
"cached_input_tokens",
|
|
93
|
-
"output_tokens",
|
|
94
|
-
"reasoning_tokens",
|
|
95
|
-
"total_tokens",
|
|
96
|
-
"estimated_usd",
|
|
97
|
-
"estimated_brl",
|
|
98
|
-
] as const;
|
|
99
|
-
|
|
100
|
-
export const COMPACT_LIFECYCLE_EXPORT_COLUMNS = [
|
|
101
|
-
"id",
|
|
102
|
-
"title",
|
|
103
|
-
"status",
|
|
104
|
-
"occurred_at",
|
|
105
|
-
"invocations",
|
|
106
|
-
"duration_hours",
|
|
107
|
-
"tokens",
|
|
108
|
-
"cost_brl",
|
|
109
|
-
] as const;
|
|
110
|
-
|
|
111
|
-
export const COST_GROUP_EXPORT_COLUMNS = [
|
|
112
|
-
"key",
|
|
113
|
-
"label",
|
|
114
|
-
"invocations",
|
|
115
|
-
"tasks",
|
|
116
|
-
"tokens",
|
|
117
|
-
"cost_usd",
|
|
118
|
-
"cost_brl",
|
|
119
|
-
"duration_hours",
|
|
120
|
-
] as const;
|
|
121
|
-
|
|
122
|
-
/** Agent exports count Task participation, including repeated Tasks across agents. */
|
|
123
|
-
export const COST_AGENT_EXPORT_COLUMNS = [
|
|
124
|
-
"Persona",
|
|
125
|
-
"Cargo",
|
|
126
|
-
"Zaip Agentes",
|
|
127
|
-
"PRDs",
|
|
128
|
-
"SPECs",
|
|
129
|
-
"Tarefas",
|
|
130
|
-
"Runs",
|
|
131
|
-
"Testes",
|
|
132
|
-
"Evidências",
|
|
133
|
-
"Tempo",
|
|
134
|
-
"Tokens",
|
|
135
|
-
"Custos",
|
|
136
|
-
] as const;
|
|
137
|
-
|
|
138
|
-
/** The model audit mirrors its table: entity links precede financial facts. */
|
|
139
|
-
export const MODEL_COST_GROUP_EXPORT_COLUMNS = [
|
|
140
|
-
"model",
|
|
141
|
-
"prds",
|
|
142
|
-
"specs",
|
|
143
|
-
"tasks",
|
|
144
|
-
"conversations",
|
|
145
|
-
"runs",
|
|
146
|
-
"tests",
|
|
147
|
-
"evidences",
|
|
148
|
-
"duration_hours",
|
|
149
|
-
"tokens",
|
|
150
|
-
"costs",
|
|
151
|
-
] as const;
|
|
152
|
-
|
|
153
|
-
// Cost Monitor developer attribution is a factual aggregate with coverage
|
|
154
|
-
// counters. Keep the workbook schema aligned with that table and retain null
|
|
155
|
-
// facts instead of allowing them to be inferred as zero by a spreadsheet.
|
|
156
|
-
export const DEVELOPER_EXPORT_COLUMNS = [
|
|
157
|
-
"account_id",
|
|
158
|
-
"login_snapshot",
|
|
159
|
-
"prd_count",
|
|
160
|
-
"spec_count",
|
|
161
|
-
"task_count",
|
|
162
|
-
"run_count",
|
|
163
|
-
"test_count",
|
|
164
|
-
"evidence_count",
|
|
165
|
-
"total_duration_hours",
|
|
166
|
-
"total_tokens",
|
|
167
|
-
"total_cost_brl",
|
|
168
|
-
"duration_covered_runs",
|
|
169
|
-
"token_covered_runs",
|
|
170
|
-
"brl_covered_runs",
|
|
171
|
-
] as const;
|
|
172
|
-
|
|
173
|
-
export const CONVERSATION_EXPORT_COLUMNS = [
|
|
174
|
-
"conversation_id",
|
|
175
|
-
"status",
|
|
176
|
-
"risk",
|
|
177
|
-
"started_at",
|
|
178
|
-
"finished_at",
|
|
179
|
-
"model",
|
|
180
|
-
"reasoning_effort",
|
|
181
|
-
"invocations",
|
|
182
|
-
"duration_hours",
|
|
183
|
-
"tokens",
|
|
184
|
-
"cost_brl",
|
|
185
|
-
] as const;
|
|
186
|
-
|
|
187
|
-
export const CHANGE_EXPORT_COLUMNS = [
|
|
188
|
-
"id",
|
|
189
|
-
"title",
|
|
190
|
-
"status",
|
|
191
|
-
"risk",
|
|
192
|
-
"source_type",
|
|
193
|
-
"source_id",
|
|
194
|
-
"requirement_ids_json",
|
|
195
|
-
"acceptance_ids_json",
|
|
196
|
-
"task_ids_json",
|
|
197
|
-
"occurred_at",
|
|
198
|
-
] as const;
|
|
199
|
-
|
|
200
|
-
export const DECISION_EXPORT_COLUMNS = [
|
|
201
|
-
"id",
|
|
202
|
-
"title",
|
|
203
|
-
"origin",
|
|
204
|
-
"scope_type",
|
|
205
|
-
"scope_id",
|
|
206
|
-
"occurred_at",
|
|
207
|
-
] as const;
|
|
208
|
-
|
|
209
|
-
/** @deprecated Use WORK_EXPORT_COLUMNS for Kanban and Work List exports. */
|
|
210
|
-
export const KANBAN_EXPORT_COLUMNS = WORK_EXPORT_COLUMNS;
|
|
211
|
-
|
|
212
57
|
export async function* exportPageSourceRows(
|
|
213
58
|
pageSource: PreparedExportPageSource,
|
|
214
59
|
mapRows: (
|
|
@@ -253,7 +98,7 @@ export function exportWorkRows(
|
|
|
253
98
|
numberValue(row.duration_ms) ??
|
|
254
99
|
numberValue(telemetry?.duration_ms) ??
|
|
255
100
|
numberValue(row.total_duration) ??
|
|
256
|
-
|
|
101
|
+
exportKnownMetric(metricDuration);
|
|
257
102
|
return {
|
|
258
103
|
type: row.kind ?? row.entity_kind,
|
|
259
104
|
id: row.id,
|
|
@@ -269,13 +114,13 @@ export function exportWorkRows(
|
|
|
269
114
|
numberValue(row.total_tokens) ??
|
|
270
115
|
numberValue(telemetry?.tokens) ??
|
|
271
116
|
numberValue(tokenUsage?.total) ??
|
|
272
|
-
|
|
117
|
+
exportKnownMetric(metricTokens),
|
|
273
118
|
cost_brl:
|
|
274
119
|
numberValue(row.cost_brl) ??
|
|
275
120
|
numberValue(row.total_cost_brl) ??
|
|
276
121
|
numberValue(telemetry?.cost_brl) ??
|
|
277
122
|
numberValue(costUsage?.brl) ??
|
|
278
|
-
|
|
123
|
+
exportKnownMetric(metricCost),
|
|
279
124
|
};
|
|
280
125
|
});
|
|
281
126
|
}
|
|
@@ -346,6 +191,11 @@ export function exportAgentInvocationRows(
|
|
|
346
191
|
});
|
|
347
192
|
}
|
|
348
193
|
|
|
194
|
+
function exportKnownMetric(metric: Record<string, unknown> | null): number | null {
|
|
195
|
+
if (metric?.complete === false && metric.coverage_ratio === 0) return null;
|
|
196
|
+
return numberValue(metric?.known_sum);
|
|
197
|
+
}
|
|
198
|
+
|
|
349
199
|
export function exportCompactLifecycleRows(
|
|
350
200
|
rows: readonly Record<string, unknown>[],
|
|
351
201
|
): Record<string, unknown>[] {
|
|
@@ -354,7 +204,8 @@ export function exportCompactLifecycleRows(
|
|
|
354
204
|
const duration = asRecord(metrics?.duration);
|
|
355
205
|
const tokens = asRecord(metrics?.total_tokens);
|
|
356
206
|
const cost = asRecord(metrics?.cost);
|
|
357
|
-
const durationMs =
|
|
207
|
+
const durationMs =
|
|
208
|
+
duration === null ? numberValue(row.total_duration) : exportKnownMetric(duration);
|
|
358
209
|
return {
|
|
359
210
|
id: row.id ?? null,
|
|
360
211
|
title: row.title ?? null,
|
|
@@ -362,8 +213,8 @@ export function exportCompactLifecycleRows(
|
|
|
362
213
|
occurred_at: row.occurred_at ?? null,
|
|
363
214
|
invocations: numberValue(row.run_count) ?? numberValue(row.invocation_count),
|
|
364
215
|
duration_hours: durationMs === null ? null : durationMs / 3_600_000,
|
|
365
|
-
tokens:
|
|
366
|
-
cost_brl:
|
|
216
|
+
tokens: tokens === null ? numberValue(row.total_tokens) : exportKnownMetric(tokens),
|
|
217
|
+
cost_brl: cost === null ? numberValue(row.total_cost_brl) : exportKnownMetric(cost),
|
|
367
218
|
};
|
|
368
219
|
});
|
|
369
220
|
}
|
|
@@ -0,0 +1,186 @@
|
|
|
1
|
+
export const PERIOD_EXPORT_COLUMNS = [
|
|
2
|
+
"key",
|
|
3
|
+
"prds",
|
|
4
|
+
"specs",
|
|
5
|
+
"tasks",
|
|
6
|
+
"conversations",
|
|
7
|
+
"runs",
|
|
8
|
+
"tests",
|
|
9
|
+
"evidences",
|
|
10
|
+
"tokens",
|
|
11
|
+
"cost",
|
|
12
|
+
"duration_hours",
|
|
13
|
+
] as const;
|
|
14
|
+
|
|
15
|
+
// Work views contain PRDs, SPECs, and Tasks. Export the common, user-facing
|
|
16
|
+
// fields instead of the union of their internal lifecycle projections. The
|
|
17
|
+
// latter produces columns that are empty for an entire view (or nearly every
|
|
18
|
+
// row), which makes the workbook much harder to use.
|
|
19
|
+
export const WORK_EXPORT_COLUMNS = [
|
|
20
|
+
"type",
|
|
21
|
+
"id",
|
|
22
|
+
"title",
|
|
23
|
+
"status",
|
|
24
|
+
"risk",
|
|
25
|
+
"developers",
|
|
26
|
+
"occurred_at",
|
|
27
|
+
"duration_hours",
|
|
28
|
+
"tokens",
|
|
29
|
+
"cost_brl",
|
|
30
|
+
] as const;
|
|
31
|
+
|
|
32
|
+
// Execution rows are entities, not period summaries. Keep their schema
|
|
33
|
+
// aligned with the Execution table so the workbook never inherits the empty
|
|
34
|
+
// PRD/SPEC/period columns shown by a different tab.
|
|
35
|
+
export const EXECUTION_EXPORT_COLUMNS = [
|
|
36
|
+
"id",
|
|
37
|
+
"kind",
|
|
38
|
+
"status",
|
|
39
|
+
"origin",
|
|
40
|
+
"task_id",
|
|
41
|
+
"conversation_id",
|
|
42
|
+
"created_at",
|
|
43
|
+
"finished_at",
|
|
44
|
+
"duration_hours",
|
|
45
|
+
"tokens",
|
|
46
|
+
"cost_brl",
|
|
47
|
+
"invocations",
|
|
48
|
+
] as const;
|
|
49
|
+
|
|
50
|
+
export const AGENT_INVOCATION_EXPORT_COLUMNS = [
|
|
51
|
+
"run_id",
|
|
52
|
+
"execution_id",
|
|
53
|
+
"conversation_id",
|
|
54
|
+
"task_id",
|
|
55
|
+
"origin",
|
|
56
|
+
"run_role",
|
|
57
|
+
"run_purpose",
|
|
58
|
+
"phase",
|
|
59
|
+
"status",
|
|
60
|
+
"agent",
|
|
61
|
+
"provider",
|
|
62
|
+
"model",
|
|
63
|
+
"reasoning_effort",
|
|
64
|
+
"started_at",
|
|
65
|
+
"finished_at",
|
|
66
|
+
"duration_hours",
|
|
67
|
+
"input_tokens",
|
|
68
|
+
"cached_input_tokens",
|
|
69
|
+
"output_tokens",
|
|
70
|
+
"reasoning_tokens",
|
|
71
|
+
"total_tokens",
|
|
72
|
+
"estimated_usd",
|
|
73
|
+
"estimated_brl",
|
|
74
|
+
] as const;
|
|
75
|
+
|
|
76
|
+
export const COMPACT_LIFECYCLE_EXPORT_COLUMNS = [
|
|
77
|
+
"id",
|
|
78
|
+
"title",
|
|
79
|
+
"status",
|
|
80
|
+
"occurred_at",
|
|
81
|
+
"invocations",
|
|
82
|
+
"duration_hours",
|
|
83
|
+
"tokens",
|
|
84
|
+
"cost_brl",
|
|
85
|
+
] as const;
|
|
86
|
+
|
|
87
|
+
export const COST_GROUP_EXPORT_COLUMNS = [
|
|
88
|
+
"key",
|
|
89
|
+
"label",
|
|
90
|
+
"invocations",
|
|
91
|
+
"tasks",
|
|
92
|
+
"tokens",
|
|
93
|
+
"cost_usd",
|
|
94
|
+
"cost_brl",
|
|
95
|
+
"duration_hours",
|
|
96
|
+
] as const;
|
|
97
|
+
|
|
98
|
+
/** Agent exports count Task participation, including repeated Tasks across agents. */
|
|
99
|
+
export const COST_AGENT_EXPORT_COLUMNS = [
|
|
100
|
+
"Persona",
|
|
101
|
+
"Cargo",
|
|
102
|
+
"Zaip Agentes",
|
|
103
|
+
"PRDs",
|
|
104
|
+
"SPECs",
|
|
105
|
+
"Tarefas",
|
|
106
|
+
"Runs",
|
|
107
|
+
"Testes",
|
|
108
|
+
"Evidências",
|
|
109
|
+
"Tempo",
|
|
110
|
+
"Tokens",
|
|
111
|
+
"Custos",
|
|
112
|
+
] as const;
|
|
113
|
+
|
|
114
|
+
/** The model audit mirrors its table: entity links precede financial facts. */
|
|
115
|
+
export const MODEL_COST_GROUP_EXPORT_COLUMNS = [
|
|
116
|
+
"model",
|
|
117
|
+
"prds",
|
|
118
|
+
"specs",
|
|
119
|
+
"tasks",
|
|
120
|
+
"conversations",
|
|
121
|
+
"runs",
|
|
122
|
+
"tests",
|
|
123
|
+
"evidences",
|
|
124
|
+
"duration_hours",
|
|
125
|
+
"tokens",
|
|
126
|
+
"costs",
|
|
127
|
+
] as const;
|
|
128
|
+
|
|
129
|
+
// Cost Monitor developer attribution is a factual aggregate with coverage
|
|
130
|
+
// counters. Keep the workbook schema aligned with that table and retain null
|
|
131
|
+
// facts instead of allowing them to be inferred as zero by a spreadsheet.
|
|
132
|
+
export const DEVELOPER_EXPORT_COLUMNS = [
|
|
133
|
+
"account_id",
|
|
134
|
+
"login_snapshot",
|
|
135
|
+
"prd_count",
|
|
136
|
+
"spec_count",
|
|
137
|
+
"task_count",
|
|
138
|
+
"run_count",
|
|
139
|
+
"test_count",
|
|
140
|
+
"evidence_count",
|
|
141
|
+
"total_duration_hours",
|
|
142
|
+
"total_tokens",
|
|
143
|
+
"total_cost_brl",
|
|
144
|
+
"duration_covered_runs",
|
|
145
|
+
"token_covered_runs",
|
|
146
|
+
"brl_covered_runs",
|
|
147
|
+
] as const;
|
|
148
|
+
|
|
149
|
+
export const CONVERSATION_EXPORT_COLUMNS = [
|
|
150
|
+
"conversation_id",
|
|
151
|
+
"status",
|
|
152
|
+
"risk",
|
|
153
|
+
"started_at",
|
|
154
|
+
"finished_at",
|
|
155
|
+
"model",
|
|
156
|
+
"reasoning_effort",
|
|
157
|
+
"invocations",
|
|
158
|
+
"duration_hours",
|
|
159
|
+
"tokens",
|
|
160
|
+
"cost_brl",
|
|
161
|
+
] as const;
|
|
162
|
+
|
|
163
|
+
export const CHANGE_EXPORT_COLUMNS = [
|
|
164
|
+
"id",
|
|
165
|
+
"title",
|
|
166
|
+
"status",
|
|
167
|
+
"risk",
|
|
168
|
+
"source_type",
|
|
169
|
+
"source_id",
|
|
170
|
+
"requirement_ids_json",
|
|
171
|
+
"acceptance_ids_json",
|
|
172
|
+
"task_ids_json",
|
|
173
|
+
"occurred_at",
|
|
174
|
+
] as const;
|
|
175
|
+
|
|
176
|
+
export const DECISION_EXPORT_COLUMNS = [
|
|
177
|
+
"id",
|
|
178
|
+
"title",
|
|
179
|
+
"origin",
|
|
180
|
+
"scope_type",
|
|
181
|
+
"scope_id",
|
|
182
|
+
"occurred_at",
|
|
183
|
+
] as const;
|
|
184
|
+
|
|
185
|
+
/** @deprecated Use WORK_EXPORT_COLUMNS for Kanban and Work List exports. */
|
|
186
|
+
export const KANBAN_EXPORT_COLUMNS = WORK_EXPORT_COLUMNS;
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
import { expect, it } from "vitest";
|
|
2
|
+
import { COST_AGENT_EXPORT_COLUMNS, exportCostAgentRows } from "./ExcelExportAction.js";
|
|
3
|
+
|
|
4
|
+
it("exports Agent tasks as participations and fills every missing numeric cell with zero", () => {
|
|
5
|
+
expect(COST_AGENT_EXPORT_COLUMNS).toEqual([
|
|
6
|
+
"Persona",
|
|
7
|
+
"Cargo",
|
|
8
|
+
"Zaip Agentes",
|
|
9
|
+
"PRDs",
|
|
10
|
+
"SPECs",
|
|
11
|
+
"Tarefas",
|
|
12
|
+
"Runs",
|
|
13
|
+
"Testes",
|
|
14
|
+
"Evidências",
|
|
15
|
+
"Tempo",
|
|
16
|
+
"Tokens",
|
|
17
|
+
"Custos",
|
|
18
|
+
]);
|
|
19
|
+
const rows = exportCostAgentRows([
|
|
20
|
+
{ key: "dave", task_count: 2 },
|
|
21
|
+
{ key: "leo", task_count: 2 },
|
|
22
|
+
{},
|
|
23
|
+
]);
|
|
24
|
+
expect(rows[0]?.Tarefas).toBe(2);
|
|
25
|
+
expect(rows[1]?.Tarefas).toBe(2);
|
|
26
|
+
for (const key of COST_AGENT_EXPORT_COLUMNS.slice(3)) expect(rows[2]?.[key]).toBe(0);
|
|
27
|
+
expect(rows[0]).not.toHaveProperty("tasks_created");
|
|
28
|
+
});
|
package/templates/.agents/dashboard/modules/operations/src/react/export/export-layout.test.ts
CHANGED
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import { readFileSync } from "node:fs";
|
|
2
2
|
import { describe, expect, it } from "vitest";
|
|
3
|
+
import { WORK_EXPORT_COLUMNS } from "./ExcelExportAction.js";
|
|
3
4
|
|
|
4
5
|
const operationsPage = readFileSync(new URL("../OperationsPage.tsx", import.meta.url), "utf8");
|
|
5
6
|
const operationsNavigation = readFileSync(
|
|
@@ -50,7 +51,7 @@ describe("Excel export layout", () => {
|
|
|
50
51
|
});
|
|
51
52
|
|
|
52
53
|
it("exports factual developer identities with the work-list rows", () => {
|
|
53
|
-
expect(
|
|
54
|
+
expect(WORK_EXPORT_COLUMNS).toContain("developers");
|
|
54
55
|
expect(action).toContain("formatDeveloperIdentities(row.developers)");
|
|
55
56
|
});
|
|
56
57
|
|
package/templates/.agents/dashboard/modules/operations/src/react/operations-export-duration.ts
ADDED
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import { applyFactualPeriodDurations } from "./PeriodSummaryTable.js";
|
|
2
|
+
import type { PeriodGranularity, PeriodSummaryRow } from "./period-summary.js";
|
|
3
|
+
|
|
4
|
+
/** Applies shared duration facts only to the period exports that own them. */
|
|
5
|
+
export function factualDurationRowsForExport(
|
|
6
|
+
granularity: PeriodGranularity,
|
|
7
|
+
rows: readonly PeriodSummaryRow[],
|
|
8
|
+
factualRows?: readonly { key: string; duration_ms: number | null }[],
|
|
9
|
+
): PeriodSummaryRow[] {
|
|
10
|
+
return granularity === "month" || granularity === "year"
|
|
11
|
+
? applyFactualPeriodDurations(rows, factualRows)
|
|
12
|
+
: [...rows];
|
|
13
|
+
}
|
package/templates/.agents/dashboard/modules/operations/src/react/use-operation-filter-feedback.ts
ADDED
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import { useCallback, useEffect, useRef, useState } from "react";
|
|
2
|
+
|
|
3
|
+
export function useOperationFilterFeedback() {
|
|
4
|
+
const [filterLoading, setFilterLoading] = useState(false);
|
|
5
|
+
const filterLoadingTimer = useRef<number | null>(null);
|
|
6
|
+
const showFilterLoading = useCallback(() => {
|
|
7
|
+
setFilterLoading(true);
|
|
8
|
+
if (filterLoadingTimer.current !== null) window.clearTimeout(filterLoadingTimer.current);
|
|
9
|
+
filterLoadingTimer.current = window.setTimeout(() => setFilterLoading(false), 220);
|
|
10
|
+
}, []);
|
|
11
|
+
useEffect(
|
|
12
|
+
() => () => {
|
|
13
|
+
if (filterLoadingTimer.current !== null) window.clearTimeout(filterLoadingTimer.current);
|
|
14
|
+
},
|
|
15
|
+
[],
|
|
16
|
+
);
|
|
17
|
+
return { filterLoading, showFilterLoading };
|
|
18
|
+
}
|
|
@@ -212,6 +212,17 @@ describe("unified work board stages", () => {
|
|
|
212
212
|
});
|
|
213
213
|
});
|
|
214
214
|
|
|
215
|
+
it("retains canonical progress when linked Tasks are outside the loaded board page", () => {
|
|
216
|
+
const spec = {
|
|
217
|
+
...macro("spec", "active", "executing"),
|
|
218
|
+
id: "SPEC-1",
|
|
219
|
+
task_ids: ["TASK-1", "TASK-2"],
|
|
220
|
+
task_count: 2,
|
|
221
|
+
quality: { completed_tasks: 1 },
|
|
222
|
+
} as MacroProjection;
|
|
223
|
+
expect(macroWorkProgress(spec, [spec], [])).toMatchObject({ completedTasks: 1, totalTasks: 2 });
|
|
224
|
+
});
|
|
225
|
+
|
|
215
226
|
it("summarizes only the Tasks that belong to a standalone SPEC", () => {
|
|
216
227
|
const spec = { ...macro("spec", "active", "executing"), id: "SPEC-1", task_ids: ["TASK-1"] };
|
|
217
228
|
const tasks = [
|