opencode-matrixx 2.0.0 → 2.1.0

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.
Files changed (34) hide show
  1. package/README.md +16 -12
  2. package/dist/agents/architect/agent.d.ts +9 -9
  3. package/dist/agents/architect/default.d.ts +3 -3
  4. package/dist/agents/architect/gpt.d.ts +3 -3
  5. package/dist/agents/architect/index.d.ts +4 -4
  6. package/dist/agents/architect/prompt-section-builder.d.ts +1 -1
  7. package/dist/agents/builtin-agents/{atlas-agent.d.ts → architect-agent.d.ts} +1 -1
  8. package/dist/agents/builtin-agents/general-agents.d.ts +1 -1
  9. package/dist/agents/index.d.ts +1 -1
  10. package/dist/agents/merovingian.d.ts +1 -0
  11. package/dist/agents/types.d.ts +2 -2
  12. package/dist/cli/index.js +11 -10
  13. package/dist/config/schema/agent-names.d.ts +2 -2
  14. package/dist/config/schema/hooks.d.ts +1 -1
  15. package/dist/config/schema/matrixx-config.d.ts +2 -2
  16. package/dist/create-hooks.d.ts +2 -2
  17. package/dist/features/builtin-commands/templates/start-work.d.ts +1 -1
  18. package/dist/features/hook-message-injector/injector.d.ts +1 -1
  19. package/dist/features/mission-state/types.d.ts +1 -1
  20. package/dist/hooks/architect/{atlas-hook.d.ts → architect-hook.d.ts} +2 -2
  21. package/dist/hooks/architect/event-handler.d.ts +3 -3
  22. package/dist/hooks/architect/index.d.ts +2 -2
  23. package/dist/hooks/architect/types.d.ts +1 -1
  24. package/dist/hooks/index.d.ts +1 -1
  25. package/dist/hooks/mouse-notepad/constants.d.ts +1 -1
  26. package/dist/index.js +144 -94
  27. package/dist/plugin/hooks/create-continuation-hooks.d.ts +2 -2
  28. package/dist/plugin/hooks/create-core-hooks.d.ts +1 -1
  29. package/dist/plugin/hooks/create-session-hooks.d.ts +1 -1
  30. package/dist/tools/delegate-task/executor-types.d.ts +1 -1
  31. package/dist/tools/delegate-task/mouse-agent.d.ts +1 -1
  32. package/dist/tools/delegate-task/types.d.ts +1 -1
  33. package/package.json +8 -8
  34. /package/dist/agents/builtin-agents/{sisyphus-agent.d.ts → morpheus-agent.d.ts} +0 -0
package/dist/index.js CHANGED
@@ -17496,7 +17496,8 @@ import * as fs4 from "fs";
17496
17496
  // src/shared/migration/hook-names.ts
17497
17497
  var HOOK_NAME_MAP = {
17498
17498
  "anthropic-auto-compact": "anthropic-context-window-limit-recovery",
17499
- "sisyphus-orchestrator": "atlas",
17499
+ "sisyphus-orchestrator": "architect",
17500
+ "sisyphus-junior-notepad": "mouse-notepad",
17500
17501
  "empty-message-sanitizer": null
17501
17502
  };
