agent-orcha 0.0.5 → 0.0.8
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +250 -1275
- package/dist/lib/agents/agent-executor.d.ts +4 -2
- package/dist/lib/agents/agent-executor.d.ts.map +1 -1
- package/dist/lib/agents/agent-executor.js +85 -53
- package/dist/lib/agents/agent-executor.js.map +1 -1
- package/dist/lib/agents/agent-loader.d.ts +3 -0
- package/dist/lib/agents/agent-loader.d.ts.map +1 -1
- package/dist/lib/agents/agent-loader.js +10 -1
- package/dist/lib/agents/agent-loader.js.map +1 -1
- package/dist/lib/agents/react-loop.d.ts.map +1 -1
- package/dist/lib/agents/react-loop.js +207 -142
- package/dist/lib/agents/react-loop.js.map +1 -1
- package/dist/lib/agents/types.d.ts +181 -18
- package/dist/lib/agents/types.d.ts.map +1 -1
- package/dist/lib/agents/types.js +18 -2
- package/dist/lib/agents/types.js.map +1 -1
- package/dist/lib/functions/function-loader.d.ts +2 -0
- package/dist/lib/functions/function-loader.d.ts.map +1 -1
- package/dist/lib/functions/function-loader.js +10 -0
- package/dist/lib/functions/function-loader.js.map +1 -1
- package/dist/lib/functions/simple-function-wrapper.js +3 -3
- package/dist/lib/functions/simple-function-wrapper.js.map +1 -1
- package/dist/lib/integrations/email.d.ts +38 -0
- package/dist/lib/integrations/email.d.ts.map +1 -0
- package/dist/lib/integrations/email.js +249 -0
- package/dist/lib/integrations/email.js.map +1 -0
- package/dist/lib/integrations/integration-manager.d.ts +5 -0
- package/dist/lib/integrations/integration-manager.d.ts.map +1 -1
- package/dist/lib/integrations/integration-manager.js +53 -3
- package/dist/lib/integrations/integration-manager.js.map +1 -1
- package/dist/lib/integrations/types.d.ts +187 -4
- package/dist/lib/integrations/types.d.ts.map +1 -1
- package/dist/lib/integrations/types.js +24 -1
- package/dist/lib/integrations/types.js.map +1 -1
- package/dist/lib/knowledge/knowledge-store.d.ts +7 -1
- package/dist/lib/knowledge/knowledge-store.d.ts.map +1 -1
- package/dist/lib/knowledge/knowledge-store.js +96 -8
- package/dist/lib/knowledge/knowledge-store.js.map +1 -1
- package/dist/lib/knowledge/loaders/file-loaders.d.ts +8 -3
- package/dist/lib/knowledge/loaders/file-loaders.d.ts.map +1 -1
- package/dist/lib/knowledge/loaders/file-loaders.js +96 -75
- package/dist/lib/knowledge/loaders/file-loaders.js.map +1 -1
- package/dist/lib/knowledge/loaders/web-loader.d.ts +12 -3
- package/dist/lib/knowledge/loaders/web-loader.d.ts.map +1 -1
- package/dist/lib/knowledge/loaders/web-loader.js +56 -22
- package/dist/lib/knowledge/loaders/web-loader.js.map +1 -1
- package/dist/lib/knowledge/sqlite-store.d.ts.map +1 -1
- package/dist/lib/knowledge/sqlite-store.js +19 -10
- package/dist/lib/knowledge/sqlite-store.js.map +1 -1
- package/dist/lib/knowledge/types.d.ts +69 -33
- package/dist/lib/knowledge/types.d.ts.map +1 -1
- package/dist/lib/knowledge/types.js +18 -3
- package/dist/lib/knowledge/types.js.map +1 -1
- package/dist/lib/llm/index.d.ts +1 -1
- package/dist/lib/llm/index.d.ts.map +1 -1
- package/dist/lib/llm/index.js +1 -1
- package/dist/lib/llm/index.js.map +1 -1
- package/dist/lib/llm/llm-call-logger.d.ts +3 -1
- package/dist/lib/llm/llm-call-logger.d.ts.map +1 -1
- package/dist/lib/llm/llm-call-logger.js +31 -26
- package/dist/lib/llm/llm-call-logger.js.map +1 -1
- package/dist/lib/llm/llm-config.d.ts +59 -8
- package/dist/lib/llm/llm-config.d.ts.map +1 -1
- package/dist/lib/llm/llm-config.js +163 -17
- package/dist/lib/llm/llm-config.js.map +1 -1
- package/dist/lib/llm/llm-factory.d.ts +1 -2
- package/dist/lib/llm/llm-factory.d.ts.map +1 -1
- package/dist/lib/llm/llm-factory.js +44 -8
- package/dist/lib/llm/llm-factory.js.map +1 -1
- package/dist/lib/llm/providers/anthropic-chat-model.d.ts +5 -1
- package/dist/lib/llm/providers/anthropic-chat-model.d.ts.map +1 -1
- package/dist/lib/llm/providers/anthropic-chat-model.js +118 -42
- package/dist/lib/llm/providers/anthropic-chat-model.js.map +1 -1
- package/dist/lib/llm/providers/gemini-chat-model.d.ts +3 -2
- package/dist/lib/llm/providers/gemini-chat-model.d.ts.map +1 -1
- package/dist/lib/llm/providers/gemini-chat-model.js +83 -24
- package/dist/lib/llm/providers/gemini-chat-model.js.map +1 -1
- package/dist/lib/llm/providers/openai-chat-model.d.ts +20 -1
- package/dist/lib/llm/providers/openai-chat-model.d.ts.map +1 -1
- package/dist/lib/llm/providers/openai-chat-model.js +265 -32
- package/dist/lib/llm/providers/openai-chat-model.js.map +1 -1
- package/dist/lib/llm/providers/openai-embeddings.d.ts.map +1 -1
- package/dist/lib/llm/providers/openai-embeddings.js +41 -10
- package/dist/lib/llm/providers/openai-embeddings.js.map +1 -1
- package/dist/lib/local-llm/binary-manager.d.ts +66 -0
- package/dist/lib/local-llm/binary-manager.d.ts.map +1 -0
- package/dist/lib/local-llm/binary-manager.js +441 -0
- package/dist/lib/local-llm/binary-manager.js.map +1 -0
- package/dist/lib/local-llm/engine-interface.d.ts +47 -0
- package/dist/lib/local-llm/engine-interface.d.ts.map +1 -0
- package/dist/lib/local-llm/engine-interface.js +2 -0
- package/dist/lib/local-llm/engine-interface.js.map +1 -0
- package/dist/lib/local-llm/engine-registry.d.ts +20 -0
- package/dist/lib/local-llm/engine-registry.d.ts.map +1 -0
- package/dist/lib/local-llm/engine-registry.js +56 -0
- package/dist/lib/local-llm/engine-registry.js.map +1 -0
- package/dist/lib/local-llm/engines/llama-cpp-engine.d.ts +31 -0
- package/dist/lib/local-llm/engines/llama-cpp-engine.d.ts.map +1 -0
- package/dist/lib/local-llm/engines/llama-cpp-engine.js +164 -0
- package/dist/lib/local-llm/engines/llama-cpp-engine.js.map +1 -0
- package/dist/lib/local-llm/engines/mlx-serve-engine.d.ts +31 -0
- package/dist/lib/local-llm/engines/mlx-serve-engine.d.ts.map +1 -0
- package/dist/lib/local-llm/engines/mlx-serve-engine.js +161 -0
- package/dist/lib/local-llm/engines/mlx-serve-engine.js.map +1 -0
- package/dist/lib/local-llm/gguf-reader.d.ts +20 -0
- package/dist/lib/local-llm/gguf-reader.d.ts.map +1 -0
- package/dist/lib/local-llm/gguf-reader.js +190 -0
- package/dist/lib/local-llm/gguf-reader.js.map +1 -0
- package/dist/lib/local-llm/index.d.ts +9 -0
- package/dist/lib/local-llm/index.d.ts.map +1 -0
- package/dist/lib/local-llm/index.js +6 -0
- package/dist/lib/local-llm/index.js.map +1 -0
- package/dist/lib/local-llm/llama-server-process.d.ts +42 -0
- package/dist/lib/local-llm/llama-server-process.d.ts.map +1 -0
- package/dist/lib/local-llm/llama-server-process.js +237 -0
- package/dist/lib/local-llm/llama-server-process.js.map +1 -0
- package/dist/lib/local-llm/mlx-binary-manager.d.ts +33 -0
- package/dist/lib/local-llm/mlx-binary-manager.d.ts.map +1 -0
- package/dist/lib/local-llm/mlx-binary-manager.js +211 -0
- package/dist/lib/local-llm/mlx-binary-manager.js.map +1 -0
- package/dist/lib/local-llm/mlx-server-process.d.ts +26 -0
- package/dist/lib/local-llm/mlx-server-process.d.ts.map +1 -0
- package/dist/lib/local-llm/mlx-server-process.js +210 -0
- package/dist/lib/local-llm/mlx-server-process.js.map +1 -0
- package/dist/lib/local-llm/model-manager.d.ts +33 -0
- package/dist/lib/local-llm/model-manager.d.ts.map +1 -0
- package/dist/lib/local-llm/model-manager.js +591 -0
- package/dist/lib/local-llm/model-manager.js.map +1 -0
- package/dist/lib/local-llm/types.d.ts +51 -0
- package/dist/lib/local-llm/types.d.ts.map +1 -0
- package/dist/lib/local-llm/types.js +2 -0
- package/dist/lib/local-llm/types.js.map +1 -0
- package/dist/lib/logger.d.ts +2 -0
- package/dist/lib/logger.d.ts.map +1 -1
- package/dist/lib/logger.js +68 -6
- package/dist/lib/logger.js.map +1 -1
- package/dist/lib/mcp/mcp-client.d.ts.map +1 -1
- package/dist/lib/mcp/mcp-client.js +5 -3
- package/dist/lib/mcp/mcp-client.js.map +1 -1
- package/dist/lib/mcp/types.d.ts +0 -9
- package/dist/lib/mcp/types.d.ts.map +1 -1
- package/dist/lib/mcp/types.js +1 -2
- package/dist/lib/mcp/types.js.map +1 -1
- package/dist/lib/memory/memory-manager.d.ts +1 -0
- package/dist/lib/memory/memory-manager.d.ts.map +1 -1
- package/dist/lib/memory/memory-manager.js +9 -0
- package/dist/lib/memory/memory-manager.js.map +1 -1
- package/dist/lib/orchestrator.d.ts +11 -8
- package/dist/lib/orchestrator.d.ts.map +1 -1
- package/dist/lib/orchestrator.js +246 -5
- package/dist/lib/orchestrator.js.map +1 -1
- package/dist/lib/sandbox/cdp-client.d.ts +15 -0
- package/dist/lib/sandbox/cdp-client.d.ts.map +1 -0
- package/dist/lib/sandbox/cdp-client.js +139 -0
- package/dist/lib/sandbox/cdp-client.js.map +1 -0
- package/dist/lib/sandbox/html-to-markdown.d.ts +9 -1
- package/dist/lib/sandbox/html-to-markdown.d.ts.map +1 -1
- package/dist/lib/sandbox/html-to-markdown.js +67 -10
- package/dist/lib/sandbox/html-to-markdown.js.map +1 -1
- package/dist/lib/sandbox/index.d.ts +6 -0
- package/dist/lib/sandbox/index.d.ts.map +1 -1
- package/dist/lib/sandbox/index.js +5 -0
- package/dist/lib/sandbox/index.js.map +1 -1
- package/dist/lib/sandbox/page-readiness.d.ts +37 -0
- package/dist/lib/sandbox/page-readiness.d.ts.map +1 -0
- package/dist/lib/sandbox/page-readiness.js +268 -0
- package/dist/lib/sandbox/page-readiness.js.map +1 -0
- package/dist/lib/sandbox/sandbox-browser.d.ts +4 -0
- package/dist/lib/sandbox/sandbox-browser.d.ts.map +1 -0
- package/dist/lib/sandbox/sandbox-browser.js +316 -0
- package/dist/lib/sandbox/sandbox-browser.js.map +1 -0
- package/dist/lib/sandbox/sandbox-container.d.ts +39 -0
- package/dist/lib/sandbox/sandbox-container.d.ts.map +1 -0
- package/dist/lib/sandbox/sandbox-container.js +176 -0
- package/dist/lib/sandbox/sandbox-container.js.map +1 -0
- package/dist/lib/sandbox/sandbox-file.d.ts +4 -0
- package/dist/lib/sandbox/sandbox-file.d.ts.map +1 -0
- package/dist/lib/sandbox/sandbox-file.js +169 -0
- package/dist/lib/sandbox/sandbox-file.js.map +1 -0
- package/dist/lib/sandbox/sandbox-shell.d.ts +5 -0
- package/dist/lib/sandbox/sandbox-shell.d.ts.map +1 -0
- package/dist/lib/sandbox/sandbox-shell.js +111 -0
- package/dist/lib/sandbox/sandbox-shell.js.map +1 -0
- package/dist/lib/sandbox/sandbox-web.d.ts.map +1 -1
- package/dist/lib/sandbox/sandbox-web.js +64 -24
- package/dist/lib/sandbox/sandbox-web.js.map +1 -1
- package/dist/lib/sandbox/types.d.ts +9 -0
- package/dist/lib/sandbox/types.d.ts.map +1 -1
- package/dist/lib/sandbox/types.js +1 -0
- package/dist/lib/sandbox/types.js.map +1 -1
- package/dist/lib/sandbox/vision-browser.d.ts +4 -0
- package/dist/lib/sandbox/vision-browser.d.ts.map +1 -0
- package/dist/lib/sandbox/vision-browser.js +298 -0
- package/dist/lib/sandbox/vision-browser.js.map +1 -0
- package/dist/lib/sea/app-window.d.ts +7 -0
- package/dist/lib/sea/app-window.d.ts.map +1 -0
- package/dist/lib/sea/app-window.js +95 -0
- package/dist/lib/sea/app-window.js.map +1 -0
- package/dist/lib/sea/bootstrap.d.ts +18 -0
- package/dist/lib/sea/bootstrap.d.ts.map +1 -0
- package/dist/lib/sea/bootstrap.js +103 -0
- package/dist/lib/sea/bootstrap.js.map +1 -0
- package/dist/lib/sea/sqlite-vec-shim.d.ts +3 -0
- package/dist/lib/sea/sqlite-vec-shim.d.ts.map +1 -0
- package/dist/lib/sea/sqlite-vec-shim.js +10 -0
- package/dist/lib/sea/sqlite-vec-shim.js.map +1 -0
- package/dist/lib/skills/skill-loader.d.ts +2 -0
- package/dist/lib/skills/skill-loader.d.ts.map +1 -1
- package/dist/lib/skills/skill-loader.js +12 -1
- package/dist/lib/skills/skill-loader.js.map +1 -1
- package/dist/lib/tasks/task-manager.d.ts +3 -1
- package/dist/lib/tasks/task-manager.d.ts.map +1 -1
- package/dist/lib/tasks/task-manager.js +11 -0
- package/dist/lib/tasks/task-manager.js.map +1 -1
- package/dist/lib/tasks/task-store.d.ts +1 -1
- package/dist/lib/tasks/task-store.d.ts.map +1 -1
- package/dist/lib/tasks/task-store.js.map +1 -1
- package/dist/lib/tasks/types.d.ts +18 -0
- package/dist/lib/tasks/types.d.ts.map +1 -1
- package/dist/lib/tools/built-in/integration-tools.d.ts +4 -0
- package/dist/lib/tools/built-in/integration-tools.d.ts.map +1 -0
- package/dist/lib/tools/built-in/integration-tools.js +47 -0
- package/dist/lib/tools/built-in/integration-tools.js.map +1 -0
- package/dist/lib/tools/built-in/knowledge-entity-lookup.tool.d.ts +1 -2
- package/dist/lib/tools/built-in/knowledge-entity-lookup.tool.d.ts.map +1 -1
- package/dist/lib/tools/built-in/knowledge-entity-lookup.tool.js +17 -17
- package/dist/lib/tools/built-in/knowledge-entity-lookup.tool.js.map +1 -1
- package/dist/lib/tools/built-in/knowledge-graph-schema.tool.d.ts.map +1 -1
- package/dist/lib/tools/built-in/knowledge-graph-schema.tool.js +2 -4
- package/dist/lib/tools/built-in/knowledge-graph-schema.tool.js.map +1 -1
- package/dist/lib/tools/built-in/knowledge-search.tool.js +4 -4
- package/dist/lib/tools/built-in/knowledge-search.tool.js.map +1 -1
- package/dist/lib/tools/built-in/knowledge-sql.tool.d.ts.map +1 -1
- package/dist/lib/tools/built-in/knowledge-sql.tool.js +74 -40
- package/dist/lib/tools/built-in/knowledge-sql.tool.js.map +1 -1
- package/dist/lib/tools/built-in/knowledge-tools-factory.js +2 -2
- package/dist/lib/tools/built-in/knowledge-tools-factory.js.map +1 -1
- package/dist/lib/tools/built-in/knowledge-traverse.tool.d.ts +1 -2
- package/dist/lib/tools/built-in/knowledge-traverse.tool.d.ts.map +1 -1
- package/dist/lib/tools/built-in/knowledge-traverse.tool.js +5 -11
- package/dist/lib/tools/built-in/knowledge-traverse.tool.js.map +1 -1
- package/dist/lib/tools/built-in/query-validators.d.ts.map +1 -1
- package/dist/lib/tools/built-in/query-validators.js +4 -0
- package/dist/lib/tools/built-in/query-validators.js.map +1 -1
- package/dist/lib/tools/workspace/workspace-tools.d.ts +1 -0
- package/dist/lib/tools/workspace/workspace-tools.d.ts.map +1 -1
- package/dist/lib/tools/workspace/workspace-tools.js +44 -4
- package/dist/lib/tools/workspace/workspace-tools.js.map +1 -1
- package/dist/lib/triggers/cron-trigger.d.ts +1 -1
- package/dist/lib/triggers/cron-trigger.d.ts.map +1 -1
- package/dist/lib/triggers/cron-trigger.js.map +1 -1
- package/dist/lib/triggers/trigger-manager.d.ts +1 -0
- package/dist/lib/triggers/trigger-manager.d.ts.map +1 -1
- package/dist/lib/triggers/trigger-manager.js +26 -0
- package/dist/lib/triggers/trigger-manager.js.map +1 -1
- package/dist/lib/triggers/webhook-trigger.d.ts +1 -1
- package/dist/lib/triggers/webhook-trigger.d.ts.map +1 -1
- package/dist/lib/triggers/webhook-trigger.js.map +1 -1
- package/dist/lib/types/llm-types.d.ts +22 -4
- package/dist/lib/types/llm-types.d.ts.map +1 -1
- package/dist/lib/types/llm-types.js +50 -0
- package/dist/lib/types/llm-types.js.map +1 -1
- package/dist/lib/types/tool-factory.d.ts +2 -2
- package/dist/lib/types/tool-factory.d.ts.map +1 -1
- package/dist/lib/types/tool-factory.js +9 -2
- package/dist/lib/types/tool-factory.js.map +1 -1
- package/dist/lib/utils/document-extract.d.ts +10 -0
- package/dist/lib/utils/document-extract.d.ts.map +1 -0
- package/dist/lib/utils/document-extract.js +149 -0
- package/dist/lib/utils/document-extract.js.map +1 -0
- package/dist/lib/utils/env-substitution.d.ts +6 -0
- package/dist/lib/utils/env-substitution.d.ts.map +1 -0
- package/dist/lib/utils/env-substitution.js +15 -0
- package/dist/lib/utils/env-substitution.js.map +1 -0
- package/dist/lib/workflows/react-workflow-executor.d.ts.map +1 -1
- package/dist/lib/workflows/react-workflow-executor.js +23 -17
- package/dist/lib/workflows/react-workflow-executor.js.map +1 -1
- package/dist/lib/workflows/types.d.ts +81 -55
- package/dist/lib/workflows/types.d.ts.map +1 -1
- package/dist/lib/workflows/types.js +10 -0
- package/dist/lib/workflows/types.js.map +1 -1
- package/dist/lib/workflows/workflow-loader.d.ts +3 -0
- package/dist/lib/workflows/workflow-loader.d.ts.map +1 -1
- package/dist/lib/workflows/workflow-loader.js +10 -1
- package/dist/lib/workflows/workflow-loader.js.map +1 -1
- package/dist/public/assets/logo.png +0 -0
- package/dist/public/chat.html +39 -0
- package/dist/public/index.html +6 -176
- package/dist/public/src/components/AgentComposer.js +807 -0
- package/dist/public/src/components/AgentsView.js +1812 -508
- package/dist/public/src/components/AppRoot.js +125 -38
- package/dist/public/src/components/GraphView.js +382 -300
- package/dist/public/src/components/IdeView.js +277 -86
- package/dist/public/src/components/KnowledgeView.js +94 -130
- package/dist/public/src/components/LlmView.js +15 -19
- package/dist/public/src/components/LocalLlmView.js +2440 -0
- package/dist/public/src/components/LogViewer.js +155 -0
- package/dist/public/src/components/McpView.js +41 -49
- package/dist/public/src/components/MonitorView.js +174 -83
- package/dist/public/src/components/NavBar.js +16 -26
- package/dist/public/src/components/StandaloneChat.js +875 -0
- package/dist/public/src/services/ApiService.js +203 -4
- package/dist/public/src/services/SessionStore.js +86 -0
- package/dist/public/src/services/StreamManager.js +183 -0
- package/dist/public/src/store.js +1 -3
- package/dist/public/src/utils/card.js +21 -0
- package/dist/public/src/utils/markdown.js +7 -0
- package/dist/public/styles.css +2777 -0
- package/dist/src/cli/commands/init.d.ts.map +1 -1
- package/dist/src/cli/commands/init.js +7 -1
- package/dist/src/cli/commands/init.js.map +1 -1
- package/dist/src/cli/commands/start.d.ts.map +1 -1
- package/dist/src/cli/commands/start.js +28 -5
- package/dist/src/cli/commands/start.js.map +1 -1
- package/dist/src/cli/index.js +19 -5
- package/dist/src/cli/index.js.map +1 -1
- package/dist/src/index.js +7 -1
- package/dist/src/index.js.map +1 -1
- package/dist/src/middleware/auth.d.ts.map +1 -1
- package/dist/src/middleware/auth.js +28 -6
- package/dist/src/middleware/auth.js.map +1 -1
- package/dist/src/middleware/rate-limit.d.ts +8 -0
- package/dist/src/middleware/rate-limit.d.ts.map +1 -0
- package/dist/src/middleware/rate-limit.js +21 -0
- package/dist/src/middleware/rate-limit.js.map +1 -0
- package/dist/src/routes/agents.route.d.ts.map +1 -1
- package/dist/src/routes/agents.route.js +138 -10
- package/dist/src/routes/agents.route.js.map +1 -1
- package/dist/src/routes/chat.route.d.ts +3 -0
- package/dist/src/routes/chat.route.d.ts.map +1 -0
- package/dist/src/routes/chat.route.js +156 -0
- package/dist/src/routes/chat.route.js.map +1 -0
- package/dist/src/routes/files.route.d.ts.map +1 -1
- package/dist/src/routes/files.route.js +37 -2
- package/dist/src/routes/files.route.js.map +1 -1
- package/dist/src/routes/llm.route.d.ts.map +1 -1
- package/dist/src/routes/llm.route.js +263 -8
- package/dist/src/routes/llm.route.js.map +1 -1
- package/dist/src/routes/local-llm.route.d.ts +3 -0
- package/dist/src/routes/local-llm.route.d.ts.map +1 -0
- package/dist/src/routes/local-llm.route.js +688 -0
- package/dist/src/routes/local-llm.route.js.map +1 -0
- package/dist/src/routes/logs.route.d.ts +3 -0
- package/dist/src/routes/logs.route.d.ts.map +1 -0
- package/dist/src/routes/logs.route.js +24 -0
- package/dist/src/routes/logs.route.js.map +1 -0
- package/dist/src/routes/tasks.route.d.ts.map +1 -1
- package/dist/src/routes/tasks.route.js +15 -1
- package/dist/src/routes/tasks.route.js.map +1 -1
- package/dist/src/routes/vnc.route.d.ts +12 -0
- package/dist/src/routes/vnc.route.d.ts.map +1 -0
- package/dist/src/routes/vnc.route.js +74 -0
- package/dist/src/routes/vnc.route.js.map +1 -0
- package/dist/src/routes/workflows.route.d.ts.map +1 -1
- package/dist/src/routes/workflows.route.js +24 -0
- package/dist/src/routes/workflows.route.js.map +1 -1
- package/dist/src/server.d.ts.map +1 -1
- package/dist/src/server.js +29 -3
- package/dist/src/server.js.map +1 -1
- package/dist/templates/Demo.md +152 -0
- package/dist/templates/README.md +12 -3
- package/dist/templates/agents/actor.agent.yaml +34 -0
- package/dist/templates/agents/architect.agent.yaml +20 -13
- package/dist/templates/agents/chatbot.agent.yaml +23 -27
- package/dist/templates/agents/corporate.agent.yaml +64 -0
- package/dist/templates/agents/functions.agent.yaml +29 -0
- package/dist/templates/agents/investment-analyst.agent.yaml +79 -0
- package/dist/templates/agents/music-librarian.agent.yaml +46 -0
- package/dist/templates/agents/network-security.agent.yaml +81 -0
- package/dist/templates/agents/transport-security.agent.yaml +69 -0
- package/dist/templates/agents/web-engineer.agent.yaml +98 -0
- package/dist/templates/agents/web-pilot.agent.yaml +57 -0
- package/dist/templates/knowledge/music-store/LICENSE.md +11 -0
- package/dist/templates/knowledge/music-store/musicstore.sqlite +0 -0
- package/dist/templates/knowledge/music-store/tables.png +0 -0
- package/dist/templates/knowledge/music-store.knowledge.yaml +138 -0
- package/dist/templates/knowledge/org-chart/personnel.csv +21 -21
- package/dist/templates/knowledge/org-chart.knowledge.yaml +4 -0
- package/dist/templates/knowledge/patient-records.knowledge.yaml +20 -0
- package/dist/templates/knowledge/pdf-patients/PDF_Deid_Deidentification_0.pdf +0 -0
- package/dist/templates/knowledge/pdf-patients/PDF_Deid_Deidentification_1.pdf +0 -0
- package/dist/templates/knowledge/pdf-patients/PDF_Deid_Deidentification_10.pdf +0 -0
- package/dist/templates/knowledge/pdf-patients/PDF_Deid_Deidentification_11.pdf +0 -0
- package/dist/templates/knowledge/pet-store.knowledge.yaml +3 -0
- package/dist/templates/knowledge/security-incidents/incidents.json +55935 -0
- package/dist/templates/knowledge/security-incidents.knowledge.yaml +46 -0
- package/dist/templates/knowledge/{example.knowledge.yaml → transcripts.knowledge.yaml} +9 -5
- package/dist/templates/knowledge/transport-ot/systems.csv +117 -0
- package/dist/templates/knowledge/transport-ot.knowledge.yaml +55 -0
- package/dist/templates/knowledge/web-docs.knowledge.yaml +1 -1
- package/dist/templates/llm.json +62 -22
- package/dist/templates/mcp.json +7 -4
- package/dist/templates/skills/orcha-builder/SKILL.md +148 -215
- package/dist/templates/skills/pii-guard/SKILL.md +22 -0
- package/dist/templates/skills/sandbox/SKILL.md +25 -48
- package/dist/templates/skills/web-pilot/SKILL.md +51 -0
- package/dist/templates/workflows/example.workflow.yaml +27 -35
- package/dist/templates/workflows/react-example.workflow.yaml +14 -19
- package/dist/templates/workflows/team-chat.workflow.yaml +47 -0
- package/package.json +17 -4
- package/dist/public/src/components/SkillsView.js +0 -137
- package/dist/public/src/components/WorkflowsView.js +0 -416
- package/dist/templates/agents/knowledge-broker.agent.yaml +0 -39
- package/dist/templates/agents/sandbox.agent.yaml +0 -56
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
|
|
2
2
|
import { Component } from '../utils/Component.js';
|
|
3
3
|
import { api } from '../services/ApiService.js';
|
|
4
|
+
import { escapeHtml as sharedEscapeHtml } from '../utils/card.js';
|
|
4
5
|
|
|
5
6
|
const STATUS_CONFIG = {
|
|
6
7
|
submitted: { label: 'Submitted', color: 'gray', icon: 'fa-clock' },
|
|
@@ -55,6 +56,13 @@ export class MonitorView extends Component {
|
|
|
55
56
|
if (this.selectedTask) {
|
|
56
57
|
const updated = tasks.find(t => t.id === this.selectedTask.id);
|
|
57
58
|
if (updated) {
|
|
59
|
+
// Preserve events and metrics from SSE — list API doesn't include them
|
|
60
|
+
if (this.selectedTask.events?.length && !updated.events?.length) {
|
|
61
|
+
updated.events = this.selectedTask.events;
|
|
62
|
+
}
|
|
63
|
+
if (this.selectedTask.metrics && !updated.metrics) {
|
|
64
|
+
updated.metrics = this.selectedTask.metrics;
|
|
65
|
+
}
|
|
58
66
|
this.selectedTask = updated;
|
|
59
67
|
this.renderDetailPanel();
|
|
60
68
|
}
|
|
@@ -70,8 +78,8 @@ export class MonitorView extends Component {
|
|
|
70
78
|
|
|
71
79
|
if (!this.tasks.length) {
|
|
72
80
|
container.innerHTML = `
|
|
73
|
-
<div class="
|
|
74
|
-
<i class="fas fa-tasks text-4xl mb-4
|
|
81
|
+
<div class="empty-state">
|
|
82
|
+
<i class="fas fa-tasks text-4xl mb-4 text-muted"></i>
|
|
75
83
|
<p class="text-lg mb-2">No tasks found</p>
|
|
76
84
|
<p class="text-sm">Submit a task via the API to see it here.</p>
|
|
77
85
|
</div>`;
|
|
@@ -85,22 +93,21 @@ export class MonitorView extends Component {
|
|
|
85
93
|
const isSelected = this.selectedTask?.id === task.id;
|
|
86
94
|
const elapsed = this.formatElapsed(task);
|
|
87
95
|
return `
|
|
88
|
-
<div class="task-row ${isSelected ?
|
|
89
|
-
data-task-id="${task.id}">
|
|
96
|
+
<div class="task-row card ${isSelected ? 'active' : ''}" data-task-id="${task.id}">
|
|
90
97
|
<div class="flex items-center justify-between">
|
|
91
98
|
<div class="flex items-center gap-3 min-w-0">
|
|
92
|
-
<i class="fas ${cfg.icon} text-${cfg.color}
|
|
99
|
+
<i class="fas ${cfg.icon} text-${cfg.color} text-sm flex-shrink-0"></i>
|
|
93
100
|
<div class="min-w-0">
|
|
94
101
|
<div class="flex items-center gap-2">
|
|
95
|
-
<span class="font-medium text-
|
|
96
|
-
<span class="
|
|
102
|
+
<span class="font-medium text-primary truncate">${task.target}</span>
|
|
103
|
+
<span class="badge badge-${kindBadgeVariant(task.kind)}">${task.kind}</span>
|
|
97
104
|
</div>
|
|
98
|
-
<div class="text-xs text-
|
|
105
|
+
<div class="text-xs text-muted mt-1 truncate">${task.id}</div>
|
|
99
106
|
</div>
|
|
100
107
|
</div>
|
|
101
108
|
<div class="flex items-center gap-3 flex-shrink-0">
|
|
102
|
-
<span class="text-xs text-
|
|
103
|
-
<span class="
|
|
109
|
+
<span class="text-xs text-muted">${elapsed}</span>
|
|
110
|
+
<span class="badge badge-pill badge-${cfg.color}">${cfg.label}</span>
|
|
104
111
|
</div>
|
|
105
112
|
</div>
|
|
106
113
|
</div>`;
|
|
@@ -114,13 +121,19 @@ export class MonitorView extends Component {
|
|
|
114
121
|
});
|
|
115
122
|
}
|
|
116
123
|
|
|
117
|
-
selectTask(taskId) {
|
|
124
|
+
async selectTask(taskId) {
|
|
118
125
|
const task = this.tasks.find(t => t.id === taskId);
|
|
119
126
|
if (!task) return;
|
|
120
127
|
|
|
121
128
|
this.selectedTask = task;
|
|
122
129
|
this.renderTaskList();
|
|
123
130
|
|
|
131
|
+
// Fetch full task with events
|
|
132
|
+
try {
|
|
133
|
+
const full = await api.getTask(taskId);
|
|
134
|
+
this.selectedTask = full;
|
|
135
|
+
} catch { /* fall back to list data */ }
|
|
136
|
+
|
|
124
137
|
const detailArea = this.querySelector('#taskDetailArea');
|
|
125
138
|
detailArea.classList.remove('hidden');
|
|
126
139
|
this.renderDetailPanel();
|
|
@@ -143,81 +156,83 @@ export class MonitorView extends Component {
|
|
|
143
156
|
this.querySelector('#detailHeader').innerHTML = `
|
|
144
157
|
<div>
|
|
145
158
|
<div class="flex items-center gap-2">
|
|
146
|
-
<i class="fas ${cfg.icon} text-${cfg.color}
|
|
147
|
-
<span class="font-medium text-
|
|
148
|
-
<span class="
|
|
159
|
+
<i class="fas ${cfg.icon} text-${cfg.color}"></i>
|
|
160
|
+
<span class="font-medium text-primary">${task.target}</span>
|
|
161
|
+
<span class="badge badge-pill badge-${cfg.color}">${cfg.label}</span>
|
|
149
162
|
</div>
|
|
150
|
-
<div class="text-xs text-
|
|
163
|
+
<div class="text-xs text-muted mt-1">${task.id}</div>
|
|
151
164
|
</div>`;
|
|
152
165
|
|
|
153
166
|
this.querySelector('#detailMeta').innerHTML = `
|
|
154
|
-
<div class="grid grid-cols-
|
|
155
|
-
<div>
|
|
156
|
-
|
|
157
|
-
|
|
158
|
-
</div>
|
|
159
|
-
<div>
|
|
160
|
-
<span class="text-gray-500 block text-xs">Created</span>
|
|
161
|
-
<span class="text-gray-300">${created}</span>
|
|
162
|
-
</div>
|
|
163
|
-
<div>
|
|
164
|
-
<span class="text-gray-500 block text-xs">Updated</span>
|
|
165
|
-
<span class="text-gray-300">${updated}</span>
|
|
166
|
-
</div>
|
|
167
|
-
<div>
|
|
168
|
-
<span class="text-gray-500 block text-xs">Completed</span>
|
|
169
|
-
<span class="text-gray-300">${completed}</span>
|
|
170
|
-
</div>
|
|
167
|
+
<div class="grid grid-cols-4 gap-4 text-sm">
|
|
168
|
+
<div><span class="text-muted block text-xs">Kind</span><span class="text-primary">${task.kind}</span></div>
|
|
169
|
+
<div><span class="text-muted block text-xs">Created</span><span class="text-primary">${created}</span></div>
|
|
170
|
+
<div><span class="text-muted block text-xs">Updated</span><span class="text-primary">${updated}</span></div>
|
|
171
|
+
<div><span class="text-muted block text-xs">Completed</span><span class="text-primary">${completed}</span></div>
|
|
171
172
|
</div>`;
|
|
172
173
|
|
|
173
|
-
//
|
|
174
|
+
// Metrics section (react-loop telemetry)
|
|
175
|
+
const metricsContainer = this.querySelector('#detailMetrics');
|
|
176
|
+
if (task.metrics) {
|
|
177
|
+
const m = task.metrics;
|
|
178
|
+
metricsContainer.innerHTML = `
|
|
179
|
+
<div class="panel-dim">
|
|
180
|
+
<div class="flex items-center gap-2 mb-3">
|
|
181
|
+
<i class="fas fa-chart-line text-accent text-sm"></i>
|
|
182
|
+
<span class="text-sm font-medium text-secondary">React-Loop Metrics</span>
|
|
183
|
+
</div>
|
|
184
|
+
<div class="grid grid-cols-6 gap-4 text-sm">
|
|
185
|
+
<div><span class="text-muted block text-xs">Iteration</span><span class="text-primary font-mono">${m.iteration}</span></div>
|
|
186
|
+
<div><span class="text-muted block text-xs">Messages</span><span class="text-primary font-mono">${m.messageCount}</span></div>
|
|
187
|
+
<div><span class="text-muted block text-xs">Images</span><span class="text-primary font-mono">${m.imageCount}</span></div>
|
|
188
|
+
<div><span class="text-muted block text-xs">Context Size</span><span class="text-primary font-mono">${formatContextSize(m.contextChars)}</span></div>
|
|
189
|
+
<div><span class="text-muted block text-xs">Input Tokens</span><span class="text-primary font-mono">${m.inputTokens ? m.inputTokens.toLocaleString() : '-'}</span></div>
|
|
190
|
+
<div><span class="text-muted block text-xs">Output Tokens</span><span class="text-primary font-mono">${m.outputTokens ? m.outputTokens.toLocaleString() : '-'}</span></div>
|
|
191
|
+
</div>
|
|
192
|
+
</div>`;
|
|
193
|
+
} else {
|
|
194
|
+
metricsContainer.innerHTML = '';
|
|
195
|
+
}
|
|
196
|
+
|
|
174
197
|
this.querySelector('#detailInput').innerHTML = `
|
|
175
|
-
<details
|
|
176
|
-
<summary class="
|
|
177
|
-
<i class="fas fa-chevron-right text-xs mr-1
|
|
178
|
-
Input
|
|
198
|
+
<details>
|
|
199
|
+
<summary class="text-sm font-medium text-secondary">
|
|
200
|
+
<i class="fas fa-chevron-right text-xs mr-1 chevron-icon"></i> Input
|
|
179
201
|
</summary>
|
|
180
|
-
<pre class="mt-2
|
|
202
|
+
<pre class="mt-2 panel-sm text-xs text-primary overflow-x-auto">${escapeHtml(JSON.stringify(task.input, null, 2))}</pre>
|
|
181
203
|
</details>`;
|
|
182
204
|
|
|
183
|
-
// Result / Error section
|
|
184
205
|
const resultContainer = this.querySelector('#detailResult');
|
|
185
206
|
if (task.error) {
|
|
186
207
|
resultContainer.innerHTML = `
|
|
187
208
|
<div>
|
|
188
|
-
<span class="text-sm font-medium text-red
|
|
189
|
-
<pre class="
|
|
209
|
+
<span class="text-sm font-medium text-red block mb-2">Error</span>
|
|
210
|
+
<pre class="badge-outline-red rounded-lg p-3 text-xs overflow-x-auto">${escapeHtml(task.error)}</pre>
|
|
190
211
|
</div>`;
|
|
191
212
|
} else if (task.result) {
|
|
192
213
|
resultContainer.innerHTML = `
|
|
193
|
-
<details open
|
|
194
|
-
<summary class="
|
|
195
|
-
<i class="fas fa-chevron-right text-xs mr-1
|
|
196
|
-
Result
|
|
214
|
+
<details open>
|
|
215
|
+
<summary class="text-sm font-medium text-secondary">
|
|
216
|
+
<i class="fas fa-chevron-right text-xs mr-1 chevron-icon"></i> Result
|
|
197
217
|
</summary>
|
|
198
|
-
<pre class="mt-2
|
|
218
|
+
<pre class="mt-2 panel-sm text-xs text-primary overflow-x-auto overflow-y-auto monitor-scroll-panel">${escapeHtml(JSON.stringify(task.result, null, 2))}</pre>
|
|
199
219
|
</details>`;
|
|
200
220
|
} else {
|
|
201
|
-
resultContainer.innerHTML =
|
|
202
|
-
<div class="text-sm text-gray-500 italic">Awaiting result...</div>`;
|
|
221
|
+
resultContainer.innerHTML = `<div class="text-sm text-muted italic">Awaiting result...</div>`;
|
|
203
222
|
}
|
|
204
223
|
|
|
205
|
-
// Input-required section
|
|
206
224
|
const inputReqContainer = this.querySelector('#detailInputRequest');
|
|
207
225
|
if (task.status === 'input-required' && task.inputRequest) {
|
|
208
226
|
inputReqContainer.innerHTML = `
|
|
209
|
-
<div class="
|
|
227
|
+
<div class="interrupt-prompt">
|
|
210
228
|
<div class="flex items-center gap-2 mb-3">
|
|
211
|
-
<i class="fas fa-question-circle text-amber
|
|
212
|
-
<span class="text-sm font-medium text-amber
|
|
229
|
+
<i class="fas fa-question-circle text-amber"></i>
|
|
230
|
+
<span class="text-sm font-medium text-amber">Input Required</span>
|
|
213
231
|
</div>
|
|
214
|
-
<p class="text-sm text-
|
|
232
|
+
<p class="text-sm text-primary mb-3">${escapeHtml(task.inputRequest.question)}</p>
|
|
215
233
|
<div class="flex gap-2">
|
|
216
|
-
<input id="respondInput" type="text" placeholder="Type your response..."
|
|
217
|
-
|
|
218
|
-
<button id="respondBtn" class="px-4 py-2 bg-amber-500 hover:bg-amber-600 text-white text-sm font-medium rounded-lg transition-colors">
|
|
219
|
-
Send
|
|
220
|
-
</button>
|
|
234
|
+
<input id="respondInput" type="text" placeholder="Type your response..." class="input flex-1 text-sm" />
|
|
235
|
+
<button id="respondBtn" class="btn btn-accent btn-sm">Send</button>
|
|
221
236
|
</div>
|
|
222
237
|
</div>`;
|
|
223
238
|
this.querySelector('#respondBtn').addEventListener('click', () => this.handleRespond());
|
|
@@ -232,13 +247,80 @@ export class MonitorView extends Component {
|
|
|
232
247
|
const actionsContainer = this.querySelector('#detailActions');
|
|
233
248
|
if (['submitted', 'working', 'input-required'].includes(task.status)) {
|
|
234
249
|
actionsContainer.innerHTML = `
|
|
235
|
-
<button id="cancelBtn" class="
|
|
236
|
-
<i class="fas fa-ban
|
|
250
|
+
<button id="cancelBtn" class="btn btn-danger btn-sm">
|
|
251
|
+
<i class="fas fa-ban"></i> Cancel Task
|
|
237
252
|
</button>`;
|
|
238
253
|
this.querySelector('#cancelBtn').addEventListener('click', () => this.handleCancel());
|
|
239
254
|
} else {
|
|
240
255
|
actionsContainer.innerHTML = '';
|
|
241
256
|
}
|
|
257
|
+
|
|
258
|
+
// Activity feed (events + LLM output)
|
|
259
|
+
this.renderActivityFeed();
|
|
260
|
+
}
|
|
261
|
+
|
|
262
|
+
renderActivityFeed() {
|
|
263
|
+
const container = this.querySelector('#detailActivity');
|
|
264
|
+
const events = this.selectedTask?.events;
|
|
265
|
+
if (!events?.length) {
|
|
266
|
+
container.innerHTML = '';
|
|
267
|
+
return;
|
|
268
|
+
}
|
|
269
|
+
|
|
270
|
+
const rows = events.map(evt => {
|
|
271
|
+
const time = new Date(evt.timestamp).toLocaleTimeString();
|
|
272
|
+
if (evt.type === 'tool_start') {
|
|
273
|
+
const inputStr = typeof evt.input === 'string' ? evt.input : JSON.stringify(evt.input ?? {});
|
|
274
|
+
const truncInput = inputStr.length > 120 ? inputStr.slice(0, 120) + '...' : inputStr;
|
|
275
|
+
return `<div class="monitor-event">
|
|
276
|
+
<span class="monitor-event-time">${time}</span>
|
|
277
|
+
<span class="text-xs"><i class="fas fa-play text-blue mr-1"></i><span class="text-blue-300 font-medium">${escapeHtml(evt.tool)}</span> <span class="text-muted">${escapeHtml(truncInput)}</span></span>
|
|
278
|
+
</div>`;
|
|
279
|
+
}
|
|
280
|
+
if (evt.type === 'tool_end') {
|
|
281
|
+
let outputStr = '';
|
|
282
|
+
if (Array.isArray(evt.output)) {
|
|
283
|
+
outputStr = evt.output.map(p => p.type === 'image' ? `[image ${formatContextSize(p.bytes)}]` : p.text || '').join(' ');
|
|
284
|
+
} else if (typeof evt.output === 'string') {
|
|
285
|
+
outputStr = evt.output;
|
|
286
|
+
}
|
|
287
|
+
const truncOutput = outputStr.length > 200 ? outputStr.slice(0, 200) + '...' : outputStr;
|
|
288
|
+
return `<div class="monitor-event">
|
|
289
|
+
<span class="monitor-event-time">${time}</span>
|
|
290
|
+
<span class="text-xs"><i class="fas fa-check text-green mr-1"></i><span class="text-green-300 font-medium">${escapeHtml(evt.tool)}</span> <span class="text-secondary">${escapeHtml(truncOutput)}</span></span>
|
|
291
|
+
</div>`;
|
|
292
|
+
}
|
|
293
|
+
if (evt.type === 'thinking') {
|
|
294
|
+
const truncContent = (evt.content || '').length > 200 ? evt.content.slice(0, 200) + '...' : evt.content;
|
|
295
|
+
return `<div class="monitor-event">
|
|
296
|
+
<span class="monitor-event-time">${time}</span>
|
|
297
|
+
<span class="text-xs"><i class="fas fa-brain text-purple mr-1"></i><span class="text-purple-300">${escapeHtml(truncContent)}</span></span>
|
|
298
|
+
</div>`;
|
|
299
|
+
}
|
|
300
|
+
if (evt.type === 'content') {
|
|
301
|
+
const truncContent = (evt.content || '').length > 300 ? evt.content.slice(0, 300) + '...' : evt.content;
|
|
302
|
+
return `<div class="monitor-event">
|
|
303
|
+
<span class="monitor-event-time">${time}</span>
|
|
304
|
+
<span class="text-xs"><i class="fas fa-comment text-secondary mr-1"></i><span class="text-primary">${escapeHtml(truncContent)}</span></span>
|
|
305
|
+
</div>`;
|
|
306
|
+
}
|
|
307
|
+
return '';
|
|
308
|
+
}).join('');
|
|
309
|
+
|
|
310
|
+
container.innerHTML = `
|
|
311
|
+
<details open>
|
|
312
|
+
<summary class="text-sm font-medium text-secondary">
|
|
313
|
+
<i class="fas fa-chevron-right text-xs mr-1 chevron-icon"></i>
|
|
314
|
+
Activity (${events.length} events)
|
|
315
|
+
</summary>
|
|
316
|
+
<div class="mt-2 panel-sm overflow-y-auto monitor-scroll-panel">
|
|
317
|
+
${rows}
|
|
318
|
+
</div>
|
|
319
|
+
</details>`;
|
|
320
|
+
|
|
321
|
+
// Auto-scroll to bottom
|
|
322
|
+
const feed = container.querySelector('.overflow-y-auto');
|
|
323
|
+
if (feed) feed.scrollTop = feed.scrollHeight;
|
|
242
324
|
}
|
|
243
325
|
|
|
244
326
|
async handleCancel() {
|
|
@@ -275,6 +357,15 @@ export class MonitorView extends Component {
|
|
|
275
357
|
if (data.type === 'status' && this.selectedTask?.id === taskId) {
|
|
276
358
|
this.loadTasks();
|
|
277
359
|
}
|
|
360
|
+
if (data.type === 'metrics' && this.selectedTask?.id === taskId) {
|
|
361
|
+
this.selectedTask.metrics = data.metrics;
|
|
362
|
+
this.renderDetailPanel();
|
|
363
|
+
}
|
|
364
|
+
if (data.type === 'events' && this.selectedTask?.id === taskId) {
|
|
365
|
+
if (!this.selectedTask.events) this.selectedTask.events = [];
|
|
366
|
+
this.selectedTask.events.push(...data.events);
|
|
367
|
+
this.renderActivityFeed();
|
|
368
|
+
}
|
|
278
369
|
if (data.type === 'done') {
|
|
279
370
|
this.closeEventSource();
|
|
280
371
|
}
|
|
@@ -319,20 +410,20 @@ export class MonitorView extends Component {
|
|
|
319
410
|
|
|
320
411
|
template() {
|
|
321
412
|
return `
|
|
322
|
-
<div class="space-y-6 h-full overflow-y-auto pb-
|
|
323
|
-
<div class="flex items-center justify-between border-b
|
|
413
|
+
<div class="space-y-6 h-full overflow-y-auto pb-6 view-panel">
|
|
414
|
+
<div class="flex items-center justify-between border-b pb-4">
|
|
324
415
|
<div>
|
|
325
|
-
<h2 class="text-lg font-semibold text-
|
|
326
|
-
<p class="text-xs text-
|
|
416
|
+
<h2 class="text-lg font-semibold text-primary">Monitor</h2>
|
|
417
|
+
<p class="text-xs text-muted mt-1">Track async task execution in real time</p>
|
|
327
418
|
</div>
|
|
328
419
|
<div class="flex items-center gap-3">
|
|
329
|
-
<select id="filterKind" class="
|
|
420
|
+
<select id="filterKind" class="select text-sm">
|
|
330
421
|
<option value="">All kinds</option>
|
|
331
422
|
<option value="agent">Agent</option>
|
|
332
423
|
<option value="workflow">Workflow</option>
|
|
333
424
|
<option value="llm">LLM</option>
|
|
334
425
|
</select>
|
|
335
|
-
<select id="filterStatus" class="
|
|
426
|
+
<select id="filterStatus" class="select text-sm">
|
|
336
427
|
<option value="">All statuses</option>
|
|
337
428
|
<option value="submitted">Submitted</option>
|
|
338
429
|
<option value="working">Working</option>
|
|
@@ -341,7 +432,7 @@ export class MonitorView extends Component {
|
|
|
341
432
|
<option value="canceled">Canceled</option>
|
|
342
433
|
<option value="input-required">Input Required</option>
|
|
343
434
|
</select>
|
|
344
|
-
<button id="refreshBtn" class="
|
|
435
|
+
<button id="refreshBtn" class="btn-ghost" title="Refresh">
|
|
345
436
|
<i class="fas fa-sync-alt text-sm"></i>
|
|
346
437
|
</button>
|
|
347
438
|
</div>
|
|
@@ -349,20 +440,20 @@ export class MonitorView extends Component {
|
|
|
349
440
|
|
|
350
441
|
<div id="tasksListContainer"></div>
|
|
351
442
|
|
|
352
|
-
<div id="taskDetailArea" class="hidden border-t
|
|
353
|
-
<div class="
|
|
443
|
+
<div id="taskDetailArea" class="hidden border-t pt-4 space-y-4">
|
|
444
|
+
<div class="panel-dim">
|
|
354
445
|
<div class="flex items-center justify-between">
|
|
355
446
|
<div id="detailHeader"></div>
|
|
356
|
-
<button id="closeDetailBtn" class="
|
|
357
|
-
<i class="fas fa-times"></i>
|
|
358
|
-
</button>
|
|
447
|
+
<button id="closeDetailBtn" class="btn-ghost"><i class="fas fa-times"></i></button>
|
|
359
448
|
</div>
|
|
360
449
|
</div>
|
|
361
450
|
|
|
362
|
-
<div id="detailMeta" class="
|
|
451
|
+
<div id="detailMeta" class="panel-dim"></div>
|
|
452
|
+
<div id="detailMetrics"></div>
|
|
363
453
|
<div id="detailInputRequest"></div>
|
|
364
454
|
<div id="detailInput"></div>
|
|
365
455
|
<div id="detailResult"></div>
|
|
456
|
+
<div id="detailActivity"></div>
|
|
366
457
|
<div id="detailActions"></div>
|
|
367
458
|
</div>
|
|
368
459
|
</div>
|
|
@@ -371,18 +462,18 @@ export class MonitorView extends Component {
|
|
|
371
462
|
}
|
|
372
463
|
|
|
373
464
|
function escapeHtml(str) {
|
|
374
|
-
|
|
375
|
-
|
|
376
|
-
|
|
465
|
+
return sharedEscapeHtml(str);
|
|
466
|
+
}
|
|
467
|
+
|
|
468
|
+
function kindBadgeVariant(kind) {
|
|
469
|
+
const map = { agent: 'blue', workflow: 'purple', llm: 'emerald' };
|
|
470
|
+
return map[kind] || 'gray';
|
|
377
471
|
}
|
|
378
472
|
|
|
379
|
-
function
|
|
380
|
-
|
|
381
|
-
|
|
382
|
-
|
|
383
|
-
llm: 'bg-emerald-500/20 text-emerald-400',
|
|
384
|
-
};
|
|
385
|
-
return map[kind] || 'bg-gray-500/20 text-gray-400';
|
|
473
|
+
function formatContextSize(chars) {
|
|
474
|
+
if (chars >= 1_000_000) return `${(chars / 1_000_000).toFixed(1)}M`;
|
|
475
|
+
if (chars >= 1_000) return `${(chars / 1_000).toFixed(1)}K`;
|
|
476
|
+
return `${chars}`;
|
|
386
477
|
}
|
|
387
478
|
|
|
388
479
|
customElements.define('monitor-view', MonitorView);
|
|
@@ -6,14 +6,13 @@ export class NavBar extends Component {
|
|
|
6
6
|
constructor() {
|
|
7
7
|
super();
|
|
8
8
|
this.tabs = [
|
|
9
|
-
{ id: 'agents', label: 'Agents', icon: 'fa-robot'
|
|
10
|
-
{ id: '
|
|
11
|
-
{ id: '
|
|
12
|
-
{ id: '
|
|
13
|
-
{ id: '
|
|
14
|
-
{ id: '
|
|
15
|
-
{ id: '
|
|
16
|
-
{ id: 'ide', label: 'IDE', icon: 'fa-code', color: 'green' }
|
|
9
|
+
{ id: 'agents', label: 'Agents', icon: 'fa-robot' },
|
|
10
|
+
{ id: 'knowledge', label: 'Knowledge', icon: 'fa-brain' },
|
|
11
|
+
{ id: 'graph', label: 'Graph', icon: 'fa-network-wired' },
|
|
12
|
+
{ id: 'mcp', label: 'MCP', icon: 'fa-server' },
|
|
13
|
+
{ id: 'monitor', label: 'Monitor', icon: 'fa-tasks' },
|
|
14
|
+
{ id: 'llm', label: 'LLM', icon: 'fa-microchip' },
|
|
15
|
+
{ id: 'ide', label: 'IDE', icon: 'fa-code' }
|
|
17
16
|
];
|
|
18
17
|
}
|
|
19
18
|
|
|
@@ -27,41 +26,32 @@ export class NavBar extends Component {
|
|
|
27
26
|
});
|
|
28
27
|
});
|
|
29
28
|
|
|
30
|
-
// Sync visual state when tab changes externally (browser back/forward)
|
|
31
29
|
store.addEventListener('state-change', (e) => {
|
|
32
30
|
if (e.detail.key === 'activeTab') {
|
|
33
31
|
this.updateActiveState(e.detail.value);
|
|
34
32
|
}
|
|
35
33
|
});
|
|
36
34
|
|
|
37
|
-
// Initialize state
|
|
38
35
|
this.updateActiveState(store.get('activeTab'));
|
|
39
36
|
}
|
|
40
37
|
|
|
41
38
|
updateActiveState(activeId) {
|
|
42
39
|
this.querySelectorAll('.tab-btn').forEach(btn => {
|
|
43
|
-
|
|
44
|
-
const color = btn.dataset.color;
|
|
45
|
-
const isActive = tabId === activeId;
|
|
46
|
-
|
|
47
|
-
if (isActive) {
|
|
48
|
-
btn.classList.add(`border-${color}-500`, `text-${color}-400`);
|
|
49
|
-
btn.classList.remove('border-transparent', 'text-gray-400', 'hover:text-gray-300');
|
|
50
|
-
} else {
|
|
51
|
-
btn.classList.remove(`border-${color}-500`, `text-${color}-400`);
|
|
52
|
-
btn.classList.add('border-transparent', 'text-gray-400', 'hover:text-gray-300');
|
|
53
|
-
}
|
|
40
|
+
btn.classList.toggle('active', btn.dataset.tab === activeId);
|
|
54
41
|
});
|
|
55
42
|
}
|
|
56
43
|
|
|
57
44
|
template() {
|
|
58
45
|
return `
|
|
59
|
-
<div class="
|
|
60
|
-
<
|
|
46
|
+
<div class="flex flex-col h-full">
|
|
47
|
+
<div class="sidebar-brand">
|
|
48
|
+
<img src="/assets/logo.png" alt="Agent Orcha" class="sidebar-logo">
|
|
49
|
+
<span>Agent Orcha</span>
|
|
50
|
+
</div>
|
|
51
|
+
<nav class="flex-1 overflow-y-auto">
|
|
61
52
|
${this.tabs.map(tab => `
|
|
62
|
-
<button class="tab-btn
|
|
63
|
-
|
|
64
|
-
<i class="fas ${tab.icon} text-sm group-hover:scale-110 transition-transform"></i>
|
|
53
|
+
<button class="tab-btn" data-tab="${tab.id}">
|
|
54
|
+
<i class="fas ${tab.icon} tab-icon"></i>
|
|
65
55
|
<span>${tab.label}</span>
|
|
66
56
|
</button>
|
|
67
57
|
`).join('')}
|