@skj1724/oh-my-opencode 3.17.13 → 3.18.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/atlas/default-prompt-sections.d.ts +6 -6
- package/dist/agents/atlas/gemini-prompt-sections.d.ts +6 -6
- package/dist/agents/atlas/gpt-prompt-sections.d.ts +6 -6
- package/dist/agents/atlas/prompt-section-builder.d.ts +3 -2
- package/dist/agents/env-context.d.ts +1 -7
- package/dist/agents/gpt-apply-patch-guard.d.ts +1 -1
- package/dist/agents/hephaestus/gpt-5-3-codex.d.ts +9 -9
- package/dist/agents/metis.d.ts +9 -9
- package/dist/agents/momus.d.ts +11 -8
- package/dist/agents/prometheus/behavioral-summary.d.ts +3 -3
- package/dist/agents/prometheus/gemini.d.ts +7 -7
- package/dist/agents/prometheus/gpt.d.ts +6 -6
- package/dist/agents/prometheus/high-accuracy-mode.d.ts +3 -3
- package/dist/agents/prometheus/identity-constraints.d.ts +4 -3
- package/dist/agents/prometheus/interview-mode.d.ts +3 -3
- package/dist/agents/prometheus/plan-generation.d.ts +4 -4
- package/dist/agents/prometheus/plan-template.d.ts +4 -4
- package/dist/agents/sisyphus/default.d.ts +2 -2
- package/dist/agents/sisyphus/gemini.d.ts +10 -10
- package/dist/agents/sisyphus/gpt-5-4.d.ts +18 -18
- package/dist/agents/sisyphus-junior/gemini.d.ts +6 -6
- package/dist/agents/sisyphus-junior/gpt-5-3-codex.d.ts +4 -4
- package/dist/agents/sisyphus-junior/gpt-5-4.d.ts +7 -7
- package/dist/agents/sisyphus-junior/gpt.d.ts +5 -5
- package/dist/cli/index.js +262 -64
- package/dist/config/schema/i18n.d.ts +21 -0
- package/dist/config/schema/oh-my-opencode-config.d.ts +3 -0
- package/dist/features/builtin-commands/templates/handoff.d.ts +1 -1
- package/dist/features/builtin-commands/templates/init-deep.d.ts +1 -1
- package/dist/features/builtin-commands/templates/ralph-loop.d.ts +3 -3
- package/dist/features/builtin-commands/templates/refactor.d.ts +1 -1
- package/dist/features/builtin-commands/templates/remove-ai-slops.d.ts +1 -1
- package/dist/features/builtin-commands/templates/start-work.d.ts +1 -1
- package/dist/features/builtin-commands/templates/stop-continuation.d.ts +1 -1
- package/dist/features/builtin-skills/skills/git-master-sections/commit-workflow.d.ts +1 -1
- package/dist/features/builtin-skills/skills/git-master-sections/history-search-workflow.d.ts +1 -1
- package/dist/features/builtin-skills/skills/git-master-sections/overview.d.ts +1 -1
- package/dist/features/builtin-skills/skills/git-master-sections/quick-reference.d.ts +1 -1
- package/dist/features/builtin-skills/skills/git-master-sections/rebase-workflow.d.ts +1 -1
- package/dist/features/builtin-skills/skills/git-master-skill-metadata.d.ts +1 -1
- package/dist/features/builtin-skills/skills/playwright-cli.d.ts +5 -5
- package/dist/features/claude-code-command-loader/loader.d.ts +2 -0
- package/dist/features/tmux-subagent/event-handlers.d.ts +0 -4
- package/dist/features/tmux-subagent/index.d.ts +0 -3
- package/dist/features/tmux-subagent/manager.d.ts +4 -0
- package/dist/features/tmux-subagent/polling-manager.d.ts +2 -1
- package/dist/hooks/agent-usage-reminder/constants.d.ts +1 -1
- package/dist/hooks/directory-agents-injector/finder.d.ts +1 -1
- package/dist/hooks/directory-readme-injector/finder.d.ts +1 -1
- package/dist/hooks/edit-error-recovery/hook.d.ts +1 -1
- package/dist/hooks/json-error-recovery/hook.d.ts +1 -1
- package/dist/hooks/keyword-detector/analyze/default.d.ts +1 -1
- package/dist/hooks/keyword-detector/search/default.d.ts +1 -1
- package/dist/hooks/rules-injector/cache.d.ts +5 -0
- package/dist/hooks/rules-injector/injector.d.ts +2 -0
- package/dist/hooks/rules-injector/project-root-finder.d.ts +1 -0
- package/dist/hooks/rules-injector/rule-file-finder.d.ts +2 -19
- package/dist/hooks/todo-continuation-enforcer/session-state.d.ts +1 -0
- package/dist/hooks/write-existing-file-guard/tool-execute-before-handler.d.ts +1 -1
- package/dist/index.js +9582 -9018
- package/dist/oh-my-opencode.schema.json +10 -0
- package/dist/shared/index.d.ts +1 -0
- package/dist/shared/jsonc-parser.d.ts +8 -5
- package/dist/shared/load-opencode-plugins.d.ts +1 -0
- package/dist/shared/project-discovery-dirs.d.ts +2 -0
- package/dist/shared/tmux/tmux-utils/session-spawn.d.ts +1 -0
- package/dist/shared/tmux/tmux-utils.d.ts +3 -1
- package/dist/tools/background-task/constants.d.ts +3 -3
- package/dist/tools/call-omo-agent/constants.d.ts +1 -1
- package/dist/tools/delegate-task/background-continuation.d.ts +1 -1
- package/dist/tools/delegate-task/constants.d.ts +2 -2
- package/dist/tools/delegate-task/resolve-metadata-model.d.ts +3 -2
- package/dist/tools/delegate-task/sync-continuation.d.ts +1 -1
- package/dist/tools/delegate-task/types.d.ts +1 -4
- package/dist/tools/hashline-edit/tool-description.d.ts +1 -1
- package/dist/tools/interactive-bash/constants.d.ts +1 -1
- package/dist/tools/look-at/constants.d.ts +1 -1
- package/dist/tools/session-manager/constants.d.ts +5 -5
- package/dist/tools/skill/constants.d.ts +2 -2
- package/dist/tools/skill/description-formatter.d.ts +1 -1
- package/dist/tools/skill-mcp/constants.d.ts +1 -1
- package/package.json +2 -2
- package/dist/features/tmux-subagent/cleanup.d.ts +0 -9
- package/dist/features/tmux-subagent/session-created-handler.d.ts +0 -22
- package/dist/features/tmux-subagent/session-deleted-handler.d.ts +0 -15
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
export declare const AGENT_USAGE_REMINDER_STORAGE: string;
|
|
2
2
|
export declare const TARGET_TOOLS: Set<string>;
|
|
3
3
|
export declare const AGENT_TOOLS: Set<string>;
|
|
4
|
-
export declare const REMINDER_MESSAGE = "\n[Agent
|
|
4
|
+
export declare const REMINDER_MESSAGE = "\n[Agent Usage Reminder]\n\nYou called a search/fetch tool directly without leveraging specialized agents.\n\nRECOMMENDED: Use task with explore/librarian agents for better results:\n\n```\n// Parallel exploration - fire multiple agents simultaneously\ntask(subagent_type=\"explore\", load_skills=[], prompt=\"Find all files matching pattern X\")\ntask(subagent_type=\"explore\", load_skills=[], prompt=\"Search for implementation of Y\")\ntask(subagent_type=\"librarian\", load_skills=[], prompt=\"Lookup documentation for Z\")\n\n// Then continue your work while they run in background\n// System will notify you when each completes\n```\n\nWHY:\n- Agents can perform deeper, more thorough searches\n- Background tasks run in parallel, saving time\n- Specialized agents have domain expertise\n- Reduces context window usage in main session\n\nALWAYS prefer: Multiple parallel task calls > Direct tool calls\n";
|
|
@@ -7,7 +7,7 @@ export declare const EDIT_ERROR_PATTERNS: readonly ["oldString and newString mus
|
|
|
7
7
|
* System reminder injected when Edit tool fails due to AI mistake
|
|
8
8
|
* Short, direct, and commanding - forces immediate corrective action
|
|
9
9
|
*/
|
|
10
|
-
export declare const EDIT_ERROR_REMINDER = "\n[EDIT
|
|
10
|
+
export declare const EDIT_ERROR_REMINDER = "\n[EDIT ERROR - IMMEDIATE ACTION REQUIRED]\n\nYou made an Edit mistake. STOP and do this NOW:\n\n1. READ the file immediately to see its ACTUAL current state\n2. VERIFY what the content really looks like (your assumption was wrong)\n3. APOLOGIZE briefly to the user for the error\n4. CONTINUE with corrected action based on the real file content\n\nDO NOT attempt another edit until you've read and verified the file state.\n";
|
|
11
11
|
/**
|
|
12
12
|
* Detects Edit tool errors caused by AI mistakes and injects a recovery reminder
|
|
13
13
|
*
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import type { PluginInput } from "@opencode-ai/plugin";
|
|
2
2
|
export declare const JSON_ERROR_TOOL_EXCLUDE_LIST: readonly ["bash", "read", "glob", "grep", "webfetch", "look_at", "grep_app_searchgithub", "websearch_web_search_exa"];
|
|
3
3
|
export declare const JSON_ERROR_PATTERNS: readonly [RegExp, RegExp, RegExp, RegExp, RegExp, RegExp, RegExp, RegExp];
|
|
4
|
-
export declare const JSON_ERROR_REMINDER = "\n[JSON
|
|
4
|
+
export declare const JSON_ERROR_REMINDER = "\n[JSON PARSE ERROR - IMMEDIATE ACTION REQUIRED]\n\nYou sent invalid JSON arguments. The system could not parse your tool call.\nSTOP and do this NOW:\n\n1. LOOK at the error message above to see what was expected vs what you sent.\n2. CORRECT your JSON syntax (missing braces, unescaped quotes, trailing commas, etc).\n3. RETRY the tool call with valid JSON.\n\nDO NOT repeat the exact same invalid call.\n";
|
|
5
5
|
export declare function createJsonErrorRecoveryHook(_ctx: PluginInput): {
|
|
6
6
|
"tool.execute.after": (input: {
|
|
7
7
|
tool: string;
|
|
@@ -9,4 +9,4 @@
|
|
|
9
9
|
* - Vietnamese: phân tích, điều tra, nghiên cứu, kiểm tra, xem xét, chẩn đoán, giải thích, tìm hiểu, gỡ lỗi, tại sao
|
|
10
10
|
*/
|
|
11
11
|
export declare const ANALYZE_PATTERN: RegExp;
|
|
12
|
-
export declare const ANALYZE_MESSAGE = "[analyze-mode]\
|
|
12
|
+
export declare const ANALYZE_MESSAGE = "[analyze-mode]\nANALYSIS MODE. Gather context before diving deep:\n\nCONTEXT GATHERING (parallel):\n- 1-2 explore agents (codebase patterns, implementations)\n- 1-2 librarian agents (if external library involved)\n- Direct tools: Grep, AST-grep, LSP for targeted searches\n\nIF COMPLEX - DO NOT STRUGGLE ALONE. Consult specialists:\n- **Oracle**: Conventional problems (architecture, debugging, complex logic)\n- **Artistry**: Non-conventional problems (different approach needed)\n\nSYNTHESIZE findings before proceeding.";
|
|
@@ -9,4 +9,4 @@
|
|
|
9
9
|
* - Vietnamese: tìm kiếm, tra cứu, định vị, quét, phát hiện, truy tìm, tìm ra, ở đâu, liệt kê
|
|
10
10
|
*/
|
|
11
11
|
export declare const SEARCH_PATTERN: RegExp;
|
|
12
|
-
export declare const SEARCH_MESSAGE = "[search-mode]\
|
|
12
|
+
export declare const SEARCH_MESSAGE = "[search-mode]\nMAXIMIZE SEARCH EFFORT. Launch multiple background agents IN PARALLEL:\n- explore agents (codebase patterns, file structures, ast-grep)\n- librarian agents (remote repos, official docs, GitHub examples)\nPlus direct tools: Grep, ripgrep (rg), ast-grep (sg)\nNEVER stop at first result - be exhaustive.";
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import type { RuleScanCache } from "./rule-scan-cache";
|
|
1
2
|
export type SessionInjectedRulesCache = {
|
|
2
3
|
contentHashes: Set<string>;
|
|
3
4
|
realPaths: Set<string>;
|
|
@@ -6,3 +7,7 @@ export declare function createSessionCacheStore(): {
|
|
|
6
7
|
getSessionCache: (sessionID: string) => SessionInjectedRulesCache;
|
|
7
8
|
clearSessionCache: (sessionID: string) => void;
|
|
8
9
|
};
|
|
10
|
+
export declare function createSessionRuleScanCacheStore(): {
|
|
11
|
+
getSessionRuleScanCache: (sessionID: string) => RuleScanCache;
|
|
12
|
+
clearSessionRuleScanCache: (sessionID: string) => void;
|
|
13
|
+
};
|
|
@@ -4,6 +4,7 @@ import type { FindRuleFilesOptions } from "./rule-file-finder";
|
|
|
4
4
|
import { createContentHash, isDuplicateByContentHash, isDuplicateByRealPath, shouldApplyRule } from "./matcher";
|
|
5
5
|
import { saveInjectedRules } from "./storage";
|
|
6
6
|
import type { SessionInjectedRulesCache } from "./cache";
|
|
7
|
+
import type { RuleScanCache } from "./rule-scan-cache";
|
|
7
8
|
type ToolExecuteOutput = {
|
|
8
9
|
title: string;
|
|
9
10
|
output: string;
|
|
@@ -19,6 +20,7 @@ export declare function createRuleInjectionProcessor(deps: {
|
|
|
19
20
|
workspaceDirectory: string;
|
|
20
21
|
truncator: DynamicTruncator;
|
|
21
22
|
getSessionCache: (sessionID: string) => SessionInjectedRulesCache;
|
|
23
|
+
getSessionRuleScanCache?: (sessionID: string) => RuleScanCache;
|
|
22
24
|
ruleFinderOptions?: FindRuleFilesOptions;
|
|
23
25
|
readFileSync?: typeof readFileSync;
|
|
24
26
|
statSync?: typeof statSync;
|
|
@@ -1,23 +1,6 @@
|
|
|
1
|
+
import type { RuleScanCache } from "./rule-scan-cache";
|
|
1
2
|
import type { RuleFileCandidate } from "./types";
|
|
2
3
|
export interface FindRuleFilesOptions {
|
|
3
|
-
/**
|
|
4
|
-
* When true, skip loading rules from ~/.claude/rules/.
|
|
5
|
-
* Use when claude_code integration is disabled to prevent
|
|
6
|
-
* Claude Code-specific instructions from leaking into non-Claude agents.
|
|
7
|
-
*/
|
|
8
4
|
skipClaudeUserRules?: boolean;
|
|
9
5
|
}
|
|
10
|
-
|
|
11
|
-
* Find all rule files for a given context.
|
|
12
|
-
* Searches from currentFile upward to projectRoot for rule directories,
|
|
13
|
-
* then user-level directory (~/.claude/rules).
|
|
14
|
-
*
|
|
15
|
-
* IMPORTANT: This searches EVERY directory from file to project root.
|
|
16
|
-
* Not just the project root itself.
|
|
17
|
-
*
|
|
18
|
-
* @param projectRoot - Project root path (or null if outside any project)
|
|
19
|
-
* @param homeDir - User home directory
|
|
20
|
-
* @param currentFile - Current file being edited (for distance calculation)
|
|
21
|
-
* @returns Array of rule file candidates sorted by distance
|
|
22
|
-
*/
|
|
23
|
-
export declare function findRuleFiles(projectRoot: string | null, homeDir: string, currentFile: string, options?: FindRuleFilesOptions): RuleFileCandidate[];
|
|
6
|
+
export declare function findRuleFiles(projectRoot: string | null, homeDir: string, currentFile: string, options?: FindRuleFilesOptions, cache?: RuleScanCache): RuleFileCandidate[];
|
|
@@ -9,6 +9,7 @@ export interface ContinuationProgressUpdate {
|
|
|
9
9
|
export interface SessionStateStore {
|
|
10
10
|
getState: (sessionID: string) => SessionState;
|
|
11
11
|
getExistingState: (sessionID: string) => SessionState | undefined;
|
|
12
|
+
startPruneInterval: () => void;
|
|
12
13
|
recordActivity: (sessionID: string) => void;
|
|
13
14
|
trackContinuationProgress: (sessionID: string, incompleteCount: number, todos?: Todo[], options?: ContinuationProgressOptions) => ContinuationProgressUpdate;
|
|
14
15
|
resetContinuationProgress: (sessionID: string) => void;
|
|
@@ -10,6 +10,6 @@ export declare function handleWriteExistingFileGuardToolExecuteBefore(params: {
|
|
|
10
10
|
};
|
|
11
11
|
readPermissionsBySession: Map<string, Set<string>>;
|
|
12
12
|
sessionLastAccess: Map<string, number>;
|
|
13
|
-
|
|
13
|
+
getCanonicalSessionRoot: () => string;
|
|
14
14
|
maxTrackedSessions: number;
|
|
15
15
|
}): Promise<void>;
|