17502
17503
  function migrateHookNames(hooks) {
@@ -18876,7 +18877,7 @@ async function isCallerOrchestrator(sessionID, client) {
18876
18877
  if (isSqliteBackend() && client) {
18877
18878
  try {
18878
18879
  const nearest2 = await findNearestMessageWithFieldsFromSDK(client, sessionID);
18879
- return getAgentConfigKey(nearest2?.agent ?? "") === "atlas";
18880
+ return getAgentConfigKey(nearest2?.agent ?? "") === "architect";
18880
18881
  } catch (error) {
18881
18882
  log("[session-utils] SDK orchestrator check failed", { sessionID, error: String(error) });
18882
18883
  return false;
@@ -21178,7 +21179,7 @@ You have an active work plan with incomplete tasks. Continue working.
21178
21179
  RULES:
21179
21180
  - **FIRST**: Read the plan file NOW to check exact current progress \u2014 count remaining \`- [ ]\` tasks
21180
21181
  - Proceed without asking for permission
21181
- - Change \`- [ ]\` to \`- [x]\` in the plan file when done
21182
+ - **IMMEDIATELY AFTER COMPLETION**: Mark \`- [ ]\` \u2192 \`- [x]\` in the plan file. This is MANDATORY \u2014 unmarked checkboxes = lost progress.
21182
21183
  - Use the notepad at .matrixx/notepads/{PLAN_NAME}/ to record learnings
21183
21184
  - Do not stop until all tasks are complete
21184
21185
  - If blocked, document the blocker and move to the next task`;
@@ -21250,7 +21251,7 @@ ${createSystemDirective(SystemDirectiveTypes.DELEGATION_REQUIRED)}
21250
21251
 
21251
21252
  **STOP. YOU ARE VIOLATING ORCHESTRATOR PROTOCOL.**
21252
21253
 
21253
- You (Atlas) are attempting to directly modify a file outside \`.matrixx/\`.
21254
+ You (Architect) are attempting to directly modify a file outside \`.matrixx/\`.
21254
21255
 
21255
21256
  **Path attempted:** $FILE_PATH
21256
21257
 
@@ -21376,7 +21377,7 @@ async function getLastAgentFromSession(sessionID, client) {
21376
21377
 
21377
21378
  // src/hooks/architect/event-handler.ts
21378
21379
  var CONTINUATION_COOLDOWN_MS = 5000;
21379
- function createAtlasEventHandler(input) {
21380
+ function createArchitectEventHandler(input) {
21380
21381
  const { ctx, options, sessions, getState } = input;
21381
21382
  return async ({ event }) => {
21382
21383
  const props = event.properties;
@@ -21450,6 +21451,7 @@ function createAtlasEventHandler(input) {
21450
21451
  const progress = getPlanProgress(missionState.active_plan);
21451
21452
  if (progress.isComplete) {
21452
21453
  log(`[${HOOK_NAME}] Mission complete`, { sessionID, plan: missionState.plan_name });
21454
+ clearMissionState(ctx.directory);
21453
21455
  return;
21454
21456
  }
21455
21457
  const now = Date.now();
@@ -21591,15 +21593,24 @@ Read(".matrixx/plans/${planName}.md")
21591
21593
  Count exactly: how many \`- [ ]\` remain? How many \`- [x]\` completed?
21592
21594
  This is YOUR ground truth. Use it to decide what comes next.
21593
21595
 
21594
- **STEP 7: MARK COMPLETION IN PLAN FILE (IMMEDIATELY)**
21596
+ **STEP 7: MARK COMPLETION IN PLAN FILE (IMMEDIATELY \u2014 NON-NEGOTIABLE)**
21595
21597
 
21596
- RIGHT NOW - Do not delay. Verification passed \u2192 Mark IMMEDIATELY.
21598
+ \u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501
21597
21599
 
21598
- Update the plan file \`.matrixx/plans/${planName}.md\`:
21599
- - Change \`- [ ]\` to \`- [x]\` for the completed task
21600
- - Use \`Edit\` tool to modify the checkbox
21600
+ **CRITICAL: THIS STEP IS MANDATORY. Skipping it = progress lost.**
21601
21601
 
21602
- **DO THIS BEFORE ANYTHING ELSE. Unmarked = Untracked = Lost progress.**
21602
+ RIGHT NOW \u2014 Do not delay. Verification passed \u2192 Mark IMMEDIATELY.
21603
+
21604
+ 1. Open plan file: \`.matrixx/plans/${planName}.md\`
21605
+ 2. Find the \`- [ ]\` checkbox for the completed task
21606
+ 3. Change \`- [ ]\` \u2192 \`- [x]\` using the \`Edit\` tool
21607
+ 4. Verify the edit was applied
21608
+
21609
+ **WARNING**: If you skip this step, the task appears UNDONE.
21610
+ The system counts \`- [x]\` checkboxes to track progress.
21611
+ No checkbox = No progress = Work wasted.
21612
+
21613
+ \u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501
21603
21614
 
21604
21615
  **STEP 8: COMMIT ATOMIC UNIT**
21605
21616
 
@@ -21700,6 +21711,9 @@ function createToolExecuteAfterHandler(input) {
21700
21711
  const missionState = readMissionState(ctx.directory);
21701
21712
  if (missionState) {
21702
21713
  const progress = getPlanProgress(missionState.active_plan);
21714
+ if (progress.isComplete) {
21715
+ return;
21716
+ }
21703
21717
  if (toolInput.sessionID && !missionState.session_ids?.includes(toolInput.sessionID)) {
21704
21718
  appendSessionId(ctx.directory, toolInput.sessionID);
21705
21719
  log(`[${HOOK_NAME}] Appended session to mission`, {
@@ -21778,8 +21792,8 @@ ${prompt}`;
21778
21792
  };
21779
21793
  }
21780
21794
 
21781
- // src/hooks/architect/atlas-hook.ts
21782
- function createAtlasHook(ctx, options) {
21795
+ // src/hooks/architect/architect-hook.ts
21796
+ function createArchitectHook(ctx, options) {
21783
21797
  const sessions = new Map;
21784
21798
  const pendingFilePaths = new Map;
21785
21799
  function getState(sessionID) {
@@ -21791,7 +21805,7 @@ function createAtlasHook(ctx, options) {
21791
21805
  return state3;
21792
21806
  }
21793
21807
  return {
21794
- handler: createAtlasEventHandler({ ctx, options, sessions, getState }),
21808
+ handler: createArchitectEventHandler({ ctx, options, sessions, getState }),
21795
21809
  "tool.execute.before": createToolExecuteBeforeHandler({ ctx, pendingFilePaths }),
21796
21810
  "tool.execute.after": createToolExecuteAfterHandler({ ctx, pendingFilePaths })
21797
21811
  };
@@ -23466,7 +23480,7 @@ var START_WORK_TEMPLATE = `You are starting a Morpheus work session.
23466
23480
  }
23467
23481
  \`\`\`
23468
23482
 
23469
- 5. **Read the plan file** and start executing tasks according to atlas workflow
23483
+ 5. **Read the plan file** and start executing tasks according to architect workflow
23470
23484
 
23471
23485
  ## OUTPUT FORMAT
23472
23486
 
@@ -23510,7 +23524,7 @@ Reading plan and beginning execution...
23510
23524
  - The session_id is injected by the hook - use it directly
23511
23525
  - Always update mission.json BEFORE starting work
23512
23526
  - Read the FULL plan file before delegating any tasks
23513
- - Follow atlas delegation protocols (7-section format)`;
23527
+ - Follow architect delegation protocols (7-section format)`;
23514
23528
 
23515
23529
  // src/features/builtin-commands/templates/stop-continuation.ts
23516
23530
  var STOP_CONTINUATION_TEMPLATE = `Stop all continuation mechanisms for the current session.
@@ -50583,7 +50597,7 @@ function createMatrixLoopHook(ctx, options) {
50583
50597
  // src/hooks/matrix-loop/index.ts
50584
50598
  init_storage();
50585
50599
  // src/hooks/mouse-notepad/constants.ts
50586
- var HOOK_NAME5 = "sisyphus-junior-notepad";
50600
+ var HOOK_NAME5 = "mouse-notepad";
50587
50601
  var NOTEPAD_DIRECTIVE = `
50588
50602
  <Work_Context>
50589
50603
  ## Notepad Location (for recording learnings)
@@ -50935,6 +50949,7 @@ function createPostCompactionDegradationMonitor(args) {
50935
50949
 
50936
50950
  // src/shared/context-limit-resolver.ts
50937
50951
  var DEFAULT_ANTHROPIC_ACTUAL_LIMIT = 200000;
50952
+ var DEFAULT_NON_ANTHROPIC_FALLBACK_LIMIT = 128000;
50938
50953
  function isAnthropicProvider2(providerID) {
50939
50954
  const normalized = providerID.toLowerCase();
50940
50955
  return normalized === "anthropic" || normalized === "google-vertex-anthropic" || normalized === "aws-bedrock-anthropic";
@@ -50955,7 +50970,7 @@ function resolveActualContextLimit(providerID, modelID, modelCacheState) {
50955
50970
  return cachedLimit;
50956
50971
  return DEFAULT_ANTHROPIC_ACTUAL_LIMIT;
50957
50972
  }
50958
- return modelCacheState?.modelContextLimitsCache?.get(`${providerID}/${modelID}`) ?? null;
50973
+ return modelCacheState?.modelContextLimitsCache?.get(`${providerID}/${modelID}`) ?? DEFAULT_NON_ANTHROPIC_FALLBACK_LIMIT;
50959
50974
  }
50960
50975
 
50961
50976
  // src/hooks/preemptive-compaction-trigger.ts
@@ -57014,8 +57029,8 @@ function createWriteExistingFileGuardHook(ctx) {
57014
57029
  }
57015
57030
  const resolvedPath = normalize(isAbsolute5(filePath) ? filePath : resolve7(ctx.directory, filePath));
57016
57031
  if (existsSync40(resolvedPath)) {
57017
- const sisyphusRoot = join55(ctx.directory, ".matrixx") + sep;
57018
- const isMatrixMarkdown = resolvedPath.startsWith(sisyphusRoot) && resolvedPath.endsWith(".md");
57032
+ const matrixxRoot = join55(ctx.directory, ".matrixx") + sep;
57033
+ const isMatrixMarkdown = resolvedPath.startsWith(matrixxRoot) && resolvedPath.endsWith(".md");
57019
57034
  if (isMatrixMarkdown) {
57020
57035
  log("[write-existing-file-guard] Allowing .matrixx/*.md overwrite", {
57021
57036
  sessionID: input.sessionID,
@@ -57103,7 +57118,7 @@ function createContinuationHooks(args) {
57103
57118
  }
57104
57119
  }
57105
57120
  const backgroundNotificationHook = isHookEnabled("background-notification") ? safeHook("background-notification", () => createBackgroundNotificationHook(backgroundManager)) : null;
57106
- const atlasHook = isHookEnabled("architect") ? safeHook("architect", () => createAtlasHook(ctx, {
57121
+ const architectHook = isHookEnabled("architect") ? safeHook("architect", () => createArchitectHook(ctx, {
57107
57122
  directory: ctx.directory,
57108
57123
  backgroundManager,
57109
57124
  isContinuationStopped: (sessionID) => stopContinuationGuard?.isStopped(sessionID) ?? false,
@@ -57116,7 +57131,7 @@ function createContinuationHooks(args) {
57116
57131
  todoContinuationEnforcer,
57117
57132
  unstableAgentBabysitter,
57118
57133
  backgroundNotificationHook,
57119
- atlasHook
57134
+ architectHook
57120
57135
  };
57121
57136
  }
57122
57137
 
@@ -74591,7 +74606,7 @@ ${textContent || "(No text output)"}`;
74591
74606
  }
74592
74607
 
74593
74608
  // src/tools/background-task/create-background-output.ts
74594
- var SISYPHUS_JUNIOR_AGENT = getAgentDisplayName("mouse");
74609
+ var MOUSE_AGENT = getAgentDisplayName("mouse");
74595
74610
  function resolveToolCallID(ctx) {
74596
74611
  if (typeof ctx.callID === "string" && ctx.callID.trim() !== "")
74597
74612
  return ctx.callID;
@@ -74602,7 +74617,7 @@ function resolveToolCallID(ctx) {
74602
74617
  return;
74603
74618
  }
74604
74619
  function formatResolvedTitle(task) {
74605
- const label = task.agent === SISYPHUS_JUNIOR_AGENT && task.category ? task.category : task.agent;
74620
+ const label = task.agent === MOUSE_AGENT && task.category ? task.category : task.agent;
74606
74621
  return `${label} - ${task.description}`;
74607
74622
  }
74608
74623
  function isTaskActiveStatus(status) {
@@ -75370,11 +75385,11 @@ function parseModelString2(model) {
75370
75385
  }
75371
75386
 
75372
75387
  // src/tools/delegate-task/mouse-agent.ts
75373
- var SISYPHUS_JUNIOR_AGENT2 = "mouse";
75388
+ var MOUSE_AGENT2 = "mouse";
75374
75389
 
75375
75390
  // src/tools/delegate-task/category-resolver.ts
75376
75391
  async function resolveCategoryExecution(args, executorCtx, inheritedModel, systemDefaultModel) {
75377
- const { client: client2, userCategories, sisyphusJuniorModel } = executorCtx;
75392
+ const { client: client2, userCategories, mouseModel } = executorCtx;
75378
75393
  const availableModels = await getAvailableModelsForDelegateTask(client2);
75379
75394
  const categoryName = args.category;
75380
75395
  const enabledCategories = mergeCategories(userCategories);
@@ -75419,16 +75434,16 @@ Available categories: ${allCategoryNames}`
75419
75434
  let actualModel;
75420
75435
  let modelInfo;
75421
75436
  let categoryModel;
75422
- const overrideModel = sisyphusJuniorModel;
75437
+ const overrideModel = mouseModel;
75423
75438
  const explicitCategoryModel = userCategories?.[args.category]?.model;
75424
75439
  if (!requirement) {
75425
- actualModel = explicitCategoryModel ?? overrideModel ?? resolved.model;
75440
+ actualModel = explicitCategoryModel ?? resolved.model ?? overrideModel;
75426
75441
  if (actualModel) {
75427
- modelInfo = explicitCategoryModel || overrideModel ? { model: actualModel, type: "user-defined", source: "override" } : { model: actualModel, type: "system-default", source: "system-default" };
75442
+ modelInfo = explicitCategoryModel ? { model: actualModel, type: "user-defined", source: "override" } : resolved.model ? { model: actualModel, type: "system-default", source: "system-default" } : { model: actualModel, type: "user-defined", source: "override" };
75428
75443
  }
75429
75444
  } else {
75430
75445
  const resolution = resolveModelForDelegateTask({
75431
- userModel: explicitCategoryModel ?? overrideModel,
75446
+ userModel: explicitCategoryModel,
75432
75447
  categoryDefaultModel: resolved.model,
75433
75448
  fallbackChain: requirement.fallbackChain,
75434
75449
  availableModels,
@@ -75448,7 +75463,7 @@ Available categories: ${allCategoryNames}`
75448
75463
  error: `Invalid model format "${actualModel}". Expected "provider/model" format (e.g., "anthropic/claude-sonnet-4-5").`
75449
75464
  };
75450
75465
  }
75451
- const type = explicitCategoryModel || overrideModel ? "user-defined" : systemDefaultModel && actualModel === systemDefaultModel ? "system-default" : "category-default";
75466
+ const type = explicitCategoryModel ? "user-defined" : systemDefaultModel && actualModel === systemDefaultModel ? "system-default" : "category-default";
75452
75467
  const source = type === "user-defined" ? "override" : type === "system-default" ? "system-default" : "category-default";
75453
75468
  modelInfo = { model: actualModel, type, source };
75454
75469
  const parsedModel = parseModelString2(actualModel);
@@ -75484,7 +75499,7 @@ Available categories: ${categoryNames.join(", ")}`
75484
75499
  const unstableModel = actualModel?.toLowerCase();
75485
75500
  const isUnstableAgent = resolved.config.is_unstable_agent === true || (unstableModel ? unstableModel.includes("gemini") || unstableModel.includes("minimax") : false);
75486
75501
  return {
75487
- agentToUse: SISYPHUS_JUNIOR_AGENT2,
75502
+ agentToUse: MOUSE_AGENT2,
75488
75503
  categoryModel,
75489
75504
  categoryPromptAppend,
75490
75505
  modelInfo,
@@ -75544,11 +75559,11 @@ async function resolveSubagentExecution(args, executorCtx, parentAgent, category
75544
75559
  return { agentToUse: "", categoryModel: undefined, error: `Agent name cannot be empty.` };
75545
75560
  }
75546
75561
  const agentName = args.subagent_type.trim();
75547
- if (agentName.toLowerCase() === SISYPHUS_JUNIOR_AGENT2.toLowerCase()) {
75562
+ if (agentName.toLowerCase() === MOUSE_AGENT2.toLowerCase()) {
75548
75563
  return {
75549
75564
  agentToUse: "",
75550
75565
  categoryModel: undefined,
75551
- error: `Cannot use subagent_type="${SISYPHUS_JUNIOR_AGENT2}" directly. Use category parameter instead (e.g., ${categoryExamples}).
75566
+ error: `Cannot use subagent_type="${MOUSE_AGENT2}" directly. Use category parameter instead (e.g., ${categoryExamples}).
75552
75567
 
75553
75568
  Mouse is spawned automatically when you specify a category. Pick the appropriate category for your task domain.`
75554
75569
  };
@@ -76685,13 +76700,13 @@ Prompts MUST be in English.`;
76685
76700
  async execute(args, toolContext) {
76686
76701
  const ctx = toolContext;
76687
76702
  if (args.category) {
76688
- if (args.subagent_type && args.subagent_type !== SISYPHUS_JUNIOR_AGENT2) {
76703
+ if (args.subagent_type && args.subagent_type !== MOUSE_AGENT2) {
76689
76704
  log("[task] category provided - overriding subagent_type to mouse", {
76690
76705
  category: args.category,
76691
76706
  subagent_type: args.subagent_type
76692
76707
  });
76693
76708
  }
76694
- args.subagent_type = SISYPHUS_JUNIOR_AGENT2;
76709
+ args.subagent_type = MOUSE_AGENT2;
76695
76710
  }
76696
76711
  await ctx.metadata?.({
76697
76712
  title: args.description
@@ -78734,7 +78749,7 @@ function createSessionHooks(args) {
78734
78749
  const delegateTaskRetry = isHookEnabled("delegate-task-retry") ? safeHook("delegate-task-retry", () => createDelegateTaskRetryHook(ctx)) : null;
78735
78750
  const startWork = isHookEnabled("start-work") ? safeHook("start-work", () => createStartWorkHook(ctx)) : null;
78736
78751
  const prometheusMdOnly = isHookEnabled("prometheus-md-only") ? safeHook("prometheus-md-only", () => createOracleMdOnlyHook(ctx)) : null;
78737
- const sisyphusJuniorNotepad = isHookEnabled("sisyphus-junior-notepad") ? safeHook("sisyphus-junior-notepad", () => createMouseNotepadHook(ctx)) : null;
78752
+ const mouseNotepad = isHookEnabled("mouse-notepad") ? safeHook("mouse-notepad", () => createMouseNotepadHook(ctx)) : null;
78738
78753
  const questionLabelTruncator = createQuestionLabelTruncatorHook();
78739
78754
  const taskResumeInfo = createTaskResumeInfoHook();
78740
78755
  const anthropicEffort = isHookEnabled("anthropic-effort") ? safeHook("anthropic-effort", () => createAnthropicEffortHook()) : null;
@@ -78758,7 +78773,7 @@ function createSessionHooks(args) {
78758
78773
  delegateTaskRetry,
78759
78774
  startWork,
78760
78775
  prometheusMdOnly,
78761
- sisyphusJuniorNotepad,
78776
+ mouseNotepad,
78762
78777
  questionLabelTruncator,
78763
78778
  taskResumeInfo,
78764
78779
  anthropicEffort,
@@ -86958,9 +86973,9 @@ function buildOracleSection(agents) {
86958
86973
  const useWhen = oracleAgent.metadata.useWhen || [];
86959
86974
  const avoidWhen = oracleAgent.metadata.avoidWhen || [];
86960
86975
  return `<Oracle_Usage>
86961
- ## Oracle \u2014 Read-Only High-IQ Consultant
86976
+ ## Oracle \u2014 Plan Builder
86962
86977
 
86963
- Oracle is a read-only, expensive, high-quality reasoning model for debugging and architecture. Consultation only.
86978
+ Oracle is the Plan Builder \u2014 creates detailed, structured work plans from user requests. Use oracle when you need comprehensive planning before implementation.
86964
86979
 
86965
86980
  ### WHEN to Consult:
86966
86981
 
@@ -86975,7 +86990,7 @@ ${avoidWhen.map((w) => `- ${w}`).join(`
86975
86990
  `)}
86976
86991
 
86977
86992
  ### Usage Pattern:
86978
- Briefly announce "Consulting Oracle for [reason]" before invocation.
86993
+ Oracle creates plans, not code. Invoke oracle to decompose complex requests into structured work plans with clear steps, then execute the plan yourself or delegate to workers.
86979
86994
 
86980
86995
  **Exception**: This is the ONLY case where you announce before acting. For all other work, start immediately without status updates.
86981
86996
  </Oracle_Usage>`;
@@ -87011,9 +87026,9 @@ ${patterns.join(`
87011
87026
  }
87012
87027
 
87013
87028
  // src/agents/architect/default.ts
87014
- var ATLAS_SYSTEM_PROMPT = `
87029
+ var ARCHITECT_SYSTEM_PROMPT = `
87015
87030
  <identity>
87016
- You are Atlas - the Master Orchestrator from Matrixx.
87031
+ You are Architect - the Master Orchestrator from Matrixx.
87017
87032
 
87018
87033
  In Greek mythology, Atlas holds up the celestial heavens. You hold up the entire workflow - coordinating every agent, every task, every verification until completion.
87019
87034
 
@@ -87410,14 +87425,14 @@ You are the QA gate. Subagents lie. Verify EVERYTHING.
87410
87425
  - **Use \`session_id="{session_id}"\` for retries, fixes, and follow-ups**
87411
87426
  </critical_overrides>
87412
87427
  `;
87413
- function getDefaultAtlasPrompt() {
87414
- return ATLAS_SYSTEM_PROMPT;
87428
+ function getDefaultArchitectPrompt() {
87429
+ return ARCHITECT_SYSTEM_PROMPT;
87415
87430
  }
87416
87431
 
87417
87432
  // src/agents/architect/gpt.ts
87418
- var ATLAS_GPT_SYSTEM_PROMPT = `
87433
+ var ARCHITECT_GPT_SYSTEM_PROMPT = `
87419
87434
  <identity>
87420
- You are Atlas - Master Orchestrator from Matrixx.
87435
+ You are Architect - Master Orchestrator from Matrixx.
87421
87436
  Role: Conductor, not musician. General, not soldier.
87422
87437
  You DELEGATE, COORDINATE, and VERIFY. You NEVER write code yourself.
87423
87438
  </identity>
@@ -87763,8 +87778,8 @@ You are the QA gate. Subagents lie. Verify EVERYTHING.
87763
87778
  - Do NOT expand task scope; if you notice new work, call it out as optional
87764
87779
  </user_updates_spec>
87765
87780
  `;
87766
- function getGptAtlasPrompt() {
87767
- return ATLAS_GPT_SYSTEM_PROMPT;
87781
+ function getGptArchitectPrompt() {
87782
+ return ARCHITECT_GPT_SYSTEM_PROMPT;
87768
87783
  }
87769
87784
 
87770
87785
  // src/agents/architect/prompt-section-builder.ts
@@ -87884,19 +87899,19 @@ ${agentRows.join(`
87884
87899
 
87885
87900
  // src/agents/architect/agent.ts
87886
87901
  var MODE = "primary";
87887
- function getAtlasPromptSource(model) {
87902
+ function getArchitectPromptSource(model) {
87888
87903
  if (model && isGptModel(model)) {
87889
87904
  return "gpt";
87890
87905
  }
87891
87906
  return "default";
87892
87907
  }
87893
- function getAtlasPrompt(model) {
87894
- const source = getAtlasPromptSource(model);
87908
+ function getArchitectPrompt(model) {
87909
+ const source = getArchitectPromptSource(model);
87895
87910
  switch (source) {
87896
87911
  case "gpt":
87897
- return getGptAtlasPrompt();
87912
+ return getGptArchitectPrompt();
87898
87913
  default:
87899
- return getDefaultAtlasPrompt();
87914
+ return getDefaultArchitectPrompt();
87900
87915
  }
87901
87916
  }
87902
87917
  function buildDynamicOrchestratorPrompt(ctx) {
@@ -87914,16 +87929,16 @@ function buildDynamicOrchestratorPrompt(ctx) {
87914
87929
  const decisionMatrix = buildDecisionMatrix(agents, userCategories);
87915
87930
  const skillsSection = buildSkillsSection(skills);
87916
87931
  const categorySkillsGuide = buildCategorySkillsDelegationGuide(availableCategories, skills);
87917
- const basePrompt = getAtlasPrompt(model);
87932
+ const basePrompt = getArchitectPrompt(model);
87918
87933
  return basePrompt.replace("{CATEGORY_SECTION}", categorySection).replace("{AGENT_SECTION}", agentSection).replace("{DECISION_MATRIX}", decisionMatrix).replace("{SKILLS_SECTION}", skillsSection).replace("{{CATEGORY_SKILLS_DELEGATION_GUIDE}}", categorySkillsGuide);
87919
87934
  }
87920
- function createAtlasAgent(ctx) {
87935
+ function createArchitectAgent(ctx) {
87921
87936
  const restrictions = createAgentToolRestrictions([
87922
87937
  "task",
87923
87938
  "delegate_agent"
87924
87939
  ]);
87925
87940
  const baseConfig = {
87926
- description: "Orchestrates work via task() to complete ALL tasks in a todo list until fully done. (Atlas - Matrixx)",
87941
+ description: "Orchestrates work via task() to complete ALL tasks in a todo list until fully done. (Architect - Matrixx)",
87927
87942
  mode: MODE,
87928
87943
  ...ctx.model ? { model: ctx.model } : {},
87929
87944
  temperature: 0.1,
@@ -87933,11 +87948,11 @@ function createAtlasAgent(ctx) {
87933
87948
  };
87934
87949
  return baseConfig;
87935
87950
  }
87936
- createAtlasAgent.mode = MODE;
87937
- var atlasPromptMetadata = {
87951
+ createArchitectAgent.mode = MODE;
87952
+ var architectPromptMetadata = {
87938
87953
  category: "advisor",
87939
87954
  cost: "EXPENSIVE",
87940
- promptAlias: "Atlas",
87955
+ promptAlias: "Architect",
87941
87956
  triggers: [
87942
87957
  {
87943
87958
  domain: "Todo list orchestration",
@@ -88059,8 +88074,8 @@ function getFirstFallbackModel(requirement) {
88059
88074
  };
88060
88075
  }
88061
88076
 
88062
- // src/agents/builtin-agents/atlas-agent.ts
88063
- function maybeCreateAtlasConfig(input) {
88077
+ // src/agents/builtin-agents/architect-agent.ts
88078
+ function maybeCreateArchitectConfig(input) {
88064
88079
  const {
88065
88080
  disabledAgents,
88066
88081
  agentOverrides,
@@ -88076,25 +88091,25 @@ function maybeCreateAtlasConfig(input) {
88076
88091
  if (disabledAgents.includes("architect"))
88077
88092
  return;
88078
88093
  const orchestratorOverride = agentOverrides.architect;
88079
- const atlasRequirement = AGENT_MODEL_REQUIREMENTS.architect;
88080
- const atlasResolution = applyModelResolution({
88094
+ const architectRequirement = AGENT_MODEL_REQUIREMENTS.architect;
88095
+ const architectResolution = applyModelResolution({
88081
88096
  uiSelectedModel: orchestratorOverride?.model ? undefined : uiSelectedModel,
88082
88097
  userModel: orchestratorOverride?.model,
88083
- requirement: atlasRequirement,
88098
+ requirement: architectRequirement,
88084
88099
  availableModels,
88085
88100
  systemDefaultModel
88086
88101
  });
88087
- if (!atlasResolution)
88102
+ if (!architectResolution)
88088
88103
  return;
88089
- const { model: atlasModel, variant: atlasResolvedVariant } = atlasResolution;
88090
- let orchestratorConfig = createAtlasAgent({
88091
- model: atlasModel,
88104
+ const { model: architectModel, variant: architectResolvedVariant } = architectResolution;
88105
+ let orchestratorConfig = createArchitectAgent({
88106
+ model: architectModel,
88092
88107
  availableAgents,
88093
88108
  availableSkills,
88094
88109
  userCategories
88095
88110
  });
88096
- if (atlasResolvedVariant) {
88097
- orchestratorConfig = { ...orchestratorConfig, variant: atlasResolvedVariant };
88111
+ if (architectResolvedVariant) {
88112
+ orchestratorConfig = { ...orchestratorConfig, variant: architectResolvedVariant };
88098
88113
  }
88099
88114
  orchestratorConfig = applyOverrides(orchestratorConfig, orchestratorOverride, mergedCategories, directory);
88100
88115
  return orchestratorConfig;
@@ -88223,6 +88238,8 @@ function collectPendingBuiltinAgents(input) {
88223
88238
  const pendingAgentConfigs = new Map;
88224
88239
  for (const [name, source] of Object.entries(agentSources)) {
88225
88240
  const agentName = name;
88241
+ if (!source)
88242
+ continue;
88226
88243
  if (agentName === "morpheus")
88227
88244
  continue;
88228
88245
  if (agentName === "keymaker")
@@ -88269,6 +88286,14 @@ function collectPendingBuiltinAgents(input) {
88269
88286
  });
88270
88287
  }
88271
88288
  }
88289
+ const oracleMetadata = agentMetadata.oracle;
88290
+ if (oracleMetadata) {
88291
+ availableAgents.push({
88292
+ name: "oracle",
88293
+ description: "Read-only consultation agent. High-IQ reasoning specialist for debugging hard problems and high-difficulty architecture design. (Oracle - Matrixx)",
88294
+ metadata: oracleMetadata
88295
+ });
88296
+ }
88272
88297
  return { pendingAgentConfigs, availableAgents };
88273
88298
  }
88274
88299
 
@@ -89386,7 +89411,7 @@ function createMorpheusAgent(model, availableAgents, availableToolNames, availab
89386
89411
  }
89387
89412
  createMorpheusAgent.mode = MODE3;
89388
89413
 
89389
- // src/agents/builtin-agents/sisyphus-agent.ts
89414
+ // src/agents/builtin-agents/morpheus-agent.ts
89390
89415
  function maybeCreateMorpheusConfig(input) {
89391
89416
  const {
89392
89417
  disabledAgents,
@@ -89403,25 +89428,25 @@ function maybeCreateMorpheusConfig(input) {
89403
89428
  useTaskSystem
89404
89429
  } = input;
89405
89430
  const morpheusOverride = agentOverrides.morpheus;
89406
- const sisyphusRequirement = AGENT_MODEL_REQUIREMENTS.morpheus;
89431
+ const morpheusRequirement = AGENT_MODEL_REQUIREMENTS.morpheus;
89407
89432
  const hasMorpheusExplicitConfig = morpheusOverride !== undefined;
89408
- const meetsMorpheusAnyModelRequirement = !sisyphusRequirement?.requiresAnyModel || hasMorpheusExplicitConfig || isFirstRunNoCache || isAnyFallbackModelAvailable(sisyphusRequirement.fallbackChain, availableModels);
89433
+ const meetsMorpheusAnyModelRequirement = !morpheusRequirement?.requiresAnyModel || hasMorpheusExplicitConfig || isFirstRunNoCache || isAnyFallbackModelAvailable(morpheusRequirement.fallbackChain, availableModels);
89409
89434
  if (disabledAgents.includes("morpheus") || !meetsMorpheusAnyModelRequirement)
89410
89435
  return;
89411
- let sisyphusResolution = applyModelResolution({
89436
+ let morpheusResolution = applyModelResolution({
89412
89437
  uiSelectedModel: morpheusOverride?.model ? undefined : uiSelectedModel,
89413
89438
  userModel: morpheusOverride?.model,
89414
- requirement: sisyphusRequirement,
89439
+ requirement: morpheusRequirement,
89415
89440
  availableModels,
89416
89441
  systemDefaultModel
89417
89442
  });
89418
89443
  if (isFirstRunNoCache && !morpheusOverride?.model && !uiSelectedModel) {
89419
- sisyphusResolution = getFirstFallbackModel(sisyphusRequirement);
89444
+ morpheusResolution = getFirstFallbackModel(morpheusRequirement);
89420
89445
  }
89421
- if (!sisyphusResolution)
89446
+ if (!morpheusResolution)
89422
89447
  return;
89423
- const { model: sisyphusModel, variant: morpheusResolvedVariant } = sisyphusResolution;
89424
- let morpheusConfig = createMorpheusAgent(sisyphusModel, availableAgents, undefined, availableSkills, availableCategories, useTaskSystem);
89448
+ const { model: morpheusModel, variant: morpheusResolvedVariant } = morpheusResolution;
89449
+ let morpheusConfig = createMorpheusAgent(morpheusModel, availableAgents, undefined, availableSkills, availableCategories, useTaskSystem);
89425
89450
  if (morpheusResolvedVariant) {
89426
89451
  morpheusConfig = { ...morpheusConfig, variant: morpheusResolvedVariant };
89427
89452
  }
@@ -89673,7 +89698,7 @@ var MODE6 = "subagent";
89673
89698
  var ORACLE_PROMPT_METADATA = {
89674
89699
  category: "advisor",
89675
89700
  cost: "EXPENSIVE",
89676
- promptAlias: "Oracle",
89701
+ promptAlias: "Consultant",
89677
89702
  triggers: [
89678
89703
  { domain: "Architecture decisions", trigger: "Multi-system tradeoffs, unfamiliar patterns" },
89679
89704
  { domain: "Self-review", trigger: "After completing significant implementation" },
@@ -89695,6 +89720,30 @@ var ORACLE_PROMPT_METADATA = {
89695
89720
  "Things you can infer from existing code patterns"
89696
89721
  ]
89697
89722
  };
89723
+ var ORACLE_PLAN_BUILDER_METADATA = {
89724
+ category: "advisor",
89725
+ cost: "EXPENSIVE",
89726
+ triggers: [
89727
+ { domain: "Architecture decisions", trigger: "Multi-system tradeoffs, unfamiliar patterns" },
89728
+ { domain: "Work planning", trigger: "Complex feature implementation, refactoring" },
89729
+ { domain: "Complex task breakdown", trigger: "Large ambiguous requests needing decomposition" },
89730
+ { domain: "Self-review", trigger: "After completing significant implementation" }
89731
+ ],
89732
+ useWhen: [
89733
+ "Complex architecture design",
89734
+ "Work planning and task decomposition",
89735
+ "Large ambiguous requests needing structure",
89736
+ "After completing significant work for review",
89737
+ "Multi-system tradeoffs and integration planning"
89738
+ ],
89739
+ avoidWhen: [
89740
+ "Simple file operations (use direct tools)",
89741
+ "Questions answerable from code you've read",
89742
+ "Trivial decisions (variable names, formatting)",
89743
+ "Quick debugging tasks (try yourself first)",
89744
+ "Things you can infer from existing code patterns"
89745
+ ]
89746
+ };
89698
89747
  var ORACLE_SYSTEM_PROMPT = `You are a strategic technical advisor with deep reasoning capabilities, operating as a specialized consultant within an AI-assisted development environment.
89699
89748
 
89700
89749
  <context>
@@ -91148,19 +91197,20 @@ var agentSources = {
91148
91197
  construct: createMultimodalLookerAgent,
91149
91198
  seraph: createSeraphAgent,
91150
91199
  smith: createSmithAgent,
91151
- architect: createAtlasAgent,
91200
+ architect: createArchitectAgent,
91152
91201
  cipher: createCipherAgent,
91153
91202
  sentinel: createSentinelAgent,
91154
91203
  sati: createSatiAgent
91155
91204
  };
91156
91205
  var agentMetadata = {
91157
91206
  merovingian: ORACLE_PROMPT_METADATA,
91207
+ oracle: ORACLE_PLAN_BUILDER_METADATA,
91158
91208
  operator: LIBRARIAN_PROMPT_METADATA,
91159
91209
  trinity: EXPLORE_PROMPT_METADATA,
91160
91210
  construct: MULTIMODAL_LOOKER_PROMPT_METADATA,
91161
91211
  seraph: seraphPromptMetadata,
91162
91212
  smith: smithPromptMetadata,
91163
- architect: atlasPromptMetadata,
91213
+ architect: architectPromptMetadata,
91164
91214
  cipher: CIPHER_PROMPT_METADATA,
91165
91215
  sentinel: SENTINEL_PROMPT_METADATA,
91166
91216
  sati: SATI_PROMPT_METADATA
@@ -91247,7 +91297,7 @@ async function createBuiltinAgents(disabledAgents = [], agentOverrides = {}, dir
91247
91297
  for (const [name, config4] of pendingAgentConfigs) {
91248
91298
  result[name] = config4;
91249
91299
  }
91250
- const atlasConfig = maybeCreateAtlasConfig({
91300
+ const architectConfig = maybeCreateArchitectConfig({
91251
91301
  disabledAgents,
91252
91302
  agentOverrides,
91253
91303
  uiSelectedModel,
@@ -91259,8 +91309,8 @@ async function createBuiltinAgents(disabledAgents = [], agentOverrides = {}, dir
91259
91309
  directory,
91260
91310
  userCategories: categories
91261
91311
  });
91262
- if (atlasConfig) {
91263
- result.architect = atlasConfig;
91312
+ if (architectConfig) {
91313
+ result.architect = architectConfig;
91264
91314
  }
91265
91315
  return result;
91266
91316
  }
@@ -94382,7 +94432,7 @@ function createToolRegistry(args) {
94382
94432
  client: ctx.client,
94383
94433
  directory: ctx.directory,
94384
94434
  userCategories: pluginConfig.categories,
94385
- sisyphusJuniorModel: pluginConfig.agents?.mouse?.model,
94435
+ mouseModel: pluginConfig.agents?.mouse?.model,
94386
94436
  browserProvider: skillContext.browserProvider,
94387
94437
  disabledSkills: skillContext.disabledSkills,
94388
94438
  availableCategories,
@@ -95066,7 +95116,7 @@ var HookNameSchema = exports_external.enum([
95066
95116
  "edit-error-recovery",
95067
95117
  "delegate-task-retry",
95068
95118
  "prometheus-md-only",
95069
- "sisyphus-junior-notepad",
95119
+ "mouse-notepad",
95070
95120
  "start-work",
95071
95121
  "architect",
95072
95122
  "unstable-agent-babysitter",
@@ -95618,7 +95668,7 @@ function createEventHandler2(args) {
95618
95668
  await Promise.resolve(hooks2.matrixLoop?.event?.(input));
95619
95669
  await Promise.resolve(hooks2.stopContinuationGuard?.event?.(input));
95620
95670
  await Promise.resolve(hooks2.compactionTodoPreserver?.event?.(input));
95621
- await Promise.resolve(hooks2.atlasHook?.handler?.(input));
95671
+ await Promise.resolve(hooks2.architectHook?.handler?.(input));
95622
95672
  };
95623
95673
  const recentSyntheticIdles = new Map;
95624
95674
  const recentRealIdles = new Map;
@@ -95803,7 +95853,7 @@ function createToolExecuteAfterHandler2(args) {
95803
95853
  await hooks2.interactiveBashSession?.["tool.execute.after"]?.(input, output);
95804
95854
  await hooks2.editErrorRecovery?.["tool.execute.after"]?.(input, output);
95805
95855
  await hooks2.delegateTaskRetry?.["tool.execute.after"]?.(input, output);
95806
- await hooks2.atlasHook?.["tool.execute.after"]?.(input, output);
95856
+ await hooks2.architectHook?.["tool.execute.after"]?.(input, output);
95807
95857
  await hooks2.taskResumeInfo?.["tool.execute.after"]?.(input, output);
95808
95858
  await hooks2.hashlineReadEnhancer?.["tool.execute.after"]?.(input, output);
95809
95859
  await hooks2.jsonErrorRecovery?.["tool.execute.after"]?.(input, output);
@@ -95862,8 +95912,8 @@ function createToolExecuteBeforeHandler2(args) {
95862
95912
  const nonInteractiveEnvHook = hooks2.nonInteractiveEnv?.["tool.execute.before"];
95863
95913
  const bashFileReadGuardHook = hooks2.bashFileReadGuard?.["tool.execute.before"];
95864
95914
  const questionLabelTruncatorHook = hooks2.questionLabelTruncator?.["tool.execute.before"];
95865
- const sisyphusJuniorNotepadHook = hooks2.sisyphusJuniorNotepad?.["tool.execute.before"];
95866
- const atlasHookHook = hooks2.atlasHook?.["tool.execute.before"];
95915
+ const mouseNotepadHook = hooks2.mouseNotepad?.["tool.execute.before"];
95916
+ const architectHookHook = hooks2.architectHook?.["tool.execute.before"];
95867
95917
  return async (input, output) => {
95868
95918
  await Promise.all([
95869
95919
  qualityGateHook?.(input, output),
@@ -95895,8 +95945,8 @@ function createToolExecuteBeforeHandler2(args) {
95895
95945
  await bashFileReadGuardHook?.(input, output);
95896
95946
  await questionLabelTruncatorHook?.(input, output);
95897
95947
  await prometheusMdOnlyHook?.(input, output);
95898
- await sisyphusJuniorNotepadHook?.(input, output);
95899
- await atlasHookHook?.(input, output);
95948
+ await mouseNotepadHook?.(input, output);
95949
+ await architectHookHook?.(input, output);
95900
95950
  if (resolvePromise) {
95901
95951
  const resolvedAgent = await resolvePromise;
95902
95952
  output.args.subagent_type = resolvedAgent ?? "continue";