@codemieai/code 0.0.45 → 0.0.47
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/agents/core/BaseAgentAdapter.d.ts.map +1 -1
- package/dist/agents/core/BaseAgentAdapter.js +20 -3
- package/dist/agents/core/BaseAgentAdapter.js.map +1 -1
- package/dist/agents/core/metrics/types.d.ts +0 -6
- package/dist/agents/core/metrics/types.d.ts.map +1 -1
- package/dist/agents/core/session/BaseSessionAdapter.d.ts +0 -6
- package/dist/agents/core/session/BaseSessionAdapter.d.ts.map +1 -1
- package/dist/agents/plugins/claude/claude.plugin-installer.d.ts +0 -11
- package/dist/agents/plugins/claude/claude.plugin-installer.d.ts.map +1 -1
- package/dist/agents/plugins/claude/claude.plugin-installer.js +0 -32
- package/dist/agents/plugins/claude/claude.plugin-installer.js.map +1 -1
- package/dist/agents/plugins/claude/claude.plugin.js +1 -1
- package/dist/agents/plugins/claude/claude.session.d.ts.map +1 -1
- package/dist/agents/plugins/claude/claude.session.js +1 -28
- package/dist/agents/plugins/claude/claude.session.js.map +1 -1
- package/dist/agents/plugins/claude/plugin/.claude-plugin/plugin.json +1 -1
- package/dist/agents/plugins/claude/plugin/README.md +1 -14
- package/dist/agents/plugins/claude/plugin/hooks/hooks.json +4 -4
- package/dist/agents/plugins/claude/plugin/skills/claude-setup-audit/SKILL.md +206 -0
- package/dist/agents/plugins/claude/plugin/skills/claude-setup-audit/examples/bad-agent.md +45 -0
- package/dist/agents/plugins/claude/plugin/skills/claude-setup-audit/examples/bad-claude-md-snippet.md +40 -0
- package/dist/agents/plugins/claude/plugin/skills/claude-setup-audit/examples/bad-command.md +30 -0
- package/dist/agents/plugins/claude/plugin/skills/claude-setup-audit/examples/bad-hooks.json +23 -0
- package/dist/agents/plugins/claude/plugin/skills/claude-setup-audit/examples/bad-skill.md +48 -0
- package/dist/agents/plugins/claude/plugin/skills/claude-setup-audit/examples/good-agent.md +145 -0
- package/dist/agents/plugins/claude/plugin/skills/claude-setup-audit/examples/good-claude-md-snippet.md +126 -0
- package/dist/agents/plugins/claude/plugin/skills/claude-setup-audit/examples/good-command.md +170 -0
- package/dist/agents/plugins/claude/plugin/skills/claude-setup-audit/examples/good-hooks.json +46 -0
- package/dist/agents/plugins/claude/plugin/skills/claude-setup-audit/examples/good-skill.md +144 -0
- package/dist/agents/plugins/claude/plugin/skills/claude-setup-audit/examples/sample-report.md +223 -0
- package/dist/agents/plugins/claude/plugin/skills/claude-setup-audit/references/best-practices.md +510 -0
- package/dist/agents/plugins/claude/plugin/skills/claude-setup-audit/references/component-checklists.md +413 -0
- package/dist/agents/plugins/claude/plugin/skills/claude-setup-audit/scripts/scan-repo.sh +162 -0
- package/dist/agents/plugins/claude/plugin/skills/msgraph/README.md +183 -0
- package/dist/agents/plugins/claude/plugin/skills/msgraph/SKILL.md +233 -0
- package/dist/agents/plugins/claude/plugin/skills/msgraph/scripts/msgraph.py +785 -0
- package/dist/agents/plugins/claude/session/processors/claude.conversations-processor.d.ts.map +1 -1
- package/dist/agents/plugins/claude/session/processors/claude.conversations-processor.js +3 -78
- package/dist/agents/plugins/claude/session/processors/claude.conversations-processor.js.map +1 -1
- package/dist/agents/plugins/claude/session/processors/claude.metrics-processor.d.ts.map +1 -1
- package/dist/agents/plugins/claude/session/processors/claude.metrics-processor.js +7 -16
- package/dist/agents/plugins/claude/session/processors/claude.metrics-processor.js.map +1 -1
- package/dist/agents/plugins/claude/sounds-installer.d.ts +1 -1
- package/dist/agents/plugins/claude/sounds-installer.d.ts.map +1 -1
- package/dist/agents/plugins/claude/sounds-installer.js +1 -4
- package/dist/agents/plugins/claude/sounds-installer.js.map +1 -1
- package/dist/agents/plugins/codemie-code.plugin.d.ts +1 -4
- package/dist/agents/plugins/codemie-code.plugin.d.ts.map +1 -1
- package/dist/agents/plugins/codemie-code.plugin.js +26 -81
- package/dist/agents/plugins/codemie-code.plugin.js.map +1 -1
- package/dist/agents/plugins/gemini/gemini.session-adapter.d.ts +1 -8
- package/dist/agents/plugins/gemini/gemini.session-adapter.d.ts.map +1 -1
- package/dist/agents/plugins/gemini/gemini.session-adapter.js +2 -30
- package/dist/agents/plugins/gemini/gemini.session-adapter.js.map +1 -1
- package/dist/agents/plugins/gemini/session/processors/gemini.conversations-processor.d.ts.map +1 -1
- package/dist/agents/plugins/gemini/session/processors/gemini.conversations-processor.js +2 -8
- package/dist/agents/plugins/gemini/session/processors/gemini.conversations-processor.js.map +1 -1
- package/dist/agents/plugins/gemini/session/processors/gemini.metrics-processor.d.ts.map +1 -1
- package/dist/agents/plugins/gemini/session/processors/gemini.metrics-processor.js +0 -7
- package/dist/agents/plugins/gemini/session/processors/gemini.metrics-processor.js.map +1 -1
- package/dist/agents/plugins/opencode/index.d.ts +1 -1
- package/dist/agents/plugins/opencode/index.d.ts.map +1 -1
- package/dist/agents/plugins/opencode/index.js.map +1 -1
- package/dist/agents/plugins/opencode/opencode-message-types.d.ts +2 -22
- package/dist/agents/plugins/opencode/opencode-message-types.d.ts.map +1 -1
- package/dist/agents/plugins/opencode/opencode-message-types.js.map +1 -1
- package/dist/agents/plugins/opencode/opencode.session.d.ts.map +1 -1
- package/dist/agents/plugins/opencode/opencode.session.js +5 -30
- package/dist/agents/plugins/opencode/opencode.session.js.map +1 -1
- package/dist/agents/plugins/opencode/opencode.sqlite-reader.d.ts.map +1 -1
- package/dist/agents/plugins/opencode/opencode.sqlite-reader.js +0 -2
- package/dist/agents/plugins/opencode/opencode.sqlite-reader.js.map +1 -1
- package/dist/agents/plugins/opencode/session/processors/opencode.metrics-processor.d.ts +0 -8
- package/dist/agents/plugins/opencode/session/processors/opencode.metrics-processor.d.ts.map +1 -1
- package/dist/agents/plugins/opencode/session/processors/opencode.metrics-processor.js +8 -97
- package/dist/agents/plugins/opencode/session/processors/opencode.metrics-processor.js.map +1 -1
- package/dist/cli/commands/analytics/aggregator.d.ts +0 -8
- package/dist/cli/commands/analytics/aggregator.d.ts.map +1 -1
- package/dist/cli/commands/analytics/aggregator.js +5 -100
- package/dist/cli/commands/analytics/aggregator.js.map +1 -1
- package/dist/cli/commands/analytics/data-loader.d.ts +0 -7
- package/dist/cli/commands/analytics/data-loader.d.ts.map +1 -1
- package/dist/cli/commands/analytics/data-loader.js +3 -10
- package/dist/cli/commands/analytics/data-loader.js.map +1 -1
- package/dist/cli/commands/analytics/exporter.d.ts.map +1 -1
- package/dist/cli/commands/analytics/exporter.js +0 -12
- package/dist/cli/commands/analytics/exporter.js.map +1 -1
- package/dist/cli/commands/analytics/formatter.d.ts.map +1 -1
- package/dist/cli/commands/analytics/formatter.js +0 -9
- package/dist/cli/commands/analytics/formatter.js.map +1 -1
- package/dist/cli/commands/analytics/types.d.ts +0 -17
- package/dist/cli/commands/analytics/types.d.ts.map +1 -1
- package/dist/cli/commands/assistants/chat/historyLoader.d.ts +22 -0
- package/dist/cli/commands/assistants/chat/historyLoader.d.ts.map +1 -0
- package/dist/cli/commands/assistants/chat/historyLoader.js +80 -0
- package/dist/cli/commands/assistants/chat/historyLoader.js.map +1 -0
- package/dist/cli/commands/assistants/{chat.d.ts → chat/index.d.ts} +1 -1
- package/dist/cli/commands/assistants/chat/index.d.ts.map +1 -0
- package/dist/cli/commands/assistants/{chat.js → chat/index.js} +54 -45
- package/dist/cli/commands/assistants/chat/index.js.map +1 -0
- package/dist/cli/commands/assistants/chat/types.d.ts +27 -0
- package/dist/cli/commands/assistants/chat/types.d.ts.map +1 -0
- package/dist/cli/commands/assistants/chat/types.js +5 -0
- package/dist/cli/commands/assistants/chat/types.js.map +1 -0
- package/dist/cli/commands/assistants/chat/utils.d.ts +12 -0
- package/dist/cli/commands/assistants/chat/utils.d.ts.map +1 -0
- package/dist/cli/commands/assistants/chat/utils.js +24 -0
- package/dist/cli/commands/assistants/chat/utils.js.map +1 -0
- package/dist/cli/commands/assistants/constants.d.ts +1 -0
- package/dist/cli/commands/assistants/constants.d.ts.map +1 -1
- package/dist/cli/commands/assistants/constants.js.map +1 -1
- package/dist/cli/commands/assistants/index.js +2 -2
- package/dist/cli/commands/assistants/index.js.map +1 -1
- package/dist/cli/commands/assistants/setup/generators/claude-agent-generator.js +1 -1
- package/dist/cli/commands/assistants/setup/generators/claude-skill-generator.js +1 -1
- package/dist/cli/commands/assistants/setup/index.js +4 -4
- package/dist/cli/commands/assistants/setup/index.js.map +1 -1
- package/dist/cli/commands/assistants/setup/selection/index.d.ts +1 -1
- package/dist/cli/commands/assistants/setup/selection/index.d.ts.map +1 -1
- package/dist/cli/commands/assistants/setup/selection/index.js +5 -3
- package/dist/cli/commands/assistants/setup/selection/index.js.map +1 -1
- package/dist/cli/commands/assistants/setup/selection/interactive-prompt.d.ts.map +1 -1
- package/dist/cli/commands/assistants/setup/selection/interactive-prompt.js +7 -1
- package/dist/cli/commands/assistants/setup/selection/interactive-prompt.js.map +1 -1
- package/dist/cli/commands/assistants/setup/selection/types.d.ts +2 -0
- package/dist/cli/commands/assistants/setup/selection/types.d.ts.map +1 -1
- package/dist/cli/commands/assistants/setup/selection/ui.d.ts.map +1 -1
- package/dist/cli/commands/assistants/setup/selection/ui.js +15 -4
- package/dist/cli/commands/assistants/setup/selection/ui.js.map +1 -1
- package/dist/cli/commands/hook.js +1 -1
- package/dist/cli/commands/hook.js.map +1 -1
- package/dist/cli/commands/plugin.d.ts +16 -0
- package/dist/cli/commands/plugin.d.ts.map +1 -0
- package/dist/cli/commands/plugin.js +210 -0
- package/dist/cli/commands/plugin.js.map +1 -0
- package/dist/cli/commands/setup.js +1 -1
- package/dist/cli/commands/skill.d.ts.map +1 -1
- package/dist/cli/commands/skill.js +3 -1
- package/dist/cli/commands/skill.js.map +1 -1
- package/dist/cli/commands/sound.d.ts +3 -0
- package/dist/cli/commands/sound.d.ts.map +1 -0
- package/dist/cli/commands/sound.js +87 -0
- package/dist/cli/commands/sound.js.map +1 -0
- package/dist/cli/commands/test-metrics.js +3 -5
- package/dist/cli/commands/test-metrics.js.map +1 -1
- package/dist/cli/index.js +4 -0
- package/dist/cli/index.js.map +1 -1
- package/dist/env/types.d.ts +8 -0
- package/dist/env/types.d.ts.map +1 -1
- package/dist/env/types.js.map +1 -1
- package/dist/plugins/core/index.d.ts +13 -0
- package/dist/plugins/core/index.d.ts.map +1 -0
- package/dist/plugins/core/index.js +15 -0
- package/dist/plugins/core/index.js.map +1 -0
- package/dist/plugins/core/manifest-parser.d.ts +28 -0
- package/dist/plugins/core/manifest-parser.d.ts.map +1 -0
- package/dist/plugins/core/manifest-parser.js +137 -0
- package/dist/plugins/core/manifest-parser.js.map +1 -0
- package/dist/plugins/core/plugin-cache.d.ts +65 -0
- package/dist/plugins/core/plugin-cache.d.ts.map +1 -0
- package/dist/plugins/core/plugin-cache.js +170 -0
- package/dist/plugins/core/plugin-cache.js.map +1 -0
- package/dist/plugins/core/plugin-loader.d.ts +21 -0
- package/dist/plugins/core/plugin-loader.d.ts.map +1 -0
- package/dist/plugins/core/plugin-loader.js +55 -0
- package/dist/plugins/core/plugin-loader.js.map +1 -0
- package/dist/plugins/core/plugin-resolver.d.ts +33 -0
- package/dist/plugins/core/plugin-resolver.d.ts.map +1 -0
- package/dist/plugins/core/plugin-resolver.js +118 -0
- package/dist/plugins/core/plugin-resolver.js.map +1 -0
- package/dist/plugins/core/types.d.ts +183 -0
- package/dist/plugins/core/types.d.ts.map +1 -0
- package/dist/plugins/core/types.js +22 -0
- package/dist/plugins/core/types.js.map +1 -0
- package/dist/plugins/loaders/agents-loader.d.ts +19 -0
- package/dist/plugins/loaders/agents-loader.d.ts.map +1 -0
- package/dist/plugins/loaders/agents-loader.js +92 -0
- package/dist/plugins/loaders/agents-loader.js.map +1 -0
- package/dist/plugins/loaders/hooks-loader.d.ts +27 -0
- package/dist/plugins/loaders/hooks-loader.d.ts.map +1 -0
- package/dist/plugins/loaders/hooks-loader.js +94 -0
- package/dist/plugins/loaders/hooks-loader.js.map +1 -0
- package/dist/plugins/loaders/mcp-loader.d.ts +24 -0
- package/dist/plugins/loaders/mcp-loader.d.ts.map +1 -0
- package/dist/plugins/loaders/mcp-loader.js +86 -0
- package/dist/plugins/loaders/mcp-loader.js.map +1 -0
- package/dist/plugins/loaders/skills-loader.d.ts +30 -0
- package/dist/plugins/loaders/skills-loader.d.ts.map +1 -0
- package/dist/plugins/loaders/skills-loader.js +167 -0
- package/dist/plugins/loaders/skills-loader.js.map +1 -0
- package/dist/providers/plugins/bedrock/bedrock.template.js +1 -1
- package/dist/providers/plugins/jwt/jwt.setup-steps.js +1 -1
- package/dist/providers/plugins/jwt/jwt.template.js +1 -1
- package/dist/providers/plugins/litellm/litellm.template.js +1 -1
- package/dist/providers/plugins/sso/proxy/plugins/header-injection.plugin.js +10 -0
- package/dist/providers/plugins/sso/proxy/plugins/header-injection.plugin.js.map +1 -1
- package/dist/providers/plugins/sso/proxy/proxy-types.d.ts +3 -0
- package/dist/providers/plugins/sso/proxy/proxy-types.d.ts.map +1 -1
- package/dist/providers/plugins/sso/session/SessionSyncer.d.ts.map +1 -1
- package/dist/providers/plugins/sso/session/SessionSyncer.js +2 -3
- package/dist/providers/plugins/sso/session/SessionSyncer.js.map +1 -1
- package/dist/providers/plugins/sso/session/processors/conversations/apiClient.d.ts +21 -0
- package/dist/providers/plugins/sso/session/processors/conversations/apiClient.d.ts.map +1 -0
- package/dist/providers/plugins/sso/session/processors/conversations/apiClient.js +159 -0
- package/dist/providers/plugins/sso/session/processors/conversations/apiClient.js.map +1 -0
- package/dist/providers/plugins/sso/session/processors/conversations/constants.d.ts +24 -0
- package/dist/providers/plugins/sso/session/processors/conversations/constants.d.ts.map +1 -0
- package/dist/providers/plugins/sso/session/processors/conversations/constants.js +36 -0
- package/dist/providers/plugins/sso/session/processors/conversations/constants.js.map +1 -0
- package/dist/providers/plugins/sso/session/processors/conversations/syncProcessor.d.ts +19 -0
- package/dist/providers/plugins/sso/session/processors/conversations/syncProcessor.d.ts.map +1 -0
- package/dist/providers/plugins/sso/session/processors/conversations/{conversation-sync-processor.js → syncProcessor.js} +48 -33
- package/dist/providers/plugins/sso/session/processors/conversations/syncProcessor.js.map +1 -0
- package/dist/providers/plugins/sso/session/processors/conversations/{conversation-types.d.ts → types.d.ts} +14 -2
- package/dist/providers/plugins/sso/session/processors/conversations/types.d.ts.map +1 -0
- package/dist/providers/plugins/sso/session/processors/conversations/types.js +14 -0
- package/dist/providers/plugins/sso/session/processors/conversations/types.js.map +1 -0
- package/dist/providers/plugins/sso/session/processors/metrics/metrics-aggregator.d.ts.map +1 -1
- package/dist/providers/plugins/sso/session/processors/metrics/metrics-aggregator.js +16 -17
- package/dist/providers/plugins/sso/session/processors/metrics/metrics-aggregator.js.map +1 -1
- package/dist/providers/plugins/sso/session/processors/metrics/metrics-api-client.d.ts +3 -3
- package/dist/providers/plugins/sso/session/processors/metrics/metrics-api-client.d.ts.map +1 -1
- package/dist/providers/plugins/sso/session/processors/metrics/metrics-api-client.js +8 -38
- package/dist/providers/plugins/sso/session/processors/metrics/metrics-api-client.js.map +1 -1
- package/dist/providers/plugins/sso/session/processors/metrics/metrics-sync-processor.d.ts.map +1 -1
- package/dist/providers/plugins/sso/session/processors/metrics/metrics-sync-processor.js +2 -6
- package/dist/providers/plugins/sso/session/processors/metrics/metrics-sync-processor.js.map +1 -1
- package/dist/providers/plugins/sso/session/processors/metrics/metrics-types.d.ts +49 -31
- package/dist/providers/plugins/sso/session/processors/metrics/metrics-types.d.ts.map +1 -1
- package/dist/providers/plugins/sso/sso.template.js +1 -1
- package/dist/{agents/codemie-code/skills → skills}/core/SkillDiscovery.d.ts +10 -0
- package/dist/skills/core/SkillDiscovery.d.ts.map +1 -0
- package/dist/{agents/codemie-code/skills → skills}/core/SkillDiscovery.js +64 -7
- package/dist/skills/core/SkillDiscovery.js.map +1 -0
- package/dist/skills/core/SkillManager.d.ts.map +1 -0
- package/dist/{agents/codemie-code/skills → skills}/core/SkillManager.js +15 -10
- package/dist/skills/core/SkillManager.js.map +1 -0
- package/dist/{agents/codemie-code/skills → skills}/core/types.d.ts +3 -25
- package/dist/skills/core/types.d.ts.map +1 -0
- package/dist/skills/core/types.js.map +1 -0
- package/dist/{agents/codemie-code/skills → skills}/index.d.ts +3 -3
- package/dist/skills/index.d.ts.map +1 -0
- package/dist/{agents/codemie-code/skills → skills}/index.js +2 -2
- package/dist/skills/index.js.map +1 -0
- package/dist/skills/sync/SkillSync.d.ts.map +1 -0
- package/dist/{agents/codemie-code/skills → skills}/sync/SkillSync.js +5 -3
- package/dist/skills/sync/SkillSync.js.map +1 -0
- package/dist/{agents/codemie-code/skills → skills}/utils/content-loader.d.ts +2 -12
- package/dist/skills/utils/content-loader.d.ts.map +1 -0
- package/dist/{agents/codemie-code/skills → skills}/utils/content-loader.js +3 -8
- package/dist/skills/utils/content-loader.js.map +1 -0
- package/dist/skills/utils/pattern-matcher.d.ts.map +1 -0
- package/dist/skills/utils/pattern-matcher.js.map +1 -0
- package/dist/utils/frontmatter.d.ts.map +1 -0
- package/dist/utils/frontmatter.js.map +1 -0
- package/package.json +1 -1
- package/dist/agents/codemie-code/agent.d.ts +0 -129
- package/dist/agents/codemie-code/agent.d.ts.map +0 -1
- package/dist/agents/codemie-code/agent.js +0 -1106
- package/dist/agents/codemie-code/agent.js.map +0 -1
- package/dist/agents/codemie-code/config.d.ts +0 -40
- package/dist/agents/codemie-code/config.d.ts.map +0 -1
- package/dist/agents/codemie-code/config.js +0 -293
- package/dist/agents/codemie-code/config.js.map +0 -1
- package/dist/agents/codemie-code/filters.d.ts +0 -91
- package/dist/agents/codemie-code/filters.d.ts.map +0 -1
- package/dist/agents/codemie-code/filters.js +0 -328
- package/dist/agents/codemie-code/filters.js.map +0 -1
- package/dist/agents/codemie-code/index.d.ts +0 -93
- package/dist/agents/codemie-code/index.d.ts.map +0 -1
- package/dist/agents/codemie-code/index.js +0 -359
- package/dist/agents/codemie-code/index.js.map +0 -1
- package/dist/agents/codemie-code/modes/contextAwarePlanning.d.ts +0 -87
- package/dist/agents/codemie-code/modes/contextAwarePlanning.d.ts.map +0 -1
- package/dist/agents/codemie-code/modes/contextAwarePlanning.js +0 -957
- package/dist/agents/codemie-code/modes/contextAwarePlanning.js.map +0 -1
- package/dist/agents/codemie-code/modes/planMode.d.ts +0 -116
- package/dist/agents/codemie-code/modes/planMode.d.ts.map +0 -1
- package/dist/agents/codemie-code/modes/planMode.js +0 -537
- package/dist/agents/codemie-code/modes/planMode.js.map +0 -1
- package/dist/agents/codemie-code/prompts.d.ts +0 -47
- package/dist/agents/codemie-code/prompts.d.ts.map +0 -1
- package/dist/agents/codemie-code/prompts.js +0 -207
- package/dist/agents/codemie-code/prompts.js.map +0 -1
- package/dist/agents/codemie-code/skills/core/SkillDiscovery.d.ts.map +0 -1
- package/dist/agents/codemie-code/skills/core/SkillDiscovery.js.map +0 -1
- package/dist/agents/codemie-code/skills/core/SkillManager.d.ts.map +0 -1
- package/dist/agents/codemie-code/skills/core/SkillManager.js.map +0 -1
- package/dist/agents/codemie-code/skills/core/types.d.ts.map +0 -1
- package/dist/agents/codemie-code/skills/core/types.js.map +0 -1
- package/dist/agents/codemie-code/skills/index.d.ts.map +0 -1
- package/dist/agents/codemie-code/skills/index.js.map +0 -1
- package/dist/agents/codemie-code/skills/sync/SkillSync.d.ts.map +0 -1
- package/dist/agents/codemie-code/skills/sync/SkillSync.js.map +0 -1
- package/dist/agents/codemie-code/skills/utils/content-loader.d.ts.map +0 -1
- package/dist/agents/codemie-code/skills/utils/content-loader.js.map +0 -1
- package/dist/agents/codemie-code/skills/utils/frontmatter.d.ts.map +0 -1
- package/dist/agents/codemie-code/skills/utils/frontmatter.js.map +0 -1
- package/dist/agents/codemie-code/skills/utils/pattern-matcher.d.ts.map +0 -1
- package/dist/agents/codemie-code/skills/utils/pattern-matcher.js.map +0 -1
- package/dist/agents/codemie-code/storage/todoStorage.d.ts +0 -78
- package/dist/agents/codemie-code/storage/todoStorage.d.ts.map +0 -1
- package/dist/agents/codemie-code/storage/todoStorage.js +0 -225
- package/dist/agents/codemie-code/storage/todoStorage.js.map +0 -1
- package/dist/agents/codemie-code/tokenUtils.d.ts +0 -108
- package/dist/agents/codemie-code/tokenUtils.d.ts.map +0 -1
- package/dist/agents/codemie-code/tokenUtils.js +0 -220
- package/dist/agents/codemie-code/tokenUtils.js.map +0 -1
- package/dist/agents/codemie-code/toolMetadata.d.ts +0 -15
- package/dist/agents/codemie-code/toolMetadata.d.ts.map +0 -1
- package/dist/agents/codemie-code/toolMetadata.js +0 -316
- package/dist/agents/codemie-code/toolMetadata.js.map +0 -1
- package/dist/agents/codemie-code/tools/assistant-invocation.d.ts +0 -47
- package/dist/agents/codemie-code/tools/assistant-invocation.d.ts.map +0 -1
- package/dist/agents/codemie-code/tools/assistant-invocation.js +0 -129
- package/dist/agents/codemie-code/tools/assistant-invocation.js.map +0 -1
- package/dist/agents/codemie-code/tools/index.d.ts +0 -111
- package/dist/agents/codemie-code/tools/index.d.ts.map +0 -1
- package/dist/agents/codemie-code/tools/index.js +0 -424
- package/dist/agents/codemie-code/tools/index.js.map +0 -1
- package/dist/agents/codemie-code/tools/planning.d.ts +0 -54
- package/dist/agents/codemie-code/tools/planning.d.ts.map +0 -1
- package/dist/agents/codemie-code/tools/planning.js +0 -226
- package/dist/agents/codemie-code/tools/planning.js.map +0 -1
- package/dist/agents/codemie-code/types.d.ts +0 -459
- package/dist/agents/codemie-code/types.d.ts.map +0 -1
- package/dist/agents/codemie-code/types.js +0 -59
- package/dist/agents/codemie-code/types.js.map +0 -1
- package/dist/agents/codemie-code/ui/autocomplete.d.ts +0 -98
- package/dist/agents/codemie-code/ui/autocomplete.d.ts.map +0 -1
- package/dist/agents/codemie-code/ui/autocomplete.js +0 -145
- package/dist/agents/codemie-code/ui/autocomplete.js.map +0 -1
- package/dist/agents/codemie-code/ui/keyHandlers.d.ts +0 -112
- package/dist/agents/codemie-code/ui/keyHandlers.d.ts.map +0 -1
- package/dist/agents/codemie-code/ui/keyHandlers.js +0 -415
- package/dist/agents/codemie-code/ui/keyHandlers.js.map +0 -1
- package/dist/agents/codemie-code/ui/mentions.d.ts +0 -86
- package/dist/agents/codemie-code/ui/mentions.d.ts.map +0 -1
- package/dist/agents/codemie-code/ui/mentions.js +0 -122
- package/dist/agents/codemie-code/ui/mentions.js.map +0 -1
- package/dist/agents/codemie-code/ui/progressTracker.d.ts +0 -125
- package/dist/agents/codemie-code/ui/progressTracker.d.ts.map +0 -1
- package/dist/agents/codemie-code/ui/progressTracker.js +0 -343
- package/dist/agents/codemie-code/ui/progressTracker.js.map +0 -1
- package/dist/agents/codemie-code/ui/terminalCodes.d.ts +0 -38
- package/dist/agents/codemie-code/ui/terminalCodes.d.ts.map +0 -1
- package/dist/agents/codemie-code/ui/terminalCodes.js +0 -42
- package/dist/agents/codemie-code/ui/terminalCodes.js.map +0 -1
- package/dist/agents/codemie-code/ui/todoPanel.d.ts +0 -112
- package/dist/agents/codemie-code/ui/todoPanel.d.ts.map +0 -1
- package/dist/agents/codemie-code/ui/todoPanel.js +0 -321
- package/dist/agents/codemie-code/ui/todoPanel.js.map +0 -1
- package/dist/agents/codemie-code/ui.d.ts +0 -180
- package/dist/agents/codemie-code/ui.d.ts.map +0 -1
- package/dist/agents/codemie-code/ui.js +0 -1345
- package/dist/agents/codemie-code/ui.js.map +0 -1
- package/dist/agents/codemie-code/utils/progressionEnforcer.d.ts +0 -87
- package/dist/agents/codemie-code/utils/progressionEnforcer.d.ts.map +0 -1
- package/dist/agents/codemie-code/utils/progressionEnforcer.js +0 -293
- package/dist/agents/codemie-code/utils/progressionEnforcer.js.map +0 -1
- package/dist/agents/codemie-code/utils/todoParser.d.ts +0 -41
- package/dist/agents/codemie-code/utils/todoParser.d.ts.map +0 -1
- package/dist/agents/codemie-code/utils/todoParser.js +0 -305
- package/dist/agents/codemie-code/utils/todoParser.js.map +0 -1
- package/dist/agents/codemie-code/utils/todoValidator.d.ts +0 -65
- package/dist/agents/codemie-code/utils/todoValidator.d.ts.map +0 -1
- package/dist/agents/codemie-code/utils/todoValidator.js +0 -249
- package/dist/agents/codemie-code/utils/todoValidator.js.map +0 -1
- package/dist/agents/codemie-code/validators/planValidator.d.ts +0 -94
- package/dist/agents/codemie-code/validators/planValidator.d.ts.map +0 -1
- package/dist/agents/codemie-code/validators/planValidator.js +0 -281
- package/dist/agents/codemie-code/validators/planValidator.js.map +0 -1
- package/dist/agents/plugins/claude/plugin/hooks/hooks.windows.json +0 -98
- package/dist/agents/plugins/claude/plugin/sounds/play-random-sound.ps1 +0 -112
- package/dist/agents/plugins/claude/plugin/sounds/play-random-sound.sh +0 -58
- package/dist/agents/plugins/gemini/session/utils/token-aggregator.d.ts +0 -26
- package/dist/agents/plugins/gemini/session/utils/token-aggregator.d.ts.map +0 -1
- package/dist/agents/plugins/gemini/session/utils/token-aggregator.js +0 -38
- package/dist/agents/plugins/gemini/session/utils/token-aggregator.js.map +0 -1
- package/dist/cli/commands/assistants/chat.d.ts.map +0 -1
- package/dist/cli/commands/assistants/chat.js.map +0 -1
- package/dist/providers/plugins/sso/session/processors/conversations/conversation-api-client.d.ts +0 -26
- package/dist/providers/plugins/sso/session/processors/conversations/conversation-api-client.d.ts.map +0 -1
- package/dist/providers/plugins/sso/session/processors/conversations/conversation-api-client.js +0 -146
- package/dist/providers/plugins/sso/session/processors/conversations/conversation-api-client.js.map +0 -1
- package/dist/providers/plugins/sso/session/processors/conversations/conversation-sync-processor.d.ts +0 -22
- package/dist/providers/plugins/sso/session/processors/conversations/conversation-sync-processor.d.ts.map +0 -1
- package/dist/providers/plugins/sso/session/processors/conversations/conversation-sync-processor.js.map +0 -1
- package/dist/providers/plugins/sso/session/processors/conversations/conversation-types.d.ts.map +0 -1
- package/dist/providers/plugins/sso/session/processors/conversations/conversation-types.js +0 -7
- package/dist/providers/plugins/sso/session/processors/conversations/conversation-types.js.map +0 -1
- /package/dist/{agents/codemie-code/skills → skills}/core/SkillManager.d.ts +0 -0
- /package/dist/{agents/codemie-code/skills → skills}/core/types.js +0 -0
- /package/dist/{agents/codemie-code/skills → skills}/sync/SkillSync.d.ts +0 -0
- /package/dist/{agents/codemie-code/skills → skills}/utils/pattern-matcher.d.ts +0 -0
- /package/dist/{agents/codemie-code/skills → skills}/utils/pattern-matcher.js +0 -0
- /package/dist/{agents/codemie-code/skills/utils → utils}/frontmatter.d.ts +0 -0
- /package/dist/{agents/codemie-code/skills/utils → utils}/frontmatter.js +0 -0
|
@@ -1,94 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Plan Validator
|
|
3
|
-
*
|
|
4
|
-
* Validates the quality and completeness of generated plans
|
|
5
|
-
* Ensures plans follow best practices for structured execution
|
|
6
|
-
*/
|
|
7
|
-
import type { Todo } from '../types.js';
|
|
8
|
-
import { type TodoListValidationResult } from '../utils/todoValidator.js';
|
|
9
|
-
/**
|
|
10
|
-
* Plan validation criteria
|
|
11
|
-
*/
|
|
12
|
-
export interface PlanValidationCriteria {
|
|
13
|
-
/** Minimum number of steps required */
|
|
14
|
-
minSteps: number;
|
|
15
|
-
/** Maximum number of steps allowed */
|
|
16
|
-
maxSteps: number;
|
|
17
|
-
/** Minimum quality score (0-100) */
|
|
18
|
-
minQualityScore: number;
|
|
19
|
-
/** Required step patterns */
|
|
20
|
-
requiredPatterns: {
|
|
21
|
-
/** Must include discovery/analysis steps */
|
|
22
|
-
discovery: boolean;
|
|
23
|
-
/** Must include implementation steps */
|
|
24
|
-
implementation: boolean;
|
|
25
|
-
/** Must include testing/verification steps */
|
|
26
|
-
testing: boolean;
|
|
27
|
-
/** Must include completion/documentation steps */
|
|
28
|
-
completion: boolean;
|
|
29
|
-
};
|
|
30
|
-
/** Task-specific requirements */
|
|
31
|
-
taskSpecific: {
|
|
32
|
-
/** Must reference specific files or components */
|
|
33
|
-
specificReferences: boolean;
|
|
34
|
-
/** Must use action verbs */
|
|
35
|
-
actionVerbs: boolean;
|
|
36
|
-
/** Must have clear completion criteria */
|
|
37
|
-
completionCriteria: boolean;
|
|
38
|
-
};
|
|
39
|
-
}
|
|
40
|
-
/**
|
|
41
|
-
* Comprehensive plan validation result
|
|
42
|
-
*/
|
|
43
|
-
export interface PlanValidationResult extends TodoListValidationResult {
|
|
44
|
-
/** Whether plan meets all criteria */
|
|
45
|
-
meetsCriteria: boolean;
|
|
46
|
-
/** Detailed criteria assessment */
|
|
47
|
-
criteriaAssessment: {
|
|
48
|
-
stepCount: {
|
|
49
|
-
valid: boolean;
|
|
50
|
-
actual: number;
|
|
51
|
-
required: string;
|
|
52
|
-
};
|
|
53
|
-
qualityScore: {
|
|
54
|
-
valid: boolean;
|
|
55
|
-
actual: number;
|
|
56
|
-
required: number;
|
|
57
|
-
};
|
|
58
|
-
patterns: {
|
|
59
|
-
[key: string]: {
|
|
60
|
-
found: boolean;
|
|
61
|
-
description: string;
|
|
62
|
-
};
|
|
63
|
-
};
|
|
64
|
-
taskSpecific: {
|
|
65
|
-
[key: string]: {
|
|
66
|
-
valid: boolean;
|
|
67
|
-
description: string;
|
|
68
|
-
};
|
|
69
|
-
};
|
|
70
|
-
};
|
|
71
|
-
/** Plan type detected */
|
|
72
|
-
detectedType: 'feature' | 'bugfix' | 'analysis' | 'mixed';
|
|
73
|
-
/** Confidence in plan quality (0-100) */
|
|
74
|
-
confidence: number;
|
|
75
|
-
/** Recommended improvements */
|
|
76
|
-
improvements: string[];
|
|
77
|
-
}
|
|
78
|
-
/**
|
|
79
|
-
* Validate a plan against comprehensive criteria
|
|
80
|
-
*/
|
|
81
|
-
export declare function validatePlan(todos: Todo[], planType?: 'feature' | 'bugfix' | 'analysis', customCriteria?: Partial<PlanValidationCriteria>): PlanValidationResult;
|
|
82
|
-
/**
|
|
83
|
-
* Quick plan quality check
|
|
84
|
-
*/
|
|
85
|
-
export declare function quickPlanCheck(todos: Todo[]): {
|
|
86
|
-
isGood: boolean;
|
|
87
|
-
score: number;
|
|
88
|
-
topIssue?: string;
|
|
89
|
-
};
|
|
90
|
-
/**
|
|
91
|
-
* Get recommended criteria for task type
|
|
92
|
-
*/
|
|
93
|
-
export declare function getRecommendedCriteria(planType: 'feature' | 'bugfix' | 'analysis'): PlanValidationCriteria;
|
|
94
|
-
//# sourceMappingURL=planValidator.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"planValidator.d.ts","sourceRoot":"","sources":["../../../../src/agents/codemie-code/validators/planValidator.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AAEH,OAAO,KAAK,EAAE,IAAI,EAAE,MAAM,aAAa,CAAC;AACxC,OAAO,EAAoB,KAAK,wBAAwB,EAAE,MAAM,2BAA2B,CAAC;AAE5F;;GAEG;AACH,MAAM,WAAW,sBAAsB;IACrC,uCAAuC;IACvC,QAAQ,EAAE,MAAM,CAAC;IAEjB,sCAAsC;IACtC,QAAQ,EAAE,MAAM,CAAC;IAEjB,oCAAoC;IACpC,eAAe,EAAE,MAAM,CAAC;IAExB,6BAA6B;IAC7B,gBAAgB,EAAE;QAChB,4CAA4C;QAC5C,SAAS,EAAE,OAAO,CAAC;QAEnB,wCAAwC;QACxC,cAAc,EAAE,OAAO,CAAC;QAExB,8CAA8C;QAC9C,OAAO,EAAE,OAAO,CAAC;QAEjB,kDAAkD;QAClD,UAAU,EAAE,OAAO,CAAC;KACrB,CAAC;IAEF,iCAAiC;IACjC,YAAY,EAAE;QACZ,kDAAkD;QAClD,kBAAkB,EAAE,OAAO,CAAC;QAE5B,4BAA4B;QAC5B,WAAW,EAAE,OAAO,CAAC;QAErB,0CAA0C;QAC1C,kBAAkB,EAAE,OAAO,CAAC;KAC7B,CAAC;CACH;AAED;;GAEG;AACH,MAAM,WAAW,oBAAqB,SAAQ,wBAAwB;IACpE,sCAAsC;IACtC,aAAa,EAAE,OAAO,CAAC;IAEvB,mCAAmC;IACnC,kBAAkB,EAAE;QAClB,SAAS,EAAE;YAAE,KAAK,EAAE,OAAO,CAAC;YAAC,MAAM,EAAE,MAAM,CAAC;YAAC,QAAQ,EAAE,MAAM,CAAA;SAAE,CAAC;QAChE,YAAY,EAAE;YAAE,KAAK,EAAE,OAAO,CAAC;YAAC,MAAM,EAAE,MAAM,CAAC;YAAC,QAAQ,EAAE,MAAM,CAAA;SAAE,CAAC;QACnE,QAAQ,EAAE;YAAE,CAAC,GAAG,EAAE,MAAM,GAAG;gBAAE,KAAK,EAAE,OAAO,CAAC;gBAAC,WAAW,EAAE,MAAM,CAAA;aAAE,CAAA;SAAE,CAAC;QACrE,YAAY,EAAE;YAAE,CAAC,GAAG,EAAE,MAAM,GAAG;gBAAE,KAAK,EAAE,OAAO,CAAC;gBAAC,WAAW,EAAE,MAAM,CAAA;aAAE,CAAA;SAAE,CAAC;KAC1E,CAAC;IAEF,yBAAyB;IACzB,YAAY,EAAE,SAAS,GAAG,QAAQ,GAAG,UAAU,GAAG,OAAO,CAAC;IAE1D,yCAAyC;IACzC,UAAU,EAAE,MAAM,CAAC;IAEnB,+BAA+B;IAC/B,YAAY,EAAE,MAAM,EAAE,CAAC;CACxB;AAwDD;;GAEG;AACH,wBAAgB,YAAY,CAC1B,KAAK,EAAE,IAAI,EAAE,EACb,QAAQ,GAAE,SAAS,GAAG,QAAQ,GAAG,UAAsB,EACvD,cAAc,CAAC,EAAE,OAAO,CAAC,sBAAsB,CAAC,GAC/C,oBAAoB,CAsCtB;AA+MD;;GAEG;AACH,wBAAgB,cAAc,CAAC,KAAK,EAAE,IAAI,EAAE,GAAG;IAC7C,MAAM,EAAE,OAAO,CAAC;IAChB,KAAK,EAAE,MAAM,CAAC;IACd,QAAQ,CAAC,EAAE,MAAM,CAAC;CACnB,CAYA;AAED;;GAEG;AACH,wBAAgB,sBAAsB,CAAC,QAAQ,EAAE,SAAS,GAAG,QAAQ,GAAG,UAAU,GAAG,sBAAsB,CAE1G"}
|
|
@@ -1,281 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Plan Validator
|
|
3
|
-
*
|
|
4
|
-
* Validates the quality and completeness of generated plans
|
|
5
|
-
* Ensures plans follow best practices for structured execution
|
|
6
|
-
*/
|
|
7
|
-
import { validateTodoList } from '../utils/todoValidator.js';
|
|
8
|
-
/**
|
|
9
|
-
* Default validation criteria for different plan types
|
|
10
|
-
*/
|
|
11
|
-
const DEFAULT_CRITERIA = {
|
|
12
|
-
feature: {
|
|
13
|
-
minSteps: 3,
|
|
14
|
-
maxSteps: 8,
|
|
15
|
-
minQualityScore: 70,
|
|
16
|
-
requiredPatterns: {
|
|
17
|
-
discovery: true,
|
|
18
|
-
implementation: true,
|
|
19
|
-
testing: true,
|
|
20
|
-
completion: true
|
|
21
|
-
},
|
|
22
|
-
taskSpecific: {
|
|
23
|
-
specificReferences: true,
|
|
24
|
-
actionVerbs: true,
|
|
25
|
-
completionCriteria: true
|
|
26
|
-
}
|
|
27
|
-
},
|
|
28
|
-
bugfix: {
|
|
29
|
-
minSteps: 3,
|
|
30
|
-
maxSteps: 6,
|
|
31
|
-
minQualityScore: 75,
|
|
32
|
-
requiredPatterns: {
|
|
33
|
-
discovery: true,
|
|
34
|
-
implementation: true,
|
|
35
|
-
testing: true,
|
|
36
|
-
completion: false
|
|
37
|
-
},
|
|
38
|
-
taskSpecific: {
|
|
39
|
-
specificReferences: true,
|
|
40
|
-
actionVerbs: true,
|
|
41
|
-
completionCriteria: true
|
|
42
|
-
}
|
|
43
|
-
},
|
|
44
|
-
analysis: {
|
|
45
|
-
minSteps: 3,
|
|
46
|
-
maxSteps: 10,
|
|
47
|
-
minQualityScore: 65,
|
|
48
|
-
requiredPatterns: {
|
|
49
|
-
discovery: true,
|
|
50
|
-
implementation: false,
|
|
51
|
-
testing: false,
|
|
52
|
-
completion: true
|
|
53
|
-
},
|
|
54
|
-
taskSpecific: {
|
|
55
|
-
specificReferences: false,
|
|
56
|
-
actionVerbs: true,
|
|
57
|
-
completionCriteria: false
|
|
58
|
-
}
|
|
59
|
-
}
|
|
60
|
-
};
|
|
61
|
-
/**
|
|
62
|
-
* Validate a plan against comprehensive criteria
|
|
63
|
-
*/
|
|
64
|
-
export function validatePlan(todos, planType = 'feature', customCriteria) {
|
|
65
|
-
// Get base validation from todo validator
|
|
66
|
-
const baseValidation = validateTodoList(todos);
|
|
67
|
-
// Get criteria for plan type
|
|
68
|
-
const criteria = {
|
|
69
|
-
...DEFAULT_CRITERIA[planType],
|
|
70
|
-
...customCriteria
|
|
71
|
-
};
|
|
72
|
-
// Detect actual plan type
|
|
73
|
-
const detectedType = detectPlanType(todos);
|
|
74
|
-
// Assess criteria
|
|
75
|
-
const criteriaAssessment = assessCriteria(todos, criteria);
|
|
76
|
-
// Calculate confidence
|
|
77
|
-
const confidence = calculateConfidence(baseValidation, criteriaAssessment);
|
|
78
|
-
// Check if all criteria are met
|
|
79
|
-
const meetsCriteria = baseValidation.isValid &&
|
|
80
|
-
criteriaAssessment.stepCount.valid &&
|
|
81
|
-
criteriaAssessment.qualityScore.valid &&
|
|
82
|
-
Object.values(criteriaAssessment.patterns).every(p => p.found) &&
|
|
83
|
-
Object.values(criteriaAssessment.taskSpecific).every(t => t.valid);
|
|
84
|
-
// Generate improvements
|
|
85
|
-
const improvements = generateImprovements(baseValidation, criteriaAssessment, criteria);
|
|
86
|
-
return {
|
|
87
|
-
...baseValidation,
|
|
88
|
-
meetsCriteria,
|
|
89
|
-
criteriaAssessment,
|
|
90
|
-
detectedType,
|
|
91
|
-
confidence,
|
|
92
|
-
improvements
|
|
93
|
-
};
|
|
94
|
-
}
|
|
95
|
-
/**
|
|
96
|
-
* Detect plan type from todo content
|
|
97
|
-
*/
|
|
98
|
-
function detectPlanType(todos) {
|
|
99
|
-
const allContent = todos.map(t => t.content.toLowerCase()).join(' ');
|
|
100
|
-
let featureScore = 0;
|
|
101
|
-
let bugfixScore = 0;
|
|
102
|
-
let analysisScore = 0;
|
|
103
|
-
// Feature indicators
|
|
104
|
-
const featureWords = ['create', 'add', 'implement', 'build', 'develop', 'design', 'new'];
|
|
105
|
-
featureScore = featureWords.filter(word => allContent.includes(word)).length;
|
|
106
|
-
// Bugfix indicators
|
|
107
|
-
const bugfixWords = ['fix', 'repair', 'resolve', 'debug', 'issue', 'error', 'bug'];
|
|
108
|
-
bugfixScore = bugfixWords.filter(word => allContent.includes(word)).length;
|
|
109
|
-
// Analysis indicators
|
|
110
|
-
const analysisWords = ['analyze', 'review', 'understand', 'explore', 'examine', 'assess'];
|
|
111
|
-
analysisScore = analysisWords.filter(word => allContent.includes(word)).length;
|
|
112
|
-
// Determine type
|
|
113
|
-
if (featureScore > bugfixScore && featureScore > analysisScore)
|
|
114
|
-
return 'feature';
|
|
115
|
-
if (bugfixScore > featureScore && bugfixScore > analysisScore)
|
|
116
|
-
return 'bugfix';
|
|
117
|
-
if (analysisScore > featureScore && analysisScore > bugfixScore)
|
|
118
|
-
return 'analysis';
|
|
119
|
-
return 'mixed';
|
|
120
|
-
}
|
|
121
|
-
/**
|
|
122
|
-
* Assess plan against specific criteria
|
|
123
|
-
*/
|
|
124
|
-
function assessCriteria(todos, criteria) {
|
|
125
|
-
const allContent = todos.map(t => t.content.toLowerCase()).join(' ');
|
|
126
|
-
// Step count assessment
|
|
127
|
-
const stepCount = {
|
|
128
|
-
valid: todos.length >= criteria.minSteps && todos.length <= criteria.maxSteps,
|
|
129
|
-
actual: todos.length,
|
|
130
|
-
required: `${criteria.minSteps}-${criteria.maxSteps}`
|
|
131
|
-
};
|
|
132
|
-
// Quality score assessment (from base validation)
|
|
133
|
-
const baseValidation = validateTodoList(todos);
|
|
134
|
-
const qualityScore = {
|
|
135
|
-
valid: baseValidation.overallQuality >= criteria.minQualityScore,
|
|
136
|
-
actual: baseValidation.overallQuality,
|
|
137
|
-
required: criteria.minQualityScore
|
|
138
|
-
};
|
|
139
|
-
// Pattern assessment
|
|
140
|
-
const patterns = {};
|
|
141
|
-
if (criteria.requiredPatterns.discovery) {
|
|
142
|
-
const discoveryWords = ['read', 'analyze', 'explore', 'understand', 'examine', 'review', 'investigate'];
|
|
143
|
-
patterns.discovery = {
|
|
144
|
-
found: discoveryWords.some(word => allContent.includes(word)),
|
|
145
|
-
description: 'Plan should include discovery/analysis steps'
|
|
146
|
-
};
|
|
147
|
-
}
|
|
148
|
-
if (criteria.requiredPatterns.implementation) {
|
|
149
|
-
const implWords = ['create', 'write', 'implement', 'build', 'modify', 'update', 'add', 'develop'];
|
|
150
|
-
patterns.implementation = {
|
|
151
|
-
found: implWords.some(word => allContent.includes(word)),
|
|
152
|
-
description: 'Plan should include implementation steps'
|
|
153
|
-
};
|
|
154
|
-
}
|
|
155
|
-
if (criteria.requiredPatterns.testing) {
|
|
156
|
-
const testWords = ['test', 'verify', 'validate', 'check', 'run'];
|
|
157
|
-
patterns.testing = {
|
|
158
|
-
found: testWords.some(word => allContent.includes(word)),
|
|
159
|
-
description: 'Plan should include testing/verification steps'
|
|
160
|
-
};
|
|
161
|
-
}
|
|
162
|
-
if (criteria.requiredPatterns.completion) {
|
|
163
|
-
const compWords = ['commit', 'document', 'summary', 'complete', 'finalize'];
|
|
164
|
-
patterns.completion = {
|
|
165
|
-
found: compWords.some(word => allContent.includes(word)),
|
|
166
|
-
description: 'Plan should include completion/documentation steps'
|
|
167
|
-
};
|
|
168
|
-
}
|
|
169
|
-
// Task-specific assessment
|
|
170
|
-
const taskSpecific = {};
|
|
171
|
-
if (criteria.taskSpecific.specificReferences) {
|
|
172
|
-
const hasFileRefs = todos.some(t => /\.(ts|js|py|md|json|yml|yaml|txt)|src\/|\/.*\/|[A-Z][a-zA-Z]*\./.test(t.content));
|
|
173
|
-
taskSpecific.specificReferences = {
|
|
174
|
-
valid: hasFileRefs,
|
|
175
|
-
description: 'Steps should reference specific files, functions, or components'
|
|
176
|
-
};
|
|
177
|
-
}
|
|
178
|
-
if (criteria.taskSpecific.actionVerbs) {
|
|
179
|
-
const actionVerbs = ['read', 'write', 'create', 'update', 'delete', 'fix', 'implement', 'test', 'run', 'build'];
|
|
180
|
-
const hasActionVerbs = todos.some(t => actionVerbs.some(verb => t.content.toLowerCase().startsWith(verb)));
|
|
181
|
-
taskSpecific.actionVerbs = {
|
|
182
|
-
valid: hasActionVerbs,
|
|
183
|
-
description: 'Steps should start with action verbs'
|
|
184
|
-
};
|
|
185
|
-
}
|
|
186
|
-
if (criteria.taskSpecific.completionCriteria) {
|
|
187
|
-
const hasCriteria = todos.some(t => t.content.length > 20 && // Reasonable detail
|
|
188
|
-
!t.content.toLowerCase().includes('handle') && // Avoid vague language
|
|
189
|
-
!t.content.toLowerCase().includes('deal with'));
|
|
190
|
-
taskSpecific.completionCriteria = {
|
|
191
|
-
valid: hasCriteria,
|
|
192
|
-
description: 'Steps should have clear, specific completion criteria'
|
|
193
|
-
};
|
|
194
|
-
}
|
|
195
|
-
return {
|
|
196
|
-
stepCount,
|
|
197
|
-
qualityScore,
|
|
198
|
-
patterns,
|
|
199
|
-
taskSpecific
|
|
200
|
-
};
|
|
201
|
-
}
|
|
202
|
-
/**
|
|
203
|
-
* Calculate confidence in plan quality
|
|
204
|
-
*/
|
|
205
|
-
function calculateConfidence(baseValidation, criteriaAssessment) {
|
|
206
|
-
let confidence = baseValidation.overallQuality;
|
|
207
|
-
// Boost confidence for meeting criteria
|
|
208
|
-
if (criteriaAssessment.stepCount.valid)
|
|
209
|
-
confidence += 5;
|
|
210
|
-
if (criteriaAssessment.qualityScore.valid)
|
|
211
|
-
confidence += 10;
|
|
212
|
-
// Boost for patterns
|
|
213
|
-
const patternScore = Object.values(criteriaAssessment.patterns).filter((p) => p.found).length;
|
|
214
|
-
const totalPatterns = Object.keys(criteriaAssessment.patterns).length;
|
|
215
|
-
if (totalPatterns > 0) {
|
|
216
|
-
confidence += (patternScore / totalPatterns) * 15;
|
|
217
|
-
}
|
|
218
|
-
// Boost for task-specific criteria
|
|
219
|
-
const taskScore = Object.values(criteriaAssessment.taskSpecific).filter((t) => t.valid).length;
|
|
220
|
-
const totalTaskCriteria = Object.keys(criteriaAssessment.taskSpecific).length;
|
|
221
|
-
if (totalTaskCriteria > 0) {
|
|
222
|
-
confidence += (taskScore / totalTaskCriteria) * 10;
|
|
223
|
-
}
|
|
224
|
-
return Math.min(100, Math.max(0, Math.round(confidence)));
|
|
225
|
-
}
|
|
226
|
-
/**
|
|
227
|
-
* Generate specific improvements based on validation results
|
|
228
|
-
*/
|
|
229
|
-
function generateImprovements(baseValidation, criteriaAssessment, criteria) {
|
|
230
|
-
const improvements = [];
|
|
231
|
-
// Step count improvements
|
|
232
|
-
if (!criteriaAssessment.stepCount.valid) {
|
|
233
|
-
if (criteriaAssessment.stepCount.actual < criteria.minSteps) {
|
|
234
|
-
improvements.push(`Add more steps (need ${criteria.minSteps - criteriaAssessment.stepCount.actual} more)`);
|
|
235
|
-
}
|
|
236
|
-
else {
|
|
237
|
-
improvements.push(`Reduce steps to ${criteria.maxSteps} or fewer - consider breaking into multiple tasks`);
|
|
238
|
-
}
|
|
239
|
-
}
|
|
240
|
-
// Quality improvements
|
|
241
|
-
if (!criteriaAssessment.qualityScore.valid) {
|
|
242
|
-
improvements.push('Improve step specificity and clarity - avoid vague language');
|
|
243
|
-
}
|
|
244
|
-
// Pattern improvements
|
|
245
|
-
Object.entries(criteriaAssessment.patterns).forEach(([, result]) => {
|
|
246
|
-
if (!result.found) {
|
|
247
|
-
improvements.push(result.description);
|
|
248
|
-
}
|
|
249
|
-
});
|
|
250
|
-
// Task-specific improvements
|
|
251
|
-
Object.entries(criteriaAssessment.taskSpecific).forEach(([, result]) => {
|
|
252
|
-
if (!result.valid) {
|
|
253
|
-
improvements.push(result.description);
|
|
254
|
-
}
|
|
255
|
-
});
|
|
256
|
-
// Add base validation suggestions
|
|
257
|
-
improvements.push(...baseValidation.suggestions.slice(0, 3));
|
|
258
|
-
// Remove duplicates and limit to top recommendations
|
|
259
|
-
return [...new Set(improvements)].slice(0, 8);
|
|
260
|
-
}
|
|
261
|
-
/**
|
|
262
|
-
* Quick plan quality check
|
|
263
|
-
*/
|
|
264
|
-
export function quickPlanCheck(todos) {
|
|
265
|
-
if (todos.length === 0) {
|
|
266
|
-
return { isGood: false, score: 0, topIssue: 'No todos provided' };
|
|
267
|
-
}
|
|
268
|
-
const validation = validatePlan(todos);
|
|
269
|
-
return {
|
|
270
|
-
isGood: validation.confidence >= 70,
|
|
271
|
-
score: validation.confidence,
|
|
272
|
-
topIssue: validation.improvements[0]
|
|
273
|
-
};
|
|
274
|
-
}
|
|
275
|
-
/**
|
|
276
|
-
* Get recommended criteria for task type
|
|
277
|
-
*/
|
|
278
|
-
export function getRecommendedCriteria(planType) {
|
|
279
|
-
return { ...DEFAULT_CRITERIA[planType] };
|
|
280
|
-
}
|
|
281
|
-
//# sourceMappingURL=planValidator.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"planValidator.js","sourceRoot":"","sources":["../../../../src/agents/codemie-code/validators/planValidator.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AAGH,OAAO,EAAE,gBAAgB,EAAiC,MAAM,2BAA2B,CAAC;AAoE5F;;GAEG;AACH,MAAM,gBAAgB,GAA2C;IAC/D,OAAO,EAAE;QACP,QAAQ,EAAE,CAAC;QACX,QAAQ,EAAE,CAAC;QACX,eAAe,EAAE,EAAE;QACnB,gBAAgB,EAAE;YAChB,SAAS,EAAE,IAAI;YACf,cAAc,EAAE,IAAI;YACpB,OAAO,EAAE,IAAI;YACb,UAAU,EAAE,IAAI;SACjB;QACD,YAAY,EAAE;YACZ,kBAAkB,EAAE,IAAI;YACxB,WAAW,EAAE,IAAI;YACjB,kBAAkB,EAAE,IAAI;SACzB;KACF;IACD,MAAM,EAAE;QACN,QAAQ,EAAE,CAAC;QACX,QAAQ,EAAE,CAAC;QACX,eAAe,EAAE,EAAE;QACnB,gBAAgB,EAAE;YAChB,SAAS,EAAE,IAAI;YACf,cAAc,EAAE,IAAI;YACpB,OAAO,EAAE,IAAI;YACb,UAAU,EAAE,KAAK;SAClB;QACD,YAAY,EAAE;YACZ,kBAAkB,EAAE,IAAI;YACxB,WAAW,EAAE,IAAI;YACjB,kBAAkB,EAAE,IAAI;SACzB;KACF;IACD,QAAQ,EAAE;QACR,QAAQ,EAAE,CAAC;QACX,QAAQ,EAAE,EAAE;QACZ,eAAe,EAAE,EAAE;QACnB,gBAAgB,EA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AC,EAAE,MAAM,CAAgB,EAAE,EAAE;QACpF,IAAI,CAAC,MAAM,CAAC,KAAK,EAAE,CAAC;YAClB,YAAY,CAAC,IAAI,CAAC,MAAM,CAAC,WAAW,CAAC,CAAC;QACxC,CAAC;IACH,CAAC,CAAC,CAAC;IAEH,kCAAkC;IAClC,YAAY,CAAC,IAAI,CAAC,GAAG,cAAc,CAAC,WAAW,CAAC,KAAK,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,CAAC;IAE7D,qDAAqD;IACrD,OAAO,CAAC,GAAG,IAAI,GAAG,CAAC,YAAY,CAAC,CAAC,CAAC,KAAK,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC;AAChD,CAAC;AAED;;GAEG;AACH,MAAM,UAAU,cAAc,CAAC,KAAa;IAK1C,IAAI,KAAK,CAAC,MAAM,KAAK,CAAC,EAAE,CAAC;QACvB,OAAO,EAAE,MAAM,EAAE,KAAK,EAAE,KAAK,EAAE,CAAC,EAAE,QAAQ,EAAE,mBAAmB,EAAE,CAAC;IACpE,CAAC;IAED,MAAM,UAAU,GAAG,YAAY,CAAC,KAAK,CAAC,CAAC;IAEvC,OAAO;QACL,MAAM,EAAE,UAAU,CAAC,UAAU,IAAI,EAAE;QACnC,KAAK,EAAE,UAAU,CAAC,UAAU;QAC5B,QAAQ,EAAE,UAAU,CAAC,YAAY,CAAC,CAAC,CAAC;KACrC,CAAC;AACJ,CAAC;AAED;;GAEG;AACH,MAAM,UAAU,sBAAsB,CAAC,QAA2C;IAChF,OAAO,EAAE,GAAG,gBAAgB,CAAC,QAAQ,CAAC,EAAE,CAAC;AAC3C,CAAC"}
|
|
@@ -1,98 +0,0 @@
|
|
|
1
|
-
{
|
|
2
|
-
"description": "CodeMie session tracking hooks - unified command handler",
|
|
3
|
-
"hooks": {
|
|
4
|
-
"SessionStart": [
|
|
5
|
-
{
|
|
6
|
-
"hooks": [
|
|
7
|
-
{
|
|
8
|
-
"type": "command",
|
|
9
|
-
"command": "codemie hook",
|
|
10
|
-
"timeout": 5
|
|
11
|
-
},
|
|
12
|
-
{
|
|
13
|
-
"type": "command",
|
|
14
|
-
"command": "powershell -ExecutionPolicy Bypass -NonInteractive -File \"%USERPROFILE%\\.codemie\\claude-plugin\\sounds\\play-random-sound.ps1\" \"%USERPROFILE%\\.codemie\\sounds\\SessionStart\""
|
|
15
|
-
}
|
|
16
|
-
]
|
|
17
|
-
}
|
|
18
|
-
],
|
|
19
|
-
"SessionEnd": [
|
|
20
|
-
{
|
|
21
|
-
"hooks": [
|
|
22
|
-
{
|
|
23
|
-
"type": "command",
|
|
24
|
-
"command": "codemie hook",
|
|
25
|
-
"timeout": 10
|
|
26
|
-
}
|
|
27
|
-
]
|
|
28
|
-
}
|
|
29
|
-
],
|
|
30
|
-
"PermissionRequest": [
|
|
31
|
-
{
|
|
32
|
-
"hooks": [
|
|
33
|
-
{
|
|
34
|
-
"type": "command",
|
|
35
|
-
"command": "codemie hook",
|
|
36
|
-
"timeout": 2
|
|
37
|
-
},
|
|
38
|
-
{
|
|
39
|
-
"type": "command",
|
|
40
|
-
"command": "powershell -ExecutionPolicy Bypass -NonInteractive -File \"%USERPROFILE%\\.codemie\\claude-plugin\\sounds\\play-random-sound.ps1\" \"%USERPROFILE%\\.codemie\\sounds\\PermissionRequest\""
|
|
41
|
-
}
|
|
42
|
-
]
|
|
43
|
-
}
|
|
44
|
-
],
|
|
45
|
-
"SubagentStop": [
|
|
46
|
-
{
|
|
47
|
-
"hooks": [
|
|
48
|
-
{
|
|
49
|
-
"type": "command",
|
|
50
|
-
"command": "codemie hook",
|
|
51
|
-
"timeout": 3
|
|
52
|
-
}
|
|
53
|
-
]
|
|
54
|
-
}
|
|
55
|
-
],
|
|
56
|
-
"Stop": [
|
|
57
|
-
{
|
|
58
|
-
"hooks": [
|
|
59
|
-
{
|
|
60
|
-
"type": "command",
|
|
61
|
-
"command": "codemie hook",
|
|
62
|
-
"timeout": 2
|
|
63
|
-
},
|
|
64
|
-
{
|
|
65
|
-
"type": "command",
|
|
66
|
-
"command": "powershell -ExecutionPolicy Bypass -NonInteractive -File \"%USERPROFILE%\\.codemie\\claude-plugin\\sounds\\play-random-sound.ps1\" \"%USERPROFILE%\\.codemie\\sounds\\Stop\""
|
|
67
|
-
}
|
|
68
|
-
]
|
|
69
|
-
}
|
|
70
|
-
],
|
|
71
|
-
"UserPromptSubmit": [
|
|
72
|
-
{
|
|
73
|
-
"hooks": [
|
|
74
|
-
{
|
|
75
|
-
"type": "command",
|
|
76
|
-
"command": "codemie hook",
|
|
77
|
-
"timeout": 2
|
|
78
|
-
},
|
|
79
|
-
{
|
|
80
|
-
"type": "command",
|
|
81
|
-
"command": "powershell -ExecutionPolicy Bypass -NonInteractive -File \"%USERPROFILE%\\.codemie\\claude-plugin\\sounds\\play-random-sound.ps1\" \"%USERPROFILE%\\.codemie\\sounds\\UserPromptSubmit\""
|
|
82
|
-
}
|
|
83
|
-
]
|
|
84
|
-
}
|
|
85
|
-
],
|
|
86
|
-
"PreCompact": [
|
|
87
|
-
{
|
|
88
|
-
"hooks": [
|
|
89
|
-
{
|
|
90
|
-
"type": "command",
|
|
91
|
-
"command": "codemie hook",
|
|
92
|
-
"timeout": 2
|
|
93
|
-
}
|
|
94
|
-
]
|
|
95
|
-
}
|
|
96
|
-
]
|
|
97
|
-
}
|
|
98
|
-
}
|
|
@@ -1,112 +0,0 @@
|
|
|
1
|
-
# play-random-sound.ps1
|
|
2
|
-
# Plays a random WAV or MP3 file from the specified directory (Windows)
|
|
3
|
-
# Usage: .\play-random-sound.ps1 <directory>
|
|
4
|
-
|
|
5
|
-
param(
|
|
6
|
-
[Parameter(Mandatory=$true, Position=0)]
|
|
7
|
-
[string]$Directory
|
|
8
|
-
)
|
|
9
|
-
|
|
10
|
-
# Set error action preference to stop on errors
|
|
11
|
-
$ErrorActionPreference = "Stop"
|
|
12
|
-
|
|
13
|
-
# Expand environment variables in the path (e.g., %USERPROFILE%)
|
|
14
|
-
$SoundDir = [System.Environment]::ExpandEnvironmentVariables($Directory)
|
|
15
|
-
|
|
16
|
-
# Check if directory exists - exit silently if not found
|
|
17
|
-
if (-not (Test-Path -Path $SoundDir -PathType Container)) {
|
|
18
|
-
exit 0
|
|
19
|
-
}
|
|
20
|
-
|
|
21
|
-
# Find all audio files (WAV and MP3)
|
|
22
|
-
$AudioFiles = Get-ChildItem -Path $SoundDir -File -Include *.wav,*.mp3 -ErrorAction SilentlyContinue
|
|
23
|
-
|
|
24
|
-
# Check if any audio files were found
|
|
25
|
-
if ($AudioFiles.Count -eq 0) {
|
|
26
|
-
exit 0
|
|
27
|
-
}
|
|
28
|
-
|
|
29
|
-
# Select a random file
|
|
30
|
-
$SelectedFile = $AudioFiles | Get-Random
|
|
31
|
-
|
|
32
|
-
# Function to play audio using mpg123 (if available)
|
|
33
|
-
function Play-WithMpg123 {
|
|
34
|
-
param([string]$FilePath)
|
|
35
|
-
|
|
36
|
-
try {
|
|
37
|
-
$mpg123 = Get-Command mpg123 -ErrorAction Stop
|
|
38
|
-
Start-Process -FilePath $mpg123.Source -ArgumentList "-q", "`"$FilePath`"" -NoNewWindow -Wait:$false
|
|
39
|
-
return $true
|
|
40
|
-
} catch {
|
|
41
|
-
return $false
|
|
42
|
-
}
|
|
43
|
-
}
|
|
44
|
-
|
|
45
|
-
# Function to play audio using Windows Media Player COM
|
|
46
|
-
function Play-WithWMP {
|
|
47
|
-
param([string]$FilePath)
|
|
48
|
-
|
|
49
|
-
try {
|
|
50
|
-
$wmp = New-Object -ComObject WMPlayer.OCX
|
|
51
|
-
$wmp.URL = $FilePath
|
|
52
|
-
$wmp.controls.play()
|
|
53
|
-
|
|
54
|
-
# Start playback in background (don't wait for completion)
|
|
55
|
-
Start-Sleep -Milliseconds 500
|
|
56
|
-
return $true
|
|
57
|
-
} catch {
|
|
58
|
-
return $false
|
|
59
|
-
}
|
|
60
|
-
}
|
|
61
|
-
|
|
62
|
-
# Function to play audio using .NET SoundPlayer (WAV only)
|
|
63
|
-
function Play-WithSoundPlayer {
|
|
64
|
-
param([string]$FilePath)
|
|
65
|
-
|
|
66
|
-
# SoundPlayer only supports WAV files
|
|
67
|
-
if ($FilePath -notmatch '\.wav$') {
|
|
68
|
-
return $false
|
|
69
|
-
}
|
|
70
|
-
|
|
71
|
-
try {
|
|
72
|
-
Add-Type -AssemblyName System.Windows.Forms
|
|
73
|
-
$player = New-Object System.Media.SoundPlayer
|
|
74
|
-
$player.SoundLocation = $FilePath
|
|
75
|
-
$player.PlaySync() # Play asynchronously
|
|
76
|
-
|
|
77
|
-
# Start in background job to avoid blocking
|
|
78
|
-
Start-Job -ScriptBlock {
|
|
79
|
-
param($path)
|
|
80
|
-
Add-Type -AssemblyName System.Windows.Forms
|
|
81
|
-
$p = New-Object System.Media.SoundPlayer
|
|
82
|
-
$p.SoundLocation = $path
|
|
83
|
-
$p.PlaySync()
|
|
84
|
-
} -ArgumentList $FilePath | Out-Null
|
|
85
|
-
|
|
86
|
-
return $true
|
|
87
|
-
} catch {
|
|
88
|
-
return $false
|
|
89
|
-
}
|
|
90
|
-
}
|
|
91
|
-
|
|
92
|
-
# Try audio players in order of preference
|
|
93
|
-
$played = $false
|
|
94
|
-
|
|
95
|
-
# 1. Try mpg123 (best option, cross-platform)
|
|
96
|
-
if (Play-WithMpg123 -FilePath $SelectedFile.FullName) {
|
|
97
|
-
$played = $true
|
|
98
|
-
}
|
|
99
|
-
# 2. Try Windows Media Player COM
|
|
100
|
-
elseif (Play-WithWMP -FilePath $SelectedFile.FullName) {
|
|
101
|
-
$played = $true
|
|
102
|
-
}
|
|
103
|
-
# 3. Try .NET SoundPlayer (WAV only)
|
|
104
|
-
elseif (Play-WithSoundPlayer -FilePath $SelectedFile.FullName) {
|
|
105
|
-
$played = $true
|
|
106
|
-
}
|
|
107
|
-
|
|
108
|
-
if (-not $played) {
|
|
109
|
-
exit 0
|
|
110
|
-
}
|
|
111
|
-
|
|
112
|
-
exit 0
|
|
@@ -1,58 +0,0 @@
|
|
|
1
|
-
#!/bin/bash
|
|
2
|
-
|
|
3
|
-
# play-random-sound.sh
|
|
4
|
-
# Plays a random WAV file from the specified directory
|
|
5
|
-
# Usage: ./play-random-sound.sh <directory>
|
|
6
|
-
|
|
7
|
-
set -e
|
|
8
|
-
|
|
9
|
-
# Check if directory argument is provided
|
|
10
|
-
if [ $# -eq 0 ]; then
|
|
11
|
-
echo "Usage: $0 <directory>" >&2
|
|
12
|
-
echo "Example: $0 ~/.codemie/claude-plugin/sounds/acolyte" >&2
|
|
13
|
-
exit 0
|
|
14
|
-
fi
|
|
15
|
-
|
|
16
|
-
# Expand tilde in the directory path
|
|
17
|
-
SOUND_DIR="${1/#\~/$HOME}"
|
|
18
|
-
|
|
19
|
-
# Check if directory exists - exit silently if not found
|
|
20
|
-
if [ ! -d "$SOUND_DIR" ]; then
|
|
21
|
-
exit 0
|
|
22
|
-
fi
|
|
23
|
-
|
|
24
|
-
# Find all audio files and store in array (compatible way)
|
|
25
|
-
WAV_FILES=()
|
|
26
|
-
while IFS= read -r -d '' file; do
|
|
27
|
-
WAV_FILES+=("$file")
|
|
28
|
-
done < <(find "$SOUND_DIR" -maxdepth 1 -type f \( -iname "*.wav" -o -iname "*.mp3" \) -print0 2>/dev/null)
|
|
29
|
-
|
|
30
|
-
# Check if any audio files were found
|
|
31
|
-
if [ ${#WAV_FILES[@]} -eq 0 ]; then
|
|
32
|
-
echo "Error: No WAV or MP3 files found in $SOUND_DIR" >&2
|
|
33
|
-
exit 0
|
|
34
|
-
fi
|
|
35
|
-
|
|
36
|
-
# Select a random file
|
|
37
|
-
RANDOM_INDEX=$((RANDOM % ${#WAV_FILES[@]}))
|
|
38
|
-
SELECTED_FILE="${WAV_FILES[$RANDOM_INDEX]}"
|
|
39
|
-
|
|
40
|
-
# Detect platform and use appropriate audio player
|
|
41
|
-
if command -v afplay &> /dev/null; then
|
|
42
|
-
# macOS
|
|
43
|
-
afplay "$SELECTED_FILE" &
|
|
44
|
-
elif command -v aplay &> /dev/null; then
|
|
45
|
-
# Linux with ALSA
|
|
46
|
-
aplay -q "$SELECTED_FILE" &
|
|
47
|
-
elif command -v paplay &> /dev/null; then
|
|
48
|
-
# Linux with PulseAudio
|
|
49
|
-
paplay "$SELECTED_FILE" &
|
|
50
|
-
elif command -v mpg123 &> /dev/null; then
|
|
51
|
-
# Cross-platform mpg123
|
|
52
|
-
mpg123 -q "$SELECTED_FILE" &
|
|
53
|
-
else
|
|
54
|
-
echo "Error: No audio player found. Install afplay (macOS), aplay, paplay, or mpg123" >&2
|
|
55
|
-
exit 0
|
|
56
|
-
fi
|
|
57
|
-
|
|
58
|
-
exit 0
|