oh-my-opencode 3.17.1 → 3.17.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.ja.md +4 -0
- package/README.ko.md +4 -0
- package/README.ru.md +4 -0
- package/README.zh-cn.md +4 -0
- package/dist/cli/index.js +888 -614
- package/dist/cli/install-validators.d.ts +1 -0
- package/dist/cli/model-fallback-types.d.ts +1 -0
- package/dist/cli/provider-model-id-transform.d.ts +1 -1
- package/dist/cli/types.d.ts +3 -0
- package/dist/config/schema/agent-definitions.d.ts +3 -0
- package/dist/config/schema/oh-my-opencode-config.d.ts +1 -0
- package/dist/features/background-agent/session-existence.d.ts +1 -1
- package/dist/features/background-agent/subagent-spawn-limits.d.ts +1 -1
- package/dist/features/background-agent/task-poller.d.ts +1 -0
- package/dist/features/claude-code-agent-loader/agent-definitions-loader.d.ts +3 -0
- package/dist/features/claude-code-agent-loader/index.d.ts +3 -0
- package/dist/features/claude-code-agent-loader/json-agent-loader.d.ts +2 -0
- package/dist/features/claude-code-agent-loader/loader.d.ts +2 -0
- package/dist/features/claude-code-agent-loader/opencode-config-agents-reader.d.ts +2 -0
- package/dist/features/claude-code-agent-loader/types.d.ts +9 -1
- package/dist/hooks/atlas/system-reminder-templates.d.ts +2 -2
- package/dist/hooks/directory-agents-injector/hook.d.ts +7 -7
- package/dist/hooks/directory-readme-injector/hook.d.ts +7 -7
- package/dist/hooks/keyword-detector/ultrawork/default.d.ts +1 -1
- package/dist/hooks/keyword-detector/ultrawork/gemini.d.ts +1 -1
- package/dist/hooks/keyword-detector/ultrawork/gpt.d.ts +1 -1
- package/dist/hooks/keyword-detector/ultrawork/planner.d.ts +1 -1
- package/dist/hooks/model-fallback/next-fallback.d.ts +8 -0
- package/dist/index.js +1455 -842
- package/dist/oh-my-opencode.schema.json +7 -0
- package/dist/shared/agent-tool-restrictions.d.ts +0 -5
- package/dist/shared/index.d.ts +2 -0
- package/dist/shared/parse-tools-config.d.ts +6 -0
- package/dist/shared/resolve-agent-definition-paths.d.ts +1 -0
- package/dist/tools/call-omo-agent/agent-resolver.d.ts +17 -0
- package/dist/tools/call-omo-agent/constants.d.ts +1 -1
- package/dist/tools/delegate-task/delegated-model-config.d.ts +3 -0
- package/dist/tools/delegate-task/fallback-entry-resolution.d.ts +12 -0
- package/dist/tools/delegate-task/fallback-entry-settings.d.ts +7 -0
- package/dist/tools/delegate-task/subagent-discovery.d.ts +15 -0
- package/dist/tools/delegate-task/sync-task-fallback.d.ts +12 -0
- package/dist/tools/skill/constants.d.ts +1 -1
- package/package.json +12 -12
|
@@ -1,7 +1,2 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Agent tool restrictions for session.prompt calls.
|
|
3
|
-
* OpenCode SDK's session.prompt `tools` parameter expects boolean values.
|
|
4
|
-
* true = tool allowed, false = tool denied.
|
|
5
|
-
*/
|
|
6
1
|
export declare function getAgentToolRestrictions(agentName: string): Record<string, boolean>;
|
|
7
2
|
export declare function hasAgentToolRestrictions(agentName: string): boolean;
|
package/dist/shared/index.d.ts
CHANGED
|
@@ -17,6 +17,7 @@ export * from "./claude-config-dir";
|
|
|
17
17
|
export * from "./jsonc-parser";
|
|
18
18
|
export * from "./migration";
|
|
19
19
|
export * from "./opencode-config-dir";
|
|
20
|
+
export * from "./resolve-agent-definition-paths";
|
|
20
21
|
export type { OpenCodeBinaryType, OpenCodeConfigDirOptions, OpenCodeConfigPaths, } from "./opencode-config-dir-types";
|
|
21
22
|
export * from "./opencode-version";
|
|
22
23
|
export * from "./opencode-storage-detection";
|
|
@@ -67,3 +68,4 @@ export { SessionCategoryRegistry } from "./session-category-registry";
|
|
|
67
68
|
export * from "./plugin-identity";
|
|
68
69
|
export * from "./log-legacy-plugin-startup-warning";
|
|
69
70
|
export * from "./task-system-enabled";
|
|
71
|
+
export * from "./parse-tools-config";
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Parses a tools configuration value into a boolean record.
|
|
3
|
+
* Accepts comma-separated strings, string arrays, or unknown values from config files.
|
|
4
|
+
* Returns undefined when input is empty or invalid.
|
|
5
|
+
*/
|
|
6
|
+
export declare function parseToolsConfig(toolsValue: unknown): Record<string, boolean> | undefined;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare function resolveAgentDefinitionPaths(paths: string[], baseDir: string, containmentDir: string | null): string[];
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import type { PluginInput } from "@opencode-ai/plugin";
|
|
2
|
+
export declare function clearCallableAgentsCache(): void;
|
|
3
|
+
/**
|
|
4
|
+
* Resolves the set of callable agent names at execute-time by merging the
|
|
5
|
+
* hardcoded `ALLOWED_AGENTS` with any additional agents discovered dynamically
|
|
6
|
+
* via `client.app.agents()`. Custom agents loaded from registered agent
|
|
7
|
+
* directories appear here alongside built-ins.
|
|
8
|
+
*
|
|
9
|
+
* Results are cached per session for 30s to avoid redundant SDK IPC calls.
|
|
10
|
+
*
|
|
11
|
+
* Falls back to `ALLOWED_AGENTS` alone if the dynamic lookup fails.
|
|
12
|
+
*
|
|
13
|
+
* @param client - The plugin client with access to the agent registry
|
|
14
|
+
* @param sessionId - Optional session ID for cache scoping
|
|
15
|
+
* @returns Array of lowercase callable agent names (excludes primary-mode agents)
|
|
16
|
+
*/
|
|
17
|
+
export declare function resolveCallableAgents(client: PluginInput["client"], sessionId?: string): Promise<string[]>;
|
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
export declare const ALLOWED_AGENTS: readonly ["explore", "librarian", "oracle", "hephaestus", "metis", "momus", "multimodal-looker"];
|
|
2
|
-
export declare const CALL_OMO_AGENT_DESCRIPTION = "Spawn explore/librarian agent. run_in_background REQUIRED (true=async with task_id, false=sync).\n\
|
|
2
|
+
export declare const CALL_OMO_AGENT_DESCRIPTION = "Spawn explore/librarian agent or custom agents. run_in_background REQUIRED (true=async with task_id, false=sync).\n\nBuilt-in agents:\n{agents}\n\nCustom agents registered via user or project agent directories are also supported.\n\nPass `session_id=<id>` to continue previous agent with full context. Nested subagent depth is tracked automatically and blocked past the configured limit. Prompts MUST be in English. Use `background_output` for async results.";
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import type { FallbackEntry } from "../../shared/model-requirements";
|
|
2
|
+
import type { DelegatedModelConfig } from "./types";
|
|
3
|
+
export declare function resolveEffectiveFallbackEntry(input: {
|
|
4
|
+
categoryModel: DelegatedModelConfig | undefined;
|
|
5
|
+
configuredFallbackChain: FallbackEntry[] | undefined;
|
|
6
|
+
resolution: {
|
|
7
|
+
skipped: true;
|
|
8
|
+
} | {
|
|
9
|
+
fallbackEntry?: FallbackEntry;
|
|
10
|
+
matchedFallback?: boolean;
|
|
11
|
+
} | undefined;
|
|
12
|
+
}): FallbackEntry | undefined;
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import type { DelegatedModelConfig } from "./types";
|
|
2
|
+
import type { FallbackEntry } from "../../shared/model-requirements";
|
|
3
|
+
export declare function applyFallbackEntrySettings(input: {
|
|
4
|
+
categoryModel: DelegatedModelConfig;
|
|
5
|
+
effectiveEntry: FallbackEntry;
|
|
6
|
+
variantOverride?: string;
|
|
7
|
+
}): DelegatedModelConfig;
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
export type AgentMode = "subagent" | "primary" | "all" | undefined;
|
|
2
|
+
export type AgentInfo = {
|
|
3
|
+
name: string;
|
|
4
|
+
mode?: "subagent" | "primary" | "all";
|
|
5
|
+
model?: string | {
|
|
6
|
+
providerID: string;
|
|
7
|
+
modelID: string;
|
|
8
|
+
};
|
|
9
|
+
};
|
|
10
|
+
export declare function sanitizeSubagentType(subagentType: string): string;
|
|
11
|
+
export declare function mergeWithClaudeCodeAgents(serverAgents: AgentInfo[], directory: string | undefined): AgentInfo[];
|
|
12
|
+
export declare function isTaskCallableAgentMode(mode: AgentMode): boolean;
|
|
13
|
+
export declare function findPrimaryAgentMatch(agents: AgentInfo[], requestedAgentName: string): AgentInfo | undefined;
|
|
14
|
+
export declare function findCallableAgentMatch(agents: AgentInfo[], requestedAgentName: string): AgentInfo | undefined;
|
|
15
|
+
export declare function listCallableAgentNames(agents: AgentInfo[]): string;
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import type { FallbackEntry } from "../../shared/model-requirements";
|
|
2
|
+
import type { DelegatedModelConfig } from "./types";
|
|
3
|
+
export declare function retrySyncPromptWithFallbacks(input: {
|
|
4
|
+
sessionID: string;
|
|
5
|
+
initialError: string;
|
|
6
|
+
categoryModel: DelegatedModelConfig | undefined;
|
|
7
|
+
fallbackChain: FallbackEntry[] | undefined;
|
|
8
|
+
sendPrompt: (categoryModel: DelegatedModelConfig) => Promise<string | null>;
|
|
9
|
+
}): Promise<{
|
|
10
|
+
promptError: string | null;
|
|
11
|
+
categoryModel: DelegatedModelConfig | undefined;
|
|
12
|
+
}>;
|
|
@@ -1,3 +1,3 @@
|
|
|
1
1
|
export declare const TOOL_NAME: "skill";
|
|
2
2
|
export declare const TOOL_DESCRIPTION_NO_SKILLS = "Load a skill or execute a slash command to get detailed instructions for a specific task. No skills are currently available.";
|
|
3
|
-
export declare const TOOL_DESCRIPTION_PREFIX = "Load a skill or execute a slash command to get detailed instructions for a specific task.\n\nSkills and commands provide specialized knowledge and step-by-step guidance.\nUse this when a task matches an available skill's or command's description.\n\n**How to use:**\n- Call with a skill name: name='
|
|
3
|
+
export declare const TOOL_DESCRIPTION_PREFIX = "Load a skill or execute a slash command to get detailed instructions for a specific task.\n\nSkills and commands provide specialized knowledge and step-by-step guidance.\nUse this when a task matches an available skill's or command's description.\n\n**How to use:**\n- Call with a skill name: name='review-work'\n- Call with a command name (without leading slash): name='publish'\n- The tool will return detailed instructions with your context applied.\n";
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "oh-my-opencode",
|
|
3
|
-
"version": "3.17.
|
|
3
|
+
"version": "3.17.3",
|
|
4
4
|
"description": "The Best AI Agent Harness - Batteries-Included OpenCode Plugin with Multi-Model Orchestration, Parallel Background Agents, and Crafted LSP/AST Tools",
|
|
5
5
|
"main": "./dist/index.js",
|
|
6
6
|
"types": "dist/index.d.ts",
|
|
@@ -79,17 +79,17 @@
|
|
|
79
79
|
"typescript": "^5.7.3"
|
|
80
80
|
},
|
|
81
81
|
"optionalDependencies": {
|
|
82
|
-
"oh-my-opencode-darwin-arm64": "3.17.
|
|
83
|
-
"oh-my-opencode-darwin-x64": "3.17.
|
|
84
|
-
"oh-my-opencode-darwin-x64-baseline": "3.17.
|
|
85
|
-
"oh-my-opencode-linux-arm64": "3.17.
|
|
86
|
-
"oh-my-opencode-linux-arm64-musl": "3.17.
|
|
87
|
-
"oh-my-opencode-linux-x64": "3.17.
|
|
88
|
-
"oh-my-opencode-linux-x64-baseline": "3.17.
|
|
89
|
-
"oh-my-opencode-linux-x64-musl": "3.17.
|
|
90
|
-
"oh-my-opencode-linux-x64-musl-baseline": "3.17.
|
|
91
|
-
"oh-my-opencode-windows-x64": "3.17.
|
|
92
|
-
"oh-my-opencode-windows-x64-baseline": "3.17.
|
|
82
|
+
"oh-my-opencode-darwin-arm64": "3.17.3",
|
|
83
|
+
"oh-my-opencode-darwin-x64": "3.17.3",
|
|
84
|
+
"oh-my-opencode-darwin-x64-baseline": "3.17.3",
|
|
85
|
+
"oh-my-opencode-linux-arm64": "3.17.3",
|
|
86
|
+
"oh-my-opencode-linux-arm64-musl": "3.17.3",
|
|
87
|
+
"oh-my-opencode-linux-x64": "3.17.3",
|
|
88
|
+
"oh-my-opencode-linux-x64-baseline": "3.17.3",
|
|
89
|
+
"oh-my-opencode-linux-x64-musl": "3.17.3",
|
|
90
|
+
"oh-my-opencode-linux-x64-musl-baseline": "3.17.3",
|
|
91
|
+
"oh-my-opencode-windows-x64": "3.17.3",
|
|
92
|
+
"oh-my-opencode-windows-x64-baseline": "3.17.3"
|
|
93
93
|
},
|
|
94
94
|
"overrides": {},
|
|
95
95
|
"trustedDependencies": [
|