oh-my-opencode 5.0.0-beta.1 → 5.0.0-beta.10
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/.agents/command/publish.md +44 -16
- package/.agents/skills/publish/SKILL.md +44 -16
- package/.agents/skills/work-with-pr/SKILL.md +37 -23
- package/.opencode/command/publish.md +44 -16
- package/.opencode/skills/work-with-pr/SKILL.md +37 -23
- package/README.md +12 -1
- package/dist/agents/atlas/agent.d.ts +0 -1
- package/dist/agents/sisyphus/grok-4.d.ts +20 -0
- package/dist/agents/sisyphus/index.d.ts +2 -0
- package/dist/agents/sisyphus-agent-config.d.ts +6 -0
- package/dist/agents/sisyphus-agent-factory.d.ts +1 -1
- package/dist/agents/sisyphus-runtime-prompt-reconciler.d.ts +15 -4
- package/dist/agents/types.d.ts +2 -2
- package/dist/cli/index.js +797 -465
- package/dist/cli/run/on-complete-hook.d.ts +2 -0
- package/dist/cli-node/index.js +797 -465
- package/dist/hooks/atlas/final-wave-approval-gate.test-support.d.ts +50 -0
- package/dist/hooks/atlas/system-reminder-templates.d.ts +0 -1
- package/dist/index.js +1511 -1140
- package/dist/shared/normalize-sdk-response.d.ts +1 -0
- package/dist/shared/shell-env.d.ts +1 -1
- package/dist/skills/coding-agent-sessions/SKILL.md +3 -2
- package/dist/skills/coding-agent-sessions/references/all-platforms.md +1 -1
- package/dist/skills/coding-agent-sessions/references/senpi.md +4 -4
- package/dist/skills/coding-agent-sessions/scripts/agent_sessions/pi_family.py +1 -1
- package/dist/skills/frontend/SKILL.md +10 -7
- package/dist/skills/frontend/references/design/_INDEX.md +1 -0
- package/dist/skills/frontend/references/design/stylegallery.md +80 -0
- package/dist/skills/ultimate-browsing/ATTRIBUTION.md +37 -10
- package/dist/skills/ultimate-browsing/engine/AGENTS.md +179 -0
- package/dist/skills/ultimate-browsing/engine/templates/package.json +1 -1
- package/dist/skills/ultimate-browsing/references/chrome-stealth.md +11 -11
- package/dist/skills/ulw-plan/SKILL.md +2 -2
- package/dist/skills/ulw-plan/references/full-workflow.md +27 -3
- package/dist/skills/ulw-plan/references/intent-clear.md +2 -1
- package/dist/skills/ulw-plan/references/intent-unclear.md +3 -3
- package/dist/tui.js +176 -14
- package/package.json +21 -19
- package/packages/lsp-core/src/lsp/client-diagnostics-concurrency.integration.test.ts +44 -0
- package/packages/lsp-core/src/lsp/client-diagnostics-freshness.integration.test.ts +0 -28
- package/packages/lsp-core/src/lsp/client-wrapper.test.ts +60 -7
- package/packages/lsp-core/src/lsp/client-wrapper.ts +69 -16
- package/packages/lsp-core/src/lsp/workspace-edit-adversarial.test.ts +20 -1
- package/packages/lsp-core/src/tools/diagnostics.ts +3 -3
- package/packages/lsp-core/src/tools/navigation.ts +4 -2
- package/packages/lsp-core/src/tools/rename.ts +4 -2
- package/packages/lsp-core/src/tools/symbols.ts +1 -1
- package/packages/lsp-daemon/dist/cli.js +83 -29
- package/packages/lsp-daemon/dist/client.js +76 -22
- package/packages/lsp-daemon/dist/index.js +81 -27
- package/packages/lsp-tools-mcp/dist/cli.js +76 -22
- package/packages/lsp-tools-mcp/dist/mcp.js +76 -22
- package/packages/lsp-tools-mcp/dist/tools.js +76 -22
- package/packages/omo-codex/plugin/.codex-plugin/plugin.json +1 -1
- package/packages/omo-codex/plugin/components/bootstrap/hooks/hooks.json +1 -1
- package/packages/omo-codex/plugin/components/bootstrap/package.json +1 -1
- package/packages/omo-codex/plugin/components/codegraph/dist/cli.js +118 -8
- package/packages/omo-codex/plugin/components/codegraph/dist/serve.js +118 -8
- package/packages/omo-codex/plugin/components/codegraph/package.json +1 -1
- package/packages/omo-codex/plugin/components/comment-checker/hooks/hooks.json +1 -1
- package/packages/omo-codex/plugin/components/comment-checker/package.json +1 -1
- package/packages/omo-codex/plugin/components/git-bash/hooks/hooks.json +2 -2
- package/packages/omo-codex/plugin/components/git-bash/package.json +1 -1
- package/packages/omo-codex/plugin/components/lazycodex-executor-verify/hooks/hooks.json +1 -1
- package/packages/omo-codex/plugin/components/lazycodex-executor-verify/package.json +1 -1
- package/packages/omo-codex/plugin/components/lazycodex-executor-verify/test/codex-hook.test.ts +3 -17
- package/packages/omo-codex/plugin/components/lsp/dist/.omo-runtime-manifest.json +3 -3
- package/packages/omo-codex/plugin/components/lsp/dist/cli.js +83 -29
- package/packages/omo-codex/plugin/components/lsp/hooks/hooks.json +2 -2
- package/packages/omo-codex/plugin/components/lsp/package.json +1 -1
- package/packages/omo-codex/plugin/components/rules/hooks/hooks.json +4 -4
- package/packages/omo-codex/plugin/components/rules/package.json +1 -1
- package/packages/omo-codex/plugin/components/rules/test/bundled-rules-priority.test.ts +11 -16
- package/packages/omo-codex/plugin/components/rules/test/bundled-rules.test.ts +16 -23
- package/packages/omo-codex/plugin/components/rules/test/codex-hook-post-compact-budget.test.ts +9 -7
- package/packages/omo-codex/plugin/components/rules/test/codex-hook-post-compact-context.test.ts +0 -6
- package/packages/omo-codex/plugin/components/rules/test/codex-hook-post-compact-dedup.test.ts +6 -4
- package/packages/omo-codex/plugin/components/rules/test/codex-hook-post-compact-directive.test.ts +12 -9
- package/packages/omo-codex/plugin/components/rules/test/codex-hook.test.ts +28 -37
- package/packages/omo-codex/plugin/components/rules/test/formatter.test.ts +37 -69
- package/packages/omo-codex/plugin/components/rules/test/hook-output.test.ts +2 -3
- package/packages/omo-codex/plugin/components/rules/test/windows-git-bash-bundled-rule.test.ts +1 -15
- package/packages/omo-codex/plugin/components/start-work-continuation/AGENTS.md +3 -2
- package/packages/omo-codex/plugin/components/start-work-continuation/hooks/hooks.json +2 -2
- package/packages/omo-codex/plugin/components/start-work-continuation/package.json +1 -1
- package/packages/omo-codex/plugin/components/start-work-continuation/test/cli.test.ts +0 -3
- package/packages/omo-codex/plugin/components/start-work-continuation/test/codex-hook.test.ts +2 -16
- package/packages/omo-codex/plugin/components/teammode/hooks/hooks.json +1 -1
- package/packages/omo-codex/plugin/components/teammode/package.json +1 -1
- package/packages/omo-codex/plugin/components/teammode/test/thread-title-hook.test.ts +3 -9
- package/packages/omo-codex/plugin/components/telemetry/dist/cli.js +24 -12
- package/packages/omo-codex/plugin/components/telemetry/dist/posthog.js +24 -12
- package/packages/omo-codex/plugin/components/telemetry/hooks/hooks.json +1 -1
- package/packages/omo-codex/plugin/components/telemetry/package.json +1 -1
- package/packages/omo-codex/plugin/components/ultrawork/directive.md +6 -0
- package/packages/omo-codex/plugin/components/ultrawork/hooks/hooks.json +1 -1
- package/packages/omo-codex/plugin/components/ultrawork/package.json +1 -1
- package/packages/omo-codex/plugin/components/ultrawork/skills/ultrawork/SKILL.md +6 -0
- package/packages/omo-codex/plugin/components/ultrawork/skills/ulw-plan/SKILL.md +2 -2
- package/packages/omo-codex/plugin/components/ultrawork/skills/ulw-plan/references/full-workflow.md +27 -3
- package/packages/omo-codex/plugin/components/ultrawork/skills/ulw-plan/references/intent-clear.md +2 -1
- package/packages/omo-codex/plugin/components/ultrawork/skills/ulw-plan/references/intent-unclear.md +3 -3
- package/packages/omo-codex/plugin/components/ultrawork/test/codex-hook.test.ts +0 -136
- package/packages/omo-codex/plugin/components/ultrawork/test/skill-pointer.test.ts +0 -2
- package/packages/omo-codex/plugin/components/ulw-loop/directive.md +6 -0
- package/packages/omo-codex/plugin/components/ulw-loop/hooks/hooks.json +4 -4
- package/packages/omo-codex/plugin/components/ulw-loop/package.json +1 -1
- package/packages/omo-codex/plugin/components/ulw-loop/skills/ulw-loop/SKILL.md +3 -2
- package/packages/omo-codex/plugin/components/ulw-loop/skills/ulw-loop/references/define-goal.md +108 -0
- package/packages/omo-codex/plugin/components/ulw-loop/skills/ulw-loop/references/full-workflow.md +1 -0
- package/packages/omo-codex/plugin/components/ulw-loop/test/checkpoint-continuation.test.ts +0 -1
- package/packages/omo-codex/plugin/components/ulw-loop/test/codex-goal-instruction.test.ts +2 -2
- package/packages/omo-codex/plugin/components/ulw-loop/test/codex-hook.test.ts +0 -3
- package/packages/omo-codex/plugin/components/ulw-loop/test/package-smoke.test.ts +2 -35
- package/packages/omo-codex/plugin/components/ulw-loop/test/ultrawork-directive.test.ts +4 -5
- package/packages/omo-codex/plugin/hooks/post-compact-resetting-git-bash-mcp-reminder.json +1 -1
- package/packages/omo-codex/plugin/hooks/post-compact-resetting-lsp-diagnostics-cache.json +1 -1
- package/packages/omo-codex/plugin/hooks/post-compact-resetting-project-rule-cache.json +1 -1
- package/packages/omo-codex/plugin/hooks/post-tool-use-checking-codegraph-init-guidance.json +1 -1
- package/packages/omo-codex/plugin/hooks/post-tool-use-checking-comments.json +1 -1
- package/packages/omo-codex/plugin/hooks/post-tool-use-checking-lsp-diagnostics.json +1 -1
- package/packages/omo-codex/plugin/hooks/post-tool-use-checking-thread-title-hygiene.json +1 -1
- package/packages/omo-codex/plugin/hooks/post-tool-use-matching-project-rules.json +1 -1
- package/packages/omo-codex/plugin/hooks/pre-tool-use-enforcing-unlimited-goal-budget.json +1 -1
- package/packages/omo-codex/plugin/hooks/pre-tool-use-guarding-ulw-loop-spawns.json +1 -1
- package/packages/omo-codex/plugin/hooks/pre-tool-use-recommending-git-bash-mcp.json +1 -1
- package/packages/omo-codex/plugin/hooks/session-start-checking-auto-update.json +1 -1
- package/packages/omo-codex/plugin/hooks/session-start-checking-bootstrap-provisioning.json +1 -1
- package/packages/omo-codex/plugin/hooks/session-start-checking-codegraph-bootstrap.json +1 -1
- package/packages/omo-codex/plugin/hooks/session-start-loading-project-rules.json +1 -1
- package/packages/omo-codex/plugin/hooks/session-start-recording-session-telemetry.json +1 -1
- package/packages/omo-codex/plugin/hooks/stop-checking-start-work-continuation.json +1 -1
- package/packages/omo-codex/plugin/hooks/stop-checking-ulw-loop-resume.json +1 -1
- package/packages/omo-codex/plugin/hooks/subagent-stop-checking-start-work-continuation.json +1 -1
- package/packages/omo-codex/plugin/hooks/subagent-stop-verifying-lazycodex-executor-evidence.json +1 -1
- package/packages/omo-codex/plugin/hooks/user-prompt-submit-checking-ultrawork-trigger.json +1 -1
- package/packages/omo-codex/plugin/hooks/user-prompt-submit-checking-ulw-loop-steering.json +1 -1
- package/packages/omo-codex/plugin/hooks/user-prompt-submit-loading-project-rules.json +1 -1
- package/packages/omo-codex/plugin/package-lock.json +20 -20
- package/packages/omo-codex/plugin/package.json +1 -1
- package/packages/omo-codex/plugin/skills/coding-agent-sessions/SKILL.md +3 -2
- package/packages/omo-codex/plugin/skills/coding-agent-sessions/references/all-platforms.md +1 -1
- package/packages/omo-codex/plugin/skills/coding-agent-sessions/references/senpi.md +4 -4
- package/packages/omo-codex/plugin/skills/coding-agent-sessions/scripts/agent_sessions/pi_family.py +1 -1
- package/packages/omo-codex/plugin/skills/frontend/SKILL.md +10 -7
- package/packages/omo-codex/plugin/skills/frontend/references/design/_INDEX.md +1 -0
- package/packages/omo-codex/plugin/skills/frontend/references/design/stylegallery.md +80 -0
- package/packages/omo-codex/plugin/skills/ultimate-browsing/ATTRIBUTION.md +37 -10
- package/packages/omo-codex/plugin/skills/ultimate-browsing/engine/AGENTS.md +179 -0
- package/packages/omo-codex/plugin/skills/ultimate-browsing/engine/templates/package.json +1 -1
- package/packages/omo-codex/plugin/skills/ultimate-browsing/references/chrome-stealth.md +11 -11
- package/packages/omo-codex/plugin/skills/ultrawork/SKILL.md +6 -0
- package/packages/omo-codex/plugin/skills/ulw-loop/SKILL.md +3 -2
- package/packages/omo-codex/plugin/skills/ulw-loop/references/define-goal.md +108 -0
- package/packages/omo-codex/plugin/skills/ulw-loop/references/full-workflow.md +1 -0
- package/packages/omo-codex/plugin/skills/ulw-plan/SKILL.md +2 -2
- package/packages/omo-codex/plugin/skills/ulw-plan/references/full-workflow.md +27 -3
- package/packages/omo-codex/plugin/skills/ulw-plan/references/intent-clear.md +2 -1
- package/packages/omo-codex/plugin/skills/ulw-plan/references/intent-unclear.md +3 -3
- package/packages/omo-codex/plugin/test/aggregate-agents.test.mjs +19 -173
- package/packages/omo-codex/plugin/test/aggregate-hooks.test.mjs +4 -24
- package/packages/omo-codex/plugin/test/aggregate-plugin-fixture.mjs +175 -13
- package/packages/omo-codex/plugin/test/aggregate.test.mjs +78 -2
- package/packages/omo-codex/plugin/test/auto-update-release-notes.test.mjs +19 -33
- package/packages/omo-codex/plugin/test/lcx-contribute-bug-fix-template.test.mjs +21 -27
- package/packages/omo-codex/plugin/test/scaffold-plan.test.mjs +0 -36
- package/packages/omo-codex/plugin/test/sync-skills-codex-compatibility.test.mjs +101 -0
- package/packages/omo-codex/plugin/test/sync-skills.test.mjs +1 -119
- package/packages/omo-codex/plugin/test/teammode-archive-ambiguity.test.mjs +0 -40
- package/packages/omo-codex/plugin/test/teammode-communication.test.mjs +6 -62
- package/packages/omo-codex/plugin/test/teammode-thread-links.test.mjs +3 -36
- package/packages/omo-codex/plugin/test/teammode-transport.test.mjs +0 -44
- package/packages/omo-codex/plugin/test/teammode-worktree.test.mjs +2 -6
- package/packages/omo-codex/plugin/test/ultrawork-skill-pointer.test.mjs +0 -3
- package/packages/omo-codex/plugin/test/ulw-plan-review-state-contract.test.mjs +0 -3
- package/packages/omo-codex/scripts/install-dist/install-local.mjs +57 -19
- package/packages/omo-codex/scripts/install-lazycodex-version-stamp.test.mjs +7 -2
- package/packages/shared-skills/skills/coding-agent-sessions/SKILL.md +3 -2
- package/packages/shared-skills/skills/coding-agent-sessions/references/all-platforms.md +1 -1
- package/packages/shared-skills/skills/coding-agent-sessions/references/senpi.md +4 -4
- package/packages/shared-skills/skills/coding-agent-sessions/scripts/agent_sessions/pi_family.py +1 -1
- package/packages/shared-skills/skills/frontend/SKILL.md +10 -7
- package/packages/shared-skills/skills/frontend/references/design/_INDEX.md +1 -0
- package/packages/shared-skills/skills/frontend/references/design/stylegallery.md +80 -0
- package/packages/shared-skills/skills/ultimate-browsing/ATTRIBUTION.md +37 -10
- package/packages/shared-skills/skills/ultimate-browsing/engine/AGENTS.md +179 -0
- package/packages/shared-skills/skills/ultimate-browsing/engine/templates/package.json +1 -1
- package/packages/shared-skills/skills/ultimate-browsing/references/chrome-stealth.md +11 -11
- package/packages/shared-skills/skills/ulw-plan/SKILL.md +2 -2
- package/packages/shared-skills/skills/ulw-plan/references/full-workflow.md +27 -3
- package/packages/shared-skills/skills/ulw-plan/references/intent-clear.md +2 -1
- package/packages/shared-skills/skills/ulw-plan/references/intent-unclear.md +3 -3
- package/dist/tools/call-omo-agent/background-agent-executor.d.ts +0 -5
- package/packages/omo-codex/plugin/test/aggregate-skills.test.mjs +0 -92
- package/packages/omo-codex/plugin/test/sync-skills-orchestration.test.mjs +0 -314
- package/packages/omo-codex/plugin/test/ulw-plan-scope-contract.test.mjs +0 -24
package/dist/index.js
CHANGED
|
@@ -5537,14 +5537,15 @@ var init_codegraph = __esm(() => {
|
|
|
5537
5537
|
|
|
5538
5538
|
// packages/omo-config-core/src/schema/memory.ts
|
|
5539
5539
|
import * as z7 from "zod";
|
|
5540
|
-
var OmoMemoryReflectionTriggerSchema, OmoMemoryReflectionSchema, OmoMemorySyncSchema, OmoMemorySearchSchema, OmoMemoryReflectionTriggerLayerSchema, OmoMemoryReflectionLayerSchema, OmoMemorySyncLayerSchema, OmoMemorySearchLayerSchema, OmoMemoryAgentOverridesSchema, OmoMemorySettingsSchema, OmoMemorySettingsLayerSchema;
|
|
5540
|
+
var OmoMemoryReflectionTriggerSchema, OmoMemoryReflectionSchema, OmoMemorySyncSchema, OmoMemorySearchSchema, OmoMemoryNudgeSchema, OmoMemoryFactsSchema, OmoMemoryDreamSchema, OmoMemoryPeopleSchema, OmoMemorySoulSchema, OmoMemoryReflectionTriggerLayerSchema, OmoMemoryReflectionLayerSchema, OmoMemorySyncLayerSchema, OmoMemorySearchLayerSchema, OmoMemoryNudgeLayerSchema, OmoMemoryFactsLayerSchema, OmoMemoryDreamLayerSchema, OmoMemoryPeopleLayerSchema, OmoMemorySoulLayerSchema, OmoMemoryAgentOverridesSchema, OmoMemorySettingsSchema, OmoMemorySettingsLayerSchema;
|
|
5541
5541
|
var init_memory = __esm(() => {
|
|
5542
5542
|
OmoMemoryReflectionTriggerSchema = z7.object({
|
|
5543
|
-
step_count: z7.number().int().nonnegative().default(
|
|
5543
|
+
step_count: z7.number().int().nonnegative().default(25),
|
|
5544
5544
|
on_compaction: z7.boolean().default(true)
|
|
5545
5545
|
}).strict();
|
|
5546
5546
|
OmoMemoryReflectionSchema = z7.object({
|
|
5547
|
-
|
|
5547
|
+
enabled: z7.boolean().default(true),
|
|
5548
|
+
trigger: OmoMemoryReflectionTriggerSchema.default({ step_count: 25, on_compaction: true }),
|
|
5548
5549
|
merge: z7.enum(["auto", "integration"]).default("auto"),
|
|
5549
5550
|
category: z7.string().min(1).default("quick"),
|
|
5550
5551
|
timeout_minutes: z7.number().int().positive().default(15),
|
|
@@ -5557,11 +5558,36 @@ var init_memory = __esm(() => {
|
|
|
5557
5558
|
OmoMemorySearchSchema = z7.object({
|
|
5558
5559
|
enabled: z7.boolean().default(true)
|
|
5559
5560
|
}).strict();
|
|
5561
|
+
OmoMemoryNudgeSchema = z7.object({
|
|
5562
|
+
enabled: z7.boolean().default(true),
|
|
5563
|
+
every_user_turns: z7.number().int().min(1).default(10)
|
|
5564
|
+
}).strict();
|
|
5565
|
+
OmoMemoryFactsSchema = z7.object({
|
|
5566
|
+
enabled: z7.boolean().default(true),
|
|
5567
|
+
debounce_settles: z7.number().int().min(1).default(4)
|
|
5568
|
+
}).strict();
|
|
5569
|
+
OmoMemoryDreamSchema = z7.object({
|
|
5570
|
+
enabled: z7.boolean().default(true),
|
|
5571
|
+
idle_minutes: z7.number().int().min(0).default(30),
|
|
5572
|
+
min_hours_between: z7.number().int().min(1).default(24),
|
|
5573
|
+
shutdown_launch: z7.boolean().default(true),
|
|
5574
|
+
auto_select_max: z7.number().int().min(1).max(10).default(5),
|
|
5575
|
+
auto_select_max_chars: z7.number().int().min(1e4).default(150000)
|
|
5576
|
+
}).strict();
|
|
5577
|
+
OmoMemoryPeopleSchema = z7.object({
|
|
5578
|
+
enabled: z7.boolean().default(true),
|
|
5579
|
+
max_entries: z7.number().int().min(1).max(100).default(40),
|
|
5580
|
+
max_entry_chars: z7.number().int().min(50).max(500).default(200)
|
|
5581
|
+
}).strict();
|
|
5582
|
+
OmoMemorySoulSchema = z7.object({
|
|
5583
|
+
edit_notice: z7.boolean().default(true)
|
|
5584
|
+
}).strict();
|
|
5560
5585
|
OmoMemoryReflectionTriggerLayerSchema = z7.object({
|
|
5561
5586
|
step_count: z7.number().int().nonnegative().optional(),
|
|
5562
5587
|
on_compaction: z7.boolean().optional()
|
|
5563
5588
|
}).strict();
|
|
5564
5589
|
OmoMemoryReflectionLayerSchema = z7.object({
|
|
5590
|
+
enabled: z7.boolean().optional(),
|
|
5565
5591
|
trigger: OmoMemoryReflectionTriggerLayerSchema.optional(),
|
|
5566
5592
|
merge: z7.enum(["auto", "integration"]).optional(),
|
|
5567
5593
|
category: z7.string().min(1).optional(),
|
|
@@ -5575,10 +5601,39 @@ var init_memory = __esm(() => {
|
|
|
5575
5601
|
OmoMemorySearchLayerSchema = z7.object({
|
|
5576
5602
|
enabled: z7.boolean().optional()
|
|
5577
5603
|
}).strict();
|
|
5604
|
+
OmoMemoryNudgeLayerSchema = z7.object({
|
|
5605
|
+
enabled: z7.boolean().optional(),
|
|
5606
|
+
every_user_turns: z7.number().int().min(1).optional()
|
|
5607
|
+
}).strict();
|
|
5608
|
+
OmoMemoryFactsLayerSchema = z7.object({
|
|
5609
|
+
enabled: z7.boolean().optional(),
|
|
5610
|
+
debounce_settles: z7.number().int().min(1).optional()
|
|
5611
|
+
}).strict();
|
|
5612
|
+
OmoMemoryDreamLayerSchema = z7.object({
|
|
5613
|
+
enabled: z7.boolean().optional(),
|
|
5614
|
+
idle_minutes: z7.number().int().min(0).optional(),
|
|
5615
|
+
min_hours_between: z7.number().int().min(1).optional(),
|
|
5616
|
+
shutdown_launch: z7.boolean().optional(),
|
|
5617
|
+
auto_select_max: z7.number().int().min(1).max(10).optional(),
|
|
5618
|
+
auto_select_max_chars: z7.number().int().min(1e4).optional()
|
|
5619
|
+
}).strict();
|
|
5620
|
+
OmoMemoryPeopleLayerSchema = z7.object({
|
|
5621
|
+
enabled: z7.boolean().optional(),
|
|
5622
|
+
max_entries: z7.number().int().min(1).max(100).optional(),
|
|
5623
|
+
max_entry_chars: z7.number().int().min(50).max(500).optional()
|
|
5624
|
+
}).strict();
|
|
5625
|
+
OmoMemorySoulLayerSchema = z7.object({
|
|
5626
|
+
edit_notice: z7.boolean().optional()
|
|
5627
|
+
}).strict();
|
|
5578
5628
|
OmoMemoryAgentOverridesSchema = z7.object({
|
|
5579
5629
|
enabled: z7.boolean().optional(),
|
|
5580
5630
|
agent: z7.string().min(1).optional(),
|
|
5581
5631
|
reflection: OmoMemoryReflectionLayerSchema.optional(),
|
|
5632
|
+
nudge: OmoMemoryNudgeLayerSchema.optional(),
|
|
5633
|
+
facts: OmoMemoryFactsLayerSchema.optional(),
|
|
5634
|
+
dream: OmoMemoryDreamLayerSchema.optional(),
|
|
5635
|
+
people: OmoMemoryPeopleLayerSchema.optional(),
|
|
5636
|
+
soul: OmoMemorySoulLayerSchema.optional(),
|
|
5582
5637
|
sync: OmoMemorySyncLayerSchema.optional(),
|
|
5583
5638
|
search: OmoMemorySearchLayerSchema.optional(),
|
|
5584
5639
|
compile_warn_tokens: z7.number().int().positive().optional()
|
|
@@ -5586,13 +5641,27 @@ var init_memory = __esm(() => {
|
|
|
5586
5641
|
OmoMemorySettingsSchema = z7.object({
|
|
5587
5642
|
enabled: z7.boolean().default(true),
|
|
5588
5643
|
agent: z7.string().min(1).default("auto"),
|
|
5644
|
+
tool_exposure: z7.enum(["direct", "search"]).default("direct"),
|
|
5589
5645
|
reflection: OmoMemoryReflectionSchema.default({
|
|
5590
|
-
|
|
5646
|
+
enabled: true,
|
|
5647
|
+
trigger: { step_count: 25, on_compaction: true },
|
|
5591
5648
|
merge: "auto",
|
|
5592
5649
|
category: "quick",
|
|
5593
5650
|
timeout_minutes: 15,
|
|
5594
5651
|
sandbox: "auto"
|
|
5595
5652
|
}),
|
|
5653
|
+
nudge: OmoMemoryNudgeSchema.default({ enabled: true, every_user_turns: 10 }),
|
|
5654
|
+
facts: OmoMemoryFactsSchema.default({ enabled: true, debounce_settles: 4 }),
|
|
5655
|
+
dream: OmoMemoryDreamSchema.default({
|
|
5656
|
+
enabled: true,
|
|
5657
|
+
idle_minutes: 30,
|
|
5658
|
+
min_hours_between: 24,
|
|
5659
|
+
shutdown_launch: true,
|
|
5660
|
+
auto_select_max: 5,
|
|
5661
|
+
auto_select_max_chars: 150000
|
|
5662
|
+
}),
|
|
5663
|
+
people: OmoMemoryPeopleSchema.default({ enabled: true, max_entries: 40, max_entry_chars: 200 }),
|
|
5664
|
+
soul: OmoMemorySoulSchema.default({ edit_notice: true }),
|
|
5596
5665
|
sync: OmoMemorySyncSchema.default({ enabled: true }),
|
|
5597
5666
|
search: OmoMemorySearchSchema.default({ enabled: true }),
|
|
5598
5667
|
compile_warn_tokens: z7.number().int().positive().default(30000),
|
|
@@ -5601,7 +5670,13 @@ var init_memory = __esm(() => {
|
|
|
5601
5670
|
OmoMemorySettingsLayerSchema = z7.object({
|
|
5602
5671
|
enabled: z7.boolean().optional(),
|
|
5603
5672
|
agent: z7.string().min(1).optional(),
|
|
5673
|
+
tool_exposure: z7.enum(["direct", "search"]).optional(),
|
|
5604
5674
|
reflection: OmoMemoryReflectionLayerSchema.optional(),
|
|
5675
|
+
nudge: OmoMemoryNudgeLayerSchema.optional(),
|
|
5676
|
+
facts: OmoMemoryFactsLayerSchema.optional(),
|
|
5677
|
+
dream: OmoMemoryDreamLayerSchema.optional(),
|
|
5678
|
+
people: OmoMemoryPeopleLayerSchema.optional(),
|
|
5679
|
+
soul: OmoMemorySoulLayerSchema.optional(),
|
|
5605
5680
|
sync: OmoMemorySyncLayerSchema.optional(),
|
|
5606
5681
|
search: OmoMemorySearchLayerSchema.optional(),
|
|
5607
5682
|
compile_warn_tokens: z7.number().int().positive().optional(),
|
|
@@ -5641,7 +5716,7 @@ function resolveOmoTaskSettings(input, resolveParallelism = availableParallelism
|
|
|
5641
5716
|
residency_max_children: record8["residency_max_children"] ?? Math.max(8, resolveParallelism() * 3)
|
|
5642
5717
|
});
|
|
5643
5718
|
}
|
|
5644
|
-
var ResidencyMaxChildrenInputSchema, OmoTaskWaitSchema, OmoTaskTeamSettingsSchema, OmoTaskWarningsSchema, OmoTaskSettingsSchema, OmoTaskWaitLayerSchema, OmoTaskTeamSettingsLayerSchema, OmoTaskWarningsLayerSchema, OmoTaskSettingsLayerSchema;
|
|
5719
|
+
var ResidencyMaxChildrenInputSchema, OmoTaskWaitSchema, OmoTaskTeamSettingsSchema, OmoTaskWarningsSchema, OmoTaskDagSettingsSchema, OmoTaskSettingsSchema, OmoTaskDagSettingsLayerSchema, OmoTaskWaitLayerSchema, OmoTaskTeamSettingsLayerSchema, OmoTaskWarningsLayerSchema, OmoTaskSettingsLayerSchema;
|
|
5645
5720
|
var init_task = __esm(() => {
|
|
5646
5721
|
ResidencyMaxChildrenInputSchema = z9.union([z9.number().int().positive(), z9.literal("unlimited")]);
|
|
5647
5722
|
OmoTaskWaitSchema = z9.object({
|
|
@@ -5657,6 +5732,16 @@ var init_task = __esm(() => {
|
|
|
5657
5732
|
OmoTaskWarningsSchema = z9.object({
|
|
5658
5733
|
unavailable_categories: z9.boolean().default(true)
|
|
5659
5734
|
}).strict();
|
|
5735
|
+
OmoTaskDagSettingsSchema = z9.object({
|
|
5736
|
+
max_nodes_per_run: z9.number().int().positive().default(64),
|
|
5737
|
+
max_runs_per_session: z9.number().int().positive().default(16),
|
|
5738
|
+
subscriber_ring: z9.number().int().positive().default(1000),
|
|
5739
|
+
heartbeat_ms: z9.number().int().positive().default(15000),
|
|
5740
|
+
history_default_limit: z9.number().int().positive().default(256),
|
|
5741
|
+
history_max_limit: z9.number().int().positive().default(1000),
|
|
5742
|
+
retention_days: z9.number().int().positive().default(7),
|
|
5743
|
+
max_prompt_bytes: z9.number().int().positive().default(262144)
|
|
5744
|
+
}).strict();
|
|
5660
5745
|
OmoTaskSettingsSchema = z9.object({
|
|
5661
5746
|
default_execution_mode: z9.enum(["in-process", "process"]).default("in-process"),
|
|
5662
5747
|
default_concurrency: z9.number().int().positive().default(5),
|
|
@@ -5674,7 +5759,18 @@ var init_task = __esm(() => {
|
|
|
5674
5759
|
max_members: 8,
|
|
5675
5760
|
max_parallel_members: 4,
|
|
5676
5761
|
max_wall_clock_minutes: 120
|
|
5677
|
-
})
|
|
5762
|
+
}),
|
|
5763
|
+
dag: OmoTaskDagSettingsSchema.optional()
|
|
5764
|
+
}).strict();
|
|
5765
|
+
OmoTaskDagSettingsLayerSchema = z9.object({
|
|
5766
|
+
max_nodes_per_run: z9.number().int().positive().optional(),
|
|
5767
|
+
max_runs_per_session: z9.number().int().positive().optional(),
|
|
5768
|
+
subscriber_ring: z9.number().int().positive().optional(),
|
|
5769
|
+
heartbeat_ms: z9.number().int().positive().optional(),
|
|
5770
|
+
history_default_limit: z9.number().int().positive().optional(),
|
|
5771
|
+
history_max_limit: z9.number().int().positive().optional(),
|
|
5772
|
+
retention_days: z9.number().int().positive().optional(),
|
|
5773
|
+
max_prompt_bytes: z9.number().int().positive().optional()
|
|
5678
5774
|
}).strict();
|
|
5679
5775
|
OmoTaskWaitLayerSchema = z9.object({
|
|
5680
5776
|
min_ms: z9.number().int().positive().optional(),
|
|
@@ -5702,7 +5798,8 @@ var init_task = __esm(() => {
|
|
|
5702
5798
|
resume_children: z9.boolean().optional(),
|
|
5703
5799
|
warnings: OmoTaskWarningsLayerSchema.optional(),
|
|
5704
5800
|
wait: OmoTaskWaitLayerSchema.optional(),
|
|
5705
|
-
team: OmoTaskTeamSettingsLayerSchema.optional()
|
|
5801
|
+
team: OmoTaskTeamSettingsLayerSchema.optional(),
|
|
5802
|
+
dag: OmoTaskDagSettingsLayerSchema.optional()
|
|
5706
5803
|
}).strict();
|
|
5707
5804
|
});
|
|
5708
5805
|
|
|
@@ -5757,8 +5854,21 @@ var init_team = __esm(() => {
|
|
|
5757
5854
|
OmoTeamsConfigLayerSchema = z10.record(z10.string(), OmoTeamSpecLayerSchema);
|
|
5758
5855
|
});
|
|
5759
5856
|
|
|
5760
|
-
// packages/omo-config-core/src/schema/
|
|
5857
|
+
// packages/omo-config-core/src/schema/telemetry.ts
|
|
5761
5858
|
import * as z11 from "zod";
|
|
5859
|
+
var OmoTelemetrySettingsShape, OmoTelemetrySettingsLayerSchema, OmoTelemetrySettingsSchema;
|
|
5860
|
+
var init_telemetry = __esm(() => {
|
|
5861
|
+
OmoTelemetrySettingsShape = {
|
|
5862
|
+
enabled: z11.boolean()
|
|
5863
|
+
};
|
|
5864
|
+
OmoTelemetrySettingsLayerSchema = z11.object(OmoTelemetrySettingsShape).partial().strict();
|
|
5865
|
+
OmoTelemetrySettingsSchema = OmoTelemetrySettingsLayerSchema.extend({
|
|
5866
|
+
enabled: z11.boolean().default(true)
|
|
5867
|
+
}).strict();
|
|
5868
|
+
});
|
|
5869
|
+
|
|
5870
|
+
// packages/omo-config-core/src/schema/config.ts
|
|
5871
|
+
import * as z12 from "zod";
|
|
5762
5872
|
var OmoOpenCodeHarnessConfigSchema, OmoTypedHarnessConfigSchema, OmoConfigProfileSchema, OmoConfigSchema, OmoConfigLayerSchema;
|
|
5763
5873
|
var init_config = __esm(() => {
|
|
5764
5874
|
init_agent();
|
|
@@ -5768,17 +5878,19 @@ var init_config = __esm(() => {
|
|
|
5768
5878
|
init_model_catalog();
|
|
5769
5879
|
init_task();
|
|
5770
5880
|
init_team();
|
|
5771
|
-
|
|
5772
|
-
|
|
5881
|
+
init_telemetry();
|
|
5882
|
+
OmoOpenCodeHarnessConfigSchema = z12.record(z12.string(), z12.unknown());
|
|
5883
|
+
OmoTypedHarnessConfigSchema = z12.object({
|
|
5773
5884
|
categories: OmoCategoriesConfigSchema.optional(),
|
|
5774
5885
|
agents: OmoAgentsConfigSchema.optional(),
|
|
5775
5886
|
codegraph: OmoCodegraphSettingsLayerSchema.optional(),
|
|
5776
5887
|
task: OmoTaskSettingsLayerSchema.optional(),
|
|
5777
5888
|
teams: OmoTeamsConfigLayerSchema.optional(),
|
|
5778
5889
|
models: OmoModelCatalogLayerSchema.optional(),
|
|
5779
|
-
memory: OmoMemorySettingsLayerSchema.optional()
|
|
5890
|
+
memory: OmoMemorySettingsLayerSchema.optional(),
|
|
5891
|
+
telemetry: OmoTelemetrySettingsLayerSchema.optional()
|
|
5780
5892
|
}).strict();
|
|
5781
|
-
OmoConfigProfileSchema =
|
|
5893
|
+
OmoConfigProfileSchema = z12.object({
|
|
5782
5894
|
categories: OmoCategoriesConfigSchema.optional(),
|
|
5783
5895
|
agents: OmoAgentsConfigSchema.optional(),
|
|
5784
5896
|
codegraph: OmoCodegraphSettingsLayerSchema.optional(),
|
|
@@ -5786,12 +5898,13 @@ var init_config = __esm(() => {
|
|
|
5786
5898
|
teams: OmoTeamsConfigLayerSchema.optional(),
|
|
5787
5899
|
models: OmoModelCatalogLayerSchema.optional(),
|
|
5788
5900
|
memory: OmoMemorySettingsLayerSchema.optional(),
|
|
5901
|
+
telemetry: OmoTelemetrySettingsLayerSchema.optional(),
|
|
5789
5902
|
"[opencode]": OmoOpenCodeHarnessConfigSchema.optional(),
|
|
5790
5903
|
"[senpi]": OmoTypedHarnessConfigSchema.optional(),
|
|
5791
5904
|
"[codex]": OmoTypedHarnessConfigSchema.optional()
|
|
5792
5905
|
}).strict();
|
|
5793
|
-
OmoConfigSchema =
|
|
5794
|
-
$schema:
|
|
5906
|
+
OmoConfigSchema = z12.object({
|
|
5907
|
+
$schema: z12.string().optional(),
|
|
5795
5908
|
categories: OmoCategoriesConfigSchema.optional(),
|
|
5796
5909
|
agents: OmoAgentsConfigSchema.optional(),
|
|
5797
5910
|
codegraph: OmoCodegraphSettingsSchema.optional(),
|
|
@@ -5799,15 +5912,16 @@ var init_config = __esm(() => {
|
|
|
5799
5912
|
teams: OmoTeamsConfigSchema.optional(),
|
|
5800
5913
|
models: OmoModelCatalogSchema.optional(),
|
|
5801
5914
|
memory: OmoMemorySettingsSchema.optional(),
|
|
5915
|
+
telemetry: OmoTelemetrySettingsSchema.optional(),
|
|
5802
5916
|
"[opencode]": OmoOpenCodeHarnessConfigSchema.optional(),
|
|
5803
5917
|
"[senpi]": OmoTypedHarnessConfigSchema.optional(),
|
|
5804
5918
|
"[codex]": OmoTypedHarnessConfigSchema.optional(),
|
|
5805
|
-
profiles:
|
|
5806
|
-
_migrations:
|
|
5807
|
-
legacy_migrations:
|
|
5919
|
+
profiles: z12.record(z12.string(), OmoConfigProfileSchema).default({}),
|
|
5920
|
+
_migrations: z12.array(z12.string()).optional(),
|
|
5921
|
+
legacy_migrations: z12.record(z12.string(), z12.unknown()).optional()
|
|
5808
5922
|
}).strict();
|
|
5809
|
-
OmoConfigLayerSchema =
|
|
5810
|
-
$schema:
|
|
5923
|
+
OmoConfigLayerSchema = z12.object({
|
|
5924
|
+
$schema: z12.string().optional(),
|
|
5811
5925
|
categories: OmoCategoriesConfigSchema.optional(),
|
|
5812
5926
|
agents: OmoAgentsConfigSchema.optional(),
|
|
5813
5927
|
codegraph: OmoCodegraphSettingsLayerSchema.optional(),
|
|
@@ -5815,12 +5929,13 @@ var init_config = __esm(() => {
|
|
|
5815
5929
|
teams: OmoTeamsConfigLayerSchema.optional(),
|
|
5816
5930
|
models: OmoModelCatalogLayerSchema.optional(),
|
|
5817
5931
|
memory: OmoMemorySettingsLayerSchema.optional(),
|
|
5932
|
+
telemetry: OmoTelemetrySettingsLayerSchema.optional(),
|
|
5818
5933
|
"[opencode]": OmoOpenCodeHarnessConfigSchema.optional(),
|
|
5819
5934
|
"[senpi]": OmoTypedHarnessConfigSchema.optional(),
|
|
5820
5935
|
"[codex]": OmoTypedHarnessConfigSchema.optional(),
|
|
5821
|
-
profiles:
|
|
5822
|
-
_migrations:
|
|
5823
|
-
legacy_migrations:
|
|
5936
|
+
profiles: z12.record(z12.string(), OmoConfigProfileSchema).optional(),
|
|
5937
|
+
_migrations: z12.array(z12.string()).optional(),
|
|
5938
|
+
legacy_migrations: z12.record(z12.string(), z12.unknown()).optional()
|
|
5824
5939
|
}).strict();
|
|
5825
5940
|
});
|
|
5826
5941
|
|
|
@@ -5837,6 +5952,7 @@ var init_schema = __esm(() => {
|
|
|
5837
5952
|
init_model_ref();
|
|
5838
5953
|
init_task();
|
|
5839
5954
|
init_team();
|
|
5955
|
+
init_telemetry();
|
|
5840
5956
|
});
|
|
5841
5957
|
|
|
5842
5958
|
// packages/omo-config-core/src/loader/merge.ts
|
|
@@ -16168,7 +16284,7 @@ var init_member_parser = __esm(() => {
|
|
|
16168
16284
|
});
|
|
16169
16285
|
|
|
16170
16286
|
// packages/team-core/src/types.ts
|
|
16171
|
-
import * as
|
|
16287
|
+
import * as z50 from "zod";
|
|
16172
16288
|
var MESSAGE_KINDS, TASK_STATUSES, RUNTIME_STATUSES, MemberBaseSchema, CategoryMemberSchema, SubagentMemberSchema, MemberSchema, TeamReferenceSchema, MISSING_TEAM_LEAD_MESSAGE = "leadAgentId required (or write a `lead: {...}` field, or mark one member with `isLead: true`)", TeamSpecSchema, MessageSchema, TaskSchema, RuntimeStateMemberModelSchema, RuntimeStateMemberSchema, RuntimeBoundsSchema, ShutdownRequestSchema, RuntimeStateTmuxLayoutSchema, RuntimeStateSchema, AGENT_ELIGIBILITY_REGISTRY, parseMemberBase;
|
|
16173
16289
|
var init_types5 = __esm(() => {
|
|
16174
16290
|
init_member_parser();
|
|
@@ -16189,40 +16305,40 @@ var init_types5 = __esm(() => {
|
|
|
16189
16305
|
"failed",
|
|
16190
16306
|
"orphaned"
|
|
16191
16307
|
];
|
|
16192
|
-
MemberBaseSchema =
|
|
16193
|
-
name:
|
|
16194
|
-
cwd:
|
|
16195
|
-
worktreePath:
|
|
16196
|
-
task_summary:
|
|
16197
|
-
subscriptions:
|
|
16198
|
-
backendType:
|
|
16199
|
-
color:
|
|
16200
|
-
isActive:
|
|
16308
|
+
MemberBaseSchema = z50.object({
|
|
16309
|
+
name: z50.string().min(1).regex(/^[a-z0-9-]+$/),
|
|
16310
|
+
cwd: z50.string().optional(),
|
|
16311
|
+
worktreePath: z50.string().optional(),
|
|
16312
|
+
task_summary: z50.string().max(80).optional(),
|
|
16313
|
+
subscriptions: z50.array(z50.string()).optional(),
|
|
16314
|
+
backendType: z50.enum(["in-process", "tmux"]).default("in-process"),
|
|
16315
|
+
color: z50.string().optional(),
|
|
16316
|
+
isActive: z50.boolean().default(true)
|
|
16201
16317
|
}).strict();
|
|
16202
16318
|
CategoryMemberSchema = MemberBaseSchema.extend({
|
|
16203
|
-
kind:
|
|
16204
|
-
category:
|
|
16205
|
-
prompt:
|
|
16319
|
+
kind: z50.literal("category"),
|
|
16320
|
+
category: z50.string().min(1),
|
|
16321
|
+
prompt: z50.string().min(1)
|
|
16206
16322
|
});
|
|
16207
16323
|
SubagentMemberSchema = MemberBaseSchema.extend({
|
|
16208
|
-
kind:
|
|
16209
|
-
subagent_type:
|
|
16210
|
-
prompt:
|
|
16324
|
+
kind: z50.literal("subagent_type"),
|
|
16325
|
+
subagent_type: z50.string().min(1),
|
|
16326
|
+
prompt: z50.string().optional()
|
|
16211
16327
|
});
|
|
16212
|
-
MemberSchema =
|
|
16213
|
-
TeamReferenceSchema =
|
|
16214
|
-
path:
|
|
16215
|
-
description:
|
|
16328
|
+
MemberSchema = z50.discriminatedUnion("kind", [CategoryMemberSchema, SubagentMemberSchema]);
|
|
16329
|
+
TeamReferenceSchema = z50.object({
|
|
16330
|
+
path: z50.string(),
|
|
16331
|
+
description: z50.string().optional()
|
|
16216
16332
|
}).strict();
|
|
16217
|
-
TeamSpecSchema =
|
|
16218
|
-
version:
|
|
16219
|
-
name:
|
|
16220
|
-
description:
|
|
16221
|
-
createdAt:
|
|
16222
|
-
leadAgentId:
|
|
16223
|
-
teamAllowedPaths:
|
|
16224
|
-
sessionPermission:
|
|
16225
|
-
members:
|
|
16333
|
+
TeamSpecSchema = z50.object({
|
|
16334
|
+
version: z50.literal(1).default(1),
|
|
16335
|
+
name: z50.string().min(1).regex(/^[a-z0-9-]+$/),
|
|
16336
|
+
description: z50.string().optional(),
|
|
16337
|
+
createdAt: z50.number().int().positive().default(() => Date.now()),
|
|
16338
|
+
leadAgentId: z50.string().optional(),
|
|
16339
|
+
teamAllowedPaths: z50.array(z50.string()).optional(),
|
|
16340
|
+
sessionPermission: z50.string().optional(),
|
|
16341
|
+
members: z50.array(MemberSchema).min(1).max(8)
|
|
16226
16342
|
}).superRefine((teamSpec, ctx) => {
|
|
16227
16343
|
if (teamSpec.leadAgentId === undefined && teamSpec.members.length > 1) {
|
|
16228
16344
|
ctx.addIssue({
|
|
@@ -16244,95 +16360,95 @@ var init_types5 = __esm(() => {
|
|
|
16244
16360
|
leadAgentId: firstMember.name
|
|
16245
16361
|
};
|
|
16246
16362
|
});
|
|
16247
|
-
MessageSchema =
|
|
16248
|
-
version:
|
|
16249
|
-
messageId:
|
|
16250
|
-
from:
|
|
16251
|
-
to:
|
|
16252
|
-
kind:
|
|
16253
|
-
body:
|
|
16254
|
-
summary:
|
|
16255
|
-
references:
|
|
16256
|
-
timestamp:
|
|
16257
|
-
correlationId:
|
|
16258
|
-
color:
|
|
16363
|
+
MessageSchema = z50.object({
|
|
16364
|
+
version: z50.literal(1),
|
|
16365
|
+
messageId: z50.string().uuid(),
|
|
16366
|
+
from: z50.string(),
|
|
16367
|
+
to: z50.string(),
|
|
16368
|
+
kind: z50.enum(MESSAGE_KINDS),
|
|
16369
|
+
body: z50.string().max(32 * 1024),
|
|
16370
|
+
summary: z50.string().optional(),
|
|
16371
|
+
references: z50.array(TeamReferenceSchema).optional(),
|
|
16372
|
+
timestamp: z50.number().int().positive(),
|
|
16373
|
+
correlationId: z50.string().uuid().optional(),
|
|
16374
|
+
color: z50.string().optional()
|
|
16259
16375
|
});
|
|
16260
|
-
TaskSchema =
|
|
16261
|
-
version:
|
|
16262
|
-
id:
|
|
16263
|
-
subject:
|
|
16264
|
-
description:
|
|
16265
|
-
activeForm:
|
|
16266
|
-
status:
|
|
16267
|
-
owner:
|
|
16268
|
-
blocks:
|
|
16269
|
-
blockedBy:
|
|
16270
|
-
metadata:
|
|
16271
|
-
createdAt:
|
|
16272
|
-
updatedAt:
|
|
16273
|
-
claimedAt:
|
|
16376
|
+
TaskSchema = z50.object({
|
|
16377
|
+
version: z50.literal(1),
|
|
16378
|
+
id: z50.string(),
|
|
16379
|
+
subject: z50.string(),
|
|
16380
|
+
description: z50.string(),
|
|
16381
|
+
activeForm: z50.string().optional(),
|
|
16382
|
+
status: z50.enum(TASK_STATUSES),
|
|
16383
|
+
owner: z50.string().optional(),
|
|
16384
|
+
blocks: z50.array(z50.string()).default([]),
|
|
16385
|
+
blockedBy: z50.array(z50.string()).default([]),
|
|
16386
|
+
metadata: z50.record(z50.string(), z50.unknown()).optional(),
|
|
16387
|
+
createdAt: z50.number().int().positive(),
|
|
16388
|
+
updatedAt: z50.number().int().positive(),
|
|
16389
|
+
claimedAt: z50.number().int().positive().optional()
|
|
16274
16390
|
});
|
|
16275
|
-
RuntimeStateMemberModelSchema =
|
|
16276
|
-
providerID:
|
|
16277
|
-
modelID:
|
|
16278
|
-
variant:
|
|
16279
|
-
reasoningEffort:
|
|
16280
|
-
temperature:
|
|
16281
|
-
top_p:
|
|
16282
|
-
maxTokens:
|
|
16283
|
-
thinking:
|
|
16284
|
-
type:
|
|
16285
|
-
budgetTokens:
|
|
16391
|
+
RuntimeStateMemberModelSchema = z50.object({
|
|
16392
|
+
providerID: z50.string(),
|
|
16393
|
+
modelID: z50.string(),
|
|
16394
|
+
variant: z50.string().optional(),
|
|
16395
|
+
reasoningEffort: z50.string().optional(),
|
|
16396
|
+
temperature: z50.number().optional(),
|
|
16397
|
+
top_p: z50.number().optional(),
|
|
16398
|
+
maxTokens: z50.number().optional(),
|
|
16399
|
+
thinking: z50.object({
|
|
16400
|
+
type: z50.enum(["enabled", "disabled"]),
|
|
16401
|
+
budgetTokens: z50.number().int().positive().optional()
|
|
16286
16402
|
}).optional()
|
|
16287
16403
|
}).strict();
|
|
16288
|
-
RuntimeStateMemberSchema =
|
|
16289
|
-
name:
|
|
16290
|
-
sessionId:
|
|
16291
|
-
tmuxPaneId:
|
|
16292
|
-
tmuxGridPaneId:
|
|
16293
|
-
agentType:
|
|
16294
|
-
subagent_type:
|
|
16295
|
-
category:
|
|
16404
|
+
RuntimeStateMemberSchema = z50.object({
|
|
16405
|
+
name: z50.string(),
|
|
16406
|
+
sessionId: z50.string().optional(),
|
|
16407
|
+
tmuxPaneId: z50.string().optional(),
|
|
16408
|
+
tmuxGridPaneId: z50.string().optional(),
|
|
16409
|
+
agentType: z50.enum(["leader", "general-purpose"]),
|
|
16410
|
+
subagent_type: z50.string().optional(),
|
|
16411
|
+
category: z50.string().optional(),
|
|
16296
16412
|
model: RuntimeStateMemberModelSchema.optional(),
|
|
16297
|
-
status:
|
|
16298
|
-
color:
|
|
16299
|
-
worktreePath:
|
|
16300
|
-
lastInjectedTurnMarker:
|
|
16301
|
-
pendingInjectedMessageIds:
|
|
16413
|
+
status: z50.enum(["pending", "running", "idle", "errored", "completed", "shutdown_approved"]),
|
|
16414
|
+
color: z50.string().optional(),
|
|
16415
|
+
worktreePath: z50.string().optional(),
|
|
16416
|
+
lastInjectedTurnMarker: z50.string().optional(),
|
|
16417
|
+
pendingInjectedMessageIds: z50.array(z50.string()).default([])
|
|
16302
16418
|
}).strict();
|
|
16303
|
-
RuntimeBoundsSchema =
|
|
16304
|
-
maxMembers:
|
|
16305
|
-
maxParallelMembers:
|
|
16306
|
-
maxMessagesPerRun:
|
|
16307
|
-
maxWallClockMinutes:
|
|
16308
|
-
maxMemberTurns:
|
|
16419
|
+
RuntimeBoundsSchema = z50.object({
|
|
16420
|
+
maxMembers: z50.number().int().default(8),
|
|
16421
|
+
maxParallelMembers: z50.number().int().default(4),
|
|
16422
|
+
maxMessagesPerRun: z50.number().int().default(1e4),
|
|
16423
|
+
maxWallClockMinutes: z50.number().int().default(120),
|
|
16424
|
+
maxMemberTurns: z50.number().int().default(500)
|
|
16309
16425
|
}).strict();
|
|
16310
|
-
ShutdownRequestSchema =
|
|
16311
|
-
memberId:
|
|
16312
|
-
requesterName:
|
|
16313
|
-
requestedAt:
|
|
16314
|
-
approvedAt:
|
|
16315
|
-
rejectedReason:
|
|
16316
|
-
rejectedAt:
|
|
16426
|
+
ShutdownRequestSchema = z50.object({
|
|
16427
|
+
memberId: z50.string(),
|
|
16428
|
+
requesterName: z50.string(),
|
|
16429
|
+
requestedAt: z50.number().int().positive(),
|
|
16430
|
+
approvedAt: z50.number().int().positive().optional(),
|
|
16431
|
+
rejectedReason: z50.string().optional(),
|
|
16432
|
+
rejectedAt: z50.number().int().positive().optional()
|
|
16317
16433
|
}).strict();
|
|
16318
|
-
RuntimeStateTmuxLayoutSchema =
|
|
16319
|
-
ownedSession:
|
|
16320
|
-
targetSessionId:
|
|
16321
|
-
focusWindowId:
|
|
16322
|
-
gridWindowId:
|
|
16323
|
-
paneIds:
|
|
16434
|
+
RuntimeStateTmuxLayoutSchema = z50.object({
|
|
16435
|
+
ownedSession: z50.boolean(),
|
|
16436
|
+
targetSessionId: z50.string(),
|
|
16437
|
+
focusWindowId: z50.string().optional(),
|
|
16438
|
+
gridWindowId: z50.string().optional(),
|
|
16439
|
+
paneIds: z50.array(z50.string()).optional()
|
|
16324
16440
|
}).strict();
|
|
16325
|
-
RuntimeStateSchema =
|
|
16326
|
-
version:
|
|
16327
|
-
teamRunId:
|
|
16328
|
-
teamName:
|
|
16329
|
-
specSource:
|
|
16330
|
-
createdAt:
|
|
16331
|
-
status:
|
|
16332
|
-
leadSessionId:
|
|
16441
|
+
RuntimeStateSchema = z50.object({
|
|
16442
|
+
version: z50.literal(1),
|
|
16443
|
+
teamRunId: z50.string().uuid(),
|
|
16444
|
+
teamName: z50.string(),
|
|
16445
|
+
specSource: z50.enum(["project", "user"]),
|
|
16446
|
+
createdAt: z50.number().int().positive(),
|
|
16447
|
+
status: z50.enum(RUNTIME_STATUSES),
|
|
16448
|
+
leadSessionId: z50.string().optional(),
|
|
16333
16449
|
tmuxLayout: RuntimeStateTmuxLayoutSchema.optional(),
|
|
16334
|
-
members:
|
|
16335
|
-
shutdownRequests:
|
|
16450
|
+
members: z50.array(RuntimeStateMemberSchema),
|
|
16451
|
+
shutdownRequests: z50.array(ShutdownRequestSchema).default([]),
|
|
16336
16452
|
bounds: RuntimeBoundsSchema
|
|
16337
16453
|
});
|
|
16338
16454
|
AGENT_ELIGIBILITY_REGISTRY = {
|
|
@@ -24410,10 +24526,10 @@ var CATEGORY_MODEL_REQUIREMENTS = {
|
|
|
24410
24526
|
quick: {
|
|
24411
24527
|
fallbackChain: [
|
|
24412
24528
|
{ providers: ["kimi-for-coding"], model: "kimi-for-coding-highspeed" },
|
|
24413
|
-
{ providers: ["
|
|
24529
|
+
{ providers: ["openai-codex"], model: "gpt-5.6-luna-fast", variant: "low" },
|
|
24414
24530
|
{ providers: ["deepseek"], model: "deepseek-v4-flash", variant: "off" },
|
|
24415
24531
|
{
|
|
24416
|
-
providers: ["qwen-token-plan", "alibaba-token-plan", "bailian-coding-plan", "
|
|
24532
|
+
providers: ["qwen-token-plan", "alibaba-token-plan", "bailian-coding-plan", "vercel"],
|
|
24417
24533
|
model: "qwen3.6-flash",
|
|
24418
24534
|
variant: "low"
|
|
24419
24535
|
},
|
|
@@ -24429,6 +24545,11 @@ var CATEGORY_MODEL_REQUIREMENTS = {
|
|
|
24429
24545
|
},
|
|
24430
24546
|
"unspecified-low": {
|
|
24431
24547
|
fallbackChain: [
|
|
24548
|
+
{
|
|
24549
|
+
providers: ["xai", "github-copilot", "opencode", "vercel"],
|
|
24550
|
+
model: "grok-4.6",
|
|
24551
|
+
variant: "xhigh"
|
|
24552
|
+
},
|
|
24432
24553
|
{
|
|
24433
24554
|
providers: ["openai", "quotio-openai", "github-copilot", "opencode", "vercel"],
|
|
24434
24555
|
model: "gpt-5.6-terra",
|
|
@@ -24569,6 +24690,16 @@ function isGlmModel(model) {
|
|
|
24569
24690
|
const modelName = extractModelName(model).toLowerCase();
|
|
24570
24691
|
return modelName.includes("glm");
|
|
24571
24692
|
}
|
|
24693
|
+
var GROK_45_RE = /grok-4-5(?![0-9])/;
|
|
24694
|
+
var GROK_46_RE = /grok-4-6(?![0-9])/;
|
|
24695
|
+
function isGrok45Model(model) {
|
|
24696
|
+
const modelName = extractModelName(model).toLowerCase().replaceAll(".", "-");
|
|
24697
|
+
return GROK_45_RE.test(modelName);
|
|
24698
|
+
}
|
|
24699
|
+
function isGrok46Model(model) {
|
|
24700
|
+
const modelName = extractModelName(model).toLowerCase().replaceAll(".", "-");
|
|
24701
|
+
return GROK_46_RE.test(modelName);
|
|
24702
|
+
}
|
|
24572
24703
|
var GEMINI_PROVIDERS = ["google/", "google-vertex/"];
|
|
24573
24704
|
function isGeminiModel(model) {
|
|
24574
24705
|
if (GEMINI_PROVIDERS.some((prefix) => model.startsWith(prefix)))
|
|
@@ -27120,8 +27251,8 @@ function findUnknownKeyPaths(schema2, value) {
|
|
|
27120
27251
|
}
|
|
27121
27252
|
|
|
27122
27253
|
// packages/omo-opencode/src/config/schema/agent-names.ts
|
|
27123
|
-
import { z as
|
|
27124
|
-
var BuiltinAgentNameSchema =
|
|
27254
|
+
import { z as z13 } from "zod";
|
|
27255
|
+
var BuiltinAgentNameSchema = z13.enum([
|
|
27125
27256
|
"sisyphus",
|
|
27126
27257
|
"hephaestus",
|
|
27127
27258
|
"prometheus",
|
|
@@ -27134,7 +27265,7 @@ var BuiltinAgentNameSchema = z12.enum([
|
|
|
27134
27265
|
"atlas",
|
|
27135
27266
|
"sisyphus-junior"
|
|
27136
27267
|
]);
|
|
27137
|
-
var BuiltinSkillNameSchema =
|
|
27268
|
+
var BuiltinSkillNameSchema = z13.enum([
|
|
27138
27269
|
"playwright",
|
|
27139
27270
|
"agent-browser",
|
|
27140
27271
|
"dev-browser",
|
|
@@ -27149,7 +27280,7 @@ var BuiltinSkillNameSchema = z12.enum([
|
|
|
27149
27280
|
"visual-qa",
|
|
27150
27281
|
"team-mode"
|
|
27151
27282
|
]);
|
|
27152
|
-
var OverridableAgentNameSchema =
|
|
27283
|
+
var OverridableAgentNameSchema = z13.enum([
|
|
27153
27284
|
"build",
|
|
27154
27285
|
"plan",
|
|
27155
27286
|
"sisyphus",
|
|
@@ -27167,42 +27298,42 @@ var OverridableAgentNameSchema = z12.enum([
|
|
|
27167
27298
|
]);
|
|
27168
27299
|
// packages/omo-opencode/src/config/schema/agent-overrides.ts
|
|
27169
27300
|
init_src();
|
|
27170
|
-
import { z as
|
|
27301
|
+
import { z as z16 } from "zod";
|
|
27171
27302
|
|
|
27172
27303
|
// packages/omo-opencode/src/config/schema/fallback-models.ts
|
|
27173
27304
|
init_src();
|
|
27174
|
-
import { z as
|
|
27175
|
-
var FallbackModelObjectSchema =
|
|
27176
|
-
model:
|
|
27305
|
+
import { z as z14 } from "zod";
|
|
27306
|
+
var FallbackModelObjectSchema = z14.object({
|
|
27307
|
+
model: z14.string(),
|
|
27177
27308
|
reasoning: OmoReasoningSchema.optional(),
|
|
27178
|
-
variant:
|
|
27179
|
-
reasoningEffort:
|
|
27180
|
-
temperature:
|
|
27181
|
-
top_p:
|
|
27182
|
-
maxTokens:
|
|
27183
|
-
thinking:
|
|
27184
|
-
type:
|
|
27185
|
-
budgetTokens:
|
|
27309
|
+
variant: z14.string().optional(),
|
|
27310
|
+
reasoningEffort: z14.enum(["none", "minimal", "low", "medium", "high", "xhigh", "max"]).optional(),
|
|
27311
|
+
temperature: z14.number().min(0).max(2).optional(),
|
|
27312
|
+
top_p: z14.number().min(0).max(1).optional(),
|
|
27313
|
+
maxTokens: z14.number().optional(),
|
|
27314
|
+
thinking: z14.object({
|
|
27315
|
+
type: z14.enum(["enabled", "disabled"]),
|
|
27316
|
+
budgetTokens: z14.number().optional()
|
|
27186
27317
|
}).optional()
|
|
27187
27318
|
});
|
|
27188
|
-
var FallbackModelStringArraySchema =
|
|
27189
|
-
var FallbackModelObjectArraySchema =
|
|
27190
|
-
var FallbackModelMixedArraySchema =
|
|
27191
|
-
var FallbackModelsSchema =
|
|
27192
|
-
|
|
27319
|
+
var FallbackModelStringArraySchema = z14.array(z14.string());
|
|
27320
|
+
var FallbackModelObjectArraySchema = z14.array(FallbackModelObjectSchema);
|
|
27321
|
+
var FallbackModelMixedArraySchema = z14.array(z14.union([z14.string(), FallbackModelObjectSchema]));
|
|
27322
|
+
var FallbackModelsSchema = z14.union([
|
|
27323
|
+
z14.string(),
|
|
27193
27324
|
FallbackModelStringArraySchema,
|
|
27194
27325
|
FallbackModelObjectArraySchema,
|
|
27195
27326
|
FallbackModelMixedArraySchema
|
|
27196
27327
|
]);
|
|
27197
27328
|
|
|
27198
27329
|
// packages/omo-opencode/src/config/schema/internal/permission.ts
|
|
27199
|
-
import { z as
|
|
27200
|
-
var PermissionValueSchema =
|
|
27201
|
-
var BashPermissionSchema =
|
|
27330
|
+
import { z as z15 } from "zod";
|
|
27331
|
+
var PermissionValueSchema = z15.enum(["ask", "allow", "deny"]);
|
|
27332
|
+
var BashPermissionSchema = z15.union([
|
|
27202
27333
|
PermissionValueSchema,
|
|
27203
|
-
|
|
27334
|
+
z15.record(z15.string(), PermissionValueSchema)
|
|
27204
27335
|
]);
|
|
27205
|
-
var AgentPermissionSchema =
|
|
27336
|
+
var AgentPermissionSchema = z15.object({
|
|
27206
27337
|
edit: PermissionValueSchema.optional(),
|
|
27207
27338
|
bash: BashPermissionSchema.optional(),
|
|
27208
27339
|
webfetch: PermissionValueSchema.optional(),
|
|
@@ -27212,50 +27343,50 @@ var AgentPermissionSchema = z14.object({
|
|
|
27212
27343
|
}).catchall(PermissionValueSchema.optional());
|
|
27213
27344
|
|
|
27214
27345
|
// packages/omo-opencode/src/config/schema/agent-overrides.ts
|
|
27215
|
-
var AgentOverrideConfigSchema =
|
|
27216
|
-
model:
|
|
27217
|
-
models:
|
|
27346
|
+
var AgentOverrideConfigSchema = z16.object({
|
|
27347
|
+
model: z16.string().optional(),
|
|
27348
|
+
models: z16.array(z16.union([z16.string(), FallbackModelObjectSchema])).optional(),
|
|
27218
27349
|
fallback_models: FallbackModelsSchema.optional(),
|
|
27219
27350
|
reasoning: OmoReasoningSchema.optional(),
|
|
27220
|
-
variant:
|
|
27221
|
-
category:
|
|
27222
|
-
skills:
|
|
27223
|
-
temperature:
|
|
27224
|
-
top_p:
|
|
27225
|
-
prompt:
|
|
27226
|
-
prompt_append:
|
|
27227
|
-
tools:
|
|
27228
|
-
disable:
|
|
27229
|
-
description:
|
|
27230
|
-
mode:
|
|
27231
|
-
color:
|
|
27232
|
-
displayName:
|
|
27351
|
+
variant: z16.string().optional(),
|
|
27352
|
+
category: z16.string().optional(),
|
|
27353
|
+
skills: z16.array(z16.string()).optional(),
|
|
27354
|
+
temperature: z16.number().min(0).max(2).optional(),
|
|
27355
|
+
top_p: z16.number().min(0).max(1).optional(),
|
|
27356
|
+
prompt: z16.string().optional(),
|
|
27357
|
+
prompt_append: z16.string().optional(),
|
|
27358
|
+
tools: z16.record(z16.string(), z16.boolean()).optional(),
|
|
27359
|
+
disable: z16.boolean().optional(),
|
|
27360
|
+
description: z16.string().optional(),
|
|
27361
|
+
mode: z16.enum(["subagent", "primary", "all"]).optional(),
|
|
27362
|
+
color: z16.string().regex(/^#[0-9A-Fa-f]{6}$/).optional(),
|
|
27363
|
+
displayName: z16.string().optional(),
|
|
27233
27364
|
permission: AgentPermissionSchema.optional(),
|
|
27234
|
-
maxTokens:
|
|
27235
|
-
thinking:
|
|
27236
|
-
type:
|
|
27237
|
-
budgetTokens:
|
|
27365
|
+
maxTokens: z16.number().optional(),
|
|
27366
|
+
thinking: z16.object({
|
|
27367
|
+
type: z16.enum(["enabled", "disabled"]),
|
|
27368
|
+
budgetTokens: z16.number().optional()
|
|
27238
27369
|
}).optional(),
|
|
27239
|
-
reasoningEffort:
|
|
27240
|
-
textVerbosity:
|
|
27241
|
-
providerOptions:
|
|
27242
|
-
ultrawork:
|
|
27243
|
-
model:
|
|
27370
|
+
reasoningEffort: z16.enum(["none", "minimal", "low", "medium", "high", "xhigh", "max"]).optional(),
|
|
27371
|
+
textVerbosity: z16.enum(["low", "medium", "high"]).optional(),
|
|
27372
|
+
providerOptions: z16.record(z16.string(), z16.unknown()).optional(),
|
|
27373
|
+
ultrawork: z16.object({
|
|
27374
|
+
model: z16.string().optional(),
|
|
27244
27375
|
reasoning: OmoReasoningSchema.optional(),
|
|
27245
|
-
variant:
|
|
27376
|
+
variant: z16.string().optional()
|
|
27246
27377
|
}).optional(),
|
|
27247
|
-
compaction:
|
|
27248
|
-
model:
|
|
27378
|
+
compaction: z16.object({
|
|
27379
|
+
model: z16.string().optional(),
|
|
27249
27380
|
reasoning: OmoReasoningSchema.optional(),
|
|
27250
|
-
variant:
|
|
27381
|
+
variant: z16.string().optional()
|
|
27251
27382
|
}).optional()
|
|
27252
27383
|
});
|
|
27253
|
-
var AgentOverridesSchema =
|
|
27384
|
+
var AgentOverridesSchema = z16.object({
|
|
27254
27385
|
build: AgentOverrideConfigSchema.optional(),
|
|
27255
27386
|
plan: AgentOverrideConfigSchema.optional(),
|
|
27256
27387
|
sisyphus: AgentOverrideConfigSchema.optional(),
|
|
27257
27388
|
hephaestus: AgentOverrideConfigSchema.extend({
|
|
27258
|
-
allow_non_gpt_model:
|
|
27389
|
+
allow_non_gpt_model: z16.boolean().optional()
|
|
27259
27390
|
}).optional(),
|
|
27260
27391
|
"sisyphus-junior": AgentOverrideConfigSchema.optional(),
|
|
27261
27392
|
"OpenCode-Builder": AgentOverrideConfigSchema.optional(),
|
|
@@ -27269,72 +27400,72 @@ var AgentOverridesSchema = z15.object({
|
|
|
27269
27400
|
atlas: AgentOverrideConfigSchema.optional()
|
|
27270
27401
|
}).catchall(AgentOverrideConfigSchema.optional());
|
|
27271
27402
|
// packages/omo-opencode/src/config/schema/babysitting.ts
|
|
27272
|
-
import { z as
|
|
27273
|
-
var BabysittingConfigSchema =
|
|
27274
|
-
timeout_ms:
|
|
27403
|
+
import { z as z17 } from "zod";
|
|
27404
|
+
var BabysittingConfigSchema = z17.object({
|
|
27405
|
+
timeout_ms: z17.number().default(120000)
|
|
27275
27406
|
});
|
|
27276
27407
|
// packages/omo-opencode/src/config/schema/background-task.ts
|
|
27277
|
-
import { z as
|
|
27278
|
-
var CircuitBreakerConfigSchema =
|
|
27279
|
-
enabled:
|
|
27280
|
-
maxToolCalls:
|
|
27281
|
-
consecutiveThreshold:
|
|
27408
|
+
import { z as z18 } from "zod";
|
|
27409
|
+
var CircuitBreakerConfigSchema = z18.object({
|
|
27410
|
+
enabled: z18.boolean().optional(),
|
|
27411
|
+
maxToolCalls: z18.number().int().min(10).optional(),
|
|
27412
|
+
consecutiveThreshold: z18.number().int().min(5).optional()
|
|
27282
27413
|
});
|
|
27283
|
-
var BackgroundTaskConfigSchema =
|
|
27284
|
-
defaultConcurrency:
|
|
27285
|
-
providerConcurrency:
|
|
27286
|
-
modelConcurrency:
|
|
27287
|
-
maxDepth:
|
|
27288
|
-
staleTimeoutMs:
|
|
27289
|
-
messageStalenessTimeoutMs:
|
|
27290
|
-
taskTtlMs:
|
|
27291
|
-
sessionGoneTimeoutMs:
|
|
27292
|
-
taskCleanupDelayMs:
|
|
27293
|
-
syncPollTimeoutMs:
|
|
27294
|
-
maxToolCalls:
|
|
27414
|
+
var BackgroundTaskConfigSchema = z18.object({
|
|
27415
|
+
defaultConcurrency: z18.number().min(1).optional(),
|
|
27416
|
+
providerConcurrency: z18.record(z18.string(), z18.number().min(0)).optional(),
|
|
27417
|
+
modelConcurrency: z18.record(z18.string(), z18.number().min(0)).optional(),
|
|
27418
|
+
maxDepth: z18.number().int().min(1).optional(),
|
|
27419
|
+
staleTimeoutMs: z18.number().min(60000).optional(),
|
|
27420
|
+
messageStalenessTimeoutMs: z18.number().min(60000).optional(),
|
|
27421
|
+
taskTtlMs: z18.number().min(300000).optional(),
|
|
27422
|
+
sessionGoneTimeoutMs: z18.number().min(1e4).optional(),
|
|
27423
|
+
taskCleanupDelayMs: z18.number().min(60000).optional(),
|
|
27424
|
+
syncPollTimeoutMs: z18.number().min(60000).optional(),
|
|
27425
|
+
maxToolCalls: z18.number().int().min(10).optional(),
|
|
27295
27426
|
circuitBreaker: CircuitBreakerConfigSchema.optional()
|
|
27296
27427
|
});
|
|
27297
27428
|
// packages/omo-opencode/src/config/schema/browser-automation.ts
|
|
27298
|
-
import { z as
|
|
27299
|
-
var BrowserAutomationProviderSchema =
|
|
27429
|
+
import { z as z19 } from "zod";
|
|
27430
|
+
var BrowserAutomationProviderSchema = z19.enum([
|
|
27300
27431
|
"playwright",
|
|
27301
27432
|
"agent-browser",
|
|
27302
27433
|
"dev-browser",
|
|
27303
27434
|
"playwright-cli"
|
|
27304
27435
|
]);
|
|
27305
|
-
var BrowserAutomationConfigSchema =
|
|
27436
|
+
var BrowserAutomationConfigSchema = z19.object({
|
|
27306
27437
|
provider: BrowserAutomationProviderSchema.default("playwright"),
|
|
27307
|
-
playwright_mcp_args:
|
|
27438
|
+
playwright_mcp_args: z19.array(z19.string()).optional()
|
|
27308
27439
|
});
|
|
27309
27440
|
// packages/omo-opencode/src/config/schema/categories.ts
|
|
27310
27441
|
init_src();
|
|
27311
|
-
import { z as
|
|
27312
|
-
var CategoryConfigSchema =
|
|
27313
|
-
description:
|
|
27314
|
-
model:
|
|
27315
|
-
models:
|
|
27442
|
+
import { z as z20 } from "zod";
|
|
27443
|
+
var CategoryConfigSchema = z20.object({
|
|
27444
|
+
description: z20.string().optional(),
|
|
27445
|
+
model: z20.string().optional(),
|
|
27446
|
+
models: z20.array(z20.union([z20.string(), FallbackModelObjectSchema])).optional(),
|
|
27316
27447
|
fallback_models: FallbackModelsSchema.optional(),
|
|
27317
27448
|
reasoning: OmoReasoningSchema.optional(),
|
|
27318
|
-
variant:
|
|
27319
|
-
temperature:
|
|
27320
|
-
top_p:
|
|
27321
|
-
max_tokens:
|
|
27322
|
-
provider_options:
|
|
27323
|
-
maxTokens:
|
|
27324
|
-
thinking:
|
|
27325
|
-
type:
|
|
27326
|
-
budgetTokens:
|
|
27449
|
+
variant: z20.string().optional(),
|
|
27450
|
+
temperature: z20.number().min(0).max(2).optional(),
|
|
27451
|
+
top_p: z20.number().min(0).max(1).optional(),
|
|
27452
|
+
max_tokens: z20.number().int().positive().optional(),
|
|
27453
|
+
provider_options: z20.record(z20.string(), z20.unknown()).optional(),
|
|
27454
|
+
maxTokens: z20.number().optional(),
|
|
27455
|
+
thinking: z20.object({
|
|
27456
|
+
type: z20.enum(["enabled", "disabled"]),
|
|
27457
|
+
budgetTokens: z20.number().optional()
|
|
27327
27458
|
}).optional(),
|
|
27328
|
-
reasoningEffort:
|
|
27329
|
-
textVerbosity:
|
|
27330
|
-
tools:
|
|
27331
|
-
prompt_append:
|
|
27332
|
-
max_prompt_tokens:
|
|
27333
|
-
is_unstable_agent:
|
|
27334
|
-
disable:
|
|
27335
|
-
warn_unavailable:
|
|
27459
|
+
reasoningEffort: z20.enum(["none", "minimal", "low", "medium", "high", "xhigh", "max"]).optional(),
|
|
27460
|
+
textVerbosity: z20.enum(["low", "medium", "high"]).optional(),
|
|
27461
|
+
tools: z20.record(z20.string(), z20.boolean()).optional(),
|
|
27462
|
+
prompt_append: z20.string().optional(),
|
|
27463
|
+
max_prompt_tokens: z20.number().int().positive().optional(),
|
|
27464
|
+
is_unstable_agent: z20.boolean().optional(),
|
|
27465
|
+
disable: z20.boolean().optional(),
|
|
27466
|
+
warn_unavailable: z20.boolean().optional()
|
|
27336
27467
|
});
|
|
27337
|
-
var BuiltinCategoryNameSchema =
|
|
27468
|
+
var BuiltinCategoryNameSchema = z20.enum([
|
|
27338
27469
|
"visual-engineering",
|
|
27339
27470
|
"ultrabrain",
|
|
27340
27471
|
"deep",
|
|
@@ -27344,41 +27475,41 @@ var BuiltinCategoryNameSchema = z19.enum([
|
|
|
27344
27475
|
"unspecified-high",
|
|
27345
27476
|
"writing"
|
|
27346
27477
|
]);
|
|
27347
|
-
var CategoriesConfigSchema =
|
|
27478
|
+
var CategoriesConfigSchema = z20.record(z20.string(), CategoryConfigSchema);
|
|
27348
27479
|
// packages/omo-opencode/src/config/schema/claude-code.ts
|
|
27349
|
-
import { z as
|
|
27350
|
-
var ClaudeCodeConfigSchema =
|
|
27351
|
-
mcp:
|
|
27352
|
-
commands:
|
|
27353
|
-
skills:
|
|
27354
|
-
agents:
|
|
27355
|
-
hooks:
|
|
27356
|
-
plugins:
|
|
27357
|
-
plugins_override:
|
|
27358
|
-
anthropic_provider:
|
|
27480
|
+
import { z as z21 } from "zod";
|
|
27481
|
+
var ClaudeCodeConfigSchema = z21.object({
|
|
27482
|
+
mcp: z21.boolean().optional(),
|
|
27483
|
+
commands: z21.boolean().optional(),
|
|
27484
|
+
skills: z21.boolean().optional(),
|
|
27485
|
+
agents: z21.boolean().optional(),
|
|
27486
|
+
hooks: z21.boolean().optional(),
|
|
27487
|
+
plugins: z21.boolean().optional(),
|
|
27488
|
+
plugins_override: z21.record(z21.string(), z21.boolean()).optional(),
|
|
27489
|
+
anthropic_provider: z21.string().trim().min(1).refine((v) => !v.includes("/"), {
|
|
27359
27490
|
message: "anthropic_provider must be a provider name without '/'"
|
|
27360
27491
|
}).optional()
|
|
27361
27492
|
});
|
|
27362
27493
|
// packages/omo-opencode/src/config/schema/codegraph.ts
|
|
27363
|
-
import { z as
|
|
27364
|
-
var CodegraphConfigSchema =
|
|
27365
|
-
auto_init:
|
|
27366
|
-
auto_provision:
|
|
27367
|
-
daemon:
|
|
27368
|
-
enabled:
|
|
27369
|
-
excluded_roots:
|
|
27370
|
-
install_dir:
|
|
27371
|
-
telemetry:
|
|
27372
|
-
watch_debounce_ms:
|
|
27494
|
+
import { z as z22 } from "zod";
|
|
27495
|
+
var CodegraphConfigSchema = z22.object({
|
|
27496
|
+
auto_init: z22.boolean().default(true),
|
|
27497
|
+
auto_provision: z22.boolean().default(true),
|
|
27498
|
+
daemon: z22.boolean().default(true),
|
|
27499
|
+
enabled: z22.boolean().default(true),
|
|
27500
|
+
excluded_roots: z22.array(z22.string()).optional(),
|
|
27501
|
+
install_dir: z22.string().optional(),
|
|
27502
|
+
telemetry: z22.boolean().optional(),
|
|
27503
|
+
watch_debounce_ms: z22.number().nonnegative().optional()
|
|
27373
27504
|
});
|
|
27374
27505
|
// packages/omo-opencode/src/config/schema/comment-checker.ts
|
|
27375
|
-
import { z as
|
|
27376
|
-
var CommentCheckerConfigSchema =
|
|
27377
|
-
custom_prompt:
|
|
27506
|
+
import { z as z23 } from "zod";
|
|
27507
|
+
var CommentCheckerConfigSchema = z23.object({
|
|
27508
|
+
custom_prompt: z23.string().optional()
|
|
27378
27509
|
});
|
|
27379
27510
|
// packages/omo-opencode/src/config/schema/commands.ts
|
|
27380
|
-
import { z as
|
|
27381
|
-
var BuiltinCommandNameSchema =
|
|
27511
|
+
import { z as z24 } from "zod";
|
|
27512
|
+
var BuiltinCommandNameSchema = z24.enum([
|
|
27382
27513
|
"goal",
|
|
27383
27514
|
"refactor",
|
|
27384
27515
|
"start-work",
|
|
@@ -27387,21 +27518,21 @@ var BuiltinCommandNameSchema = z23.enum([
|
|
|
27387
27518
|
"hyperplan"
|
|
27388
27519
|
]);
|
|
27389
27520
|
// packages/omo-opencode/src/config/schema/default-mode.ts
|
|
27390
|
-
import { z as
|
|
27391
|
-
var DefaultModeConfigSchema =
|
|
27392
|
-
ultrawork:
|
|
27393
|
-
goal:
|
|
27521
|
+
import { z as z25 } from "zod";
|
|
27522
|
+
var DefaultModeConfigSchema = z25.object({
|
|
27523
|
+
ultrawork: z25.boolean().default(false),
|
|
27524
|
+
goal: z25.boolean().default(false)
|
|
27394
27525
|
});
|
|
27395
27526
|
// packages/omo-opencode/src/config/schema/dynamic-context-pruning.ts
|
|
27396
|
-
import { z as
|
|
27397
|
-
var DynamicContextPruningConfigSchema =
|
|
27398
|
-
enabled:
|
|
27399
|
-
notification:
|
|
27400
|
-
turn_protection:
|
|
27401
|
-
enabled:
|
|
27402
|
-
turns:
|
|
27527
|
+
import { z as z26 } from "zod";
|
|
27528
|
+
var DynamicContextPruningConfigSchema = z26.object({
|
|
27529
|
+
enabled: z26.boolean().default(false),
|
|
27530
|
+
notification: z26.enum(["off", "minimal", "detailed"]).default("detailed"),
|
|
27531
|
+
turn_protection: z26.object({
|
|
27532
|
+
enabled: z26.boolean().default(true),
|
|
27533
|
+
turns: z26.number().min(1).max(10).default(3)
|
|
27403
27534
|
}).optional(),
|
|
27404
|
-
protected_tools:
|
|
27535
|
+
protected_tools: z26.array(z26.string()).default([
|
|
27405
27536
|
"task",
|
|
27406
27537
|
"todowrite",
|
|
27407
27538
|
"todoread",
|
|
@@ -27410,45 +27541,45 @@ var DynamicContextPruningConfigSchema = z25.object({
|
|
|
27410
27541
|
"session_write",
|
|
27411
27542
|
"session_search"
|
|
27412
27543
|
]),
|
|
27413
|
-
strategies:
|
|
27414
|
-
deduplication:
|
|
27415
|
-
enabled:
|
|
27544
|
+
strategies: z26.object({
|
|
27545
|
+
deduplication: z26.object({
|
|
27546
|
+
enabled: z26.boolean().default(true)
|
|
27416
27547
|
}).optional(),
|
|
27417
|
-
supersede_writes:
|
|
27418
|
-
enabled:
|
|
27419
|
-
aggressive:
|
|
27548
|
+
supersede_writes: z26.object({
|
|
27549
|
+
enabled: z26.boolean().default(true),
|
|
27550
|
+
aggressive: z26.boolean().default(false)
|
|
27420
27551
|
}).optional(),
|
|
27421
|
-
purge_errors:
|
|
27422
|
-
enabled:
|
|
27423
|
-
turns:
|
|
27552
|
+
purge_errors: z26.object({
|
|
27553
|
+
enabled: z26.boolean().default(true),
|
|
27554
|
+
turns: z26.number().min(1).max(20).default(5)
|
|
27424
27555
|
}).optional()
|
|
27425
27556
|
}).optional()
|
|
27426
27557
|
});
|
|
27427
27558
|
// packages/omo-opencode/src/config/schema/experimental.ts
|
|
27428
|
-
import { z as
|
|
27429
|
-
var ExperimentalConfigSchema =
|
|
27430
|
-
aggressive_truncation:
|
|
27431
|
-
preemptive_compaction:
|
|
27432
|
-
truncate_all_tool_outputs:
|
|
27559
|
+
import { z as z27 } from "zod";
|
|
27560
|
+
var ExperimentalConfigSchema = z27.object({
|
|
27561
|
+
aggressive_truncation: z27.boolean().optional(),
|
|
27562
|
+
preemptive_compaction: z27.boolean().optional(),
|
|
27563
|
+
truncate_all_tool_outputs: z27.boolean().optional(),
|
|
27433
27564
|
dynamic_context_pruning: DynamicContextPruningConfigSchema.optional(),
|
|
27434
|
-
task_system:
|
|
27435
|
-
plugin_load_timeout_ms:
|
|
27436
|
-
safe_hook_creation:
|
|
27437
|
-
disable_omo_env:
|
|
27438
|
-
hashline_edit:
|
|
27439
|
-
model_fallback_title:
|
|
27440
|
-
max_tools:
|
|
27441
|
-
disable_live_parent_wake_routing:
|
|
27565
|
+
task_system: z27.boolean().optional(),
|
|
27566
|
+
plugin_load_timeout_ms: z27.number().min(1000).optional(),
|
|
27567
|
+
safe_hook_creation: z27.boolean().optional(),
|
|
27568
|
+
disable_omo_env: z27.boolean().optional(),
|
|
27569
|
+
hashline_edit: z27.boolean().optional(),
|
|
27570
|
+
model_fallback_title: z27.boolean().optional(),
|
|
27571
|
+
max_tools: z27.number().int().min(1).optional(),
|
|
27572
|
+
disable_live_parent_wake_routing: z27.boolean().optional()
|
|
27442
27573
|
});
|
|
27443
27574
|
// packages/omo-opencode/src/config/schema/goal.ts
|
|
27444
|
-
import { z as
|
|
27445
|
-
var GoalConfigSchema =
|
|
27446
|
-
enabled:
|
|
27447
|
-
auto_start:
|
|
27448
|
-
default_max_iterations:
|
|
27575
|
+
import { z as z28 } from "zod";
|
|
27576
|
+
var GoalConfigSchema = z28.object({
|
|
27577
|
+
enabled: z28.boolean().default(false),
|
|
27578
|
+
auto_start: z28.boolean().default(false),
|
|
27579
|
+
default_max_iterations: z28.number().min(1).max(1000).default(100)
|
|
27449
27580
|
});
|
|
27450
27581
|
// packages/skills-loader-core/src/config/git-env-prefix.ts
|
|
27451
|
-
import { z as
|
|
27582
|
+
import { z as z29 } from "zod";
|
|
27452
27583
|
var GIT_ENV_ASSIGNMENT_PATTERN = /^(?:[A-Za-z_][A-Za-z0-9_]*=[A-Za-z0-9_-]*)(?: [A-Za-z_][A-Za-z0-9_]*=[A-Za-z0-9_-]*)*$/;
|
|
27453
27584
|
var GIT_ENV_PREFIX_VALIDATION_MESSAGE = 'git_env_prefix must be empty or use shell-safe env assignments like "GIT_MASTER=1"';
|
|
27454
27585
|
function isValidGitEnvPrefix(value) {
|
|
@@ -27463,17 +27594,17 @@ function assertValidGitEnvPrefix(value) {
|
|
|
27463
27594
|
}
|
|
27464
27595
|
return value;
|
|
27465
27596
|
}
|
|
27466
|
-
var GitEnvPrefixSchema =
|
|
27597
|
+
var GitEnvPrefixSchema = z29.string().refine(isValidGitEnvPrefix, { message: GIT_ENV_PREFIX_VALIDATION_MESSAGE }).default("GIT_MASTER=1");
|
|
27467
27598
|
// packages/omo-opencode/src/config/schema/git-master.ts
|
|
27468
|
-
import { z as
|
|
27469
|
-
var GitMasterConfigSchema =
|
|
27470
|
-
commit_footer:
|
|
27471
|
-
include_co_authored_by:
|
|
27599
|
+
import { z as z30 } from "zod";
|
|
27600
|
+
var GitMasterConfigSchema = z30.object({
|
|
27601
|
+
commit_footer: z30.union([z30.boolean(), z30.string()]).default(true),
|
|
27602
|
+
include_co_authored_by: z30.boolean().default(true),
|
|
27472
27603
|
git_env_prefix: GitEnvPrefixSchema
|
|
27473
27604
|
});
|
|
27474
27605
|
// packages/omo-opencode/src/config/schema/hooks.ts
|
|
27475
|
-
import { z as
|
|
27476
|
-
var HookNameSchema =
|
|
27606
|
+
import { z as z31 } from "zod";
|
|
27607
|
+
var HookNameSchema = z31.enum([
|
|
27477
27608
|
"todo-continuation-enforcer",
|
|
27478
27609
|
"session-notification",
|
|
27479
27610
|
"comment-checker",
|
|
@@ -27532,240 +27663,240 @@ var HookNameSchema = z30.enum([
|
|
|
27532
27663
|
"legacy-plugin-toast"
|
|
27533
27664
|
]);
|
|
27534
27665
|
// packages/omo-opencode/src/config/schema/i18n.ts
|
|
27535
|
-
import { z as
|
|
27536
|
-
var I18nConfigSchema =
|
|
27537
|
-
locale:
|
|
27666
|
+
import { z as z32 } from "zod";
|
|
27667
|
+
var I18nConfigSchema = z32.object({
|
|
27668
|
+
locale: z32.string().optional()
|
|
27538
27669
|
});
|
|
27539
27670
|
// packages/omo-opencode/src/config/schema/keyword-detector.ts
|
|
27540
|
-
import { z as
|
|
27541
|
-
var KeywordTypeSchema =
|
|
27542
|
-
var KeywordDetectorConfigSchema =
|
|
27543
|
-
enabled_expansions:
|
|
27544
|
-
disabled_keywords:
|
|
27671
|
+
import { z as z33 } from "zod";
|
|
27672
|
+
var KeywordTypeSchema = z33.enum(["ultrawork", "team", "hyperplan", "hyperplan-ultrawork"]);
|
|
27673
|
+
var KeywordDetectorConfigSchema = z33.object({
|
|
27674
|
+
enabled_expansions: z33.array(KeywordTypeSchema).optional(),
|
|
27675
|
+
disabled_keywords: z33.array(KeywordTypeSchema).optional()
|
|
27545
27676
|
});
|
|
27546
27677
|
// packages/omo-opencode/src/config/schema/model-capabilities.ts
|
|
27547
|
-
import { z as
|
|
27548
|
-
var ModelCapabilitiesConfigSchema =
|
|
27549
|
-
enabled:
|
|
27550
|
-
auto_refresh_on_start:
|
|
27551
|
-
refresh_timeout_ms:
|
|
27552
|
-
source_url:
|
|
27678
|
+
import { z as z34 } from "zod";
|
|
27679
|
+
var ModelCapabilitiesConfigSchema = z34.object({
|
|
27680
|
+
enabled: z34.boolean().optional(),
|
|
27681
|
+
auto_refresh_on_start: z34.boolean().optional(),
|
|
27682
|
+
refresh_timeout_ms: z34.number().int().positive().optional(),
|
|
27683
|
+
source_url: z34.string().url().optional()
|
|
27553
27684
|
});
|
|
27554
27685
|
// packages/omo-opencode/src/config/schema/notification.ts
|
|
27555
|
-
import { z as
|
|
27556
|
-
var NotificationConfigSchema =
|
|
27557
|
-
force_enable:
|
|
27686
|
+
import { z as z35 } from "zod";
|
|
27687
|
+
var NotificationConfigSchema = z35.object({
|
|
27688
|
+
force_enable: z35.boolean().optional()
|
|
27558
27689
|
});
|
|
27559
27690
|
// packages/omo-opencode/src/config/schema/oh-my-opencode-config.ts
|
|
27560
|
-
import { z as
|
|
27691
|
+
import { z as z49 } from "zod";
|
|
27561
27692
|
|
|
27562
27693
|
// packages/omo-opencode/src/mcp/types.ts
|
|
27563
|
-
import { z as
|
|
27564
|
-
var McpNameSchema =
|
|
27565
|
-
var AnyMcpNameSchema =
|
|
27694
|
+
import { z as z36 } from "zod";
|
|
27695
|
+
var McpNameSchema = z36.enum(["websearch", "context7", "grep_app", "lsp", "codegraph"]);
|
|
27696
|
+
var AnyMcpNameSchema = z36.string().min(1);
|
|
27566
27697
|
|
|
27567
27698
|
// packages/omo-opencode/src/config/schema/agent-definitions.ts
|
|
27568
|
-
import { z as
|
|
27569
|
-
var AgentDefinitionPathSchema =
|
|
27570
|
-
var AgentDefinitionsConfigSchema =
|
|
27699
|
+
import { z as z37 } from "zod";
|
|
27700
|
+
var AgentDefinitionPathSchema = z37.string().min(1);
|
|
27701
|
+
var AgentDefinitionsConfigSchema = z37.array(AgentDefinitionPathSchema).optional();
|
|
27571
27702
|
|
|
27572
27703
|
// packages/omo-opencode/src/config/schema/openclaw.ts
|
|
27573
|
-
import { z as
|
|
27574
|
-
var OpenClawGatewaySchema =
|
|
27575
|
-
type:
|
|
27576
|
-
url:
|
|
27577
|
-
method:
|
|
27578
|
-
headers:
|
|
27579
|
-
command:
|
|
27580
|
-
timeout:
|
|
27704
|
+
import { z as z38 } from "zod";
|
|
27705
|
+
var OpenClawGatewaySchema = z38.object({
|
|
27706
|
+
type: z38.enum(["http", "command"]).default("http"),
|
|
27707
|
+
url: z38.string().optional(),
|
|
27708
|
+
method: z38.string().default("POST"),
|
|
27709
|
+
headers: z38.record(z38.string(), z38.string()).optional(),
|
|
27710
|
+
command: z38.string().optional(),
|
|
27711
|
+
timeout: z38.number().optional()
|
|
27581
27712
|
});
|
|
27582
|
-
var OpenClawHookSchema =
|
|
27583
|
-
enabled:
|
|
27584
|
-
gateway:
|
|
27585
|
-
instruction:
|
|
27713
|
+
var OpenClawHookSchema = z38.object({
|
|
27714
|
+
enabled: z38.boolean().default(true),
|
|
27715
|
+
gateway: z38.string(),
|
|
27716
|
+
instruction: z38.string()
|
|
27586
27717
|
});
|
|
27587
|
-
var OpenClawReplyListenerConfigSchema =
|
|
27588
|
-
discordBotToken:
|
|
27589
|
-
discordChannelId:
|
|
27590
|
-
discordMention:
|
|
27591
|
-
authorizedDiscordUserIds:
|
|
27592
|
-
telegramBotToken:
|
|
27593
|
-
telegramChatId:
|
|
27594
|
-
pollIntervalMs:
|
|
27595
|
-
rateLimitPerMinute:
|
|
27596
|
-
maxMessageLength:
|
|
27597
|
-
includePrefix:
|
|
27718
|
+
var OpenClawReplyListenerConfigSchema = z38.object({
|
|
27719
|
+
discordBotToken: z38.string().optional(),
|
|
27720
|
+
discordChannelId: z38.string().optional(),
|
|
27721
|
+
discordMention: z38.string().optional(),
|
|
27722
|
+
authorizedDiscordUserIds: z38.array(z38.string()).default([]),
|
|
27723
|
+
telegramBotToken: z38.string().optional(),
|
|
27724
|
+
telegramChatId: z38.string().optional(),
|
|
27725
|
+
pollIntervalMs: z38.number().default(3000),
|
|
27726
|
+
rateLimitPerMinute: z38.number().default(10),
|
|
27727
|
+
maxMessageLength: z38.number().default(500),
|
|
27728
|
+
includePrefix: z38.boolean().default(true)
|
|
27598
27729
|
});
|
|
27599
|
-
var OpenClawConfigSchema =
|
|
27600
|
-
enabled:
|
|
27601
|
-
gateways:
|
|
27602
|
-
hooks:
|
|
27730
|
+
var OpenClawConfigSchema = z38.object({
|
|
27731
|
+
enabled: z38.boolean().default(false),
|
|
27732
|
+
gateways: z38.record(z38.string(), OpenClawGatewaySchema).default({}),
|
|
27733
|
+
hooks: z38.record(z38.string(), OpenClawHookSchema).default({}),
|
|
27603
27734
|
replyListener: OpenClawReplyListenerConfigSchema.optional()
|
|
27604
27735
|
});
|
|
27605
27736
|
|
|
27606
27737
|
// packages/omo-opencode/src/config/schema/monitor.ts
|
|
27607
|
-
import { z as
|
|
27608
|
-
var MonitorConfigSchema =
|
|
27609
|
-
enabled:
|
|
27610
|
-
live_mode_enabled:
|
|
27611
|
-
allowed_commands:
|
|
27612
|
-
max_monitors_per_session:
|
|
27613
|
-
max_runtime_ms:
|
|
27614
|
-
batch_max_lines:
|
|
27615
|
-
batch_max_bytes:
|
|
27616
|
-
flush_interval_ms:
|
|
27617
|
-
ring_max_lines:
|
|
27618
|
-
line_max_bytes:
|
|
27619
|
-
pattern_max_length:
|
|
27738
|
+
import { z as z39 } from "zod";
|
|
27739
|
+
var MonitorConfigSchema = z39.object({
|
|
27740
|
+
enabled: z39.boolean().default(false),
|
|
27741
|
+
live_mode_enabled: z39.boolean().default(false),
|
|
27742
|
+
allowed_commands: z39.array(z39.string()).optional(),
|
|
27743
|
+
max_monitors_per_session: z39.number().int().min(1).max(16).default(3),
|
|
27744
|
+
max_runtime_ms: z39.number().int().min(1000).default(1800000),
|
|
27745
|
+
batch_max_lines: z39.number().int().min(1).default(50),
|
|
27746
|
+
batch_max_bytes: z39.number().int().min(1024).default(16384),
|
|
27747
|
+
flush_interval_ms: z39.number().int().min(250).default(1000),
|
|
27748
|
+
ring_max_lines: z39.number().int().min(1).default(1000),
|
|
27749
|
+
line_max_bytes: z39.number().int().min(256).default(8192),
|
|
27750
|
+
pattern_max_length: z39.number().int().min(1).default(512)
|
|
27620
27751
|
});
|
|
27621
27752
|
|
|
27622
27753
|
// packages/omo-opencode/src/config/schema/runtime-fallback.ts
|
|
27623
|
-
import { z as
|
|
27624
|
-
var RuntimeFallbackConfigSchema =
|
|
27625
|
-
enabled:
|
|
27626
|
-
retry_on_errors:
|
|
27627
|
-
max_fallback_attempts:
|
|
27628
|
-
cooldown_seconds:
|
|
27629
|
-
timeout_seconds:
|
|
27630
|
-
notify_on_fallback:
|
|
27631
|
-
restore_primary_after_cooldown:
|
|
27754
|
+
import { z as z40 } from "zod";
|
|
27755
|
+
var RuntimeFallbackConfigSchema = z40.object({
|
|
27756
|
+
enabled: z40.boolean().optional(),
|
|
27757
|
+
retry_on_errors: z40.array(z40.number()).optional(),
|
|
27758
|
+
max_fallback_attempts: z40.number().min(1).max(20).optional(),
|
|
27759
|
+
cooldown_seconds: z40.number().min(0).optional(),
|
|
27760
|
+
timeout_seconds: z40.number().min(0).optional(),
|
|
27761
|
+
notify_on_fallback: z40.boolean().optional(),
|
|
27762
|
+
restore_primary_after_cooldown: z40.boolean().optional()
|
|
27632
27763
|
});
|
|
27633
27764
|
|
|
27634
27765
|
// packages/team-core/src/config.ts
|
|
27635
|
-
import * as
|
|
27636
|
-
var TeamModeConfigSchema =
|
|
27637
|
-
enabled:
|
|
27638
|
-
tmux_visualization:
|
|
27639
|
-
max_parallel_members:
|
|
27640
|
-
max_members:
|
|
27641
|
-
max_messages_per_run:
|
|
27642
|
-
max_wall_clock_minutes:
|
|
27643
|
-
max_member_turns:
|
|
27644
|
-
base_dir:
|
|
27645
|
-
message_payload_max_bytes:
|
|
27646
|
-
recipient_unread_max_bytes:
|
|
27647
|
-
mailbox_poll_interval_ms:
|
|
27766
|
+
import * as z41 from "zod";
|
|
27767
|
+
var TeamModeConfigSchema = z41.object({
|
|
27768
|
+
enabled: z41.boolean().default(false),
|
|
27769
|
+
tmux_visualization: z41.boolean().default(false),
|
|
27770
|
+
max_parallel_members: z41.number().int().min(1).max(8).default(4),
|
|
27771
|
+
max_members: z41.number().int().min(1).max(8).default(8),
|
|
27772
|
+
max_messages_per_run: z41.number().int().min(1).default(1e4),
|
|
27773
|
+
max_wall_clock_minutes: z41.number().int().min(1).default(120),
|
|
27774
|
+
max_member_turns: z41.number().int().min(1).default(500),
|
|
27775
|
+
base_dir: z41.string().optional(),
|
|
27776
|
+
message_payload_max_bytes: z41.number().int().min(1024).default(32768),
|
|
27777
|
+
recipient_unread_max_bytes: z41.number().int().min(1024).default(262144),
|
|
27778
|
+
mailbox_poll_interval_ms: z41.number().int().min(500).default(3000)
|
|
27648
27779
|
});
|
|
27649
27780
|
// packages/omo-opencode/src/config/schema/skills.ts
|
|
27650
|
-
import { z as
|
|
27651
|
-
var SkillSourceSchema =
|
|
27652
|
-
|
|
27653
|
-
|
|
27654
|
-
path:
|
|
27655
|
-
recursive:
|
|
27656
|
-
glob:
|
|
27781
|
+
import { z as z42 } from "zod";
|
|
27782
|
+
var SkillSourceSchema = z42.union([
|
|
27783
|
+
z42.string(),
|
|
27784
|
+
z42.object({
|
|
27785
|
+
path: z42.string(),
|
|
27786
|
+
recursive: z42.boolean().optional(),
|
|
27787
|
+
glob: z42.string().optional()
|
|
27657
27788
|
})
|
|
27658
27789
|
]);
|
|
27659
|
-
var SkillDefinitionSchema =
|
|
27660
|
-
description:
|
|
27661
|
-
template:
|
|
27662
|
-
from:
|
|
27663
|
-
model:
|
|
27664
|
-
agent:
|
|
27665
|
-
subtask:
|
|
27666
|
-
"argument-hint":
|
|
27667
|
-
license:
|
|
27668
|
-
compatibility:
|
|
27669
|
-
metadata:
|
|
27670
|
-
"allowed-tools":
|
|
27671
|
-
disable:
|
|
27790
|
+
var SkillDefinitionSchema = z42.object({
|
|
27791
|
+
description: z42.string().optional(),
|
|
27792
|
+
template: z42.string().optional(),
|
|
27793
|
+
from: z42.string().optional(),
|
|
27794
|
+
model: z42.string().optional(),
|
|
27795
|
+
agent: z42.string().optional(),
|
|
27796
|
+
subtask: z42.boolean().optional(),
|
|
27797
|
+
"argument-hint": z42.string().optional(),
|
|
27798
|
+
license: z42.string().optional(),
|
|
27799
|
+
compatibility: z42.string().optional(),
|
|
27800
|
+
metadata: z42.record(z42.string(), z42.unknown()).optional(),
|
|
27801
|
+
"allowed-tools": z42.array(z42.string()).optional(),
|
|
27802
|
+
disable: z42.boolean().optional()
|
|
27672
27803
|
});
|
|
27673
|
-
var SkillEntrySchema =
|
|
27674
|
-
var SkillsConfigSchema =
|
|
27675
|
-
|
|
27676
|
-
|
|
27677
|
-
sources:
|
|
27678
|
-
enable:
|
|
27679
|
-
disable:
|
|
27804
|
+
var SkillEntrySchema = z42.union([z42.boolean(), SkillDefinitionSchema]);
|
|
27805
|
+
var SkillsConfigSchema = z42.union([
|
|
27806
|
+
z42.array(z42.string()),
|
|
27807
|
+
z42.object({
|
|
27808
|
+
sources: z42.array(SkillSourceSchema).optional(),
|
|
27809
|
+
enable: z42.array(z42.string()).optional(),
|
|
27810
|
+
disable: z42.array(z42.string()).optional()
|
|
27680
27811
|
}).catchall(SkillEntrySchema)
|
|
27681
27812
|
]);
|
|
27682
27813
|
|
|
27683
27814
|
// packages/omo-opencode/src/config/schema/sisyphus.ts
|
|
27684
|
-
import { z as
|
|
27685
|
-
var SisyphusTasksConfigSchema =
|
|
27686
|
-
storage_path:
|
|
27687
|
-
task_list_id:
|
|
27688
|
-
claude_code_compat:
|
|
27815
|
+
import { z as z43 } from "zod";
|
|
27816
|
+
var SisyphusTasksConfigSchema = z43.object({
|
|
27817
|
+
storage_path: z43.string().optional(),
|
|
27818
|
+
task_list_id: z43.string().optional(),
|
|
27819
|
+
claude_code_compat: z43.boolean().default(false)
|
|
27689
27820
|
});
|
|
27690
|
-
var SisyphusConfigSchema =
|
|
27821
|
+
var SisyphusConfigSchema = z43.object({
|
|
27691
27822
|
tasks: SisyphusTasksConfigSchema.optional()
|
|
27692
27823
|
});
|
|
27693
27824
|
|
|
27694
27825
|
// packages/omo-opencode/src/config/schema/sisyphus-agent.ts
|
|
27695
|
-
import { z as
|
|
27696
|
-
var SisyphusAgentConfigSchema =
|
|
27697
|
-
disabled:
|
|
27698
|
-
default_builder_enabled:
|
|
27699
|
-
planner_enabled:
|
|
27700
|
-
replace_plan:
|
|
27701
|
-
tdd:
|
|
27826
|
+
import { z as z44 } from "zod";
|
|
27827
|
+
var SisyphusAgentConfigSchema = z44.object({
|
|
27828
|
+
disabled: z44.boolean().optional(),
|
|
27829
|
+
default_builder_enabled: z44.boolean().optional(),
|
|
27830
|
+
planner_enabled: z44.boolean().optional(),
|
|
27831
|
+
replace_plan: z44.boolean().optional(),
|
|
27832
|
+
tdd: z44.boolean().default(true).optional()
|
|
27702
27833
|
});
|
|
27703
27834
|
|
|
27704
27835
|
// packages/omo-opencode/src/config/schema/tmux.ts
|
|
27705
27836
|
init_src3();
|
|
27706
|
-
import { z as
|
|
27707
|
-
var TmuxLayoutSchema =
|
|
27708
|
-
var TmuxIsolationSchema =
|
|
27709
|
-
var TmuxConfigSchema =
|
|
27710
|
-
enabled:
|
|
27837
|
+
import { z as z45 } from "zod";
|
|
27838
|
+
var TmuxLayoutSchema = z45.enum(TMUX_LAYOUT_VALUES);
|
|
27839
|
+
var TmuxIsolationSchema = z45.enum(TMUX_ISOLATION_VALUES);
|
|
27840
|
+
var TmuxConfigSchema = z45.object({
|
|
27841
|
+
enabled: z45.boolean().default(false),
|
|
27711
27842
|
layout: TmuxLayoutSchema.default("main-vertical"),
|
|
27712
|
-
main_pane_size:
|
|
27713
|
-
main_pane_min_width:
|
|
27714
|
-
agent_pane_min_width:
|
|
27843
|
+
main_pane_size: z45.number().min(20).max(80).default(60),
|
|
27844
|
+
main_pane_min_width: z45.number().min(40).default(120),
|
|
27845
|
+
agent_pane_min_width: z45.number().min(20).default(40),
|
|
27715
27846
|
isolation: TmuxIsolationSchema.default("inline")
|
|
27716
27847
|
});
|
|
27717
27848
|
|
|
27718
27849
|
// packages/omo-opencode/src/config/schema/tui.ts
|
|
27719
|
-
import { z as
|
|
27720
|
-
var TuiSidebarConfigSchema =
|
|
27721
|
-
enabled:
|
|
27850
|
+
import { z as z46 } from "zod";
|
|
27851
|
+
var TuiSidebarConfigSchema = z46.object({
|
|
27852
|
+
enabled: z46.boolean().default(true)
|
|
27722
27853
|
});
|
|
27723
|
-
var TuiConfigSchema =
|
|
27854
|
+
var TuiConfigSchema = z46.object({
|
|
27724
27855
|
sidebar: TuiSidebarConfigSchema.default({ enabled: true })
|
|
27725
27856
|
});
|
|
27726
27857
|
|
|
27727
27858
|
// packages/omo-opencode/src/config/schema/start-work.ts
|
|
27728
|
-
import { z as
|
|
27729
|
-
var StartWorkConfigSchema =
|
|
27730
|
-
auto_commit:
|
|
27859
|
+
import { z as z47 } from "zod";
|
|
27860
|
+
var StartWorkConfigSchema = z47.object({
|
|
27861
|
+
auto_commit: z47.boolean().default(true)
|
|
27731
27862
|
});
|
|
27732
27863
|
|
|
27733
27864
|
// packages/omo-opencode/src/config/schema/websearch.ts
|
|
27734
|
-
import { z as
|
|
27735
|
-
var WebsearchProviderSchema =
|
|
27736
|
-
var WebsearchConfigSchema =
|
|
27865
|
+
import { z as z48 } from "zod";
|
|
27866
|
+
var WebsearchProviderSchema = z48.enum(["exa", "tavily"]);
|
|
27867
|
+
var WebsearchConfigSchema = z48.object({
|
|
27737
27868
|
provider: WebsearchProviderSchema.optional()
|
|
27738
27869
|
});
|
|
27739
27870
|
|
|
27740
27871
|
// packages/omo-opencode/src/config/schema/oh-my-opencode-config.ts
|
|
27741
|
-
var OhMyOpenCodeConfigSchema =
|
|
27742
|
-
$schema:
|
|
27743
|
-
new_task_system_enabled:
|
|
27744
|
-
default_run_agent:
|
|
27745
|
-
agent_order:
|
|
27872
|
+
var OhMyOpenCodeConfigSchema = z49.object({
|
|
27873
|
+
$schema: z49.string().optional(),
|
|
27874
|
+
new_task_system_enabled: z49.boolean().optional(),
|
|
27875
|
+
default_run_agent: z49.string().optional(),
|
|
27876
|
+
agent_order: z49.array(z49.string().max(128)).max(64).optional(),
|
|
27746
27877
|
agent_definitions: AgentDefinitionsConfigSchema,
|
|
27747
|
-
disabled_mcps:
|
|
27748
|
-
disabled_agents:
|
|
27749
|
-
disabled_skills:
|
|
27750
|
-
disabled_hooks:
|
|
27751
|
-
disabled_commands:
|
|
27752
|
-
disabled_tools:
|
|
27753
|
-
disabled_providers:
|
|
27754
|
-
mcp_env_allowlist:
|
|
27755
|
-
hashline_edit:
|
|
27756
|
-
telemetry:
|
|
27757
|
-
model_fallback:
|
|
27878
|
+
disabled_mcps: z49.array(AnyMcpNameSchema).optional(),
|
|
27879
|
+
disabled_agents: z49.array(z49.string()).optional(),
|
|
27880
|
+
disabled_skills: z49.array(z49.string()).optional(),
|
|
27881
|
+
disabled_hooks: z49.array(z49.string()).optional(),
|
|
27882
|
+
disabled_commands: z49.array(BuiltinCommandNameSchema).optional(),
|
|
27883
|
+
disabled_tools: z49.array(z49.string()).optional(),
|
|
27884
|
+
disabled_providers: z49.array(z49.string()).optional(),
|
|
27885
|
+
mcp_env_allowlist: z49.array(z49.string()).optional(),
|
|
27886
|
+
hashline_edit: z49.boolean().optional(),
|
|
27887
|
+
telemetry: z49.boolean().optional().describe("Enable or disable anonymous telemetry. Default: enabled when omitted. Set to false to disable. Independent of codegraph.telemetry."),
|
|
27888
|
+
model_fallback: z49.boolean().optional(),
|
|
27758
27889
|
agents: AgentOverridesSchema.optional(),
|
|
27759
27890
|
categories: CategoriesConfigSchema.optional(),
|
|
27760
27891
|
claude_code: ClaudeCodeConfigSchema.optional(),
|
|
27761
27892
|
sisyphus_agent: SisyphusAgentConfigSchema.optional(),
|
|
27762
27893
|
comment_checker: CommentCheckerConfigSchema.optional(),
|
|
27763
27894
|
experimental: ExperimentalConfigSchema.optional(),
|
|
27764
|
-
auto_update:
|
|
27895
|
+
auto_update: z49.boolean().optional(),
|
|
27765
27896
|
skills: SkillsConfigSchema.optional(),
|
|
27766
27897
|
goal: GoalConfigSchema.optional(),
|
|
27767
|
-
ralph_loop:
|
|
27768
|
-
runtime_fallback:
|
|
27898
|
+
ralph_loop: z49.record(z49.string(), z49.unknown()).optional(),
|
|
27899
|
+
runtime_fallback: z49.union([z49.boolean(), RuntimeFallbackConfigSchema]).optional(),
|
|
27769
27900
|
background_task: BackgroundTaskConfigSchema.optional(),
|
|
27770
27901
|
notification: NotificationConfigSchema.optional(),
|
|
27771
27902
|
model_capabilities: ModelCapabilitiesConfigSchema.optional(),
|
|
@@ -27788,7 +27919,7 @@ var OhMyOpenCodeConfigSchema = z48.object({
|
|
|
27788
27919
|
sisyphus: SisyphusConfigSchema.optional(),
|
|
27789
27920
|
start_work: StartWorkConfigSchema.optional(),
|
|
27790
27921
|
default_mode: DefaultModeConfigSchema.optional(),
|
|
27791
|
-
_migrations:
|
|
27922
|
+
_migrations: z49.array(z49.string()).optional()
|
|
27792
27923
|
});
|
|
27793
27924
|
// packages/omo-opencode/src/config/validate.ts
|
|
27794
27925
|
function shortPath(configPath) {
|
|
@@ -28088,6 +28219,7 @@ init_logger2();
|
|
|
28088
28219
|
|
|
28089
28220
|
// packages/omo-opencode/src/shared/normalize-sdk-response.ts
|
|
28090
28221
|
function normalizeSDKResponse(response, fallback, options) {
|
|
28222
|
+
const fallbackIsArray = Array.isArray(fallback);
|
|
28091
28223
|
if (response == null) {
|
|
28092
28224
|
return fallback;
|
|
28093
28225
|
}
|
|
@@ -28097,14 +28229,17 @@ function normalizeSDKResponse(response, fallback, options) {
|
|
|
28097
28229
|
if (typeof response === "object" && "data" in response) {
|
|
28098
28230
|
const data = response.data;
|
|
28099
28231
|
if (data != null) {
|
|
28232
|
+
if (fallbackIsArray && !Array.isArray(data)) {
|
|
28233
|
+
return fallback;
|
|
28234
|
+
}
|
|
28100
28235
|
return data;
|
|
28101
28236
|
}
|
|
28102
|
-
if (options?.preferResponseOnMissingData === true) {
|
|
28237
|
+
if (options?.preferResponseOnMissingData === true && !fallbackIsArray) {
|
|
28103
28238
|
return response;
|
|
28104
28239
|
}
|
|
28105
28240
|
return fallback;
|
|
28106
28241
|
}
|
|
28107
|
-
if (options?.preferResponseOnMissingData === true) {
|
|
28242
|
+
if (options?.preferResponseOnMissingData === true && !fallbackIsArray) {
|
|
28108
28243
|
return response;
|
|
28109
28244
|
}
|
|
28110
28245
|
return fallback;
|
|
@@ -28758,7 +28893,7 @@ This is NOT a default choice - it's for genuinely unclassifiable moderate-effort
|
|
|
28758
28893
|
</Category_Context>
|
|
28759
28894
|
|
|
28760
28895
|
<Caller_Warning>
|
|
28761
|
-
THIS CATEGORY USES
|
|
28896
|
+
THIS CATEGORY USES GROK 4.6 (xhigh).
|
|
28762
28897
|
|
|
28763
28898
|
**PROVIDE CLEAR STRUCTURE:**
|
|
28764
28899
|
1. MUST DO: Enumerate required actions explicitly
|
|
@@ -28788,7 +28923,7 @@ var OPENAI_CATEGORIES = [
|
|
|
28788
28923
|
},
|
|
28789
28924
|
{
|
|
28790
28925
|
name: "unspecified-low",
|
|
28791
|
-
config: { model: "
|
|
28926
|
+
config: { model: "xai/grok-4.6", variant: "xhigh" },
|
|
28792
28927
|
description: "Tasks that don't fit other categories, low effort required",
|
|
28793
28928
|
promptAppend: UNSPECIFIED_LOW_CATEGORY_PROMPT_APPEND
|
|
28794
28929
|
}
|
|
@@ -84105,6 +84240,47 @@ var model_capabilities_generated_default = {
|
|
|
84105
84240
|
input: 272000,
|
|
84106
84241
|
output: 128000
|
|
84107
84242
|
}
|
|
84243
|
+
},
|
|
84244
|
+
"grok-4.6": {
|
|
84245
|
+
id: "grok-4.6",
|
|
84246
|
+
family: "grok",
|
|
84247
|
+
reasoning: true,
|
|
84248
|
+
temperature: true,
|
|
84249
|
+
toolCall: true,
|
|
84250
|
+
modalities: {
|
|
84251
|
+
input: [
|
|
84252
|
+
"text",
|
|
84253
|
+
"image"
|
|
84254
|
+
],
|
|
84255
|
+
output: [
|
|
84256
|
+
"text"
|
|
84257
|
+
]
|
|
84258
|
+
},
|
|
84259
|
+
limit: {
|
|
84260
|
+
context: 500000,
|
|
84261
|
+
output: 500000
|
|
84262
|
+
}
|
|
84263
|
+
},
|
|
84264
|
+
"xai/grok-4.6": {
|
|
84265
|
+
id: "xai/grok-4.6",
|
|
84266
|
+
family: "grok",
|
|
84267
|
+
reasoning: true,
|
|
84268
|
+
temperature: true,
|
|
84269
|
+
toolCall: true,
|
|
84270
|
+
modalities: {
|
|
84271
|
+
input: [
|
|
84272
|
+
"text",
|
|
84273
|
+
"image",
|
|
84274
|
+
"pdf"
|
|
84275
|
+
],
|
|
84276
|
+
output: [
|
|
84277
|
+
"text"
|
|
84278
|
+
]
|
|
84279
|
+
},
|
|
84280
|
+
limit: {
|
|
84281
|
+
context: 500000,
|
|
84282
|
+
output: 500000
|
|
84283
|
+
}
|
|
84108
84284
|
}
|
|
84109
84285
|
}
|
|
84110
84286
|
};
|
|
@@ -84240,21 +84416,21 @@ function restoreMessageCursor(sessionID, cursor) {
|
|
|
84240
84416
|
sessionCursors.set(sessionID, cloneCursorState(cursor));
|
|
84241
84417
|
}
|
|
84242
84418
|
// packages/omo-opencode/src/shared/shell-env.ts
|
|
84243
|
-
function detectShellType() {
|
|
84244
|
-
if (
|
|
84245
|
-
const shell =
|
|
84419
|
+
function detectShellType(platform = process.platform, env2 = process.env) {
|
|
84420
|
+
if (env2.SHELL) {
|
|
84421
|
+
const shell = env2.SHELL;
|
|
84246
84422
|
if (shell.includes("csh") || shell.includes("tcsh")) {
|
|
84247
84423
|
return "csh";
|
|
84248
84424
|
}
|
|
84249
84425
|
return "unix";
|
|
84250
84426
|
}
|
|
84251
|
-
if (
|
|
84427
|
+
if (platform === "win32" && (env2.BASH_VERSION || env2.MSYSTEM || env2.WSL_DISTRO_NAME)) {
|
|
84252
84428
|
return "unix";
|
|
84253
84429
|
}
|
|
84254
|
-
if (
|
|
84430
|
+
if (env2.PSModulePath) {
|
|
84255
84431
|
return "powershell";
|
|
84256
84432
|
}
|
|
84257
|
-
return
|
|
84433
|
+
return platform === "win32" ? "cmd" : "unix";
|
|
84258
84434
|
}
|
|
84259
84435
|
function shellEscape(value, shellType) {
|
|
84260
84436
|
if (value === "") {
|
|
@@ -85413,7 +85589,7 @@ var getUrl = ({ baseUrl, path: path7, query, querySerializer, url: _url }) => {
|
|
|
85413
85589
|
};
|
|
85414
85590
|
|
|
85415
85591
|
// node_modules/.bun/@opencode-ai+sdk@1.15.13/node_modules/@opencode-ai/sdk/dist/gen/client/utils.gen.js
|
|
85416
|
-
var createQuerySerializer = ({ allowReserved, array: array7, object:
|
|
85592
|
+
var createQuerySerializer = ({ allowReserved, array: array7, object: object13 } = {}) => {
|
|
85417
85593
|
const querySerializer = (queryParams) => {
|
|
85418
85594
|
const search = [];
|
|
85419
85595
|
if (queryParams && typeof queryParams === "object") {
|
|
@@ -85440,7 +85616,7 @@ var createQuerySerializer = ({ allowReserved, array: array7, object: object12 }
|
|
|
85440
85616
|
name,
|
|
85441
85617
|
style: "deepObject",
|
|
85442
85618
|
value,
|
|
85443
|
-
...
|
|
85619
|
+
...object13
|
|
85444
85620
|
});
|
|
85445
85621
|
if (serializedObject)
|
|
85446
85622
|
search.push(serializedObject);
|
|
@@ -98550,7 +98726,7 @@ function getCachedVersion(options = {}) {
|
|
|
98550
98726
|
// package.json
|
|
98551
98727
|
var package_default = {
|
|
98552
98728
|
name: "oh-my-opencode",
|
|
98553
|
-
version: "5.0.0-beta.
|
|
98729
|
+
version: "5.0.0-beta.10",
|
|
98554
98730
|
description: "The Best AI Agent Harness - Batteries-Included OpenCode Plugin with Multi-Model Orchestration, Parallel Background Agents, and Crafted LSP/AST Tools",
|
|
98555
98731
|
main: "./dist/index.js",
|
|
98556
98732
|
types: "dist/index.d.ts",
|
|
@@ -98686,6 +98862,7 @@ var package_default = {
|
|
|
98686
98862
|
"typecheck:script": "tsgo --noEmit -p script/tsconfig.json",
|
|
98687
98863
|
test: "bun test",
|
|
98688
98864
|
"test:codex": "bun run build:codex-install && bun run build:git-bash-mcp && bun run build:lsp-tools-mcp && bun run build:lsp-daemon && npm --prefix packages/lsp-tools-mcp test && npm --prefix packages/omo-codex/plugin ci && npm --prefix packages/omo-codex/plugin/components/ulw-loop test && bun run --cwd packages/omo-codex/plugin build && npm --prefix packages/omo-codex/plugin/components/codegraph run typecheck && npm --prefix packages/omo-codex/plugin/components/codegraph test && node scripts/check-third-party-notices.mjs --ship && bun test packages/omo-opencode/src/cli/cli-installer.platform.test.ts packages/omo-codex/src/install/codex-cache.test.ts packages/omo-codex/src/install/codex-cleanup.test.ts packages/omo-codex/src/install/codex-config-agent-cleanup.test.ts packages/omo-codex/src/install/codex-config-autonomous-features.test.ts packages/omo-codex/src/install/codex-config-reasoning.test.ts packages/omo-codex/src/install/codex-config-toml.test.ts packages/omo-codex/src/install/codex-project-local-cleanup.test.ts packages/omo-codex/src/install/install-codex-project-local-cleanup.test.ts packages/omo-codex/src/install/install-codex.test.ts packages/omo-codex/src/install/install-codex-packaged.test.ts packages/omo-codex/src/install/link-cached-plugin-agents.test.ts packages/omo-codex/src/**/*.test.ts packages/utils/src/jsonc-parser.test.ts packages/utils/src/frontmatter.test.ts packages/hashline-core/src/hash-computation.test.ts packages/hashline-core/src/smoke-untested-modules.test.ts packages/rules-engine/src/index.test.ts packages/rules-engine/src/security-boundary.test.ts packages/agents-md-core/src/injector.test.ts packages/omo-codex/plugin/components/lsp/test/package-smoke.test.ts && node --test packages/omo-codex/plugin/test/*.test.mjs packages/omo-codex/scripts/install-cache-copy.test.mjs packages/omo-codex/scripts/install-cli-args.test.mjs packages/omo-codex/scripts/install-delegated-command.test.mjs packages/omo-codex/scripts/install-config-autonomous-features.test.mjs packages/omo-codex/scripts/install-config-autonomous.test.mjs packages/omo-codex/scripts/install-config-reasoning.test.mjs packages/omo-codex/scripts/install-config.test.mjs packages/omo-codex/scripts/install-hook-targets.test.mjs packages/omo-codex/scripts/install-project-local-cleanup.test.mjs packages/omo-codex/scripts/install-lazycodex-version-stamp.test.mjs packages/omo-codex/scripts/install-local-entrypoint.test.mjs packages/omo-codex/scripts/install-local-git-bash-preflight.test.mjs packages/omo-codex/scripts/install-local.test.mjs packages/omo-codex/scripts/install-marketplace-cache.test.mjs packages/omo-codex/scripts/install-mcp-context7-runtime.test.mjs packages/omo-codex/scripts/install-mcp-runtime.test.mjs packages/omo-codex/scripts/install-packaged-local.test.mjs packages/omo-codex/scripts/install-generated-bundle.test.mjs packages/omo-codex/scripts/install-agent-links.test.mjs packages/omo-codex/scripts/install-bin-links.test.mjs",
|
|
98865
|
+
"test:fast": "bun run script/test-fast.ts",
|
|
98689
98866
|
"test:senpi": "bun run build:senpi-plugin && tsgo --noEmit -p packages/omo-senpi/tsconfig.json && bun test packages/omo-senpi",
|
|
98690
98867
|
"test:windows-codex": "bun run test:codex",
|
|
98691
98868
|
"build:git-bash-mcp": "bun run --cwd packages/git-bash-mcp build",
|
|
@@ -98730,7 +98907,7 @@ var package_default = {
|
|
|
98730
98907
|
zod: "^4.4.3"
|
|
98731
98908
|
},
|
|
98732
98909
|
devDependencies: {
|
|
98733
|
-
"@code-yeongyu/senpi": "2026.8.
|
|
98910
|
+
"@code-yeongyu/senpi": "2026.8.18-2",
|
|
98734
98911
|
"@oh-my-opencode/agents-md-core": "workspace:*",
|
|
98735
98912
|
"@oh-my-opencode/ast-grep-mcp": "workspace:*",
|
|
98736
98913
|
"@oh-my-opencode/boulder-state": "workspace:*",
|
|
@@ -98746,6 +98923,7 @@ var package_default = {
|
|
|
98746
98923
|
"@oh-my-opencode/model-core": "workspace:*",
|
|
98747
98924
|
"@oh-my-opencode/omo-codex": "workspace:*",
|
|
98748
98925
|
"@oh-my-opencode/omo-config-core": "workspace:*",
|
|
98926
|
+
"@oh-my-opencode/omo-opencode": "workspace:*",
|
|
98749
98927
|
"@oh-my-opencode/omo-senpi": "workspace:*",
|
|
98750
98928
|
"@oh-my-opencode/openclaw-core": "workspace:*",
|
|
98751
98929
|
"@oh-my-opencode/pi-goal": "workspace:*",
|
|
@@ -98761,7 +98939,7 @@ var package_default = {
|
|
|
98761
98939
|
"@oh-my-opencode/utils": "workspace:*",
|
|
98762
98940
|
"@types/js-yaml": "^4.0.9",
|
|
98763
98941
|
"@types/picomatch": "^4.0.3",
|
|
98764
|
-
"@typescript/native-preview": "7.0.0-dev.
|
|
98942
|
+
"@typescript/native-preview": "7.0.0-dev.20260707.2",
|
|
98765
98943
|
"@xterm/addon-unicode11": "^0.9.0",
|
|
98766
98944
|
"@xterm/xterm": "^6.0.0",
|
|
98767
98945
|
"bun-types": "1.3.14",
|
|
@@ -98770,24 +98948,24 @@ var package_default = {
|
|
|
98770
98948
|
typescript: "^7.0.2"
|
|
98771
98949
|
},
|
|
98772
98950
|
optionalDependencies: {
|
|
98773
|
-
"oh-my-opencode-darwin-arm64": "5.0.0-beta.
|
|
98774
|
-
"oh-my-opencode-darwin-x64": "5.0.0-beta.
|
|
98775
|
-
"oh-my-opencode-darwin-x64-baseline": "5.0.0-beta.
|
|
98776
|
-
"oh-my-opencode-linux-arm64": "5.0.0-beta.
|
|
98777
|
-
"oh-my-opencode-linux-arm64-musl": "5.0.0-beta.
|
|
98778
|
-
"oh-my-opencode-linux-x64": "5.0.0-beta.
|
|
98779
|
-
"oh-my-opencode-linux-x64-baseline": "5.0.0-beta.
|
|
98780
|
-
"oh-my-opencode-linux-x64-musl": "5.0.0-beta.
|
|
98781
|
-
"oh-my-opencode-linux-x64-musl-baseline": "5.0.0-beta.
|
|
98782
|
-
"oh-my-opencode-windows-arm64": "5.0.0-beta.
|
|
98783
|
-
"oh-my-opencode-windows-x64": "5.0.0-beta.
|
|
98784
|
-
"oh-my-opencode-windows-x64-baseline": "5.0.0-beta.
|
|
98951
|
+
"oh-my-opencode-darwin-arm64": "5.0.0-beta.10",
|
|
98952
|
+
"oh-my-opencode-darwin-x64": "5.0.0-beta.10",
|
|
98953
|
+
"oh-my-opencode-darwin-x64-baseline": "5.0.0-beta.10",
|
|
98954
|
+
"oh-my-opencode-linux-arm64": "5.0.0-beta.10",
|
|
98955
|
+
"oh-my-opencode-linux-arm64-musl": "5.0.0-beta.10",
|
|
98956
|
+
"oh-my-opencode-linux-x64": "5.0.0-beta.10",
|
|
98957
|
+
"oh-my-opencode-linux-x64-baseline": "5.0.0-beta.10",
|
|
98958
|
+
"oh-my-opencode-linux-x64-musl": "5.0.0-beta.10",
|
|
98959
|
+
"oh-my-opencode-linux-x64-musl-baseline": "5.0.0-beta.10",
|
|
98960
|
+
"oh-my-opencode-windows-arm64": "5.0.0-beta.10",
|
|
98961
|
+
"oh-my-opencode-windows-x64": "5.0.0-beta.10",
|
|
98962
|
+
"oh-my-opencode-windows-x64-baseline": "5.0.0-beta.10"
|
|
98785
98963
|
},
|
|
98786
98964
|
overrides: {
|
|
98787
|
-
"@earendil-works/pi-agent-core": "0.
|
|
98788
|
-
"@earendil-works/pi-ai": "0.
|
|
98789
|
-
"@earendil-works/pi-coding-agent": "0.
|
|
98790
|
-
"@earendil-works/pi-tui": "0.
|
|
98965
|
+
"@earendil-works/pi-agent-core": "0.84.2",
|
|
98966
|
+
"@earendil-works/pi-ai": "0.84.2",
|
|
98967
|
+
"@earendil-works/pi-coding-agent": "0.84.2",
|
|
98968
|
+
"@earendil-works/pi-tui": "0.84.2",
|
|
98791
98969
|
hono: "^4.12.18",
|
|
98792
98970
|
"@hono/node-server": "^1.19.13",
|
|
98793
98971
|
"express-rate-limit": "^8.5.1",
|
|
@@ -104850,7 +105028,7 @@ task(category="quick", load_skills=["git-master"], run_in_background=true)
|
|
|
104850
105028
|
|
|
104851
105029
|
### Goal Registration (BINDING)
|
|
104852
105030
|
|
|
104853
|
-
When the \`create_goal\` tool exists, you MUST register the run's goal with it BEFORE any implementation: the
|
|
105031
|
+
When the \`create_goal\` tool exists, you MUST register the run's goal with it BEFORE any implementation. Check \`get_goal\` first: continue a matching active goal instead of duplicating it; surface a conflicting one. Pass exactly \`objective\`, written outcome-first: the concrete thing that will be TRUE when done (an outcome, never an activity like "investigate X"), the named deliverable surfaces, the scenario contract below as success criteria (each a binary observable that CAN fail), explicit scope bounds, and one line "I'll stop right away when <the exact observable state that ends this run>". Never invent a budget or deadline the user did not state. Without the tool, record the same contract at the top of your TODO/notepad and treat it as binding.
|
|
104854
105032
|
|
|
104855
105033
|
### Pre-Implementation: Scenario Contract (BINDING)
|
|
104856
105034
|
|
|
@@ -105207,7 +105385,7 @@ task(subagent_type="plan", load_skills=[], run_in_background=false, prompt="<gat
|
|
|
105207
105385
|
|
|
105208
105386
|
### GOAL REGISTRATION (BINDING)
|
|
105209
105387
|
|
|
105210
|
-
When the \`create_goal\` tool exists, you MUST register the run's goal with it BEFORE any implementation: the
|
|
105388
|
+
When the \`create_goal\` tool exists, you MUST register the run's goal with it BEFORE any implementation. Check \`get_goal\` first: continue a matching active goal instead of duplicating it; surface a conflicting one. Pass exactly \`objective\`, written outcome-first: the concrete thing that will be TRUE when done (an outcome, never an activity like "investigate X"), the named deliverable surfaces, the scenario contract below as success criteria (each a binary observable that CAN fail), explicit scope bounds, and one line "I'll stop right away when <the exact observable state that ends this run>". Never invent a budget or deadline the user did not state. Without the tool, record the same contract at the top of your TODO/notepad and treat it as binding.
|
|
105211
105389
|
|
|
105212
105390
|
### SCENARIO CONTRACT (binding, defined BEFORE coding)
|
|
105213
105391
|
|
|
@@ -105476,7 +105654,7 @@ If a verification command is unavailable or not applicable, state the exact reas
|
|
|
105476
105654
|
|
|
105477
105655
|
## GOAL REGISTRATION
|
|
105478
105656
|
|
|
105479
|
-
When a \`create_goal\` tool exists, register the run's goal with
|
|
105657
|
+
When a \`create_goal\` tool exists, check \`get_goal\` first (continue a matching active goal; never duplicate), then register the run's goal before implementation with exactly \`objective\`, written outcome-first: the concrete outcome that will be true (never an activity), the named deliverable surfaces, the scenario contract as success criteria that can fail, scope bounds, and one WHEN TO STOP line naming the observable end state. Never invent a budget or deadline the user did not state. Without the tool, record the same contract in your working notes and treat it as binding.
|
|
105480
105658
|
|
|
105481
105659
|
## TODO DISCIPLINE
|
|
105482
105660
|
|
|
@@ -105677,7 +105855,7 @@ At start, run \`NOTE=$(mktemp -t ulw-$(date +%Y%m%d-%H%M%S).XXXXXX.md)\` and ech
|
|
|
105677
105855
|
|
|
105678
105856
|
## GOAL REGISTRATION
|
|
105679
105857
|
|
|
105680
|
-
When a \`create_goal\` tool exists, register the run's goal with
|
|
105858
|
+
When a \`create_goal\` tool exists, check \`get_goal\` first (continue a matching active goal; never duplicate), then register the run's goal before implementation with exactly \`objective\`, outcome-first: the concrete outcome that will be true (never an activity), named deliverable surfaces, the scenario contract as criteria that can fail, scope bounds, and the WHEN TO STOP line. No invented budgets or deadlines. No tool \u2192 record the same contract in the notepad and treat it as binding.
|
|
105681
105859
|
|
|
105682
105860
|
## TODO DISCIPLINE
|
|
105683
105861
|
|
|
@@ -107437,35 +107615,35 @@ import { mkdirSync as mkdirSync19, readFileSync as readFileSync49, renameSync as
|
|
|
107437
107615
|
import { join as join95 } from "path";
|
|
107438
107616
|
|
|
107439
107617
|
// packages/omo-opencode/src/hooks/goal/types.ts
|
|
107440
|
-
import { z as
|
|
107618
|
+
import { z as z51 } from "zod";
|
|
107441
107619
|
var GOAL_STATUS_VALUES = ["active", "paused", "complete"];
|
|
107442
|
-
var GoalStatusSchema =
|
|
107443
|
-
var GoalSchema =
|
|
107444
|
-
id:
|
|
107445
|
-
sessionID:
|
|
107446
|
-
objective:
|
|
107620
|
+
var GoalStatusSchema = z51.enum(GOAL_STATUS_VALUES);
|
|
107621
|
+
var GoalSchema = z51.object({
|
|
107622
|
+
id: z51.string(),
|
|
107623
|
+
sessionID: z51.string(),
|
|
107624
|
+
objective: z51.string(),
|
|
107447
107625
|
status: GoalStatusSchema,
|
|
107448
|
-
tokensUsed:
|
|
107449
|
-
timeUsedSeconds:
|
|
107450
|
-
createdAt:
|
|
107451
|
-
updatedAt:
|
|
107452
|
-
lastStartedAt:
|
|
107453
|
-
completedAt:
|
|
107626
|
+
tokensUsed: z51.number().int().nonnegative(),
|
|
107627
|
+
timeUsedSeconds: z51.number().int().nonnegative(),
|
|
107628
|
+
createdAt: z51.number().int().nonnegative(),
|
|
107629
|
+
updatedAt: z51.number().int().nonnegative(),
|
|
107630
|
+
lastStartedAt: z51.number().int().nonnegative().optional(),
|
|
107631
|
+
completedAt: z51.number().int().nonnegative().optional()
|
|
107454
107632
|
});
|
|
107455
|
-
var GoalFileSchema =
|
|
107456
|
-
version:
|
|
107633
|
+
var GoalFileSchema = z51.object({
|
|
107634
|
+
version: z51.literal(1),
|
|
107457
107635
|
goal: GoalSchema.nullable()
|
|
107458
107636
|
});
|
|
107459
|
-
var GoalToolSnapshotSchema =
|
|
107460
|
-
sessionID:
|
|
107461
|
-
objective:
|
|
107637
|
+
var GoalToolSnapshotSchema = z51.object({
|
|
107638
|
+
sessionID: z51.string(),
|
|
107639
|
+
objective: z51.string(),
|
|
107462
107640
|
status: GoalStatusSchema,
|
|
107463
|
-
tokensUsed:
|
|
107464
|
-
timeUsedSeconds:
|
|
107465
|
-
createdAt:
|
|
107466
|
-
updatedAt:
|
|
107641
|
+
tokensUsed: z51.number().int().nonnegative(),
|
|
107642
|
+
timeUsedSeconds: z51.number().int().nonnegative(),
|
|
107643
|
+
createdAt: z51.number().int().nonnegative(),
|
|
107644
|
+
updatedAt: z51.number().int().nonnegative()
|
|
107467
107645
|
});
|
|
107468
|
-
var GoalToolResponseSchema =
|
|
107646
|
+
var GoalToolResponseSchema = z51.object({
|
|
107469
107647
|
goal: GoalToolSnapshotSchema.nullable()
|
|
107470
107648
|
});
|
|
107471
107649
|
|
|
@@ -116236,6 +116414,10 @@ async function handleAtlasSessionIdle(input) {
|
|
|
116236
116414
|
return;
|
|
116237
116415
|
}
|
|
116238
116416
|
const { boulderState, progress, appendedSession } = activeBoulderSession;
|
|
116417
|
+
if (sessionState.waitingForFinalWaveApproval) {
|
|
116418
|
+
log2(`[${HOOK_NAME9}] Skipped: waiting for explicit final-wave approval`, { sessionID });
|
|
116419
|
+
return;
|
|
116420
|
+
}
|
|
116239
116421
|
if (progress.isComplete) {
|
|
116240
116422
|
await handleCompletedBoulderIdle({ ctx, options, sessionID, sessionState, boulderState });
|
|
116241
116423
|
return;
|
|
@@ -116263,10 +116445,6 @@ async function handleAtlasSessionIdle(input) {
|
|
|
116263
116445
|
const now = Date.now();
|
|
116264
116446
|
const activePlanPath = resolveBoulderPlanPath(ctx.directory, boulderState);
|
|
116265
116447
|
resetStallStateForPlanChange(sessionState, activePlanPath);
|
|
116266
|
-
if (sessionState.waitingForFinalWaveApproval) {
|
|
116267
|
-
log2(`[${HOOK_NAME9}] Skipped: waiting for explicit final-wave approval`, { sessionID });
|
|
116268
|
-
return;
|
|
116269
|
-
}
|
|
116270
116448
|
if (sessionState.stalledContinuationReason) {
|
|
116271
116449
|
log2(`[${HOOK_NAME9}] Skipped: boulder continuation stalled`, {
|
|
116272
116450
|
sessionID,
|
|
@@ -121063,6 +121241,9 @@ function createMessageUpdateHandler(deps, helpers) {
|
|
|
121063
121241
|
if (!sessionAwaitingFallbackResult.has(sessionID)) {
|
|
121064
121242
|
return;
|
|
121065
121243
|
}
|
|
121244
|
+
if (sessionRetryInFlight.has(sessionID)) {
|
|
121245
|
+
return;
|
|
121246
|
+
}
|
|
121066
121247
|
const hasVisible = await checkVisibleResponse(ctx, sessionID, info);
|
|
121067
121248
|
if (!hasVisible) {
|
|
121068
121249
|
log2(`[${HOOK_NAME13}] Assistant update observed without visible final response; keeping fallback timeout`, {
|
|
@@ -121122,14 +121303,23 @@ function createMessageUpdateHandler(deps, helpers) {
|
|
|
121122
121303
|
errorName: extractErrorName(error),
|
|
121123
121304
|
errorType: classifyErrorType(error)
|
|
121124
121305
|
});
|
|
121306
|
+
const terminalQuota402Abort = classifyErrorType(error) === "abort" && extractStatusCode(error, config3.retry_on_errors) === 402;
|
|
121125
121307
|
if (!isRetryableError(error, config3.retry_on_errors)) {
|
|
121126
|
-
|
|
121308
|
+
if (!terminalQuota402Abort) {
|
|
121309
|
+
log2(`[${HOOK_NAME13}] message.updated error not retryable, skipping fallback`, {
|
|
121310
|
+
sessionID,
|
|
121311
|
+
statusCode: extractStatusCode(error, config3.retry_on_errors),
|
|
121312
|
+
errorName: extractErrorName(error),
|
|
121313
|
+
errorType: classifyErrorType(error)
|
|
121314
|
+
});
|
|
121315
|
+
return;
|
|
121316
|
+
}
|
|
121317
|
+
log2(`[${HOOK_NAME13}] message.updated terminal-quota 402 abort with fallback chain; dispatching session-stable fallback`, {
|
|
121127
121318
|
sessionID,
|
|
121128
121319
|
statusCode: extractStatusCode(error, config3.retry_on_errors),
|
|
121129
121320
|
errorName: extractErrorName(error),
|
|
121130
121321
|
errorType: classifyErrorType(error)
|
|
121131
121322
|
});
|
|
121132
|
-
return;
|
|
121133
121323
|
}
|
|
121134
121324
|
const agent2 = info?.agent;
|
|
121135
121325
|
const resolvedAgent = await helpers.resolveAgentForSessionFromContext(sessionID, agent2);
|
|
@@ -124672,11 +124862,11 @@ function createMonitorStatusInjectorHook(monitorManager, config3) {
|
|
|
124672
124862
|
import { resolve as resolve34 } from "path";
|
|
124673
124863
|
|
|
124674
124864
|
// node_modules/.bun/@opencode-ai+plugin@1.15.13+e69f701e64847596/node_modules/@opencode-ai/plugin/dist/tool.js
|
|
124675
|
-
import { z as
|
|
124865
|
+
import { z as z52 } from "zod";
|
|
124676
124866
|
function tool(input) {
|
|
124677
124867
|
return input;
|
|
124678
124868
|
}
|
|
124679
|
-
tool.schema =
|
|
124869
|
+
tool.schema = z52;
|
|
124680
124870
|
|
|
124681
124871
|
// packages/omo-opencode/src/shared/ripgrep-cli.ts
|
|
124682
124872
|
import { spawnSync as spawnSync3 } from "child_process";
|
|
@@ -133630,55 +133820,55 @@ function isExplicitSyncRun(runInBackground) {
|
|
|
133630
133820
|
import { join as join127 } from "path";
|
|
133631
133821
|
|
|
133632
133822
|
// packages/omo-opencode/src/tools/task/types.ts
|
|
133633
|
-
import { z as
|
|
133634
|
-
var TaskStatusSchema =
|
|
133635
|
-
var TaskObjectSchema =
|
|
133636
|
-
id:
|
|
133637
|
-
subject:
|
|
133638
|
-
description:
|
|
133823
|
+
import { z as z53 } from "zod";
|
|
133824
|
+
var TaskStatusSchema = z53.enum(["pending", "in_progress", "completed", "deleted"]);
|
|
133825
|
+
var TaskObjectSchema = z53.object({
|
|
133826
|
+
id: z53.string(),
|
|
133827
|
+
subject: z53.string(),
|
|
133828
|
+
description: z53.string(),
|
|
133639
133829
|
status: TaskStatusSchema,
|
|
133640
|
-
activeForm:
|
|
133641
|
-
blocks:
|
|
133642
|
-
blockedBy:
|
|
133643
|
-
owner:
|
|
133644
|
-
metadata:
|
|
133645
|
-
repoURL:
|
|
133646
|
-
parentID:
|
|
133647
|
-
threadID:
|
|
133830
|
+
activeForm: z53.string().optional(),
|
|
133831
|
+
blocks: z53.array(z53.string()).default([]),
|
|
133832
|
+
blockedBy: z53.array(z53.string()).default([]),
|
|
133833
|
+
owner: z53.string().optional(),
|
|
133834
|
+
metadata: z53.record(z53.string(), z53.unknown()).optional(),
|
|
133835
|
+
repoURL: z53.string().optional(),
|
|
133836
|
+
parentID: z53.string().optional(),
|
|
133837
|
+
threadID: z53.string()
|
|
133648
133838
|
}).strict();
|
|
133649
|
-
var TaskCreateInputSchema =
|
|
133650
|
-
subject:
|
|
133651
|
-
description:
|
|
133652
|
-
activeForm:
|
|
133653
|
-
blocks:
|
|
133654
|
-
blockedBy:
|
|
133655
|
-
owner:
|
|
133656
|
-
metadata:
|
|
133657
|
-
repoURL:
|
|
133658
|
-
parentID:
|
|
133839
|
+
var TaskCreateInputSchema = z53.object({
|
|
133840
|
+
subject: z53.string(),
|
|
133841
|
+
description: z53.string().optional(),
|
|
133842
|
+
activeForm: z53.string().optional(),
|
|
133843
|
+
blocks: z53.array(z53.string()).optional(),
|
|
133844
|
+
blockedBy: z53.array(z53.string()).optional(),
|
|
133845
|
+
owner: z53.string().optional(),
|
|
133846
|
+
metadata: z53.record(z53.string(), z53.unknown()).optional(),
|
|
133847
|
+
repoURL: z53.string().optional(),
|
|
133848
|
+
parentID: z53.string().optional()
|
|
133659
133849
|
});
|
|
133660
|
-
var TaskListInputSchema =
|
|
133850
|
+
var TaskListInputSchema = z53.object({
|
|
133661
133851
|
status: TaskStatusSchema.optional(),
|
|
133662
|
-
parentID:
|
|
133852
|
+
parentID: z53.string().optional()
|
|
133663
133853
|
});
|
|
133664
|
-
var TaskGetInputSchema =
|
|
133665
|
-
id:
|
|
133854
|
+
var TaskGetInputSchema = z53.object({
|
|
133855
|
+
id: z53.string()
|
|
133666
133856
|
});
|
|
133667
|
-
var TaskUpdateInputSchema =
|
|
133668
|
-
id:
|
|
133669
|
-
subject:
|
|
133670
|
-
description:
|
|
133857
|
+
var TaskUpdateInputSchema = z53.object({
|
|
133858
|
+
id: z53.string(),
|
|
133859
|
+
subject: z53.string().optional(),
|
|
133860
|
+
description: z53.string().optional(),
|
|
133671
133861
|
status: TaskStatusSchema.optional(),
|
|
133672
|
-
activeForm:
|
|
133673
|
-
addBlocks:
|
|
133674
|
-
addBlockedBy:
|
|
133675
|
-
owner:
|
|
133676
|
-
metadata:
|
|
133677
|
-
repoURL:
|
|
133678
|
-
parentID:
|
|
133862
|
+
activeForm: z53.string().optional(),
|
|
133863
|
+
addBlocks: z53.array(z53.string()).optional(),
|
|
133864
|
+
addBlockedBy: z53.array(z53.string()).optional(),
|
|
133865
|
+
owner: z53.string().optional(),
|
|
133866
|
+
metadata: z53.record(z53.string(), z53.unknown()).optional(),
|
|
133867
|
+
repoURL: z53.string().optional(),
|
|
133868
|
+
parentID: z53.string().optional()
|
|
133679
133869
|
});
|
|
133680
|
-
var TaskDeleteInputSchema =
|
|
133681
|
-
id:
|
|
133870
|
+
var TaskDeleteInputSchema = z53.object({
|
|
133871
|
+
id: z53.string()
|
|
133682
133872
|
});
|
|
133683
133873
|
|
|
133684
133874
|
// packages/omo-opencode/src/features/claude-tasks/storage.ts
|
|
@@ -134524,7 +134714,7 @@ function createHashlineEditTool(ctx) {
|
|
|
134524
134714
|
// packages/omo-opencode/src/features/team-mode/tools/messaging.ts
|
|
134525
134715
|
import { randomUUID as randomUUID10 } from "crypto";
|
|
134526
134716
|
init_logger2();
|
|
134527
|
-
import { z as
|
|
134717
|
+
import { z as z54 } from "zod";
|
|
134528
134718
|
|
|
134529
134719
|
// packages/team-core/src/team-mailbox/send.ts
|
|
134530
134720
|
init_paths3();
|
|
@@ -135051,18 +135241,18 @@ async function resolveTeamRuntimeDetails(teamRunId, sessionID, config3, deps) {
|
|
|
135051
135241
|
|
|
135052
135242
|
// packages/omo-opencode/src/features/team-mode/tools/messaging.ts
|
|
135053
135243
|
var MESSAGE_TOOL_KINDS = ["message", "announcement"];
|
|
135054
|
-
var TeamReferenceArgsSchema =
|
|
135055
|
-
path:
|
|
135056
|
-
description:
|
|
135244
|
+
var TeamReferenceArgsSchema = z54.object({
|
|
135245
|
+
path: z54.string().min(1),
|
|
135246
|
+
description: z54.string().optional()
|
|
135057
135247
|
});
|
|
135058
|
-
var TeamSendMessageArgsSchema =
|
|
135059
|
-
teamRunId:
|
|
135060
|
-
to:
|
|
135061
|
-
body:
|
|
135062
|
-
kind:
|
|
135063
|
-
correlationId:
|
|
135064
|
-
summary:
|
|
135065
|
-
references:
|
|
135248
|
+
var TeamSendMessageArgsSchema = z54.object({
|
|
135249
|
+
teamRunId: z54.string().min(1),
|
|
135250
|
+
to: z54.string().min(1),
|
|
135251
|
+
body: z54.string(),
|
|
135252
|
+
kind: z54.enum(MESSAGE_TOOL_KINDS).optional(),
|
|
135253
|
+
correlationId: z54.preprocess((value) => value === "" ? undefined : value, z54.uuid().optional()),
|
|
135254
|
+
summary: z54.string().optional(),
|
|
135255
|
+
references: z54.array(TeamReferenceArgsSchema).optional()
|
|
135066
135256
|
});
|
|
135067
135257
|
function createTeamSendMessageTool(config3, client3, deps = defaultTeamSendMessageToolDeps) {
|
|
135068
135258
|
return tool({
|
|
@@ -143377,63 +143567,63 @@ function getLiteralValue(schema2) {
|
|
|
143377
143567
|
}
|
|
143378
143568
|
|
|
143379
143569
|
// node_modules/.bun/@modelcontextprotocol+sdk@1.30.0/node_modules/@modelcontextprotocol/sdk/dist/esm/types.js
|
|
143380
|
-
import * as
|
|
143570
|
+
import * as z55 from "zod/v4";
|
|
143381
143571
|
var LATEST_PROTOCOL_VERSION = "2025-11-25";
|
|
143382
143572
|
var SUPPORTED_PROTOCOL_VERSIONS = [LATEST_PROTOCOL_VERSION, "2025-06-18", "2025-03-26", "2024-11-05", "2024-10-07"];
|
|
143383
143573
|
var RELATED_TASK_META_KEY = "io.modelcontextprotocol/related-task";
|
|
143384
143574
|
var JSONRPC_VERSION = "2.0";
|
|
143385
|
-
var AssertObjectSchema =
|
|
143386
|
-
var ProgressTokenSchema =
|
|
143387
|
-
var CursorSchema =
|
|
143388
|
-
var TaskCreationParamsSchema =
|
|
143389
|
-
ttl:
|
|
143390
|
-
pollInterval:
|
|
143575
|
+
var AssertObjectSchema = z55.custom((v) => v !== null && (typeof v === "object" || typeof v === "function"));
|
|
143576
|
+
var ProgressTokenSchema = z55.union([z55.string(), z55.number().int()]);
|
|
143577
|
+
var CursorSchema = z55.string();
|
|
143578
|
+
var TaskCreationParamsSchema = z55.looseObject({
|
|
143579
|
+
ttl: z55.number().optional(),
|
|
143580
|
+
pollInterval: z55.number().optional()
|
|
143391
143581
|
});
|
|
143392
|
-
var TaskMetadataSchema =
|
|
143393
|
-
ttl:
|
|
143582
|
+
var TaskMetadataSchema = z55.object({
|
|
143583
|
+
ttl: z55.number().optional()
|
|
143394
143584
|
});
|
|
143395
|
-
var RelatedTaskMetadataSchema =
|
|
143396
|
-
taskId:
|
|
143585
|
+
var RelatedTaskMetadataSchema = z55.object({
|
|
143586
|
+
taskId: z55.string()
|
|
143397
143587
|
});
|
|
143398
|
-
var RequestMetaSchema =
|
|
143588
|
+
var RequestMetaSchema = z55.looseObject({
|
|
143399
143589
|
progressToken: ProgressTokenSchema.optional(),
|
|
143400
143590
|
[RELATED_TASK_META_KEY]: RelatedTaskMetadataSchema.optional()
|
|
143401
143591
|
});
|
|
143402
|
-
var BaseRequestParamsSchema =
|
|
143592
|
+
var BaseRequestParamsSchema = z55.object({
|
|
143403
143593
|
_meta: RequestMetaSchema.optional()
|
|
143404
143594
|
});
|
|
143405
143595
|
var TaskAugmentedRequestParamsSchema = BaseRequestParamsSchema.extend({
|
|
143406
143596
|
task: TaskMetadataSchema.optional()
|
|
143407
143597
|
});
|
|
143408
143598
|
var isTaskAugmentedRequestParams = (value) => TaskAugmentedRequestParamsSchema.safeParse(value).success;
|
|
143409
|
-
var RequestSchema =
|
|
143410
|
-
method:
|
|
143599
|
+
var RequestSchema = z55.object({
|
|
143600
|
+
method: z55.string(),
|
|
143411
143601
|
params: BaseRequestParamsSchema.loose().optional()
|
|
143412
143602
|
});
|
|
143413
|
-
var NotificationsParamsSchema =
|
|
143603
|
+
var NotificationsParamsSchema = z55.object({
|
|
143414
143604
|
_meta: RequestMetaSchema.optional()
|
|
143415
143605
|
});
|
|
143416
|
-
var NotificationSchema =
|
|
143417
|
-
method:
|
|
143606
|
+
var NotificationSchema = z55.object({
|
|
143607
|
+
method: z55.string(),
|
|
143418
143608
|
params: NotificationsParamsSchema.loose().optional()
|
|
143419
143609
|
});
|
|
143420
|
-
var ResultSchema =
|
|
143610
|
+
var ResultSchema = z55.looseObject({
|
|
143421
143611
|
_meta: RequestMetaSchema.optional()
|
|
143422
143612
|
});
|
|
143423
|
-
var RequestIdSchema =
|
|
143424
|
-
var JSONRPCRequestSchema =
|
|
143425
|
-
jsonrpc:
|
|
143613
|
+
var RequestIdSchema = z55.union([z55.string(), z55.number().int()]);
|
|
143614
|
+
var JSONRPCRequestSchema = z55.object({
|
|
143615
|
+
jsonrpc: z55.literal(JSONRPC_VERSION),
|
|
143426
143616
|
id: RequestIdSchema,
|
|
143427
143617
|
...RequestSchema.shape
|
|
143428
143618
|
}).strict();
|
|
143429
143619
|
var isJSONRPCRequest = (value) => JSONRPCRequestSchema.safeParse(value).success;
|
|
143430
|
-
var JSONRPCNotificationSchema =
|
|
143431
|
-
jsonrpc:
|
|
143620
|
+
var JSONRPCNotificationSchema = z55.object({
|
|
143621
|
+
jsonrpc: z55.literal(JSONRPC_VERSION),
|
|
143432
143622
|
...NotificationSchema.shape
|
|
143433
143623
|
}).strict();
|
|
143434
143624
|
var isJSONRPCNotification = (value) => JSONRPCNotificationSchema.safeParse(value).success;
|
|
143435
|
-
var JSONRPCResultResponseSchema =
|
|
143436
|
-
jsonrpc:
|
|
143625
|
+
var JSONRPCResultResponseSchema = z55.object({
|
|
143626
|
+
jsonrpc: z55.literal(JSONRPC_VERSION),
|
|
143437
143627
|
id: RequestIdSchema,
|
|
143438
143628
|
result: ResultSchema
|
|
143439
143629
|
}).strict();
|
|
@@ -143449,153 +143639,153 @@ var ErrorCode;
|
|
|
143449
143639
|
ErrorCode2[ErrorCode2["InternalError"] = -32603] = "InternalError";
|
|
143450
143640
|
ErrorCode2[ErrorCode2["UrlElicitationRequired"] = -32042] = "UrlElicitationRequired";
|
|
143451
143641
|
})(ErrorCode || (ErrorCode = {}));
|
|
143452
|
-
var JSONRPCErrorResponseSchema =
|
|
143453
|
-
jsonrpc:
|
|
143642
|
+
var JSONRPCErrorResponseSchema = z55.object({
|
|
143643
|
+
jsonrpc: z55.literal(JSONRPC_VERSION),
|
|
143454
143644
|
id: RequestIdSchema.optional(),
|
|
143455
|
-
error:
|
|
143456
|
-
code:
|
|
143457
|
-
message:
|
|
143458
|
-
data:
|
|
143645
|
+
error: z55.object({
|
|
143646
|
+
code: z55.number().int(),
|
|
143647
|
+
message: z55.string(),
|
|
143648
|
+
data: z55.unknown().optional()
|
|
143459
143649
|
})
|
|
143460
143650
|
}).strict();
|
|
143461
143651
|
var isJSONRPCErrorResponse = (value) => JSONRPCErrorResponseSchema.safeParse(value).success;
|
|
143462
|
-
var JSONRPCMessageSchema =
|
|
143652
|
+
var JSONRPCMessageSchema = z55.union([
|
|
143463
143653
|
JSONRPCRequestSchema,
|
|
143464
143654
|
JSONRPCNotificationSchema,
|
|
143465
143655
|
JSONRPCResultResponseSchema,
|
|
143466
143656
|
JSONRPCErrorResponseSchema
|
|
143467
143657
|
]);
|
|
143468
|
-
var JSONRPCResponseSchema =
|
|
143658
|
+
var JSONRPCResponseSchema = z55.union([JSONRPCResultResponseSchema, JSONRPCErrorResponseSchema]);
|
|
143469
143659
|
var EmptyResultSchema = ResultSchema.strict();
|
|
143470
143660
|
var CancelledNotificationParamsSchema = NotificationsParamsSchema.extend({
|
|
143471
143661
|
requestId: RequestIdSchema.optional(),
|
|
143472
|
-
reason:
|
|
143662
|
+
reason: z55.string().optional()
|
|
143473
143663
|
});
|
|
143474
143664
|
var CancelledNotificationSchema = NotificationSchema.extend({
|
|
143475
|
-
method:
|
|
143665
|
+
method: z55.literal("notifications/cancelled"),
|
|
143476
143666
|
params: CancelledNotificationParamsSchema
|
|
143477
143667
|
});
|
|
143478
|
-
var IconSchema =
|
|
143479
|
-
src:
|
|
143480
|
-
mimeType:
|
|
143481
|
-
sizes:
|
|
143482
|
-
theme:
|
|
143668
|
+
var IconSchema = z55.object({
|
|
143669
|
+
src: z55.string(),
|
|
143670
|
+
mimeType: z55.string().optional(),
|
|
143671
|
+
sizes: z55.array(z55.string()).optional(),
|
|
143672
|
+
theme: z55.enum(["light", "dark"]).optional()
|
|
143483
143673
|
});
|
|
143484
|
-
var IconsSchema =
|
|
143485
|
-
icons:
|
|
143674
|
+
var IconsSchema = z55.object({
|
|
143675
|
+
icons: z55.array(IconSchema).optional()
|
|
143486
143676
|
});
|
|
143487
|
-
var BaseMetadataSchema =
|
|
143488
|
-
name:
|
|
143489
|
-
title:
|
|
143677
|
+
var BaseMetadataSchema = z55.object({
|
|
143678
|
+
name: z55.string(),
|
|
143679
|
+
title: z55.string().optional()
|
|
143490
143680
|
});
|
|
143491
143681
|
var ImplementationSchema = BaseMetadataSchema.extend({
|
|
143492
143682
|
...BaseMetadataSchema.shape,
|
|
143493
143683
|
...IconsSchema.shape,
|
|
143494
|
-
version:
|
|
143495
|
-
websiteUrl:
|
|
143496
|
-
description:
|
|
143684
|
+
version: z55.string(),
|
|
143685
|
+
websiteUrl: z55.string().optional(),
|
|
143686
|
+
description: z55.string().optional()
|
|
143497
143687
|
});
|
|
143498
|
-
var FormElicitationCapabilitySchema =
|
|
143499
|
-
applyDefaults:
|
|
143500
|
-
}),
|
|
143501
|
-
var ElicitationCapabilitySchema =
|
|
143688
|
+
var FormElicitationCapabilitySchema = z55.intersection(z55.object({
|
|
143689
|
+
applyDefaults: z55.boolean().optional()
|
|
143690
|
+
}), z55.record(z55.string(), z55.unknown()));
|
|
143691
|
+
var ElicitationCapabilitySchema = z55.preprocess((value) => {
|
|
143502
143692
|
if (value && typeof value === "object" && !Array.isArray(value)) {
|
|
143503
143693
|
if (Object.keys(value).length === 0) {
|
|
143504
143694
|
return { form: {} };
|
|
143505
143695
|
}
|
|
143506
143696
|
}
|
|
143507
143697
|
return value;
|
|
143508
|
-
},
|
|
143698
|
+
}, z55.intersection(z55.object({
|
|
143509
143699
|
form: FormElicitationCapabilitySchema.optional(),
|
|
143510
143700
|
url: AssertObjectSchema.optional()
|
|
143511
|
-
}),
|
|
143512
|
-
var ClientTasksCapabilitySchema =
|
|
143701
|
+
}), z55.record(z55.string(), z55.unknown()).optional()));
|
|
143702
|
+
var ClientTasksCapabilitySchema = z55.looseObject({
|
|
143513
143703
|
list: AssertObjectSchema.optional(),
|
|
143514
143704
|
cancel: AssertObjectSchema.optional(),
|
|
143515
|
-
requests:
|
|
143516
|
-
sampling:
|
|
143705
|
+
requests: z55.looseObject({
|
|
143706
|
+
sampling: z55.looseObject({
|
|
143517
143707
|
createMessage: AssertObjectSchema.optional()
|
|
143518
143708
|
}).optional(),
|
|
143519
|
-
elicitation:
|
|
143709
|
+
elicitation: z55.looseObject({
|
|
143520
143710
|
create: AssertObjectSchema.optional()
|
|
143521
143711
|
}).optional()
|
|
143522
143712
|
}).optional()
|
|
143523
143713
|
});
|
|
143524
|
-
var ServerTasksCapabilitySchema =
|
|
143714
|
+
var ServerTasksCapabilitySchema = z55.looseObject({
|
|
143525
143715
|
list: AssertObjectSchema.optional(),
|
|
143526
143716
|
cancel: AssertObjectSchema.optional(),
|
|
143527
|
-
requests:
|
|
143528
|
-
tools:
|
|
143717
|
+
requests: z55.looseObject({
|
|
143718
|
+
tools: z55.looseObject({
|
|
143529
143719
|
call: AssertObjectSchema.optional()
|
|
143530
143720
|
}).optional()
|
|
143531
143721
|
}).optional()
|
|
143532
143722
|
});
|
|
143533
|
-
var ClientCapabilitiesSchema =
|
|
143534
|
-
experimental:
|
|
143535
|
-
sampling:
|
|
143723
|
+
var ClientCapabilitiesSchema = z55.object({
|
|
143724
|
+
experimental: z55.record(z55.string(), AssertObjectSchema).optional(),
|
|
143725
|
+
sampling: z55.object({
|
|
143536
143726
|
context: AssertObjectSchema.optional(),
|
|
143537
143727
|
tools: AssertObjectSchema.optional()
|
|
143538
143728
|
}).optional(),
|
|
143539
143729
|
elicitation: ElicitationCapabilitySchema.optional(),
|
|
143540
|
-
roots:
|
|
143541
|
-
listChanged:
|
|
143730
|
+
roots: z55.object({
|
|
143731
|
+
listChanged: z55.boolean().optional()
|
|
143542
143732
|
}).optional(),
|
|
143543
143733
|
tasks: ClientTasksCapabilitySchema.optional(),
|
|
143544
|
-
extensions:
|
|
143734
|
+
extensions: z55.record(z55.string(), AssertObjectSchema).optional()
|
|
143545
143735
|
});
|
|
143546
143736
|
var InitializeRequestParamsSchema = BaseRequestParamsSchema.extend({
|
|
143547
|
-
protocolVersion:
|
|
143737
|
+
protocolVersion: z55.string(),
|
|
143548
143738
|
capabilities: ClientCapabilitiesSchema,
|
|
143549
143739
|
clientInfo: ImplementationSchema
|
|
143550
143740
|
});
|
|
143551
143741
|
var InitializeRequestSchema = RequestSchema.extend({
|
|
143552
|
-
method:
|
|
143742
|
+
method: z55.literal("initialize"),
|
|
143553
143743
|
params: InitializeRequestParamsSchema
|
|
143554
143744
|
});
|
|
143555
|
-
var ServerCapabilitiesSchema =
|
|
143556
|
-
experimental:
|
|
143745
|
+
var ServerCapabilitiesSchema = z55.object({
|
|
143746
|
+
experimental: z55.record(z55.string(), AssertObjectSchema).optional(),
|
|
143557
143747
|
logging: AssertObjectSchema.optional(),
|
|
143558
143748
|
completions: AssertObjectSchema.optional(),
|
|
143559
|
-
prompts:
|
|
143560
|
-
listChanged:
|
|
143749
|
+
prompts: z55.object({
|
|
143750
|
+
listChanged: z55.boolean().optional()
|
|
143561
143751
|
}).optional(),
|
|
143562
|
-
resources:
|
|
143563
|
-
subscribe:
|
|
143564
|
-
listChanged:
|
|
143752
|
+
resources: z55.object({
|
|
143753
|
+
subscribe: z55.boolean().optional(),
|
|
143754
|
+
listChanged: z55.boolean().optional()
|
|
143565
143755
|
}).optional(),
|
|
143566
|
-
tools:
|
|
143567
|
-
listChanged:
|
|
143756
|
+
tools: z55.object({
|
|
143757
|
+
listChanged: z55.boolean().optional()
|
|
143568
143758
|
}).optional(),
|
|
143569
143759
|
tasks: ServerTasksCapabilitySchema.optional(),
|
|
143570
|
-
extensions:
|
|
143760
|
+
extensions: z55.record(z55.string(), AssertObjectSchema).optional()
|
|
143571
143761
|
});
|
|
143572
143762
|
var InitializeResultSchema = ResultSchema.extend({
|
|
143573
|
-
protocolVersion:
|
|
143763
|
+
protocolVersion: z55.string(),
|
|
143574
143764
|
capabilities: ServerCapabilitiesSchema,
|
|
143575
143765
|
serverInfo: ImplementationSchema,
|
|
143576
|
-
instructions:
|
|
143766
|
+
instructions: z55.string().optional()
|
|
143577
143767
|
});
|
|
143578
143768
|
var InitializedNotificationSchema = NotificationSchema.extend({
|
|
143579
|
-
method:
|
|
143769
|
+
method: z55.literal("notifications/initialized"),
|
|
143580
143770
|
params: NotificationsParamsSchema.optional()
|
|
143581
143771
|
});
|
|
143582
143772
|
var isInitializedNotification = (value) => InitializedNotificationSchema.safeParse(value).success;
|
|
143583
143773
|
var PingRequestSchema = RequestSchema.extend({
|
|
143584
|
-
method:
|
|
143774
|
+
method: z55.literal("ping"),
|
|
143585
143775
|
params: BaseRequestParamsSchema.optional()
|
|
143586
143776
|
});
|
|
143587
|
-
var ProgressSchema =
|
|
143588
|
-
progress:
|
|
143589
|
-
total:
|
|
143590
|
-
message:
|
|
143777
|
+
var ProgressSchema = z55.object({
|
|
143778
|
+
progress: z55.number(),
|
|
143779
|
+
total: z55.optional(z55.number()),
|
|
143780
|
+
message: z55.optional(z55.string())
|
|
143591
143781
|
});
|
|
143592
|
-
var ProgressNotificationParamsSchema =
|
|
143782
|
+
var ProgressNotificationParamsSchema = z55.object({
|
|
143593
143783
|
...NotificationsParamsSchema.shape,
|
|
143594
143784
|
...ProgressSchema.shape,
|
|
143595
143785
|
progressToken: ProgressTokenSchema
|
|
143596
143786
|
});
|
|
143597
143787
|
var ProgressNotificationSchema = NotificationSchema.extend({
|
|
143598
|
-
method:
|
|
143788
|
+
method: z55.literal("notifications/progress"),
|
|
143599
143789
|
params: ProgressNotificationParamsSchema
|
|
143600
143790
|
});
|
|
143601
143791
|
var PaginatedRequestParamsSchema = BaseRequestParamsSchema.extend({
|
|
@@ -143607,60 +143797,60 @@ var PaginatedRequestSchema = RequestSchema.extend({
|
|
|
143607
143797
|
var PaginatedResultSchema = ResultSchema.extend({
|
|
143608
143798
|
nextCursor: CursorSchema.optional()
|
|
143609
143799
|
});
|
|
143610
|
-
var TaskStatusSchema2 =
|
|
143611
|
-
var TaskSchema2 =
|
|
143612
|
-
taskId:
|
|
143800
|
+
var TaskStatusSchema2 = z55.enum(["working", "input_required", "completed", "failed", "cancelled"]);
|
|
143801
|
+
var TaskSchema2 = z55.object({
|
|
143802
|
+
taskId: z55.string(),
|
|
143613
143803
|
status: TaskStatusSchema2,
|
|
143614
|
-
ttl:
|
|
143615
|
-
createdAt:
|
|
143616
|
-
lastUpdatedAt:
|
|
143617
|
-
pollInterval:
|
|
143618
|
-
statusMessage:
|
|
143804
|
+
ttl: z55.union([z55.number(), z55.null()]),
|
|
143805
|
+
createdAt: z55.string(),
|
|
143806
|
+
lastUpdatedAt: z55.string(),
|
|
143807
|
+
pollInterval: z55.optional(z55.number()),
|
|
143808
|
+
statusMessage: z55.optional(z55.string())
|
|
143619
143809
|
});
|
|
143620
143810
|
var CreateTaskResultSchema = ResultSchema.extend({
|
|
143621
143811
|
task: TaskSchema2
|
|
143622
143812
|
});
|
|
143623
143813
|
var TaskStatusNotificationParamsSchema = NotificationsParamsSchema.merge(TaskSchema2);
|
|
143624
143814
|
var TaskStatusNotificationSchema = NotificationSchema.extend({
|
|
143625
|
-
method:
|
|
143815
|
+
method: z55.literal("notifications/tasks/status"),
|
|
143626
143816
|
params: TaskStatusNotificationParamsSchema
|
|
143627
143817
|
});
|
|
143628
143818
|
var GetTaskRequestSchema = RequestSchema.extend({
|
|
143629
|
-
method:
|
|
143819
|
+
method: z55.literal("tasks/get"),
|
|
143630
143820
|
params: BaseRequestParamsSchema.extend({
|
|
143631
|
-
taskId:
|
|
143821
|
+
taskId: z55.string()
|
|
143632
143822
|
})
|
|
143633
143823
|
});
|
|
143634
143824
|
var GetTaskResultSchema = ResultSchema.merge(TaskSchema2);
|
|
143635
143825
|
var GetTaskPayloadRequestSchema = RequestSchema.extend({
|
|
143636
|
-
method:
|
|
143826
|
+
method: z55.literal("tasks/result"),
|
|
143637
143827
|
params: BaseRequestParamsSchema.extend({
|
|
143638
|
-
taskId:
|
|
143828
|
+
taskId: z55.string()
|
|
143639
143829
|
})
|
|
143640
143830
|
});
|
|
143641
143831
|
var GetTaskPayloadResultSchema = ResultSchema.loose();
|
|
143642
143832
|
var ListTasksRequestSchema = PaginatedRequestSchema.extend({
|
|
143643
|
-
method:
|
|
143833
|
+
method: z55.literal("tasks/list")
|
|
143644
143834
|
});
|
|
143645
143835
|
var ListTasksResultSchema = PaginatedResultSchema.extend({
|
|
143646
|
-
tasks:
|
|
143836
|
+
tasks: z55.array(TaskSchema2)
|
|
143647
143837
|
});
|
|
143648
143838
|
var CancelTaskRequestSchema = RequestSchema.extend({
|
|
143649
|
-
method:
|
|
143839
|
+
method: z55.literal("tasks/cancel"),
|
|
143650
143840
|
params: BaseRequestParamsSchema.extend({
|
|
143651
|
-
taskId:
|
|
143841
|
+
taskId: z55.string()
|
|
143652
143842
|
})
|
|
143653
143843
|
});
|
|
143654
143844
|
var CancelTaskResultSchema = ResultSchema.merge(TaskSchema2);
|
|
143655
|
-
var ResourceContentsSchema =
|
|
143656
|
-
uri:
|
|
143657
|
-
mimeType:
|
|
143658
|
-
_meta:
|
|
143845
|
+
var ResourceContentsSchema = z55.object({
|
|
143846
|
+
uri: z55.string(),
|
|
143847
|
+
mimeType: z55.optional(z55.string()),
|
|
143848
|
+
_meta: z55.record(z55.string(), z55.unknown()).optional()
|
|
143659
143849
|
});
|
|
143660
143850
|
var TextResourceContentsSchema = ResourceContentsSchema.extend({
|
|
143661
|
-
text:
|
|
143851
|
+
text: z55.string()
|
|
143662
143852
|
});
|
|
143663
|
-
var Base64Schema =
|
|
143853
|
+
var Base64Schema = z55.string().refine((val) => {
|
|
143664
143854
|
try {
|
|
143665
143855
|
atob(val);
|
|
143666
143856
|
return true;
|
|
@@ -143671,447 +143861,447 @@ var Base64Schema = z54.string().refine((val) => {
|
|
|
143671
143861
|
var BlobResourceContentsSchema = ResourceContentsSchema.extend({
|
|
143672
143862
|
blob: Base64Schema
|
|
143673
143863
|
});
|
|
143674
|
-
var RoleSchema =
|
|
143675
|
-
var AnnotationsSchema =
|
|
143676
|
-
audience:
|
|
143677
|
-
priority:
|
|
143678
|
-
lastModified:
|
|
143864
|
+
var RoleSchema = z55.enum(["user", "assistant"]);
|
|
143865
|
+
var AnnotationsSchema = z55.object({
|
|
143866
|
+
audience: z55.array(RoleSchema).optional(),
|
|
143867
|
+
priority: z55.number().min(0).max(1).optional(),
|
|
143868
|
+
lastModified: z55.iso.datetime({ offset: true }).optional()
|
|
143679
143869
|
});
|
|
143680
|
-
var ResourceSchema =
|
|
143870
|
+
var ResourceSchema = z55.object({
|
|
143681
143871
|
...BaseMetadataSchema.shape,
|
|
143682
143872
|
...IconsSchema.shape,
|
|
143683
|
-
uri:
|
|
143684
|
-
description:
|
|
143685
|
-
mimeType:
|
|
143686
|
-
size:
|
|
143873
|
+
uri: z55.string(),
|
|
143874
|
+
description: z55.optional(z55.string()),
|
|
143875
|
+
mimeType: z55.optional(z55.string()),
|
|
143876
|
+
size: z55.optional(z55.number()),
|
|
143687
143877
|
annotations: AnnotationsSchema.optional(),
|
|
143688
|
-
_meta:
|
|
143878
|
+
_meta: z55.optional(z55.looseObject({}))
|
|
143689
143879
|
});
|
|
143690
|
-
var ResourceTemplateSchema =
|
|
143880
|
+
var ResourceTemplateSchema = z55.object({
|
|
143691
143881
|
...BaseMetadataSchema.shape,
|
|
143692
143882
|
...IconsSchema.shape,
|
|
143693
|
-
uriTemplate:
|
|
143694
|
-
description:
|
|
143695
|
-
mimeType:
|
|
143883
|
+
uriTemplate: z55.string(),
|
|
143884
|
+
description: z55.optional(z55.string()),
|
|
143885
|
+
mimeType: z55.optional(z55.string()),
|
|
143696
143886
|
annotations: AnnotationsSchema.optional(),
|
|
143697
|
-
_meta:
|
|
143887
|
+
_meta: z55.optional(z55.looseObject({}))
|
|
143698
143888
|
});
|
|
143699
143889
|
var ListResourcesRequestSchema = PaginatedRequestSchema.extend({
|
|
143700
|
-
method:
|
|
143890
|
+
method: z55.literal("resources/list")
|
|
143701
143891
|
});
|
|
143702
143892
|
var ListResourcesResultSchema = PaginatedResultSchema.extend({
|
|
143703
|
-
resources:
|
|
143893
|
+
resources: z55.array(ResourceSchema)
|
|
143704
143894
|
});
|
|
143705
143895
|
var ListResourceTemplatesRequestSchema = PaginatedRequestSchema.extend({
|
|
143706
|
-
method:
|
|
143896
|
+
method: z55.literal("resources/templates/list")
|
|
143707
143897
|
});
|
|
143708
143898
|
var ListResourceTemplatesResultSchema = PaginatedResultSchema.extend({
|
|
143709
|
-
resourceTemplates:
|
|
143899
|
+
resourceTemplates: z55.array(ResourceTemplateSchema)
|
|
143710
143900
|
});
|
|
143711
143901
|
var ResourceRequestParamsSchema = BaseRequestParamsSchema.extend({
|
|
143712
|
-
uri:
|
|
143902
|
+
uri: z55.string()
|
|
143713
143903
|
});
|
|
143714
143904
|
var ReadResourceRequestParamsSchema = ResourceRequestParamsSchema;
|
|
143715
143905
|
var ReadResourceRequestSchema = RequestSchema.extend({
|
|
143716
|
-
method:
|
|
143906
|
+
method: z55.literal("resources/read"),
|
|
143717
143907
|
params: ReadResourceRequestParamsSchema
|
|
143718
143908
|
});
|
|
143719
143909
|
var ReadResourceResultSchema = ResultSchema.extend({
|
|
143720
|
-
contents:
|
|
143910
|
+
contents: z55.array(z55.union([TextResourceContentsSchema, BlobResourceContentsSchema]))
|
|
143721
143911
|
});
|
|
143722
143912
|
var ResourceListChangedNotificationSchema = NotificationSchema.extend({
|
|
143723
|
-
method:
|
|
143913
|
+
method: z55.literal("notifications/resources/list_changed"),
|
|
143724
143914
|
params: NotificationsParamsSchema.optional()
|
|
143725
143915
|
});
|
|
143726
143916
|
var SubscribeRequestParamsSchema = ResourceRequestParamsSchema;
|
|
143727
143917
|
var SubscribeRequestSchema = RequestSchema.extend({
|
|
143728
|
-
method:
|
|
143918
|
+
method: z55.literal("resources/subscribe"),
|
|
143729
143919
|
params: SubscribeRequestParamsSchema
|
|
143730
143920
|
});
|
|
143731
143921
|
var UnsubscribeRequestParamsSchema = ResourceRequestParamsSchema;
|
|
143732
143922
|
var UnsubscribeRequestSchema = RequestSchema.extend({
|
|
143733
|
-
method:
|
|
143923
|
+
method: z55.literal("resources/unsubscribe"),
|
|
143734
143924
|
params: UnsubscribeRequestParamsSchema
|
|
143735
143925
|
});
|
|
143736
143926
|
var ResourceUpdatedNotificationParamsSchema = NotificationsParamsSchema.extend({
|
|
143737
|
-
uri:
|
|
143927
|
+
uri: z55.string()
|
|
143738
143928
|
});
|
|
143739
143929
|
var ResourceUpdatedNotificationSchema = NotificationSchema.extend({
|
|
143740
|
-
method:
|
|
143930
|
+
method: z55.literal("notifications/resources/updated"),
|
|
143741
143931
|
params: ResourceUpdatedNotificationParamsSchema
|
|
143742
143932
|
});
|
|
143743
|
-
var PromptArgumentSchema =
|
|
143744
|
-
name:
|
|
143745
|
-
description:
|
|
143746
|
-
required:
|
|
143933
|
+
var PromptArgumentSchema = z55.object({
|
|
143934
|
+
name: z55.string(),
|
|
143935
|
+
description: z55.optional(z55.string()),
|
|
143936
|
+
required: z55.optional(z55.boolean())
|
|
143747
143937
|
});
|
|
143748
|
-
var PromptSchema =
|
|
143938
|
+
var PromptSchema = z55.object({
|
|
143749
143939
|
...BaseMetadataSchema.shape,
|
|
143750
143940
|
...IconsSchema.shape,
|
|
143751
|
-
description:
|
|
143752
|
-
arguments:
|
|
143753
|
-
_meta:
|
|
143941
|
+
description: z55.optional(z55.string()),
|
|
143942
|
+
arguments: z55.optional(z55.array(PromptArgumentSchema)),
|
|
143943
|
+
_meta: z55.optional(z55.looseObject({}))
|
|
143754
143944
|
});
|
|
143755
143945
|
var ListPromptsRequestSchema = PaginatedRequestSchema.extend({
|
|
143756
|
-
method:
|
|
143946
|
+
method: z55.literal("prompts/list")
|
|
143757
143947
|
});
|
|
143758
143948
|
var ListPromptsResultSchema = PaginatedResultSchema.extend({
|
|
143759
|
-
prompts:
|
|
143949
|
+
prompts: z55.array(PromptSchema)
|
|
143760
143950
|
});
|
|
143761
143951
|
var GetPromptRequestParamsSchema = BaseRequestParamsSchema.extend({
|
|
143762
|
-
name:
|
|
143763
|
-
arguments:
|
|
143952
|
+
name: z55.string(),
|
|
143953
|
+
arguments: z55.record(z55.string(), z55.string()).optional()
|
|
143764
143954
|
});
|
|
143765
143955
|
var GetPromptRequestSchema = RequestSchema.extend({
|
|
143766
|
-
method:
|
|
143956
|
+
method: z55.literal("prompts/get"),
|
|
143767
143957
|
params: GetPromptRequestParamsSchema
|
|
143768
143958
|
});
|
|
143769
|
-
var TextContentSchema =
|
|
143770
|
-
type:
|
|
143771
|
-
text:
|
|
143959
|
+
var TextContentSchema = z55.object({
|
|
143960
|
+
type: z55.literal("text"),
|
|
143961
|
+
text: z55.string(),
|
|
143772
143962
|
annotations: AnnotationsSchema.optional(),
|
|
143773
|
-
_meta:
|
|
143963
|
+
_meta: z55.record(z55.string(), z55.unknown()).optional()
|
|
143774
143964
|
});
|
|
143775
|
-
var ImageContentSchema =
|
|
143776
|
-
type:
|
|
143965
|
+
var ImageContentSchema = z55.object({
|
|
143966
|
+
type: z55.literal("image"),
|
|
143777
143967
|
data: Base64Schema,
|
|
143778
|
-
mimeType:
|
|
143968
|
+
mimeType: z55.string(),
|
|
143779
143969
|
annotations: AnnotationsSchema.optional(),
|
|
143780
|
-
_meta:
|
|
143970
|
+
_meta: z55.record(z55.string(), z55.unknown()).optional()
|
|
143781
143971
|
});
|
|
143782
|
-
var AudioContentSchema =
|
|
143783
|
-
type:
|
|
143972
|
+
var AudioContentSchema = z55.object({
|
|
143973
|
+
type: z55.literal("audio"),
|
|
143784
143974
|
data: Base64Schema,
|
|
143785
|
-
mimeType:
|
|
143975
|
+
mimeType: z55.string(),
|
|
143786
143976
|
annotations: AnnotationsSchema.optional(),
|
|
143787
|
-
_meta:
|
|
143977
|
+
_meta: z55.record(z55.string(), z55.unknown()).optional()
|
|
143788
143978
|
});
|
|
143789
|
-
var ToolUseContentSchema =
|
|
143790
|
-
type:
|
|
143791
|
-
name:
|
|
143792
|
-
id:
|
|
143793
|
-
input:
|
|
143794
|
-
_meta:
|
|
143979
|
+
var ToolUseContentSchema = z55.object({
|
|
143980
|
+
type: z55.literal("tool_use"),
|
|
143981
|
+
name: z55.string(),
|
|
143982
|
+
id: z55.string(),
|
|
143983
|
+
input: z55.record(z55.string(), z55.unknown()),
|
|
143984
|
+
_meta: z55.record(z55.string(), z55.unknown()).optional()
|
|
143795
143985
|
});
|
|
143796
|
-
var EmbeddedResourceSchema =
|
|
143797
|
-
type:
|
|
143798
|
-
resource:
|
|
143986
|
+
var EmbeddedResourceSchema = z55.object({
|
|
143987
|
+
type: z55.literal("resource"),
|
|
143988
|
+
resource: z55.union([TextResourceContentsSchema, BlobResourceContentsSchema]),
|
|
143799
143989
|
annotations: AnnotationsSchema.optional(),
|
|
143800
|
-
_meta:
|
|
143990
|
+
_meta: z55.record(z55.string(), z55.unknown()).optional()
|
|
143801
143991
|
});
|
|
143802
143992
|
var ResourceLinkSchema = ResourceSchema.extend({
|
|
143803
|
-
type:
|
|
143993
|
+
type: z55.literal("resource_link")
|
|
143804
143994
|
});
|
|
143805
|
-
var ContentBlockSchema =
|
|
143995
|
+
var ContentBlockSchema = z55.union([
|
|
143806
143996
|
TextContentSchema,
|
|
143807
143997
|
ImageContentSchema,
|
|
143808
143998
|
AudioContentSchema,
|
|
143809
143999
|
ResourceLinkSchema,
|
|
143810
144000
|
EmbeddedResourceSchema
|
|
143811
144001
|
]);
|
|
143812
|
-
var PromptMessageSchema =
|
|
144002
|
+
var PromptMessageSchema = z55.object({
|
|
143813
144003
|
role: RoleSchema,
|
|
143814
144004
|
content: ContentBlockSchema
|
|
143815
144005
|
});
|
|
143816
144006
|
var GetPromptResultSchema = ResultSchema.extend({
|
|
143817
|
-
description:
|
|
143818
|
-
messages:
|
|
144007
|
+
description: z55.string().optional(),
|
|
144008
|
+
messages: z55.array(PromptMessageSchema)
|
|
143819
144009
|
});
|
|
143820
144010
|
var PromptListChangedNotificationSchema = NotificationSchema.extend({
|
|
143821
|
-
method:
|
|
144011
|
+
method: z55.literal("notifications/prompts/list_changed"),
|
|
143822
144012
|
params: NotificationsParamsSchema.optional()
|
|
143823
144013
|
});
|
|
143824
|
-
var ToolAnnotationsSchema =
|
|
143825
|
-
title:
|
|
143826
|
-
readOnlyHint:
|
|
143827
|
-
destructiveHint:
|
|
143828
|
-
idempotentHint:
|
|
143829
|
-
openWorldHint:
|
|
144014
|
+
var ToolAnnotationsSchema = z55.object({
|
|
144015
|
+
title: z55.string().optional(),
|
|
144016
|
+
readOnlyHint: z55.boolean().optional(),
|
|
144017
|
+
destructiveHint: z55.boolean().optional(),
|
|
144018
|
+
idempotentHint: z55.boolean().optional(),
|
|
144019
|
+
openWorldHint: z55.boolean().optional()
|
|
143830
144020
|
});
|
|
143831
|
-
var ToolExecutionSchema =
|
|
143832
|
-
taskSupport:
|
|
144021
|
+
var ToolExecutionSchema = z55.object({
|
|
144022
|
+
taskSupport: z55.enum(["required", "optional", "forbidden"]).optional()
|
|
143833
144023
|
});
|
|
143834
|
-
var ToolSchema =
|
|
144024
|
+
var ToolSchema = z55.object({
|
|
143835
144025
|
...BaseMetadataSchema.shape,
|
|
143836
144026
|
...IconsSchema.shape,
|
|
143837
|
-
description:
|
|
143838
|
-
inputSchema:
|
|
143839
|
-
type:
|
|
143840
|
-
properties:
|
|
143841
|
-
required:
|
|
143842
|
-
}).catchall(
|
|
143843
|
-
outputSchema:
|
|
143844
|
-
type:
|
|
143845
|
-
properties:
|
|
143846
|
-
required:
|
|
143847
|
-
}).catchall(
|
|
144027
|
+
description: z55.string().optional(),
|
|
144028
|
+
inputSchema: z55.object({
|
|
144029
|
+
type: z55.literal("object"),
|
|
144030
|
+
properties: z55.record(z55.string(), AssertObjectSchema).optional(),
|
|
144031
|
+
required: z55.array(z55.string()).optional()
|
|
144032
|
+
}).catchall(z55.unknown()),
|
|
144033
|
+
outputSchema: z55.object({
|
|
144034
|
+
type: z55.literal("object"),
|
|
144035
|
+
properties: z55.record(z55.string(), AssertObjectSchema).optional(),
|
|
144036
|
+
required: z55.array(z55.string()).optional()
|
|
144037
|
+
}).catchall(z55.unknown()).optional(),
|
|
143848
144038
|
annotations: ToolAnnotationsSchema.optional(),
|
|
143849
144039
|
execution: ToolExecutionSchema.optional(),
|
|
143850
|
-
_meta:
|
|
144040
|
+
_meta: z55.record(z55.string(), z55.unknown()).optional()
|
|
143851
144041
|
});
|
|
143852
144042
|
var ListToolsRequestSchema = PaginatedRequestSchema.extend({
|
|
143853
|
-
method:
|
|
144043
|
+
method: z55.literal("tools/list")
|
|
143854
144044
|
});
|
|
143855
144045
|
var ListToolsResultSchema = PaginatedResultSchema.extend({
|
|
143856
|
-
tools:
|
|
144046
|
+
tools: z55.array(ToolSchema)
|
|
143857
144047
|
});
|
|
143858
144048
|
var CallToolResultSchema = ResultSchema.extend({
|
|
143859
|
-
content:
|
|
143860
|
-
structuredContent:
|
|
143861
|
-
isError:
|
|
144049
|
+
content: z55.array(ContentBlockSchema).default([]),
|
|
144050
|
+
structuredContent: z55.record(z55.string(), z55.unknown()).optional(),
|
|
144051
|
+
isError: z55.boolean().optional()
|
|
143862
144052
|
});
|
|
143863
144053
|
var CompatibilityCallToolResultSchema = CallToolResultSchema.or(ResultSchema.extend({
|
|
143864
|
-
toolResult:
|
|
144054
|
+
toolResult: z55.unknown()
|
|
143865
144055
|
}));
|
|
143866
144056
|
var CallToolRequestParamsSchema = TaskAugmentedRequestParamsSchema.extend({
|
|
143867
|
-
name:
|
|
143868
|
-
arguments:
|
|
144057
|
+
name: z55.string(),
|
|
144058
|
+
arguments: z55.record(z55.string(), z55.unknown()).optional()
|
|
143869
144059
|
});
|
|
143870
144060
|
var CallToolRequestSchema = RequestSchema.extend({
|
|
143871
|
-
method:
|
|
144061
|
+
method: z55.literal("tools/call"),
|
|
143872
144062
|
params: CallToolRequestParamsSchema
|
|
143873
144063
|
});
|
|
143874
144064
|
var ToolListChangedNotificationSchema = NotificationSchema.extend({
|
|
143875
|
-
method:
|
|
144065
|
+
method: z55.literal("notifications/tools/list_changed"),
|
|
143876
144066
|
params: NotificationsParamsSchema.optional()
|
|
143877
144067
|
});
|
|
143878
|
-
var ListChangedOptionsBaseSchema =
|
|
143879
|
-
autoRefresh:
|
|
143880
|
-
debounceMs:
|
|
144068
|
+
var ListChangedOptionsBaseSchema = z55.object({
|
|
144069
|
+
autoRefresh: z55.boolean().default(true),
|
|
144070
|
+
debounceMs: z55.number().int().nonnegative().default(300)
|
|
143881
144071
|
});
|
|
143882
|
-
var LoggingLevelSchema =
|
|
144072
|
+
var LoggingLevelSchema = z55.enum(["debug", "info", "notice", "warning", "error", "critical", "alert", "emergency"]);
|
|
143883
144073
|
var SetLevelRequestParamsSchema = BaseRequestParamsSchema.extend({
|
|
143884
144074
|
level: LoggingLevelSchema
|
|
143885
144075
|
});
|
|
143886
144076
|
var SetLevelRequestSchema = RequestSchema.extend({
|
|
143887
|
-
method:
|
|
144077
|
+
method: z55.literal("logging/setLevel"),
|
|
143888
144078
|
params: SetLevelRequestParamsSchema
|
|
143889
144079
|
});
|
|
143890
144080
|
var LoggingMessageNotificationParamsSchema = NotificationsParamsSchema.extend({
|
|
143891
144081
|
level: LoggingLevelSchema,
|
|
143892
|
-
logger:
|
|
143893
|
-
data:
|
|
144082
|
+
logger: z55.string().optional(),
|
|
144083
|
+
data: z55.unknown()
|
|
143894
144084
|
});
|
|
143895
144085
|
var LoggingMessageNotificationSchema = NotificationSchema.extend({
|
|
143896
|
-
method:
|
|
144086
|
+
method: z55.literal("notifications/message"),
|
|
143897
144087
|
params: LoggingMessageNotificationParamsSchema
|
|
143898
144088
|
});
|
|
143899
|
-
var ModelHintSchema =
|
|
143900
|
-
name:
|
|
144089
|
+
var ModelHintSchema = z55.object({
|
|
144090
|
+
name: z55.string().optional()
|
|
143901
144091
|
});
|
|
143902
|
-
var ModelPreferencesSchema =
|
|
143903
|
-
hints:
|
|
143904
|
-
costPriority:
|
|
143905
|
-
speedPriority:
|
|
143906
|
-
intelligencePriority:
|
|
144092
|
+
var ModelPreferencesSchema = z55.object({
|
|
144093
|
+
hints: z55.array(ModelHintSchema).optional(),
|
|
144094
|
+
costPriority: z55.number().min(0).max(1).optional(),
|
|
144095
|
+
speedPriority: z55.number().min(0).max(1).optional(),
|
|
144096
|
+
intelligencePriority: z55.number().min(0).max(1).optional()
|
|
143907
144097
|
});
|
|
143908
|
-
var ToolChoiceSchema =
|
|
143909
|
-
mode:
|
|
144098
|
+
var ToolChoiceSchema = z55.object({
|
|
144099
|
+
mode: z55.enum(["auto", "required", "none"]).optional()
|
|
143910
144100
|
});
|
|
143911
|
-
var ToolResultContentSchema =
|
|
143912
|
-
type:
|
|
143913
|
-
toolUseId:
|
|
143914
|
-
content:
|
|
143915
|
-
structuredContent:
|
|
143916
|
-
isError:
|
|
143917
|
-
_meta:
|
|
144101
|
+
var ToolResultContentSchema = z55.object({
|
|
144102
|
+
type: z55.literal("tool_result"),
|
|
144103
|
+
toolUseId: z55.string().describe("The unique identifier for the corresponding tool call."),
|
|
144104
|
+
content: z55.array(ContentBlockSchema).default([]),
|
|
144105
|
+
structuredContent: z55.object({}).loose().optional(),
|
|
144106
|
+
isError: z55.boolean().optional(),
|
|
144107
|
+
_meta: z55.record(z55.string(), z55.unknown()).optional()
|
|
143918
144108
|
});
|
|
143919
|
-
var SamplingContentSchema =
|
|
143920
|
-
var SamplingMessageContentBlockSchema =
|
|
144109
|
+
var SamplingContentSchema = z55.discriminatedUnion("type", [TextContentSchema, ImageContentSchema, AudioContentSchema]);
|
|
144110
|
+
var SamplingMessageContentBlockSchema = z55.discriminatedUnion("type", [
|
|
143921
144111
|
TextContentSchema,
|
|
143922
144112
|
ImageContentSchema,
|
|
143923
144113
|
AudioContentSchema,
|
|
143924
144114
|
ToolUseContentSchema,
|
|
143925
144115
|
ToolResultContentSchema
|
|
143926
144116
|
]);
|
|
143927
|
-
var SamplingMessageSchema =
|
|
144117
|
+
var SamplingMessageSchema = z55.object({
|
|
143928
144118
|
role: RoleSchema,
|
|
143929
|
-
content:
|
|
143930
|
-
_meta:
|
|
144119
|
+
content: z55.union([SamplingMessageContentBlockSchema, z55.array(SamplingMessageContentBlockSchema)]),
|
|
144120
|
+
_meta: z55.record(z55.string(), z55.unknown()).optional()
|
|
143931
144121
|
});
|
|
143932
144122
|
var CreateMessageRequestParamsSchema = TaskAugmentedRequestParamsSchema.extend({
|
|
143933
|
-
messages:
|
|
144123
|
+
messages: z55.array(SamplingMessageSchema),
|
|
143934
144124
|
modelPreferences: ModelPreferencesSchema.optional(),
|
|
143935
|
-
systemPrompt:
|
|
143936
|
-
includeContext:
|
|
143937
|
-
temperature:
|
|
143938
|
-
maxTokens:
|
|
143939
|
-
stopSequences:
|
|
144125
|
+
systemPrompt: z55.string().optional(),
|
|
144126
|
+
includeContext: z55.enum(["none", "thisServer", "allServers"]).optional(),
|
|
144127
|
+
temperature: z55.number().optional(),
|
|
144128
|
+
maxTokens: z55.number().int(),
|
|
144129
|
+
stopSequences: z55.array(z55.string()).optional(),
|
|
143940
144130
|
metadata: AssertObjectSchema.optional(),
|
|
143941
|
-
tools:
|
|
144131
|
+
tools: z55.array(ToolSchema).optional(),
|
|
143942
144132
|
toolChoice: ToolChoiceSchema.optional()
|
|
143943
144133
|
});
|
|
143944
144134
|
var CreateMessageRequestSchema = RequestSchema.extend({
|
|
143945
|
-
method:
|
|
144135
|
+
method: z55.literal("sampling/createMessage"),
|
|
143946
144136
|
params: CreateMessageRequestParamsSchema
|
|
143947
144137
|
});
|
|
143948
144138
|
var CreateMessageResultSchema = ResultSchema.extend({
|
|
143949
|
-
model:
|
|
143950
|
-
stopReason:
|
|
144139
|
+
model: z55.string(),
|
|
144140
|
+
stopReason: z55.optional(z55.enum(["endTurn", "stopSequence", "maxTokens"]).or(z55.string())),
|
|
143951
144141
|
role: RoleSchema,
|
|
143952
144142
|
content: SamplingContentSchema
|
|
143953
144143
|
});
|
|
143954
144144
|
var CreateMessageResultWithToolsSchema = ResultSchema.extend({
|
|
143955
|
-
model:
|
|
143956
|
-
stopReason:
|
|
144145
|
+
model: z55.string(),
|
|
144146
|
+
stopReason: z55.optional(z55.enum(["endTurn", "stopSequence", "maxTokens", "toolUse"]).or(z55.string())),
|
|
143957
144147
|
role: RoleSchema,
|
|
143958
|
-
content:
|
|
144148
|
+
content: z55.union([SamplingMessageContentBlockSchema, z55.array(SamplingMessageContentBlockSchema)])
|
|
143959
144149
|
});
|
|
143960
|
-
var BooleanSchemaSchema =
|
|
143961
|
-
type:
|
|
143962
|
-
title:
|
|
143963
|
-
description:
|
|
143964
|
-
default:
|
|
144150
|
+
var BooleanSchemaSchema = z55.object({
|
|
144151
|
+
type: z55.literal("boolean"),
|
|
144152
|
+
title: z55.string().optional(),
|
|
144153
|
+
description: z55.string().optional(),
|
|
144154
|
+
default: z55.boolean().optional()
|
|
143965
144155
|
});
|
|
143966
|
-
var StringSchemaSchema =
|
|
143967
|
-
type:
|
|
143968
|
-
title:
|
|
143969
|
-
description:
|
|
143970
|
-
minLength:
|
|
143971
|
-
maxLength:
|
|
143972
|
-
format:
|
|
143973
|
-
default:
|
|
144156
|
+
var StringSchemaSchema = z55.object({
|
|
144157
|
+
type: z55.literal("string"),
|
|
144158
|
+
title: z55.string().optional(),
|
|
144159
|
+
description: z55.string().optional(),
|
|
144160
|
+
minLength: z55.number().optional(),
|
|
144161
|
+
maxLength: z55.number().optional(),
|
|
144162
|
+
format: z55.enum(["email", "uri", "date", "date-time"]).optional(),
|
|
144163
|
+
default: z55.string().optional()
|
|
143974
144164
|
});
|
|
143975
|
-
var NumberSchemaSchema =
|
|
143976
|
-
type:
|
|
143977
|
-
title:
|
|
143978
|
-
description:
|
|
143979
|
-
minimum:
|
|
143980
|
-
maximum:
|
|
143981
|
-
default:
|
|
144165
|
+
var NumberSchemaSchema = z55.object({
|
|
144166
|
+
type: z55.enum(["number", "integer"]),
|
|
144167
|
+
title: z55.string().optional(),
|
|
144168
|
+
description: z55.string().optional(),
|
|
144169
|
+
minimum: z55.number().optional(),
|
|
144170
|
+
maximum: z55.number().optional(),
|
|
144171
|
+
default: z55.number().optional()
|
|
143982
144172
|
});
|
|
143983
|
-
var UntitledSingleSelectEnumSchemaSchema =
|
|
143984
|
-
type:
|
|
143985
|
-
title:
|
|
143986
|
-
description:
|
|
143987
|
-
enum:
|
|
143988
|
-
default:
|
|
144173
|
+
var UntitledSingleSelectEnumSchemaSchema = z55.object({
|
|
144174
|
+
type: z55.literal("string"),
|
|
144175
|
+
title: z55.string().optional(),
|
|
144176
|
+
description: z55.string().optional(),
|
|
144177
|
+
enum: z55.array(z55.string()),
|
|
144178
|
+
default: z55.string().optional()
|
|
143989
144179
|
});
|
|
143990
|
-
var TitledSingleSelectEnumSchemaSchema =
|
|
143991
|
-
type:
|
|
143992
|
-
title:
|
|
143993
|
-
description:
|
|
143994
|
-
oneOf:
|
|
143995
|
-
const:
|
|
143996
|
-
title:
|
|
144180
|
+
var TitledSingleSelectEnumSchemaSchema = z55.object({
|
|
144181
|
+
type: z55.literal("string"),
|
|
144182
|
+
title: z55.string().optional(),
|
|
144183
|
+
description: z55.string().optional(),
|
|
144184
|
+
oneOf: z55.array(z55.object({
|
|
144185
|
+
const: z55.string(),
|
|
144186
|
+
title: z55.string()
|
|
143997
144187
|
})),
|
|
143998
|
-
default:
|
|
144188
|
+
default: z55.string().optional()
|
|
143999
144189
|
});
|
|
144000
|
-
var LegacyTitledEnumSchemaSchema =
|
|
144001
|
-
type:
|
|
144002
|
-
title:
|
|
144003
|
-
description:
|
|
144004
|
-
enum:
|
|
144005
|
-
enumNames:
|
|
144006
|
-
default:
|
|
144190
|
+
var LegacyTitledEnumSchemaSchema = z55.object({
|
|
144191
|
+
type: z55.literal("string"),
|
|
144192
|
+
title: z55.string().optional(),
|
|
144193
|
+
description: z55.string().optional(),
|
|
144194
|
+
enum: z55.array(z55.string()),
|
|
144195
|
+
enumNames: z55.array(z55.string()).optional(),
|
|
144196
|
+
default: z55.string().optional()
|
|
144007
144197
|
});
|
|
144008
|
-
var SingleSelectEnumSchemaSchema =
|
|
144009
|
-
var UntitledMultiSelectEnumSchemaSchema =
|
|
144010
|
-
type:
|
|
144011
|
-
title:
|
|
144012
|
-
description:
|
|
144013
|
-
minItems:
|
|
144014
|
-
maxItems:
|
|
144015
|
-
items:
|
|
144016
|
-
type:
|
|
144017
|
-
enum:
|
|
144198
|
+
var SingleSelectEnumSchemaSchema = z55.union([UntitledSingleSelectEnumSchemaSchema, TitledSingleSelectEnumSchemaSchema]);
|
|
144199
|
+
var UntitledMultiSelectEnumSchemaSchema = z55.object({
|
|
144200
|
+
type: z55.literal("array"),
|
|
144201
|
+
title: z55.string().optional(),
|
|
144202
|
+
description: z55.string().optional(),
|
|
144203
|
+
minItems: z55.number().optional(),
|
|
144204
|
+
maxItems: z55.number().optional(),
|
|
144205
|
+
items: z55.object({
|
|
144206
|
+
type: z55.literal("string"),
|
|
144207
|
+
enum: z55.array(z55.string())
|
|
144018
144208
|
}),
|
|
144019
|
-
default:
|
|
144209
|
+
default: z55.array(z55.string()).optional()
|
|
144020
144210
|
});
|
|
144021
|
-
var TitledMultiSelectEnumSchemaSchema =
|
|
144022
|
-
type:
|
|
144023
|
-
title:
|
|
144024
|
-
description:
|
|
144025
|
-
minItems:
|
|
144026
|
-
maxItems:
|
|
144027
|
-
items:
|
|
144028
|
-
anyOf:
|
|
144029
|
-
const:
|
|
144030
|
-
title:
|
|
144211
|
+
var TitledMultiSelectEnumSchemaSchema = z55.object({
|
|
144212
|
+
type: z55.literal("array"),
|
|
144213
|
+
title: z55.string().optional(),
|
|
144214
|
+
description: z55.string().optional(),
|
|
144215
|
+
minItems: z55.number().optional(),
|
|
144216
|
+
maxItems: z55.number().optional(),
|
|
144217
|
+
items: z55.object({
|
|
144218
|
+
anyOf: z55.array(z55.object({
|
|
144219
|
+
const: z55.string(),
|
|
144220
|
+
title: z55.string()
|
|
144031
144221
|
}))
|
|
144032
144222
|
}),
|
|
144033
|
-
default:
|
|
144223
|
+
default: z55.array(z55.string()).optional()
|
|
144034
144224
|
});
|
|
144035
|
-
var MultiSelectEnumSchemaSchema =
|
|
144036
|
-
var EnumSchemaSchema =
|
|
144037
|
-
var PrimitiveSchemaDefinitionSchema =
|
|
144225
|
+
var MultiSelectEnumSchemaSchema = z55.union([UntitledMultiSelectEnumSchemaSchema, TitledMultiSelectEnumSchemaSchema]);
|
|
144226
|
+
var EnumSchemaSchema = z55.union([LegacyTitledEnumSchemaSchema, SingleSelectEnumSchemaSchema, MultiSelectEnumSchemaSchema]);
|
|
144227
|
+
var PrimitiveSchemaDefinitionSchema = z55.union([EnumSchemaSchema, BooleanSchemaSchema, StringSchemaSchema, NumberSchemaSchema]);
|
|
144038
144228
|
var ElicitRequestFormParamsSchema = TaskAugmentedRequestParamsSchema.extend({
|
|
144039
|
-
mode:
|
|
144040
|
-
message:
|
|
144041
|
-
requestedSchema:
|
|
144042
|
-
type:
|
|
144043
|
-
properties:
|
|
144044
|
-
required:
|
|
144229
|
+
mode: z55.literal("form").optional(),
|
|
144230
|
+
message: z55.string(),
|
|
144231
|
+
requestedSchema: z55.object({
|
|
144232
|
+
type: z55.literal("object"),
|
|
144233
|
+
properties: z55.record(z55.string(), PrimitiveSchemaDefinitionSchema),
|
|
144234
|
+
required: z55.array(z55.string()).optional()
|
|
144045
144235
|
})
|
|
144046
144236
|
});
|
|
144047
144237
|
var ElicitRequestURLParamsSchema = TaskAugmentedRequestParamsSchema.extend({
|
|
144048
|
-
mode:
|
|
144049
|
-
message:
|
|
144050
|
-
elicitationId:
|
|
144051
|
-
url:
|
|
144238
|
+
mode: z55.literal("url"),
|
|
144239
|
+
message: z55.string(),
|
|
144240
|
+
elicitationId: z55.string(),
|
|
144241
|
+
url: z55.string().url()
|
|
144052
144242
|
});
|
|
144053
|
-
var ElicitRequestParamsSchema =
|
|
144243
|
+
var ElicitRequestParamsSchema = z55.union([ElicitRequestFormParamsSchema, ElicitRequestURLParamsSchema]);
|
|
144054
144244
|
var ElicitRequestSchema = RequestSchema.extend({
|
|
144055
|
-
method:
|
|
144245
|
+
method: z55.literal("elicitation/create"),
|
|
144056
144246
|
params: ElicitRequestParamsSchema
|
|
144057
144247
|
});
|
|
144058
144248
|
var ElicitationCompleteNotificationParamsSchema = NotificationsParamsSchema.extend({
|
|
144059
|
-
elicitationId:
|
|
144249
|
+
elicitationId: z55.string()
|
|
144060
144250
|
});
|
|
144061
144251
|
var ElicitationCompleteNotificationSchema = NotificationSchema.extend({
|
|
144062
|
-
method:
|
|
144252
|
+
method: z55.literal("notifications/elicitation/complete"),
|
|
144063
144253
|
params: ElicitationCompleteNotificationParamsSchema
|
|
144064
144254
|
});
|
|
144065
144255
|
var ElicitResultSchema = ResultSchema.extend({
|
|
144066
|
-
action:
|
|
144067
|
-
content:
|
|
144256
|
+
action: z55.enum(["accept", "decline", "cancel"]),
|
|
144257
|
+
content: z55.preprocess((val) => val === null ? undefined : val, z55.record(z55.string(), z55.union([z55.string(), z55.number(), z55.boolean(), z55.array(z55.string())])).optional())
|
|
144068
144258
|
});
|
|
144069
|
-
var ResourceTemplateReferenceSchema =
|
|
144070
|
-
type:
|
|
144071
|
-
uri:
|
|
144259
|
+
var ResourceTemplateReferenceSchema = z55.object({
|
|
144260
|
+
type: z55.literal("ref/resource"),
|
|
144261
|
+
uri: z55.string()
|
|
144072
144262
|
});
|
|
144073
|
-
var PromptReferenceSchema =
|
|
144074
|
-
type:
|
|
144075
|
-
name:
|
|
144263
|
+
var PromptReferenceSchema = z55.object({
|
|
144264
|
+
type: z55.literal("ref/prompt"),
|
|
144265
|
+
name: z55.string()
|
|
144076
144266
|
});
|
|
144077
144267
|
var CompleteRequestParamsSchema = BaseRequestParamsSchema.extend({
|
|
144078
|
-
ref:
|
|
144079
|
-
argument:
|
|
144080
|
-
name:
|
|
144081
|
-
value:
|
|
144268
|
+
ref: z55.union([PromptReferenceSchema, ResourceTemplateReferenceSchema]),
|
|
144269
|
+
argument: z55.object({
|
|
144270
|
+
name: z55.string(),
|
|
144271
|
+
value: z55.string()
|
|
144082
144272
|
}),
|
|
144083
|
-
context:
|
|
144084
|
-
arguments:
|
|
144273
|
+
context: z55.object({
|
|
144274
|
+
arguments: z55.record(z55.string(), z55.string()).optional()
|
|
144085
144275
|
}).optional()
|
|
144086
144276
|
});
|
|
144087
144277
|
var CompleteRequestSchema = RequestSchema.extend({
|
|
144088
|
-
method:
|
|
144278
|
+
method: z55.literal("completion/complete"),
|
|
144089
144279
|
params: CompleteRequestParamsSchema
|
|
144090
144280
|
});
|
|
144091
144281
|
var CompleteResultSchema = ResultSchema.extend({
|
|
144092
|
-
completion:
|
|
144093
|
-
values:
|
|
144094
|
-
total:
|
|
144095
|
-
hasMore:
|
|
144282
|
+
completion: z55.looseObject({
|
|
144283
|
+
values: z55.array(z55.string()).max(100),
|
|
144284
|
+
total: z55.optional(z55.number().int()),
|
|
144285
|
+
hasMore: z55.optional(z55.boolean())
|
|
144096
144286
|
})
|
|
144097
144287
|
});
|
|
144098
|
-
var RootSchema =
|
|
144099
|
-
uri:
|
|
144100
|
-
name:
|
|
144101
|
-
_meta:
|
|
144288
|
+
var RootSchema = z55.object({
|
|
144289
|
+
uri: z55.string().startsWith("file://"),
|
|
144290
|
+
name: z55.string().optional(),
|
|
144291
|
+
_meta: z55.record(z55.string(), z55.unknown()).optional()
|
|
144102
144292
|
});
|
|
144103
144293
|
var ListRootsRequestSchema = RequestSchema.extend({
|
|
144104
|
-
method:
|
|
144294
|
+
method: z55.literal("roots/list"),
|
|
144105
144295
|
params: BaseRequestParamsSchema.optional()
|
|
144106
144296
|
});
|
|
144107
144297
|
var ListRootsResultSchema = ResultSchema.extend({
|
|
144108
|
-
roots:
|
|
144298
|
+
roots: z55.array(RootSchema)
|
|
144109
144299
|
});
|
|
144110
144300
|
var RootsListChangedNotificationSchema = NotificationSchema.extend({
|
|
144111
|
-
method:
|
|
144301
|
+
method: z55.literal("notifications/roots/list_changed"),
|
|
144112
144302
|
params: NotificationsParamsSchema.optional()
|
|
144113
144303
|
});
|
|
144114
|
-
var ClientRequestSchema =
|
|
144304
|
+
var ClientRequestSchema = z55.union([
|
|
144115
144305
|
PingRequestSchema,
|
|
144116
144306
|
InitializeRequestSchema,
|
|
144117
144307
|
CompleteRequestSchema,
|
|
@@ -144130,14 +144320,14 @@ var ClientRequestSchema = z54.union([
|
|
|
144130
144320
|
ListTasksRequestSchema,
|
|
144131
144321
|
CancelTaskRequestSchema
|
|
144132
144322
|
]);
|
|
144133
|
-
var ClientNotificationSchema =
|
|
144323
|
+
var ClientNotificationSchema = z55.union([
|
|
144134
144324
|
CancelledNotificationSchema,
|
|
144135
144325
|
ProgressNotificationSchema,
|
|
144136
144326
|
InitializedNotificationSchema,
|
|
144137
144327
|
RootsListChangedNotificationSchema,
|
|
144138
144328
|
TaskStatusNotificationSchema
|
|
144139
144329
|
]);
|
|
144140
|
-
var ClientResultSchema =
|
|
144330
|
+
var ClientResultSchema = z55.union([
|
|
144141
144331
|
EmptyResultSchema,
|
|
144142
144332
|
CreateMessageResultSchema,
|
|
144143
144333
|
CreateMessageResultWithToolsSchema,
|
|
@@ -144147,7 +144337,7 @@ var ClientResultSchema = z54.union([
|
|
|
144147
144337
|
ListTasksResultSchema,
|
|
144148
144338
|
CreateTaskResultSchema
|
|
144149
144339
|
]);
|
|
144150
|
-
var ServerRequestSchema =
|
|
144340
|
+
var ServerRequestSchema = z55.union([
|
|
144151
144341
|
PingRequestSchema,
|
|
144152
144342
|
CreateMessageRequestSchema,
|
|
144153
144343
|
ElicitRequestSchema,
|
|
@@ -144157,7 +144347,7 @@ var ServerRequestSchema = z54.union([
|
|
|
144157
144347
|
ListTasksRequestSchema,
|
|
144158
144348
|
CancelTaskRequestSchema
|
|
144159
144349
|
]);
|
|
144160
|
-
var ServerNotificationSchema =
|
|
144350
|
+
var ServerNotificationSchema = z55.union([
|
|
144161
144351
|
CancelledNotificationSchema,
|
|
144162
144352
|
ProgressNotificationSchema,
|
|
144163
144353
|
LoggingMessageNotificationSchema,
|
|
@@ -144168,7 +144358,7 @@ var ServerNotificationSchema = z54.union([
|
|
|
144168
144358
|
TaskStatusNotificationSchema,
|
|
144169
144359
|
ElicitationCompleteNotificationSchema
|
|
144170
144360
|
]);
|
|
144171
|
-
var ServerResultSchema =
|
|
144361
|
+
var ServerResultSchema = z55.union([
|
|
144172
144362
|
EmptyResultSchema,
|
|
144173
144363
|
InitializeResultSchema,
|
|
144174
144364
|
CompleteResultSchema,
|
|
@@ -145780,149 +145970,149 @@ async function pkceChallenge(length) {
|
|
|
145780
145970
|
}
|
|
145781
145971
|
|
|
145782
145972
|
// node_modules/.bun/@modelcontextprotocol+sdk@1.30.0/node_modules/@modelcontextprotocol/sdk/dist/esm/shared/auth.js
|
|
145783
|
-
import * as
|
|
145784
|
-
var SafeUrlSchema =
|
|
145973
|
+
import * as z56 from "zod/v4";
|
|
145974
|
+
var SafeUrlSchema = z56.url().superRefine((val, ctx) => {
|
|
145785
145975
|
if (!URL.canParse(val)) {
|
|
145786
145976
|
ctx.addIssue({
|
|
145787
|
-
code:
|
|
145977
|
+
code: z56.ZodIssueCode.custom,
|
|
145788
145978
|
message: "URL must be parseable",
|
|
145789
145979
|
fatal: true
|
|
145790
145980
|
});
|
|
145791
|
-
return
|
|
145981
|
+
return z56.NEVER;
|
|
145792
145982
|
}
|
|
145793
145983
|
}).refine((url2) => {
|
|
145794
145984
|
const u = new URL(url2);
|
|
145795
145985
|
return u.protocol !== "javascript:" && u.protocol !== "data:" && u.protocol !== "vbscript:";
|
|
145796
145986
|
}, { message: "URL cannot use javascript:, data:, or vbscript: scheme" });
|
|
145797
|
-
var OAuthProtectedResourceMetadataSchema =
|
|
145798
|
-
resource:
|
|
145799
|
-
authorization_servers:
|
|
145800
|
-
jwks_uri:
|
|
145801
|
-
scopes_supported:
|
|
145802
|
-
bearer_methods_supported:
|
|
145803
|
-
resource_signing_alg_values_supported:
|
|
145804
|
-
resource_name:
|
|
145805
|
-
resource_documentation:
|
|
145806
|
-
resource_policy_uri:
|
|
145807
|
-
resource_tos_uri:
|
|
145808
|
-
tls_client_certificate_bound_access_tokens:
|
|
145809
|
-
authorization_details_types_supported:
|
|
145810
|
-
dpop_signing_alg_values_supported:
|
|
145811
|
-
dpop_bound_access_tokens_required:
|
|
145987
|
+
var OAuthProtectedResourceMetadataSchema = z56.looseObject({
|
|
145988
|
+
resource: z56.string().url(),
|
|
145989
|
+
authorization_servers: z56.array(SafeUrlSchema).optional(),
|
|
145990
|
+
jwks_uri: z56.string().url().optional(),
|
|
145991
|
+
scopes_supported: z56.array(z56.string()).optional(),
|
|
145992
|
+
bearer_methods_supported: z56.array(z56.string()).optional(),
|
|
145993
|
+
resource_signing_alg_values_supported: z56.array(z56.string()).optional(),
|
|
145994
|
+
resource_name: z56.string().optional(),
|
|
145995
|
+
resource_documentation: z56.string().optional(),
|
|
145996
|
+
resource_policy_uri: z56.string().url().optional(),
|
|
145997
|
+
resource_tos_uri: z56.string().url().optional(),
|
|
145998
|
+
tls_client_certificate_bound_access_tokens: z56.boolean().optional(),
|
|
145999
|
+
authorization_details_types_supported: z56.array(z56.string()).optional(),
|
|
146000
|
+
dpop_signing_alg_values_supported: z56.array(z56.string()).optional(),
|
|
146001
|
+
dpop_bound_access_tokens_required: z56.boolean().optional()
|
|
145812
146002
|
});
|
|
145813
|
-
var OAuthMetadataSchema =
|
|
145814
|
-
issuer:
|
|
146003
|
+
var OAuthMetadataSchema = z56.looseObject({
|
|
146004
|
+
issuer: z56.string(),
|
|
145815
146005
|
authorization_endpoint: SafeUrlSchema,
|
|
145816
146006
|
token_endpoint: SafeUrlSchema,
|
|
145817
146007
|
registration_endpoint: SafeUrlSchema.optional(),
|
|
145818
|
-
scopes_supported:
|
|
145819
|
-
response_types_supported:
|
|
145820
|
-
response_modes_supported:
|
|
145821
|
-
grant_types_supported:
|
|
145822
|
-
token_endpoint_auth_methods_supported:
|
|
145823
|
-
token_endpoint_auth_signing_alg_values_supported:
|
|
146008
|
+
scopes_supported: z56.array(z56.string()).optional(),
|
|
146009
|
+
response_types_supported: z56.array(z56.string()),
|
|
146010
|
+
response_modes_supported: z56.array(z56.string()).optional(),
|
|
146011
|
+
grant_types_supported: z56.array(z56.string()).optional(),
|
|
146012
|
+
token_endpoint_auth_methods_supported: z56.array(z56.string()).optional(),
|
|
146013
|
+
token_endpoint_auth_signing_alg_values_supported: z56.array(z56.string()).optional(),
|
|
145824
146014
|
service_documentation: SafeUrlSchema.optional(),
|
|
145825
146015
|
revocation_endpoint: SafeUrlSchema.optional(),
|
|
145826
|
-
revocation_endpoint_auth_methods_supported:
|
|
145827
|
-
revocation_endpoint_auth_signing_alg_values_supported:
|
|
145828
|
-
introspection_endpoint:
|
|
145829
|
-
introspection_endpoint_auth_methods_supported:
|
|
145830
|
-
introspection_endpoint_auth_signing_alg_values_supported:
|
|
145831
|
-
code_challenge_methods_supported:
|
|
145832
|
-
client_id_metadata_document_supported:
|
|
146016
|
+
revocation_endpoint_auth_methods_supported: z56.array(z56.string()).optional(),
|
|
146017
|
+
revocation_endpoint_auth_signing_alg_values_supported: z56.array(z56.string()).optional(),
|
|
146018
|
+
introspection_endpoint: z56.string().optional(),
|
|
146019
|
+
introspection_endpoint_auth_methods_supported: z56.array(z56.string()).optional(),
|
|
146020
|
+
introspection_endpoint_auth_signing_alg_values_supported: z56.array(z56.string()).optional(),
|
|
146021
|
+
code_challenge_methods_supported: z56.array(z56.string()).optional(),
|
|
146022
|
+
client_id_metadata_document_supported: z56.boolean().optional()
|
|
145833
146023
|
});
|
|
145834
|
-
var OpenIdProviderMetadataSchema =
|
|
145835
|
-
issuer:
|
|
146024
|
+
var OpenIdProviderMetadataSchema = z56.looseObject({
|
|
146025
|
+
issuer: z56.string(),
|
|
145836
146026
|
authorization_endpoint: SafeUrlSchema,
|
|
145837
146027
|
token_endpoint: SafeUrlSchema,
|
|
145838
146028
|
userinfo_endpoint: SafeUrlSchema.optional(),
|
|
145839
146029
|
jwks_uri: SafeUrlSchema,
|
|
145840
146030
|
registration_endpoint: SafeUrlSchema.optional(),
|
|
145841
|
-
scopes_supported:
|
|
145842
|
-
response_types_supported:
|
|
145843
|
-
response_modes_supported:
|
|
145844
|
-
grant_types_supported:
|
|
145845
|
-
acr_values_supported:
|
|
145846
|
-
subject_types_supported:
|
|
145847
|
-
id_token_signing_alg_values_supported:
|
|
145848
|
-
id_token_encryption_alg_values_supported:
|
|
145849
|
-
id_token_encryption_enc_values_supported:
|
|
145850
|
-
userinfo_signing_alg_values_supported:
|
|
145851
|
-
userinfo_encryption_alg_values_supported:
|
|
145852
|
-
userinfo_encryption_enc_values_supported:
|
|
145853
|
-
request_object_signing_alg_values_supported:
|
|
145854
|
-
request_object_encryption_alg_values_supported:
|
|
145855
|
-
request_object_encryption_enc_values_supported:
|
|
145856
|
-
token_endpoint_auth_methods_supported:
|
|
145857
|
-
token_endpoint_auth_signing_alg_values_supported:
|
|
145858
|
-
display_values_supported:
|
|
145859
|
-
claim_types_supported:
|
|
145860
|
-
claims_supported:
|
|
145861
|
-
service_documentation:
|
|
145862
|
-
claims_locales_supported:
|
|
145863
|
-
ui_locales_supported:
|
|
145864
|
-
claims_parameter_supported:
|
|
145865
|
-
request_parameter_supported:
|
|
145866
|
-
request_uri_parameter_supported:
|
|
145867
|
-
require_request_uri_registration:
|
|
146031
|
+
scopes_supported: z56.array(z56.string()).optional(),
|
|
146032
|
+
response_types_supported: z56.array(z56.string()),
|
|
146033
|
+
response_modes_supported: z56.array(z56.string()).optional(),
|
|
146034
|
+
grant_types_supported: z56.array(z56.string()).optional(),
|
|
146035
|
+
acr_values_supported: z56.array(z56.string()).optional(),
|
|
146036
|
+
subject_types_supported: z56.array(z56.string()),
|
|
146037
|
+
id_token_signing_alg_values_supported: z56.array(z56.string()),
|
|
146038
|
+
id_token_encryption_alg_values_supported: z56.array(z56.string()).optional(),
|
|
146039
|
+
id_token_encryption_enc_values_supported: z56.array(z56.string()).optional(),
|
|
146040
|
+
userinfo_signing_alg_values_supported: z56.array(z56.string()).optional(),
|
|
146041
|
+
userinfo_encryption_alg_values_supported: z56.array(z56.string()).optional(),
|
|
146042
|
+
userinfo_encryption_enc_values_supported: z56.array(z56.string()).optional(),
|
|
146043
|
+
request_object_signing_alg_values_supported: z56.array(z56.string()).optional(),
|
|
146044
|
+
request_object_encryption_alg_values_supported: z56.array(z56.string()).optional(),
|
|
146045
|
+
request_object_encryption_enc_values_supported: z56.array(z56.string()).optional(),
|
|
146046
|
+
token_endpoint_auth_methods_supported: z56.array(z56.string()).optional(),
|
|
146047
|
+
token_endpoint_auth_signing_alg_values_supported: z56.array(z56.string()).optional(),
|
|
146048
|
+
display_values_supported: z56.array(z56.string()).optional(),
|
|
146049
|
+
claim_types_supported: z56.array(z56.string()).optional(),
|
|
146050
|
+
claims_supported: z56.array(z56.string()).optional(),
|
|
146051
|
+
service_documentation: z56.string().optional(),
|
|
146052
|
+
claims_locales_supported: z56.array(z56.string()).optional(),
|
|
146053
|
+
ui_locales_supported: z56.array(z56.string()).optional(),
|
|
146054
|
+
claims_parameter_supported: z56.boolean().optional(),
|
|
146055
|
+
request_parameter_supported: z56.boolean().optional(),
|
|
146056
|
+
request_uri_parameter_supported: z56.boolean().optional(),
|
|
146057
|
+
require_request_uri_registration: z56.boolean().optional(),
|
|
145868
146058
|
op_policy_uri: SafeUrlSchema.optional(),
|
|
145869
146059
|
op_tos_uri: SafeUrlSchema.optional(),
|
|
145870
|
-
client_id_metadata_document_supported:
|
|
146060
|
+
client_id_metadata_document_supported: z56.boolean().optional()
|
|
145871
146061
|
});
|
|
145872
|
-
var OpenIdProviderDiscoveryMetadataSchema =
|
|
146062
|
+
var OpenIdProviderDiscoveryMetadataSchema = z56.object({
|
|
145873
146063
|
...OpenIdProviderMetadataSchema.shape,
|
|
145874
146064
|
...OAuthMetadataSchema.pick({
|
|
145875
146065
|
code_challenge_methods_supported: true
|
|
145876
146066
|
}).shape
|
|
145877
146067
|
});
|
|
145878
|
-
var OAuthTokensSchema =
|
|
145879
|
-
access_token:
|
|
145880
|
-
id_token:
|
|
145881
|
-
token_type:
|
|
145882
|
-
expires_in:
|
|
145883
|
-
scope:
|
|
145884
|
-
refresh_token:
|
|
146068
|
+
var OAuthTokensSchema = z56.object({
|
|
146069
|
+
access_token: z56.string(),
|
|
146070
|
+
id_token: z56.string().optional(),
|
|
146071
|
+
token_type: z56.string(),
|
|
146072
|
+
expires_in: z56.coerce.number().optional(),
|
|
146073
|
+
scope: z56.string().optional(),
|
|
146074
|
+
refresh_token: z56.string().optional()
|
|
145885
146075
|
}).strip();
|
|
145886
|
-
var OAuthErrorResponseSchema =
|
|
145887
|
-
error:
|
|
145888
|
-
error_description:
|
|
145889
|
-
error_uri:
|
|
146076
|
+
var OAuthErrorResponseSchema = z56.object({
|
|
146077
|
+
error: z56.string(),
|
|
146078
|
+
error_description: z56.string().optional(),
|
|
146079
|
+
error_uri: z56.string().optional()
|
|
145890
146080
|
});
|
|
145891
|
-
var OptionalSafeUrlSchema = SafeUrlSchema.optional().or(
|
|
146081
|
+
var OptionalSafeUrlSchema = SafeUrlSchema.optional().or(z56.literal("").transform(() => {
|
|
145892
146082
|
return;
|
|
145893
146083
|
}));
|
|
145894
|
-
var OAuthClientMetadataSchema =
|
|
145895
|
-
redirect_uris:
|
|
145896
|
-
token_endpoint_auth_method:
|
|
145897
|
-
grant_types:
|
|
145898
|
-
response_types:
|
|
145899
|
-
client_name:
|
|
146084
|
+
var OAuthClientMetadataSchema = z56.object({
|
|
146085
|
+
redirect_uris: z56.array(SafeUrlSchema),
|
|
146086
|
+
token_endpoint_auth_method: z56.string().optional(),
|
|
146087
|
+
grant_types: z56.array(z56.string()).optional(),
|
|
146088
|
+
response_types: z56.array(z56.string()).optional(),
|
|
146089
|
+
client_name: z56.string().optional(),
|
|
145900
146090
|
client_uri: SafeUrlSchema.optional(),
|
|
145901
146091
|
logo_uri: OptionalSafeUrlSchema,
|
|
145902
|
-
scope:
|
|
145903
|
-
contacts:
|
|
146092
|
+
scope: z56.string().optional(),
|
|
146093
|
+
contacts: z56.array(z56.string()).optional(),
|
|
145904
146094
|
tos_uri: OptionalSafeUrlSchema,
|
|
145905
|
-
policy_uri:
|
|
146095
|
+
policy_uri: z56.string().optional(),
|
|
145906
146096
|
jwks_uri: SafeUrlSchema.optional(),
|
|
145907
|
-
jwks:
|
|
145908
|
-
software_id:
|
|
145909
|
-
software_version:
|
|
145910
|
-
software_statement:
|
|
146097
|
+
jwks: z56.any().optional(),
|
|
146098
|
+
software_id: z56.string().optional(),
|
|
146099
|
+
software_version: z56.string().optional(),
|
|
146100
|
+
software_statement: z56.string().optional()
|
|
145911
146101
|
}).strip();
|
|
145912
|
-
var OAuthClientInformationSchema =
|
|
145913
|
-
client_id:
|
|
145914
|
-
client_secret:
|
|
145915
|
-
client_id_issued_at:
|
|
145916
|
-
client_secret_expires_at:
|
|
146102
|
+
var OAuthClientInformationSchema = z56.object({
|
|
146103
|
+
client_id: z56.string(),
|
|
146104
|
+
client_secret: z56.string().optional(),
|
|
146105
|
+
client_id_issued_at: z56.number().optional(),
|
|
146106
|
+
client_secret_expires_at: z56.number().optional()
|
|
145917
146107
|
}).strip();
|
|
145918
146108
|
var OAuthClientInformationFullSchema = OAuthClientMetadataSchema.merge(OAuthClientInformationSchema);
|
|
145919
|
-
var OAuthClientRegistrationErrorSchema =
|
|
145920
|
-
error:
|
|
145921
|
-
error_description:
|
|
146109
|
+
var OAuthClientRegistrationErrorSchema = z56.object({
|
|
146110
|
+
error: z56.string(),
|
|
146111
|
+
error_description: z56.string().optional()
|
|
145922
146112
|
}).strip();
|
|
145923
|
-
var OAuthTokenRevocationRequestSchema =
|
|
145924
|
-
token:
|
|
145925
|
-
token_type_hint:
|
|
146113
|
+
var OAuthTokenRevocationRequestSchema = z56.object({
|
|
146114
|
+
token: z56.string(),
|
|
146115
|
+
token_type_hint: z56.string().optional()
|
|
145926
146116
|
}).strip();
|
|
145927
146117
|
|
|
145928
146118
|
// node_modules/.bun/@modelcontextprotocol+sdk@1.30.0/node_modules/@modelcontextprotocol/sdk/dist/esm/shared/auth-utils.js
|
|
@@ -148134,7 +148324,7 @@ function mirrorFilePath(projectDir) {
|
|
|
148134
148324
|
}
|
|
148135
148325
|
|
|
148136
148326
|
// packages/omo-opencode/src/features/tui-sidebar/snapshot-schema.ts
|
|
148137
|
-
import { z as
|
|
148327
|
+
import { z as z57 } from "zod";
|
|
148138
148328
|
var AGENT_STATUS_VALUES = [
|
|
148139
148329
|
"busy",
|
|
148140
148330
|
"idle",
|
|
@@ -148150,32 +148340,32 @@ var BACKGROUND_TASK_STATUS_VALUES = [
|
|
|
148150
148340
|
"cancelled",
|
|
148151
148341
|
"interrupt"
|
|
148152
148342
|
];
|
|
148153
|
-
var AgentRowSchema =
|
|
148154
|
-
name:
|
|
148155
|
-
status:
|
|
148343
|
+
var AgentRowSchema = z57.object({
|
|
148344
|
+
name: z57.string(),
|
|
148345
|
+
status: z57.enum(AGENT_STATUS_VALUES)
|
|
148156
148346
|
});
|
|
148157
|
-
var JobRowSchema =
|
|
148158
|
-
title:
|
|
148159
|
-
status:
|
|
148160
|
-
toolCalls:
|
|
148161
|
-
lastTool:
|
|
148347
|
+
var JobRowSchema = z57.object({
|
|
148348
|
+
title: z57.string(),
|
|
148349
|
+
status: z57.enum(BACKGROUND_TASK_STATUS_VALUES),
|
|
148350
|
+
toolCalls: z57.number().int().nonnegative().nullable(),
|
|
148351
|
+
lastTool: z57.string().nullable()
|
|
148162
148352
|
});
|
|
148163
|
-
var LoopLiveSchema =
|
|
148164
|
-
kind:
|
|
148165
|
-
goalsDone:
|
|
148166
|
-
goalsTotal:
|
|
148167
|
-
pass:
|
|
148168
|
-
fail:
|
|
148169
|
-
pending:
|
|
148170
|
-
blocked:
|
|
148171
|
-
activeGoal:
|
|
148353
|
+
var LoopLiveSchema = z57.object({
|
|
148354
|
+
kind: z57.literal("live"),
|
|
148355
|
+
goalsDone: z57.number().int().nonnegative(),
|
|
148356
|
+
goalsTotal: z57.number().int().nonnegative(),
|
|
148357
|
+
pass: z57.number().int().nonnegative(),
|
|
148358
|
+
fail: z57.number().int().nonnegative(),
|
|
148359
|
+
pending: z57.number().int().nonnegative(),
|
|
148360
|
+
blocked: z57.number().int().nonnegative(),
|
|
148361
|
+
activeGoal: z57.string().nullable()
|
|
148172
148362
|
});
|
|
148173
|
-
var TuiRuntimeSnapshotSchema =
|
|
148174
|
-
version:
|
|
148175
|
-
projectDir:
|
|
148176
|
-
updatedAt:
|
|
148177
|
-
activeAgents:
|
|
148178
|
-
jobBoard:
|
|
148363
|
+
var TuiRuntimeSnapshotSchema = z57.object({
|
|
148364
|
+
version: z57.literal(MIRROR_SCHEMA_VERSION),
|
|
148365
|
+
projectDir: z57.string(),
|
|
148366
|
+
updatedAt: z57.number(),
|
|
148367
|
+
activeAgents: z57.array(AgentRowSchema),
|
|
148368
|
+
jobBoard: z57.array(JobRowSchema),
|
|
148179
148369
|
loop: LoopLiveSchema.nullable()
|
|
148180
148370
|
});
|
|
148181
148371
|
|
|
@@ -148190,25 +148380,25 @@ function writeMirror(projectDir, snapshot) {
|
|
|
148190
148380
|
// packages/omo-opencode/src/features/tui-sidebar/loop-reader.ts
|
|
148191
148381
|
import { readdirSync as readdirSync32, readFileSync as readFileSync71, statSync as statSync14 } from "fs";
|
|
148192
148382
|
import { join as join137 } from "path";
|
|
148193
|
-
import { z as
|
|
148194
|
-
var CriterionSchema =
|
|
148195
|
-
status:
|
|
148383
|
+
import { z as z58 } from "zod";
|
|
148384
|
+
var CriterionSchema = z58.object({
|
|
148385
|
+
status: z58.string()
|
|
148196
148386
|
});
|
|
148197
|
-
var GoalBaseSchema =
|
|
148198
|
-
id:
|
|
148199
|
-
title:
|
|
148200
|
-
status:
|
|
148387
|
+
var GoalBaseSchema = z58.object({
|
|
148388
|
+
id: z58.string(),
|
|
148389
|
+
title: z58.string(),
|
|
148390
|
+
status: z58.string()
|
|
148201
148391
|
});
|
|
148202
|
-
var CurrentLoopSchema =
|
|
148203
|
-
version:
|
|
148204
|
-
activeGoalId:
|
|
148205
|
-
goals:
|
|
148206
|
-
successCriteria:
|
|
148392
|
+
var CurrentLoopSchema = z58.object({
|
|
148393
|
+
version: z58.literal(1),
|
|
148394
|
+
activeGoalId: z58.string().optional(),
|
|
148395
|
+
goals: z58.array(GoalBaseSchema.extend({
|
|
148396
|
+
successCriteria: z58.array(CriterionSchema)
|
|
148207
148397
|
}))
|
|
148208
148398
|
});
|
|
148209
|
-
var LegacyLoopSchema =
|
|
148210
|
-
goals:
|
|
148211
|
-
criteria:
|
|
148399
|
+
var LegacyLoopSchema = z58.object({
|
|
148400
|
+
goals: z58.array(GoalBaseSchema.extend({
|
|
148401
|
+
criteria: z58.array(CriterionSchema)
|
|
148212
148402
|
}))
|
|
148213
148403
|
});
|
|
148214
148404
|
function readActiveLoop(projectDir) {
|
|
@@ -152812,6 +153002,12 @@ function buildGptSisyphusAgentConfig(mode, model, prompt) {
|
|
|
152812
153002
|
function buildGlmSisyphusAgentConfig(mode, model, prompt) {
|
|
152813
153003
|
return buildBaseSisyphusAgentConfig(mode, model, prompt);
|
|
152814
153004
|
}
|
|
153005
|
+
function buildGrokSisyphusAgentConfig(mode, model, prompt) {
|
|
153006
|
+
return {
|
|
153007
|
+
...buildBaseSisyphusAgentConfig(mode, model, prompt),
|
|
153008
|
+
reasoningEffort: "high"
|
|
153009
|
+
};
|
|
153010
|
+
}
|
|
152815
153011
|
function buildClaudeSisyphusAgentConfig(mode, model, prompt) {
|
|
152816
153012
|
return {
|
|
152817
153013
|
...buildBaseSisyphusAgentConfig(mode, model, prompt),
|
|
@@ -156181,6 +156377,158 @@ function buildGpt55SisyphusPrompt(model, availableAgents, _availableTools = [],
|
|
|
156181
156377
|
${body}`;
|
|
156182
156378
|
}
|
|
156183
156379
|
|
|
156380
|
+
// packages/omo-opencode/src/agents/sisyphus/grok-4.ts
|
|
156381
|
+
function getGrokPromptIdentity(model) {
|
|
156382
|
+
return isGrok46Model(model) ? "Grok 4.6" : "Grok 4.5";
|
|
156383
|
+
}
|
|
156384
|
+
function buildGrok4TasksSection(useTaskSystem) {
|
|
156385
|
+
const noun = useTaskSystem ? "tasks" : "todos";
|
|
156386
|
+
const create = useTaskSystem ? "task_create" : "todowrite";
|
|
156387
|
+
const update = useTaskSystem ? "task_update" : "todowrite";
|
|
156388
|
+
const hook = useTaskSystem ? "TASK CONTINUATION" : "TODO CONTINUATION";
|
|
156389
|
+
return `<tasks>
|
|
156390
|
+
Use ${noun} for implementation work with two or more real steps, cross-file edits, delegated work, or uncertain scope. Skip tracking for direct answers, pure exploration, and one-step edits.
|
|
156391
|
+
|
|
156392
|
+
When tracking: call \`${create}\` before implementation, keep exactly one item \`in_progress\`, and call \`${update}\` the moment an item is done. Never batch completions. If scope changes, revise the list before more edits.
|
|
156393
|
+
|
|
156394
|
+
Your ${noun} are tracked by the harness via [SYSTEM REMINDER - ${hook}].
|
|
156395
|
+
</tasks>`;
|
|
156396
|
+
}
|
|
156397
|
+
function buildGrok4SisyphusPrompt(model, availableAgents, availableTools = [], availableSkills = [], availableCategories = [], useTaskSystem = false) {
|
|
156398
|
+
const keyTriggers = buildKeyTriggersSection(availableAgents, availableSkills);
|
|
156399
|
+
const toolSelection = buildToolSelectionTable(availableAgents, availableTools, availableSkills);
|
|
156400
|
+
const exploreSection = buildExploreSection(availableAgents);
|
|
156401
|
+
const librarianSection = buildLibrarianSection(availableAgents);
|
|
156402
|
+
const categorySkillsGuide = buildCategorySkillsDelegationGuide(availableCategories, availableSkills);
|
|
156403
|
+
const delegationTable = buildDelegationTable(availableAgents);
|
|
156404
|
+
const oracleSection = buildOracleSection(availableAgents);
|
|
156405
|
+
const hardBlocks = buildHardBlocksSection();
|
|
156406
|
+
const antiPatterns = buildAntiPatternsSection();
|
|
156407
|
+
const nonClaudePlannerSection = buildNonClaudePlannerSection(model);
|
|
156408
|
+
const tasksSection = buildGrok4TasksSection(useTaskSystem);
|
|
156409
|
+
const agentIdentity = buildAgentIdentitySection("Sisyphus", "Powerful AI Agent with orchestration capabilities from OhMyOpenCode");
|
|
156410
|
+
const roleBlock = `<role>
|
|
156411
|
+
You are Sisyphus, the OhMyOpenCode orchestration lead, running on ${getGrokPromptIdentity(model)}.
|
|
156412
|
+
|
|
156413
|
+
You are a senior engineer who scales output through specialists. Understand the user's destination, route the work to the right specialist, verify with real evidence, and stop only when the result is production ready.
|
|
156414
|
+
|
|
156415
|
+
Implementation starts only when the current user turn explicitly asks for it with concrete scope. Questions get answers, investigations get findings, implementation requests get shipped work.
|
|
156416
|
+
</role>`;
|
|
156417
|
+
const calibrationBlock = `<grok_calibration>
|
|
156418
|
+
Your judgment is good; this prompt stays short on purpose and trusts you to fill gaps with taste. Four rules carry the leverage:
|
|
156419
|
+
|
|
156420
|
+
1. DONE IS WRITTEN DOWN. Before implementation, state what done means in one line: observable acceptance criteria, not a vibe. You verify against exactly those criteria, and you neither stop short of them nor expand past them.
|
|
156421
|
+
2. VERIFY, THEN ITERATE. Verify the function and the design after implementation, and keep iterating and verifying until it is production ready. One pass of "it runs" is not done.
|
|
156422
|
+
3. CAPTURE, LIST, FIX. When output is hard to inspect (visual, layout, motion, formatted documents), capture the current state, list concretely what is wrong with it, then fix only those things. Never "improve" blind.
|
|
156423
|
+
4. NO REPEATED BLOCKS. You tend to duplicate code across components. The second time a block appears, extract and share it instead of pasting a third copy.
|
|
156424
|
+
</grok_calibration>`;
|
|
156425
|
+
const intentBlock = `<intent>
|
|
156426
|
+
Classify the CURRENT user message only. Do not carry implementation authorization across turns.
|
|
156427
|
+
|
|
156428
|
+
${keyTriggers}
|
|
156429
|
+
|
|
156430
|
+
Surface form to routing:
|
|
156431
|
+
|
|
156432
|
+
| User says | True intent | You do |
|
|
156433
|
+
|---|---|---|
|
|
156434
|
+
| "explain", "how does" | understanding | explore enough, then answer |
|
|
156435
|
+
| "implement", "add", "create", "write" | implementation | plan, delegate or execute, verify |
|
|
156436
|
+
| "look into", "check", "investigate" | investigation | inspect, report findings, wait |
|
|
156437
|
+
| "what do you think" | evaluation | judge, propose, wait |
|
|
156438
|
+
| "broken", "error", "fix" | root-cause repair | diagnose, fix minimally, verify |
|
|
156439
|
+
| "refactor", "improve", "clean up" | open-ended change | assess, propose or use the matching skill |
|
|
156440
|
+
|
|
156441
|
+
Say one concise intent line before non-trivial action: "I read this as [type]: [route]." If the answer is already in context, answer instead of re-deriving.
|
|
156442
|
+
|
|
156443
|
+
Ask only for scope changes, critical missing information, destructive actions, or external side effects. Minor decisions (names, defaults, equivalent approaches) are yours; note the choice later.
|
|
156444
|
+
</intent>`;
|
|
156445
|
+
const explorationBlock = `<exploration>
|
|
156446
|
+
Use tools for facts. Internal memory is not evidence for file contents, configs, APIs, or current project state.
|
|
156447
|
+
|
|
156448
|
+
${toolSelection}
|
|
156449
|
+
|
|
156450
|
+
${exploreSection}
|
|
156451
|
+
|
|
156452
|
+
${librarianSection}
|
|
156453
|
+
|
|
156454
|
+
Parallelize independent calls: file reads, searches, diagnostics, and background agents go out together. Sequence only when a later call needs an earlier result.
|
|
156455
|
+
|
|
156456
|
+
Search budget: known file or symbol = direct read/search; unfamiliar local pattern = one parallel wave; external package or API = librarian; architectural risk = Oracle. Stop when sources converge, the target file set is known, or the answer is found.
|
|
156457
|
+
|
|
156458
|
+
Fire explore/librarian in the background with [CONTEXT], [GOAL], [DOWNSTREAM], and [REQUEST]. Continue only with non-overlapping work; otherwise end the turn and wait for the completion reminder before calling \`background_output(task_id="bg_...")\`. Use \`task(task_id="ses_...")\` only for follow-ups to the same subagent.
|
|
156459
|
+
|
|
156460
|
+
${buildAntiDuplicationSection()}
|
|
156461
|
+
</exploration>`;
|
|
156462
|
+
const delegationBlock = `<delegation>
|
|
156463
|
+
Prefer delegation when a specialist fits, the work spans multiple files, the domain is visual/frontend/security/performance, or the module is unfamiliar. Execute directly only for small, local, fully understood changes.
|
|
156464
|
+
|
|
156465
|
+
${categorySkillsGuide}
|
|
156466
|
+
|
|
156467
|
+
${nonClaudePlannerSection}
|
|
156468
|
+
|
|
156469
|
+
${delegationTable}
|
|
156470
|
+
|
|
156471
|
+
Every delegation prompt carries six sections: TASK, EXPECTED OUTCOME, REQUIRED TOOLS, MUST DO, MUST NOT DO, CONTEXT. The EXPECTED OUTCOME is the delegate's definition of done - make it observable.
|
|
156472
|
+
|
|
156473
|
+
After delegation, verify the files and behavior yourself. A subagent report is a lead, not evidence.
|
|
156474
|
+
${oracleSection ? `
|
|
156475
|
+
${oracleSection}
|
|
156476
|
+
` : ""}</delegation>`;
|
|
156477
|
+
const executionBlock = `<behavior>
|
|
156478
|
+
Implementation loop:
|
|
156479
|
+
|
|
156480
|
+
1. Write down what done means, then plan the smallest path to it. Two or more steps need ${useTaskSystem ? "tasks" : "todos"}; one obvious edit does not.
|
|
156481
|
+
2. Match the repo: read configs and similar files before writing. Do not invent style.
|
|
156482
|
+
3. Change only what the request requires. Bug fix does not mean refactor. Refactor does not mean feature work.
|
|
156483
|
+
4. Use type-safe code. No type suppression, no speculative fallbacks, no helpers for one-off operations, no validation away from trust boundaries.
|
|
156484
|
+
5. On failure, read the error, identify the root cause, try a materially different approach, and re-verify. After three failed approaches, stop editing and consult Oracle, or ask if Oracle cannot resolve it.
|
|
156485
|
+
|
|
156486
|
+
Never revert, delete, push, publish, message, or affect shared systems without explicit approval. Reversible local edits and verification commands are allowed.
|
|
156487
|
+
</behavior>`;
|
|
156488
|
+
const verificationBlock = `<verification>
|
|
156489
|
+
Verification defines done, and it loops until production ready.
|
|
156490
|
+
|
|
156491
|
+
- File edit: run \`lsp_diagnostics\` on every changed file.
|
|
156492
|
+
- Behavioral change: run adjacent tests or the smallest relevant suite.
|
|
156493
|
+
- Buildable project: run the build/typecheck path that covers the touched code.
|
|
156494
|
+
- Runnable or user-visible behavior: exercise the real surface - browser for web, interactive_bash for TUI/CLI, curl for HTTP, driver script for libraries. Click through the real user path, not just the happy entry point.
|
|
156495
|
+
- Hard-to-inspect output: capture the current state, list what is wrong, fix only those things, capture again.
|
|
156496
|
+
- Delegated work: inspect touched files and rerun checks yourself.
|
|
156497
|
+
|
|
156498
|
+
A pass that surfaces a defect goes back to step one of the loop, not into the report. Report only evidence from this turn: "should pass" means unverified. Fix failures caused by your change; name unrelated pre-existing failures without widening scope.
|
|
156499
|
+
</verification>`;
|
|
156500
|
+
const communicationBlock = `<communication>
|
|
156501
|
+
Every sentence carries information the user does not already have. Never restate the task back, never narrate routine tool calls, no flattery or filler.
|
|
156502
|
+
|
|
156503
|
+
Stay quiet through small changes; start narrating when you touch many files or change direction. Final answers state what changed, where, the verification evidence, and any real residual risk - dense and short.
|
|
156504
|
+
</communication>`;
|
|
156505
|
+
const constraintsBlock = `<constraints>
|
|
156506
|
+
${hardBlocks}
|
|
156507
|
+
|
|
156508
|
+
${antiPatterns}
|
|
156509
|
+
</constraints>`;
|
|
156510
|
+
return `${agentIdentity}
|
|
156511
|
+
${roleBlock}
|
|
156512
|
+
|
|
156513
|
+
${calibrationBlock}
|
|
156514
|
+
|
|
156515
|
+
${intentBlock}
|
|
156516
|
+
|
|
156517
|
+
${explorationBlock}
|
|
156518
|
+
|
|
156519
|
+
${delegationBlock}
|
|
156520
|
+
|
|
156521
|
+
${executionBlock}
|
|
156522
|
+
|
|
156523
|
+
${verificationBlock}
|
|
156524
|
+
|
|
156525
|
+
${tasksSection}
|
|
156526
|
+
|
|
156527
|
+
${communicationBlock}
|
|
156528
|
+
|
|
156529
|
+
${constraintsBlock}`;
|
|
156530
|
+
}
|
|
156531
|
+
|
|
156184
156532
|
// packages/omo-opencode/src/agents/kimi-tool-loop-guard.ts
|
|
156185
156533
|
var KIMI_TOOL_LOOP_GUARD = `<tool_loop_guard>
|
|
156186
156534
|
Never call the same tool with the same arguments more than twice in a row.
|
|
@@ -157048,6 +157396,8 @@ function resolveSisyphusPromptFamily(model) {
|
|
|
157048
157396
|
return "claude-opus-4-7";
|
|
157049
157397
|
if (isGlmModel(model))
|
|
157050
157398
|
return "glm-5-2";
|
|
157399
|
+
if (isGrok45Model(model) || isGrok46Model(model))
|
|
157400
|
+
return "grok-4";
|
|
157051
157401
|
return "fallback";
|
|
157052
157402
|
}
|
|
157053
157403
|
function createSisyphusAgent(model, availableAgents, availableToolNames, availableSkills, availableCategories, useTaskSystem = false) {
|
|
@@ -157076,6 +157426,8 @@ function createSisyphusAgent(model, availableAgents, availableToolNames, availab
|
|
|
157076
157426
|
return buildClaudeSisyphusAgentConfig(MODE, model, buildClaudeOpus47SisyphusPrompt(model, agents, tools, skills2, categories2, useTaskSystem));
|
|
157077
157427
|
case "glm-5-2":
|
|
157078
157428
|
return buildGlmSisyphusAgentConfig(MODE, model, buildGlm52SisyphusPrompt(model, agents, tools, skills2, categories2, useTaskSystem));
|
|
157429
|
+
case "grok-4":
|
|
157430
|
+
return buildGrokSisyphusAgentConfig(MODE, model, buildGrok4SisyphusPrompt(model, agents, tools, skills2, categories2, useTaskSystem));
|
|
157079
157431
|
case "fallback": {
|
|
157080
157432
|
const prompt = buildFallbackSisyphusPrompt(model, agents, tools, skills2, categories2, useTaskSystem);
|
|
157081
157433
|
return isGptModel(model) ? buildGptSisyphusAgentConfig(MODE, model, prompt) : buildClaudeSisyphusAgentConfig(MODE, model, prompt);
|
|
@@ -161750,7 +162102,7 @@ function setSisyphusRuntimePromptContext(ctx) {
|
|
|
161750
162102
|
function reconcileSisyphusRuntimePrompt(system, runtimeModel) {
|
|
161751
162103
|
if (!runtimeModel || !context)
|
|
161752
162104
|
return false;
|
|
161753
|
-
if (
|
|
162105
|
+
if (runtimeModel === context.configuredModel) {
|
|
161754
162106
|
return false;
|
|
161755
162107
|
}
|
|
161756
162108
|
const rebuilt = context.rebuildPromptForModel(runtimeModel);
|
|
@@ -163224,7 +163576,7 @@ function createCodegraphMcpConfig(options = {}) {
|
|
|
163224
163576
|
import { existsSync as existsSync115, readFileSync as readFileSync78 } from "fs";
|
|
163225
163577
|
import { delimiter as delimiter2, dirname as dirname50, resolve as resolve44 } from "path";
|
|
163226
163578
|
import { fileURLToPath as fileURLToPath8 } from "url";
|
|
163227
|
-
import { z as
|
|
163579
|
+
import { z as z59 } from "zod";
|
|
163228
163580
|
|
|
163229
163581
|
// packages/omo-opencode/src/mcp/cli-suffix.ts
|
|
163230
163582
|
function normalizeCliPath(path21) {
|
|
@@ -163290,8 +163642,8 @@ var PROJECT_LSP_CONFIGS = [".opencode/lsp.json", ".omo/lsp.json", ".omo/lsp-clie
|
|
|
163290
163642
|
var DAEMON_PACKAGE_NAME = "@code-yeongyu/lsp-daemon";
|
|
163291
163643
|
var OMO_LSP_DAEMON_CLI = "OMO_LSP_DAEMON_CLI";
|
|
163292
163644
|
var OMO_LSP_DAEMON_VERSION = "OMO_LSP_DAEMON_VERSION";
|
|
163293
|
-
var DaemonPackageSchema =
|
|
163294
|
-
version:
|
|
163645
|
+
var DaemonPackageSchema = z59.object({
|
|
163646
|
+
version: z59.string().min(1)
|
|
163295
163647
|
});
|
|
163296
163648
|
var LSP_BOOTSTRAP_SCRIPT = [
|
|
163297
163649
|
"const { existsSync } = require('node:fs')",
|
|
@@ -167556,14 +167908,14 @@ class OpencodeClient2 extends HeyApiClient {
|
|
|
167556
167908
|
// node_modules/.bun/@opencode-ai+sdk@1.15.13/node_modules/@opencode-ai/sdk/dist/v2/server.js
|
|
167557
167909
|
var import_cross_spawn3 = __toESM(require_cross_spawn(), 1);
|
|
167558
167910
|
// packages/omo-opencode/src/plugin/native-skills.ts
|
|
167559
|
-
import { z as
|
|
167560
|
-
var NativeSkillEntrySchema =
|
|
167561
|
-
name:
|
|
167562
|
-
description:
|
|
167563
|
-
location:
|
|
167564
|
-
content:
|
|
167911
|
+
import { z as z60 } from "zod";
|
|
167912
|
+
var NativeSkillEntrySchema = z60.object({
|
|
167913
|
+
name: z60.string(),
|
|
167914
|
+
description: z60.string().default(""),
|
|
167915
|
+
location: z60.string(),
|
|
167916
|
+
content: z60.string()
|
|
167565
167917
|
});
|
|
167566
|
-
var NativeSkillEntriesSchema =
|
|
167918
|
+
var NativeSkillEntriesSchema = z60.array(NativeSkillEntrySchema);
|
|
167567
167919
|
function getObjectProperty(value, property) {
|
|
167568
167920
|
if (typeof value !== "object" || value === null)
|
|
167569
167921
|
return;
|
|
@@ -168708,7 +169060,7 @@ async function resolveParticipant2(teamRunId, sessionID, config3, deps) {
|
|
|
168708
169060
|
}
|
|
168709
169061
|
|
|
168710
169062
|
// packages/omo-opencode/src/features/team-mode/tools/lifecycle-inline-spec.ts
|
|
168711
|
-
import { z as
|
|
169063
|
+
import { z as z61 } from "zod";
|
|
168712
169064
|
init_types5();
|
|
168713
169065
|
var TEAM_CREATE_USAGE = 'team_create requires exactly one of teamName or inline_spec. Use team_create({ teamName: "existing-team" }) or team_create({ inline_spec: { name: "team-name", members: [{ name: "worker", category: "quick", prompt: "Do the assigned work." }] } }).';
|
|
168714
169066
|
function omitEmptyStringArgs(rawArgs) {
|
|
@@ -168717,10 +169069,10 @@ function omitEmptyStringArgs(rawArgs) {
|
|
|
168717
169069
|
}
|
|
168718
169070
|
return Object.fromEntries(Object.entries(rawArgs).filter(([, value]) => value !== ""));
|
|
168719
169071
|
}
|
|
168720
|
-
var TeamCreateArgsSchema =
|
|
168721
|
-
teamName:
|
|
168722
|
-
inline_spec:
|
|
168723
|
-
leadSessionId:
|
|
169072
|
+
var TeamCreateArgsSchema = z61.preprocess(omitEmptyStringArgs, z61.object({
|
|
169073
|
+
teamName: z61.string().min(1).nullish(),
|
|
169074
|
+
inline_spec: z61.unknown().nullish(),
|
|
169075
|
+
leadSessionId: z61.string().nullish()
|
|
168724
169076
|
}).superRefine((value, ctx) => {
|
|
168725
169077
|
const optionCount = Number(value.teamName != null) + Number(value.inline_spec != null);
|
|
168726
169078
|
if (optionCount !== 1) {
|
|
@@ -168841,7 +169193,7 @@ function createTeamCreateTool(config3, client5, bgMgr, tmuxMgr, executorConfig,
|
|
|
168841
169193
|
});
|
|
168842
169194
|
}
|
|
168843
169195
|
// packages/omo-opencode/src/features/team-mode/tools/lifecycle-shutdown-tools.ts
|
|
168844
|
-
import { z as
|
|
169196
|
+
import { z as z62 } from "zod";
|
|
168845
169197
|
// packages/omo-opencode/src/features/team-mode/team-runtime/shutdown.ts
|
|
168846
169198
|
init_store3();
|
|
168847
169199
|
init_shutdown_helpers();
|
|
@@ -168930,13 +169282,13 @@ async function rejectShutdown(teamRunId, memberName, rejectorName, reason, confi
|
|
|
168930
169282
|
|
|
168931
169283
|
// packages/omo-opencode/src/features/team-mode/tools/lifecycle-shutdown-tools.ts
|
|
168932
169284
|
init_store2();
|
|
168933
|
-
var TeamDeleteArgsSchema =
|
|
168934
|
-
var TeamShutdownRequestArgsSchema =
|
|
168935
|
-
var TeamApproveShutdownArgsSchema =
|
|
168936
|
-
var TeamRejectShutdownArgsSchema =
|
|
168937
|
-
teamRunId:
|
|
168938
|
-
memberName:
|
|
168939
|
-
reason:
|
|
169285
|
+
var TeamDeleteArgsSchema = z62.object({ teamRunId: z62.string().min(1), force: z62.boolean().optional() });
|
|
169286
|
+
var TeamShutdownRequestArgsSchema = z62.object({ teamRunId: z62.string().min(1), targetMemberName: z62.string().min(1) });
|
|
169287
|
+
var TeamApproveShutdownArgsSchema = z62.object({ teamRunId: z62.string().min(1), memberName: z62.string().min(1) });
|
|
169288
|
+
var TeamRejectShutdownArgsSchema = z62.object({
|
|
169289
|
+
teamRunId: z62.string().min(1),
|
|
169290
|
+
memberName: z62.string().min(1),
|
|
169291
|
+
reason: z62.string().min(1)
|
|
168940
169292
|
});
|
|
168941
169293
|
var defaultTeamShutdownToolDeps = {
|
|
168942
169294
|
listActiveTeams,
|
|
@@ -170733,9 +171085,16 @@ function createMessagesTransformHandler(args) {
|
|
|
170733
171085
|
|
|
170734
171086
|
// packages/omo-opencode/src/plugin/system-transform.ts
|
|
170735
171087
|
var ULTRAWORK_MODE_TAG = "<ultrawork-mode>";
|
|
171088
|
+
function toCanonicalModel(model) {
|
|
171089
|
+
if (!model?.id)
|
|
171090
|
+
return;
|
|
171091
|
+
if (model.id.includes("/") || !model.providerID)
|
|
171092
|
+
return model.id;
|
|
171093
|
+
return `${model.providerID}/${model.id}`;
|
|
171094
|
+
}
|
|
170736
171095
|
function createSystemTransformHandler(defaultMode, getUltraworkMessage2) {
|
|
170737
171096
|
return async (input, output) => {
|
|
170738
|
-
reconcileSisyphusRuntimePrompt(output.system, input.model
|
|
171097
|
+
reconcileSisyphusRuntimePrompt(output.system, toCanonicalModel(input.model));
|
|
170739
171098
|
if (!defaultMode?.ultrawork || !getUltraworkMessage2)
|
|
170740
171099
|
return;
|
|
170741
171100
|
if (output.system.some((part) => part.includes(ULTRAWORK_MODE_TAG)))
|
|
@@ -172772,6 +173131,7 @@ function writePostHogActivityState(stateDir, nextState, diagnostics) {
|
|
|
172772
173131
|
// packages/telemetry-core/src/constants.ts
|
|
172773
173132
|
var DEFAULT_POSTHOG_HOST = "https://us.i.posthog.com";
|
|
172774
173133
|
var DEFAULT_POSTHOG_API_KEY = "phc_CFJhj5HyvA62QPhvyaUCtaq23aUfznnijg5VaaGkNk74";
|
|
173134
|
+
var UNCONFIGURED_POSTHOG_API_KEY = "phc_REPLACE_ME_OMO_NATIVE";
|
|
172775
173135
|
|
|
172776
173136
|
// packages/telemetry-core/src/env.ts
|
|
172777
173137
|
var TRUTHY_DISABLE_VALUES = ["1", "true", "yes"];
|
|
@@ -172793,6 +173153,9 @@ function shouldDisableTelemetry(input) {
|
|
|
172793
173153
|
const env2 = input.env ?? process.env;
|
|
172794
173154
|
const globalPrefix = input.globalEnvPrefix ?? "OMO";
|
|
172795
173155
|
const prefixes = Array.from(new Set([globalPrefix, input.productEnvPrefix]));
|
|
173156
|
+
if (isDisableFlag(env2["DO_NOT_TRACK"])) {
|
|
173157
|
+
return true;
|
|
173158
|
+
}
|
|
172796
173159
|
for (const prefix of prefixes) {
|
|
172797
173160
|
if (isDisableFlag(env2[`${prefix}_DISABLE_POSTHOG`])) {
|
|
172798
173161
|
return true;
|
|
@@ -172806,18 +173169,15 @@ function shouldDisableTelemetry(input) {
|
|
|
172806
173169
|
function getTelemetryApiKey(env2 = process.env, defaultApiKey = DEFAULT_POSTHOG_API_KEY) {
|
|
172807
173170
|
return env2["POSTHOG_API_KEY"]?.trim() ?? defaultApiKey;
|
|
172808
173171
|
}
|
|
172809
|
-
function
|
|
172810
|
-
|
|
173172
|
+
function isConfiguredTelemetryApiKey(apiKey) {
|
|
173173
|
+
const normalized = apiKey.trim();
|
|
173174
|
+
return normalized.length > 0 && normalized !== UNCONFIGURED_POSTHOG_API_KEY;
|
|
172811
173175
|
}
|
|
172812
|
-
|
|
172813
|
-
|
|
172814
|
-
import { createHash as createHash9 } from "crypto";
|
|
172815
|
-
import os6 from "os";
|
|
172816
|
-
function getDefaultTelemetryOsProvider() {
|
|
172817
|
-
return os6;
|
|
173176
|
+
function hasTelemetryApiKey(env2, defaultApiKey) {
|
|
173177
|
+
return isConfiguredTelemetryApiKey(getTelemetryApiKey(env2, defaultApiKey));
|
|
172818
173178
|
}
|
|
172819
|
-
function
|
|
172820
|
-
return
|
|
173179
|
+
function getTelemetryHost(env2 = process.env, defaultHost = DEFAULT_POSTHOG_HOST) {
|
|
173180
|
+
return env2["POSTHOG_HOST"]?.trim() || defaultHost;
|
|
172821
173181
|
}
|
|
172822
173182
|
|
|
172823
173183
|
// node_modules/.bun/posthog-node@5.35.12/node_modules/posthog-node/dist/extensions/error-tracking/modifiers/module.node.mjs
|
|
@@ -174143,7 +174503,7 @@ var FULL_MATCH = /at (?:async )?(?:(.+?)\s+\()?(?:(.+):(\d+):(\d+)?|([^)]+))\)?/
|
|
|
174143
174503
|
var nodeStackLineParser = (line, platform2) => {
|
|
174144
174504
|
const lineMatch = line.match(FULL_MATCH);
|
|
174145
174505
|
if (lineMatch) {
|
|
174146
|
-
let
|
|
174506
|
+
let object19;
|
|
174147
174507
|
let method;
|
|
174148
174508
|
let functionName;
|
|
174149
174509
|
let typeName;
|
|
@@ -174154,18 +174514,18 @@ var nodeStackLineParser = (line, platform2) => {
|
|
|
174154
174514
|
if (functionName[methodStart - 1] === ".")
|
|
174155
174515
|
methodStart--;
|
|
174156
174516
|
if (methodStart > 0) {
|
|
174157
|
-
|
|
174517
|
+
object19 = functionName.slice(0, methodStart);
|
|
174158
174518
|
method = functionName.slice(methodStart + 1);
|
|
174159
|
-
const objectEnd =
|
|
174519
|
+
const objectEnd = object19.indexOf(".Module");
|
|
174160
174520
|
if (objectEnd > 0) {
|
|
174161
174521
|
functionName = functionName.slice(objectEnd + 1);
|
|
174162
|
-
|
|
174522
|
+
object19 = object19.slice(0, objectEnd);
|
|
174163
174523
|
}
|
|
174164
174524
|
}
|
|
174165
174525
|
typeName = undefined;
|
|
174166
174526
|
}
|
|
174167
174527
|
if (method) {
|
|
174168
|
-
typeName =
|
|
174528
|
+
typeName = object19;
|
|
174169
174529
|
methodName = method;
|
|
174170
174530
|
}
|
|
174171
174531
|
if (method === "<anonymous>") {
|
|
@@ -177987,6 +178347,16 @@ class PostHog extends PostHogBackendClient {
|
|
|
177987
178347
|
}
|
|
177988
178348
|
}
|
|
177989
178349
|
|
|
178350
|
+
// packages/telemetry-core/src/machine-id.ts
|
|
178351
|
+
import { createHash as createHash9 } from "crypto";
|
|
178352
|
+
import os6 from "os";
|
|
178353
|
+
function getDefaultTelemetryOsProvider() {
|
|
178354
|
+
return os6;
|
|
178355
|
+
}
|
|
178356
|
+
function getTelemetryDistinctId(machineIdPrefix, osProvider = getDefaultTelemetryOsProvider()) {
|
|
178357
|
+
return createHash9("sha256").update(`${machineIdPrefix}${osProvider.hostname()}`).digest("hex");
|
|
178358
|
+
}
|
|
178359
|
+
|
|
177990
178360
|
// packages/telemetry-core/src/posthog-client.ts
|
|
177991
178361
|
var NO_OP_CLIENT = {
|
|
177992
178362
|
enabled: false,
|
|
@@ -178021,7 +178391,7 @@ function createDefaultPostHogTransport(apiKey, options) {
|
|
|
178021
178391
|
}
|
|
178022
178392
|
function isTelemetryClientEnabled(input) {
|
|
178023
178393
|
const env2 = input.env ?? process.env;
|
|
178024
|
-
return !shouldDisableTelemetry({ env: env2, productEnvPrefix: input.product.productEnvPrefix }) &&
|
|
178394
|
+
return !shouldDisableTelemetry({ env: env2, productEnvPrefix: input.product.productEnvPrefix }) && hasTelemetryApiKey(env2, input.product.defaultApiKey);
|
|
178025
178395
|
}
|
|
178026
178396
|
function createTelemetryClient(input) {
|
|
178027
178397
|
if (!isTelemetryClientEnabled(input)) {
|
|
@@ -178087,7 +178457,8 @@ function createTransport(input) {
|
|
|
178087
178457
|
flushAt: 1,
|
|
178088
178458
|
flushInterval: 0,
|
|
178089
178459
|
host: getTelemetryHost(env2, input.product.defaultHost),
|
|
178090
|
-
disableGeoip: false
|
|
178460
|
+
disableGeoip: input.product.disableGeoip ?? false,
|
|
178461
|
+
...input.product.transportOptions
|
|
178091
178462
|
});
|
|
178092
178463
|
} catch (error) {
|
|
178093
178464
|
input.diagnostics?.({
|