hanseol 3.2.7
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/LICENSE +21 -0
- package/README.md +267 -0
- package/dist/agents/base/base-agent.d.ts +38 -0
- package/dist/agents/base/base-agent.d.ts.map +1 -0
- package/dist/agents/base/base-agent.js +69 -0
- package/dist/agents/base/base-agent.js.map +1 -0
- package/dist/agents/docs-search/index.d.ts +33 -0
- package/dist/agents/docs-search/index.d.ts.map +1 -0
- package/dist/agents/docs-search/index.js +244 -0
- package/dist/agents/docs-search/index.js.map +1 -0
- package/dist/agents/index.d.ts +4 -0
- package/dist/agents/index.d.ts.map +1 -0
- package/dist/agents/index.js +4 -0
- package/dist/agents/index.js.map +1 -0
- package/dist/agents/planner/index.d.ts +15 -0
- package/dist/agents/planner/index.d.ts.map +1 -0
- package/dist/agents/planner/index.js +270 -0
- package/dist/agents/planner/index.js.map +1 -0
- package/dist/cli.d.ts +3 -0
- package/dist/cli.d.ts.map +1 -0
- package/dist/cli.js +97 -0
- package/dist/cli.js.map +1 -0
- package/dist/constants.d.ts +8 -0
- package/dist/constants.d.ts.map +1 -0
- package/dist/constants.js +10 -0
- package/dist/constants.js.map +1 -0
- package/dist/core/auth/auth-manager.d.ts +23 -0
- package/dist/core/auth/auth-manager.d.ts.map +1 -0
- package/dist/core/auth/auth-manager.js +159 -0
- package/dist/core/auth/auth-manager.js.map +1 -0
- package/dist/core/auth/index.d.ts +4 -0
- package/dist/core/auth/index.d.ts.map +1 -0
- package/dist/core/auth/index.js +4 -0
- package/dist/core/auth/index.js.map +1 -0
- package/dist/core/auth/jwt-decoder.d.ts +7 -0
- package/dist/core/auth/jwt-decoder.d.ts.map +1 -0
- package/dist/core/auth/jwt-decoder.js +101 -0
- package/dist/core/auth/jwt-decoder.js.map +1 -0
- package/dist/core/auth/sso-client.d.ts +20 -0
- package/dist/core/auth/sso-client.d.ts.map +1 -0
- package/dist/core/auth/sso-client.js +164 -0
- package/dist/core/auth/sso-client.js.map +1 -0
- package/dist/core/auth/types.d.ts +45 -0
- package/dist/core/auth/types.d.ts.map +1 -0
- package/dist/core/auth/types.js +2 -0
- package/dist/core/auth/types.js.map +1 -0
- package/dist/core/compact/compact-manager.d.ts +22 -0
- package/dist/core/compact/compact-manager.d.ts.map +1 -0
- package/dist/core/compact/compact-manager.js +74 -0
- package/dist/core/compact/compact-manager.js.map +1 -0
- package/dist/core/compact/compact-prompts.d.ts +11 -0
- package/dist/core/compact/compact-prompts.d.ts.map +1 -0
- package/dist/core/compact/compact-prompts.js +80 -0
- package/dist/core/compact/compact-prompts.js.map +1 -0
- package/dist/core/compact/context-tracker.d.ts +28 -0
- package/dist/core/compact/context-tracker.d.ts.map +1 -0
- package/dist/core/compact/context-tracker.js +71 -0
- package/dist/core/compact/context-tracker.js.map +1 -0
- package/dist/core/compact/index.d.ts +4 -0
- package/dist/core/compact/index.d.ts.map +1 -0
- package/dist/core/compact/index.js +4 -0
- package/dist/core/compact/index.js.map +1 -0
- package/dist/core/config/config-manager.d.ts +43 -0
- package/dist/core/config/config-manager.d.ts.map +1 -0
- package/dist/core/config/config-manager.js +247 -0
- package/dist/core/config/config-manager.js.map +1 -0
- package/dist/core/config/index.d.ts +2 -0
- package/dist/core/config/index.d.ts.map +1 -0
- package/dist/core/config/index.js +2 -0
- package/dist/core/config/index.js.map +1 -0
- package/dist/core/docs-manager.d.ts +46 -0
- package/dist/core/docs-manager.d.ts.map +1 -0
- package/dist/core/docs-manager.js +475 -0
- package/dist/core/docs-manager.js.map +1 -0
- package/dist/core/llm/index.d.ts +2 -0
- package/dist/core/llm/index.d.ts.map +1 -0
- package/dist/core/llm/index.js +2 -0
- package/dist/core/llm/index.js.map +1 -0
- package/dist/core/llm/llm-client.d.ts +97 -0
- package/dist/core/llm/llm-client.d.ts.map +1 -0
- package/dist/core/llm/llm-client.js +1002 -0
- package/dist/core/llm/llm-client.js.map +1 -0
- package/dist/core/model-sync.d.ts +20 -0
- package/dist/core/model-sync.d.ts.map +1 -0
- package/dist/core/model-sync.js +182 -0
- package/dist/core/model-sync.js.map +1 -0
- package/dist/core/notification-manager.d.ts +23 -0
- package/dist/core/notification-manager.d.ts.map +1 -0
- package/dist/core/notification-manager.js +76 -0
- package/dist/core/notification-manager.js.map +1 -0
- package/dist/core/s3-auto-updater.d.ts +51 -0
- package/dist/core/s3-auto-updater.d.ts.map +1 -0
- package/dist/core/s3-auto-updater.js +292 -0
- package/dist/core/s3-auto-updater.js.map +1 -0
- package/dist/core/session/index.d.ts +2 -0
- package/dist/core/session/index.d.ts.map +1 -0
- package/dist/core/session/index.js +2 -0
- package/dist/core/session/index.js.map +1 -0
- package/dist/core/session/session-manager.d.ts +71 -0
- package/dist/core/session/session-manager.d.ts.map +1 -0
- package/dist/core/session/session-manager.js +235 -0
- package/dist/core/session/session-manager.js.map +1 -0
- package/dist/core/slash-command-handler.d.ts +32 -0
- package/dist/core/slash-command-handler.d.ts.map +1 -0
- package/dist/core/slash-command-handler.js +402 -0
- package/dist/core/slash-command-handler.js.map +1 -0
- package/dist/core/usage-tracker.d.ts +70 -0
- package/dist/core/usage-tracker.d.ts.map +1 -0
- package/dist/core/usage-tracker.js +251 -0
- package/dist/core/usage-tracker.js.map +1 -0
- package/dist/errors/base.d.ts +22 -0
- package/dist/errors/base.d.ts.map +1 -0
- package/dist/errors/base.js +43 -0
- package/dist/errors/base.js.map +1 -0
- package/dist/errors/file.d.ts +31 -0
- package/dist/errors/file.d.ts.map +1 -0
- package/dist/errors/file.js +110 -0
- package/dist/errors/file.js.map +1 -0
- package/dist/errors/index.d.ts +10 -0
- package/dist/errors/index.d.ts.map +1 -0
- package/dist/errors/index.js +41 -0
- package/dist/errors/index.js.map +1 -0
- package/dist/errors/llm.d.ts +26 -0
- package/dist/errors/llm.d.ts.map +1 -0
- package/dist/errors/llm.js +86 -0
- package/dist/errors/llm.js.map +1 -0
- package/dist/errors/network.d.ts +19 -0
- package/dist/errors/network.d.ts.map +1 -0
- package/dist/errors/network.js +82 -0
- package/dist/errors/network.js.map +1 -0
- package/dist/errors/validation.d.ts +19 -0
- package/dist/errors/validation.d.ts.map +1 -0
- package/dist/errors/validation.js +62 -0
- package/dist/errors/validation.js.map +1 -0
- package/dist/eval/eval-runner.d.ts +24 -0
- package/dist/eval/eval-runner.d.ts.map +1 -0
- package/dist/eval/eval-runner.js +291 -0
- package/dist/eval/eval-runner.js.map +1 -0
- package/dist/eval/index.d.ts +3 -0
- package/dist/eval/index.d.ts.map +1 -0
- package/dist/eval/index.js +3 -0
- package/dist/eval/index.js.map +1 -0
- package/dist/eval/types.d.ts +77 -0
- package/dist/eval/types.d.ts.map +1 -0
- package/dist/eval/types.js +2 -0
- package/dist/eval/types.js.map +1 -0
- package/dist/index.d.ts +4 -0
- package/dist/index.d.ts.map +1 -0
- package/dist/index.js +6 -0
- package/dist/index.js.map +1 -0
- package/dist/orchestration/index.d.ts +4 -0
- package/dist/orchestration/index.d.ts.map +1 -0
- package/dist/orchestration/index.js +3 -0
- package/dist/orchestration/index.js.map +1 -0
- package/dist/orchestration/plan-executor.d.ts +28 -0
- package/dist/orchestration/plan-executor.d.ts.map +1 -0
- package/dist/orchestration/plan-executor.js +368 -0
- package/dist/orchestration/plan-executor.js.map +1 -0
- package/dist/orchestration/types.d.ts +65 -0
- package/dist/orchestration/types.d.ts.map +1 -0
- package/dist/orchestration/types.js +2 -0
- package/dist/orchestration/types.js.map +1 -0
- package/dist/orchestration/utils.d.ts +13 -0
- package/dist/orchestration/utils.d.ts.map +1 -0
- package/dist/orchestration/utils.js +81 -0
- package/dist/orchestration/utils.js.map +1 -0
- package/dist/prompts/agents/docs-search-decision.d.ts +6 -0
- package/dist/prompts/agents/docs-search-decision.d.ts.map +1 -0
- package/dist/prompts/agents/docs-search-decision.js +46 -0
- package/dist/prompts/agents/docs-search-decision.js.map +1 -0
- package/dist/prompts/agents/docs-search.d.ts +4 -0
- package/dist/prompts/agents/docs-search.d.ts.map +1 -0
- package/dist/prompts/agents/docs-search.js +70 -0
- package/dist/prompts/agents/docs-search.js.map +1 -0
- package/dist/prompts/agents/planning.d.ts +4 -0
- package/dist/prompts/agents/planning.d.ts.map +1 -0
- package/dist/prompts/agents/planning.js +119 -0
- package/dist/prompts/agents/planning.js.map +1 -0
- package/dist/prompts/index.d.ts +10 -0
- package/dist/prompts/index.d.ts.map +1 -0
- package/dist/prompts/index.js +10 -0
- package/dist/prompts/index.js.map +1 -0
- package/dist/prompts/shared/codebase-rules.d.ts +4 -0
- package/dist/prompts/shared/codebase-rules.d.ts.map +1 -0
- package/dist/prompts/shared/codebase-rules.js +16 -0
- package/dist/prompts/shared/codebase-rules.js.map +1 -0
- package/dist/prompts/shared/git-rules.d.ts +2 -0
- package/dist/prompts/shared/git-rules.d.ts.map +1 -0
- package/dist/prompts/shared/git-rules.js +87 -0
- package/dist/prompts/shared/git-rules.js.map +1 -0
- package/dist/prompts/shared/language-rules.d.ts +4 -0
- package/dist/prompts/shared/language-rules.d.ts.map +1 -0
- package/dist/prompts/shared/language-rules.js +22 -0
- package/dist/prompts/shared/language-rules.js.map +1 -0
- package/dist/prompts/shared/tool-usage.d.ts +12 -0
- package/dist/prompts/shared/tool-usage.d.ts.map +1 -0
- package/dist/prompts/shared/tool-usage.js +49 -0
- package/dist/prompts/shared/tool-usage.js.map +1 -0
- package/dist/prompts/system/compact.d.ts +3 -0
- package/dist/prompts/system/compact.d.ts.map +1 -0
- package/dist/prompts/system/compact.js +73 -0
- package/dist/prompts/system/compact.js.map +1 -0
- package/dist/prompts/system/plan-execute.d.ts +3 -0
- package/dist/prompts/system/plan-execute.d.ts.map +1 -0
- package/dist/prompts/system/plan-execute.js +83 -0
- package/dist/prompts/system/plan-execute.js.map +1 -0
- package/dist/tools/browser/browser-client.d.ts +107 -0
- package/dist/tools/browser/browser-client.d.ts.map +1 -0
- package/dist/tools/browser/browser-client.js +958 -0
- package/dist/tools/browser/browser-client.js.map +1 -0
- package/dist/tools/browser/browser-tools.d.ts +17 -0
- package/dist/tools/browser/browser-tools.d.ts.map +1 -0
- package/dist/tools/browser/browser-tools.js +888 -0
- package/dist/tools/browser/browser-tools.js.map +1 -0
- package/dist/tools/browser/index.d.ts +7 -0
- package/dist/tools/browser/index.d.ts.map +1 -0
- package/dist/tools/browser/index.js +17 -0
- package/dist/tools/browser/index.js.map +1 -0
- package/dist/tools/index.d.ts +4 -0
- package/dist/tools/index.d.ts.map +1 -0
- package/dist/tools/index.js +4 -0
- package/dist/tools/index.js.map +1 -0
- package/dist/tools/llm/agents/docs-search-tools.d.ts +17 -0
- package/dist/tools/llm/agents/docs-search-tools.d.ts.map +1 -0
- package/dist/tools/llm/agents/docs-search-tools.js +265 -0
- package/dist/tools/llm/agents/docs-search-tools.js.map +1 -0
- package/dist/tools/llm/agents/index.d.ts +4 -0
- package/dist/tools/llm/agents/index.d.ts.map +1 -0
- package/dist/tools/llm/agents/index.js +3 -0
- package/dist/tools/llm/agents/index.js.map +1 -0
- package/dist/tools/llm/index.d.ts +3 -0
- package/dist/tools/llm/index.d.ts.map +1 -0
- package/dist/tools/llm/index.js +3 -0
- package/dist/tools/llm/index.js.map +1 -0
- package/dist/tools/llm/simple/ask-user-tool.d.ts +5 -0
- package/dist/tools/llm/simple/ask-user-tool.d.ts.map +1 -0
- package/dist/tools/llm/simple/ask-user-tool.js +7 -0
- package/dist/tools/llm/simple/ask-user-tool.js.map +1 -0
- package/dist/tools/llm/simple/background-bash-tool.d.ts +30 -0
- package/dist/tools/llm/simple/background-bash-tool.d.ts.map +1 -0
- package/dist/tools/llm/simple/background-bash-tool.js +320 -0
- package/dist/tools/llm/simple/background-bash-tool.js.map +1 -0
- package/dist/tools/llm/simple/background-powershell-tool.d.ts +30 -0
- package/dist/tools/llm/simple/background-powershell-tool.d.ts.map +1 -0
- package/dist/tools/llm/simple/background-powershell-tool.js +302 -0
- package/dist/tools/llm/simple/background-powershell-tool.js.map +1 -0
- package/dist/tools/llm/simple/bash-tool.d.ts +4 -0
- package/dist/tools/llm/simple/bash-tool.d.ts.map +1 -0
- package/dist/tools/llm/simple/bash-tool.js +167 -0
- package/dist/tools/llm/simple/bash-tool.js.map +1 -0
- package/dist/tools/llm/simple/docs-search-agent-tool.d.ts +6 -0
- package/dist/tools/llm/simple/docs-search-agent-tool.d.ts.map +1 -0
- package/dist/tools/llm/simple/docs-search-agent-tool.js +104 -0
- package/dist/tools/llm/simple/docs-search-agent-tool.js.map +1 -0
- package/dist/tools/llm/simple/file-tools.d.ts +12 -0
- package/dist/tools/llm/simple/file-tools.d.ts.map +1 -0
- package/dist/tools/llm/simple/file-tools.js +597 -0
- package/dist/tools/llm/simple/file-tools.js.map +1 -0
- package/dist/tools/llm/simple/final-response-tool.d.ts +12 -0
- package/dist/tools/llm/simple/final-response-tool.d.ts.map +1 -0
- package/dist/tools/llm/simple/final-response-tool.js +107 -0
- package/dist/tools/llm/simple/final-response-tool.js.map +1 -0
- package/dist/tools/llm/simple/index.d.ts +11 -0
- package/dist/tools/llm/simple/index.d.ts.map +1 -0
- package/dist/tools/llm/simple/index.js +20 -0
- package/dist/tools/llm/simple/index.js.map +1 -0
- package/dist/tools/llm/simple/planning-tools.d.ts +5 -0
- package/dist/tools/llm/simple/planning-tools.d.ts.map +1 -0
- package/dist/tools/llm/simple/planning-tools.js +117 -0
- package/dist/tools/llm/simple/planning-tools.js.map +1 -0
- package/dist/tools/llm/simple/powershell-tool.d.ts +4 -0
- package/dist/tools/llm/simple/powershell-tool.d.ts.map +1 -0
- package/dist/tools/llm/simple/powershell-tool.js +150 -0
- package/dist/tools/llm/simple/powershell-tool.js.map +1 -0
- package/dist/tools/llm/simple/simple-tool-executor.d.ts +38 -0
- package/dist/tools/llm/simple/simple-tool-executor.d.ts.map +1 -0
- package/dist/tools/llm/simple/simple-tool-executor.js +132 -0
- package/dist/tools/llm/simple/simple-tool-executor.js.map +1 -0
- package/dist/tools/llm/simple/todo-tools.d.ts +15 -0
- package/dist/tools/llm/simple/todo-tools.d.ts.map +1 -0
- package/dist/tools/llm/simple/todo-tools.js +145 -0
- package/dist/tools/llm/simple/todo-tools.js.map +1 -0
- package/dist/tools/llm/simple/user-interaction-tools.d.ts +21 -0
- package/dist/tools/llm/simple/user-interaction-tools.d.ts.map +1 -0
- package/dist/tools/llm/simple/user-interaction-tools.js +167 -0
- package/dist/tools/llm/simple/user-interaction-tools.js.map +1 -0
- package/dist/tools/office/common/constants.d.ts +194 -0
- package/dist/tools/office/common/constants.d.ts.map +1 -0
- package/dist/tools/office/common/constants.js +169 -0
- package/dist/tools/office/common/constants.js.map +1 -0
- package/dist/tools/office/common/index.d.ts +4 -0
- package/dist/tools/office/common/index.d.ts.map +1 -0
- package/dist/tools/office/common/index.js +3 -0
- package/dist/tools/office/common/index.js.map +1 -0
- package/dist/tools/office/common/types.d.ts +82 -0
- package/dist/tools/office/common/types.d.ts.map +1 -0
- package/dist/tools/office/common/types.js +2 -0
- package/dist/tools/office/common/types.js.map +1 -0
- package/dist/tools/office/common/utils.d.ts +14 -0
- package/dist/tools/office/common/utils.d.ts.map +1 -0
- package/dist/tools/office/common/utils.js +58 -0
- package/dist/tools/office/common/utils.js.map +1 -0
- package/dist/tools/office/excel-client.d.ts +123 -0
- package/dist/tools/office/excel-client.d.ts.map +1 -0
- package/dist/tools/office/excel-client.js +1037 -0
- package/dist/tools/office/excel-client.js.map +1 -0
- package/dist/tools/office/excel-tools/cells.d.ts +10 -0
- package/dist/tools/office/excel-tools/cells.d.ts.map +1 -0
- package/dist/tools/office/excel-tools/cells.js +279 -0
- package/dist/tools/office/excel-tools/cells.js.map +1 -0
- package/dist/tools/office/excel-tools/charts.d.ts +6 -0
- package/dist/tools/office/excel-tools/charts.d.ts.map +1 -0
- package/dist/tools/office/excel-tools/charts.js +124 -0
- package/dist/tools/office/excel-tools/charts.js.map +1 -0
- package/dist/tools/office/excel-tools/comments.d.ts +6 -0
- package/dist/tools/office/excel-tools/comments.d.ts.map +1 -0
- package/dist/tools/office/excel-tools/comments.js +114 -0
- package/dist/tools/office/excel-tools/comments.js.map +1 -0
- package/dist/tools/office/excel-tools/data-ops.d.ts +10 -0
- package/dist/tools/office/excel-tools/data-ops.d.ts.map +1 -0
- package/dist/tools/office/excel-tools/data-ops.js +266 -0
- package/dist/tools/office/excel-tools/data-ops.js.map +1 -0
- package/dist/tools/office/excel-tools/export.d.ts +5 -0
- package/dist/tools/office/excel-tools/export.d.ts.map +1 -0
- package/dist/tools/office/excel-tools/export.js +75 -0
- package/dist/tools/office/excel-tools/export.js.map +1 -0
- package/dist/tools/office/excel-tools/formatting.d.ts +10 -0
- package/dist/tools/office/excel-tools/formatting.d.ts.map +1 -0
- package/dist/tools/office/excel-tools/formatting.js +276 -0
- package/dist/tools/office/excel-tools/formatting.js.map +1 -0
- package/dist/tools/office/excel-tools/index.d.ts +16 -0
- package/dist/tools/office/excel-tools/index.d.ts.map +1 -0
- package/dist/tools/office/excel-tools/index.js +42 -0
- package/dist/tools/office/excel-tools/index.js.map +1 -0
- package/dist/tools/office/excel-tools/launch.d.ts +10 -0
- package/dist/tools/office/excel-tools/launch.d.ts.map +1 -0
- package/dist/tools/office/excel-tools/launch.js +248 -0
- package/dist/tools/office/excel-tools/launch.js.map +1 -0
- package/dist/tools/office/excel-tools/media.d.ts +5 -0
- package/dist/tools/office/excel-tools/media.d.ts.map +1 -0
- package/dist/tools/office/excel-tools/media.js +84 -0
- package/dist/tools/office/excel-tools/media.js.map +1 -0
- package/dist/tools/office/excel-tools/named-ranges.d.ts +6 -0
- package/dist/tools/office/excel-tools/named-ranges.d.ts.map +1 -0
- package/dist/tools/office/excel-tools/named-ranges.js +113 -0
- package/dist/tools/office/excel-tools/named-ranges.js.map +1 -0
- package/dist/tools/office/excel-tools/protection.d.ts +5 -0
- package/dist/tools/office/excel-tools/protection.d.ts.map +1 -0
- package/dist/tools/office/excel-tools/protection.js +75 -0
- package/dist/tools/office/excel-tools/protection.js.map +1 -0
- package/dist/tools/office/excel-tools/rows-columns.d.ts +11 -0
- package/dist/tools/office/excel-tools/rows-columns.d.ts.map +1 -0
- package/dist/tools/office/excel-tools/rows-columns.js +293 -0
- package/dist/tools/office/excel-tools/rows-columns.js.map +1 -0
- package/dist/tools/office/excel-tools/sheets.d.ts +8 -0
- package/dist/tools/office/excel-tools/sheets.d.ts.map +1 -0
- package/dist/tools/office/excel-tools/sheets.js +177 -0
- package/dist/tools/office/excel-tools/sheets.js.map +1 -0
- package/dist/tools/office/excel-tools/validation.d.ts +7 -0
- package/dist/tools/office/excel-tools/validation.d.ts.map +1 -0
- package/dist/tools/office/excel-tools/validation.js +175 -0
- package/dist/tools/office/excel-tools/validation.js.map +1 -0
- package/dist/tools/office/excel-tools.d.ts +3 -0
- package/dist/tools/office/excel-tools.d.ts.map +1 -0
- package/dist/tools/office/excel-tools.js +3 -0
- package/dist/tools/office/excel-tools.js.map +1 -0
- package/dist/tools/office/index.d.ts +6 -0
- package/dist/tools/office/index.d.ts.map +1 -0
- package/dist/tools/office/index.js +9 -0
- package/dist/tools/office/index.js.map +1 -0
- package/dist/tools/office/office-client-base.d.ts +29 -0
- package/dist/tools/office/office-client-base.d.ts.map +1 -0
- package/dist/tools/office/office-client-base.js +148 -0
- package/dist/tools/office/office-client-base.js.map +1 -0
- package/dist/tools/office/office-client.d.ts +196 -0
- package/dist/tools/office/office-client.d.ts.map +1 -0
- package/dist/tools/office/office-client.js +200 -0
- package/dist/tools/office/office-client.js.map +1 -0
- package/dist/tools/office/powerpoint-client.d.ts +135 -0
- package/dist/tools/office/powerpoint-client.d.ts.map +1 -0
- package/dist/tools/office/powerpoint-client.js +1136 -0
- package/dist/tools/office/powerpoint-client.js.map +1 -0
- package/dist/tools/office/powerpoint-tools/effects.d.ts +9 -0
- package/dist/tools/office/powerpoint-tools/effects.d.ts.map +1 -0
- package/dist/tools/office/powerpoint-tools/effects.js +246 -0
- package/dist/tools/office/powerpoint-tools/effects.js.map +1 -0
- package/dist/tools/office/powerpoint-tools/export.d.ts +6 -0
- package/dist/tools/office/powerpoint-tools/export.d.ts.map +1 -0
- package/dist/tools/office/powerpoint-tools/export.js +108 -0
- package/dist/tools/office/powerpoint-tools/export.js.map +1 -0
- package/dist/tools/office/powerpoint-tools/index.d.ts +13 -0
- package/dist/tools/office/powerpoint-tools/index.d.ts.map +1 -0
- package/dist/tools/office/powerpoint-tools/index.js +33 -0
- package/dist/tools/office/powerpoint-tools/index.js.map +1 -0
- package/dist/tools/office/powerpoint-tools/launch.d.ts +9 -0
- package/dist/tools/office/powerpoint-tools/launch.d.ts.map +1 -0
- package/dist/tools/office/powerpoint-tools/launch.js +214 -0
- package/dist/tools/office/powerpoint-tools/launch.js.map +1 -0
- package/dist/tools/office/powerpoint-tools/media.d.ts +8 -0
- package/dist/tools/office/powerpoint-tools/media.d.ts.map +1 -0
- package/dist/tools/office/powerpoint-tools/media.js +211 -0
- package/dist/tools/office/powerpoint-tools/media.js.map +1 -0
- package/dist/tools/office/powerpoint-tools/notes.d.ts +8 -0
- package/dist/tools/office/powerpoint-tools/notes.d.ts.map +1 -0
- package/dist/tools/office/powerpoint-tools/notes.js +171 -0
- package/dist/tools/office/powerpoint-tools/notes.js.map +1 -0
- package/dist/tools/office/powerpoint-tools/sections.d.ts +6 -0
- package/dist/tools/office/powerpoint-tools/sections.d.ts.map +1 -0
- package/dist/tools/office/powerpoint-tools/sections.js +104 -0
- package/dist/tools/office/powerpoint-tools/sections.js.map +1 -0
- package/dist/tools/office/powerpoint-tools/shapes.d.ts +22 -0
- package/dist/tools/office/powerpoint-tools/shapes.d.ts.map +1 -0
- package/dist/tools/office/powerpoint-tools/shapes.js +681 -0
- package/dist/tools/office/powerpoint-tools/shapes.js.map +1 -0
- package/dist/tools/office/powerpoint-tools/slides.d.ts +11 -0
- package/dist/tools/office/powerpoint-tools/slides.d.ts.map +1 -0
- package/dist/tools/office/powerpoint-tools/slides.js +283 -0
- package/dist/tools/office/powerpoint-tools/slides.js.map +1 -0
- package/dist/tools/office/powerpoint-tools/tables.d.ts +6 -0
- package/dist/tools/office/powerpoint-tools/tables.d.ts.map +1 -0
- package/dist/tools/office/powerpoint-tools/tables.js +132 -0
- package/dist/tools/office/powerpoint-tools/tables.js.map +1 -0
- package/dist/tools/office/powerpoint-tools/text.d.ts +12 -0
- package/dist/tools/office/powerpoint-tools/text.d.ts.map +1 -0
- package/dist/tools/office/powerpoint-tools/text.js +366 -0
- package/dist/tools/office/powerpoint-tools/text.js.map +1 -0
- package/dist/tools/office/powerpoint-tools.d.ts +3 -0
- package/dist/tools/office/powerpoint-tools.d.ts.map +1 -0
- package/dist/tools/office/powerpoint-tools.js +3 -0
- package/dist/tools/office/powerpoint-tools.js.map +1 -0
- package/dist/tools/office/word-client.d.ts +111 -0
- package/dist/tools/office/word-client.d.ts.map +1 -0
- package/dist/tools/office/word-client.js +995 -0
- package/dist/tools/office/word-client.js.map +1 -0
- package/dist/tools/office/word-tools/bookmarks.d.ts +7 -0
- package/dist/tools/office/word-tools/bookmarks.d.ts.map +1 -0
- package/dist/tools/office/word-tools/bookmarks.js +146 -0
- package/dist/tools/office/word-tools/bookmarks.js.map +1 -0
- package/dist/tools/office/word-tools/comments.d.ts +7 -0
- package/dist/tools/office/word-tools/comments.d.ts.map +1 -0
- package/dist/tools/office/word-tools/comments.js +146 -0
- package/dist/tools/office/word-tools/comments.js.map +1 -0
- package/dist/tools/office/word-tools/content.d.ts +7 -0
- package/dist/tools/office/word-tools/content.d.ts.map +1 -0
- package/dist/tools/office/word-tools/content.js +168 -0
- package/dist/tools/office/word-tools/content.js.map +1 -0
- package/dist/tools/office/word-tools/export.d.ts +5 -0
- package/dist/tools/office/word-tools/export.d.ts.map +1 -0
- package/dist/tools/office/word-tools/export.js +73 -0
- package/dist/tools/office/word-tools/export.js.map +1 -0
- package/dist/tools/office/word-tools/formatting.d.ts +6 -0
- package/dist/tools/office/word-tools/formatting.d.ts.map +1 -0
- package/dist/tools/office/word-tools/formatting.js +129 -0
- package/dist/tools/office/word-tools/formatting.js.map +1 -0
- package/dist/tools/office/word-tools/headers-footers.d.ts +6 -0
- package/dist/tools/office/word-tools/headers-footers.d.ts.map +1 -0
- package/dist/tools/office/word-tools/headers-footers.js +117 -0
- package/dist/tools/office/word-tools/headers-footers.js.map +1 -0
- package/dist/tools/office/word-tools/index.d.ts +16 -0
- package/dist/tools/office/word-tools/index.d.ts.map +1 -0
- package/dist/tools/office/word-tools/index.js +45 -0
- package/dist/tools/office/word-tools/index.js.map +1 -0
- package/dist/tools/office/word-tools/launch.d.ts +10 -0
- package/dist/tools/office/word-tools/launch.d.ts.map +1 -0
- package/dist/tools/office/word-tools/launch.js +255 -0
- package/dist/tools/office/word-tools/launch.js.map +1 -0
- package/dist/tools/office/word-tools/lists.d.ts +5 -0
- package/dist/tools/office/word-tools/lists.d.ts.map +1 -0
- package/dist/tools/office/word-tools/lists.js +73 -0
- package/dist/tools/office/word-tools/lists.js.map +1 -0
- package/dist/tools/office/word-tools/navigation.d.ts +5 -0
- package/dist/tools/office/word-tools/navigation.d.ts.map +1 -0
- package/dist/tools/office/word-tools/navigation.js +85 -0
- package/dist/tools/office/word-tools/navigation.js.map +1 -0
- package/dist/tools/office/word-tools/page-setup.d.ts +7 -0
- package/dist/tools/office/word-tools/page-setup.d.ts.map +1 -0
- package/dist/tools/office/word-tools/page-setup.js +152 -0
- package/dist/tools/office/word-tools/page-setup.js.map +1 -0
- package/dist/tools/office/word-tools/tables.d.ts +8 -0
- package/dist/tools/office/word-tools/tables.d.ts.map +1 -0
- package/dist/tools/office/word-tools/tables.js +197 -0
- package/dist/tools/office/word-tools/tables.js.map +1 -0
- package/dist/tools/office/word-tools/text.d.ts +9 -0
- package/dist/tools/office/word-tools/text.d.ts.map +1 -0
- package/dist/tools/office/word-tools/text.js +235 -0
- package/dist/tools/office/word-tools/text.js.map +1 -0
- package/dist/tools/office/word-tools/undo-redo.d.ts +5 -0
- package/dist/tools/office/word-tools/undo-redo.d.ts.map +1 -0
- package/dist/tools/office/word-tools/undo-redo.js +73 -0
- package/dist/tools/office/word-tools/undo-redo.js.map +1 -0
- package/dist/tools/office/word-tools/watermarks.d.ts +5 -0
- package/dist/tools/office/word-tools/watermarks.d.ts.map +1 -0
- package/dist/tools/office/word-tools/watermarks.js +81 -0
- package/dist/tools/office/word-tools/watermarks.js.map +1 -0
- package/dist/tools/office/word-tools.d.ts +3 -0
- package/dist/tools/office/word-tools.d.ts.map +1 -0
- package/dist/tools/office/word-tools.js +3 -0
- package/dist/tools/office/word-tools.js.map +1 -0
- package/dist/tools/registry.d.ts +46 -0
- package/dist/tools/registry.d.ts.map +1 -0
- package/dist/tools/registry.js +258 -0
- package/dist/tools/registry.js.map +1 -0
- package/dist/tools/types.d.ts +88 -0
- package/dist/tools/types.d.ts.map +1 -0
- package/dist/tools/types.js +19 -0
- package/dist/tools/types.js.map +1 -0
- package/dist/types/index.d.ts +122 -0
- package/dist/types/index.d.ts.map +1 -0
- package/dist/types/index.js +2 -0
- package/dist/types/index.js.map +1 -0
- package/dist/ui/PlanExecuteView.d.ts +11 -0
- package/dist/ui/PlanExecuteView.d.ts.map +1 -0
- package/dist/ui/PlanExecuteView.js +27 -0
- package/dist/ui/PlanExecuteView.js.map +1 -0
- package/dist/ui/TodoPanel.d.ts +13 -0
- package/dist/ui/TodoPanel.d.ts.map +1 -0
- package/dist/ui/TodoPanel.js +135 -0
- package/dist/ui/TodoPanel.js.map +1 -0
- package/dist/ui/UpdateNotification.d.ts +13 -0
- package/dist/ui/UpdateNotification.d.ts.map +1 -0
- package/dist/ui/UpdateNotification.js +42 -0
- package/dist/ui/UpdateNotification.js.map +1 -0
- package/dist/ui/components/ActivityIndicator.d.ts +25 -0
- package/dist/ui/components/ActivityIndicator.d.ts.map +1 -0
- package/dist/ui/components/ActivityIndicator.js +115 -0
- package/dist/ui/components/ActivityIndicator.js.map +1 -0
- package/dist/ui/components/CommandBrowser.d.ts +10 -0
- package/dist/ui/components/CommandBrowser.d.ts.map +1 -0
- package/dist/ui/components/CommandBrowser.js +53 -0
- package/dist/ui/components/CommandBrowser.js.map +1 -0
- package/dist/ui/components/CustomTextInput.d.ts +13 -0
- package/dist/ui/components/CustomTextInput.d.ts.map +1 -0
- package/dist/ui/components/CustomTextInput.js +245 -0
- package/dist/ui/components/CustomTextInput.js.map +1 -0
- package/dist/ui/components/DocsSearchProgress.d.ts +13 -0
- package/dist/ui/components/DocsSearchProgress.d.ts.map +1 -0
- package/dist/ui/components/DocsSearchProgress.js +37 -0
- package/dist/ui/components/DocsSearchProgress.js.map +1 -0
- package/dist/ui/components/FileBrowser.d.ts +11 -0
- package/dist/ui/components/FileBrowser.d.ts.map +1 -0
- package/dist/ui/components/FileBrowser.js +45 -0
- package/dist/ui/components/FileBrowser.js.map +1 -0
- package/dist/ui/components/LLMSetupWizard.d.ts +8 -0
- package/dist/ui/components/LLMSetupWizard.d.ts.map +1 -0
- package/dist/ui/components/LLMSetupWizard.js +183 -0
- package/dist/ui/components/LLMSetupWizard.js.map +1 -0
- package/dist/ui/components/Logo.d.ts +19 -0
- package/dist/ui/components/Logo.d.ts.map +1 -0
- package/dist/ui/components/Logo.js +99 -0
- package/dist/ui/components/Logo.js.map +1 -0
- package/dist/ui/components/MarkdownRenderer.d.ts +9 -0
- package/dist/ui/components/MarkdownRenderer.d.ts.map +1 -0
- package/dist/ui/components/MarkdownRenderer.js +198 -0
- package/dist/ui/components/MarkdownRenderer.js.map +1 -0
- package/dist/ui/components/ModelSelector.d.ts +8 -0
- package/dist/ui/components/ModelSelector.d.ts.map +1 -0
- package/dist/ui/components/ModelSelector.js +111 -0
- package/dist/ui/components/ModelSelector.js.map +1 -0
- package/dist/ui/components/PlanExecuteApp.d.ts +23 -0
- package/dist/ui/components/PlanExecuteApp.d.ts.map +1 -0
- package/dist/ui/components/PlanExecuteApp.js +1432 -0
- package/dist/ui/components/PlanExecuteApp.js.map +1 -0
- package/dist/ui/components/ProgressBar.d.ts +10 -0
- package/dist/ui/components/ProgressBar.d.ts.map +1 -0
- package/dist/ui/components/ProgressBar.js +26 -0
- package/dist/ui/components/ProgressBar.js.map +1 -0
- package/dist/ui/components/StatusBar.d.ts +23 -0
- package/dist/ui/components/StatusBar.d.ts.map +1 -0
- package/dist/ui/components/StatusBar.js +162 -0
- package/dist/ui/components/StatusBar.js.map +1 -0
- package/dist/ui/components/ThinkingIndicator.d.ts +14 -0
- package/dist/ui/components/ThinkingIndicator.d.ts.map +1 -0
- package/dist/ui/components/ThinkingIndicator.js +63 -0
- package/dist/ui/components/ThinkingIndicator.js.map +1 -0
- package/dist/ui/components/TodoListView.d.ts +11 -0
- package/dist/ui/components/TodoListView.d.ts.map +1 -0
- package/dist/ui/components/TodoListView.js +69 -0
- package/dist/ui/components/TodoListView.js.map +1 -0
- package/dist/ui/components/ToolSelector.d.ts +7 -0
- package/dist/ui/components/ToolSelector.d.ts.map +1 -0
- package/dist/ui/components/ToolSelector.js +112 -0
- package/dist/ui/components/ToolSelector.js.map +1 -0
- package/dist/ui/components/dialogs/ApprovalDialog.d.ts +13 -0
- package/dist/ui/components/dialogs/ApprovalDialog.d.ts.map +1 -0
- package/dist/ui/components/dialogs/ApprovalDialog.js +173 -0
- package/dist/ui/components/dialogs/ApprovalDialog.js.map +1 -0
- package/dist/ui/components/dialogs/AskUserDialog.d.ts +9 -0
- package/dist/ui/components/dialogs/AskUserDialog.d.ts.map +1 -0
- package/dist/ui/components/dialogs/AskUserDialog.js +111 -0
- package/dist/ui/components/dialogs/AskUserDialog.js.map +1 -0
- package/dist/ui/components/dialogs/DocsBrowser.d.ts +8 -0
- package/dist/ui/components/dialogs/DocsBrowser.d.ts.map +1 -0
- package/dist/ui/components/dialogs/DocsBrowser.js +127 -0
- package/dist/ui/components/dialogs/DocsBrowser.js.map +1 -0
- package/dist/ui/components/dialogs/RatingDialog.d.ts +9 -0
- package/dist/ui/components/dialogs/RatingDialog.d.ts.map +1 -0
- package/dist/ui/components/dialogs/RatingDialog.js +54 -0
- package/dist/ui/components/dialogs/RatingDialog.js.map +1 -0
- package/dist/ui/components/dialogs/SettingsDialog.d.ts +10 -0
- package/dist/ui/components/dialogs/SettingsDialog.d.ts.map +1 -0
- package/dist/ui/components/dialogs/SettingsDialog.js +563 -0
- package/dist/ui/components/dialogs/SettingsDialog.js.map +1 -0
- package/dist/ui/components/dialogs/index.d.ts +4 -0
- package/dist/ui/components/dialogs/index.d.ts.map +1 -0
- package/dist/ui/components/dialogs/index.js +4 -0
- package/dist/ui/components/dialogs/index.js.map +1 -0
- package/dist/ui/components/index.d.ts +12 -0
- package/dist/ui/components/index.d.ts.map +1 -0
- package/dist/ui/components/index.js +9 -0
- package/dist/ui/components/index.js.map +1 -0
- package/dist/ui/components/panels/SessionPanel.d.ts +8 -0
- package/dist/ui/components/panels/SessionPanel.d.ts.map +1 -0
- package/dist/ui/components/panels/SessionPanel.js +81 -0
- package/dist/ui/components/panels/SessionPanel.js.map +1 -0
- package/dist/ui/components/panels/index.d.ts +3 -0
- package/dist/ui/components/panels/index.d.ts.map +1 -0
- package/dist/ui/components/panels/index.js +3 -0
- package/dist/ui/components/panels/index.js.map +1 -0
- package/dist/ui/components/views/ChatView.d.ts +12 -0
- package/dist/ui/components/views/ChatView.d.ts.map +1 -0
- package/dist/ui/components/views/ChatView.js +289 -0
- package/dist/ui/components/views/ChatView.js.map +1 -0
- package/dist/ui/components/views/index.d.ts +2 -0
- package/dist/ui/components/views/index.d.ts.map +1 -0
- package/dist/ui/components/views/index.js +2 -0
- package/dist/ui/components/views/index.js.map +1 -0
- package/dist/ui/contexts/TokenContext.d.ts +29 -0
- package/dist/ui/contexts/TokenContext.d.ts.map +1 -0
- package/dist/ui/contexts/TokenContext.js +79 -0
- package/dist/ui/contexts/TokenContext.js.map +1 -0
- package/dist/ui/hooks/atFileProcessor.d.ts +15 -0
- package/dist/ui/hooks/atFileProcessor.d.ts.map +1 -0
- package/dist/ui/hooks/atFileProcessor.js +88 -0
- package/dist/ui/hooks/atFileProcessor.js.map +1 -0
- package/dist/ui/hooks/index.d.ts +8 -0
- package/dist/ui/hooks/index.d.ts.map +1 -0
- package/dist/ui/hooks/index.js +8 -0
- package/dist/ui/hooks/index.js.map +1 -0
- package/dist/ui/hooks/slashCommandProcessor.d.ts +21 -0
- package/dist/ui/hooks/slashCommandProcessor.d.ts.map +1 -0
- package/dist/ui/hooks/slashCommandProcessor.js +100 -0
- package/dist/ui/hooks/slashCommandProcessor.js.map +1 -0
- package/dist/ui/hooks/useCommandBrowserState.d.ts +12 -0
- package/dist/ui/hooks/useCommandBrowserState.d.ts.map +1 -0
- package/dist/ui/hooks/useCommandBrowserState.js +66 -0
- package/dist/ui/hooks/useCommandBrowserState.js.map +1 -0
- package/dist/ui/hooks/useFileBrowserState.d.ts +15 -0
- package/dist/ui/hooks/useFileBrowserState.d.ts.map +1 -0
- package/dist/ui/hooks/useFileBrowserState.js +79 -0
- package/dist/ui/hooks/useFileBrowserState.js.map +1 -0
- package/dist/ui/hooks/useFileList.d.ts +20 -0
- package/dist/ui/hooks/useFileList.d.ts.map +1 -0
- package/dist/ui/hooks/useFileList.js +56 -0
- package/dist/ui/hooks/useFileList.js.map +1 -0
- package/dist/ui/hooks/useInputHistory.d.ts +9 -0
- package/dist/ui/hooks/useInputHistory.d.ts.map +1 -0
- package/dist/ui/hooks/useInputHistory.js +68 -0
- package/dist/ui/hooks/useInputHistory.js.map +1 -0
- package/dist/ui/hooks/usePlanExecution.d.ts +8 -0
- package/dist/ui/hooks/usePlanExecution.d.ts.map +1 -0
- package/dist/ui/hooks/usePlanExecution.js +208 -0
- package/dist/ui/hooks/usePlanExecution.js.map +1 -0
- package/dist/ui/index.d.ts +7 -0
- package/dist/ui/index.d.ts.map +1 -0
- package/dist/ui/index.js +7 -0
- package/dist/ui/index.js.map +1 -0
- package/dist/ui/ink-entry.d.ts +3 -0
- package/dist/ui/ink-entry.d.ts.map +1 -0
- package/dist/ui/ink-entry.js +21 -0
- package/dist/ui/ink-entry.js.map +1 -0
- package/dist/utils/file-system.d.ts +9 -0
- package/dist/utils/file-system.d.ts.map +1 -0
- package/dist/utils/file-system.js +99 -0
- package/dist/utils/file-system.js.map +1 -0
- package/dist/utils/git-utils.d.ts +2 -0
- package/dist/utils/git-utils.d.ts.map +1 -0
- package/dist/utils/git-utils.js +16 -0
- package/dist/utils/git-utils.js.map +1 -0
- package/dist/utils/json-stream-logger.d.ts +52 -0
- package/dist/utils/json-stream-logger.d.ts.map +1 -0
- package/dist/utils/json-stream-logger.js +442 -0
- package/dist/utils/json-stream-logger.js.map +1 -0
- package/dist/utils/logger.d.ts +86 -0
- package/dist/utils/logger.d.ts.map +1 -0
- package/dist/utils/logger.js +588 -0
- package/dist/utils/logger.js.map +1 -0
- package/dist/utils/platform-utils.d.ts +19 -0
- package/dist/utils/platform-utils.d.ts.map +1 -0
- package/dist/utils/platform-utils.js +134 -0
- package/dist/utils/platform-utils.js.map +1 -0
- package/dist/utils/wsl-utils.d.ts +4 -0
- package/dist/utils/wsl-utils.d.ts.map +1 -0
- package/dist/utils/wsl-utils.js +72 -0
- package/dist/utils/wsl-utils.js.map +1 -0
- package/package.json +150 -0
- package/scripts/patch-yoga.js +48 -0
|
@@ -0,0 +1,214 @@
|
|
|
1
|
+
import { powerpointClient } from '../powerpoint-client.js';
|
|
2
|
+
import { saveScreenshot } from '../common/utils.js';
|
|
3
|
+
import { OFFICE_SCREENSHOT_PATH_DESC, OFFICE_CATEGORIES } from '../common/constants.js';
|
|
4
|
+
const POWERPOINT_LAUNCH_DEFINITION = {
|
|
5
|
+
type: 'function',
|
|
6
|
+
function: {
|
|
7
|
+
name: 'powerpoint_launch',
|
|
8
|
+
description: `Launch Microsoft PowerPoint for presentation editing.
|
|
9
|
+
Use this tool to start PowerPoint before working with presentations.
|
|
10
|
+
The PowerPoint window will be visible so you can see the changes in real-time.`,
|
|
11
|
+
parameters: {
|
|
12
|
+
type: 'object',
|
|
13
|
+
properties: {
|
|
14
|
+
reason: { type: 'string', description: 'Explanation of why you are launching PowerPoint' },
|
|
15
|
+
},
|
|
16
|
+
required: ['reason'],
|
|
17
|
+
},
|
|
18
|
+
},
|
|
19
|
+
};
|
|
20
|
+
async function executePowerPointLaunch(_args) {
|
|
21
|
+
try {
|
|
22
|
+
const response = await powerpointClient.powerpointLaunch();
|
|
23
|
+
if (response.success) {
|
|
24
|
+
return { success: true, result: response.message || 'PowerPoint launched successfully' };
|
|
25
|
+
}
|
|
26
|
+
return { success: false, error: response.error || 'Failed to launch PowerPoint' };
|
|
27
|
+
}
|
|
28
|
+
catch (error) {
|
|
29
|
+
return { success: false, error: `Failed to launch PowerPoint: ${error instanceof Error ? error.message : String(error)}` };
|
|
30
|
+
}
|
|
31
|
+
}
|
|
32
|
+
export const powerpointLaunchTool = {
|
|
33
|
+
definition: POWERPOINT_LAUNCH_DEFINITION,
|
|
34
|
+
execute: executePowerPointLaunch,
|
|
35
|
+
categories: OFFICE_CATEGORIES,
|
|
36
|
+
description: 'Launch Microsoft PowerPoint',
|
|
37
|
+
};
|
|
38
|
+
const POWERPOINT_CREATE_DEFINITION = {
|
|
39
|
+
type: 'function',
|
|
40
|
+
function: {
|
|
41
|
+
name: 'powerpoint_create',
|
|
42
|
+
description: `Create a new PowerPoint presentation.`,
|
|
43
|
+
parameters: {
|
|
44
|
+
type: 'object',
|
|
45
|
+
properties: {
|
|
46
|
+
reason: { type: 'string', description: 'Why you are creating a presentation' },
|
|
47
|
+
},
|
|
48
|
+
required: ['reason'],
|
|
49
|
+
},
|
|
50
|
+
},
|
|
51
|
+
};
|
|
52
|
+
async function executePowerPointCreate(_args) {
|
|
53
|
+
try {
|
|
54
|
+
const response = await powerpointClient.powerpointCreate();
|
|
55
|
+
if (response.success) {
|
|
56
|
+
return { success: true, result: response.message || 'New presentation created' };
|
|
57
|
+
}
|
|
58
|
+
return { success: false, error: response.error || 'Failed to create presentation' };
|
|
59
|
+
}
|
|
60
|
+
catch (error) {
|
|
61
|
+
return { success: false, error: `Failed to create presentation: ${error instanceof Error ? error.message : String(error)}` };
|
|
62
|
+
}
|
|
63
|
+
}
|
|
64
|
+
export const powerpointCreateTool = {
|
|
65
|
+
definition: POWERPOINT_CREATE_DEFINITION,
|
|
66
|
+
execute: executePowerPointCreate,
|
|
67
|
+
categories: OFFICE_CATEGORIES,
|
|
68
|
+
description: 'Create new PowerPoint presentation',
|
|
69
|
+
};
|
|
70
|
+
const POWERPOINT_OPEN_DEFINITION = {
|
|
71
|
+
type: 'function',
|
|
72
|
+
function: {
|
|
73
|
+
name: 'powerpoint_open',
|
|
74
|
+
description: `Open an existing PowerPoint presentation. WSL paths are automatically converted to Windows paths.`,
|
|
75
|
+
parameters: {
|
|
76
|
+
type: 'object',
|
|
77
|
+
properties: {
|
|
78
|
+
reason: { type: 'string', description: 'Why you are opening this presentation' },
|
|
79
|
+
path: { type: 'string', description: 'File path to open. Can use Linux/WSL paths or Windows paths.' },
|
|
80
|
+
},
|
|
81
|
+
required: ['reason', 'path'],
|
|
82
|
+
},
|
|
83
|
+
},
|
|
84
|
+
};
|
|
85
|
+
async function executePowerPointOpen(args) {
|
|
86
|
+
try {
|
|
87
|
+
const response = await powerpointClient.powerpointOpen(args['path']);
|
|
88
|
+
if (response.success) {
|
|
89
|
+
return { success: true, result: `Presentation opened: ${response['presentation_name'] || args['path']}` };
|
|
90
|
+
}
|
|
91
|
+
return { success: false, error: response.error || 'Failed to open presentation' };
|
|
92
|
+
}
|
|
93
|
+
catch (error) {
|
|
94
|
+
return { success: false, error: `Failed to open presentation: ${error instanceof Error ? error.message : String(error)}` };
|
|
95
|
+
}
|
|
96
|
+
}
|
|
97
|
+
export const powerpointOpenTool = {
|
|
98
|
+
definition: POWERPOINT_OPEN_DEFINITION,
|
|
99
|
+
execute: executePowerPointOpen,
|
|
100
|
+
categories: OFFICE_CATEGORIES,
|
|
101
|
+
description: 'Open existing PowerPoint presentation',
|
|
102
|
+
};
|
|
103
|
+
const POWERPOINT_SCREENSHOT_DEFINITION = {
|
|
104
|
+
type: 'function',
|
|
105
|
+
function: {
|
|
106
|
+
name: 'powerpoint_screenshot',
|
|
107
|
+
description: `Take a screenshot of the current slide.
|
|
108
|
+
Saves to ${OFFICE_SCREENSHOT_PATH_DESC}.`,
|
|
109
|
+
parameters: {
|
|
110
|
+
type: 'object',
|
|
111
|
+
properties: {
|
|
112
|
+
reason: { type: 'string', description: 'Why you are taking a screenshot' },
|
|
113
|
+
},
|
|
114
|
+
required: ['reason'],
|
|
115
|
+
},
|
|
116
|
+
},
|
|
117
|
+
};
|
|
118
|
+
async function executePowerPointScreenshot(_args) {
|
|
119
|
+
try {
|
|
120
|
+
const response = await powerpointClient.powerpointScreenshot();
|
|
121
|
+
if (response.success && response.image) {
|
|
122
|
+
const filePath = await saveScreenshot(response.image, 'powerpoint');
|
|
123
|
+
return {
|
|
124
|
+
success: true,
|
|
125
|
+
result: `PowerPoint screenshot saved to: ${filePath}`,
|
|
126
|
+
};
|
|
127
|
+
}
|
|
128
|
+
return { success: false, error: response.error || 'Failed to capture screenshot' };
|
|
129
|
+
}
|
|
130
|
+
catch (error) {
|
|
131
|
+
return { success: false, error: `Failed to capture screenshot: ${error instanceof Error ? error.message : String(error)}` };
|
|
132
|
+
}
|
|
133
|
+
}
|
|
134
|
+
export const powerpointScreenshotTool = {
|
|
135
|
+
definition: POWERPOINT_SCREENSHOT_DEFINITION,
|
|
136
|
+
execute: executePowerPointScreenshot,
|
|
137
|
+
categories: OFFICE_CATEGORIES,
|
|
138
|
+
description: 'Take PowerPoint slide screenshot',
|
|
139
|
+
};
|
|
140
|
+
const POWERPOINT_CLOSE_DEFINITION = {
|
|
141
|
+
type: 'function',
|
|
142
|
+
function: {
|
|
143
|
+
name: 'powerpoint_close',
|
|
144
|
+
description: `Close the active presentation.`,
|
|
145
|
+
parameters: {
|
|
146
|
+
type: 'object',
|
|
147
|
+
properties: {
|
|
148
|
+
reason: { type: 'string', description: 'Why you are closing' },
|
|
149
|
+
save: { type: 'boolean', description: 'Whether to save before closing (default: false)' },
|
|
150
|
+
},
|
|
151
|
+
required: ['reason'],
|
|
152
|
+
},
|
|
153
|
+
},
|
|
154
|
+
};
|
|
155
|
+
async function executePowerPointClose(args) {
|
|
156
|
+
try {
|
|
157
|
+
const response = await powerpointClient.powerpointClose(args['save'] === true);
|
|
158
|
+
if (response.success) {
|
|
159
|
+
return { success: true, result: `Presentation closed${args['save'] ? ' (saved)' : ''}` };
|
|
160
|
+
}
|
|
161
|
+
return { success: false, error: response.error || 'Failed to close presentation' };
|
|
162
|
+
}
|
|
163
|
+
catch (error) {
|
|
164
|
+
return { success: false, error: `Failed to close presentation: ${error instanceof Error ? error.message : String(error)}` };
|
|
165
|
+
}
|
|
166
|
+
}
|
|
167
|
+
export const powerpointCloseTool = {
|
|
168
|
+
definition: POWERPOINT_CLOSE_DEFINITION,
|
|
169
|
+
execute: executePowerPointClose,
|
|
170
|
+
categories: OFFICE_CATEGORIES,
|
|
171
|
+
description: 'Close PowerPoint presentation',
|
|
172
|
+
};
|
|
173
|
+
const POWERPOINT_QUIT_DEFINITION = {
|
|
174
|
+
type: 'function',
|
|
175
|
+
function: {
|
|
176
|
+
name: 'powerpoint_quit',
|
|
177
|
+
description: `Quit Microsoft PowerPoint application entirely.`,
|
|
178
|
+
parameters: {
|
|
179
|
+
type: 'object',
|
|
180
|
+
properties: {
|
|
181
|
+
reason: { type: 'string', description: 'Why you are quitting PowerPoint' },
|
|
182
|
+
save: { type: 'boolean', description: 'Whether to save all presentations before quitting (default: false)' },
|
|
183
|
+
},
|
|
184
|
+
required: ['reason'],
|
|
185
|
+
},
|
|
186
|
+
},
|
|
187
|
+
};
|
|
188
|
+
async function executePowerPointQuit(args) {
|
|
189
|
+
try {
|
|
190
|
+
const response = await powerpointClient.powerpointQuit(args['save'] === true);
|
|
191
|
+
if (response.success) {
|
|
192
|
+
return { success: true, result: `PowerPoint closed${args['save'] ? ' (all presentations saved)' : ''}` };
|
|
193
|
+
}
|
|
194
|
+
return { success: false, error: response.error || 'Failed to quit PowerPoint' };
|
|
195
|
+
}
|
|
196
|
+
catch (error) {
|
|
197
|
+
return { success: false, error: `Failed to quit PowerPoint: ${error instanceof Error ? error.message : String(error)}` };
|
|
198
|
+
}
|
|
199
|
+
}
|
|
200
|
+
export const powerpointQuitTool = {
|
|
201
|
+
definition: POWERPOINT_QUIT_DEFINITION,
|
|
202
|
+
execute: executePowerPointQuit,
|
|
203
|
+
categories: OFFICE_CATEGORIES,
|
|
204
|
+
description: 'Quit Microsoft PowerPoint',
|
|
205
|
+
};
|
|
206
|
+
export const launchTools = [
|
|
207
|
+
powerpointLaunchTool,
|
|
208
|
+
powerpointCreateTool,
|
|
209
|
+
powerpointOpenTool,
|
|
210
|
+
powerpointScreenshotTool,
|
|
211
|
+
powerpointCloseTool,
|
|
212
|
+
powerpointQuitTool,
|
|
213
|
+
];
|
|
214
|
+
//# sourceMappingURL=launch.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"launch.js","sourceRoot":"","sources":["../../../../src/tools/office/powerpoint-tools/launch.ts"],"names":[],"mappings":"AASA,OAAO,EAAE,gBAAgB,EAAE,MAAM,yBAAyB,CAAC;AAC3D,OAAO,EAAE,cAAc,EAAE,MAAM,oBAAoB,CAAC;AACpD,OAAO,EAAE,2BAA2B,EAAE,iBAAiB,EAAE,MAAM,wBAAwB,CAAC;AAMxF,MAAM,4BAA4B,GAAmB;IACnD,IAAI,EAAE,UAAU;IAChB,QAAQ,EAAE;QACR,IAAI,EAAE,mBAAmB;QACzB,WAAW,EAAE;;+EAE8D;QAC3E,UAAU,EAAE;YACV,IAAI,EAAE,QAAQ;YACd,UAAU,EAAE;gBACV,MAAM,EAAE,EAAE,IAAI,EAAE,QAAQ,EAAE,WAAW,EAAE,iDAAiD,EAAE;aAC3F;YACD,QAAQ,EAAE,CAAC,QAAQ,CAAC;SACrB;KACF;CACF,CAAC;AAEF,KAAK,UAAU,uBAAuB,CAAC,KAA8B;IACnE,IAAI,CAAC;QACH,MAAM,QAAQ,GAAG,MAAM,gBAAgB,CAAC,gBAAgB,EAAE,CAAC;QAC3D,IAAI,QAAQ,CAAC,OAAO,E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M,CAAC,CAAC,CAAC,CAAC,4BAA4B,CAAC,CAAC,CAAC,EAAE,EAAE,EAAE,CAAC;QAC3G,CAAC;QACD,OAAO,EAAE,OAAO,EAAE,KAAK,EAAE,KAAK,EAAE,QAAQ,CAAC,KAAK,IAAI,2BAA2B,EAAE,CAAC;IAClF,CAAC;IAAC,OAAO,KAAK,EAAE,CAAC;QACf,OAAO,EAAE,OAAO,EAAE,KAAK,EAAE,KAAK,EAAE,8BAA8B,KAAK,YAAY,KAAK,CAAC,CAAC,CAAC,KAAK,CAAC,OAAO,CAAC,CAAC,CAAC,MAAM,CAAC,KAAK,CAAC,EAAE,EAAE,CAAC;IAC3H,CAAC;AACH,CAAC;AAED,MAAM,CAAC,MAAM,kBAAkB,GAAkB;IAC/C,UAAU,EAAE,0BAA0B;IACtC,OAAO,EAAE,qBAAqB;IAC9B,UAAU,EAAE,iBAAiB;IAC7B,WAAW,EAAE,2BAA2B;CACzC,CAAC;AAMF,MAAM,CAAC,MAAM,WAAW,GAAoB;IAC1C,oBAAoB;IACpB,oBAAoB;IACpB,kBAAkB;IAClB,wBAAwB;IACxB,mBAAmB;IACnB,kBAAkB;CACnB,CAAC"}
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { LLMSimpleTool } from '../../types.js';
|
|
2
|
+
export declare const powerpointAddImageTool: LLMSimpleTool;
|
|
3
|
+
export declare const powerpointAddVideoTool: LLMSimpleTool;
|
|
4
|
+
export declare const powerpointAddAudioTool: LLMSimpleTool;
|
|
5
|
+
export declare const powerpointAddHyperlinkTool: LLMSimpleTool;
|
|
6
|
+
export declare const powerpointAddChartTool: LLMSimpleTool;
|
|
7
|
+
export declare const mediaTools: LLMSimpleTool[];
|
|
8
|
+
//# sourceMappingURL=media.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"media.d.ts","sourceRoot":"","sources":["../../../../src/tools/office/powerpoint-tools/media.ts"],"names":[],"mappings":"AAYA,OAAO,EAAE,aAAa,EAAc,MAAM,gBAAgB,CAAC;AAgD3D,eAAO,MAAM,sBAAsB,EAAE,aAKpC,CAAC;AA6CF,eAAO,MAAM,sBAAsB,EAAE,aAKpC,CAAC;AA2CF,eAAO,MAAM,sBAAsB,EAAE,aAKpC,CAAC;AAyCF,eAAO,MAAM,0BAA0B,EAAE,aAKxC,CAAC;AAgEF,eAAO,MAAM,sBAAsB,EAAE,aAKpC,CAAC;AAMF,eAAO,MAAM,UAAU,EAAE,aAAa,EAMrC,CAAC"}
|
|
@@ -0,0 +1,211 @@
|
|
|
1
|
+
import { powerpointClient } from '../powerpoint-client.js';
|
|
2
|
+
import { OFFICE_CATEGORIES } from '../common/constants.js';
|
|
3
|
+
const POWERPOINT_ADD_IMAGE_DEFINITION = {
|
|
4
|
+
type: 'function',
|
|
5
|
+
function: {
|
|
6
|
+
name: 'powerpoint_add_image',
|
|
7
|
+
description: `Add an image to a slide. WSL paths are automatically converted to Windows paths.`,
|
|
8
|
+
parameters: {
|
|
9
|
+
type: 'object',
|
|
10
|
+
properties: {
|
|
11
|
+
reason: { type: 'string', description: 'Why you are adding an image' },
|
|
12
|
+
slide: { type: 'number', description: 'Slide number' },
|
|
13
|
+
path: { type: 'string', description: 'Image file path' },
|
|
14
|
+
left: { type: 'number', description: 'Left position in points (default: 100)' },
|
|
15
|
+
top: { type: 'number', description: 'Top position in points (default: 100)' },
|
|
16
|
+
width: { type: 'number', description: 'Width in points (optional)' },
|
|
17
|
+
height: { type: 'number', description: 'Height in points (optional)' },
|
|
18
|
+
},
|
|
19
|
+
required: ['reason', 'slide', 'path'],
|
|
20
|
+
},
|
|
21
|
+
},
|
|
22
|
+
};
|
|
23
|
+
async function executePowerPointAddImage(args) {
|
|
24
|
+
try {
|
|
25
|
+
const response = await powerpointClient.powerpointAddImage(args['slide'], args['path'], args['left'] ?? 100, args['top'] ?? 100, args['width'], args['height']);
|
|
26
|
+
if (response.success) {
|
|
27
|
+
return { success: true, result: `Image added to slide ${args['slide']}` };
|
|
28
|
+
}
|
|
29
|
+
return { success: false, error: response.error || 'Failed to add image' };
|
|
30
|
+
}
|
|
31
|
+
catch (error) {
|
|
32
|
+
return { success: false, error: `Failed to add image: ${error instanceof Error ? error.message : String(error)}` };
|
|
33
|
+
}
|
|
34
|
+
}
|
|
35
|
+
export const powerpointAddImageTool = {
|
|
36
|
+
definition: POWERPOINT_ADD_IMAGE_DEFINITION,
|
|
37
|
+
execute: executePowerPointAddImage,
|
|
38
|
+
categories: OFFICE_CATEGORIES,
|
|
39
|
+
description: 'Add PowerPoint image',
|
|
40
|
+
};
|
|
41
|
+
const POWERPOINT_ADD_VIDEO_DEFINITION = {
|
|
42
|
+
type: 'function',
|
|
43
|
+
function: {
|
|
44
|
+
name: 'powerpoint_add_video',
|
|
45
|
+
description: `Add a video to a slide.`,
|
|
46
|
+
parameters: {
|
|
47
|
+
type: 'object',
|
|
48
|
+
properties: {
|
|
49
|
+
slide_number: { type: 'number', description: 'Slide number' },
|
|
50
|
+
video_path: { type: 'string', description: 'Path to video file' },
|
|
51
|
+
left: { type: 'number', description: 'Left position (default: 100)' },
|
|
52
|
+
top: { type: 'number', description: 'Top position (default: 100)' },
|
|
53
|
+
width: { type: 'number', description: 'Width (default: 400)' },
|
|
54
|
+
height: { type: 'number', description: 'Height (default: 300)' },
|
|
55
|
+
},
|
|
56
|
+
required: ['slide_number', 'video_path'],
|
|
57
|
+
},
|
|
58
|
+
},
|
|
59
|
+
};
|
|
60
|
+
async function executePowerPointAddVideo(args) {
|
|
61
|
+
try {
|
|
62
|
+
const response = await powerpointClient.powerpointAddVideo(args['slide_number'], args['video_path'], args['left'], args['top'], args['width'], args['height']);
|
|
63
|
+
if (response.success) {
|
|
64
|
+
return { success: true, result: `Video added. Shape index: ${response['shape_index']}` };
|
|
65
|
+
}
|
|
66
|
+
return { success: false, error: response.error || 'Failed to add video' };
|
|
67
|
+
}
|
|
68
|
+
catch (error) {
|
|
69
|
+
return { success: false, error: `Failed to add video: ${error instanceof Error ? error.message : String(error)}` };
|
|
70
|
+
}
|
|
71
|
+
}
|
|
72
|
+
export const powerpointAddVideoTool = {
|
|
73
|
+
definition: POWERPOINT_ADD_VIDEO_DEFINITION,
|
|
74
|
+
execute: executePowerPointAddVideo,
|
|
75
|
+
categories: OFFICE_CATEGORIES,
|
|
76
|
+
description: 'Add video to slide',
|
|
77
|
+
};
|
|
78
|
+
const POWERPOINT_ADD_AUDIO_DEFINITION = {
|
|
79
|
+
type: 'function',
|
|
80
|
+
function: {
|
|
81
|
+
name: 'powerpoint_add_audio',
|
|
82
|
+
description: `Add an audio file to a slide.`,
|
|
83
|
+
parameters: {
|
|
84
|
+
type: 'object',
|
|
85
|
+
properties: {
|
|
86
|
+
slide_number: { type: 'number', description: 'Slide number' },
|
|
87
|
+
audio_path: { type: 'string', description: 'Path to audio file' },
|
|
88
|
+
left: { type: 'number', description: 'Left position (default: 100)' },
|
|
89
|
+
top: { type: 'number', description: 'Top position (default: 100)' },
|
|
90
|
+
play_in_background: { type: 'boolean', description: 'Play audio in background (default: false)' },
|
|
91
|
+
},
|
|
92
|
+
required: ['slide_number', 'audio_path'],
|
|
93
|
+
},
|
|
94
|
+
},
|
|
95
|
+
};
|
|
96
|
+
async function executePowerPointAddAudio(args) {
|
|
97
|
+
try {
|
|
98
|
+
const response = await powerpointClient.powerpointAddAudio(args['slide_number'], args['audio_path'], args['left'], args['top'], args['play_in_background']);
|
|
99
|
+
if (response.success) {
|
|
100
|
+
return { success: true, result: `Audio added. Shape index: ${response['shape_index']}` };
|
|
101
|
+
}
|
|
102
|
+
return { success: false, error: response.error || 'Failed to add audio' };
|
|
103
|
+
}
|
|
104
|
+
catch (error) {
|
|
105
|
+
return { success: false, error: `Failed to add audio: ${error instanceof Error ? error.message : String(error)}` };
|
|
106
|
+
}
|
|
107
|
+
}
|
|
108
|
+
export const powerpointAddAudioTool = {
|
|
109
|
+
definition: POWERPOINT_ADD_AUDIO_DEFINITION,
|
|
110
|
+
execute: executePowerPointAddAudio,
|
|
111
|
+
categories: OFFICE_CATEGORIES,
|
|
112
|
+
description: 'Add audio to slide',
|
|
113
|
+
};
|
|
114
|
+
const POWERPOINT_ADD_HYPERLINK_DEFINITION = {
|
|
115
|
+
type: 'function',
|
|
116
|
+
function: {
|
|
117
|
+
name: 'powerpoint_add_hyperlink',
|
|
118
|
+
description: `Add a hyperlink to a shape.`,
|
|
119
|
+
parameters: {
|
|
120
|
+
type: 'object',
|
|
121
|
+
properties: {
|
|
122
|
+
slide_number: { type: 'number', description: 'Slide number' },
|
|
123
|
+
shape_index: { type: 'number', description: 'Shape index' },
|
|
124
|
+
url: { type: 'string', description: 'Hyperlink URL' },
|
|
125
|
+
screen_tip: { type: 'string', description: 'Tooltip text when hovering' },
|
|
126
|
+
},
|
|
127
|
+
required: ['slide_number', 'shape_index', 'url'],
|
|
128
|
+
},
|
|
129
|
+
},
|
|
130
|
+
};
|
|
131
|
+
async function executePowerPointAddHyperlink(args) {
|
|
132
|
+
try {
|
|
133
|
+
const response = await powerpointClient.powerpointAddHyperlink(args['slide_number'], args['shape_index'], args['url'], args['screen_tip']);
|
|
134
|
+
if (response.success) {
|
|
135
|
+
return { success: true, result: response.message || 'Hyperlink added' };
|
|
136
|
+
}
|
|
137
|
+
return { success: false, error: response.error || 'Failed to add hyperlink' };
|
|
138
|
+
}
|
|
139
|
+
catch (error) {
|
|
140
|
+
return { success: false, error: `Failed to add hyperlink: ${error instanceof Error ? error.message : String(error)}` };
|
|
141
|
+
}
|
|
142
|
+
}
|
|
143
|
+
export const powerpointAddHyperlinkTool = {
|
|
144
|
+
definition: POWERPOINT_ADD_HYPERLINK_DEFINITION,
|
|
145
|
+
execute: executePowerPointAddHyperlink,
|
|
146
|
+
categories: OFFICE_CATEGORIES,
|
|
147
|
+
description: 'Add hyperlink to shape',
|
|
148
|
+
};
|
|
149
|
+
const POWERPOINT_ADD_CHART_DEFINITION = {
|
|
150
|
+
type: 'function',
|
|
151
|
+
function: {
|
|
152
|
+
name: 'powerpoint_add_chart',
|
|
153
|
+
description: `Add a chart to a slide.`,
|
|
154
|
+
parameters: {
|
|
155
|
+
type: 'object',
|
|
156
|
+
properties: {
|
|
157
|
+
slide_number: { type: 'number', description: 'Slide number' },
|
|
158
|
+
chart_type: { type: 'string', enum: ['column', 'bar', 'line', 'pie', 'area', 'scatter'], description: 'Chart type' },
|
|
159
|
+
left: { type: 'number', description: 'Left position (default: 100)' },
|
|
160
|
+
top: { type: 'number', description: 'Top position (default: 100)' },
|
|
161
|
+
width: { type: 'number', description: 'Width (default: 400)' },
|
|
162
|
+
height: { type: 'number', description: 'Height (default: 300)' },
|
|
163
|
+
data: {
|
|
164
|
+
type: 'object',
|
|
165
|
+
description: 'Chart data',
|
|
166
|
+
properties: {
|
|
167
|
+
categories: { type: 'array', items: { type: 'string' }, description: 'Category labels' },
|
|
168
|
+
series: {
|
|
169
|
+
type: 'array',
|
|
170
|
+
items: {
|
|
171
|
+
type: 'object',
|
|
172
|
+
properties: {
|
|
173
|
+
name: { type: 'string' },
|
|
174
|
+
values: { type: 'array', items: { type: 'number' } },
|
|
175
|
+
},
|
|
176
|
+
},
|
|
177
|
+
description: 'Data series',
|
|
178
|
+
},
|
|
179
|
+
},
|
|
180
|
+
},
|
|
181
|
+
},
|
|
182
|
+
required: ['slide_number', 'chart_type'],
|
|
183
|
+
},
|
|
184
|
+
},
|
|
185
|
+
};
|
|
186
|
+
async function executePowerPointAddChart(args) {
|
|
187
|
+
try {
|
|
188
|
+
const response = await powerpointClient.powerpointAddChart(args['slide_number'], args['chart_type'], args['left'], args['top'], args['width'], args['height'], args['data']);
|
|
189
|
+
if (response.success) {
|
|
190
|
+
return { success: true, result: `Chart added. Shape index: ${response['shape_index']}` };
|
|
191
|
+
}
|
|
192
|
+
return { success: false, error: response.error || 'Failed to add chart' };
|
|
193
|
+
}
|
|
194
|
+
catch (error) {
|
|
195
|
+
return { success: false, error: `Failed to add chart: ${error instanceof Error ? error.message : String(error)}` };
|
|
196
|
+
}
|
|
197
|
+
}
|
|
198
|
+
export const powerpointAddChartTool = {
|
|
199
|
+
definition: POWERPOINT_ADD_CHART_DEFINITION,
|
|
200
|
+
execute: executePowerPointAddChart,
|
|
201
|
+
categories: OFFICE_CATEGORIES,
|
|
202
|
+
description: 'Add chart to slide',
|
|
203
|
+
};
|
|
204
|
+
export const mediaTools = [
|
|
205
|
+
powerpointAddImageTool,
|
|
206
|
+
powerpointAddVideoTool,
|
|
207
|
+
powerpointAddAudioTool,
|
|
208
|
+
powerpointAddHyperlinkTool,
|
|
209
|
+
powerpointAddChartTool,
|
|
210
|
+
];
|
|
211
|
+
//# sourceMappingURL=media.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"media.js","sourceRoot":"","sources":["../../../../src/tools/office/powerpoint-tools/media.ts"],"names":[],"mappings":"AAaA,OAAO,EAAE,gBAAgB,EAAE,MAAM,yBAAyB,CAAC;AAC3D,OAAO,EAAE,iBAAiB,EAAE,MAAM,wBAAwB,CAAC;AAM3D,MAAM,+BAA+B,GAAmB;IACtD,IAAI,EAAE,UAAU;IAChB,QAAQ,EAAE;QACR,IAAI,EAAE,sBAAsB;QAC5B,WAAW,EAAE,kFAAkF;QAC/F,UAAU,EAAE;YACV,IAAI,EAAE,QAAQ;YACd,UAAU,EAAE;gBACV,MAAM,EAAE,EAAE,IAAI,EAAE,QAAQ,EAAE,WAAW,EAAE,6BAA6B,EAAE;gBACtE,KAAK,EAAE,EAAE,IAAI,EAAE,QAAQ,EAAE,WAAW,EAAE,cAAc,EAAE;gBACtD,IAAI,EAAE,EAAE,IAAI,EAAE,QAAQ,EAAE,WAAW,EAAE,iBAAiB,EAAE;gBACxD,IAAI,EAAE,EAAE,IAAI,EAAE,QAAQ,EAAE,WAAW,EAAE,wCAAwC,EAAE;gBAC/E,GAAG,EAAE,EAAE,IAAI,EAAE,QAAQ,EAAE,WAAW,EAAE,uCAAuC,EAAE;gBAC7E,KAAK,EAAE,EAAE,IAAI,EAAE,QAAQ,EA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xD,IAAI,CAAC,cAAc,CAAW,EAC9B,IAAI,CAAC,YAAY,CAA2D,EAC5E,IAAI,CAAC,MAAM,CAAuB,EAClC,IAAI,CAAC,KAAK,CAAuB,EACjC,IAAI,CAAC,OAAO,CAAuB,EACnC,IAAI,CAAC,QAAQ,CAAuB,EACpC,IAAI,CAAC,MAAM,CAAuF,CACnG,CAAC;QACF,IAAI,QAAQ,CAAC,OAAO,EAAE,CAAC;YACrB,OAAO,EAAE,OAAO,EAAE,IAAI,EAAE,MAAM,EAAE,6BAA6B,QAAQ,CAAC,aAAa,CAAC,EAAE,EAAE,CAAC;QAC3F,CAAC;QACD,OAAO,EAAE,OAAO,EAAE,KAAK,EAAE,KAAK,EAAE,QAAQ,CAAC,KAAK,IAAI,qBAAqB,EAAE,CAAC;IAC5E,CAAC;IAAC,OAAO,KAAK,EAAE,CAAC;QACf,OAAO,EAAE,OAAO,EAAE,KAAK,EAAE,KAAK,EAAE,wBAAwB,KAAK,YAAY,KAAK,CAAC,CAAC,CAAC,KAAK,CAAC,OAAO,CAAC,CAAC,CAAC,MAAM,CAAC,KAAK,CAAC,EAAE,EAAE,CAAC;IACrH,CAAC;AACH,CAAC;AAED,MAAM,CAAC,MAAM,sBAAsB,GAAkB;IACnD,UAAU,EAAE,+BAA+B;IAC3C,OAAO,EAAE,yBAAyB;IAClC,UAAU,EAAE,iBAAiB;IAC7B,WAAW,EAAE,oBAAoB;CAClC,CAAC;AAMF,MAAM,CAAC,MAAM,UAAU,GAAoB;IACzC,sBAAsB;IACtB,sBAAsB;IACtB,sBAAsB;IACtB,0BAA0B;IAC1B,sBAAsB;CACvB,CAAC"}
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { LLMSimpleTool } from '../../types.js';
|
|
2
|
+
export declare const powerpointAddNoteTool: LLMSimpleTool;
|
|
3
|
+
export declare const powerpointGetNoteTool: LLMSimpleTool;
|
|
4
|
+
export declare const powerpointSetPlaceholderTextTool: LLMSimpleTool;
|
|
5
|
+
export declare const powerpointGetPlaceholdersTool: LLMSimpleTool;
|
|
6
|
+
export declare const powerpointGetSlideLayoutsTool: LLMSimpleTool;
|
|
7
|
+
export declare const notesTools: LLMSimpleTool[];
|
|
8
|
+
//# sourceMappingURL=notes.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"notes.d.ts","sourceRoot":"","sources":["../../../../src/tools/office/powerpoint-tools/notes.ts"],"names":[],"mappings":"AAOA,OAAO,EAAE,aAAa,EAAc,MAAM,gBAAgB,CAAC;AAuC3D,eAAO,MAAM,qBAAqB,EAAE,aAKnC,CAAC;AAiCF,eAAO,MAAM,qBAAqB,EAAE,aAKnC,CAAC;AAuCF,eAAO,MAAM,gCAAgC,EAAE,aAK9C,CAAC;AAiCF,eAAO,MAAM,6BAA6B,EAAE,aAK3C,CAAC;AA+BF,eAAO,MAAM,6BAA6B,EAAE,aAK3C,CAAC;AAMF,eAAO,MAAM,UAAU,EAAE,aAAa,EAMrC,CAAC"}
|
|
@@ -0,0 +1,171 @@
|
|
|
1
|
+
import { powerpointClient } from '../powerpoint-client.js';
|
|
2
|
+
import { OFFICE_CATEGORIES } from '../common/constants.js';
|
|
3
|
+
const POWERPOINT_ADD_NOTE_DEFINITION = {
|
|
4
|
+
type: 'function',
|
|
5
|
+
function: {
|
|
6
|
+
name: 'powerpoint_add_note',
|
|
7
|
+
description: `Add speaker notes to a slide.`,
|
|
8
|
+
parameters: {
|
|
9
|
+
type: 'object',
|
|
10
|
+
properties: {
|
|
11
|
+
slide_number: { type: 'number', description: 'Slide number' },
|
|
12
|
+
note_text: { type: 'string', description: 'Note text' },
|
|
13
|
+
},
|
|
14
|
+
required: ['slide_number', 'note_text'],
|
|
15
|
+
},
|
|
16
|
+
},
|
|
17
|
+
};
|
|
18
|
+
async function executePowerPointAddNote(args) {
|
|
19
|
+
try {
|
|
20
|
+
const response = await powerpointClient.powerpointAddNote(args['slide_number'], args['note_text']);
|
|
21
|
+
if (response.success) {
|
|
22
|
+
return { success: true, result: response.message || 'Note added' };
|
|
23
|
+
}
|
|
24
|
+
return { success: false, error: response.error || 'Failed to add note' };
|
|
25
|
+
}
|
|
26
|
+
catch (error) {
|
|
27
|
+
return { success: false, error: `Failed to add note: ${error instanceof Error ? error.message : String(error)}` };
|
|
28
|
+
}
|
|
29
|
+
}
|
|
30
|
+
export const powerpointAddNoteTool = {
|
|
31
|
+
definition: POWERPOINT_ADD_NOTE_DEFINITION,
|
|
32
|
+
execute: executePowerPointAddNote,
|
|
33
|
+
categories: OFFICE_CATEGORIES,
|
|
34
|
+
description: 'Add speaker notes',
|
|
35
|
+
};
|
|
36
|
+
const POWERPOINT_GET_NOTE_DEFINITION = {
|
|
37
|
+
type: 'function',
|
|
38
|
+
function: {
|
|
39
|
+
name: 'powerpoint_get_note',
|
|
40
|
+
description: `Get speaker notes from a slide.`,
|
|
41
|
+
parameters: {
|
|
42
|
+
type: 'object',
|
|
43
|
+
properties: {
|
|
44
|
+
slide_number: { type: 'number', description: 'Slide number' },
|
|
45
|
+
},
|
|
46
|
+
required: ['slide_number'],
|
|
47
|
+
},
|
|
48
|
+
},
|
|
49
|
+
};
|
|
50
|
+
async function executePowerPointGetNote(args) {
|
|
51
|
+
try {
|
|
52
|
+
const response = await powerpointClient.powerpointGetNote(args['slide_number']);
|
|
53
|
+
if (response.success) {
|
|
54
|
+
return { success: true, result: `Note: ${response['note']}` };
|
|
55
|
+
}
|
|
56
|
+
return { success: false, error: response.error || 'Failed to get note' };
|
|
57
|
+
}
|
|
58
|
+
catch (error) {
|
|
59
|
+
return { success: false, error: `Failed to get note: ${error instanceof Error ? error.message : String(error)}` };
|
|
60
|
+
}
|
|
61
|
+
}
|
|
62
|
+
export const powerpointGetNoteTool = {
|
|
63
|
+
definition: POWERPOINT_GET_NOTE_DEFINITION,
|
|
64
|
+
execute: executePowerPointGetNote,
|
|
65
|
+
categories: OFFICE_CATEGORIES,
|
|
66
|
+
description: 'Get speaker notes',
|
|
67
|
+
};
|
|
68
|
+
const POWERPOINT_SET_PLACEHOLDER_TEXT_DEFINITION = {
|
|
69
|
+
type: 'function',
|
|
70
|
+
function: {
|
|
71
|
+
name: 'powerpoint_set_placeholder_text',
|
|
72
|
+
description: `Set text in a slide placeholder (title, subtitle, body, etc.).`,
|
|
73
|
+
parameters: {
|
|
74
|
+
type: 'object',
|
|
75
|
+
properties: {
|
|
76
|
+
slide_number: { type: 'number', description: 'Slide number' },
|
|
77
|
+
placeholder_type: { type: 'string', enum: ['title', 'subtitle', 'body', 'footer', 'slideNumber', 'date'], description: 'Placeholder type' },
|
|
78
|
+
text: { type: 'string', description: 'Text to set' },
|
|
79
|
+
},
|
|
80
|
+
required: ['slide_number', 'placeholder_type', 'text'],
|
|
81
|
+
},
|
|
82
|
+
},
|
|
83
|
+
};
|
|
84
|
+
async function executePowerPointSetPlaceholderText(args) {
|
|
85
|
+
try {
|
|
86
|
+
const response = await powerpointClient.powerpointSetPlaceholderText(args['slide_number'], args['placeholder_type'], args['text']);
|
|
87
|
+
if (response.success) {
|
|
88
|
+
return { success: true, result: response.message || 'Placeholder text set' };
|
|
89
|
+
}
|
|
90
|
+
return { success: false, error: response.error || 'Failed to set placeholder text' };
|
|
91
|
+
}
|
|
92
|
+
catch (error) {
|
|
93
|
+
return { success: false, error: `Failed to set placeholder text: ${error instanceof Error ? error.message : String(error)}` };
|
|
94
|
+
}
|
|
95
|
+
}
|
|
96
|
+
export const powerpointSetPlaceholderTextTool = {
|
|
97
|
+
definition: POWERPOINT_SET_PLACEHOLDER_TEXT_DEFINITION,
|
|
98
|
+
execute: executePowerPointSetPlaceholderText,
|
|
99
|
+
categories: OFFICE_CATEGORIES,
|
|
100
|
+
description: 'Set placeholder text',
|
|
101
|
+
};
|
|
102
|
+
const POWERPOINT_GET_PLACEHOLDERS_DEFINITION = {
|
|
103
|
+
type: 'function',
|
|
104
|
+
function: {
|
|
105
|
+
name: 'powerpoint_get_placeholders',
|
|
106
|
+
description: `Get list of placeholders on a slide.`,
|
|
107
|
+
parameters: {
|
|
108
|
+
type: 'object',
|
|
109
|
+
properties: {
|
|
110
|
+
slide_number: { type: 'number', description: 'Slide number' },
|
|
111
|
+
},
|
|
112
|
+
required: ['slide_number'],
|
|
113
|
+
},
|
|
114
|
+
},
|
|
115
|
+
};
|
|
116
|
+
async function executePowerPointGetPlaceholders(args) {
|
|
117
|
+
try {
|
|
118
|
+
const response = await powerpointClient.powerpointGetPlaceholders(args['slide_number']);
|
|
119
|
+
if (response.success) {
|
|
120
|
+
return { success: true, result: JSON.stringify(response, null, 2) };
|
|
121
|
+
}
|
|
122
|
+
return { success: false, error: response.error || 'Failed to get placeholders' };
|
|
123
|
+
}
|
|
124
|
+
catch (error) {
|
|
125
|
+
return { success: false, error: `Failed to get placeholders: ${error instanceof Error ? error.message : String(error)}` };
|
|
126
|
+
}
|
|
127
|
+
}
|
|
128
|
+
export const powerpointGetPlaceholdersTool = {
|
|
129
|
+
definition: POWERPOINT_GET_PLACEHOLDERS_DEFINITION,
|
|
130
|
+
execute: executePowerPointGetPlaceholders,
|
|
131
|
+
categories: OFFICE_CATEGORIES,
|
|
132
|
+
description: 'Get placeholders on slide',
|
|
133
|
+
};
|
|
134
|
+
const POWERPOINT_GET_SLIDE_LAYOUTS_DEFINITION = {
|
|
135
|
+
type: 'function',
|
|
136
|
+
function: {
|
|
137
|
+
name: 'powerpoint_get_slide_layouts',
|
|
138
|
+
description: `Get available slide layouts.`,
|
|
139
|
+
parameters: {
|
|
140
|
+
type: 'object',
|
|
141
|
+
properties: {},
|
|
142
|
+
required: [],
|
|
143
|
+
},
|
|
144
|
+
},
|
|
145
|
+
};
|
|
146
|
+
async function executePowerPointGetSlideLayouts(_args) {
|
|
147
|
+
try {
|
|
148
|
+
const response = await powerpointClient.powerpointGetSlideLayouts();
|
|
149
|
+
if (response.success) {
|
|
150
|
+
return { success: true, result: JSON.stringify(response, null, 2) };
|
|
151
|
+
}
|
|
152
|
+
return { success: false, error: response.error || 'Failed to get slide layouts' };
|
|
153
|
+
}
|
|
154
|
+
catch (error) {
|
|
155
|
+
return { success: false, error: `Failed to get slide layouts: ${error instanceof Error ? error.message : String(error)}` };
|
|
156
|
+
}
|
|
157
|
+
}
|
|
158
|
+
export const powerpointGetSlideLayoutsTool = {
|
|
159
|
+
definition: POWERPOINT_GET_SLIDE_LAYOUTS_DEFINITION,
|
|
160
|
+
execute: executePowerPointGetSlideLayouts,
|
|
161
|
+
categories: OFFICE_CATEGORIES,
|
|
162
|
+
description: 'Get available slide layouts',
|
|
163
|
+
};
|
|
164
|
+
export const notesTools = [
|
|
165
|
+
powerpointAddNoteTool,
|
|
166
|
+
powerpointGetNoteTool,
|
|
167
|
+
powerpointSetPlaceholderTextTool,
|
|
168
|
+
powerpointGetPlaceholdersTool,
|
|
169
|
+
powerpointGetSlideLayoutsTool,
|
|
170
|
+
];
|
|
171
|
+
//# sourceMappingURL=notes.js.map
|