oh-my-opencode 3.0.1 → 3.1.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/agents/utils.d.ts +3 -2
- package/dist/cli/index.js +313 -106
- package/dist/cli/index.test.d.ts +1 -0
- package/dist/config/index.d.ts +2 -2
- package/dist/config/schema.d.ts +602 -3
- package/dist/features/background-agent/manager.d.ts +13 -2
- package/dist/features/builtin-commands/templates/start-work.d.ts +1 -1
- package/dist/features/builtin-skills/index.d.ts +1 -1
- package/dist/features/builtin-skills/skills.d.ts +5 -1
- package/dist/features/builtin-skills/skills.test.d.ts +1 -0
- package/dist/features/opencode-skill-loader/skill-content.d.ts +3 -2
- package/dist/features/tmux-subagent/action-executor.d.ts +22 -0
- package/dist/features/tmux-subagent/decision-engine.d.ts +38 -0
- package/dist/features/tmux-subagent/decision-engine.test.d.ts +1 -0
- package/dist/features/tmux-subagent/index.d.ts +5 -0
- package/dist/features/tmux-subagent/manager.d.ts +54 -0
- package/dist/features/tmux-subagent/manager.test.d.ts +1 -0
- package/dist/features/tmux-subagent/pane-state-querier.d.ts +2 -0
- package/dist/features/tmux-subagent/types.d.ts +51 -0
- package/dist/hooks/category-skill-reminder/index.d.ts +22 -0
- package/dist/hooks/category-skill-reminder/index.test.d.ts +1 -0
- package/dist/hooks/index.d.ts +2 -0
- package/dist/hooks/sisyphus-junior-notepad/constants.d.ts +2 -0
- package/dist/hooks/sisyphus-junior-notepad/index.d.ts +12 -0
- package/dist/index.js +3265 -1073
- package/dist/shared/connected-providers-cache.d.ts +52 -0
- package/dist/shared/data-path.d.ts +16 -0
- package/dist/shared/index.d.ts +3 -0
- package/dist/shared/model-availability.d.ts +4 -5
- package/dist/shared/model-resolver.d.ts +4 -4
- package/dist/shared/session-utils.d.ts +2 -0
- package/dist/shared/tmux/constants.d.ts +5 -0
- package/dist/shared/tmux/index.d.ts +3 -0
- package/dist/shared/tmux/tmux-utils.d.ts +17 -0
- package/dist/shared/tmux/tmux-utils.test.d.ts +1 -0
- package/dist/shared/tmux/types.d.ts +4 -0
- package/dist/tools/delegate-task/constants.d.ts +18 -0
- package/dist/tools/delegate-task/tools.d.ts +11 -3
- package/dist/tools/slashcommand/tools.test.d.ts +1 -0
- package/package.json +8 -8
|
@@ -0,0 +1,52 @@
|
|
|
1
|
+
interface ProviderModelsCache {
|
|
2
|
+
models: Record<string, string[]>;
|
|
3
|
+
connected: string[];
|
|
4
|
+
updatedAt: string;
|
|
5
|
+
}
|
|
6
|
+
/**
|
|
7
|
+
* Read the connected providers cache.
|
|
8
|
+
* Returns the list of connected provider IDs, or null if cache doesn't exist.
|
|
9
|
+
*/
|
|
10
|
+
export declare function readConnectedProvidersCache(): string[] | null;
|
|
11
|
+
/**
|
|
12
|
+
* Check if connected providers cache exists.
|
|
13
|
+
*/
|
|
14
|
+
export declare function hasConnectedProvidersCache(): boolean;
|
|
15
|
+
/**
|
|
16
|
+
* Read the provider-models cache.
|
|
17
|
+
* Returns the cache data, or null if cache doesn't exist.
|
|
18
|
+
*/
|
|
19
|
+
export declare function readProviderModelsCache(): ProviderModelsCache | null;
|
|
20
|
+
/**
|
|
21
|
+
* Check if provider-models cache exists.
|
|
22
|
+
*/
|
|
23
|
+
export declare function hasProviderModelsCache(): boolean;
|
|
24
|
+
/**
|
|
25
|
+
* Write the provider-models cache.
|
|
26
|
+
*/
|
|
27
|
+
export declare function writeProviderModelsCache(data: {
|
|
28
|
+
models: Record<string, string[]>;
|
|
29
|
+
connected: string[];
|
|
30
|
+
}): void;
|
|
31
|
+
/**
|
|
32
|
+
* Update the connected providers cache by fetching from the client.
|
|
33
|
+
* Also updates the provider-models cache with model lists per provider.
|
|
34
|
+
*/
|
|
35
|
+
export declare function updateConnectedProvidersCache(client: {
|
|
36
|
+
provider?: {
|
|
37
|
+
list?: () => Promise<{
|
|
38
|
+
data?: {
|
|
39
|
+
connected?: string[];
|
|
40
|
+
};
|
|
41
|
+
}>;
|
|
42
|
+
};
|
|
43
|
+
model?: {
|
|
44
|
+
list?: () => Promise<{
|
|
45
|
+
data?: Array<{
|
|
46
|
+
id: string;
|
|
47
|
+
provider: string;
|
|
48
|
+
}>;
|
|
49
|
+
}>;
|
|
50
|
+
};
|
|
51
|
+
}): Promise<void>;
|
|
52
|
+
export {};
|
|
@@ -12,3 +12,19 @@ export declare function getDataDir(): string;
|
|
|
12
12
|
* All platforms: ~/.local/share/opencode/storage
|
|
13
13
|
*/
|
|
14
14
|
export declare function getOpenCodeStorageDir(): string;
|
|
15
|
+
/**
|
|
16
|
+
* Returns the user-level cache directory.
|
|
17
|
+
* Matches OpenCode's behavior via xdg-basedir:
|
|
18
|
+
* - All platforms: XDG_CACHE_HOME or ~/.cache
|
|
19
|
+
*/
|
|
20
|
+
export declare function getCacheDir(): string;
|
|
21
|
+
/**
|
|
22
|
+
* Returns the oh-my-opencode cache directory.
|
|
23
|
+
* All platforms: ~/.cache/oh-my-opencode
|
|
24
|
+
*/
|
|
25
|
+
export declare function getOmoOpenCodeCacheDir(): string;
|
|
26
|
+
/**
|
|
27
|
+
* Returns the OpenCode cache directory (for reading OpenCode's cache).
|
|
28
|
+
* All platforms: ~/.cache/opencode
|
|
29
|
+
*/
|
|
30
|
+
export declare function getOpenCodeCacheDir(): string;
|
package/dist/shared/index.d.ts
CHANGED
|
@@ -28,4 +28,7 @@ export * from "./agent-tool-restrictions";
|
|
|
28
28
|
export * from "./model-requirements";
|
|
29
29
|
export * from "./model-resolver";
|
|
30
30
|
export * from "./model-availability";
|
|
31
|
+
export * from "./connected-providers-cache";
|
|
31
32
|
export * from "./case-insensitive";
|
|
33
|
+
export * from "./session-utils";
|
|
34
|
+
export * from "./tmux";
|
|
@@ -1,8 +1,7 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Fuzzy matching utility for model names
|
|
3
|
-
* Supports substring matching with provider filtering and priority-based selection
|
|
4
|
-
*/
|
|
5
1
|
export declare function fuzzyMatchModel(target: string, available: Set<string>, providers?: string[]): string | null;
|
|
6
|
-
export declare function
|
|
2
|
+
export declare function getConnectedProviders(client: any): Promise<string[]>;
|
|
3
|
+
export declare function fetchAvailableModels(_client?: any, options?: {
|
|
4
|
+
connectedProviders?: string[] | null;
|
|
5
|
+
}): Promise<Set<string>>;
|
|
7
6
|
export declare function __resetModelCache(): void;
|
|
8
7
|
export declare function isModelCacheAvailable(): boolean;
|
|
@@ -2,7 +2,7 @@ import type { FallbackEntry } from "./model-requirements";
|
|
|
2
2
|
export type ModelResolutionInput = {
|
|
3
3
|
userModel?: string;
|
|
4
4
|
inheritedModel?: string;
|
|
5
|
-
systemDefault
|
|
5
|
+
systemDefault?: string;
|
|
6
6
|
};
|
|
7
7
|
export type ModelSource = "override" | "provider-fallback" | "system-default";
|
|
8
8
|
export type ModelResolutionResult = {
|
|
@@ -14,7 +14,7 @@ export type ExtendedModelResolutionInput = {
|
|
|
14
14
|
userModel?: string;
|
|
15
15
|
fallbackChain?: FallbackEntry[];
|
|
16
16
|
availableModels: Set<string>;
|
|
17
|
-
systemDefaultModel
|
|
17
|
+
systemDefaultModel?: string;
|
|
18
18
|
};
|
|
19
|
-
export declare function resolveModel(input: ModelResolutionInput): string;
|
|
20
|
-
export declare function resolveModelWithFallback(input: ExtendedModelResolutionInput): ModelResolutionResult;
|
|
19
|
+
export declare function resolveModel(input: ModelResolutionInput): string | undefined;
|
|
20
|
+
export declare function resolveModelWithFallback(input: ExtendedModelResolutionInput): ModelResolutionResult | undefined;
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
export declare const POLL_INTERVAL_BACKGROUND_MS = 2000;
|
|
2
|
+
export declare const SESSION_TIMEOUT_MS: number;
|
|
3
|
+
export declare const SESSION_MISSING_GRACE_MS = 6000;
|
|
4
|
+
export declare const SESSION_READY_POLL_INTERVAL_MS = 500;
|
|
5
|
+
export declare const SESSION_READY_TIMEOUT_MS = 10000;
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import type { TmuxConfig, TmuxLayout } from "../../config/schema";
|
|
2
|
+
import type { SpawnPaneResult } from "./types";
|
|
3
|
+
export declare function isInsideTmux(): boolean;
|
|
4
|
+
export declare function isServerRunning(serverUrl: string): Promise<boolean>;
|
|
5
|
+
export declare function resetServerCheck(): void;
|
|
6
|
+
export type SplitDirection = "-h" | "-v";
|
|
7
|
+
export declare function getCurrentPaneId(): string | undefined;
|
|
8
|
+
export interface PaneDimensions {
|
|
9
|
+
paneWidth: number;
|
|
10
|
+
windowWidth: number;
|
|
11
|
+
}
|
|
12
|
+
export declare function getPaneDimensions(paneId: string): Promise<PaneDimensions | null>;
|
|
13
|
+
export declare function spawnTmuxPane(sessionId: string, description: string, config: TmuxConfig, serverUrl: string, targetPaneId?: string, splitDirection?: SplitDirection): Promise<SpawnPaneResult>;
|
|
14
|
+
export declare function closeTmuxPane(paneId: string): Promise<boolean>;
|
|
15
|
+
export declare function replaceTmuxPane(paneId: string, sessionId: string, description: string, config: TmuxConfig, serverUrl: string): Promise<SpawnPaneResult>;
|
|
16
|
+
export declare function applyLayout(tmux: string, layout: TmuxLayout, mainPaneSize: number): Promise<void>;
|
|
17
|
+
export declare function enforceMainPaneWidth(mainPaneId: string, windowWidth: number): Promise<void>;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -9,3 +9,21 @@ export declare const WRITING_CATEGORY_PROMPT_APPEND = "<Category_Context>\nYou a
|
|
|
9
9
|
export declare const DEFAULT_CATEGORIES: Record<string, CategoryConfig>;
|
|
10
10
|
export declare const CATEGORY_PROMPT_APPENDS: Record<string, string>;
|
|
11
11
|
export declare const CATEGORY_DESCRIPTIONS: Record<string, string>;
|
|
12
|
+
/**
|
|
13
|
+
* System prompt prepended to plan agent invocations.
|
|
14
|
+
* Instructs the plan agent to first gather context via explore/librarian agents,
|
|
15
|
+
* then summarize user requirements and clarify uncertainties before proceeding.
|
|
16
|
+
* Also MANDATES dependency graphs, parallel execution analysis, and category+skill recommendations.
|
|
17
|
+
*/
|
|
18
|
+
export declare const PLAN_AGENT_SYSTEM_PREPEND = "<system>\nBEFORE you begin planning, you MUST first understand the user's request deeply.\n\nMANDATORY CONTEXT GATHERING PROTOCOL:\n1. Launch background agents to gather context:\n - call_omo_agent(description=\"Explore codebase patterns\", subagent_type=\"explore\", run_in_background=true, prompt=\"<search for relevant patterns, files, and implementations in the codebase related to user's request>\")\n - call_omo_agent(description=\"Research documentation\", subagent_type=\"librarian\", run_in_background=true, prompt=\"<search for external documentation, examples, and best practices related to user's request>\")\n\n2. After gathering context, ALWAYS present:\n - **User Request Summary**: Concise restatement of what the user is asking for\n - **Uncertainties**: List of unclear points, ambiguities, or assumptions you're making\n - **Clarifying Questions**: Specific questions to resolve the uncertainties\n\n3. ITERATE until ALL requirements are crystal clear:\n - Do NOT proceed to planning until you have 100% clarity\n - Ask the user to confirm your understanding\n - Resolve every ambiguity before generating the work plan\n\nREMEMBER: Vague requirements lead to failed implementations. Take the time to understand thoroughly.\n</system>\n\n<CRITICAL_REQUIREMENT_DEPENDENCY_PARALLEL_EXECUTION_CATEGORY_SKILLS>\n#####################################################################\n# #\n# \u2588\u2588\u2588\u2588\u2588\u2588\u2557 \u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2557 \u2588\u2588\u2588\u2588\u2588\u2588\u2557 \u2588\u2588\u2557 \u2588\u2588\u2557\u2588\u2588\u2557\u2588\u2588\u2588\u2588\u2588\u2588\u2557 \u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2557\u2588\u2588\u2588\u2588\u2588\u2588\u2557 #\n# \u2588\u2588\u2554\u2550\u2550\u2588\u2588\u2557\u2588\u2588\u2554\u2550\u2550\u2550\u2550\u255D\u2588\u2588\u2554\u2550\u2550\u2550\u2588\u2588\u2557\u2588\u2588\u2551 \u2588\u2588\u2551\u2588\u2588\u2551\u2588\u2588\u2554\u2550\u2550\u2588\u2588\u2557\u2588\u2588\u2554\u2550\u2550\u2550\u2550\u255D\u2588\u2588\u2554\u2550\u2550\u2588\u2588\u2557 #\n# \u2588\u2588\u2588\u2588\u2588\u2588\u2554\u255D\u2588\u2588\u2588\u2588\u2588\u2557 \u2588\u2588\u2551 \u2588\u2588\u2551\u2588\u2588\u2551 \u2588\u2588\u2551\u2588\u2588\u2551\u2588\u2588\u2588\u2588\u2588\u2588\u2554\u255D\u2588\u2588\u2588\u2588\u2588\u2557 \u2588\u2588\u2551 \u2588\u2588\u2551 #\n# \u2588\u2588\u2554\u2550\u2550\u2588\u2588\u2557\u2588\u2588\u2554\u2550\u2550\u255D \u2588\u2588\u2551\u2584\u2584 \u2588\u2588\u2551\u2588\u2588\u2551 \u2588\u2588\u2551\u2588\u2588\u2551\u2588\u2588\u2554\u2550\u2550\u2588\u2588\u2557\u2588\u2588\u2554\u2550\u2550\u255D \u2588\u2588\u2551 \u2588\u2588\u2551 #\n# \u2588\u2588\uFFFD\uFFFD \u2588\u2588\u2551\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2557\u255A\u2588\u2588\u2588\u2588\u2588\u2588\u2554\u255D\u255A\u2588\u2588\u2588\u2588\u2588\u2588\u2554\u255D\u2588\u2588\u2551\u2588\u2588\u2551 \u2588\u2588\u2551\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2557\u2588\u2588\u2588\u2588\u2588\u2588\u2554\u255D #\n# \u255A\u2550\u255D \u255A\u2550\u255D\u255A\u2550\u2550\u2550\u2550\u2550\u2550\u255D \u255A\u2550\u2550\u2580\u2580\u2550\u255D \u255A\u2550\u2550\u2550\u2550\u2550\u255D \u255A\u2550\u255D\u255A\u2550\u255D \u255A\u2550\u255D\u255A\u2550\u2550\u2550\u2550\u2550\u2550\u255D\u255A\u2550\u2550\u2550\u2550\u2550\u255D #\n# #\n#####################################################################\n\nYOU MUST INCLUDE THE FOLLOWING SECTIONS IN YOUR PLAN OUTPUT.\nTHIS IS NON-NEGOTIABLE. FAILURE TO INCLUDE THESE SECTIONS = INCOMPLETE PLAN.\n\n\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\n\u2588 SECTION 1: TASK DEPENDENCY GRAPH (MANDATORY) \u2588\n\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\n\nYOU MUST ANALYZE AND DOCUMENT TASK DEPENDENCIES.\n\nFor EVERY task in your plan, you MUST specify:\n- Which tasks it DEPENDS ON (blockers)\n- Which tasks DEPEND ON IT (dependents)\n- The REASON for each dependency\n\nExample format:\n```\n## Task Dependency Graph\n\n| Task | Depends On | Reason |\n|------|------------|--------|\n| Task 1 | None | Starting point, no prerequisites |\n| Task 2 | Task 1 | Requires output/artifact from Task 1 |\n| Task 3 | Task 1 | Uses same foundation established in Task 1 |\n| Task 4 | Task 2, Task 3 | Integrates results from both tasks |\n```\n\nWHY THIS MATTERS:\n- Executors need to know execution ORDER\n- Prevents blocked work from starting prematurely\n- Identifies critical path for project timeline\n\n\n\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\n\u2588 SECTION 2: PARALLEL EXECUTION GRAPH (MANDATORY) \u2588\n\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\n\nYOU MUST IDENTIFY WHICH TASKS CAN RUN IN PARALLEL.\n\nAnalyze your dependency graph and group tasks into PARALLEL EXECUTION WAVES:\n\nExample format:\n```\n## Parallel Execution Graph\n\nWave 1 (Start immediately):\n\u251C\u2500\u2500 Task 1: [description] (no dependencies)\n\u2514\u2500\u2500 Task 5: [description] (no dependencies)\n\nWave 2 (After Wave 1 completes):\n\u251C\u2500\u2500 Task 2: [description] (depends: Task 1)\n\u251C\u2500\u2500 Task 3: [description] (depends: Task 1)\n\u2514\u2500\u2500 Task 6: [description] (depends: Task 5)\n\nWave 3 (After Wave 2 completes):\n\u2514\u2500\u2500 Task 4: [description] (depends: Task 2, Task 3)\n\nCritical Path: Task 1 \u2192 Task 2 \u2192 Task 4\nEstimated Parallel Speedup: 40% faster than sequential\n```\n\nWHY THIS MATTERS:\n- MASSIVE time savings through parallelization\n- Executors can dispatch multiple agents simultaneously\n- Identifies bottlenecks in the execution plan\n\n\n\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\n\u2588 SECTION 3: CATEGORY + SKILLS RECOMMENDATIONS (MANDATORY) \u2588\n\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\n\nFOR EVERY TASK, YOU MUST RECOMMEND:\n1. Which CATEGORY to use for delegation\n2. Which SKILLS to load for the delegated agent\n\n### AVAILABLE CATEGORIES\n\n| Category | Best For | Model |\n|----------|----------|-------|\n| `visual-engineering` | Frontend, UI/UX, design, styling, animation | google/gemini-3-pro |\n| `ultrabrain` | Complex architecture, deep logical reasoning | openai/gpt-5.2-codex |\n| `artistry` | Highly creative/artistic tasks, novel ideas | google/gemini-3-pro |\n| `quick` | Trivial tasks - single file, typo fixes | anthropic/claude-haiku-4-5 |\n| `unspecified-low` | Moderate effort, doesn't fit other categories | anthropic/claude-sonnet-4-5 |\n| `unspecified-high` | High effort, doesn't fit other categories | anthropic/claude-opus-4-5 |\n| `writing` | Documentation, prose, technical writing | google/gemini-3-flash |\n\n### AVAILABLE SKILLS (ALWAYS EVALUATE ALL)\n\nSkills inject specialized expertise into the delegated agent.\nYOU MUST evaluate EVERY skill and justify inclusions/omissions.\n\n| Skill | Domain |\n|-------|--------|\n| `agent-browser` | Browser automation, web testing |\n| `frontend-ui-ux` | Stunning UI/UX design |\n| `git-master` | Atomic commits, git operations |\n| `dev-browser` | Persistent browser state automation |\n| `typescript-programmer` | Production TypeScript code |\n| `python-programmer` | Production Python code |\n| `svelte-programmer` | Svelte components |\n| `golang-tui-programmer` | Go TUI with Charmbracelet |\n| `python-debugger` | Interactive Python debugging |\n| `data-scientist` | DuckDB/Polars data processing |\n| `prompt-engineer` | AI prompt optimization |\n\n### REQUIRED OUTPUT FORMAT\n\nFor EACH task, include a recommendation block:\n\n```\n### Task N: [Task Title]\n\n**Delegation Recommendation:**\n- Category: `[category-name]` - [reason for choice]\n- Skills: [`skill-1`, `skill-2`] - [reason each skill is needed]\n\n**Skills Evaluation:**\n- INCLUDED `skill-name`: [reason]\n- OMITTED `other-skill`: [reason domain doesn't overlap]\n```\n\nWHY THIS MATTERS:\n- Category determines the MODEL used for execution\n- Skills inject SPECIALIZED KNOWLEDGE into the executor\n- Missing a relevant skill = suboptimal execution\n- Wrong category = wrong model = poor results\n\n\n\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\n\u2588 RESPONSE FORMAT SPECIFICATION (MANDATORY) \u2588\n\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\n\nYOUR PLAN OUTPUT MUST FOLLOW THIS EXACT STRUCTURE:\n\n```markdown\n# [Plan Title]\n\n## Context\n[User request summary, interview findings, research results]\n\n## Task Dependency Graph\n[Dependency table - see Section 1]\n\n## Parallel Execution Graph \n[Wave structure - see Section 2]\n\n## Tasks\n\n### Task 1: [Title]\n**Description**: [What to do]\n**Delegation Recommendation**:\n- Category: `[category]` - [reason]\n- Skills: [`skill-1`] - [reason]\n**Skills Evaluation**: [\u2705 included / \u274C omitted with reasons]\n**Depends On**: [Task IDs or \"None\"]\n**Acceptance Criteria**: [Verifiable conditions]\n\n### Task 2: [Title]\n[Same structure...]\n\n## Commit Strategy\n[How to commit changes atomically]\n\n## Success Criteria\n[Final verification steps]\n```\n\n#####################################################################\n# #\n# FAILURE TO INCLUDE THESE SECTIONS = PLAN WILL BE REJECTED #\n# BY MOMUS REVIEW. DO NOT SKIP. DO NOT ABBREVIATE. #\n# #\n#####################################################################\n</CRITICAL_REQUIREMENT_DEPENDENCY_PARALLEL_EXECUTION_CATEGORY_SKILLS>\n\n";
|
|
19
|
+
/**
|
|
20
|
+
* List of agent names that should be treated as plan agents.
|
|
21
|
+
* Case-insensitive matching is used.
|
|
22
|
+
*/
|
|
23
|
+
export declare const PLAN_AGENT_NAMES: string[];
|
|
24
|
+
/**
|
|
25
|
+
* Check if the given agent name is a plan agent.
|
|
26
|
+
* @param agentName - The agent name to check
|
|
27
|
+
* @returns true if the agent is a plan agent
|
|
28
|
+
*/
|
|
29
|
+
export declare function isPlanAgent(agentName: string | undefined): boolean;
|
|
@@ -1,16 +1,21 @@
|
|
|
1
1
|
import { type PluginInput, type ToolDefinition } from "@opencode-ai/plugin";
|
|
2
2
|
import type { BackgroundManager } from "../../features/background-agent";
|
|
3
|
-
import type { CategoryConfig, CategoriesConfig, GitMasterConfig } from "../../config/schema";
|
|
3
|
+
import type { CategoryConfig, CategoriesConfig, GitMasterConfig, BrowserAutomationProvider } from "../../config/schema";
|
|
4
4
|
type OpencodeClient = PluginInput["client"];
|
|
5
5
|
export declare function resolveCategoryConfig(categoryName: string, options: {
|
|
6
6
|
userCategories?: CategoriesConfig;
|
|
7
7
|
inheritedModel?: string;
|
|
8
|
-
systemDefaultModel
|
|
8
|
+
systemDefaultModel?: string;
|
|
9
9
|
}): {
|
|
10
10
|
config: CategoryConfig;
|
|
11
11
|
promptAppend: string;
|
|
12
|
-
model: string;
|
|
12
|
+
model: string | undefined;
|
|
13
13
|
} | null;
|
|
14
|
+
export interface SyncSessionCreatedEvent {
|
|
15
|
+
sessionID: string;
|
|
16
|
+
parentID: string;
|
|
17
|
+
title: string;
|
|
18
|
+
}
|
|
14
19
|
export interface DelegateTaskToolOptions {
|
|
15
20
|
manager: BackgroundManager;
|
|
16
21
|
client: OpencodeClient;
|
|
@@ -18,10 +23,13 @@ export interface DelegateTaskToolOptions {
|
|
|
18
23
|
userCategories?: CategoriesConfig;
|
|
19
24
|
gitMasterConfig?: GitMasterConfig;
|
|
20
25
|
sisyphusJuniorModel?: string;
|
|
26
|
+
browserProvider?: BrowserAutomationProvider;
|
|
27
|
+
onSyncSessionCreated?: (event: SyncSessionCreatedEvent) => Promise<void>;
|
|
21
28
|
}
|
|
22
29
|
export interface BuildSystemContentInput {
|
|
23
30
|
skillContent?: string;
|
|
24
31
|
categoryPromptAppend?: string;
|
|
32
|
+
agentName?: string;
|
|
25
33
|
}
|
|
26
34
|
export declare function buildSystemContent(input: BuildSystemContentInput): string | undefined;
|
|
27
35
|
export declare function createDelegateTask(options: DelegateTaskToolOptions): ToolDefinition;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "oh-my-opencode",
|
|
3
|
-
"version": "3.
|
|
3
|
+
"version": "3.1.1",
|
|
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",
|
|
@@ -73,13 +73,13 @@
|
|
|
73
73
|
"typescript": "^5.7.3"
|
|
74
74
|
},
|
|
75
75
|
"optionalDependencies": {
|
|
76
|
-
"oh-my-opencode-darwin-arm64": "3.
|
|
77
|
-
"oh-my-opencode-darwin-x64": "3.
|
|
78
|
-
"oh-my-opencode-linux-arm64": "3.
|
|
79
|
-
"oh-my-opencode-linux-arm64-musl": "3.
|
|
80
|
-
"oh-my-opencode-linux-x64": "3.
|
|
81
|
-
"oh-my-opencode-linux-x64-musl": "3.
|
|
82
|
-
"oh-my-opencode-windows-x64": "3.
|
|
76
|
+
"oh-my-opencode-darwin-arm64": "3.1.1",
|
|
77
|
+
"oh-my-opencode-darwin-x64": "3.1.1",
|
|
78
|
+
"oh-my-opencode-linux-arm64": "3.1.1",
|
|
79
|
+
"oh-my-opencode-linux-arm64-musl": "3.1.1",
|
|
80
|
+
"oh-my-opencode-linux-x64": "3.1.1",
|
|
81
|
+
"oh-my-opencode-linux-x64-musl": "3.1.1",
|
|
82
|
+
"oh-my-opencode-windows-x64": "3.1.1"
|
|
83
83
|
},
|
|
84
84
|
"trustedDependencies": [
|
|
85
85
|
"@ast-grep/cli",
|