@reinamaccredy/oh-my-opencode 3.0.0-beta.11 → 3.0.0-beta.13

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.
@@ -40,6 +40,8 @@ export interface AgentPromptMetadata {
40
40
  keyTrigger?: string;
41
41
  }
42
42
  export declare function isGptModel(model: string): boolean;
43
+ export declare function isProxyPalGptModel(model: string): boolean;
44
+ export declare function getGptReasoningEffort(model: string): "medium" | "xhigh";
43
45
  export type BuiltinAgentName = "Sisyphus" | "oracle" | "librarian" | "explore" | "frontend-ui-ux-engineer" | "document-writer" | "multimodal-looker" | "Metis (Plan Consultant)" | "Momus (Plan Reviewer)" | "orchestrator-sisyphus";
44
46
  export type OverridableAgentName = "build" | BuiltinAgentName;
45
47
  export type AgentName = BuiltinAgentName;
package/dist/cli/index.js CHANGED
@@ -2253,7 +2253,7 @@ var require_picocolors = __commonJS((exports, module) => {
2253
2253
  var require_package = __commonJS((exports, module) => {
2254
2254
  module.exports = {
2255
2255
  name: "@reinamaccredy/oh-my-opencode",
2256
- version: "3.0.0-beta.11",
2256
+ version: "3.0.0-beta.13",
2257
2257
  description: "Fork of oh-my-opencode with Maestro workflow integration - Multi-Model Orchestration, Parallel Background Agents, Design Phases, and TDD Methodology",
2258
2258
  main: "dist/index.js",
2259
2259
  types: "dist/index.d.ts",
package/dist/index.js CHANGED
@@ -9048,11 +9048,15 @@ function createTodoContinuationEnforcer(ctx, options = {}) {
9048
9048
  }).catch(() => {});
9049
9049
  }
9050
9050
  async function injectContinuation(sessionID, incompleteCount, total) {
9051
- const state2 = sessions.get(sessionID);
9052
- if (state2?.isRecovering) {
9051
+ const sessionState = getState(sessionID);
9052
+ if (sessionState.isRecovering) {
9053
9053
  log(`[${HOOK_NAME}] Skipped injection: in recovery`, { sessionID });
9054
9054
  return;
9055
9055
  }
9056
+ if (sessionState.injectionFailed) {
9057
+ log(`[${HOOK_NAME}] Skipped injection: previous injection permanently failed`, { sessionID });
9058
+ return;
9059
+ }
9056
9060
  const hasRunningBgTasks = backgroundManager ? backgroundManager.getTasksByParentSession(sessionID).some((t) => t.status === "running") : false;
9057
9061
  if (hasRunningBgTasks) {
9058
9062
  log(`[${HOOK_NAME}] Skipped injection: background tasks running`, { sessionID });
@@ -9098,9 +9102,31 @@ function createTodoContinuationEnforcer(ctx, options = {}) {
9098
9102
  },
9099
9103
  query: { directory: ctx.directory }
9100
9104
  });
9105
+ sessionState.consecutiveFailures = 0;
9101
9106
  log(`[${HOOK_NAME}] Injection successful`, { sessionID });
9102
9107
  } catch (err) {
9103
- log(`[${HOOK_NAME}] Injection failed`, { sessionID, error: String(err) });
9108
+ const errorStr = String(err);
9109
+ const isProviderError = errorStr.includes("ProviderModelNotFoundError") || errorStr.includes("ProviderNotFoundError") || errorStr.includes("provider") && errorStr.includes("not found");
9110
+ sessionState.consecutiveFailures = (sessionState.consecutiveFailures ?? 0) + 1;
9111
+ if (isProviderError || sessionState.consecutiveFailures >= 3) {
9112
+ sessionState.injectionFailed = true;
9113
+ log(`[${HOOK_NAME}] Injection permanently failed - stopping retries`, {
9114
+ sessionID,
9115
+ error: errorStr,
9116
+ isProviderError,
9117
+ consecutiveFailures: sessionState.consecutiveFailures
9118
+ });
9119
+ await ctx.client.tui.showToast({
9120
+ body: {
9121
+ title: "Todo Continuation Error",
9122
+ message: isProviderError ? "Model not found. Check your provider configuration." : "Failed to continue after 3 attempts. Please continue manually.",
9123
+ variant: "error",
9124
+ duration: 5000
9125
+ }
9126
+ }).catch(() => {});
9127
+ } else {
9128
+ log(`[${HOOK_NAME}] Injection failed (attempt ${sessionState.consecutiveFailures}/3)`, { sessionID, error: errorStr });
9129
+ }
9104
9130
  }
9105
9131
  }
9106
9132
  function startCountdown(sessionID, incompleteCount, total) {
@@ -16940,6 +16966,14 @@ var AGENT_NAME_MAP = {
16940
16966
  var HOOK_NAME_MAP = {
16941
16967
  "anthropic-auto-compact": "anthropic-context-window-limit-recovery"
16942
16968
  };
16969
+ var GOOGLE_TO_PROXYPAL_MODEL_MAP = {
16970
+ "google/gemini-3-pro-preview": "proxypal/gemini-3-pro-preview",
16971
+ "google/gemini-3-flash-preview": "proxypal/gemini-3-flash-preview",
16972
+ "google/gemini-3-flash": "proxypal/gemini-3-flash-preview",
16973
+ "google/gemini-3-pro": "proxypal/gemini-3-pro-preview",
16974
+ "google/gemini-3-pro-high": "proxypal/gemini-3-pro-preview",
16975
+ "google/gemini-3-pro-low": "proxypal/gemini-3-pro-preview"
16976
+ };
16943
16977
  var MODEL_TO_CATEGORY_MAP = {
16944
16978
  "proxypal/gemini-3-pro-preview": "visual-engineering",
16945
16979
  "proxypal/gpt-5.2-codex": "ultrabrain",
@@ -16947,6 +16981,25 @@ var MODEL_TO_CATEGORY_MAP = {
16947
16981
  "proxypal/gemini-claude-opus-4-5-thinking": "most-capable",
16948
16982
  "proxypal/gemini-claude-sonnet-4-5-thinking": "general"
16949
16983
  };
16984
+ function migrateGoogleToProxypalModel(model) {
16985
+ const proxypalModel = GOOGLE_TO_PROXYPAL_MODEL_MAP[model];
16986
+ if (proxypalModel) {
16987
+ return { migrated: proxypalModel, changed: true };
16988
+ }
16989
+ return { migrated: model, changed: false };
16990
+ }
16991
+ function migrateModelsInConfig(config) {
16992
+ let changed = false;
16993
+ const migrated = { ...config };
16994
+ if (typeof migrated.model === "string") {
16995
+ const { migrated: newModel, changed: modelChanged } = migrateGoogleToProxypalModel(migrated.model);
16996
+ if (modelChanged) {
16997
+ migrated.model = newModel;
16998
+ changed = true;
16999
+ }
17000
+ }
17001
+ return { migrated, changed };
17002
+ }
16950
17003
  function migrateAgentNames(agents) {
16951
17004
  const migrated = {};
16952
17005
  let changed = false;
@@ -17009,6 +17062,26 @@ function migrateConfigFile(configPath, rawConfig) {
17009
17062
  needsWrite = true;
17010
17063
  }
17011
17064
  }
17065
+ if (rawConfig.agents && typeof rawConfig.agents === "object") {
17066
+ const agents = rawConfig.agents;
17067
+ for (const [name, config] of Object.entries(agents)) {
17068
+ const { migrated, changed } = migrateModelsInConfig(config);
17069
+ if (changed) {
17070
+ agents[name] = migrated;
17071
+ needsWrite = true;
17072
+ }
17073
+ }
17074
+ }
17075
+ if (rawConfig.categories && typeof rawConfig.categories === "object") {
17076
+ const categories = rawConfig.categories;
17077
+ for (const [name, config] of Object.entries(categories)) {
17078
+ const { migrated, changed } = migrateModelsInConfig(config);
17079
+ if (changed) {
17080
+ categories[name] = migrated;
17081
+ needsWrite = true;
17082
+ }
17083
+ }
17084
+ }
17012
17085
  if (rawConfig.agents && typeof rawConfig.agents === "object") {
17013
17086
  const agents = rawConfig.agents;
17014
17087
  for (const [name, config] of Object.entries(agents)) {
@@ -45216,7 +45289,7 @@ function resolveCategoryConfig(categoryName, userCategories) {
45216
45289
  const config3 = {
45217
45290
  ...defaultConfig,
45218
45291
  ...userConfig,
45219
- model: userConfig?.model ?? defaultConfig?.model ?? "anthropic/claude-sonnet-4-5"
45292
+ model: userConfig?.model ?? defaultConfig?.model ?? "proxypal/gemini-claude-sonnet-4-5-thinking"
45220
45293
  };
45221
45294
  let promptAppend = defaultPromptAppend;
45222
45295
  if (userConfig?.prompt_append) {
@@ -45375,10 +45448,20 @@ Session ID: ${args.resume}
45375
45448
  ${textContent || "(No text output)"}`;
45376
45449
  }
45377
45450
  if (args.category && args.subagent_type) {
45378
- return `\u274C Invalid arguments: Provide EITHER category OR subagent_type, not both.`;
45451
+ return `\u274C Invalid arguments: Provide EITHER category OR subagent_type, not both.
45452
+
45453
+ WRONG: sisyphus_task(category="general", subagent_type="Sisyphus-Junior-general", ...)
45454
+ RIGHT: sisyphus_task(category="general", ...) // Uses Sisyphus-Junior with general config
45455
+ RIGHT: sisyphus_task(subagent_type="oracle", ...) // Uses oracle agent directly`;
45379
45456
  }
45380
45457
  if (!args.category && !args.subagent_type) {
45381
- return `\u274C Invalid arguments: Must provide either category or subagent_type.`;
45458
+ return `\u274C Invalid arguments: Must provide either category or subagent_type.
45459
+
45460
+ Examples:
45461
+ - sisyphus_task(category="general", ...) \u2192 Uses Sisyphus-Junior with general config
45462
+ - sisyphus_task(category="visual-engineering", ...) \u2192 Uses Sisyphus-Junior with visual config
45463
+ - sisyphus_task(subagent_type="oracle", ...) \u2192 Uses oracle agent directly
45464
+ - sisyphus_task(subagent_type="explore", ...) \u2192 Uses explore agent directly`;
45382
45465
  }
45383
45466
  let agentToUse;
45384
45467
  let categoryModel;
@@ -49297,7 +49380,13 @@ function getModelLimit(state2, providerID, modelID) {
49297
49380
 
49298
49381
  // src/agents/types.ts
49299
49382
  function isGptModel(model) {
49300
- return model.startsWith("openai/") || model.startsWith("github-copilot/gpt-");
49383
+ return model.startsWith("openai/") || model.startsWith("github-copilot/gpt-") || model.includes("/gpt-");
49384
+ }
49385
+ function isProxyPalGptModel(model) {
49386
+ return model.startsWith("proxypal/") && model.includes("gpt-");
49387
+ }
49388
+ function getGptReasoningEffort(model) {
49389
+ return isProxyPalGptModel(model) ? "xhigh" : "medium";
49301
49390
  }
49302
49391
 
49303
49392
  // src/agents/sisyphus-prompt-builder.ts
@@ -50134,7 +50223,7 @@ function createSisyphusAgent(model = DEFAULT_MODEL, availableAgents, availableTo
50134
50223
  tools: { call_omo_agent: false }
50135
50224
  };
50136
50225
  if (isGptModel(model)) {
50137
- return { ...base, reasoningEffort: "medium" };
50226
+ return { ...base, reasoningEffort: getGptReasoningEffort(model) };
50138
50227
  }
50139
50228
  return { ...base, thinking: { type: "enabled", budgetTokens: 32000 } };
50140
50229
  }
@@ -50247,7 +50336,7 @@ function createOracleAgent(model = DEFAULT_MODEL2) {
50247
50336
  prompt: ORACLE_SYSTEM_PROMPT
50248
50337
  };
50249
50338
  if (isGptModel(model)) {
50250
- return { ...base, reasoningEffort: "medium", textVerbosity: "high" };
50339
+ return { ...base, reasoningEffort: getGptReasoningEffort(model), textVerbosity: "high" };
50251
50340
  }
50252
50341
  return { ...base, thinking: { type: "enabled", budgetTokens: 32000 } };
50253
50342
  }
@@ -51370,7 +51459,8 @@ function buildCategorySection(userCategories) {
51370
51459
  });
51371
51460
  return `##### Option A: Use CATEGORY (for domain-specific work)
51372
51461
 
51373
- Categories spawn \`Sisyphus-Junior-{category}\` with optimized settings:
51462
+ Categories configure \`Sisyphus-Junior\` with optimized settings for each domain.
51463
+ **Use \`category\` parameter only - do NOT include \`subagent_type\` when using category!**
51374
51464
 
51375
51465
  | Category | Temperature | Best For |
51376
51466
  |----------|-------------|----------|
@@ -51378,8 +51468,9 @@ ${categoryRows.join(`
51378
51468
  `)}
51379
51469
 
51380
51470
  \`\`\`typescript
51381
- sisyphus_task(category="visual-engineering", prompt="...") // UI/frontend work
51382
- sisyphus_task(category="ultrabrain", prompt="...") // Backend/strategic work
51471
+ sisyphus_task(category="visual-engineering", prompt="...") // UI/frontend work
51472
+ sisyphus_task(category="ultrabrain", prompt="...") // Backend/strategic work
51473
+ sisyphus_task(category="general", prompt="...") // General tasks
51383
51474
  \`\`\``;
51384
51475
  }
51385
51476
  function buildSkillsSection(skills) {
@@ -53102,7 +53193,7 @@ function createMomusAgent(model = DEFAULT_MODEL10) {
53102
53193
  prompt: MOMUS_SYSTEM_PROMPT
53103
53194
  };
53104
53195
  if (isGptModel(model)) {
53105
- return { ...base, reasoningEffort: "medium", textVerbosity: "high" };
53196
+ return { ...base, reasoningEffort: getGptReasoningEffort(model), textVerbosity: "high" };
53106
53197
  }
53107
53198
  return { ...base, thinking: { type: "enabled", budgetTokens: 32000 } };
53108
53199
  }
@@ -53348,7 +53439,7 @@ function createSisyphusJuniorAgent(categoryConfig, promptAppend) {
53348
53439
  };
53349
53440
  }
53350
53441
  if (isGptModel(model)) {
53351
- return { ...base, reasoningEffort: "medium" };
53442
+ return { ...base, reasoningEffort: getGptReasoningEffort(model) };
53352
53443
  }
53353
53444
  return {
53354
53445
  ...base,
@@ -56065,7 +56156,7 @@ function createConfigHandler(deps) {
56065
56156
  Sisyphus: builtinAgents.Sisyphus
56066
56157
  };
56067
56158
  agentConfig["Sisyphus-Junior"] = createSisyphusJuniorAgent({
56068
- model: "anthropic/claude-sonnet-4-5",
56159
+ model: "proxypal/gemini-claude-sonnet-4-5-thinking",
56069
56160
  temperature: 0.1
56070
56161
  });
56071
56162
  if (builderEnabled) {
@@ -1,6 +1,15 @@
1
1
  export declare const AGENT_NAME_MAP: Record<string, string>;
2
2
  export declare const HOOK_NAME_MAP: Record<string, string>;
3
+ export declare const GOOGLE_TO_PROXYPAL_MODEL_MAP: Record<string, string>;
3
4
  export declare const MODEL_TO_CATEGORY_MAP: Record<string, string>;
5
+ export declare function migrateGoogleToProxypalModel(model: string): {
6
+ migrated: string;
7
+ changed: boolean;
8
+ };
9
+ export declare function migrateModelsInConfig(config: Record<string, unknown>): {
10
+ migrated: Record<string, unknown>;
11
+ changed: boolean;
12
+ };
4
13
  export declare function migrateAgentNames(agents: Record<string, unknown>): {
5
14
  migrated: Record<string, unknown>;
6
15
  changed: boolean;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@reinamaccredy/oh-my-opencode",
3
- "version": "3.0.0-beta.11",
3
+ "version": "3.0.0-beta.13",
4
4
  "description": "Fork of oh-my-opencode with Maestro workflow integration - Multi-Model Orchestration, Parallel Background Agents, Design Phases, and TDD Methodology",
5
5
  "main": "dist/index.js",
6
6
  "types": "dist/index.d.ts",