@open-mercato/enterprise 0.7.1-develop.7193.1.910a5b0a1e → 0.7.1-develop.7194.1.ab4fc81f82
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/.turbo/turbo-build.log +1 -1
- package/README.md +1 -0
- package/dist/index.js +1 -1
- package/dist/index.js.map +2 -2
- package/dist/modules/agent_orchestrator/acl.js +132 -0
- package/dist/modules/agent_orchestrator/acl.js.map +7 -0
- package/dist/modules/agent_orchestrator/ai-agents.js +57 -0
- package/dist/modules/agent_orchestrator/ai-agents.js.map +7 -0
- package/dist/modules/agent_orchestrator/ai-skills.js +48 -0
- package/dist/modules/agent_orchestrator/ai-skills.js.map +7 -0
- package/dist/modules/agent_orchestrator/ai-tools.js +254 -0
- package/dist/modules/agent_orchestrator/ai-tools.js.map +7 -0
- package/dist/modules/agent_orchestrator/api/agents/[id]/files/route.js +69 -0
- package/dist/modules/agent_orchestrator/api/agents/[id]/files/route.js.map +7 -0
- package/dist/modules/agent_orchestrator/api/agents/[id]/metrics/route.js +81 -0
- package/dist/modules/agent_orchestrator/api/agents/[id]/metrics/route.js.map +7 -0
- package/dist/modules/agent_orchestrator/api/agents/[id]/route.js +154 -0
- package/dist/modules/agent_orchestrator/api/agents/[id]/route.js.map +7 -0
- package/dist/modules/agent_orchestrator/api/agents/[id]/run/route.js +250 -0
- package/dist/modules/agent_orchestrator/api/agents/[id]/run/route.js.map +7 -0
- package/dist/modules/agent_orchestrator/api/agents/[id]/settings/route.js +105 -0
- package/dist/modules/agent_orchestrator/api/agents/[id]/settings/route.js.map +7 -0
- package/dist/modules/agent_orchestrator/api/agents/route.js +114 -0
- package/dist/modules/agent_orchestrator/api/agents/route.js.map +7 -0
- package/dist/modules/agent_orchestrator/api/artifacts/file/[id]/route.js +64 -0
- package/dist/modules/agent_orchestrator/api/artifacts/file/[id]/route.js.map +7 -0
- package/dist/modules/agent_orchestrator/api/audit/by-instigator/[humanUserId]/route.js +105 -0
- package/dist/modules/agent_orchestrator/api/audit/by-instigator/[humanUserId]/route.js.map +7 -0
- package/dist/modules/agent_orchestrator/api/auto-approval/settings/route.js +110 -0
- package/dist/modules/agent_orchestrator/api/auto-approval/settings/route.js.map +7 -0
- package/dist/modules/agent_orchestrator/api/context-bundles/route.js +88 -0
- package/dist/modules/agent_orchestrator/api/context-bundles/route.js.map +7 -0
- package/dist/modules/agent_orchestrator/api/corrections/route.js +101 -0
- package/dist/modules/agent_orchestrator/api/corrections/route.js.map +7 -0
- package/dist/modules/agent_orchestrator/api/eval-assertions/preview/route.js +98 -0
- package/dist/modules/agent_orchestrator/api/eval-assertions/preview/route.js.map +7 -0
- package/dist/modules/agent_orchestrator/api/eval-assertions/route.js +196 -0
- package/dist/modules/agent_orchestrator/api/eval-assertions/route.js.map +7 -0
- package/dist/modules/agent_orchestrator/api/eval-cases/[id]/approve/route.js +86 -0
- package/dist/modules/agent_orchestrator/api/eval-cases/[id]/approve/route.js.map +7 -0
- package/dist/modules/agent_orchestrator/api/eval-cases/[id]/archive/route.js +85 -0
- package/dist/modules/agent_orchestrator/api/eval-cases/[id]/archive/route.js.map +7 -0
- package/dist/modules/agent_orchestrator/api/eval-cases/[id]/route.js +67 -0
- package/dist/modules/agent_orchestrator/api/eval-cases/[id]/route.js.map +7 -0
- package/dist/modules/agent_orchestrator/api/eval-cases/export/route.js +78 -0
- package/dist/modules/agent_orchestrator/api/eval-cases/export/route.js.map +7 -0
- package/dist/modules/agent_orchestrator/api/eval-cases/route.js +140 -0
- package/dist/modules/agent_orchestrator/api/eval-cases/route.js.map +7 -0
- package/dist/modules/agent_orchestrator/api/eval-runs/[id]/cancel/route.js +67 -0
- package/dist/modules/agent_orchestrator/api/eval-runs/[id]/cancel/route.js.map +7 -0
- package/dist/modules/agent_orchestrator/api/eval-runs/[id]/case-runs/[caseRunId]/results/route.js +66 -0
- package/dist/modules/agent_orchestrator/api/eval-runs/[id]/case-runs/[caseRunId]/results/route.js.map +7 -0
- package/dist/modules/agent_orchestrator/api/eval-runs/[id]/route.js +111 -0
- package/dist/modules/agent_orchestrator/api/eval-runs/[id]/route.js.map +7 -0
- package/dist/modules/agent_orchestrator/api/eval-runs/route.js +157 -0
- package/dist/modules/agent_orchestrator/api/eval-runs/route.js.map +7 -0
- package/dist/modules/agent_orchestrator/api/eval-scorers/route.js +34 -0
- package/dist/modules/agent_orchestrator/api/eval-scorers/route.js.map +7 -0
- package/dist/modules/agent_orchestrator/api/executions/[id]/route.js +72 -0
- package/dist/modules/agent_orchestrator/api/executions/[id]/route.js.map +7 -0
- package/dist/modules/agent_orchestrator/api/executions/route.js +185 -0
- package/dist/modules/agent_orchestrator/api/executions/route.js.map +7 -0
- package/dist/modules/agent_orchestrator/api/features/route.js +61 -0
- package/dist/modules/agent_orchestrator/api/features/route.js.map +7 -0
- package/dist/modules/agent_orchestrator/api/guardrail-checks/route.js +85 -0
- package/dist/modules/agent_orchestrator/api/guardrail-checks/route.js.map +7 -0
- package/dist/modules/agent_orchestrator/api/identity/agent/auth/route.js +95 -0
- package/dist/modules/agent_orchestrator/api/identity/agent/auth/route.js.map +7 -0
- package/dist/modules/agent_orchestrator/api/identity/grants/[id]/revoke/route.js +109 -0
- package/dist/modules/agent_orchestrator/api/identity/grants/[id]/revoke/route.js.map +7 -0
- package/dist/modules/agent_orchestrator/api/identity/token/route.js +80 -0
- package/dist/modules/agent_orchestrator/api/identity/token/route.js.map +7 -0
- package/dist/modules/agent_orchestrator/api/identity/well-known/route.js +44 -0
- package/dist/modules/agent_orchestrator/api/identity/well-known/route.js.map +7 -0
- package/dist/modules/agent_orchestrator/api/metrics/agents/route.js +122 -0
- package/dist/modules/agent_orchestrator/api/metrics/agents/route.js.map +7 -0
- package/dist/modules/agent_orchestrator/api/metrics/overview/route.js +165 -0
- package/dist/modules/agent_orchestrator/api/metrics/overview/route.js.map +7 -0
- package/dist/modules/agent_orchestrator/api/openapi.js +29 -0
- package/dist/modules/agent_orchestrator/api/openapi.js.map +7 -0
- package/dist/modules/agent_orchestrator/api/processes/[id]/executions/route.js +160 -0
- package/dist/modules/agent_orchestrator/api/processes/[id]/executions/route.js.map +7 -0
- package/dist/modules/agent_orchestrator/api/processes/[id]/route.js +53 -0
- package/dist/modules/agent_orchestrator/api/processes/[id]/route.js.map +7 -0
- package/dist/modules/agent_orchestrator/api/processes/route.js +357 -0
- package/dist/modules/agent_orchestrator/api/processes/route.js.map +7 -0
- package/dist/modules/agent_orchestrator/api/proposals/[id]/dispose/route.js +111 -0
- package/dist/modules/agent_orchestrator/api/proposals/[id]/dispose/route.js.map +7 -0
- package/dist/modules/agent_orchestrator/api/proposals/route.js +98 -0
- package/dist/modules/agent_orchestrator/api/proposals/route.js.map +7 -0
- package/dist/modules/agent_orchestrator/api/runs/[id]/artifact/route.js +71 -0
- package/dist/modules/agent_orchestrator/api/runs/[id]/artifact/route.js.map +7 -0
- package/dist/modules/agent_orchestrator/api/runs/[id]/artifacts/route.js +66 -0
- package/dist/modules/agent_orchestrator/api/runs/[id]/artifacts/route.js.map +7 -0
- package/dist/modules/agent_orchestrator/api/runs/[id]/eval-case/route.js +73 -0
- package/dist/modules/agent_orchestrator/api/runs/[id]/eval-case/route.js.map +7 -0
- package/dist/modules/agent_orchestrator/api/runs/[id]/flag/route.js +74 -0
- package/dist/modules/agent_orchestrator/api/runs/[id]/flag/route.js.map +7 -0
- package/dist/modules/agent_orchestrator/api/runs/[id]/rerun/route.js +165 -0
- package/dist/modules/agent_orchestrator/api/runs/[id]/rerun/route.js.map +7 -0
- package/dist/modules/agent_orchestrator/api/runs/[id]/route.js +86 -0
- package/dist/modules/agent_orchestrator/api/runs/[id]/route.js.map +7 -0
- package/dist/modules/agent_orchestrator/api/runs/route.js +137 -0
- package/dist/modules/agent_orchestrator/api/runs/route.js.map +7 -0
- package/dist/modules/agent_orchestrator/api/tokens/estimate/route.js +56 -0
- package/dist/modules/agent_orchestrator/api/tokens/estimate/route.js.map +7 -0
- package/dist/modules/agent_orchestrator/api/trace/ingest/route.js +80 -0
- package/dist/modules/agent_orchestrator/api/trace/ingest/route.js.map +7 -0
- package/dist/modules/agent_orchestrator/api/web-search/health/route.js +184 -0
- package/dist/modules/agent_orchestrator/api/web-search/health/route.js.map +7 -0
- package/dist/modules/agent_orchestrator/api/web-search/preview/route.js +150 -0
- package/dist/modules/agent_orchestrator/api/web-search/preview/route.js.map +7 -0
- package/dist/modules/agent_orchestrator/api/web-search/settings/route.js +213 -0
- package/dist/modules/agent_orchestrator/api/web-search/settings/route.js.map +7 -0
- package/dist/modules/agent_orchestrator/backend/agents/[id]/components/ActivityTab.js +112 -0
- package/dist/modules/agent_orchestrator/backend/agents/[id]/components/ActivityTab.js.map +7 -0
- package/dist/modules/agent_orchestrator/backend/agents/[id]/components/AgentConfigDrawer.js +58 -0
- package/dist/modules/agent_orchestrator/backend/agents/[id]/components/AgentConfigDrawer.js.map +7 -0
- package/dist/modules/agent_orchestrator/backend/agents/[id]/components/AgentHeaderCard.js +117 -0
- package/dist/modules/agent_orchestrator/backend/agents/[id]/components/AgentHeaderCard.js.map +7 -0
- package/dist/modules/agent_orchestrator/backend/agents/[id]/components/AssertionFormDrawer.js +318 -0
- package/dist/modules/agent_orchestrator/backend/agents/[id]/components/AssertionFormDrawer.js.map +7 -0
- package/dist/modules/agent_orchestrator/backend/agents/[id]/components/ConfigurationTab.js +126 -0
- package/dist/modules/agent_orchestrator/backend/agents/[id]/components/ConfigurationTab.js.map +7 -0
- package/dist/modules/agent_orchestrator/backend/agents/[id]/components/EvalCaseDrawer.js +379 -0
- package/dist/modules/agent_orchestrator/backend/agents/[id]/components/EvalCaseDrawer.js.map +7 -0
- package/dist/modules/agent_orchestrator/backend/agents/[id]/components/EvalResultsDrawer.js +159 -0
- package/dist/modules/agent_orchestrator/backend/agents/[id]/components/EvalResultsDrawer.js.map +7 -0
- package/dist/modules/agent_orchestrator/backend/agents/[id]/components/EvaluationTab.js +581 -0
- package/dist/modules/agent_orchestrator/backend/agents/[id]/components/EvaluationTab.js.map +7 -0
- package/dist/modules/agent_orchestrator/backend/agents/[id]/components/FilesTab.js +249 -0
- package/dist/modules/agent_orchestrator/backend/agents/[id]/components/FilesTab.js.map +7 -0
- package/dist/modules/agent_orchestrator/backend/agents/[id]/components/OverviewTab.js +162 -0
- package/dist/modules/agent_orchestrator/backend/agents/[id]/components/OverviewTab.js.map +7 -0
- package/dist/modules/agent_orchestrator/backend/agents/[id]/components/RunEvaluationDrawer.js +199 -0
- package/dist/modules/agent_orchestrator/backend/agents/[id]/components/RunEvaluationDrawer.js.map +7 -0
- package/dist/modules/agent_orchestrator/backend/agents/[id]/components/TokenCalculatorTab.js +137 -0
- package/dist/modules/agent_orchestrator/backend/agents/[id]/components/TokenCalculatorTab.js.map +7 -0
- package/dist/modules/agent_orchestrator/backend/agents/[id]/components/filesShared.js +97 -0
- package/dist/modules/agent_orchestrator/backend/agents/[id]/components/filesShared.js.map +7 -0
- package/dist/modules/agent_orchestrator/backend/agents/[id]/components/workspacePrimitives.js +159 -0
- package/dist/modules/agent_orchestrator/backend/agents/[id]/components/workspacePrimitives.js.map +7 -0
- package/dist/modules/agent_orchestrator/backend/agents/[id]/components/workspaceShared.js +132 -0
- package/dist/modules/agent_orchestrator/backend/agents/[id]/components/workspaceShared.js.map +7 -0
- package/dist/modules/agent_orchestrator/backend/agents/[id]/page.js +266 -0
- package/dist/modules/agent_orchestrator/backend/agents/[id]/page.js.map +7 -0
- package/dist/modules/agent_orchestrator/backend/agents/[id]/page.meta.js +18 -0
- package/dist/modules/agent_orchestrator/backend/agents/[id]/page.meta.js.map +7 -0
- package/dist/modules/agent_orchestrator/backend/agents/agentListFilters.js +44 -0
- package/dist/modules/agent_orchestrator/backend/agents/agentListFilters.js.map +7 -0
- package/dist/modules/agent_orchestrator/backend/agents/page.js +439 -0
- package/dist/modules/agent_orchestrator/backend/agents/page.js.map +7 -0
- package/dist/modules/agent_orchestrator/backend/agents/page.meta.js +28 -0
- package/dist/modules/agent_orchestrator/backend/agents/page.meta.js.map +7 -0
- package/dist/modules/agent_orchestrator/backend/audit/by-instigator/[humanUserId]/page.js +80 -0
- package/dist/modules/agent_orchestrator/backend/audit/by-instigator/[humanUserId]/page.js.map +7 -0
- package/dist/modules/agent_orchestrator/backend/audit/by-instigator/[humanUserId]/page.meta.js +19 -0
- package/dist/modules/agent_orchestrator/backend/audit/by-instigator/[humanUserId]/page.meta.js.map +7 -0
- package/dist/modules/agent_orchestrator/backend/audit/page.js +324 -0
- package/dist/modules/agent_orchestrator/backend/audit/page.js.map +7 -0
- package/dist/modules/agent_orchestrator/backend/audit/page.meta.js +27 -0
- package/dist/modules/agent_orchestrator/backend/audit/page.meta.js.map +7 -0
- package/dist/modules/agent_orchestrator/backend/caseload/[proposalId]/page.js +239 -0
- package/dist/modules/agent_orchestrator/backend/caseload/[proposalId]/page.js.map +7 -0
- package/dist/modules/agent_orchestrator/backend/caseload/[proposalId]/page.meta.js +18 -0
- package/dist/modules/agent_orchestrator/backend/caseload/[proposalId]/page.meta.js.map +7 -0
- package/dist/modules/agent_orchestrator/backend/caseload/hooks.js +344 -0
- package/dist/modules/agent_orchestrator/backend/caseload/hooks.js.map +7 -0
- package/dist/modules/agent_orchestrator/backend/caseload/page.js +1360 -0
- package/dist/modules/agent_orchestrator/backend/caseload/page.js.map +7 -0
- package/dist/modules/agent_orchestrator/backend/caseload/page.meta.js +25 -0
- package/dist/modules/agent_orchestrator/backend/caseload/page.meta.js.map +7 -0
- package/dist/modules/agent_orchestrator/backend/eval-cases/[id]/page.js +357 -0
- package/dist/modules/agent_orchestrator/backend/eval-cases/[id]/page.js.map +7 -0
- package/dist/modules/agent_orchestrator/backend/eval-cases/[id]/page.meta.js +18 -0
- package/dist/modules/agent_orchestrator/backend/eval-cases/[id]/page.meta.js.map +7 -0
- package/dist/modules/agent_orchestrator/backend/eval-runs/[id]/page.js +595 -0
- package/dist/modules/agent_orchestrator/backend/eval-runs/[id]/page.js.map +7 -0
- package/dist/modules/agent_orchestrator/backend/eval-runs/[id]/page.meta.js +18 -0
- package/dist/modules/agent_orchestrator/backend/eval-runs/[id]/page.meta.js.map +7 -0
- package/dist/modules/agent_orchestrator/backend/overview/page.js +593 -0
- package/dist/modules/agent_orchestrator/backend/overview/page.js.map +7 -0
- package/dist/modules/agent_orchestrator/backend/overview/page.meta.js +27 -0
- package/dist/modules/agent_orchestrator/backend/overview/page.meta.js.map +7 -0
- package/dist/modules/agent_orchestrator/backend/playground/PlaygroundEvalPanel.js +219 -0
- package/dist/modules/agent_orchestrator/backend/playground/PlaygroundEvalPanel.js.map +7 -0
- package/dist/modules/agent_orchestrator/backend/playground/page.js +443 -0
- package/dist/modules/agent_orchestrator/backend/playground/page.js.map +7 -0
- package/dist/modules/agent_orchestrator/backend/playground/page.meta.js +24 -0
- package/dist/modules/agent_orchestrator/backend/playground/page.meta.js.map +7 -0
- package/dist/modules/agent_orchestrator/backend/processes/[id]/page.js +611 -0
- package/dist/modules/agent_orchestrator/backend/processes/[id]/page.js.map +7 -0
- package/dist/modules/agent_orchestrator/backend/processes/[id]/page.meta.js +18 -0
- package/dist/modules/agent_orchestrator/backend/processes/[id]/page.meta.js.map +7 -0
- package/dist/modules/agent_orchestrator/backend/processes/definitions/MilestoneEditor.js +219 -0
- package/dist/modules/agent_orchestrator/backend/processes/definitions/MilestoneEditor.js.map +7 -0
- package/dist/modules/agent_orchestrator/backend/processes/definitions/TriggerEditor.js +326 -0
- package/dist/modules/agent_orchestrator/backend/processes/definitions/TriggerEditor.js.map +7 -0
- package/dist/modules/agent_orchestrator/backend/processes/definitions/[id]/page.js +565 -0
- package/dist/modules/agent_orchestrator/backend/processes/definitions/[id]/page.js.map +7 -0
- package/dist/modules/agent_orchestrator/backend/processes/definitions/[id]/page.meta.js +17 -0
- package/dist/modules/agent_orchestrator/backend/processes/definitions/[id]/page.meta.js.map +7 -0
- package/dist/modules/agent_orchestrator/backend/processes/definitions/formHelpers.js +69 -0
- package/dist/modules/agent_orchestrator/backend/processes/definitions/formHelpers.js.map +7 -0
- package/dist/modules/agent_orchestrator/backend/processes/definitions/navigation.js +9 -0
- package/dist/modules/agent_orchestrator/backend/processes/definitions/navigation.js.map +7 -0
- package/dist/modules/agent_orchestrator/backend/processes/definitions/page.js +735 -0
- package/dist/modules/agent_orchestrator/backend/processes/definitions/page.js.map +7 -0
- package/dist/modules/agent_orchestrator/backend/processes/definitions/page.meta.js +25 -0
- package/dist/modules/agent_orchestrator/backend/processes/definitions/page.meta.js.map +7 -0
- package/dist/modules/agent_orchestrator/backend/processes/page.js +244 -0
- package/dist/modules/agent_orchestrator/backend/processes/page.js.map +7 -0
- package/dist/modules/agent_orchestrator/backend/processes/page.meta.js +29 -0
- package/dist/modules/agent_orchestrator/backend/processes/page.meta.js.map +7 -0
- package/dist/modules/agent_orchestrator/backend/settings/auto-approval/page.js +204 -0
- package/dist/modules/agent_orchestrator/backend/settings/auto-approval/page.js.map +7 -0
- package/dist/modules/agent_orchestrator/backend/settings/auto-approval/page.meta.js +30 -0
- package/dist/modules/agent_orchestrator/backend/settings/auto-approval/page.meta.js.map +7 -0
- package/dist/modules/agent_orchestrator/backend/settings/web-search/AdapterRow.js +241 -0
- package/dist/modules/agent_orchestrator/backend/settings/web-search/AdapterRow.js.map +7 -0
- package/dist/modules/agent_orchestrator/backend/settings/web-search/WebSearchPreview.js +129 -0
- package/dist/modules/agent_orchestrator/backend/settings/web-search/WebSearchPreview.js.map +7 -0
- package/dist/modules/agent_orchestrator/backend/settings/web-search/page.js +644 -0
- package/dist/modules/agent_orchestrator/backend/settings/web-search/page.js.map +7 -0
- package/dist/modules/agent_orchestrator/backend/settings/web-search/page.meta.js +32 -0
- package/dist/modules/agent_orchestrator/backend/settings/web-search/page.meta.js.map +7 -0
- package/dist/modules/agent_orchestrator/backend/traces/[id]/page.js +1015 -0
- package/dist/modules/agent_orchestrator/backend/traces/[id]/page.js.map +7 -0
- package/dist/modules/agent_orchestrator/backend/traces/[id]/page.meta.js +18 -0
- package/dist/modules/agent_orchestrator/backend/traces/[id]/page.meta.js.map +7 -0
- package/dist/modules/agent_orchestrator/backend/traces/page.js +477 -0
- package/dist/modules/agent_orchestrator/backend/traces/page.js.map +7 -0
- package/dist/modules/agent_orchestrator/backend/traces/page.meta.js +24 -0
- package/dist/modules/agent_orchestrator/backend/traces/page.meta.js.map +7 -0
- package/dist/modules/agent_orchestrator/cli.js +592 -0
- package/dist/modules/agent_orchestrator/cli.js.map +7 -0
- package/dist/modules/agent_orchestrator/commands/artifacts.js +127 -0
- package/dist/modules/agent_orchestrator/commands/artifacts.js.map +7 -0
- package/dist/modules/agent_orchestrator/commands/corrections.js +284 -0
- package/dist/modules/agent_orchestrator/commands/corrections.js.map +7 -0
- package/dist/modules/agent_orchestrator/commands/dispose.js +265 -0
- package/dist/modules/agent_orchestrator/commands/dispose.js.map +7 -0
- package/dist/modules/agent_orchestrator/commands/evalRuns.js +202 -0
- package/dist/modules/agent_orchestrator/commands/evalRuns.js.map +7 -0
- package/dist/modules/agent_orchestrator/commands/grants.js +119 -0
- package/dist/modules/agent_orchestrator/commands/grants.js.map +7 -0
- package/dist/modules/agent_orchestrator/commands/index.js +11 -0
- package/dist/modules/agent_orchestrator/commands/index.js.map +7 -0
- package/dist/modules/agent_orchestrator/commands/processes.js +130 -0
- package/dist/modules/agent_orchestrator/commands/processes.js.map +7 -0
- package/dist/modules/agent_orchestrator/commands/proposals.js +67 -0
- package/dist/modules/agent_orchestrator/commands/proposals.js.map +7 -0
- package/dist/modules/agent_orchestrator/commands/runActions.js +42 -0
- package/dist/modules/agent_orchestrator/commands/runActions.js.map +7 -0
- package/dist/modules/agent_orchestrator/commands/runs.js +183 -0
- package/dist/modules/agent_orchestrator/commands/runs.js.map +7 -0
- package/dist/modules/agent_orchestrator/commands/trace.js +89 -0
- package/dist/modules/agent_orchestrator/commands/trace.js.map +7 -0
- package/dist/modules/agent_orchestrator/components/AgentIoDrawer.js +45 -0
- package/dist/modules/agent_orchestrator/components/AgentIoDrawer.js.map +7 -0
- package/dist/modules/agent_orchestrator/components/AgentTimeline.js +129 -0
- package/dist/modules/agent_orchestrator/components/AgentTimeline.js.map +7 -0
- package/dist/modules/agent_orchestrator/components/DisposeDialog.js +87 -0
- package/dist/modules/agent_orchestrator/components/DisposeDialog.js.map +7 -0
- package/dist/modules/agent_orchestrator/components/EmptyArt.js +50 -0
- package/dist/modules/agent_orchestrator/components/EmptyArt.js.map +7 -0
- package/dist/modules/agent_orchestrator/components/InvokeAgentNodeConfig.js +111 -0
- package/dist/modules/agent_orchestrator/components/InvokeAgentNodeConfig.js.map +7 -0
- package/dist/modules/agent_orchestrator/components/ProcessOutcomeLink.js +42 -0
- package/dist/modules/agent_orchestrator/components/ProcessOutcomeLink.js.map +7 -0
- package/dist/modules/agent_orchestrator/components/ProposalCard.js +431 -0
- package/dist/modules/agent_orchestrator/components/ProposalCard.js.map +7 -0
- package/dist/modules/agent_orchestrator/components/ProposalFacts.js +85 -0
- package/dist/modules/agent_orchestrator/components/ProposalFacts.js.map +7 -0
- package/dist/modules/agent_orchestrator/components/ProposalOptionList.js +190 -0
- package/dist/modules/agent_orchestrator/components/ProposalOptionList.js.map +7 -0
- package/dist/modules/agent_orchestrator/components/ProposeOnlyNotice.js +25 -0
- package/dist/modules/agent_orchestrator/components/ProposeOnlyNotice.js.map +7 -0
- package/dist/modules/agent_orchestrator/components/SkillDrawer.js +48 -0
- package/dist/modules/agent_orchestrator/components/SkillDrawer.js.map +7 -0
- package/dist/modules/agent_orchestrator/components/StartHereGuide.js +183 -0
- package/dist/modules/agent_orchestrator/components/StartHereGuide.js.map +7 -0
- package/dist/modules/agent_orchestrator/components/SystemHealthTile.js +135 -0
- package/dist/modules/agent_orchestrator/components/SystemHealthTile.js.map +7 -0
- package/dist/modules/agent_orchestrator/components/WebSearchActivity.js +87 -0
- package/dist/modules/agent_orchestrator/components/WebSearchActivity.js.map +7 -0
- package/dist/modules/agent_orchestrator/components/agentChips.js +90 -0
- package/dist/modules/agent_orchestrator/components/agentChips.js.map +7 -0
- package/dist/modules/agent_orchestrator/components/cockpitStatus.js +94 -0
- package/dist/modules/agent_orchestrator/components/cockpitStatus.js.map +7 -0
- package/dist/modules/agent_orchestrator/components/evalRunTypes.js +209 -0
- package/dist/modules/agent_orchestrator/components/evalRunTypes.js.map +7 -0
- package/dist/modules/agent_orchestrator/components/health/HealthRow.js +15 -0
- package/dist/modules/agent_orchestrator/components/health/HealthRow.js.map +7 -0
- package/dist/modules/agent_orchestrator/components/health/HealthStateBadge.js +13 -0
- package/dist/modules/agent_orchestrator/components/health/HealthStateBadge.js.map +7 -0
- package/dist/modules/agent_orchestrator/components/health/SystemHealthPanel.js +126 -0
- package/dist/modules/agent_orchestrator/components/health/SystemHealthPanel.js.map +7 -0
- package/dist/modules/agent_orchestrator/components/health/vocabulary.js +40 -0
- package/dist/modules/agent_orchestrator/components/health/vocabulary.js.map +7 -0
- package/dist/modules/agent_orchestrator/components/optionalRequest.js +7 -0
- package/dist/modules/agent_orchestrator/components/optionalRequest.js.map +7 -0
- package/dist/modules/agent_orchestrator/components/playgroundRunError.js +37 -0
- package/dist/modules/agent_orchestrator/components/playgroundRunError.js.map +7 -0
- package/dist/modules/agent_orchestrator/components/playgroundToolCalls.js +12 -0
- package/dist/modules/agent_orchestrator/components/playgroundToolCalls.js.map +7 -0
- package/dist/modules/agent_orchestrator/components/processTypes.js +454 -0
- package/dist/modules/agent_orchestrator/components/processTypes.js.map +7 -0
- package/dist/modules/agent_orchestrator/components/proposalCaseStatus.js +64 -0
- package/dist/modules/agent_orchestrator/components/proposalCaseStatus.js.map +7 -0
- package/dist/modules/agent_orchestrator/components/proposalEdit.js +71 -0
- package/dist/modules/agent_orchestrator/components/proposalEdit.js.map +7 -0
- package/dist/modules/agent_orchestrator/components/proposalFactsData.js +138 -0
- package/dist/modules/agent_orchestrator/components/proposalFactsData.js.map +7 -0
- package/dist/modules/agent_orchestrator/components/serverSort.js +34 -0
- package/dist/modules/agent_orchestrator/components/serverSort.js.map +7 -0
- package/dist/modules/agent_orchestrator/components/subjectRef.js +34 -0
- package/dist/modules/agent_orchestrator/components/subjectRef.js.map +7 -0
- package/dist/modules/agent_orchestrator/components/types.js +462 -0
- package/dist/modules/agent_orchestrator/components/types.js.map +7 -0
- package/dist/modules/agent_orchestrator/components/useAgentIcons.js +31 -0
- package/dist/modules/agent_orchestrator/components/useAgentIcons.js.map +7 -0
- package/dist/modules/agent_orchestrator/components/useAgentLabels.js +35 -0
- package/dist/modules/agent_orchestrator/components/useAgentLabels.js.map +7 -0
- package/dist/modules/agent_orchestrator/components/useAgentTags.js +32 -0
- package/dist/modules/agent_orchestrator/components/useAgentTags.js.map +7 -0
- package/dist/modules/agent_orchestrator/components/useCoalescedReload.js +33 -0
- package/dist/modules/agent_orchestrator/components/useCoalescedReload.js.map +7 -0
- package/dist/modules/agent_orchestrator/data/agentIcons.js +35 -0
- package/dist/modules/agent_orchestrator/data/agentIcons.js.map +7 -0
- package/dist/modules/agent_orchestrator/data/agentTags.js +26 -0
- package/dist/modules/agent_orchestrator/data/agentTags.js.map +7 -0
- package/dist/modules/agent_orchestrator/data/entities.js +1382 -0
- package/dist/modules/agent_orchestrator/data/entities.js.map +7 -0
- package/dist/modules/agent_orchestrator/data/proposalEnvelope.js +168 -0
- package/dist/modules/agent_orchestrator/data/proposalEnvelope.js.map +7 -0
- package/dist/modules/agent_orchestrator/data/validators.js +949 -0
- package/dist/modules/agent_orchestrator/data/validators.js.map +7 -0
- package/dist/modules/agent_orchestrator/di.js +169 -0
- package/dist/modules/agent_orchestrator/di.js.map +7 -0
- package/dist/modules/agent_orchestrator/encryption.js +100 -0
- package/dist/modules/agent_orchestrator/encryption.js.map +7 -0
- package/dist/modules/agent_orchestrator/events.js +87 -0
- package/dist/modules/agent_orchestrator/events.js.map +7 -0
- package/dist/modules/agent_orchestrator/examples/deals-health-check-workflow.json +124 -0
- package/dist/modules/agent_orchestrator/examples/refund-triage-workflow.json +210 -0
- package/dist/modules/agent_orchestrator/generated/file-agents.generated.js +169 -0
- package/dist/modules/agent_orchestrator/generated/file-agents.generated.js.map +7 -0
- package/dist/modules/agent_orchestrator/i18n/de.json +1495 -0
- package/dist/modules/agent_orchestrator/i18n/en.json +1495 -0
- package/dist/modules/agent_orchestrator/i18n/es.json +1495 -0
- package/dist/modules/agent_orchestrator/i18n/ko.json +1495 -0
- package/dist/modules/agent_orchestrator/i18n/pl.json +1495 -0
- package/dist/modules/agent_orchestrator/index.js +151 -0
- package/dist/modules/agent_orchestrator/index.js.map +7 -0
- package/dist/modules/agent_orchestrator/lib/automationLinks.js +12 -0
- package/dist/modules/agent_orchestrator/lib/automationLinks.js.map +7 -0
- package/dist/modules/agent_orchestrator/lib/context/contextResolver.js +317 -0
- package/dist/modules/agent_orchestrator/lib/context/contextResolver.js.map +7 -0
- package/dist/modules/agent_orchestrator/lib/context/documentIngest.js +93 -0
- package/dist/modules/agent_orchestrator/lib/context/documentIngest.js.map +7 -0
- package/dist/modules/agent_orchestrator/lib/context/documentOcrProvider.js +90 -0
- package/dist/modules/agent_orchestrator/lib/context/documentOcrProvider.js.map +7 -0
- package/dist/modules/agent_orchestrator/lib/context/documentSource.js +44 -0
- package/dist/modules/agent_orchestrator/lib/context/documentSource.js.map +7 -0
- package/dist/modules/agent_orchestrator/lib/context/index.js +64 -0
- package/dist/modules/agent_orchestrator/lib/context/index.js.map +7 -0
- package/dist/modules/agent_orchestrator/lib/context/packer.js +47 -0
- package/dist/modules/agent_orchestrator/lib/context/packer.js.map +7 -0
- package/dist/modules/agent_orchestrator/lib/context/redactor.js +72 -0
- package/dist/modules/agent_orchestrator/lib/context/redactor.js.map +7 -0
- package/dist/modules/agent_orchestrator/lib/context/registry.js +60 -0
- package/dist/modules/agent_orchestrator/lib/context/registry.js.map +7 -0
- package/dist/modules/agent_orchestrator/lib/context/retrievalSource.js +69 -0
- package/dist/modules/agent_orchestrator/lib/context/retrievalSource.js.map +7 -0
- package/dist/modules/agent_orchestrator/lib/crudCache.js +24 -0
- package/dist/modules/agent_orchestrator/lib/crudCache.js.map +7 -0
- package/dist/modules/agent_orchestrator/lib/disposition/autoApprovalPolicy.js +51 -0
- package/dist/modules/agent_orchestrator/lib/disposition/autoApprovalPolicy.js.map +7 -0
- package/dist/modules/agent_orchestrator/lib/disposition/dispositionService.js +190 -0
- package/dist/modules/agent_orchestrator/lib/disposition/dispositionService.js.map +7 -0
- package/dist/modules/agent_orchestrator/lib/disposition/resume.js +42 -0
- package/dist/modules/agent_orchestrator/lib/disposition/resume.js.map +7 -0
- package/dist/modules/agent_orchestrator/lib/disposition/tenantAutoApprovalPolicy.js +59 -0
- package/dist/modules/agent_orchestrator/lib/disposition/tenantAutoApprovalPolicy.js.map +7 -0
- package/dist/modules/agent_orchestrator/lib/eval/assertionResolution.js +53 -0
- package/dist/modules/agent_orchestrator/lib/eval/assertionResolution.js.map +7 -0
- package/dist/modules/agent_orchestrator/lib/eval/canonicalInputKey.js +20 -0
- package/dist/modules/agent_orchestrator/lib/eval/canonicalInputKey.js.map +7 -0
- package/dist/modules/agent_orchestrator/lib/eval/defaultAssertions.js +78 -0
- package/dist/modules/agent_orchestrator/lib/eval/defaultAssertions.js.map +7 -0
- package/dist/modules/agent_orchestrator/lib/eval/evalGate.js +71 -0
- package/dist/modules/agent_orchestrator/lib/eval/evalGate.js.map +7 -0
- package/dist/modules/agent_orchestrator/lib/eval/evalReplayService.js +277 -0
- package/dist/modules/agent_orchestrator/lib/eval/evalReplayService.js.map +7 -0
- package/dist/modules/agent_orchestrator/lib/eval/evalRuntimeService.js +141 -0
- package/dist/modules/agent_orchestrator/lib/eval/evalRuntimeService.js.map +7 -0
- package/dist/modules/agent_orchestrator/lib/eval/judgeRubric.js +150 -0
- package/dist/modules/agent_orchestrator/lib/eval/judgeRubric.js.map +7 -0
- package/dist/modules/agent_orchestrator/lib/eval/llmJudge.js +122 -0
- package/dist/modules/agent_orchestrator/lib/eval/llmJudge.js.map +7 -0
- package/dist/modules/agent_orchestrator/lib/eval/projectRunView.js +32 -0
- package/dist/modules/agent_orchestrator/lib/eval/projectRunView.js.map +7 -0
- package/dist/modules/agent_orchestrator/lib/eval/registry/agent.js +240 -0
- package/dist/modules/agent_orchestrator/lib/eval/registry/agent.js.map +7 -0
- package/dist/modules/agent_orchestrator/lib/eval/registry/economics.js +77 -0
- package/dist/modules/agent_orchestrator/lib/eval/registry/economics.js.map +7 -0
- package/dist/modules/agent_orchestrator/lib/eval/registry/index.js +97 -0
- package/dist/modules/agent_orchestrator/lib/eval/registry/index.js.map +7 -0
- package/dist/modules/agent_orchestrator/lib/eval/registry/judge.js +66 -0
- package/dist/modules/agent_orchestrator/lib/eval/registry/judge.js.map +7 -0
- package/dist/modules/agent_orchestrator/lib/eval/registry/shared.js +146 -0
- package/dist/modules/agent_orchestrator/lib/eval/registry/shared.js.map +7 -0
- package/dist/modules/agent_orchestrator/lib/eval/registry/structured.js +264 -0
- package/dist/modules/agent_orchestrator/lib/eval/registry/structured.js.map +7 -0
- package/dist/modules/agent_orchestrator/lib/eval/registry/text.js +110 -0
- package/dist/modules/agent_orchestrator/lib/eval/registry/text.js.map +7 -0
- package/dist/modules/agent_orchestrator/lib/eval/registry/tools.js +232 -0
- package/dist/modules/agent_orchestrator/lib/eval/registry/tools.js.map +7 -0
- package/dist/modules/agent_orchestrator/lib/eval/sampling.js +26 -0
- package/dist/modules/agent_orchestrator/lib/eval/sampling.js.map +7 -0
- package/dist/modules/agent_orchestrator/lib/eval/scorers.js +46 -0
- package/dist/modules/agent_orchestrator/lib/eval/scorers.js.map +7 -0
- package/dist/modules/agent_orchestrator/lib/eval/types.js +16 -0
- package/dist/modules/agent_orchestrator/lib/eval/types.js.map +7 -0
- package/dist/modules/agent_orchestrator/lib/featureFlags.js +9 -0
- package/dist/modules/agent_orchestrator/lib/featureFlags.js.map +7 -0
- package/dist/modules/agent_orchestrator/lib/guardrails/grounding.js +90 -0
- package/dist/modules/agent_orchestrator/lib/guardrails/grounding.js.map +7 -0
- package/dist/modules/agent_orchestrator/lib/guardrails/groundingSets.js +35 -0
- package/dist/modules/agent_orchestrator/lib/guardrails/groundingSets.js.map +7 -0
- package/dist/modules/agent_orchestrator/lib/guardrails/guardrailService.js +160 -0
- package/dist/modules/agent_orchestrator/lib/guardrails/guardrailService.js.map +7 -0
- package/dist/modules/agent_orchestrator/lib/guardrails/promptInjection.js +94 -0
- package/dist/modules/agent_orchestrator/lib/guardrails/promptInjection.js.map +7 -0
- package/dist/modules/agent_orchestrator/lib/guardrails/publicEndpointRateLimit.js +36 -0
- package/dist/modules/agent_orchestrator/lib/guardrails/publicEndpointRateLimit.js.map +7 -0
- package/dist/modules/agent_orchestrator/lib/guardrails/syncGroundingSets.js +43 -0
- package/dist/modules/agent_orchestrator/lib/guardrails/syncGroundingSets.js.map +7 -0
- package/dist/modules/agent_orchestrator/lib/identity/agentAuthMdService.js +136 -0
- package/dist/modules/agent_orchestrator/lib/identity/agentAuthMdService.js.map +7 -0
- package/dist/modules/agent_orchestrator/lib/identity/agentDelegationGrantService.js +55 -0
- package/dist/modules/agent_orchestrator/lib/identity/agentDelegationGrantService.js.map +7 -0
- package/dist/modules/agent_orchestrator/lib/identity/agentNoBypassSubscriber.js +50 -0
- package/dist/modules/agent_orchestrator/lib/identity/agentNoBypassSubscriber.js.map +7 -0
- package/dist/modules/agent_orchestrator/lib/identity/agentPrincipalService.js +149 -0
- package/dist/modules/agent_orchestrator/lib/identity/agentPrincipalService.js.map +7 -0
- package/dist/modules/agent_orchestrator/lib/identity/agentTokenService.js +138 -0
- package/dist/modules/agent_orchestrator/lib/identity/agentTokenService.js.map +7 -0
- package/dist/modules/agent_orchestrator/lib/identity/agentWriteScope.js +22 -0
- package/dist/modules/agent_orchestrator/lib/identity/agentWriteScope.js.map +7 -0
- package/dist/modules/agent_orchestrator/lib/metrics/metricRollupService.js +112 -0
- package/dist/modules/agent_orchestrator/lib/metrics/metricRollupService.js.map +7 -0
- package/dist/modules/agent_orchestrator/lib/processes/executionSearch.js +16 -0
- package/dist/modules/agent_orchestrator/lib/processes/executionSearch.js.map +7 -0
- package/dist/modules/agent_orchestrator/lib/processes/materializeAgentWorkflow.js +178 -0
- package/dist/modules/agent_orchestrator/lib/processes/materializeAgentWorkflow.js.map +7 -0
- package/dist/modules/agent_orchestrator/lib/processes/processProjection.js +220 -0
- package/dist/modules/agent_orchestrator/lib/processes/processProjection.js.map +7 -0
- package/dist/modules/agent_orchestrator/lib/processes/subjectContext.js +14 -0
- package/dist/modules/agent_orchestrator/lib/processes/subjectContext.js.map +7 -0
- package/dist/modules/agent_orchestrator/lib/processes/workflowGrant.js +41 -0
- package/dist/modules/agent_orchestrator/lib/processes/workflowGrant.js.map +7 -0
- package/dist/modules/agent_orchestrator/lib/queue.js +25 -0
- package/dist/modules/agent_orchestrator/lib/queue.js.map +7 -0
- package/dist/modules/agent_orchestrator/lib/runtime/actionVocabulary.js +66 -0
- package/dist/modules/agent_orchestrator/lib/runtime/actionVocabulary.js.map +7 -0
- package/dist/modules/agent_orchestrator/lib/runtime/admission.js +113 -0
- package/dist/modules/agent_orchestrator/lib/runtime/admission.js.map +7 -0
- package/dist/modules/agent_orchestrator/lib/runtime/agentRunSessionStore.js +92 -0
- package/dist/modules/agent_orchestrator/lib/runtime/agentRunSessionStore.js.map +7 -0
- package/dist/modules/agent_orchestrator/lib/runtime/agentRuntime.js +67 -0
- package/dist/modules/agent_orchestrator/lib/runtime/agentRuntime.js.map +7 -0
- package/dist/modules/agent_orchestrator/lib/runtime/agentWorkspaceManager.js +111 -0
- package/dist/modules/agent_orchestrator/lib/runtime/agentWorkspaceManager.js.map +7 -0
- package/dist/modules/agent_orchestrator/lib/runtime/artifactCollector.js +146 -0
- package/dist/modules/agent_orchestrator/lib/runtime/artifactCollector.js.map +7 -0
- package/dist/modules/agent_orchestrator/lib/runtime/artifactFileStore.js +85 -0
- package/dist/modules/agent_orchestrator/lib/runtime/artifactFileStore.js.map +7 -0
- package/dist/modules/agent_orchestrator/lib/runtime/attachmentStager.js +62 -0
- package/dist/modules/agent_orchestrator/lib/runtime/attachmentStager.js.map +7 -0
- package/dist/modules/agent_orchestrator/lib/runtime/errors.js +38 -0
- package/dist/modules/agent_orchestrator/lib/runtime/errors.js.map +7 -0
- package/dist/modules/agent_orchestrator/lib/runtime/executeProposal.js +37 -0
- package/dist/modules/agent_orchestrator/lib/runtime/executeProposal.js.map +7 -0
- package/dist/modules/agent_orchestrator/lib/runtime/fileAgentSkills.js +32 -0
- package/dist/modules/agent_orchestrator/lib/runtime/fileAgentSkills.js.map +7 -0
- package/dist/modules/agent_orchestrator/lib/runtime/fileInput.js +27 -0
- package/dist/modules/agent_orchestrator/lib/runtime/fileInput.js.map +7 -0
- package/dist/modules/agent_orchestrator/lib/runtime/invokeAgentForWorkflow.js +115 -0
- package/dist/modules/agent_orchestrator/lib/runtime/invokeAgentForWorkflow.js.map +7 -0
- package/dist/modules/agent_orchestrator/lib/runtime/modelPricing.js +77 -0
- package/dist/modules/agent_orchestrator/lib/runtime/modelPricing.js.map +7 -0
- package/dist/modules/agent_orchestrator/lib/runtime/nativeAgentRunner.js +422 -0
- package/dist/modules/agent_orchestrator/lib/runtime/nativeAgentRunner.js.map +7 -0
- package/dist/modules/agent_orchestrator/lib/runtime/nativeTraceCapture.js +132 -0
- package/dist/modules/agent_orchestrator/lib/runtime/nativeTraceCapture.js.map +7 -0
- package/dist/modules/agent_orchestrator/lib/runtime/openCodeAgentRunner.js +581 -0
- package/dist/modules/agent_orchestrator/lib/runtime/openCodeAgentRunner.js.map +7 -0
- package/dist/modules/agent_orchestrator/lib/runtime/persistence.js +110 -0
- package/dist/modules/agent_orchestrator/lib/runtime/persistence.js.map +7 -0
- package/dist/modules/agent_orchestrator/lib/runtime/providerBudget.js +152 -0
- package/dist/modules/agent_orchestrator/lib/runtime/providerBudget.js.map +7 -0
- package/dist/modules/agent_orchestrator/lib/runtime/rerunContext.js +13 -0
- package/dist/modules/agent_orchestrator/lib/runtime/rerunContext.js.map +7 -0
- package/dist/modules/agent_orchestrator/lib/runtime/runContext.js +17 -0
- package/dist/modules/agent_orchestrator/lib/runtime/runContext.js.map +7 -0
- package/dist/modules/agent_orchestrator/lib/runtime/sandboxedScript.js +39 -0
- package/dist/modules/agent_orchestrator/lib/runtime/sandboxedScript.js.map +7 -0
- package/dist/modules/agent_orchestrator/lib/sdk/agentMarkdown.js +91 -0
- package/dist/modules/agent_orchestrator/lib/sdk/agentMarkdown.js.map +7 -0
- package/dist/modules/agent_orchestrator/lib/sdk/agentOutcomeContract.js +35 -0
- package/dist/modules/agent_orchestrator/lib/sdk/agentOutcomeContract.js.map +7 -0
- package/dist/modules/agent_orchestrator/lib/sdk/defineAgent.js +214 -0
- package/dist/modules/agent_orchestrator/lib/sdk/defineAgent.js.map +7 -0
- package/dist/modules/agent_orchestrator/lib/sdk/defineFileAgent.js +417 -0
- package/dist/modules/agent_orchestrator/lib/sdk/defineFileAgent.js.map +7 -0
- package/dist/modules/agent_orchestrator/lib/sdk/defineSkill.js +40 -0
- package/dist/modules/agent_orchestrator/lib/sdk/defineSkill.js.map +7 -0
- package/dist/modules/agent_orchestrator/lib/sdk/outcomeSchema.js +129 -0
- package/dist/modules/agent_orchestrator/lib/sdk/outcomeSchema.js.map +7 -0
- package/dist/modules/agent_orchestrator/lib/sdk/skillMarkdown.js +78 -0
- package/dist/modules/agent_orchestrator/lib/sdk/skillMarkdown.js.map +7 -0
- package/dist/modules/agent_orchestrator/lib/seeds.js +224 -0
- package/dist/modules/agent_orchestrator/lib/seeds.js.map +7 -0
- package/dist/modules/agent_orchestrator/lib/settings/agentSettings.js +55 -0
- package/dist/modules/agent_orchestrator/lib/settings/agentSettings.js.map +7 -0
- package/dist/modules/agent_orchestrator/lib/systemHealth.js +94 -0
- package/dist/modules/agent_orchestrator/lib/systemHealth.js.map +7 -0
- package/dist/modules/agent_orchestrator/lib/tasks/eventTriggerMatch.js +81 -0
- package/dist/modules/agent_orchestrator/lib/tasks/eventTriggerMatch.js.map +7 -0
- package/dist/modules/agent_orchestrator/lib/tasks/milestones.js +96 -0
- package/dist/modules/agent_orchestrator/lib/tasks/milestones.js.map +7 -0
- package/dist/modules/agent_orchestrator/lib/tasks/outcome.js +44 -0
- package/dist/modules/agent_orchestrator/lib/tasks/outcome.js.map +7 -0
- package/dist/modules/agent_orchestrator/lib/tasks/outcomeLink.js +45 -0
- package/dist/modules/agent_orchestrator/lib/tasks/outcomeLink.js.map +7 -0
- package/dist/modules/agent_orchestrator/lib/tasks/schedule.js +63 -0
- package/dist/modules/agent_orchestrator/lib/tasks/schedule.js.map +7 -0
- package/dist/modules/agent_orchestrator/lib/tasks/scheduleValidation.js +25 -0
- package/dist/modules/agent_orchestrator/lib/tasks/scheduleValidation.js.map +7 -0
- package/dist/modules/agent_orchestrator/lib/tasks/triggers.js +34 -0
- package/dist/modules/agent_orchestrator/lib/tasks/triggers.js.map +7 -0
- package/dist/modules/agent_orchestrator/lib/tokens/computeAgentTokenUsage.js +70 -0
- package/dist/modules/agent_orchestrator/lib/tokens/computeAgentTokenUsage.js.map +7 -0
- package/dist/modules/agent_orchestrator/lib/tokens/types.js +1 -0
- package/dist/modules/agent_orchestrator/lib/tokens/types.js.map +7 -0
- package/dist/modules/agent_orchestrator/lib/trace/artifactStore.js +89 -0
- package/dist/modules/agent_orchestrator/lib/trace/artifactStore.js.map +7 -0
- package/dist/modules/agent_orchestrator/lib/trace/correctionService.js +61 -0
- package/dist/modules/agent_orchestrator/lib/trace/correctionService.js.map +7 -0
- package/dist/modules/agent_orchestrator/lib/trace/ingestAuth.js +39 -0
- package/dist/modules/agent_orchestrator/lib/trace/ingestAuth.js.map +7 -0
- package/dist/modules/agent_orchestrator/lib/trace/redactToolSummary.js +44 -0
- package/dist/modules/agent_orchestrator/lib/trace/redactToolSummary.js.map +7 -0
- package/dist/modules/agent_orchestrator/lib/trace/spanTimeline.js +96 -0
- package/dist/modules/agent_orchestrator/lib/trace/spanTimeline.js.map +7 -0
- package/dist/modules/agent_orchestrator/lib/trace/traceIngestionService.js +168 -0
- package/dist/modules/agent_orchestrator/lib/trace/traceIngestionService.js.map +7 -0
- package/dist/modules/agent_orchestrator/lib/webSearch/guardrails.js +116 -0
- package/dist/modules/agent_orchestrator/lib/webSearch/guardrails.js.map +7 -0
- package/dist/modules/agent_orchestrator/lib/webSearch/healthCache.js +68 -0
- package/dist/modules/agent_orchestrator/lib/webSearch/healthCache.js.map +7 -0
- package/dist/modules/agent_orchestrator/lib/webSearch/healthProbePlan.js +16 -0
- package/dist/modules/agent_orchestrator/lib/webSearch/healthProbePlan.js.map +7 -0
- package/dist/modules/agent_orchestrator/lib/webSearch/policy.js +172 -0
- package/dist/modules/agent_orchestrator/lib/webSearch/policy.js.map +7 -0
- package/dist/modules/agent_orchestrator/lib/webSearch/registry.js +113 -0
- package/dist/modules/agent_orchestrator/lib/webSearch/registry.js.map +7 -0
- package/dist/modules/agent_orchestrator/lib/webSearch/secretStorage.js +87 -0
- package/dist/modules/agent_orchestrator/lib/webSearch/secretStorage.js.map +7 -0
- package/dist/modules/agent_orchestrator/lib/webSearch/steps.js +48 -0
- package/dist/modules/agent_orchestrator/lib/webSearch/steps.js.map +7 -0
- package/dist/modules/agent_orchestrator/lib/webSearch/tools.js +176 -0
- package/dist/modules/agent_orchestrator/lib/webSearch/tools.js.map +7 -0
- package/dist/modules/agent_orchestrator/lib/workInbox/agentDispositionSource.js +151 -0
- package/dist/modules/agent_orchestrator/lib/workInbox/agentDispositionSource.js.map +7 -0
- package/dist/modules/agent_orchestrator/migrations/Migration20260906141535_agent_orchestrator.js +200 -0
- package/dist/modules/agent_orchestrator/migrations/Migration20260906141535_agent_orchestrator.js.map +7 -0
- package/dist/modules/agent_orchestrator/notifications.js +32 -0
- package/dist/modules/agent_orchestrator/notifications.js.map +7 -0
- package/dist/modules/agent_orchestrator/setup.js +147 -0
- package/dist/modules/agent_orchestrator/setup.js.map +7 -0
- package/dist/modules/agent_orchestrator/subscribers/process-event-trigger.js +140 -0
- package/dist/modules/agent_orchestrator/subscribers/process-event-trigger.js.map +7 -0
- package/dist/modules/agent_orchestrator/subscribers/process-proposal-created.js +17 -0
- package/dist/modules/agent_orchestrator/subscribers/process-proposal-created.js.map +7 -0
- package/dist/modules/agent_orchestrator/subscribers/process-proposal-disposed.js +15 -0
- package/dist/modules/agent_orchestrator/subscribers/process-proposal-disposed.js.map +7 -0
- package/dist/modules/agent_orchestrator/subscribers/process-run-completed.js +17 -0
- package/dist/modules/agent_orchestrator/subscribers/process-run-completed.js.map +7 -0
- package/dist/modules/agent_orchestrator/subscribers/process-run-ingested.js +17 -0
- package/dist/modules/agent_orchestrator/subscribers/process-run-ingested.js.map +7 -0
- package/dist/modules/agent_orchestrator/subscribers/process-workflow-cancelled.js +20 -0
- package/dist/modules/agent_orchestrator/subscribers/process-workflow-cancelled.js.map +7 -0
- package/dist/modules/agent_orchestrator/subscribers/process-workflow-completed.js +20 -0
- package/dist/modules/agent_orchestrator/subscribers/process-workflow-completed.js.map +7 -0
- package/dist/modules/agent_orchestrator/subscribers/process-workflow-failed.js +21 -0
- package/dist/modules/agent_orchestrator/subscribers/process-workflow-failed.js.map +7 -0
- package/dist/modules/agent_orchestrator/subscribers/process-workflow-milestone.js +30 -0
- package/dist/modules/agent_orchestrator/subscribers/process-workflow-milestone.js.map +7 -0
- package/dist/modules/agent_orchestrator/subscribers/process-workflow-started.js +25 -0
- package/dist/modules/agent_orchestrator/subscribers/process-workflow-started.js.map +7 -0
- package/dist/modules/agent_orchestrator/subscribers/proposal-disposed-notification-clear.js +34 -0
- package/dist/modules/agent_orchestrator/subscribers/proposal-disposed-notification-clear.js.map +7 -0
- package/dist/modules/agent_orchestrator/subscribers/proposal-pending-notification.js +53 -0
- package/dist/modules/agent_orchestrator/subscribers/proposal-pending-notification.js.map +7 -0
- package/dist/modules/agent_orchestrator/widgets/injection/caseload-nav-badge/widget.client.js +44 -0
- package/dist/modules/agent_orchestrator/widgets/injection/caseload-nav-badge/widget.client.js.map +7 -0
- package/dist/modules/agent_orchestrator/widgets/injection/caseload-nav-badge/widget.js +17 -0
- package/dist/modules/agent_orchestrator/widgets/injection/caseload-nav-badge/widget.js.map +7 -0
- package/dist/modules/agent_orchestrator/widgets/injection/task-proposal-draft/widget.client.js +107 -0
- package/dist/modules/agent_orchestrator/widgets/injection/task-proposal-draft/widget.client.js.map +7 -0
- package/dist/modules/agent_orchestrator/widgets/injection/task-proposal-draft/widget.js +17 -0
- package/dist/modules/agent_orchestrator/widgets/injection/task-proposal-draft/widget.js.map +7 -0
- package/dist/modules/agent_orchestrator/widgets/injection/task-proposal-link/widget.js +28 -0
- package/dist/modules/agent_orchestrator/widgets/injection/task-proposal-link/widget.js.map +7 -0
- package/dist/modules/agent_orchestrator/widgets/injection-table.js +33 -0
- package/dist/modules/agent_orchestrator/widgets/injection-table.js.map +7 -0
- package/dist/modules/agent_orchestrator/workers/eval-suite-runner.js +56 -0
- package/dist/modules/agent_orchestrator/workers/eval-suite-runner.js.map +7 -0
- package/dist/modules/agent_orchestrator/workers/llm-judge.js +29 -0
- package/dist/modules/agent_orchestrator/workers/llm-judge.js.map +7 -0
- package/dist/modules/agent_orchestrator/workers/metric-rollup.js +29 -0
- package/dist/modules/agent_orchestrator/workers/metric-rollup.js.map +7 -0
- package/dist/modules/agent_orchestrator/workers/process-execution-starter.js +130 -0
- package/dist/modules/agent_orchestrator/workers/process-execution-starter.js.map +7 -0
- package/dist/modules/record_locks/lib/conflictValues.js +78 -0
- package/dist/modules/record_locks/lib/conflictValues.js.map +7 -0
- package/dist/modules/record_locks/lib/crudMutationGuardService.js +19 -4
- package/dist/modules/record_locks/lib/crudMutationGuardService.js.map +2 -2
- package/dist/modules/record_locks/lib/recordLockService.js +1 -44
- package/dist/modules/record_locks/lib/recordLockService.js.map +2 -2
- package/jest.config.cjs +2 -0
- package/package.json +18 -6
- package/src/index.ts +1 -1
- package/src/modules/agent_orchestrator/.ai/skills/om-create-opencode-agent/SKILL.md +251 -0
- package/src/modules/agent_orchestrator/AGENTS.md +374 -0
- package/src/modules/agent_orchestrator/DEMO.md +175 -0
- package/src/modules/agent_orchestrator/acl.ts +131 -0
- package/src/modules/agent_orchestrator/ai-agents.ts +70 -0
- package/src/modules/agent_orchestrator/ai-skills.ts +59 -0
- package/src/modules/agent_orchestrator/ai-tools.ts +391 -0
- package/src/modules/agent_orchestrator/api/agents/[id]/files/route.ts +77 -0
- package/src/modules/agent_orchestrator/api/agents/[id]/metrics/route.ts +106 -0
- package/src/modules/agent_orchestrator/api/agents/[id]/route.ts +166 -0
- package/src/modules/agent_orchestrator/api/agents/[id]/run/route.ts +339 -0
- package/src/modules/agent_orchestrator/api/agents/[id]/settings/route.ts +119 -0
- package/src/modules/agent_orchestrator/api/agents/route.ts +124 -0
- package/src/modules/agent_orchestrator/api/artifacts/file/[id]/route.ts +80 -0
- package/src/modules/agent_orchestrator/api/audit/by-instigator/[humanUserId]/route.ts +143 -0
- package/src/modules/agent_orchestrator/api/auto-approval/settings/route.ts +143 -0
- package/src/modules/agent_orchestrator/api/context-bundles/route.ts +89 -0
- package/src/modules/agent_orchestrator/api/corrections/route.ts +119 -0
- package/src/modules/agent_orchestrator/api/eval-assertions/preview/route.ts +123 -0
- package/src/modules/agent_orchestrator/api/eval-assertions/route.ts +228 -0
- package/src/modules/agent_orchestrator/api/eval-cases/[id]/approve/route.ts +101 -0
- package/src/modules/agent_orchestrator/api/eval-cases/[id]/archive/route.ts +100 -0
- package/src/modules/agent_orchestrator/api/eval-cases/[id]/route.ts +84 -0
- package/src/modules/agent_orchestrator/api/eval-cases/export/route.ts +92 -0
- package/src/modules/agent_orchestrator/api/eval-cases/route.ts +159 -0
- package/src/modules/agent_orchestrator/api/eval-runs/[id]/cancel/route.ts +78 -0
- package/src/modules/agent_orchestrator/api/eval-runs/[id]/case-runs/[caseRunId]/results/route.ts +82 -0
- package/src/modules/agent_orchestrator/api/eval-runs/[id]/route.ts +133 -0
- package/src/modules/agent_orchestrator/api/eval-runs/route.ts +197 -0
- package/src/modules/agent_orchestrator/api/eval-scorers/route.ts +51 -0
- package/src/modules/agent_orchestrator/api/executions/[id]/route.ts +106 -0
- package/src/modules/agent_orchestrator/api/executions/route.ts +206 -0
- package/src/modules/agent_orchestrator/api/features/route.ts +71 -0
- package/src/modules/agent_orchestrator/api/guardrail-checks/route.ts +86 -0
- package/src/modules/agent_orchestrator/api/identity/agent/auth/route.ts +121 -0
- package/src/modules/agent_orchestrator/api/identity/grants/[id]/revoke/route.ts +133 -0
- package/src/modules/agent_orchestrator/api/identity/token/route.ts +102 -0
- package/src/modules/agent_orchestrator/api/identity/well-known/route.ts +60 -0
- package/src/modules/agent_orchestrator/api/metrics/agents/route.ts +160 -0
- package/src/modules/agent_orchestrator/api/metrics/overview/route.ts +240 -0
- package/src/modules/agent_orchestrator/api/openapi.ts +31 -0
- package/src/modules/agent_orchestrator/api/processes/[id]/executions/route.ts +211 -0
- package/src/modules/agent_orchestrator/api/processes/[id]/route.ts +70 -0
- package/src/modules/agent_orchestrator/api/processes/route.ts +458 -0
- package/src/modules/agent_orchestrator/api/proposals/[id]/dispose/route.ts +131 -0
- package/src/modules/agent_orchestrator/api/proposals/route.ts +113 -0
- package/src/modules/agent_orchestrator/api/runs/[id]/artifact/route.ts +93 -0
- package/src/modules/agent_orchestrator/api/runs/[id]/artifacts/route.ts +83 -0
- package/src/modules/agent_orchestrator/api/runs/[id]/eval-case/route.ts +91 -0
- package/src/modules/agent_orchestrator/api/runs/[id]/flag/route.ts +89 -0
- package/src/modules/agent_orchestrator/api/runs/[id]/rerun/route.ts +195 -0
- package/src/modules/agent_orchestrator/api/runs/[id]/route.ts +102 -0
- package/src/modules/agent_orchestrator/api/runs/route.ts +146 -0
- package/src/modules/agent_orchestrator/api/tokens/estimate/route.ts +61 -0
- package/src/modules/agent_orchestrator/api/trace/ingest/route.ts +98 -0
- package/src/modules/agent_orchestrator/api/web-search/health/route.ts +268 -0
- package/src/modules/agent_orchestrator/api/web-search/preview/route.ts +184 -0
- package/src/modules/agent_orchestrator/api/web-search/settings/route.ts +309 -0
- package/src/modules/agent_orchestrator/auth.md +107 -0
- package/src/modules/agent_orchestrator/backend/agents/[id]/components/ActivityTab.tsx +118 -0
- package/src/modules/agent_orchestrator/backend/agents/[id]/components/AgentConfigDrawer.tsx +96 -0
- package/src/modules/agent_orchestrator/backend/agents/[id]/components/AgentHeaderCard.tsx +174 -0
- package/src/modules/agent_orchestrator/backend/agents/[id]/components/AssertionFormDrawer.tsx +418 -0
- package/src/modules/agent_orchestrator/backend/agents/[id]/components/ConfigurationTab.tsx +185 -0
- package/src/modules/agent_orchestrator/backend/agents/[id]/components/EvalCaseDrawer.tsx +488 -0
- package/src/modules/agent_orchestrator/backend/agents/[id]/components/EvalResultsDrawer.tsx +244 -0
- package/src/modules/agent_orchestrator/backend/agents/[id]/components/EvaluationTab.tsx +715 -0
- package/src/modules/agent_orchestrator/backend/agents/[id]/components/FilesTab.tsx +328 -0
- package/src/modules/agent_orchestrator/backend/agents/[id]/components/OverviewTab.tsx +211 -0
- package/src/modules/agent_orchestrator/backend/agents/[id]/components/RunEvaluationDrawer.tsx +247 -0
- package/src/modules/agent_orchestrator/backend/agents/[id]/components/TokenCalculatorTab.tsx +143 -0
- package/src/modules/agent_orchestrator/backend/agents/[id]/components/filesShared.ts +149 -0
- package/src/modules/agent_orchestrator/backend/agents/[id]/components/workspacePrimitives.tsx +236 -0
- package/src/modules/agent_orchestrator/backend/agents/[id]/components/workspaceShared.ts +193 -0
- package/src/modules/agent_orchestrator/backend/agents/[id]/page.meta.ts +14 -0
- package/src/modules/agent_orchestrator/backend/agents/[id]/page.tsx +335 -0
- package/src/modules/agent_orchestrator/backend/agents/agentListFilters.ts +95 -0
- package/src/modules/agent_orchestrator/backend/agents/page.meta.ts +26 -0
- package/src/modules/agent_orchestrator/backend/agents/page.tsx +549 -0
- package/src/modules/agent_orchestrator/backend/audit/by-instigator/[humanUserId]/page.meta.ts +15 -0
- package/src/modules/agent_orchestrator/backend/audit/by-instigator/[humanUserId]/page.tsx +126 -0
- package/src/modules/agent_orchestrator/backend/audit/page.meta.ts +25 -0
- package/src/modules/agent_orchestrator/backend/audit/page.tsx +392 -0
- package/src/modules/agent_orchestrator/backend/caseload/[proposalId]/page.meta.ts +14 -0
- package/src/modules/agent_orchestrator/backend/caseload/[proposalId]/page.tsx +298 -0
- package/src/modules/agent_orchestrator/backend/caseload/hooks.ts +583 -0
- package/src/modules/agent_orchestrator/backend/caseload/page.meta.ts +23 -0
- package/src/modules/agent_orchestrator/backend/caseload/page.tsx +1761 -0
- package/src/modules/agent_orchestrator/backend/eval-cases/[id]/page.meta.ts +14 -0
- package/src/modules/agent_orchestrator/backend/eval-cases/[id]/page.tsx +446 -0
- package/src/modules/agent_orchestrator/backend/eval-runs/[id]/page.meta.ts +14 -0
- package/src/modules/agent_orchestrator/backend/eval-runs/[id]/page.tsx +824 -0
- package/src/modules/agent_orchestrator/backend/overview/page.meta.ts +25 -0
- package/src/modules/agent_orchestrator/backend/overview/page.tsx +755 -0
- package/src/modules/agent_orchestrator/backend/playground/PlaygroundEvalPanel.tsx +292 -0
- package/src/modules/agent_orchestrator/backend/playground/page.meta.ts +22 -0
- package/src/modules/agent_orchestrator/backend/playground/page.tsx +647 -0
- package/src/modules/agent_orchestrator/backend/processes/[id]/page.meta.ts +14 -0
- package/src/modules/agent_orchestrator/backend/processes/[id]/page.tsx +856 -0
- package/src/modules/agent_orchestrator/backend/processes/definitions/MilestoneEditor.tsx +285 -0
- package/src/modules/agent_orchestrator/backend/processes/definitions/TriggerEditor.tsx +391 -0
- package/src/modules/agent_orchestrator/backend/processes/definitions/[id]/page.meta.ts +13 -0
- package/src/modules/agent_orchestrator/backend/processes/definitions/[id]/page.tsx +705 -0
- package/src/modules/agent_orchestrator/backend/processes/definitions/formHelpers.ts +100 -0
- package/src/modules/agent_orchestrator/backend/processes/definitions/navigation.ts +6 -0
- package/src/modules/agent_orchestrator/backend/processes/definitions/page.meta.ts +23 -0
- package/src/modules/agent_orchestrator/backend/processes/definitions/page.tsx +904 -0
- package/src/modules/agent_orchestrator/backend/processes/page.meta.ts +27 -0
- package/src/modules/agent_orchestrator/backend/processes/page.tsx +317 -0
- package/src/modules/agent_orchestrator/backend/settings/auto-approval/page.meta.ts +28 -0
- package/src/modules/agent_orchestrator/backend/settings/auto-approval/page.tsx +315 -0
- package/src/modules/agent_orchestrator/backend/settings/web-search/AdapterRow.tsx +351 -0
- package/src/modules/agent_orchestrator/backend/settings/web-search/WebSearchPreview.tsx +203 -0
- package/src/modules/agent_orchestrator/backend/settings/web-search/page.meta.ts +30 -0
- package/src/modules/agent_orchestrator/backend/settings/web-search/page.tsx +913 -0
- package/src/modules/agent_orchestrator/backend/traces/[id]/page.meta.ts +14 -0
- package/src/modules/agent_orchestrator/backend/traces/[id]/page.tsx +1383 -0
- package/src/modules/agent_orchestrator/backend/traces/page.meta.ts +22 -0
- package/src/modules/agent_orchestrator/backend/traces/page.tsx +601 -0
- package/src/modules/agent_orchestrator/cli.ts +719 -0
- package/src/modules/agent_orchestrator/commands/artifacts.ts +171 -0
- package/src/modules/agent_orchestrator/commands/corrections.ts +345 -0
- package/src/modules/agent_orchestrator/commands/dispose.ts +380 -0
- package/src/modules/agent_orchestrator/commands/evalRuns.ts +291 -0
- package/src/modules/agent_orchestrator/commands/grants.ts +149 -0
- package/src/modules/agent_orchestrator/commands/index.ts +10 -0
- package/src/modules/agent_orchestrator/commands/processes.ts +176 -0
- package/src/modules/agent_orchestrator/commands/proposals.ts +82 -0
- package/src/modules/agent_orchestrator/commands/runActions.ts +52 -0
- package/src/modules/agent_orchestrator/commands/runs.ts +212 -0
- package/src/modules/agent_orchestrator/commands/trace.ts +118 -0
- package/src/modules/agent_orchestrator/components/AgentIoDrawer.tsx +87 -0
- package/src/modules/agent_orchestrator/components/AgentTimeline.tsx +175 -0
- package/src/modules/agent_orchestrator/components/DisposeDialog.tsx +112 -0
- package/src/modules/agent_orchestrator/components/EmptyArt.tsx +51 -0
- package/src/modules/agent_orchestrator/components/InvokeAgentNodeConfig.tsx +150 -0
- package/src/modules/agent_orchestrator/components/ProcessOutcomeLink.tsx +50 -0
- package/src/modules/agent_orchestrator/components/ProposalCard.tsx +602 -0
- package/src/modules/agent_orchestrator/components/ProposalFacts.tsx +139 -0
- package/src/modules/agent_orchestrator/components/ProposalOptionList.tsx +273 -0
- package/src/modules/agent_orchestrator/components/ProposeOnlyNotice.tsx +40 -0
- package/src/modules/agent_orchestrator/components/SkillDrawer.tsx +75 -0
- package/src/modules/agent_orchestrator/components/StartHereGuide.tsx +241 -0
- package/src/modules/agent_orchestrator/components/SystemHealthTile.tsx +189 -0
- package/src/modules/agent_orchestrator/components/WebSearchActivity.tsx +180 -0
- package/src/modules/agent_orchestrator/components/agentChips.tsx +123 -0
- package/src/modules/agent_orchestrator/components/cockpitStatus.tsx +154 -0
- package/src/modules/agent_orchestrator/components/evalRunTypes.ts +339 -0
- package/src/modules/agent_orchestrator/components/health/HealthRow.tsx +36 -0
- package/src/modules/agent_orchestrator/components/health/HealthStateBadge.tsx +21 -0
- package/src/modules/agent_orchestrator/components/health/SystemHealthPanel.tsx +206 -0
- package/src/modules/agent_orchestrator/components/health/vocabulary.ts +53 -0
- package/src/modules/agent_orchestrator/components/optionalRequest.ts +18 -0
- package/src/modules/agent_orchestrator/components/playgroundRunError.ts +63 -0
- package/src/modules/agent_orchestrator/components/playgroundToolCalls.ts +32 -0
- package/src/modules/agent_orchestrator/components/processTypes.ts +613 -0
- package/src/modules/agent_orchestrator/components/proposalCaseStatus.ts +100 -0
- package/src/modules/agent_orchestrator/components/proposalEdit.ts +118 -0
- package/src/modules/agent_orchestrator/components/proposalFactsData.ts +222 -0
- package/src/modules/agent_orchestrator/components/serverSort.ts +56 -0
- package/src/modules/agent_orchestrator/components/subjectRef.ts +61 -0
- package/src/modules/agent_orchestrator/components/types.ts +834 -0
- package/src/modules/agent_orchestrator/components/useAgentIcons.ts +42 -0
- package/src/modules/agent_orchestrator/components/useAgentLabels.ts +44 -0
- package/src/modules/agent_orchestrator/components/useAgentTags.ts +38 -0
- package/src/modules/agent_orchestrator/components/useCoalescedReload.ts +43 -0
- package/src/modules/agent_orchestrator/data/agentIcons.ts +52 -0
- package/src/modules/agent_orchestrator/data/agentTags.ts +39 -0
- package/src/modules/agent_orchestrator/data/entities.ts +1904 -0
- package/src/modules/agent_orchestrator/data/proposalEnvelope.ts +263 -0
- package/src/modules/agent_orchestrator/data/validators.ts +1585 -0
- package/src/modules/agent_orchestrator/di.ts +182 -0
- package/src/modules/agent_orchestrator/encryption.ts +98 -0
- package/src/modules/agent_orchestrator/events.ts +97 -0
- package/src/modules/agent_orchestrator/examples/deals-health-check-workflow.json +124 -0
- package/src/modules/agent_orchestrator/examples/refund-triage-workflow.json +210 -0
- package/src/modules/agent_orchestrator/generated/file-agents.generated.ts +207 -0
- package/src/modules/agent_orchestrator/i18n/.hardcoded-allowlist.json +22 -0
- package/src/modules/agent_orchestrator/i18n/de.json +1495 -0
- package/src/modules/agent_orchestrator/i18n/en.json +1495 -0
- package/src/modules/agent_orchestrator/i18n/es.json +1495 -0
- package/src/modules/agent_orchestrator/i18n/ko.json +1495 -0
- package/src/modules/agent_orchestrator/i18n/pl.json +1495 -0
- package/src/modules/agent_orchestrator/index.ts +155 -0
- package/src/modules/agent_orchestrator/lib/automationLinks.ts +20 -0
- package/src/modules/agent_orchestrator/lib/context/contextResolver.ts +528 -0
- package/src/modules/agent_orchestrator/lib/context/documentIngest.ts +187 -0
- package/src/modules/agent_orchestrator/lib/context/documentOcrProvider.ts +189 -0
- package/src/modules/agent_orchestrator/lib/context/documentSource.ts +88 -0
- package/src/modules/agent_orchestrator/lib/context/index.ts +68 -0
- package/src/modules/agent_orchestrator/lib/context/packer.ts +114 -0
- package/src/modules/agent_orchestrator/lib/context/redactor.ts +138 -0
- package/src/modules/agent_orchestrator/lib/context/registry.ts +153 -0
- package/src/modules/agent_orchestrator/lib/context/retrievalSource.ts +146 -0
- package/src/modules/agent_orchestrator/lib/crudCache.ts +62 -0
- package/src/modules/agent_orchestrator/lib/disposition/autoApprovalPolicy.ts +163 -0
- package/src/modules/agent_orchestrator/lib/disposition/dispositionService.ts +310 -0
- package/src/modules/agent_orchestrator/lib/disposition/resume.ts +81 -0
- package/src/modules/agent_orchestrator/lib/disposition/tenantAutoApprovalPolicy.ts +100 -0
- package/src/modules/agent_orchestrator/lib/eval/assertionResolution.ts +105 -0
- package/src/modules/agent_orchestrator/lib/eval/canonicalInputKey.ts +32 -0
- package/src/modules/agent_orchestrator/lib/eval/defaultAssertions.ts +103 -0
- package/src/modules/agent_orchestrator/lib/eval/evalGate.ts +139 -0
- package/src/modules/agent_orchestrator/lib/eval/evalReplayService.ts +517 -0
- package/src/modules/agent_orchestrator/lib/eval/evalRuntimeService.ts +215 -0
- package/src/modules/agent_orchestrator/lib/eval/judgeRubric.ts +212 -0
- package/src/modules/agent_orchestrator/lib/eval/llmJudge.ts +174 -0
- package/src/modules/agent_orchestrator/lib/eval/projectRunView.ts +53 -0
- package/src/modules/agent_orchestrator/lib/eval/registry/agent.ts +334 -0
- package/src/modules/agent_orchestrator/lib/eval/registry/economics.ts +91 -0
- package/src/modules/agent_orchestrator/lib/eval/registry/index.ts +157 -0
- package/src/modules/agent_orchestrator/lib/eval/registry/judge.ts +102 -0
- package/src/modules/agent_orchestrator/lib/eval/registry/shared.ts +208 -0
- package/src/modules/agent_orchestrator/lib/eval/registry/structured.ts +297 -0
- package/src/modules/agent_orchestrator/lib/eval/registry/text.ts +125 -0
- package/src/modules/agent_orchestrator/lib/eval/registry/tools.ts +263 -0
- package/src/modules/agent_orchestrator/lib/eval/sampling.ts +33 -0
- package/src/modules/agent_orchestrator/lib/eval/scorers.ts +90 -0
- package/src/modules/agent_orchestrator/lib/eval/types.ts +189 -0
- package/src/modules/agent_orchestrator/lib/featureFlags.ts +22 -0
- package/src/modules/agent_orchestrator/lib/guardrails/grounding.ts +172 -0
- package/src/modules/agent_orchestrator/lib/guardrails/groundingSets.ts +61 -0
- package/src/modules/agent_orchestrator/lib/guardrails/guardrailService.ts +293 -0
- package/src/modules/agent_orchestrator/lib/guardrails/promptInjection.ts +163 -0
- package/src/modules/agent_orchestrator/lib/guardrails/publicEndpointRateLimit.ts +74 -0
- package/src/modules/agent_orchestrator/lib/guardrails/syncGroundingSets.ts +68 -0
- package/src/modules/agent_orchestrator/lib/identity/agentAuthMdService.ts +247 -0
- package/src/modules/agent_orchestrator/lib/identity/agentDelegationGrantService.ts +85 -0
- package/src/modules/agent_orchestrator/lib/identity/agentNoBypassSubscriber.ts +98 -0
- package/src/modules/agent_orchestrator/lib/identity/agentPrincipalService.ts +230 -0
- package/src/modules/agent_orchestrator/lib/identity/agentTokenService.ts +281 -0
- package/src/modules/agent_orchestrator/lib/identity/agentWriteScope.ts +68 -0
- package/src/modules/agent_orchestrator/lib/metrics/metricRollupService.ts +168 -0
- package/src/modules/agent_orchestrator/lib/processes/executionSearch.ts +35 -0
- package/src/modules/agent_orchestrator/lib/processes/materializeAgentWorkflow.ts +320 -0
- package/src/modules/agent_orchestrator/lib/processes/processProjection.ts +401 -0
- package/src/modules/agent_orchestrator/lib/processes/subjectContext.ts +30 -0
- package/src/modules/agent_orchestrator/lib/processes/workflowGrant.ts +84 -0
- package/src/modules/agent_orchestrator/lib/queue.ts +56 -0
- package/src/modules/agent_orchestrator/lib/runtime/actionVocabulary.ts +127 -0
- package/src/modules/agent_orchestrator/lib/runtime/admission.ts +177 -0
- package/src/modules/agent_orchestrator/lib/runtime/agentRunSessionStore.ts +166 -0
- package/src/modules/agent_orchestrator/lib/runtime/agentRuntime.ts +108 -0
- package/src/modules/agent_orchestrator/lib/runtime/agentWorkspaceManager.ts +187 -0
- package/src/modules/agent_orchestrator/lib/runtime/artifactCollector.ts +188 -0
- package/src/modules/agent_orchestrator/lib/runtime/artifactFileStore.ts +189 -0
- package/src/modules/agent_orchestrator/lib/runtime/attachmentStager.ts +100 -0
- package/src/modules/agent_orchestrator/lib/runtime/errors.ts +63 -0
- package/src/modules/agent_orchestrator/lib/runtime/executeProposal.ts +78 -0
- package/src/modules/agent_orchestrator/lib/runtime/fileAgentSkills.ts +81 -0
- package/src/modules/agent_orchestrator/lib/runtime/fileInput.ts +44 -0
- package/src/modules/agent_orchestrator/lib/runtime/invokeAgentForWorkflow.ts +255 -0
- package/src/modules/agent_orchestrator/lib/runtime/modelPricing.ts +146 -0
- package/src/modules/agent_orchestrator/lib/runtime/nativeAgentRunner.ts +617 -0
- package/src/modules/agent_orchestrator/lib/runtime/nativeTraceCapture.ts +217 -0
- package/src/modules/agent_orchestrator/lib/runtime/openCodeAgentRunner.ts +889 -0
- package/src/modules/agent_orchestrator/lib/runtime/persistence.ts +314 -0
- package/src/modules/agent_orchestrator/lib/runtime/providerBudget.ts +230 -0
- package/src/modules/agent_orchestrator/lib/runtime/rerunContext.ts +26 -0
- package/src/modules/agent_orchestrator/lib/runtime/runContext.ts +47 -0
- package/src/modules/agent_orchestrator/lib/runtime/sandboxedScript.ts +106 -0
- package/src/modules/agent_orchestrator/lib/sdk/agentMarkdown.ts +157 -0
- package/src/modules/agent_orchestrator/lib/sdk/agentOutcomeContract.ts +58 -0
- package/src/modules/agent_orchestrator/lib/sdk/defineAgent.ts +525 -0
- package/src/modules/agent_orchestrator/lib/sdk/defineFileAgent.ts +765 -0
- package/src/modules/agent_orchestrator/lib/sdk/defineSkill.ts +80 -0
- package/src/modules/agent_orchestrator/lib/sdk/outcomeSchema.ts +190 -0
- package/src/modules/agent_orchestrator/lib/sdk/skillMarkdown.ts +139 -0
- package/src/modules/agent_orchestrator/lib/seeds.ts +335 -0
- package/src/modules/agent_orchestrator/lib/settings/agentSettings.ts +92 -0
- package/src/modules/agent_orchestrator/lib/systemHealth.ts +212 -0
- package/src/modules/agent_orchestrator/lib/tasks/eventTriggerMatch.ts +116 -0
- package/src/modules/agent_orchestrator/lib/tasks/milestones.ts +201 -0
- package/src/modules/agent_orchestrator/lib/tasks/outcome.ts +93 -0
- package/src/modules/agent_orchestrator/lib/tasks/outcomeLink.ts +91 -0
- package/src/modules/agent_orchestrator/lib/tasks/schedule.ts +106 -0
- package/src/modules/agent_orchestrator/lib/tasks/scheduleValidation.ts +34 -0
- package/src/modules/agent_orchestrator/lib/tasks/triggers.ts +47 -0
- package/src/modules/agent_orchestrator/lib/tokens/computeAgentTokenUsage.ts +111 -0
- package/src/modules/agent_orchestrator/lib/tokens/types.ts +77 -0
- package/src/modules/agent_orchestrator/lib/trace/artifactStore.ts +198 -0
- package/src/modules/agent_orchestrator/lib/trace/correctionService.ts +117 -0
- package/src/modules/agent_orchestrator/lib/trace/ingestAuth.ts +65 -0
- package/src/modules/agent_orchestrator/lib/trace/redactToolSummary.ts +76 -0
- package/src/modules/agent_orchestrator/lib/trace/spanTimeline.ts +181 -0
- package/src/modules/agent_orchestrator/lib/trace/traceIngestionService.ts +250 -0
- package/src/modules/agent_orchestrator/lib/webSearch/guardrails.ts +199 -0
- package/src/modules/agent_orchestrator/lib/webSearch/healthCache.ts +109 -0
- package/src/modules/agent_orchestrator/lib/webSearch/healthProbePlan.ts +58 -0
- package/src/modules/agent_orchestrator/lib/webSearch/policy.ts +283 -0
- package/src/modules/agent_orchestrator/lib/webSearch/registry.ts +177 -0
- package/src/modules/agent_orchestrator/lib/webSearch/secretStorage.ts +181 -0
- package/src/modules/agent_orchestrator/lib/webSearch/steps.ts +77 -0
- package/src/modules/agent_orchestrator/lib/webSearch/tools.ts +246 -0
- package/src/modules/agent_orchestrator/lib/workInbox/agentDispositionSource.ts +324 -0
- package/src/modules/agent_orchestrator/migrations/.snapshot-open-mercato.json +7083 -0
- package/src/modules/agent_orchestrator/migrations/Migration20260906141535_agent_orchestrator.ts +278 -0
- package/src/modules/agent_orchestrator/migrations/adopt-squash.mjs +232 -0
- package/src/modules/agent_orchestrator/notifications.ts +43 -0
- package/src/modules/agent_orchestrator/setup.ts +190 -0
- package/src/modules/agent_orchestrator/skills/deals.stage_playbook.md +37 -0
- package/src/modules/agent_orchestrator/subscribers/process-event-trigger.ts +198 -0
- package/src/modules/agent_orchestrator/subscribers/process-proposal-created.ts +28 -0
- package/src/modules/agent_orchestrator/subscribers/process-proposal-disposed.ts +20 -0
- package/src/modules/agent_orchestrator/subscribers/process-run-completed.ts +23 -0
- package/src/modules/agent_orchestrator/subscribers/process-run-ingested.ts +22 -0
- package/src/modules/agent_orchestrator/subscribers/process-workflow-cancelled.ts +22 -0
- package/src/modules/agent_orchestrator/subscribers/process-workflow-completed.ts +32 -0
- package/src/modules/agent_orchestrator/subscribers/process-workflow-failed.ts +23 -0
- package/src/modules/agent_orchestrator/subscribers/process-workflow-milestone.ts +47 -0
- package/src/modules/agent_orchestrator/subscribers/process-workflow-started.ts +34 -0
- package/src/modules/agent_orchestrator/subscribers/proposal-disposed-notification-clear.ts +50 -0
- package/src/modules/agent_orchestrator/subscribers/proposal-pending-notification.ts +84 -0
- package/src/modules/agent_orchestrator/widgets/injection/caseload-nav-badge/widget.client.tsx +68 -0
- package/src/modules/agent_orchestrator/widgets/injection/caseload-nav-badge/widget.ts +16 -0
- package/src/modules/agent_orchestrator/widgets/injection/task-proposal-draft/widget.client.tsx +148 -0
- package/src/modules/agent_orchestrator/widgets/injection/task-proposal-draft/widget.ts +24 -0
- package/src/modules/agent_orchestrator/widgets/injection/task-proposal-link/widget.ts +34 -0
- package/src/modules/agent_orchestrator/widgets/injection-table.ts +42 -0
- package/src/modules/agent_orchestrator/workers/eval-suite-runner.ts +85 -0
- package/src/modules/agent_orchestrator/workers/llm-judge.ts +39 -0
- package/src/modules/agent_orchestrator/workers/metric-rollup.ts +39 -0
- package/src/modules/agent_orchestrator/workers/process-execution-starter.ts +227 -0
- package/src/modules/record_locks/lib/conflictValues.ts +107 -0
- package/src/modules/record_locks/lib/crudMutationGuardService.ts +47 -3
- package/src/modules/record_locks/lib/recordLockService.ts +1 -51
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
{
|
|
2
|
+
"version": 3,
|
|
3
|
+
"sources": ["../../../src/modules/agent_orchestrator/ai-tools.ts"],
|
|
4
|
+
"sourcesContent": ["import { z } from 'zod'\nimport { defineAiTool } from '@open-mercato/ai-assistant/modules/ai_assistant/lib/ai-tool-definition'\nimport type { AiToolDefinition, McpToolContext } from '@open-mercato/ai-assistant/modules/ai_assistant/lib/types'\nimport { DELEGATE_TOOL_ID, getAgentEntry, ensureAgentsLoaded } from './lib/sdk/defineAgent'\nimport type { AgentRuntimeService } from './lib/runtime/agentRuntime'\nimport type { AgentRunSessionStore } from './lib/runtime/agentRunSessionStore'\nimport { getAgentSkill, getAgentSkillScript } from './lib/runtime/fileAgentSkills'\nimport { runSandboxedScript } from './lib/runtime/sandboxedScript'\nimport { getCurrentRunId, getCurrentRunSource } from './lib/runtime/runContext'\nimport { webSearchTool, webFetchTool } from './lib/webSearch/tools'\n\n/** Tool id of the OUTCOME-submission tool an OpenCode file-agent finishes with. */\nexport const SUBMIT_OUTCOME_TOOL_ID = 'agent_orchestrator.submit_outcome'\n\n/** Tool id of the skill progressive-disclosure fallback (native skills preferred). */\nexport const LOAD_SKILL_TOOL_ID = 'agent_orchestrator.load_skill'\n\n/** Tool id of the sandboxed skill-script / local-tool runner (Phase 5). */\nexport const RUN_SKILL_SCRIPT_TOOL_ID = 'agent_orchestrator.run_skill_script'\n\nconst delegateInput = z.object({\n agentId: z.string().min(1).describe('Id of the sub-agent to run (must be a researcher agent).'),\n input: z.unknown().describe('Input payload passed to the sub-agent (shape is sub-agent specific).'),\n})\n\n/** Default wall-clock budget for a delegated sub-agent run (ms) \u2014 deliberately far\n * below the top-level `OM_OPENCODE_RUN_TIMEOUT_MS` so a hung sub-agent tool (e.g. a\n * wedged web_search navigation) fails fast and returns an error to the orchestrator\n * instead of blocking it for the full top-level deadline. */\nconst DEFAULT_DELEGATE_RUN_TIMEOUT_MS = 3 * 60_000\n\n/** Resolve the delegated-run wall-clock budget from `OM_AGENT_DELEGATE_RUN_TIMEOUT_MS`,\n * falling back to {@link DEFAULT_DELEGATE_RUN_TIMEOUT_MS}. A non-positive/NaN override is ignored. */\nfunction resolveDelegateRunTimeoutMs(): number {\n const raw = process.env.OM_AGENT_DELEGATE_RUN_TIMEOUT_MS\n if (raw != null && raw !== '') {\n const parsed = Number(raw)\n if (Number.isFinite(parsed) && parsed > 0) return parsed\n }\n return DEFAULT_DELEGATE_RUN_TIMEOUT_MS\n}\n\n/**\n * Resolve the parent run id from the caller's run session when the in-process\n * run context is absent. On the OpenCode path this tool runs in the separate\n * `mcp:serve-http` process where `getCurrentRunId()` is always undefined, so the\n * nested-run `parent_run_id` trace link would be lost. Mirrors how\n * `submit_outcome` (this file) and `lib/webSearch/guardrails.ts` resolve the run\n * from the session token via `agentRunSessionStore`. Never throws \u2014 a missing\n * session or an unresolvable store yields `undefined` (a top-level nested run).\n */\nasync function resolveParentRunIdFromSession(ctx: McpToolContext): Promise<string | undefined> {\n const sessionToken = ctx.sessionId\n if (!sessionToken) return undefined\n try {\n const store = ctx.container.resolve('agentRunSessionStore') as AgentRunSessionStore\n return (await store.resolveActiveRunId(sessionToken)) ?? undefined\n } catch {\n return undefined\n }\n}\n\n/**\n * Sub-agent-as-tool: lets a parent agent run another agent as a read-only\n * sub-agent and fan several out in parallel (the model emits multiple calls in\n * one step; the SDK runs them concurrently). Propose-only is preserved:\n *\n * - the tool is `isMutation: false` \u2014 never gated, never a write;\n * - the target MUST be an `researcher` agent (sub-agents inform; only the\n * parent proposes), so no nested proposals are created;\n * - the target may NOT itself delegate (no `subAgents`), which caps tree depth\n * at one and prevents cycles;\n * - the sub-agent runs under the SAME caller scope/ACL \u2014 never escalated.\n *\n * Errors are returned as data (`{ ok: false }`) so one failed sub-task never\n * crashes the parent loop.\n */\nconst delegateAgentTool: AiToolDefinition = {\n name: DELEGATE_TOOL_ID,\n displayName: 'Delegate to sub-agent',\n description:\n 'Run another agent as a read-only sub-agent and return its result. Only researcher, non-delegating agents may be targeted. Call multiple times in one step to fan out in parallel.',\n inputSchema: delegateInput,\n requiredFeatures: ['agent_orchestrator.agents.run'],\n isMutation: false,\n tags: ['read', 'agent_orchestrator'],\n async handler(rawInput, ctx) {\n const { agentId, input } = delegateInput.parse(rawInput)\n if (!ctx.tenantId || !ctx.organizationId || !ctx.userId) {\n return { ok: false as const, agentId, error: 'missing tenant/org/user scope' }\n }\n\n await ensureAgentsLoaded()\n const entry = getAgentEntry(agentId)\n if (!entry) {\n return { ok: false as const, agentId, error: `unknown sub-agent \"${agentId}\"` }\n }\n if (entry.resultKind !== 'research') {\n return { ok: false as const, agentId, error: 'only research sub-agents may be delegated to' }\n }\n if (entry.subAgents.length > 0) {\n return { ok: false as const, agentId, error: 'sub-agents may not delegate further (depth capped at 1)' }\n }\n\n try {\n const agentRuntime = ctx.container.resolve('agentRuntime') as AgentRuntimeService\n // The parent run is the in-process run currently executing (bound via the\n // run-context AsyncLocalStorage); pass its id so the nested sub-agent run\n // records `parent_run_id` for traceability (Phase 4). On the OpenCode path\n // this tool runs in the separate mcp:serve-http process where that async\n // context is never set \u2014 fall back to the cross-process correlation store,\n // resolving the parent run from THIS run's session token. Undefined when\n // neither resolves (the nested run is then a top-level run).\n const parentRunId = getCurrentRunId() ?? (await resolveParentRunIdFromSession(ctx))\n const delegatedSource = getCurrentRunSource()\n const result = await agentRuntime.run(agentId, input, {\n tenantId: ctx.tenantId,\n organizationId: ctx.organizationId,\n userId: ctx.userId,\n // Bound the delegated run well below the top-level budget so a hung\n // sub-agent tool (e.g. a wedged web_search navigation) fails fast and\n // returns an error to the orchestrator instead of blocking it for an hour.\n runTimeoutMs: resolveDelegateRunTimeoutMs(),\n ...(parentRunId ? { parentRunId } : {}),\n // Inherit the parent's origin so an eval replay's sub-agent runs are not\n // counted as production traffic in the agent's metric rollups.\n ...(delegatedSource ? { source: delegatedSource } : {}),\n })\n // Whatever the sub-agent produced, handed back verbatim under its own key:\n // the orchestrator reads a finding, an intent and a file list differently,\n // and flattening them here would make them indistinguishable.\n const data =\n result.kind === 'research'\n ? result.data\n : result.kind === 'proposal'\n ? result.proposal\n : { artifacts: result.artifacts, summary: result.summary }\n return { ok: true as const, agentId, data }\n } catch (err) {\n const message = err instanceof Error ? err.message : String(err)\n return { ok: false as const, agentId, error: message }\n }\n },\n}\n\nconst submitOutcomeInput = z.object({\n outcome: z\n .unknown()\n .describe(\n 'The structured result, matching the active agent OUTCOME contract. The active agent and its schema are resolved server-side from the run session \u2014 never trusted from this call.',\n ),\n // File plane (#12): ADVISORY captions for files the agent wrote into the sandbox\n // `out/` dir. Additive + optional (existing single-`outcome` callers stay valid).\n // The collector is FILESYSTEM-authoritative: it captures whatever is on disk and\n // uses these only to attach a caption (matched by relative path) \u2014 it never\n // trusts this list to invent, hide, or rename a file.\n artifacts: z\n .array(\n z.object({\n path: z.string().max(255).describe('Path of the produced file, relative to the sandbox out/ dir.'),\n caption: z.string().max(500).optional().describe('Short human description of the file.'),\n }),\n )\n .max(20)\n .optional()\n .describe('Optional captions for files written to the sandbox out/ directory.'),\n})\n\n/**\n * Terminal tool an OpenCode file-agent calls to deliver its structured result.\n *\n * The active agent id is resolved from the cross-process correlation store keyed\n * by THIS run's session token (`ctx.sessionId`, which the MCP HTTP server sets to\n * the session token the runner minted) \u2014 NOT trusted from the model. The store is\n * DB-backed because the runner and this tool run in different processes. The\n * agent's compiled OUTCOME schema is read from the registry; the submitted\n * `outcome` is validated against it:\n *\n * - valid \u2192 written to the store; the polling runner reads it back. `{ ok: true }`.\n * - invalid \u2192 `{ ok: false, code: 'outcome_invalid', errors }` so OpenCode/the\n * agent can correct and retry (NOT thrown). A non-JSON string is the\n * same: parsed first, then validated.\n * - missing/stale correlation (no run for this session, or already completed)\n * \u2192 `{ ok: false, code: 'no_active_run' }`.\n *\n * Propose-only: `isMutation: false` \u2014 the only state this ever produces is the\n * AgentRun/AgentProposal the runner persists from the captured outcome.\n */\nconst submitOutcomeTool: AiToolDefinition = {\n name: SUBMIT_OUTCOME_TOOL_ID,\n displayName: 'Submit agent outcome',\n description:\n 'Finish the current agent run by submitting its structured outcome (as the `outcome` argument object). The server validates it against the agent OUTCOME contract; on failure it returns the validation errors so you can correct and resubmit.',\n inputSchema: submitOutcomeInput,\n requiredFeatures: ['agent_orchestrator.agents.run'],\n isMutation: false,\n tags: ['read', 'agent_orchestrator'],\n async handler(rawInput, ctx) {\n const { outcome } = submitOutcomeInput.parse(rawInput)\n const sessionToken = ctx.sessionId\n if (!sessionToken) {\n return { ok: false as const, code: 'no_active_run' as const, error: 'no run session in context' }\n }\n const store = ctx.container.resolve('agentRunSessionStore') as AgentRunSessionStore\n const agentId = await store.resolveActiveAgentId(sessionToken)\n if (!agentId) {\n return { ok: false as const, code: 'no_active_run' as const, error: 'no active run for this session' }\n }\n await ensureAgentsLoaded()\n const entry = getAgentEntry(agentId)\n if (!entry) {\n return { ok: false as const, code: 'no_active_run' as const, error: 'active agent is no longer registered' }\n }\n // Models sometimes pass the outcome as a JSON STRING \u2014 parse it before validating.\n let outcomeValue = outcome\n if (typeof outcomeValue === 'string') {\n try {\n outcomeValue = JSON.parse(outcomeValue)\n } catch {\n return {\n ok: false as const,\n code: 'outcome_invalid' as const,\n errors: [{ path: '', message: 'outcome must be a JSON object, not an unparseable string' }],\n }\n }\n }\n const parsed = entry.schema.safeParse(outcomeValue)\n if (!parsed.success) {\n return {\n ok: false as const,\n code: 'outcome_invalid' as const,\n errors: parsed.error.issues.map((issue) => ({\n path: issue.path.join('.'),\n message: issue.message,\n })),\n }\n }\n const completion = await store.completeOutcome(sessionToken, parsed.data)\n if (completion !== 'completed') {\n // not_found (run gone) or already_completed \u2192 nothing more to capture.\n return { ok: false as const, code: 'no_active_run' as const, error: `run ${completion}` }\n }\n return { ok: true as const }\n },\n}\n\nconst loadSkillInput = z.object({\n skillId: z\n .string()\n .min(1)\n .describe('Id of the skill to load. Must be one of the active agent allowed skills.'),\n})\n\n/**\n * Progressive-disclosure FALLBACK for agent-local skills. Native OpenCode skills\n * (generated `SKILL.md` files) are the primary path; this MCP tool returns a\n * skill's full content on demand AND carries TEMPLATE.md/examples that native\n * skills may not bundle.\n *\n * The allowed skill set is the ACTIVE agent's skills \u2014 resolved from the per-run\n * correlation store keyed by THIS run's session token (`ctx.sessionId`) \u2014 NEVER\n * trusted from the model. Outcomes:\n *\n * - missing/stale correlation (no run for this session) \u2192 `{ ok:false, code:'no_active_run' }`.\n * - skillId not registered for the active agent \u2192 `{ ok:false, code:'skill_not_allowed' }`.\n * - otherwise \u2192 `{ ok:true, instructions, template?, examples }`.\n *\n * Propose-only: `isMutation:false` \u2014 it only reads skill content.\n */\nconst loadSkillTool: AiToolDefinition = {\n name: LOAD_SKILL_TOOL_ID,\n displayName: 'Load agent skill',\n description:\n 'Load the full instructions (and optional template + examples) of one of the current agent skills, by skill id.',\n inputSchema: loadSkillInput,\n requiredFeatures: ['agent_orchestrator.agents.run'],\n isMutation: false,\n tags: ['read', 'agent_orchestrator'],\n async handler(rawInput, ctx) {\n const { skillId } = loadSkillInput.parse(rawInput)\n const sessionToken = ctx.sessionId\n if (!sessionToken) {\n return { ok: false as const, code: 'no_active_run' as const, error: 'no run session in context' }\n }\n const store = ctx.container.resolve('agentRunSessionStore') as AgentRunSessionStore\n const agentId = await store.resolveActiveAgentId(sessionToken)\n if (!agentId) {\n return { ok: false as const, code: 'no_active_run' as const, error: 'no active run for this session' }\n }\n // Populate the file-agent skill registry before resolving \u2014 on a fresh\n // process this tool can be the first agent_orchestrator call, so the\n // registry would otherwise be empty and reject a valid skill.\n await ensureAgentsLoaded()\n const skill = getAgentSkill(agentId, skillId)\n if (!skill) {\n return {\n ok: false as const,\n code: 'skill_not_allowed' as const,\n error: `skill \"${skillId}\" is not available to the active agent`,\n }\n }\n return {\n ok: true as const,\n instructions: skill.instructions,\n ...(skill.template != null ? { template: skill.template } : {}),\n examples: skill.examples,\n }\n },\n}\n\nconst runSkillScriptInput = z.object({\n skillId: z\n .string()\n .min(1)\n .describe('Id of the skill the script belongs to (one of the current agent skills).'),\n scriptName: z\n .string()\n .min(1)\n .describe('Script basename without extension (e.g. `scripts/score.ts` \u2192 \"score\").'),\n args: z.unknown().optional().describe('Arguments passed to the script `run(args)` function.'),\n})\n\n/**\n * Run one of the active agent's sandboxed helper scripts (Phase 5) \u2014 a skill\n * `scripts/<name>.ts` or a local tool file (carried under the synthetic\n * `__agent_tools__` skill id) \u2014 and return its value.\n *\n * The active agent + its allowed skill/script set are resolved server-side from\n * the per-run correlation store (`ctx.sessionId`) \u2014 NEVER trusted from the model.\n * The script source runs in the Code Mode `isolated-vm` sandbox: no fs/net/\n * imports, a hard 30s cap, and per-call ACL via `requiredFeatures` + the session\n * token. A script is a pure function of its `args`, so this stays propose-only \u2014\n * it can compute, not mutate. Errors are returned as data, never thrown.\n */\nconst runSkillScriptTool: AiToolDefinition = {\n name: RUN_SKILL_SCRIPT_TOOL_ID,\n displayName: 'Run agent skill script',\n description:\n 'Run one of the current agent sandboxed helper scripts by skill id + script name and return its result. Scripts are pure functions of their args (no fs/net/side effects) executed in a sandbox.',\n inputSchema: runSkillScriptInput,\n requiredFeatures: ['agent_orchestrator.agents.run'],\n isMutation: false,\n tags: ['read', 'agent_orchestrator'],\n async handler(rawInput, ctx) {\n const { skillId, scriptName, args } = runSkillScriptInput.parse(rawInput)\n const sessionToken = ctx.sessionId\n if (!sessionToken) {\n return { ok: false as const, code: 'no_active_run' as const, error: 'no run session in context' }\n }\n const store = ctx.container.resolve('agentRunSessionStore') as AgentRunSessionStore\n const agentId = await store.resolveActiveAgentId(sessionToken)\n if (!agentId) {\n return { ok: false as const, code: 'no_active_run' as const, error: 'no active run for this session' }\n }\n // Populate the file-agent skill registry before resolving \u2014 on a fresh\n // process this tool can be the first agent_orchestrator call, so the\n // registry would otherwise be empty and reject a valid skill/script.\n await ensureAgentsLoaded()\n if (!getAgentSkill(agentId, skillId)) {\n return {\n ok: false as const,\n code: 'skill_not_allowed' as const,\n error: `skill \"${skillId}\" is not available to the active agent`,\n }\n }\n const script = getAgentSkillScript(agentId, skillId, scriptName)\n if (!script) {\n return {\n ok: false as const,\n code: 'script_not_found' as const,\n error: `script \"${scriptName}\" not found in skill \"${skillId}\"`,\n }\n }\n const outcome = await runSandboxedScript({ source: script.source, args })\n if (!outcome.ok) {\n return { ok: false as const, code: outcome.code, error: outcome.error }\n }\n return { ok: true as const, result: outcome.result }\n },\n}\n\nexport const aiTools: AiToolDefinition[] = [\n delegateAgentTool,\n submitOutcomeTool,\n loadSkillTool,\n runSkillScriptTool,\n webSearchTool,\n webFetchTool,\n]\n\nexport default aiTools\n"],
|
|
5
|
+
"mappings": "AAAA,SAAS,SAAS;AAGlB,SAAS,kBAAkB,eAAe,0BAA0B;AAGpE,SAAS,eAAe,2BAA2B;AACnD,SAAS,0BAA0B;AACnC,SAAS,iBAAiB,2BAA2B;AACrD,SAAS,eAAe,oBAAoB;AAGrC,MAAM,yBAAyB;AAG/B,MAAM,qBAAqB;AAG3B,MAAM,2BAA2B;AAExC,MAAM,gBAAgB,EAAE,OAAO;AAAA,EAC7B,SAAS,EAAE,OAAO,EAAE,IAAI,CAAC,EAAE,SAAS,0DAA0D;AAAA,EAC9F,OAAO,EAAE,QAAQ,EAAE,SAAS,sEAAsE;AACpG,CAAC;AAMD,MAAM,kCAAkC,IAAI;AAI5C,SAAS,8BAAsC;AAC7C,QAAM,MAAM,QAAQ,IAAI;AACxB,MAAI,OAAO,QAAQ,QAAQ,IAAI;AAC7B,UAAM,SAAS,OAAO,GAAG;AACzB,QAAI,OAAO,SAAS,MAAM,KAAK,SAAS,EAAG,QAAO;AAAA,EACpD;AACA,SAAO;AACT;AAWA,eAAe,8BAA8B,KAAkD;AAC7F,QAAM,eAAe,IAAI;AACzB,MAAI,CAAC,aAAc,QAAO;AAC1B,MAAI;AACF,UAAM,QAAQ,IAAI,UAAU,QAAQ,sBAAsB;AAC1D,WAAQ,MAAM,MAAM,mBAAmB,YAAY,KAAM;AAAA,EAC3D,QAAQ;AACN,WAAO;AAAA,EACT;AACF;AAiBA,MAAM,oBAAsC;AAAA,EAC1C,MAAM;AAAA,EACN,aAAa;AAAA,EACb,aACE;AAAA,EACF,aAAa;AAAA,EACb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EAAE,IAAI,OAAgB,MAAM,iBAA0B,OAAO,4BAA4B;AAAA,IAClG;AACA,UAAM,QAAQ,IAAI,UAAU,QAAQ,sBAAsB;AAC1D,UAAM,UAAU,MAAM,MAAM,qBAAqB,YAAY;AAC7D,QAAI,CAAC,SAAS;AACZ,aAAO,EAAE,IAAI,OAAgB,MAAM,iBAA0B,OAAO,iCAAiC;AAAA,IACvG;AAIA,UAAM,mBAAmB;AACzB,QAAI,CAAC,cAAc,SAAS,OAAO,GAAG;AACpC,aAAO;AAAA,QACL,IAAI;AAAA,QACJ,MAAM;AAAA,QACN,OAAO,UAAU,OAAO;AAAA,MAC1B;AAAA,IACF;AACA,UAAM,SAAS,oBAAoB,SAAS,SAAS,UAAU;AAC/D,QAAI,CAAC,QAAQ;AACX,aAAO;AAAA,QACL,IAAI;AAAA,QACJ,MAAM;AAAA,QACN,OAAO,WAAW,UAAU,yBAAyB,OAAO;AAAA,MAC9D;AAAA,IACF;AACA,UAAM,UAAU,MAAM,mBAAmB,EAAE,QAAQ,OAAO,QAAQ,KAAK,CAAC;AACxE,QAAI,CAAC,QAAQ,IAAI;AACf,aAAO,EAAE,IAAI,OAAgB,MAAM,QAAQ,MAAM,OAAO,QAAQ,MAAM;AAAA,IACxE;AACA,WAAO,EAAE,IAAI,MAAe,QAAQ,QAAQ,OAAO;AAAA,EACrD;AACF;AAEO,MAAM,UAA8B;AAAA,EACzC;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AACF;AAEA,IAAO,mBAAQ;",
|
|
6
|
+
"names": []
|
|
7
|
+
}
|
|
@@ -0,0 +1,69 @@
|
|
|
1
|
+
import { NextResponse } from "next/server";
|
|
2
|
+
import { z } from "zod";
|
|
3
|
+
import { getAuthFromRequest } from "@open-mercato/shared/lib/auth/server";
|
|
4
|
+
import { getAgentEntry, ensureAgentsLoaded } from "../../../../lib/sdk/defineAgent.js";
|
|
5
|
+
const metadata = {
|
|
6
|
+
GET: { requireAuth: true, requireFeatures: ["agent_orchestrator.agents.view"] }
|
|
7
|
+
};
|
|
8
|
+
const sourceFileSchema = z.object({
|
|
9
|
+
path: z.string(),
|
|
10
|
+
content: z.string(),
|
|
11
|
+
tokens: z.number(),
|
|
12
|
+
inContext: z.boolean()
|
|
13
|
+
});
|
|
14
|
+
const tokenizedFileSchema = z.object({ path: z.string(), tokens: z.number() });
|
|
15
|
+
const tokenUsageSchema = z.object({
|
|
16
|
+
total: z.number(),
|
|
17
|
+
self: z.number(),
|
|
18
|
+
agent: z.number(),
|
|
19
|
+
outcome: z.number(),
|
|
20
|
+
skills: z.array(z.object({ id: z.string(), tokens: z.number(), files: z.array(tokenizedFileSchema) })),
|
|
21
|
+
tools: z.array(z.object({ name: z.string(), path: z.string(), tokens: z.number() })),
|
|
22
|
+
subAgents: z.array(z.object({ id: z.string(), tokens: z.number() }))
|
|
23
|
+
});
|
|
24
|
+
const filesResponseSchema = z.object({
|
|
25
|
+
agentId: z.string(),
|
|
26
|
+
files: z.array(sourceFileSchema),
|
|
27
|
+
tokenUsage: tokenUsageSchema.nullable()
|
|
28
|
+
});
|
|
29
|
+
const errorSchema = z.object({ error: z.string() });
|
|
30
|
+
async function GET(req, ctx) {
|
|
31
|
+
const auth = await getAuthFromRequest(req);
|
|
32
|
+
if (!auth) return NextResponse.json({ error: "Unauthorized" }, { status: 401 });
|
|
33
|
+
const { id } = await ctx.params;
|
|
34
|
+
await ensureAgentsLoaded();
|
|
35
|
+
const entry = getAgentEntry(id);
|
|
36
|
+
if (!entry) return NextResponse.json({ error: "Agent not found" }, { status: 404 });
|
|
37
|
+
if (entry.runtime !== "opencode" || !entry.sourceFiles) {
|
|
38
|
+
return NextResponse.json({ error: "Agent has no source files" }, { status: 404 });
|
|
39
|
+
}
|
|
40
|
+
return NextResponse.json({
|
|
41
|
+
agentId: entry.id,
|
|
42
|
+
files: entry.sourceFiles,
|
|
43
|
+
tokenUsage: entry.tokenUsage ?? null
|
|
44
|
+
});
|
|
45
|
+
}
|
|
46
|
+
const openApi = {
|
|
47
|
+
tag: "Agent Orchestrator",
|
|
48
|
+
summary: "Get an agent definition files",
|
|
49
|
+
methods: {
|
|
50
|
+
GET: {
|
|
51
|
+
summary: "Read a file-defined agent's raw definition files",
|
|
52
|
+
description: "Returns the baked raw content and o200k_base token count of every construction file (AGENT.md, OUTCOME.md, skills, tools, sub-agents) of a file-defined (OpenCode) agent, for the read-only Files tab. 404 for native agents. Gated by agent_orchestrator.agents.view.",
|
|
53
|
+
responses: [
|
|
54
|
+
{ status: 200, description: "Agent source files", schema: filesResponseSchema }
|
|
55
|
+
],
|
|
56
|
+
errors: [
|
|
57
|
+
{ status: 401, description: "Unauthorized", schema: errorSchema },
|
|
58
|
+
{ status: 403, description: "Missing agent_orchestrator.agents.view", schema: errorSchema },
|
|
59
|
+
{ status: 404, description: "Unknown agent id or native agent (no files)", schema: errorSchema }
|
|
60
|
+
]
|
|
61
|
+
}
|
|
62
|
+
}
|
|
63
|
+
};
|
|
64
|
+
export {
|
|
65
|
+
GET,
|
|
66
|
+
metadata,
|
|
67
|
+
openApi
|
|
68
|
+
};
|
|
69
|
+
//# sourceMappingURL=route.js.map
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
{
|
|
2
|
+
"version": 3,
|
|
3
|
+
"sources": ["../../../../../../../src/modules/agent_orchestrator/api/agents/%5Bid%5D/files/route.ts"],
|
|
4
|
+
"sourcesContent": ["import { NextResponse } from 'next/server'\nimport { z } from 'zod'\nimport type { OpenApiRouteDoc } from '@open-mercato/shared/lib/openapi'\nimport { getAuthFromRequest } from '@open-mercato/shared/lib/auth/server'\nimport { getAgentEntry, ensureAgentsLoaded } from '../../../../lib/sdk/defineAgent'\n\nexport const metadata = {\n GET: { requireAuth: true, requireFeatures: ['agent_orchestrator.agents.view'] },\n}\n\nconst sourceFileSchema = z.object({\n path: z.string(),\n content: z.string(),\n tokens: z.number(),\n inContext: z.boolean(),\n})\n\nconst tokenizedFileSchema = z.object({ path: z.string(), tokens: z.number() })\nconst tokenUsageSchema = z.object({\n total: z.number(),\n self: z.number(),\n agent: z.number(),\n outcome: z.number(),\n skills: z.array(z.object({ id: z.string(), tokens: z.number(), files: z.array(tokenizedFileSchema) })),\n tools: z.array(z.object({ name: z.string(), path: z.string(), tokens: z.number() })),\n subAgents: z.array(z.object({ id: z.string(), tokens: z.number() })),\n})\n\nconst filesResponseSchema = z.object({\n agentId: z.string(),\n files: z.array(sourceFileSchema),\n tokenUsage: tokenUsageSchema.nullable(),\n})\n\nconst errorSchema = z.object({ error: z.string() })\n\ntype RouteContext = { params: Promise<{ id: string }> }\n\nexport async function GET(req: Request, ctx: RouteContext) {\n const auth = await getAuthFromRequest(req)\n if (!auth) return NextResponse.json({ error: 'Unauthorized' }, { status: 401 })\n const { id } = await ctx.params\n await ensureAgentsLoaded()\n const entry = getAgentEntry(id)\n if (!entry) return NextResponse.json({ error: 'Agent not found' }, { status: 404 })\n // The Files tab is a read-only view of a file-defined (OpenCode) agent's\n // source. Native/in-process agents have no baked files \u2192 404 so the UI never\n // renders the tab for them.\n if (entry.runtime !== 'opencode' || !entry.sourceFiles) {\n return NextResponse.json({ error: 'Agent has no source files' }, { status: 404 })\n }\n return NextResponse.json({\n agentId: entry.id,\n files: entry.sourceFiles,\n tokenUsage: entry.tokenUsage ?? null,\n })\n}\n\nexport const openApi: OpenApiRouteDoc = {\n tag: 'Agent Orchestrator',\n summary: 'Get an agent definition files',\n methods: {\n GET: {\n summary: \"Read a file-defined agent's raw definition files\",\n description:\n \"Returns the baked raw content and o200k_base token count of every construction file (AGENT.md, OUTCOME.md, skills, tools, sub-agents) of a file-defined (OpenCode) agent, for the read-only Files tab. 404 for native agents. Gated by agent_orchestrator.agents.view.\",\n responses: [\n { status: 200, description: 'Agent source files', schema: filesResponseSchema },\n ],\n errors: [\n { status: 401, description: 'Unauthorized', schema: errorSchema },\n { status: 403, description: 'Missing agent_orchestrator.agents.view', schema: errorSchema },\n { status: 404, description: 'Unknown agent id or native agent (no files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ib/auth/server";
|
|
4
|
+
import { createRequestContainer } from "@open-mercato/shared/lib/di/container";
|
|
5
|
+
import { AgentMetricRollup } from "../../../../data/entities.js";
|
|
6
|
+
import { runWindow, agentMetricRollupMetricsSchema } from "../../../../data/validators.js";
|
|
7
|
+
import {
|
|
8
|
+
ROLLUP_WINDOW_MS,
|
|
9
|
+
ROLLUP_BUCKET_MS,
|
|
10
|
+
computeAgentMetrics
|
|
11
|
+
} from "../../../../lib/metrics/metricRollupService.js";
|
|
12
|
+
const metadata = {
|
|
13
|
+
GET: { requireAuth: true, requireFeatures: ["agent_orchestrator.trace.view"] }
|
|
14
|
+
};
|
|
15
|
+
const ROLLUP_FRESHNESS_MS = 2 * ROLLUP_BUCKET_MS;
|
|
16
|
+
const errorSchema = z.object({ error: z.string() });
|
|
17
|
+
async function GET(req, ctx) {
|
|
18
|
+
const auth = await getAuthFromRequest(req);
|
|
19
|
+
if (!auth) return NextResponse.json({ error: "Unauthorized" }, { status: 401 });
|
|
20
|
+
if (!auth.tenantId || !auth.orgId) {
|
|
21
|
+
return NextResponse.json({ error: "Tenant context required" }, { status: 400 });
|
|
22
|
+
}
|
|
23
|
+
const { id: agentId } = await ctx.params;
|
|
24
|
+
const url = new URL(req.url);
|
|
25
|
+
const window = runWindow.catch("30d").parse(url.searchParams.get("window") ?? "30d");
|
|
26
|
+
const since = new Date(Date.now() - ROLLUP_WINDOW_MS[window]);
|
|
27
|
+
const container = await createRequestContainer();
|
|
28
|
+
const em = container.resolve("em").fork();
|
|
29
|
+
const scope = { tenantId: auth.tenantId, organizationId: auth.orgId };
|
|
30
|
+
const windowSpanMs = ROLLUP_WINDOW_MS[window];
|
|
31
|
+
const candidate = await em.findOne(
|
|
32
|
+
AgentMetricRollup,
|
|
33
|
+
{ organizationId: scope.organizationId, agentId },
|
|
34
|
+
{ orderBy: { computedAt: "desc" } }
|
|
35
|
+
);
|
|
36
|
+
if (candidate && Math.abs(candidate.windowEnd.getTime() - candidate.windowStart.getTime() - windowSpanMs) < ROLLUP_BUCKET_MS && Date.now() - candidate.computedAt.getTime() <= ROLLUP_FRESHNESS_MS) {
|
|
37
|
+
const parsed = agentMetricRollupMetricsSchema.safeParse(candidate.metrics);
|
|
38
|
+
if (parsed.success) {
|
|
39
|
+
return NextResponse.json({
|
|
40
|
+
agentId,
|
|
41
|
+
window,
|
|
42
|
+
since: candidate.windowStart.toISOString(),
|
|
43
|
+
...parsed.data,
|
|
44
|
+
capped: false,
|
|
45
|
+
source: "rollup",
|
|
46
|
+
computedAt: candidate.computedAt.toISOString()
|
|
47
|
+
});
|
|
48
|
+
}
|
|
49
|
+
}
|
|
50
|
+
const metrics = await computeAgentMetrics(em, scope, { agentId, since });
|
|
51
|
+
return NextResponse.json({
|
|
52
|
+
agentId,
|
|
53
|
+
window,
|
|
54
|
+
since: since.toISOString(),
|
|
55
|
+
...metrics,
|
|
56
|
+
capped: false,
|
|
57
|
+
source: "live",
|
|
58
|
+
computedAt: (/* @__PURE__ */ new Date()).toISOString()
|
|
59
|
+
});
|
|
60
|
+
}
|
|
61
|
+
const openApi = {
|
|
62
|
+
tag: "Agent Orchestrator",
|
|
63
|
+
summary: "Get per-agent quality metrics",
|
|
64
|
+
methods: {
|
|
65
|
+
GET: {
|
|
66
|
+
summary: "Override rate, eval-pass rate, latency and cost for an agent over a window",
|
|
67
|
+
description: `Per-agent metrics over a window (24h|7d|30d|90d, default 30d). Prefers a precomputed rollup row when one matches the window and is fresh (source="rollup"); otherwise live-computes from this module's run + correction tables (source="live"). Gated by agent_orchestrator.trace.view.`,
|
|
68
|
+
responses: [{ status: 200, description: "Per-agent metrics over the window" }],
|
|
69
|
+
errors: [
|
|
70
|
+
{ status: 401, description: "Unauthorized", schema: errorSchema },
|
|
71
|
+
{ status: 403, description: "Missing agent_orchestrator.trace.view", schema: errorSchema }
|
|
72
|
+
]
|
|
73
|
+
}
|
|
74
|
+
}
|
|
75
|
+
};
|
|
76
|
+
export {
|
|
77
|
+
GET,
|
|
78
|
+
metadata,
|
|
79
|
+
openApi
|
|
80
|
+
};
|
|
81
|
+
//# sourceMappingURL=route.js.map
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
{
|
|
2
|
+
"version": 3,
|
|
3
|
+
"sources": ["../../../../../../../src/modules/agent_orchestrator/api/agents/%5Bid%5D/metrics/route.ts"],
|
|
4
|
+
"sourcesContent": ["import { NextResponse } from 'next/server'\nimport { z } from 'zod'\nimport type { EntityManager } from '@mikro-orm/postgresql'\nimport type { OpenApiRouteDoc } from '@open-mercato/shared/lib/openapi'\nimport { getAuthFromRequest } from '@open-mercato/shared/lib/auth/server'\nimport { createRequestContainer } from '@open-mercato/shared/lib/di/container'\nimport { AgentMetricRollup } from '../../../../data/entities'\nimport { runWindow, agentMetricRollupMetricsSchema } from '../../../../data/validators'\nimport {\n ROLLUP_WINDOW_MS,\n ROLLUP_BUCKET_MS,\n computeAgentMetrics,\n} from '../../../../lib/metrics/metricRollupService'\n\n/**\n * Per-agent quality metrics over a window \u2014 override rate, eval-pass rate,\n * latency and cost. Prefers a precomputed rollup row (F2) whose window matches\n * the request and is still fresh; otherwise falls back to a live compute over\n * this module's tables. The response is backward-compatible \u2014 `source` and\n * `computedAt` are the only additive fields.\n */\nexport const metadata = {\n GET: { requireAuth: true, requireFeatures: ['agent_orchestrator.trace.view'] },\n}\n\n/**\n * A rollup is considered fresh when it was computed within 2 buckets of now.\n * Beyond that the scheduler likely missed ticks, so we live-compute instead of\n * serving a stale window.\n */\nconst ROLLUP_FRESHNESS_MS = 2 * ROLLUP_BUCKET_MS\n\nconst errorSchema = z.object({ error: z.string() })\n\ntype RouteContext = { params: Promise<{ id: string }> }\n\nexport async function GET(req: Request, ctx: RouteContext) {\n const auth = await getAuthFromRequest(req)\n if (!auth) return NextResponse.json({ error: 'Unauthorized' }, { status: 401 })\n if (!auth.tenantId || !auth.orgId) {\n return NextResponse.json({ error: 'Tenant context required' }, { status: 400 })\n }\n\n const { id: agentId } = await ctx.params\n const url = new URL(req.url)\n const window = runWindow.catch('30d').parse(url.searchParams.get('window') ?? '30d')\n const since = new Date(Date.now() - ROLLUP_WINDOW_MS[window])\n\n const container = await createRequestContainer()\n const em = (container.resolve('em') as EntityManager).fork()\n const scope = { tenantId: auth.tenantId, organizationId: auth.orgId }\n\n // Prefer the freshest rollup row whose window length matches the request.\n const windowSpanMs = ROLLUP_WINDOW_MS[window]\n const candidate = await em.findOne(\n AgentMetricRollup,\n { organizationId: scope.organizationId, agentId },\n { orderBy: { computedAt: 'desc' } },\n )\n if (\n candidate &&\n Math.abs(candidate.windowEnd.getTime() - candidate.windowStart.getTime() - windowSpanMs) < ROLLUP_BUCKET_MS &&\n Date.now() - candidate.computedAt.getTime() <= ROLLUP_FRESHNESS_MS\n ) {\n const parsed = agentMetricRollupMetricsSchema.safeParse(candidate.metrics)\n if (parsed.success) {\n return NextResponse.json({\n agentId,\n window,\n since: candidate.windowStart.toISOString(),\n ...parsed.data,\n capped: false,\n source: 'rollup' as const,\n computedAt: candidate.computedAt.toISOString(),\n })\n }\n }\n\n const metrics = await computeAgentMetrics(em, scope, { agentId, since })\n return NextResponse.json({\n agentId,\n window,\n since: since.toISOString(),\n ...metrics,\n capped: false,\n source: 'live' as const,\n computedAt: new Date().toISOString(),\n })\n}\n\nexport const openApi: OpenApiRouteDoc = {\n tag: 'Agent Orchestrator',\n summary: 'Get per-agent quality metrics',\n methods: {\n GET: {\n summary: 'Override rate, eval-pass rate, latency and cost for an agent over a window',\n description:\n 'Per-agent metrics over a window (24h|7d|30d|90d, default 30d). Prefers a precomputed rollup row when one matches the window and is fresh (source=\"rollup\"); otherwise live-computes from this module\\'s run + correction tables (source=\"live\"). Gated by agent_orchestrator.trace.view.',\n responses: [{ status: 200, description: 'Per-agent metrics over the window' }],\n errors: [\n { status: 401, description: 'Unauthorized', schema: errorSchema },\n { status: 403, description: 'Missing agent_orchestrator.trace.view', schema: errorSchema },\n ],\n },\n },\n}\n"],
|
|
5
|
+
"mappings": "AAAA,SAAS,oBAA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,MACE,aACA,KAAK,IAAI,UAAU,UAAU,QAAQ,IAAI,UAAU,YAAY,QAAQ,IAAI,YAAY,IAAI,oBAC3F,KAAK,IAAI,IAAI,UAAU,WAAW,QAAQ,KAAK,qBAC/C;AACA,UAAM,SAAS,+BAA+B,UAAU,UAAU,OAAO;AACzE,QAAI,OAAO,SAAS;AAClB,aAAO,aAAa,KAAK;AAAA,QACvB;AAAA,QACA;AAAA,QACA,OAAO,UAAU,YAAY,YAAY;AAAA,QACzC,GAAG,OAAO;AAAA,QACV,QAAQ;AAAA,QACR,QAAQ;AAAA,QACR,YAAY,UAAU,WAAW,YAAY;AAAA,MAC/C,CAAC;AAAA,IACH;AAAA,EACF;AAEA,QAAM,UAAU,MAAM,oBAAoB,IAAI,OAAO,EAAE,SAAS,MAAM,CAAC;AACvE,SAAO,aAAa,KAAK;AAAA,IACvB;AAAA,IACA;AAAA,IACA,OAAO,MAAM,YAAY;AAAA,IACzB,GAAG;AAAA,IACH,QAAQ;AAAA,IACR,QAAQ;AAAA,IACR,aAAY,oBAAI,KAAK,GAAE,YAAY;AAAA,EACrC,CAAC;AACH;AAEO,MAAM,UAA2B;AAAA,EACtC,KAAK;AAAA,EACL,SAAS;AAAA,EACT,SAAS;AAAA,IACP,KAAK;AAAA,MACH,SAAS;AAAA,MACT,aACE;AAAA,MACF,WAAW,CAAC,EAAE,QAAQ,KAAK,aAAa,oCAAoC,CAAC;AAAA,MAC7E,QAAQ;AAAA,QACN,EAAE,QAAQ,KAAK,aAAa,gBAAgB,QAAQ,YAAY;AAAA,QAChE,EAAE,QAAQ,KAAK,aAAa,yCAAyC,QAAQ,YAAY;AAAA,MAC3F;AAAA,IACF;AAAA,EACF;AACF;",
|
|
6
|
+
"names": []
|
|
7
|
+
}
|
|
@@ -0,0 +1,154 @@
|
|
|
1
|
+
import { NextResponse } from "next/server";
|
|
2
|
+
import { z } from "zod";
|
|
3
|
+
import { getAuthFromRequest } from "@open-mercato/shared/lib/auth/server";
|
|
4
|
+
import { createRequestContainer } from "@open-mercato/shared/lib/di/container";
|
|
5
|
+
import { getAgentEntry, ensureAgentsLoaded } from "../../../lib/sdk/defineAgent.js";
|
|
6
|
+
import { getSkillEntry, ensureSkillsLoaded } from "../../../lib/sdk/defineSkill.js";
|
|
7
|
+
import { getAgentSkill } from "../../../lib/runtime/fileAgentSkills.js";
|
|
8
|
+
import { getAgentSettingRow } from "../../../lib/settings/agentSettings.js";
|
|
9
|
+
import { AGENT_ICON_NAMES, isAgentIconName } from "../../../data/agentIcons.js";
|
|
10
|
+
import { normalizeAgentTags } from "../../../data/agentTags.js";
|
|
11
|
+
import { agentTypeSchema } from "../../../data/validators.js";
|
|
12
|
+
const metadata = {
|
|
13
|
+
GET: { requireAuth: true, requireFeatures: ["agent_orchestrator.agents.view"] }
|
|
14
|
+
};
|
|
15
|
+
const skillDetailSchema = z.object({
|
|
16
|
+
id: z.string(),
|
|
17
|
+
label: z.string(),
|
|
18
|
+
description: z.string(),
|
|
19
|
+
instructions: z.string(),
|
|
20
|
+
tools: z.array(z.string())
|
|
21
|
+
});
|
|
22
|
+
const tokenizedFileSchema = z.object({ path: z.string(), tokens: z.number() });
|
|
23
|
+
const tokenUsageSchema = z.object({
|
|
24
|
+
total: z.number(),
|
|
25
|
+
self: z.number(),
|
|
26
|
+
agent: z.number(),
|
|
27
|
+
outcome: z.number(),
|
|
28
|
+
skills: z.array(z.object({ id: z.string(), tokens: z.number(), files: z.array(tokenizedFileSchema) })),
|
|
29
|
+
tools: z.array(z.object({ name: z.string(), path: z.string(), tokens: z.number() })),
|
|
30
|
+
subAgents: z.array(z.object({ id: z.string(), tokens: z.number() }))
|
|
31
|
+
});
|
|
32
|
+
const agentDetailSchema = z.object({
|
|
33
|
+
id: z.string(),
|
|
34
|
+
moduleId: z.string(),
|
|
35
|
+
resultKind: z.enum(["research", "proposal", "artifact"]),
|
|
36
|
+
// Declared type + effective action vocabulary — see the list route for the
|
|
37
|
+
// null semantics (undeclared type, un-narrowed catalogue).
|
|
38
|
+
agentType: agentTypeSchema.nullable(),
|
|
39
|
+
allowedActions: z.array(z.string()).nullable(),
|
|
40
|
+
runtime: z.enum(["in-process", "native", "opencode", "external"]),
|
|
41
|
+
tools: z.array(z.string()),
|
|
42
|
+
skills: z.array(z.string()),
|
|
43
|
+
skillDetails: z.array(skillDetailSchema),
|
|
44
|
+
subAgents: z.array(z.string()),
|
|
45
|
+
label: z.string(),
|
|
46
|
+
description: z.string(),
|
|
47
|
+
icon: z.enum(AGENT_ICON_NAMES).nullable(),
|
|
48
|
+
// Per-tenant operator tags, normalized; empty when untagged.
|
|
49
|
+
tags: z.array(z.string()),
|
|
50
|
+
// Settings-row version for optimistic locking on the icon picker and the tag
|
|
51
|
+
// editor (they share the row); null when the tenant has never customised this
|
|
52
|
+
// agent (no row yet).
|
|
53
|
+
iconUpdatedAt: z.string().nullable(),
|
|
54
|
+
instructions: z.string(),
|
|
55
|
+
defaultProvider: z.string().nullable(),
|
|
56
|
+
defaultModel: z.string().nullable(),
|
|
57
|
+
loop: z.object({ maxSteps: z.number().optional() }).nullable(),
|
|
58
|
+
// Baked token-usage estimate for file-defined (opencode) agents; null otherwise.
|
|
59
|
+
tokenUsage: tokenUsageSchema.nullable()
|
|
60
|
+
});
|
|
61
|
+
const errorSchema = z.object({ error: z.string() });
|
|
62
|
+
async function GET(req, ctx) {
|
|
63
|
+
const auth = await getAuthFromRequest(req);
|
|
64
|
+
if (!auth) return NextResponse.json({ error: "Unauthorized" }, { status: 401 });
|
|
65
|
+
const { id } = await ctx.params;
|
|
66
|
+
await Promise.all([ensureAgentsLoaded(), ensureSkillsLoaded()]);
|
|
67
|
+
const entry = getAgentEntry(id);
|
|
68
|
+
if (!entry) return NextResponse.json({ error: "Agent not found" }, { status: 404 });
|
|
69
|
+
let icon = null;
|
|
70
|
+
let tags = [];
|
|
71
|
+
let iconUpdatedAt = null;
|
|
72
|
+
if (auth.tenantId && auth.orgId) {
|
|
73
|
+
try {
|
|
74
|
+
const container = await createRequestContainer();
|
|
75
|
+
const em = container.resolve("em").fork();
|
|
76
|
+
const row = await getAgentSettingRow(em, { tenantId: auth.tenantId, organizationId: auth.orgId }, entry.id);
|
|
77
|
+
if (row) {
|
|
78
|
+
icon = isAgentIconName(row.icon) ? row.icon : null;
|
|
79
|
+
tags = normalizeAgentTags(row.tags);
|
|
80
|
+
iconUpdatedAt = row.updatedAt.toISOString();
|
|
81
|
+
}
|
|
82
|
+
} catch {
|
|
83
|
+
icon = null;
|
|
84
|
+
tags = [];
|
|
85
|
+
iconUpdatedAt = null;
|
|
86
|
+
}
|
|
87
|
+
}
|
|
88
|
+
const skillDetails = entry.skills.map((skillId) => {
|
|
89
|
+
const skill = getSkillEntry(skillId);
|
|
90
|
+
if (skill) {
|
|
91
|
+
return {
|
|
92
|
+
id: skillId,
|
|
93
|
+
label: skill.label,
|
|
94
|
+
description: skill.description,
|
|
95
|
+
instructions: skill.instructions,
|
|
96
|
+
tools: skill.tools
|
|
97
|
+
};
|
|
98
|
+
}
|
|
99
|
+
const fileSkill = getAgentSkill(entry.id, skillId);
|
|
100
|
+
return {
|
|
101
|
+
id: skillId,
|
|
102
|
+
label: skillId,
|
|
103
|
+
description: "",
|
|
104
|
+
instructions: fileSkill?.instructions ?? "",
|
|
105
|
+
tools: fileSkill?.tools ?? []
|
|
106
|
+
};
|
|
107
|
+
});
|
|
108
|
+
return NextResponse.json({
|
|
109
|
+
id: entry.id,
|
|
110
|
+
moduleId: entry.moduleId,
|
|
111
|
+
resultKind: entry.resultKind,
|
|
112
|
+
agentType: entry.agentType ?? null,
|
|
113
|
+
allowedActions: entry.allowedActions ? [...entry.allowedActions] : null,
|
|
114
|
+
runtime: entry.runtime,
|
|
115
|
+
tools: entry.tools,
|
|
116
|
+
skills: entry.skills,
|
|
117
|
+
skillDetails,
|
|
118
|
+
subAgents: entry.subAgents,
|
|
119
|
+
label: entry.label,
|
|
120
|
+
description: entry.description,
|
|
121
|
+
icon,
|
|
122
|
+
tags,
|
|
123
|
+
iconUpdatedAt,
|
|
124
|
+
instructions: entry.instructions,
|
|
125
|
+
defaultProvider: entry.defaultProvider ?? null,
|
|
126
|
+
defaultModel: entry.defaultModel ?? null,
|
|
127
|
+
loop: entry.loop ?? null,
|
|
128
|
+
tokenUsage: entry.tokenUsage ?? null
|
|
129
|
+
});
|
|
130
|
+
}
|
|
131
|
+
const openApi = {
|
|
132
|
+
tag: "Agent Orchestrator",
|
|
133
|
+
summary: "Get agent definition",
|
|
134
|
+
methods: {
|
|
135
|
+
GET: {
|
|
136
|
+
summary: "Get the full definition of a registered agent",
|
|
137
|
+
description: "Returns the full in-module agent definition (id, module, result kind, tools, skills, instructions, provider/model, loop) for an agent declared via defineAgent. Gated by agent_orchestrator.agents.view.",
|
|
138
|
+
responses: [
|
|
139
|
+
{ status: 200, description: "Agent definition", schema: agentDetailSchema }
|
|
140
|
+
],
|
|
141
|
+
errors: [
|
|
142
|
+
{ status: 401, description: "Unauthorized", schema: errorSchema },
|
|
143
|
+
{ status: 403, description: "Missing agent_orchestrator.agents.view", schema: errorSchema },
|
|
144
|
+
{ status: 404, description: "Unknown agent id", schema: errorSchema }
|
|
145
|
+
]
|
|
146
|
+
}
|
|
147
|
+
}
|
|
148
|
+
};
|
|
149
|
+
export {
|
|
150
|
+
GET,
|
|
151
|
+
metadata,
|
|
152
|
+
openApi
|
|
153
|
+
};
|
|
154
|
+
//# sourceMappingURL=route.js.map
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
{
|
|
2
|
+
"version": 3,
|
|
3
|
+
"sources": ["../../../../../../src/modules/agent_orchestrator/api/agents/%5Bid%5D/route.ts"],
|
|
4
|
+
"sourcesContent": ["import { NextResponse } from 'next/server'\nimport { z } from 'zod'\nimport type { EntityManager } from '@mikro-orm/postgresql'\nimport type { OpenApiRouteDoc } from '@open-mercato/shared/lib/openapi'\nimport { getAuthFromRequest } from '@open-mercato/shared/lib/auth/server'\nimport { createRequestContainer } from '@open-mercato/shared/lib/di/container'\nimport { getAgentEntry, ensureAgentsLoaded } from '../../../lib/sdk/defineAgent'\nimport { getSkillEntry, ensureSkillsLoaded } from '../../../lib/sdk/defineSkill'\nimport { getAgentSkill } from '../../../lib/runtime/fileAgentSkills'\nimport { getAgentSettingRow } from '../../../lib/settings/agentSettings'\nimport { AGENT_ICON_NAMES, isAgentIconName } from '../../../data/agentIcons'\nimport { normalizeAgentTags } from '../../../data/agentTags'\nimport { agentTypeSchema } from '../../../data/validators'\n\nexport const metadata = {\n GET: { requireAuth: true, requireFeatures: ['agent_orchestrator.agents.view'] },\n}\n\nconst skillDetailSchema = z.object({\n id: z.string(),\n label: z.string(),\n description: z.string(),\n instructions: z.string(),\n tools: z.array(z.string()),\n})\n\nconst tokenizedFileSchema = z.object({ path: z.string(), tokens: z.number() })\nconst tokenUsageSchema = z.object({\n total: z.number(),\n self: z.number(),\n agent: z.number(),\n outcome: z.number(),\n skills: z.array(z.object({ id: z.string(), tokens: z.number(), files: z.array(tokenizedFileSchema) })),\n tools: z.array(z.object({ name: z.string(), path: z.string(), tokens: z.number() })),\n subAgents: z.array(z.object({ id: z.string(), tokens: z.number() })),\n})\n\nconst agentDetailSchema = z.object({\n id: z.string(),\n moduleId: z.string(),\n resultKind: z.enum(['research', 'proposal', 'artifact']),\n // Declared type + effective action vocabulary \u2014 see the list route for the\n // null semantics (undeclared type, un-narrowed catalogue).\n agentType: agentTypeSchema.nullable(),\n allowedActions: z.array(z.string()).nullable(),\n runtime: z.enum(['in-process', 'native', 'opencode', 'external']),\n tools: z.array(z.string()),\n skills: z.array(z.string()),\n skillDetails: z.array(skillDetailSchema),\n subAgents: z.array(z.string()),\n label: z.string(),\n description: z.string(),\n icon: z.enum(AGENT_ICON_NAMES).nullable(),\n // Per-tenant operator tags, normalized; empty when untagged.\n tags: z.array(z.string()),\n // Settings-row version for optimistic locking on the icon picker and the tag\n // editor (they share the row); null when the tenant has never customised this\n // agent (no row yet).\n iconUpdatedAt: z.string().nullable(),\n instructions: z.string(),\n defaultProvider: z.string().nullable(),\n defaultModel: z.string().nullable(),\n loop: z.object({ maxSteps: z.number().optional() }).nullable(),\n // Baked token-usage estimate for file-defined (opencode) agents; null otherwise.\n tokenUsage: tokenUsageSchema.nullable(),\n})\n\nconst errorSchema = z.object({ error: z.string() })\n\ntype RouteContext = { params: Promise<{ id: string }> }\n\nexport async function GET(req: Request, ctx: RouteContext) {\n const auth = await getAuthFromRequest(req)\n if (!auth) return NextResponse.json({ error: 'Unauthorized' }, { status: 401 })\n const { id } = await ctx.params\n await Promise.all([ensureAgentsLoaded(), ensureSkillsLoaded()])\n const entry = getAgentEntry(id)\n if (!entry) return NextResponse.json({ error: 'Agent not found' }, { status: 404 })\n\n // Tenant presentation overrides + the row's lock version (best-effort \u2014 never\n // fails the definition read).\n let icon: string | null = null\n let tags: string[] = []\n let iconUpdatedAt: string | null = null\n if (auth.tenantId && auth.orgId) {\n try {\n const container = await createRequestContainer()\n const em = (container.resolve('em') as EntityManager).fork()\n const row = await getAgentSettingRow(em, { tenantId: auth.tenantId, organizationId: auth.orgId }, entry.id)\n if (row) {\n icon = isAgentIconName(row.icon) ? row.icon : null\n tags = normalizeAgentTags(row.tags)\n iconUpdatedAt = row.updatedAt.toISOString()\n }\n } catch {\n icon = null\n tags = []\n iconUpdatedAt = null\n }\n }\n const skillDetails = entry.skills.map((skillId) => {\n const skill = getSkillEntry(skillId)\n if (skill) {\n return {\n id: skillId,\n label: skill.label,\n description: skill.description,\n instructions: skill.instructions,\n tools: skill.tools,\n }\n }\n // File-defined (OpenCode) agents carry agent-local skills (their SKILL.md\n // content) in `fileAgentSkills`, NOT the in-process `defineSkill` registry \u2014\n // so resolve those from there, else the drawer shows the empty-default fallback.\n const fileSkill = getAgentSkill(entry.id, skillId)\n return {\n id: skillId,\n label: skillId,\n description: '',\n instructions: fileSkill?.instructions ?? '',\n tools: fileSkill?.tools ?? [],\n }\n })\n return NextResponse.json({\n id: entry.id,\n moduleId: entry.moduleId,\n resultKind: entry.resultKind,\n agentType: entry.agentType ?? null,\n allowedActions: entry.allowedActions ? [...entry.allowedActions] : null,\n runtime: entry.runtime,\n tools: entry.tools,\n skills: entry.skills,\n skillDetails,\n subAgents: entry.subAgents,\n label: entry.label,\n description: entry.description,\n icon,\n tags,\n iconUpdatedAt,\n instructions: entry.instructions,\n defaultProvider: entry.defaultProvider ?? null,\n defaultModel: entry.defaultModel ?? null,\n loop: entry.loop ?? null,\n tokenUsage: entry.tokenUsage ?? null,\n })\n}\n\nexport const openApi: OpenApiRouteDoc = {\n tag: 'Agent Orchestrator',\n summary: 'Get agent definition',\n methods: {\n GET: {\n summary: 'Get the full definition of a registered agent',\n description:\n 'Returns the full in-module agent definition (id, module, result kind, tools, skills, instructions, provider/model, loop) for an agent declared via defineAgent. Gated by agent_orchestrator.agents.view.',\n responses: [\n { status: 200, description: 'Agent definition', schema: agentDetailSchema },\n ],\n errors: [\n { status: 401, description: 'Unauthorized', schema: errorSchema },\n { status: 403, description: 'Missing agent_orchestrator.agents.view', schema: errorSchema },\n { status: 404, description: 'Unknown agent id', schema: errorSchema },\n ],\n },\n },\n}\n"],
|
|
5
|
+
"mappings": "AAAA,SAAS,oBAAoB;AAC7B,SAAS,SAAS;AAGlB,SAAS,0BAA0B;AACnC,SAAS,8BAA8B;AACvC,SAAS,eAAe,0BAA0B;AAClD,SAAS,eAAe,0BAA0B;AAClD,SAAS,qBAAqB;AAC9B,SAAS,0BAA0B;AACnC,SAAS,kBAAkB,uBAAuB;AAClD,SAAS,0BAA0B;AACnC,SAAS,uBAAuB;AAEzB,MAAM,WAAW;AAAA,EACtB,KAAK,EAAE,aAAa,MAAM,iBAAiB,CAAC,gCAAgC,EAAE;AAChF;AAEA,MAAM,oBAAoB,EAAE,OAAO;AAAA,EACjC,IAAI,EAAE,OAAO;AAAA,EACb,OAAO,EAAE,OAAO;AAAA,EAChB,aAAa,EAAE,OAAO;AAAA,EACtB,cAAc,EAAE,OAAO;AAAA,EACvB,OAAO,EAAE,MAAM,EAAE,OAAO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