ur-agent 1.65.9 → 1.65.10

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/cli.js CHANGED
@@ -75597,7 +75597,7 @@ var init_auth = __esm(() => {
75597
75597
 
75598
75598
  // src/utils/userAgent.ts
75599
75599
  function getURCodeUserAgent() {
75600
- return `ur/${"1.65.9"}`;
75600
+ return `ur/${"1.65.10"}`;
75601
75601
  }
75602
75602
 
75603
75603
  // src/utils/workloadContext.ts
@@ -75619,7 +75619,7 @@ function getUserAgent() {
75619
75619
  const clientApp = process.env.UR_AGENT_SDK_CLIENT_APP ? `, client-app/${process.env.UR_AGENT_SDK_CLIENT_APP}` : "";
75620
75620
  const workload = getWorkload();
75621
75621
  const workloadSuffix = workload ? `, workload/${workload}` : "";
75622
- return `ur-cli/${"1.65.9"} (${process.env.USER_TYPE}, ${process.env.UR_CODE_ENTRYPOINT ?? "cli"}${agentSdkVersion}${clientApp}${workloadSuffix})`;
75622
+ return `ur-cli/${"1.65.10"} (${process.env.USER_TYPE}, ${process.env.UR_CODE_ENTRYPOINT ?? "cli"}${agentSdkVersion}${clientApp}${workloadSuffix})`;
75623
75623
  }
75624
75624
  function getMCPUserAgent() {
75625
75625
  const parts = [];
@@ -75633,7 +75633,7 @@ function getMCPUserAgent() {
75633
75633
  parts.push(`client-app/${process.env.UR_AGENT_SDK_CLIENT_APP}`);
75634
75634
  }
75635
75635
  const suffix = parts.length > 0 ? ` (${parts.join(", ")})` : "";
75636
- return `ur/${"1.65.9"}${suffix}`;
75636
+ return `ur/${"1.65.10"}${suffix}`;
75637
75637
  }
75638
75638
  function getWebFetchUserAgent() {
75639
75639
  return `UR-User (${getURCodeUserAgent()})`;
@@ -75771,7 +75771,7 @@ var init_user = __esm(() => {
75771
75771
  deviceId,
75772
75772
  sessionId: getSessionId(),
75773
75773
  email: getEmail(),
75774
- appVersion: "1.65.9",
75774
+ appVersion: "1.65.10",
75775
75775
  platform: getHostPlatformForAnalytics(),
75776
75776
  organizationUuid,
75777
75777
  accountUuid,
@@ -83971,7 +83971,7 @@ var init_metadata = __esm(() => {
83971
83971
  COMPOUND_OPERATOR_REGEX = /\s*(?:&&|\|\||[;|])\s*/;
83972
83972
  WHITESPACE_REGEX = /\s+/;
83973
83973
  getVersionBase = memoize_default(() => {
83974
- const match = "1.65.9".match(/^\d+\.\d+\.\d+(?:-[a-z]+)?/);
83974
+ const match = "1.65.10".match(/^\d+\.\d+\.\d+(?:-[a-z]+)?/);
83975
83975
  return match ? match[0] : undefined;
83976
83976
  });
83977
83977
  buildEnvContext = memoize_default(async () => {
@@ -84011,7 +84011,7 @@ var init_metadata = __esm(() => {
84011
84011
  isGithubAction: isEnvTruthy(process.env.GITHUB_ACTIONS),
84012
84012
  isURCodeAction: isEnvTruthy(process.env.UR_CODE_ACTION),
84013
84013
  isURAiAuth: isURAISubscriber(),
84014
- version: "1.65.9",
84014
+ version: "1.65.10",
84015
84015
  versionBase: getVersionBase(),
84016
84016
  buildTime: "",
84017
84017
  deploymentEnvironment: env2.detectDeploymentEnvironment(),
@@ -84681,7 +84681,7 @@ function initialize1PEventLogging() {
84681
84681
  const platform2 = getPlatform();
84682
84682
  const attributes = {
84683
84683
  [import_semantic_conventions4.ATTR_SERVICE_NAME]: "ur",
84684
- [import_semantic_conventions4.ATTR_SERVICE_VERSION]: "1.65.9"
84684
+ [import_semantic_conventions4.ATTR_SERVICE_VERSION]: "1.65.10"
84685
84685
  };
84686
84686
  if (platform2 === "wsl") {
84687
84687
  const wslVersion = getWslVersion();
@@ -84709,7 +84709,7 @@ function initialize1PEventLogging() {
84709
84709
  })
84710
84710
  ]
84711
84711
  });
84712
- firstPartyEventLogger = firstPartyEventLoggerProvider.getLogger("com.urhq.ur.events", "1.65.9");
84712
+ firstPartyEventLogger = firstPartyEventLoggerProvider.getLogger("com.urhq.ur.events", "1.65.10");
84713
84713
  }
84714
84714
  async function reinitialize1PEventLoggingIfConfigChanged() {
84715
84715
  if (!is1PEventLoggingEnabled() || !firstPartyEventLoggerProvider) {
@@ -86756,12 +86756,13 @@ function extractMcpToolDisplayName(userFacingName) {
86756
86756
  var init_mcpStringUtils = () => {};
86757
86757
 
86758
86758
  // src/tools/AgentTool/constants.ts
86759
- var AGENT_TOOL_NAME = "Agent", LEGACY_AGENT_TOOL_NAME = "Task", VERIFICATION_AGENT_TYPE = "verification", ONE_SHOT_BUILTIN_AGENT_TYPES;
86759
+ var AGENT_TOOL_NAME = "Agent", LEGACY_AGENT_TOOL_NAME = "Task", VERIFICATION_AGENT_TYPE = "verification", READ_ONLY_PLAN_AGENT_TYPES, ONE_SHOT_BUILTIN_AGENT_TYPES;
86760
86760
  var init_constants2 = __esm(() => {
86761
- ONE_SHOT_BUILTIN_AGENT_TYPES = new Set([
86761
+ READ_ONLY_PLAN_AGENT_TYPES = new Set([
86762
86762
  "Explore",
86763
86763
  "Plan"
86764
86764
  ]);
86765
+ ONE_SHOT_BUILTIN_AGENT_TYPES = READ_ONLY_PLAN_AGENT_TYPES;
86765
86766
  });
86766
86767
 
86767
86768
  // src/tools/TaskOutputTool/constants.ts
@@ -94596,7 +94597,7 @@ function formatAgentTrendReport(report = buildAgentTrendReport()) {
94596
94597
  function formatA2AAgentCard(options = {}, pretty = true) {
94597
94598
  return JSON.stringify(buildA2AAgentCard(options), null, pretty ? 2 : 0);
94598
94599
  }
94599
- var urVersion = "1.65.9", researchSnapshotDate = "2026-07-15", coverage, priorityRoadmap;
94600
+ var urVersion = "1.65.10", researchSnapshotDate = "2026-07-15", coverage, priorityRoadmap;
94600
94601
  var init_trends = __esm(() => {
94601
94602
  init_a2aCardSignature();
94602
94603
  coverage = [
@@ -97399,7 +97400,7 @@ function getAttributionHeader(fingerprint) {
97399
97400
  if (!isAttributionHeaderEnabled()) {
97400
97401
  return "";
97401
97402
  }
97402
- const version2 = `${"1.65.9"}.${fingerprint}`;
97403
+ const version2 = `${"1.65.10"}.${fingerprint}`;
97403
97404
  const entrypoint = process.env.UR_CODE_ENTRYPOINT ?? "unknown";
97404
97405
  const cch = "";
97405
97406
  const workload = getWorkload();
@@ -144901,6 +144902,8 @@ function getExploreSystemPrompt() {
144901
144902
  const embedded = hasEmbeddedSearchTools();
144902
144903
  const globGuidance = embedded ? `- Use \`find\` via ${BASH_TOOL_NAME} for broad file pattern matching` : `- Use ${GLOB_TOOL_NAME} for broad file pattern matching`;
144903
144904
  const grepGuidance = embedded ? `- Use \`grep\` via ${BASH_TOOL_NAME} for searching file contents with regex` : `- Use ${GREP_TOOL_NAME} for searching file contents with regex`;
144905
+ const shellGuidance = embedded ? `- Use ${BASH_TOOL_NAME} ONLY for read-only operations (ls, git status, git log, git diff, find, grep, cat, head, tail)
144906
+ - NEVER use ${BASH_TOOL_NAME} for: mkdir, touch, rm, cp, mv, git add, git commit, package installation, redirects, or any file creation/modification` : "";
144904
144907
  return `You are a file search specialist for Ur. You excel at thoroughly navigating and exploring codebases.
144905
144908
 
144906
144909
  === CRITICAL: READ-ONLY MODE - NO FILE MODIFICATIONS ===
@@ -144924,8 +144927,7 @@ Guidelines:
144924
144927
  ${globGuidance}
144925
144928
  ${grepGuidance}
144926
144929
  - Use ${FILE_READ_TOOL_NAME} when you know the specific file path you need to read
144927
- - Use ${BASH_TOOL_NAME} ONLY for read-only operations (ls, git status, git log, git diff, find${embedded ? ", grep" : ""}, cat, head, tail)
144928
- - NEVER use ${BASH_TOOL_NAME} for: mkdir, touch, rm, cp, mv, git add, git commit, npm install, pip install, or any file creation/modification
144930
+ ${shellGuidance}
144929
144931
  - Adapt your search approach based on the thoroughness level specified by the caller
144930
144932
  - Communicate your final report directly as a regular message - do NOT attempt to create files
144931
144933
 
@@ -144945,6 +144947,7 @@ var init_exploreAgent = __esm(() => {
144945
144947
  EXPLORE_AGENT = {
144946
144948
  agentType: "Explore",
144947
144949
  whenToUse: EXPLORE_WHEN_TO_USE,
144950
+ tools: hasEmbeddedSearchTools() ? [BASH_TOOL_NAME, FILE_READ_TOOL_NAME] : [GLOB_TOOL_NAME, GREP_TOOL_NAME, FILE_READ_TOOL_NAME],
144948
144951
  disallowedTools: [
144949
144952
  AGENT_TOOL_NAME,
144950
144953
  EXIT_PLAN_MODE_TOOL_NAME,
@@ -144955,6 +144958,7 @@ var init_exploreAgent = __esm(() => {
144955
144958
  source: "built-in",
144956
144959
  baseDir: "built-in",
144957
144960
  model: process.env.USER_TYPE === "ant" ? "inherit" : "modelH",
144961
+ permissionMode: "dontAsk",
144958
144962
  omitAgentMd: true,
144959
144963
  getSystemPrompt: () => getExploreSystemPrompt()
144960
144964
  };
@@ -144994,9 +144998,58 @@ var init_generalPurposeAgent = __esm(() => {
144994
144998
  };
144995
144999
  });
144996
145000
 
145001
+ // src/tools/TaskCreateTool/constants.ts
145002
+ var TASK_CREATE_TOOL_NAME = "TaskCreate";
145003
+
145004
+ // src/tools/TaskUpdateTool/constants.ts
145005
+ var TASK_UPDATE_TOOL_NAME = "TaskUpdate";
145006
+
145007
+ // src/tools/TodoWriteTool/constants.ts
145008
+ var TODO_WRITE_TOOL_NAME = "TodoWrite";
145009
+
145010
+ // src/constants/planImplementationContract.ts
145011
+ function getApprovedPlanCapabilities(toolUseContext) {
145012
+ const tools = toolUseContext.options.tools;
145013
+ const hasTaskV2 = tools.some((tool) => toolMatchesName(tool, TASK_CREATE_TOOL_NAME)) && tools.some((tool) => toolMatchesName(tool, TASK_UPDATE_TOOL_NAME));
145014
+ const hasTodoWrite = tools.some((tool) => toolMatchesName(tool, TODO_WRITE_TOOL_NAME));
145015
+ const hasAgent = tools.some((tool) => toolMatchesName(tool, AGENT_TOOL_NAME));
145016
+ const activeAgents = toolUseContext.options.agentDefinitions?.activeAgents ?? [];
145017
+ const implementationAgentType = hasAgent ? ["worker", "general-purpose"].find((agentType) => activeAgents.some((agent) => agent.agentType === agentType && agent.source === "built-in")) : undefined;
145018
+ return {
145019
+ taskTool: hasTaskV2 ? "task-v2" : hasTodoWrite ? "todo-write" : "none",
145020
+ ...implementationAgentType ? { implementationAgentType } : {}
145021
+ };
145022
+ }
145023
+ function getApprovedPlanImplementationInstruction(capabilities) {
145024
+ const taskTracking = capabilities.taskTool === "task-v2" ? [
145025
+ `Use one ${TASK_CREATE_TOOL_NAME} call per cohesive, independently verifiable outcome; one umbrella task does not satisfy this requirement. Keep genuinely atomic work whole instead of manufacturing file- or tool-call-level tasks.`,
145026
+ `Emit independent ${TASK_CREATE_TOOL_NAME} calls together (up to 8 per turn), then use ${TASK_UPDATE_TOOL_NAME} to add dependencies once task IDs are known. Leave unrelated tasks unblocked.`
145027
+ ] : capabilities.taskTool === "todo-write" ? [
145028
+ `Use ${TODO_WRITE_TOOL_NAME} to record the complete list with one item per cohesive, independently verifiable outcome; one umbrella item does not satisfy this requirement. Keep genuinely atomic work whole instead of manufacturing file- or tool-call-level items.`,
145029
+ "Order dependent items after their prerequisites, keep every real outcome visible, and update each status from pending to in_progress to completed only as evidence is obtained."
145030
+ ] : [
145031
+ "Use the plan\u2019s numbered Implementation Tasks as the execution checklist, with one cohesive, independently verifiable outcome per item. Keep genuinely atomic work whole; do not invent unavailable task tools."
145032
+ ];
145033
+ const delegation = capabilities.implementationAgentType ? `After the graph is complete, launch up to 8 ready tasks with no conflicting shared mutation per parallel wave through ${AGENT_TOOL_NAME} using subagent_type=${capabilities.implementationAgentType}; continue with later waves as slots free. Give each worker its ${capabilities.taskTool === "task-v2" ? "task ID" : "numbered outcome"}, bounded scope, dependency outputs, completion check, and required verification. Keep dependent tasks and conflicting shared writes sequential; independently verify worker results before completing their tasks.` : "After the graph is complete, execute ready tasks in dependency order and independently verify each result before completing its task.";
145034
+ return [
145035
+ "Before changing the workspace, translate the approved plan into a complete task graph.",
145036
+ ...taskTracking,
145037
+ delegation
145038
+ ].join(`
145039
+ `);
145040
+ }
145041
+ var PLAN_TASK_GRAPH_REQUIREMENT = "Add an **Implementation Tasks** section with one numbered task per cohesive, independently verifiable outcome. Do not collapse separate deliverables into one umbrella task or split atomic work into file/tool-call micro-tasks. For each task, state its completion check, real dependencies, and whether it can run in a parallel worker wave.";
145042
+ var init_planImplementationContract = __esm(() => {
145043
+ init_Tool();
145044
+ init_constants2();
145045
+ });
145046
+
144997
145047
  // src/tools/AgentTool/built-in/planAgent.ts
144998
145048
  function getPlanV2SystemPrompt() {
144999
- const searchToolsHint = hasEmbeddedSearchTools() ? `\`find\`, \`grep\`, and ${FILE_READ_TOOL_NAME}` : `${GLOB_TOOL_NAME}, ${GREP_TOOL_NAME}, and ${FILE_READ_TOOL_NAME}`;
145049
+ const embedded = hasEmbeddedSearchTools();
145050
+ const searchToolsHint = embedded ? `\`find\`, \`grep\`, and ${FILE_READ_TOOL_NAME}` : `${GLOB_TOOL_NAME}, ${GREP_TOOL_NAME}, and ${FILE_READ_TOOL_NAME}`;
145051
+ const shellGuidance = embedded ? ` - Use ${BASH_TOOL_NAME} ONLY for read-only operations (ls, git status, git log, git diff, find, grep, cat, head, tail)
145052
+ - NEVER use ${BASH_TOOL_NAME} for: mkdir, touch, rm, cp, mv, git add, git commit, package installation, redirects, or any file creation/modification` : "";
145000
145053
  return `You are a software architect and planning specialist for Ur. Your role is to explore the codebase and design implementation plans.
145001
145054
 
145002
145055
  === CRITICAL: READ-ONLY MODE - NO FILE MODIFICATIONS ===
@@ -145023,8 +145076,7 @@ You will be provided with a set of requirements and optionally a perspective on
145023
145076
  - Understand the current architecture
145024
145077
  - Identify similar features as reference
145025
145078
  - Trace through relevant code paths
145026
- - Use ${BASH_TOOL_NAME} ONLY for read-only operations (ls, git status, git log, git diff, find${hasEmbeddedSearchTools() ? ", grep" : ""}, cat, head, tail)
145027
- - NEVER use ${BASH_TOOL_NAME} for: mkdir, touch, rm, cp, mv, git add, git commit, npm install, pip install, or any file creation/modification
145079
+ ${shellGuidance}
145028
145080
 
145029
145081
  3. **Design Solution**:
145030
145082
  - Create implementation approach based on your assigned perspective
@@ -145038,6 +145090,9 @@ You will be provided with a set of requirements and optionally a perspective on
145038
145090
 
145039
145091
  ## Required Output
145040
145092
 
145093
+ Include an **Implementation Tasks** section before the critical-files list.
145094
+ ${PLAN_TASK_GRAPH_REQUIREMENT}
145095
+
145041
145096
  End your response with:
145042
145097
 
145043
145098
  ### Critical Files for Implementation
@@ -145050,6 +145105,7 @@ REMEMBER: You can ONLY explore and plan. You CANNOT and MUST NOT write, edit, or
145050
145105
  }
145051
145106
  var PLAN_AGENT;
145052
145107
  var init_planAgent = __esm(() => {
145108
+ init_planImplementationContract();
145053
145109
  init_prompt2();
145054
145110
  init_prompt3();
145055
145111
  init_prompt();
@@ -145068,6 +145124,7 @@ var init_planAgent = __esm(() => {
145068
145124
  ],
145069
145125
  source: "built-in",
145070
145126
  tools: EXPLORE_AGENT.tools,
145127
+ permissionMode: "dontAsk",
145071
145128
  baseDir: "built-in",
145072
145129
  model: "inherit",
145073
145130
  omitAgentMd: true,
@@ -145368,7 +145425,7 @@ Use the literal string \`VERDICT: \` followed by exactly one of \`PASS\`, \`FAIL
145368
145425
  // src/tools/AgentTool/builtInAgents.ts
145369
145426
  function areExplorePlanAgentsEnabled() {
145370
145427
  if (false) {}
145371
- return false;
145428
+ return !(isEnvTruthy(process.env.UR_AGENT_SDK_DISABLE_BUILTIN_AGENTS) && getIsNonInteractiveSession());
145372
145429
  }
145373
145430
  function getBuiltInAgents() {
145374
145431
  if (isEnvTruthy(process.env.UR_AGENT_SDK_DISABLE_BUILTIN_AGENTS) && getIsNonInteractiveSession()) {
@@ -145394,7 +145451,6 @@ function getBuiltInAgents() {
145394
145451
  }
145395
145452
  var init_builtInAgents = __esm(() => {
145396
145453
  init_state();
145397
- init_growthbook();
145398
145454
  init_envUtils();
145399
145455
  init_urCodeGuideAgent();
145400
145456
  init_exploreAgent();
@@ -155213,7 +155269,7 @@ var init_projectSafety = __esm(() => {
155213
155269
  function getInstruments() {
155214
155270
  if (instruments)
155215
155271
  return instruments;
155216
- const meter = import_api10.metrics.getMeter("ur-agent.gen_ai", "1.65.9");
155272
+ const meter = import_api10.metrics.getMeter("ur-agent.gen_ai", "1.65.10");
155217
155273
  instruments = {
155218
155274
  operationDuration: meter.createHistogram("gen_ai.client.operation.duration", {
155219
155275
  description: "GenAI operation duration.",
@@ -155311,7 +155367,7 @@ function genAiAgentAttributes() {
155311
155367
  "gen_ai.operation.name": GEN_AI_OPERATION_INVOKE_AGENT,
155312
155368
  "gen_ai.provider.name": "ur",
155313
155369
  "gen_ai.agent.name": "UR-Nexus",
155314
- "gen_ai.agent.version": "1.65.9"
155370
+ "gen_ai.agent.version": "1.65.10"
155315
155371
  };
155316
155372
  }
155317
155373
  function genAiWorkflowAttributes(workflowName) {
@@ -155327,7 +155383,7 @@ function genAiWorkflowAttributes(workflowName) {
155327
155383
  function startGenAiWorkflowSpan(workflowName) {
155328
155384
  const attributes = genAiWorkflowAttributes(workflowName);
155329
155385
  const name = typeof attributes["gen_ai.workflow.name"] === "string" ? `invoke_workflow ${attributes["gen_ai.workflow.name"]}` : GEN_AI_OPERATION_INVOKE_WORKFLOW;
155330
- return import_api10.trace.getTracer("ur-agent.gen_ai", "1.65.9").startSpan(name, { kind: import_api10.SpanKind.INTERNAL, attributes });
155386
+ return import_api10.trace.getTracer("ur-agent.gen_ai", "1.65.10").startSpan(name, { kind: import_api10.SpanKind.INTERNAL, attributes });
155331
155387
  }
155332
155388
  function endGenAiWorkflowSpan(span, options2 = {}) {
155333
155389
  try {
@@ -155365,7 +155421,7 @@ function startGenAiMemorySpan(operation, options2 = {}) {
155365
155421
  if (options2.recordCount !== undefined && Number.isInteger(options2.recordCount) && options2.recordCount >= 0) {
155366
155422
  attributes["gen_ai.memory.record.count"] = options2.recordCount;
155367
155423
  }
155368
- return import_api10.trace.getTracer("ur-agent.gen_ai", "1.65.9").startSpan(operation, { kind: import_api10.SpanKind.INTERNAL, attributes });
155424
+ return import_api10.trace.getTracer("ur-agent.gen_ai", "1.65.10").startSpan(operation, { kind: import_api10.SpanKind.INTERNAL, attributes });
155369
155425
  }
155370
155426
  function endGenAiMemorySpan(span, options2 = {}) {
155371
155427
  try {
@@ -248848,7 +248904,7 @@ function getTelemetryAttributes() {
248848
248904
  attributes["session.id"] = sessionId;
248849
248905
  }
248850
248906
  if (shouldIncludeAttribute("OTEL_METRICS_INCLUDE_VERSION")) {
248851
- attributes["app.version"] = "1.65.9";
248907
+ attributes["app.version"] = "1.65.10";
248852
248908
  }
248853
248909
  const oauthAccount = getOauthAccountInfo();
248854
248910
  if (oauthAccount) {
@@ -265101,24 +265157,15 @@ Plan mode note: In plan mode, use this tool to clarify requirements or choose be
265101
265157
  `;
265102
265158
  });
265103
265159
 
265104
- // src/tools/TodoWriteTool/constants.ts
265105
- var TODO_WRITE_TOOL_NAME = "TodoWrite";
265106
-
265107
265160
  // src/tools/SkillTool/constants.ts
265108
265161
  var SKILL_TOOL_NAME = "Skill";
265109
265162
 
265110
- // src/tools/TaskCreateTool/constants.ts
265111
- var TASK_CREATE_TOOL_NAME = "TaskCreate";
265112
-
265113
265163
  // src/tools/TaskGetTool/constants.ts
265114
265164
  var TASK_GET_TOOL_NAME = "TaskGet";
265115
265165
 
265116
265166
  // src/tools/TaskListTool/constants.ts
265117
265167
  var TASK_LIST_TOOL_NAME = "TaskList";
265118
265168
 
265119
- // src/tools/TaskUpdateTool/constants.ts
265120
- var TASK_UPDATE_TOOL_NAME = "TaskUpdate";
265121
-
265122
265169
  // src/tools/EnterWorktreeTool/constants.ts
265123
265170
  var ENTER_WORKTREE_TOOL_NAME = "EnterWorktree";
265124
265171
 
@@ -295391,7 +295438,7 @@ function getInstallationEnv() {
295391
295438
  return;
295392
295439
  }
295393
295440
  function getURCodeVersion() {
295394
- return "1.65.9";
295441
+ return "1.65.10";
295395
295442
  }
295396
295443
  async function getInstalledVSCodeExtensionVersion(command) {
295397
295444
  const { stdout } = await execFileNoThrow(command, ["--list-extensions", "--show-versions"], {
@@ -302722,7 +302769,7 @@ async function setupSdkMcpClients(sdkMcpConfigs, sendMcpMessage) {
302722
302769
  const client2 = new Client({
302723
302770
  name: "ur",
302724
302771
  title: "UR",
302725
- version: "1.65.9",
302772
+ version: "1.65.10",
302726
302773
  description: "UR-Nexus autonomous engineering workflow engine",
302727
302774
  websiteUrl: PRODUCT_URL
302728
302775
  }, {
@@ -303082,7 +303129,7 @@ var init_client5 = __esm(() => {
303082
303129
  const client2 = new Client({
303083
303130
  name: "ur",
303084
303131
  title: "UR",
303085
- version: "1.65.9",
303132
+ version: "1.65.10",
303086
303133
  description: "UR-Nexus autonomous engineering workflow engine",
303087
303134
  websiteUrl: PRODUCT_URL
303088
303135
  }, {
@@ -315621,7 +315668,7 @@ async function createRuntime() {
315621
315668
  bootstrapTelemetry();
315622
315669
  const resource = defaultResource().merge(detectResources({ detectors: [envDetector] })).merge(resourceFromAttributes({
315623
315670
  [import_semantic_conventions7.ATTR_SERVICE_NAME]: "ur-agent",
315624
- [import_semantic_conventions7.ATTR_SERVICE_VERSION]: "1.65.9"
315671
+ [import_semantic_conventions7.ATTR_SERVICE_VERSION]: "1.65.10"
315625
315672
  }));
315626
315673
  const tracerProvider = exporters.traces.length > 0 ? new BasicTracerProvider({
315627
315674
  resource,
@@ -315654,11 +315701,11 @@ async function createRuntime() {
315654
315701
  setMeterProvider(meterProvider);
315655
315702
  setLoggerProvider(loggerProvider);
315656
315703
  if (meterProvider) {
315657
- const meter = meterProvider.getMeter("ur-agent", "1.65.9");
315704
+ const meter = meterProvider.getMeter("ur-agent", "1.65.10");
315658
315705
  setMeter(meter, (name, options2) => meter.createCounter(name, options2));
315659
315706
  }
315660
315707
  if (loggerProvider) {
315661
- setEventLogger(loggerProvider.getLogger("ur-agent.events", "1.65.9"));
315708
+ setEventLogger(loggerProvider.getLogger("ur-agent.events", "1.65.10"));
315662
315709
  }
315663
315710
  if (!cleanupRegistered2) {
315664
315711
  cleanupRegistered2 = true;
@@ -316320,9 +316367,9 @@ async function assertMinVersion() {
316320
316367
  if (false) {}
316321
316368
  try {
316322
316369
  const versionConfig = await getDynamicConfig_BLOCKS_ON_INIT("tengu_version_config", { minVersion: "0.0.0" });
316323
- if (versionConfig.minVersion && lt("1.65.9", versionConfig.minVersion)) {
316370
+ if (versionConfig.minVersion && lt("1.65.10", versionConfig.minVersion)) {
316324
316371
  console.error(`
316325
- It looks like your version of UR (${"1.65.9"}) needs an update.
316372
+ It looks like your version of UR (${"1.65.10"}) needs an update.
316326
316373
  A newer version (${versionConfig.minVersion} or higher) is required to continue.
316327
316374
 
316328
316375
  To update, please run:
@@ -316538,7 +316585,7 @@ async function installGlobalPackage(specificVersion) {
316538
316585
  logError2(new AutoUpdaterError("Another process is currently installing an update"));
316539
316586
  logEvent("tengu_auto_updater_lock_contention", {
316540
316587
  pid: process.pid,
316541
- currentVersion: "1.65.9"
316588
+ currentVersion: "1.65.10"
316542
316589
  });
316543
316590
  return "in_progress";
316544
316591
  }
@@ -316547,7 +316594,7 @@ async function installGlobalPackage(specificVersion) {
316547
316594
  if (!env2.isRunningWithBun() && env2.isNpmFromWindowsPath()) {
316548
316595
  logError2(new Error("Windows NPM detected in WSL environment"));
316549
316596
  logEvent("tengu_auto_updater_windows_npm_in_wsl", {
316550
- currentVersion: "1.65.9"
316597
+ currentVersion: "1.65.10"
316551
316598
  });
316552
316599
  console.error(`
316553
316600
  Error: Windows NPM detected in WSL
@@ -317082,7 +317129,7 @@ function detectLinuxGlobPatternWarnings() {
317082
317129
  }
317083
317130
  async function getDoctorDiagnostic() {
317084
317131
  const installationType = await getCurrentInstallationType();
317085
- const version2 = typeof MACRO !== "undefined" ? "1.65.9" : "unknown";
317132
+ const version2 = typeof MACRO !== "undefined" ? "1.65.10" : "unknown";
317086
317133
  const installationPath = await getInstallationPath();
317087
317134
  const invokedBinary = getInvokedBinary();
317088
317135
  const multipleInstallations = await detectMultipleInstallations();
@@ -318017,8 +318064,8 @@ async function updateLatest(channelOrVersion, forceReinstall = false) {
318017
318064
  const maxVersion = await getMaxVersion();
318018
318065
  if (maxVersion && gt(version2, maxVersion)) {
318019
318066
  logForDebugging(`Native installer: maxVersion ${maxVersion} is set, capping update from ${version2} to ${maxVersion}`);
318020
- if (gte("1.65.9", maxVersion)) {
318021
- logForDebugging(`Native installer: current version ${"1.65.9"} is already at or above maxVersion ${maxVersion}, skipping update`);
318067
+ if (gte("1.65.10", maxVersion)) {
318068
+ logForDebugging(`Native installer: current version ${"1.65.10"} is already at or above maxVersion ${maxVersion}, skipping update`);
318022
318069
  logEvent("tengu_native_update_skipped_max_version", {
318023
318070
  latency_ms: Date.now() - startTime,
318024
318071
  max_version: maxVersion,
@@ -318029,7 +318076,7 @@ async function updateLatest(channelOrVersion, forceReinstall = false) {
318029
318076
  version2 = maxVersion;
318030
318077
  }
318031
318078
  }
318032
- if (!forceReinstall && version2 === "1.65.9" && await versionIsAvailable(version2) && await isPossibleURBinary(executablePath)) {
318079
+ if (!forceReinstall && version2 === "1.65.10" && await versionIsAvailable(version2) && await isPossibleURBinary(executablePath)) {
318033
318080
  logForDebugging(`Found ${version2} at ${executablePath}, skipping install`);
318034
318081
  logEvent("tengu_native_update_complete", {
318035
318082
  latency_ms: Date.now() - startTime,
@@ -339523,19 +339570,23 @@ that can be completed clearly in fewer than three small steps.
339523
339570
 
339524
339571
  ## Lifecycle
339525
339572
 
339526
- 1. Put todos in dependency order. Each item must be specific, actionable, and
339527
- independently checkable.
339528
- 2. Provide both forms for every item:
339573
+ 1. Decompose non-trivial work into one item per cohesive outcome with its own
339574
+ observable done check. Split separately completable deliverables out of
339575
+ omnibus items, but keep genuinely atomic work as one item; never create
339576
+ items merely for individual files, tool calls, or tiny mechanical steps.
339577
+ 2. Put todos in dependency order. Keep unrelated outcomes independent rather
339578
+ than inventing dependencies.
339579
+ 3. Provide both forms for every item:
339529
339580
  - \`content\`: imperative outcome, such as "Run tests".
339530
339581
  - \`activeForm\`: present-continuous status, such as "Running tests".
339531
- 3. Mark the next unblocked item \`in_progress\` when work starts. Keep only one
339582
+ 4. Mark the next unblocked item \`in_progress\` when work starts. Keep only one
339532
339583
  item \`in_progress\` in this agent's list.
339533
- 4. Update the list immediately when requirements or discovered work change.
339534
- 5. Mark an item \`completed\` only after its implementation and relevant
339584
+ 5. Update the list immediately when requirements or discovered work change.
339585
+ 6. Mark an item \`completed\` only after its implementation and relevant
339535
339586
  verification have succeeded. Do not batch completion updates.
339536
- 6. If work is partial, blocked, or failing, leave the item open and record the
339587
+ 7. If work is partial, blocked, or failing, leave the item open and record the
339537
339588
  concrete follow-up or blocker in the list.
339538
- 7. Remove an item only when it is genuinely obsolete or was created by mistake.
339589
+ 8. Remove an item only when it is genuinely obsolete or was created by mistake.
339539
339590
 
339540
339591
  Never mark an item completed when tests still fail, an error is unresolved, a
339541
339592
  required dependency is missing, or only part of the outcome was implemented.
@@ -361089,14 +361140,15 @@ function getEditToolDescription() {
361089
361140
  }
361090
361141
  function getDefaultEditDescription() {
361091
361142
  const prefixFormat = isCompactLinePrefixEnabled() ? "line number + tab" : "spaces + line number + arrow";
361092
- const minimalUniquenessHint = process.env.USER_TYPE === "ant" ? `
361093
- - Use the smallest old_string that's clearly unique \u2014 usually 2-4 adjacent lines is sufficient. Avoid including 10+ lines of context when less uniquely identifies the target.` : "";
361143
+ const minimalUniquenessHint = `
361144
+ - Use the smallest old_string that's clearly unique \u2014 usually 2-4 adjacent lines is sufficient. Avoid including 10+ lines of context when less uniquely identifies the target. Split changes across distant HTML/CSS/JavaScript sections into separate edits instead of replacing one large cross-section block.`;
361094
361145
  return `Performs exact string replacements in files.
361095
361146
 
361096
361147
  Usage:${getPreReadInstruction2()}
361097
361148
  - When editing text from Read tool output, ensure you preserve the exact indentation (tabs/spaces) as it appears AFTER the line number prefix. The line number prefix format is: ${prefixFormat}. Everything after that is the actual file content to match. Never include any part of the line number prefix in the old_string or new_string.
361098
361149
  - ALWAYS prefer editing existing files in the codebase. NEVER write new files unless explicitly required.
361099
361150
  - Only use emojis if the user explicitly requests it. Avoid adding emojis to files unless asked.
361151
+ - \`old_string\` must be copied from the current file as one exact, contiguous block. If it is not found, re-read the target region and retry with a corrected smaller block; never retry the unchanged call.
361100
361152
  - The edit will FAIL if \`old_string\` is not unique in the file. Either provide a larger string with more surrounding context to make it unique or use \`replace_all\` to change every instance of \`old_string\`.${minimalUniquenessHint}
361101
361153
  - Use \`replace_all\` for replacing and renaming strings across the file. This parameter is useful if you want to rename a variable for instance.`;
361102
361154
  }
@@ -363476,6 +363528,58 @@ function findActualStringWhitespaceTolerant(fileContent, searchString) {
363476
363528
  }
363477
363529
  return null;
363478
363530
  }
363531
+ function findSearchAnchor(fileContent, searchString) {
363532
+ const fileLines = fileContent.split(`
363533
+ `);
363534
+ const occurrencesByLine = new Map;
363535
+ for (let index2 = 0;index2 < fileLines.length; index2++) {
363536
+ const normalized = normalizeLineForMatch(fileLines[index2]);
363537
+ if (normalized.trim().length === 0)
363538
+ continue;
363539
+ const occurrence = occurrencesByLine.get(normalized);
363540
+ if (occurrence) {
363541
+ occurrence.count++;
363542
+ } else {
363543
+ occurrencesByLine.set(normalized, { firstIndex: index2, count: 1 });
363544
+ }
363545
+ }
363546
+ let repeatedMatch = null;
363547
+ for (const searchLine of searchString.split(`
363548
+ `)) {
363549
+ const normalized = normalizeLineForMatch(searchLine);
363550
+ if (normalized.trim().length === 0)
363551
+ continue;
363552
+ const occurrence = occurrencesByLine.get(normalized);
363553
+ if (!occurrence)
363554
+ continue;
363555
+ if (occurrence.count === 1) {
363556
+ return { fileLine: occurrence.firstIndex + 1, unique: true };
363557
+ }
363558
+ repeatedMatch ??= {
363559
+ fileLine: occurrence.firstIndex + 1,
363560
+ unique: false
363561
+ };
363562
+ }
363563
+ return repeatedMatch;
363564
+ }
363565
+ function formatStringNotFoundMessage(fileContent, searchString) {
363566
+ const lineCount = searchString.split(`
363567
+ `).length;
363568
+ const anchor = findSearchAnchor(fileContent, searchString);
363569
+ const location = anchor ? `A line from old_string ${anchor.unique ? "uniquely " : ""}matches the current file at line ${anchor.fileLine}, but the complete ${lineCount}-line block is not contiguous there.` : "No complete non-empty line from old_string matches the current file.";
363570
+ const recovery = anchor ? `Re-read the target around line ${anchor.fileLine}, then retry with the smallest unique contiguous old_string copied from the current Read output (usually 2-4 lines).` : "Search for a short distinctive fragment, re-read the current target region, then retry with the smallest unique contiguous old_string (usually 2-4 lines).";
363571
+ const preview = searchString.length > STRING_NOT_FOUND_PREVIEW_CHARS ? `${searchString.slice(0, STRING_NOT_FOUND_PREVIEW_CHARS)}
363572
+ \u2026 [old_string preview truncated; ${searchString.length} characters total]` : searchString;
363573
+ return [
363574
+ "String to replace not found in file.",
363575
+ location,
363576
+ recovery,
363577
+ "Do not include Read line-number prefixes. Split large cross-section replacements into smaller edits, and do not retry this call unchanged.",
363578
+ `old_string preview:
363579
+ ${preview}`
363580
+ ].join(`
363581
+ `);
363582
+ }
363479
363583
  function findActualString(fileContent, searchString) {
363480
363584
  if (fileContent.includes(searchString)) {
363481
363585
  return searchString;
@@ -363787,7 +363891,7 @@ function areFileEditsInputsEquivalent(input1, input2) {
363787
363891
  }
363788
363892
  return areFileEditsEquivalent(input1.edits, input2.edits, fileContent);
363789
363893
  }
363790
- var LEFT_SINGLE_CURLY_QUOTE = "\u2018", RIGHT_SINGLE_CURLY_QUOTE = "\u2019", LEFT_DOUBLE_CURLY_QUOTE = "\u201C", RIGHT_DOUBLE_CURLY_QUOTE = "\u201D", DIFF_SNIPPET_MAX_BYTES = 8192, DESANITIZATIONS;
363894
+ var LEFT_SINGLE_CURLY_QUOTE = "\u2018", RIGHT_SINGLE_CURLY_QUOTE = "\u2019", LEFT_DOUBLE_CURLY_QUOTE = "\u201C", RIGHT_DOUBLE_CURLY_QUOTE = "\u201D", STRING_NOT_FOUND_PREVIEW_CHARS = 600, DIFF_SNIPPET_MAX_BYTES = 8192, DESANITIZATIONS;
363791
363895
  var init_utils10 = __esm(() => {
363792
363896
  init_libesm();
363793
363897
  init_log2();
@@ -364346,8 +364450,7 @@ var init_FileEditTool = __esm(() => {
364346
364450
  return {
364347
364451
  result: false,
364348
364452
  behavior: "ask",
364349
- message: `String to replace not found in file.
364350
- String: ${old_string}`,
364453
+ message: formatStringNotFoundMessage(file2, old_string),
364351
364454
  meta: {
364352
364455
  isFilePathAbsolute: String(isAbsolute24(file_path))
364353
364456
  },
@@ -371511,9 +371614,9 @@ var permissionSetupModule = null, allowedPromptSchema, allowedPromptsSchema, inp
371511
371614
  var init_ExitPlanModeV2Tool = __esm(() => {
371512
371615
  init_v4();
371513
371616
  init_state();
371617
+ init_planImplementationContract();
371514
371618
  init_analytics();
371515
371619
  init_Tool();
371516
- init_agentSwarmsEnabled();
371517
371620
  init_debug();
371518
371621
  init_inProcessTeammateHelpers();
371519
371622
  init_log2();
@@ -371521,7 +371624,6 @@ var init_ExitPlanModeV2Tool = __esm(() => {
371521
371624
  init_slowOperations();
371522
371625
  init_teammate();
371523
371626
  init_teammateMailbox();
371524
- init_constants2();
371525
371627
  init_prompt14();
371526
371628
  init_UI18();
371527
371629
  allowedPromptSchema = lazySchema(() => exports_external.object({
@@ -371541,7 +371643,8 @@ var init_ExitPlanModeV2Tool = __esm(() => {
371541
371643
  plan: exports_external.string().nullable().describe("The plan that was presented to the user"),
371542
371644
  isAgent: exports_external.boolean(),
371543
371645
  filePath: exports_external.string().optional().describe("The file path where the plan was saved"),
371544
- hasTaskTool: exports_external.boolean().optional().describe("Whether the Agent tool is available in the current context"),
371646
+ implementationTaskTool: exports_external.enum(["task-v2", "todo-write", "none"]).optional().describe("Task tracking surface available after approval"),
371647
+ implementationAgentType: exports_external.string().optional().describe("Executable built-in implementation worker type, when present"),
371545
371648
  planWasEdited: exports_external.boolean().optional().describe("True when the user edited the plan (CCR web UI or Ctrl+G); determines whether the plan is echoed back in tool_result"),
371546
371649
  awaitingLeaderApproval: exports_external.boolean().optional().describe("When true, the teammate has sent a plan approval request to the team leader"),
371547
371650
  requestId: exports_external.string().optional().describe("Unique identifier for the plan approval request")
@@ -371696,13 +371799,14 @@ var init_ExitPlanModeV2Tool = __esm(() => {
371696
371799
  }
371697
371800
  };
371698
371801
  });
371699
- const hasTaskTool = isAgentSwarmsEnabled() && context5.options.tools.some((t) => toolMatchesName(t, AGENT_TOOL_NAME));
371802
+ const implementationCapabilities = getApprovedPlanCapabilities(context5);
371700
371803
  return {
371701
371804
  data: {
371702
371805
  plan,
371703
371806
  isAgent,
371704
371807
  filePath,
371705
- hasTaskTool: hasTaskTool || undefined,
371808
+ implementationTaskTool: implementationCapabilities.taskTool,
371809
+ implementationAgentType: implementationCapabilities.implementationAgentType,
371706
371810
  planWasEdited: inputPlan !== undefined || undefined
371707
371811
  }
371708
371812
  };
@@ -371711,7 +371815,8 @@ var init_ExitPlanModeV2Tool = __esm(() => {
371711
371815
  isAgent,
371712
371816
  plan,
371713
371817
  filePath,
371714
- hasTaskTool,
371818
+ implementationTaskTool,
371819
+ implementationAgentType,
371715
371820
  planWasEdited,
371716
371821
  awaitingLeaderApproval,
371717
371822
  requestId
@@ -371749,16 +371854,19 @@ Request ID: ${requestId}`,
371749
371854
  tool_use_id: toolUseID
371750
371855
  };
371751
371856
  }
371752
- const teamHint = hasTaskTool ? `
371753
-
371754
- If this plan can be broken down into multiple independent tasks, consider using the ${TEAM_CREATE_TOOL_NAME} tool to create a team and parallelize the work.` : "";
371857
+ const implementationInstruction = getApprovedPlanImplementationInstruction({
371858
+ taskTool: implementationTaskTool ?? "none",
371859
+ ...implementationAgentType ? { implementationAgentType } : {}
371860
+ });
371755
371861
  const planLabel = planWasEdited ? "Approved Plan (edited by user)" : "Approved Plan";
371756
371862
  return {
371757
371863
  type: "tool_result",
371758
- content: `User has approved your plan. You can now start coding. Start with updating your todo list if applicable
371864
+ content: `User has approved your plan. You can now start implementation.
371759
371865
 
371760
371866
  Your plan has been saved to: ${filePath}
371761
- You can refer back to it if needed during implementation.${teamHint}
371867
+ You can refer back to it if needed during implementation.
371868
+
371869
+ ${implementationInstruction}
371762
371870
 
371763
371871
  ## ${planLabel}:
371764
371872
  ${plan}`,
@@ -377510,6 +377618,23 @@ var init_ConfigTool = __esm(() => {
377510
377618
  });
377511
377619
  });
377512
377620
 
377621
+ // src/tools/taskIdInput.ts
377622
+ function taskIdInputSchema(description) {
377623
+ return exports_external.union([
377624
+ exports_external.string().min(1),
377625
+ exports_external.number().int().positive().max(Number.MAX_SAFE_INTEGER)
377626
+ ]).describe(description);
377627
+ }
377628
+ function normalizeTaskIdInput(taskId) {
377629
+ return String(taskId);
377630
+ }
377631
+ function normalizeTaskIdInputs(taskIds) {
377632
+ return taskIds?.map(normalizeTaskIdInput);
377633
+ }
377634
+ var init_taskIdInput = __esm(() => {
377635
+ init_v4();
377636
+ });
377637
+
377513
377638
  // src/tools/TaskCreateTool/prompt.ts
377514
377639
  function getPrompt4() {
377515
377640
  const teammateContext = isAgentSwarmsEnabled() ? " and potentially assigned to teammates" : "";
@@ -377543,6 +377668,23 @@ NOTE that you should not use this tool if there is only one trivial task to do.
377543
377668
 
377544
377669
  EXCEPTION: none of the "skip" rules apply when the user explicitly asks for an item to be added to the task list ("add to your tasks \u2026"). An explicit request always wins \u2014 create the task.
377545
377670
 
377671
+ ## Decomposition Quality
377672
+
377673
+ For non-trivial work, create the complete task graph before implementation:
377674
+
377675
+ - One task represents one cohesive outcome with an observable done check.
377676
+ Split an omnibus task when it contains separately completable deliverables.
377677
+ - Keep a genuinely atomic outcome as one task. Do not manufacture tasks for
377678
+ individual files, tool calls, or tiny mechanical steps.
377679
+ - Express real ordering constraints with \`blocks\` / \`blockedBy\`. Leave
377680
+ unrelated tasks unblocked so agents can claim them in parallel.
377681
+ - If delegation is available, launch mutually independent tasks concurrently
377682
+ only when they have no conflicting shared mutations. Keep dependent or
377683
+ conflicting work sequential.
377684
+ - Emit one \`TaskCreate\` call per outcome. Batch independent creates in the
377685
+ same assistant turn (up to 8), then use \`TaskUpdate\` to add dependency
377686
+ edges once IDs are known and before starting blocked work.
377687
+
377546
377688
  ## Task Fields
377547
377689
 
377548
377690
  - **subject**: A brief, actionable title in imperative form (e.g., "Fix authentication bug in login flow")
@@ -377574,17 +377716,21 @@ var init_TaskCreateTool = __esm(() => {
377574
377716
  init_hooks5();
377575
377717
  init_tasks();
377576
377718
  init_teammate();
377719
+ init_taskIdInput();
377577
377720
  init_prompt18();
377578
- inputSchema38 = lazySchema(() => exports_external.strictObject({
377579
- subject: exports_external.string().describe("A brief title for the task"),
377580
- description: exports_external.string().describe("What needs to be done"),
377581
- activeForm: exports_external.string().optional().describe('Present continuous form shown in spinner when in_progress (e.g., "Running tests")'),
377582
- metadata: exports_external.record(exports_external.string(), exports_external.unknown()).optional().describe("Arbitrary metadata to attach to the task"),
377583
- blocks: exports_external.array(exports_external.string()).optional().describe("Task IDs that this task blocks at creation time"),
377584
- blockedBy: exports_external.array(exports_external.string()).optional().describe("Task IDs that block this task at creation time"),
377585
- addBlocks: exports_external.array(exports_external.string()).optional().describe("Alias for blocks, accepted for compatibility with TaskUpdate"),
377586
- addBlockedBy: exports_external.array(exports_external.string()).optional().describe("Alias for blockedBy, accepted for compatibility with TaskUpdate")
377587
- }));
377721
+ inputSchema38 = lazySchema(() => {
377722
+ const TaskIdSchema = taskIdInputSchema("A task dependency ID. Positive integer JSON values are accepted and normalized to strings.");
377723
+ return exports_external.strictObject({
377724
+ subject: exports_external.string().describe("A brief title for the task"),
377725
+ description: exports_external.string().describe("What needs to be done"),
377726
+ activeForm: exports_external.string().optional().describe('Present continuous form shown in spinner when in_progress (e.g., "Running tests")'),
377727
+ metadata: exports_external.record(exports_external.string(), exports_external.unknown()).optional().describe("Arbitrary metadata to attach to the task"),
377728
+ blocks: exports_external.array(TaskIdSchema).optional().describe("Task IDs that this task blocks at creation time"),
377729
+ blockedBy: exports_external.array(TaskIdSchema).optional().describe("Task IDs that block this task at creation time"),
377730
+ addBlocks: exports_external.array(TaskIdSchema).optional().describe("Alias for blocks, accepted for compatibility with TaskUpdate"),
377731
+ addBlockedBy: exports_external.array(TaskIdSchema).optional().describe("Alias for blockedBy, accepted for compatibility with TaskUpdate")
377732
+ });
377733
+ });
377588
377734
  outputSchema33 = lazySchema(() => exports_external.object({
377589
377735
  task: exports_external.object({
377590
377736
  id: exports_external.string(),
@@ -377633,9 +377779,14 @@ var init_TaskCreateTool = __esm(() => {
377633
377779
  addBlocks,
377634
377780
  addBlockedBy
377635
377781
  }, context5) {
377636
- const initialBlocks = [...new Set([...blocks ?? [], ...addBlocks ?? []])];
377782
+ const initialBlocks = [
377783
+ ...new Set(normalizeTaskIdInputs([...blocks ?? [], ...addBlocks ?? []]) ?? [])
377784
+ ];
377637
377785
  const initialBlockedBy = [
377638
- ...new Set([...blockedBy ?? [], ...addBlockedBy ?? []])
377786
+ ...new Set(normalizeTaskIdInputs([
377787
+ ...blockedBy ?? [],
377788
+ ...addBlockedBy ?? []
377789
+ ]) ?? [])
377639
377790
  ];
377640
377791
  const taskListId = getTaskListId();
377641
377792
  const taskId = await createTask(taskListId, {
@@ -377701,7 +377852,9 @@ var init_TaskCreateTool = __esm(() => {
377701
377852
  return {
377702
377853
  tool_use_id: toolUseID,
377703
377854
  type: "tool_result",
377704
- content: `Task #${task.id} created successfully: ${task.subject}`
377855
+ content: `Task #${task.id} created successfully: ${task.subject}
377856
+
377857
+ ` + `If this is one outcome within non-trivial work, create the remaining ` + `outcome tasks before implementation. Keep one task only when the ` + `work is genuinely atomic.`
377705
377858
  };
377706
377859
  }
377707
377860
  });
@@ -377737,8 +377890,9 @@ var init_TaskGetTool = __esm(() => {
377737
377890
  init_v4();
377738
377891
  init_Tool();
377739
377892
  init_tasks();
377893
+ init_taskIdInput();
377740
377894
  inputSchema39 = lazySchema(() => exports_external.strictObject({
377741
- taskId: exports_external.string().describe("The ID of the task to retrieve")
377895
+ taskId: taskIdInputSchema("The ID of the task to retrieve. Positive integer JSON values are accepted and normalized to strings.")
377742
377896
  }));
377743
377897
  outputSchema34 = lazySchema(() => exports_external.object({
377744
377898
  task: exports_external.object({
@@ -377780,12 +377934,13 @@ var init_TaskGetTool = __esm(() => {
377780
377934
  return true;
377781
377935
  },
377782
377936
  toAutoClassifierInput(input) {
377783
- return input.taskId;
377937
+ return String(input.taskId);
377784
377938
  },
377785
377939
  renderToolUseMessage() {
377786
377940
  return null;
377787
377941
  },
377788
- async call({ taskId }) {
377942
+ async call({ taskId: rawTaskId }) {
377943
+ const taskId = normalizeTaskIdInput(rawTaskId);
377789
377944
  const taskListId = getTaskListId();
377790
377945
  const task = await getTask(taskListId, taskId);
377791
377946
  if (!task) {
@@ -377912,16 +378067,18 @@ var init_TaskUpdateTool = __esm(() => {
377912
378067
  init_teammate();
377913
378068
  init_teammateMailbox();
377914
378069
  init_constants2();
378070
+ init_taskIdInput();
377915
378071
  inputSchema40 = lazySchema(() => {
377916
378072
  const TaskUpdateStatusSchema = TaskStatusSchema2().or(exports_external.literal("deleted"));
378073
+ const TaskIdSchema = taskIdInputSchema("The ID of the task to update. Positive integer JSON values are accepted and normalized to strings.");
377917
378074
  return exports_external.strictObject({
377918
- taskId: exports_external.string().describe("The ID of the task to update"),
378075
+ taskId: TaskIdSchema,
377919
378076
  subject: exports_external.string().optional().describe("New subject for the task"),
377920
378077
  description: exports_external.string().optional().describe("New description for the task"),
377921
378078
  activeForm: exports_external.string().optional().describe('Present continuous form shown in spinner when in_progress (e.g., "Running tests")'),
377922
378079
  status: TaskUpdateStatusSchema.optional().describe("New status for the task"),
377923
- addBlocks: exports_external.array(exports_external.string()).optional().describe("Task IDs that this task blocks"),
377924
- addBlockedBy: exports_external.array(exports_external.string()).optional().describe("Task IDs that block this task"),
378080
+ addBlocks: exports_external.array(TaskIdSchema).optional().describe("Task IDs that this task blocks. Positive integer JSON values are accepted and normalized to strings."),
378081
+ addBlockedBy: exports_external.array(TaskIdSchema).optional().describe("Task IDs that block this task. Positive integer JSON values are accepted and normalized to strings."),
377925
378082
  owner: exports_external.string().optional().describe("New owner for the task"),
377926
378083
  metadata: exports_external.record(exports_external.string(), exports_external.unknown()).optional().describe("Metadata keys to merge into the task. Set a key to null to delete it.")
377927
378084
  });
@@ -377964,7 +378121,7 @@ var init_TaskUpdateTool = __esm(() => {
377964
378121
  return false;
377965
378122
  },
377966
378123
  toAutoClassifierInput(input) {
377967
- const parts = [input.taskId];
378124
+ const parts = [String(input.taskId)];
377968
378125
  if (input.status)
377969
378126
  parts.push(input.status);
377970
378127
  if (input.subject)
@@ -377975,7 +378132,7 @@ var init_TaskUpdateTool = __esm(() => {
377975
378132
  return null;
377976
378133
  },
377977
378134
  async call({
377978
- taskId,
378135
+ taskId: rawTaskId,
377979
378136
  subject,
377980
378137
  description,
377981
378138
  activeForm,
@@ -377985,6 +378142,9 @@ var init_TaskUpdateTool = __esm(() => {
377985
378142
  addBlockedBy,
377986
378143
  metadata
377987
378144
  }, context5) {
378145
+ const taskId = normalizeTaskIdInput(rawTaskId);
378146
+ const normalizedAddBlocks = normalizeTaskIdInputs(addBlocks);
378147
+ const normalizedAddBlockedBy = normalizeTaskIdInputs(addBlockedBy);
377988
378148
  const taskListId = getTaskListId();
377989
378149
  context5.setAppState((prev) => {
377990
378150
  if (prev.expandedView === "tasks")
@@ -378003,12 +378163,12 @@ var init_TaskUpdateTool = __esm(() => {
378003
378163
  };
378004
378164
  }
378005
378165
  const requestedDependencies = [
378006
- ...(addBlocks ?? []).map((targetId) => ({
378166
+ ...(normalizedAddBlocks ?? []).map((targetId) => ({
378007
378167
  fromTaskId: taskId,
378008
378168
  toTaskId: targetId,
378009
378169
  field: "addBlocks"
378010
378170
  })),
378011
- ...(addBlockedBy ?? []).map((blockerId) => ({
378171
+ ...(normalizedAddBlockedBy ?? []).map((blockerId) => ({
378012
378172
  fromTaskId: blockerId,
378013
378173
  toTaskId: taskId,
378014
378174
  field: "addBlockedBy"
@@ -378082,7 +378242,7 @@ var init_TaskUpdateTool = __esm(() => {
378082
378242
  const tasksById = new Map((await listTasks(taskListId)).map((task) => [task.id, task]));
378083
378243
  const effectiveBlockers = new Set([
378084
378244
  ...existingTask.blockedBy,
378085
- ...addBlockedBy ?? []
378245
+ ...normalizedAddBlockedBy ?? []
378086
378246
  ]);
378087
378247
  const unresolvedBlockers = [...effectiveBlockers].filter((blockerId) => {
378088
378248
  const blocker = tasksById.get(blockerId);
@@ -378121,8 +378281,8 @@ var init_TaskUpdateTool = __esm(() => {
378121
378281
  updatedFields.push("status");
378122
378282
  }
378123
378283
  }
378124
- const newBlocks = (addBlocks ?? []).filter((id) => !existingTask.blocks.includes(id));
378125
- const newBlockedBy = (addBlockedBy ?? []).filter((id) => !existingTask.blockedBy.includes(id));
378284
+ const newBlocks = (normalizedAddBlocks ?? []).filter((id) => !existingTask.blocks.includes(id));
378285
+ const newBlockedBy = (normalizedAddBlockedBy ?? []).filter((id) => !existingTask.blockedBy.includes(id));
378126
378286
  if (newBlocks.length > 0)
378127
378287
  updatedFields.push("blocks");
378128
378288
  if (newBlockedBy.length > 0)
@@ -378529,7 +378689,14 @@ var init_TeamCreateTool = __esm(() => {
378529
378689
  toAutoClassifierInput(input) {
378530
378690
  return input.team_name;
378531
378691
  },
378532
- async validateInput(input, _context) {
378692
+ async validateInput(input, context5) {
378693
+ if (context5.getAppState().toolPermissionContext.mode === "plan") {
378694
+ return {
378695
+ result: false,
378696
+ message: "TeamCreate is unavailable in plan mode because it changes team and task state. Finish and approve the plan before creating a team; use read-only Explore or Plan agents for planning research.",
378697
+ errorCode: 9
378698
+ };
378699
+ }
378533
378700
  if (!input.team_name || input.team_name.trim().length === 0) {
378534
378701
  return {
378535
378702
  result: false,
@@ -378560,6 +378727,9 @@ var init_TeamCreateTool = __esm(() => {
378560
378727
  async call(input, context5) {
378561
378728
  const { setAppState, getAppState } = context5;
378562
378729
  const { team_name, description: _description, agent_type } = input;
378730
+ if (getAppState().toolPermissionContext.mode === "plan") {
378731
+ throw new Error("TeamCreate is unavailable in plan mode because it changes team and task state.");
378732
+ }
378563
378733
  const appState = getAppState();
378564
378734
  const existingTeam = appState.teamContext?.teamName;
378565
378735
  if (existingTeam) {
@@ -378704,6 +378874,16 @@ var init_TeamDeleteTool = __esm(() => {
378704
378874
  async prompt() {
378705
378875
  return getPrompt7();
378706
378876
  },
378877
+ async validateInput(_input, context5) {
378878
+ if (context5.getAppState().toolPermissionContext.mode === "plan") {
378879
+ return {
378880
+ result: false,
378881
+ message: "TeamDelete is unavailable in plan mode because it changes team and task state. Finish or exit plan mode before deleting a team.",
378882
+ errorCode: 9
378883
+ };
378884
+ }
378885
+ return { result: true };
378886
+ },
378707
378887
  mapToolResultToToolResultBlockParam(data, toolUseID) {
378708
378888
  return {
378709
378889
  tool_use_id: toolUseID,
@@ -378719,6 +378899,9 @@ var init_TeamDeleteTool = __esm(() => {
378719
378899
  async call(_input, context5) {
378720
378900
  const { setAppState, getAppState } = context5;
378721
378901
  const appState = getAppState();
378902
+ if (appState.toolPermissionContext.mode === "plan") {
378903
+ throw new Error("TeamDelete is unavailable in plan mode because it changes team and task state.");
378904
+ }
378722
378905
  const teamName = appState.teamContext?.teamName;
378723
378906
  if (teamName) {
378724
378907
  const teamFile = readTeamFile(teamName);
@@ -381485,7 +381668,9 @@ The ${AGENT_TOOL_NAME} tool launches specialized agents (subprocesses) that auto
381485
381668
 
381486
381669
  ${agentListSection}
381487
381670
 
381488
- ${forkEnabled ? `When using the ${AGENT_TOOL_NAME} tool, specify a subagent_type to use a specialized agent, or omit it to fork yourself \u2014 a fork inherits your full conversation context.` : `When using the ${AGENT_TOOL_NAME} tool, specify a subagent_type parameter to select which agent type to use. If omitted, the general-purpose agent is used.`}`;
381671
+ ${forkEnabled ? `When using the ${AGENT_TOOL_NAME} tool, specify a subagent_type to use a specialized agent, or omit it to fork yourself \u2014 a fork inherits your full conversation context.` : `When using the ${AGENT_TOOL_NAME} tool, specify a subagent_type parameter to select which agent type to use. If omitted, the general-purpose agent is used.`}
381672
+
381673
+ For non-trivial delegation, define one cohesive task with its own observable done check per outcome before launching workers. Launch mutually independent tasks together only when they have no conflicting shared mutations; keep dependent or conflicting work sequential. Keep genuinely atomic work as one task instead of manufacturing extra agents.`;
381489
381674
  if (isCoordinator) {
381490
381675
  return shared;
381491
381676
  }
@@ -387616,7 +387801,7 @@ function isAnyTracingEnabled() {
387616
387801
  return isTelemetryEnabled() || isEnhancedTelemetryEnabled() || isBetaTracingEnabled();
387617
387802
  }
387618
387803
  function getTracer() {
387619
- return import_api39.trace.getTracer("ur-agent.gen_ai", "1.65.9");
387804
+ return import_api39.trace.getTracer("ur-agent.gen_ai", "1.65.10");
387620
387805
  }
387621
387806
  function createSpanAttributes(spanType, customAttributes = {}) {
387622
387807
  const baseAttributes = getTelemetryAttributes();
@@ -388328,25 +388513,28 @@ function checkTaskListGate(input) {
388328
388513
  return { allowed: true };
388329
388514
  }
388330
388515
  if (input.taskCount === null) {
388516
+ const taskTool2 = input.taskPlanningToolName ?? "TaskCreate";
388331
388517
  return {
388332
388518
  allowed: false,
388333
- reason: `The task list could not be read, so ${input.toolName} was not allowed ` + `to change state without a verifiable plan. Retry TaskList or ` + `TaskCreate, then retry this call. Disable with ` + `tasks.requireBeforeChanges.enabled=false in settings.`
388519
+ reason: `The task list could not be read, so ${input.toolName} was not allowed ` + `to change state without a verifiable plan. Use ${taskTool2} to create ` + `or repair the task list, then retry this call. ` + `${TASK_DECOMPOSITION_RECOVERY} ` + `Disable with ` + `tasks.requireBeforeChanges.enabled=false in settings.`
388334
388520
  };
388335
388521
  }
388336
388522
  if (input.isSubagent || ALWAYS_REQUIRE_PLAN_TOOLS.has(input.toolName)) {
388523
+ const taskTool2 = input.taskPlanningToolName ?? "TaskCreate";
388337
388524
  return {
388338
388525
  allowed: false,
388339
- reason: `No actionable parent task exists for ${input.toolName}. Call ` + `TaskCreate before delegating or changing state, then retry this call. ` + `Disable with tasks.requireBeforeChanges.enabled=false in settings.`
388526
+ reason: `No actionable parent task exists for ${input.toolName}. Call ` + `${taskTool2} before delegating or changing state, then retry this call. ` + `${TASK_DECOMPOSITION_RECOVERY} ` + `Disable with tasks.requireBeforeChanges.enabled=false in settings.`
388340
388527
  };
388341
388528
  }
388342
388529
  if (input.readsSoFar < config2.freeReads)
388343
388530
  return { allowed: true };
388531
+ const taskTool = input.taskPlanningToolName ?? "TaskCreate";
388344
388532
  return {
388345
388533
  allowed: false,
388346
- reason: `No task list exists, and ${input.toolName} changes the workspace. ` + `Call TaskCreate first with the steps you intend to take, then retry ` + `this call. Reads are unrestricted, so investigate as much as you need ` + `before writing the list. ` + `Disable with tasks.requireBeforeChanges.enabled=false in settings.`
388534
+ reason: `No task list exists, and ${input.toolName} changes the workspace. ` + `Call ${taskTool} first, then retry this call. ` + `${TASK_DECOMPOSITION_RECOVERY} Reads are unrestricted, so investigate ` + `as much as you need before writing the list. ` + `Disable with tasks.requireBeforeChanges.enabled=false in settings.`
388347
388535
  };
388348
388536
  }
388349
- var TASK_LIST_GATE_DEFAULTS, KNOWN_MUTATING_TOOLS, GATE_EXEMPT_TOOLS, ALWAYS_REQUIRE_PLAN_TOOLS, PLAN_ARTIFACT_MUTATING_TOOLS;
388537
+ var TASK_LIST_GATE_DEFAULTS, KNOWN_MUTATING_TOOLS, GATE_EXEMPT_TOOLS, ALWAYS_REQUIRE_PLAN_TOOLS, TASK_DECOMPOSITION_RECOVERY, PLAN_ARTIFACT_MUTATING_TOOLS;
388350
388538
  var init_taskListGate = __esm(() => {
388351
388539
  init_settings2();
388352
388540
  init_path();
@@ -388378,6 +388566,7 @@ var init_taskListGate = __esm(() => {
388378
388566
  "Agent",
388379
388567
  "Task"
388380
388568
  ]);
388569
+ TASK_DECOMPOSITION_RECOVERY = "For non-trivial work, create one task per cohesive outcome with its own " + "observable done check; keep one task only when the work is genuinely atomic.";
388381
388570
  PLAN_ARTIFACT_MUTATING_TOOLS = new Set([
388382
388571
  "Write",
388383
388572
  "Edit",
@@ -389460,6 +389649,36 @@ function isCurrentPlanArtifactMutation(toolName, input, toolUseContext) {
389460
389649
  return false;
389461
389650
  }
389462
389651
  }
389652
+ function isReadOnlyPlanAgentDelegation(tool, input, toolUseContext) {
389653
+ try {
389654
+ if (toolUseContext.getAppState().toolPermissionContext.mode !== "plan" || !toolMatchesName(tool, AGENT_TOOL_NAME) || typeof input !== "object" || input === null) {
389655
+ return false;
389656
+ }
389657
+ const candidate = input;
389658
+ if (typeof candidate.subagent_type !== "string" || !READ_ONLY_PLAN_AGENT_TYPES.has(candidate.subagent_type) || candidate.name !== undefined || candidate.team_name !== undefined || candidate.mode !== undefined || candidate.isolation !== undefined || candidate.cwd !== undefined || candidate.run_in_background === true) {
389659
+ return false;
389660
+ }
389661
+ const activeAgent = toolUseContext.options.agentDefinitions?.activeAgents?.find((agent) => agent.agentType === candidate.subagent_type);
389662
+ return activeAgent?.source === "built-in";
389663
+ } catch {
389664
+ return false;
389665
+ }
389666
+ }
389667
+ function isBuiltInReadOnlyPlanningSubagent(toolUseContext) {
389668
+ if (!toolUseContext.agentId || !toolUseContext.agentType || !READ_ONLY_PLAN_AGENT_TYPES.has(toolUseContext.agentType)) {
389669
+ return false;
389670
+ }
389671
+ return toolUseContext.options.agentDefinitions?.activeAgents?.find((agent) => agent.agentType === toolUseContext.agentType)?.source === "built-in";
389672
+ }
389673
+ function getTaskPlanningToolName(toolUseContext) {
389674
+ if (toolUseContext.options.tools.some((tool) => toolMatchesName(tool, TASK_CREATE_TOOL_NAME))) {
389675
+ return TASK_CREATE_TOOL_NAME;
389676
+ }
389677
+ if (toolUseContext.options.tools.some((tool) => toolMatchesName(tool, TODO_WRITE_TOOL_NAME))) {
389678
+ return TODO_WRITE_TOOL_NAME;
389679
+ }
389680
+ return "the available task-list tool";
389681
+ }
389463
389682
  function getStopHookInfo(attachment) {
389464
389683
  if (typeof attachment !== "object" || attachment === null || !("command" in attachment) || typeof attachment.command !== "string" || !("durationMs" in attachment) || typeof attachment.durationMs !== "number") {
389465
389684
  return null;
@@ -389920,18 +390139,36 @@ async function checkPermissionsAndCallTool(tool, toolUseID, input, toolUseContex
389920
390139
  const initiallyValidatedCallSig = callSig;
389921
390140
  let isMutating = true;
389922
390141
  try {
389923
- isMutating = !tool.isReadOnly(parsedInput.data);
390142
+ isMutating = !tool.isReadOnly(parsedInput.data) && !isReadOnlyPlanAgentDelegation(tool, parsedInput.data, toolUseContext);
389924
390143
  } catch {
389925
390144
  isMutating = true;
389926
390145
  }
389927
390146
  const isPlanArtifactMutation = isCurrentPlanArtifactMutation(tool.name, parsedInput.data, toolUseContext);
390147
+ if (isMutating && isBuiltInReadOnlyPlanningSubagent(toolUseContext)) {
390148
+ recordCallFailure(callSig);
390149
+ return [
390150
+ {
390151
+ message: createUserMessage({
390152
+ content: [
390153
+ {
390154
+ type: "tool_result",
390155
+ content: "<tool_use_error>ReadOnlyPlanningAgent: Built-in Explore and Plan agents may only perform read-only operations. Return your findings to the parent agent instead of changing state.</tool_use_error>",
390156
+ is_error: true,
390157
+ tool_use_id: toolUseID
390158
+ }
390159
+ ]
390160
+ })
390161
+ }
390162
+ ];
390163
+ }
389928
390164
  const gate = checkTaskListGate({
389929
390165
  toolName: tool.name,
389930
390166
  taskCount: await countTasksForGate(toolUseContext),
389931
390167
  readsSoFar: countToolCallsBeforeCurrent(toolUseContext.messages, assistantMessage, toolUseID),
389932
390168
  isSubagent: Boolean(toolUseContext.agentId),
389933
390169
  isMutating,
389934
- isPlanArtifactMutation
390170
+ isPlanArtifactMutation,
390171
+ taskPlanningToolName: getTaskPlanningToolName(toolUseContext)
389935
390172
  });
389936
390173
  if (gate.allowed === false) {
389937
390174
  recordCallFailure(callSig);
@@ -390282,11 +390519,29 @@ async function checkPermissionsAndCallTool(tool, toolUseID, input, toolUseContex
390282
390519
  }
390283
390520
  let finalIsMutating = true;
390284
390521
  try {
390285
- finalIsMutating = !tool.isReadOnly(finalParsedInput.data);
390522
+ finalIsMutating = !tool.isReadOnly(finalParsedInput.data) && !isReadOnlyPlanAgentDelegation(tool, finalParsedInput.data, toolUseContext);
390286
390523
  } catch {
390287
390524
  finalIsMutating = true;
390288
390525
  }
390289
390526
  const finalIsPlanArtifactMutation = isCurrentPlanArtifactMutation(tool.name, finalParsedInput.data, toolUseContext);
390527
+ if (finalIsMutating && isBuiltInReadOnlyPlanningSubagent(toolUseContext)) {
390528
+ recordCallFailure(callSig);
390529
+ finishPreExecutionRejection();
390530
+ resultingMessages.push({
390531
+ message: createUserMessage({
390532
+ content: [
390533
+ {
390534
+ type: "tool_result",
390535
+ content: "<tool_use_error>ReadOnlyPlanningAgent after input update: Built-in Explore and Plan agents may only perform read-only operations. Return your findings to the parent agent instead of changing state.</tool_use_error>",
390536
+ is_error: true,
390537
+ tool_use_id: toolUseID
390538
+ }
390539
+ ],
390540
+ sourceToolAssistantUUID: assistantMessage.uuid
390541
+ })
390542
+ });
390543
+ return resultingMessages;
390544
+ }
390290
390545
  const effectiveCallChanged = callSig !== initiallyValidatedCallSig || finalIsMutating !== isMutating || finalIsPlanArtifactMutation !== isPlanArtifactMutation;
390291
390546
  if (finalIsMutating && !finalIsPlanArtifactMutation) {
390292
390547
  const finalGate = checkTaskListGate({
@@ -390295,7 +390550,8 @@ async function checkPermissionsAndCallTool(tool, toolUseID, input, toolUseContex
390295
390550
  readsSoFar: countToolCallsBeforeCurrent(toolUseContext.messages, assistantMessage, toolUseID),
390296
390551
  isSubagent: Boolean(toolUseContext.agentId),
390297
390552
  isMutating: finalIsMutating,
390298
- isPlanArtifactMutation: finalIsPlanArtifactMutation
390553
+ isPlanArtifactMutation: finalIsPlanArtifactMutation,
390554
+ taskPlanningToolName: getTaskPlanningToolName(toolUseContext)
390299
390555
  });
390300
390556
  if (finalGate.allowed === false) {
390301
390557
  recordCallFailure(callSig);
@@ -390693,6 +390949,7 @@ var init_toolExecution = __esm(() => {
390693
390949
  init_cwd2();
390694
390950
  init_permissionLogging();
390695
390951
  init_Tool();
390952
+ init_constants2();
390696
390953
  init_bashPermissions();
390697
390954
  init_prompt2();
390698
390955
  init_prompt3();
@@ -395688,7 +395945,8 @@ async function createPlanModeAttachmentIfNeeded(context5) {
395688
395945
  reminderType: "full",
395689
395946
  isSubAgent: !!context5.agentId,
395690
395947
  planFilePath,
395691
- planExists
395948
+ planExists,
395949
+ availablePlanAgentTypes: getAvailableReadOnlyPlanAgentTypes(context5)
395692
395950
  });
395693
395951
  }
395694
395952
  async function createAsyncAgentAttachmentsIfNeeded(context5) {
@@ -399951,10 +400209,24 @@ async function getPlanModeAttachments(messages, toolUseContext) {
399951
400209
  reminderType,
399952
400210
  isSubAgent: !!toolUseContext.agentId,
399953
400211
  planFilePath,
399954
- planExists: existingPlan !== null
400212
+ planExists: existingPlan !== null,
400213
+ availablePlanAgentTypes: getAvailableReadOnlyPlanAgentTypes(toolUseContext)
399955
400214
  });
399956
400215
  return attachments;
399957
400216
  }
400217
+ function getAvailableReadOnlyPlanAgentTypes(toolUseContext) {
400218
+ const hasAgentTool = toolUseContext.options.tools.some((tool) => toolMatchesName(tool, AGENT_TOOL_NAME));
400219
+ if (!hasAgentTool)
400220
+ return [];
400221
+ try {
400222
+ const definitions = toolUseContext.options.agentDefinitions;
400223
+ const activeAgents = definitions?.activeAgents ?? [];
400224
+ const allowlistedAgents = definitions?.allowedAgentTypes ? activeAgents.filter((agent) => definitions.allowedAgentTypes.includes(agent.agentType)) : activeAgents;
400225
+ return filterDeniedAgents(allowlistedAgents, toolUseContext.getAppState().toolPermissionContext, AGENT_TOOL_NAME).filter((agent) => agent.source === "built-in" && READ_ONLY_PLAN_AGENT_TYPES.has(agent.agentType)).map((agent) => agent.agentType);
400226
+ } catch {
400227
+ return [];
400228
+ }
400229
+ }
399958
400230
  async function getPlanModeExitAttachment(toolUseContext) {
399959
400231
  if (!needsPlanModeExitAttachment()) {
399960
400232
  return [];
@@ -408416,6 +408688,12 @@ function getPlanPhase4Section() {
408416
408688
  return PLAN_PHASE4_CONTROL;
408417
408689
  }
408418
408690
  }
408691
+ function getAvailablePlanAgentTypes(attachment) {
408692
+ if (attachment.availablePlanAgentTypes !== undefined) {
408693
+ return new Set(attachment.availablePlanAgentTypes);
408694
+ }
408695
+ return areExplorePlanAgentsEnabled() ? new Set([EXPLORE_AGENT.agentType, PLAN_AGENT.agentType]) : new Set;
408696
+ }
408419
408697
  function getPlanModeV2Instructions(attachment) {
408420
408698
  if (attachment.isSubAgent) {
408421
408699
  return [];
@@ -408426,26 +408704,21 @@ function getPlanModeV2Instructions(attachment) {
408426
408704
  const agentCount = getPlanModeV2AgentCount();
408427
408705
  const exploreAgentCount = getPlanModeV2ExploreAgentCount();
408428
408706
  const planFileInfo = attachment.planExists ? `A plan file already exists at ${attachment.planFilePath}. You can read it and make incremental edits using the ${FileEditTool.name} tool.` : `No plan file exists yet. You should create your plan at ${attachment.planFilePath} using the ${FileWriteTool.name} tool.`;
408429
- const content = `Plan mode is active. The user indicated that they do not want you to execute yet -- you MUST NOT make any edits (with the exception of the plan file mentioned below), run any non-readonly tools (including changing configs or making commits), or otherwise make any changes to the system. This supercedes any other instructions you have received.
408430
-
408431
- ## Plan File Info:
408432
- ${planFileInfo}
408433
- You should build your plan incrementally by writing to or editing this file. NOTE that this is the only file you are allowed to edit - other than this you are only allowed to take READ-ONLY actions.
408434
-
408435
- ## Plan Workflow
408436
-
408437
- ### Phase 1: Initial Understanding
408707
+ const availablePlanAgents = getAvailablePlanAgentTypes(attachment);
408708
+ const phase1 = availablePlanAgents.has(EXPLORE_AGENT.agentType) ? `### Phase 1: Initial Understanding
408438
408709
  Goal: Gain a comprehensive understanding of the user's request by reading through code and asking them questions. Critical: In this phase you should only use the ${EXPLORE_AGENT.agentType} subagent type.
408439
408710
 
408440
408711
  1. Focus on understanding the user's request and the code associated with their request. Actively search for existing functions, utilities, and patterns that can be reused \u2014 avoid proposing new code when suitable implementations already exist.
408441
408712
 
408442
408713
  2. **Launch up to ${exploreAgentCount} ${EXPLORE_AGENT.agentType} agents IN PARALLEL** (single message, multiple tool calls) to efficiently explore the codebase.
408443
408714
  - Use 1 agent when the task is isolated to known files, the user provided specific file paths, or you're making a small targeted change.
408444
- - Use multiple agents when: the scope is uncertain, multiple areas of the codebase are involved, or you need to understand existing patterns before planning.
408445
- - Quality over quantity - ${exploreAgentCount} agents maximum, but you should try to use the minimum number of agents necessary (usually just 1)
408446
- - If using multiple agents: Provide each agent with a specific search focus or area to explore. Example: One agent searches for existing implementations, another explores related components, a third investigating testing patterns
408715
+ - Use multiple agents when the scope is uncertain or independent areas need investigation.
408716
+ - Give every agent a distinct search focus; use the minimum number needed.` : `### Phase 1: Initial Understanding
408717
+ Goal: Gain a comprehensive understanding of the user's request using the read-only tools that are actually available.
408447
408718
 
408448
- ### Phase 2: Design
408719
+ 1. Focus on the request and associated code. Search for existing functions, utilities, and patterns that can be reused.
408720
+ 2. Use ${getReadOnlyToolNames()} directly. Batch independent searches and reads in parallel (up to 8 calls per turn), but keep dependent investigation sequential. Do not call a generic Agent as a planning fallback.`;
408721
+ const phase2 = availablePlanAgents.has(PLAN_AGENT.agentType) ? `### Phase 2: Design
408449
408722
  Goal: Design an implementation approach.
408450
408723
 
408451
408724
  Launch ${PLAN_AGENT.agentType} agent(s) to design the implementation based on the user's intent and your exploration results from Phase 1.
@@ -408457,21 +408730,22 @@ You can launch up to ${agentCount} agent(s) in parallel.
408457
408730
  - **Skip agents**: Only for truly trivial tasks (typo fixes, single-line changes, simple renames)
408458
408731
  ${agentCount > 1 ? `- **Multiple agents**: Use up to ${agentCount} agents for complex tasks that benefit from different perspectives
408459
408732
 
408460
- Examples of when to use multiple agents:
408461
- - The task touches multiple parts of the codebase
408462
- - It's a large refactor or architectural change
408463
- - There are many edge cases to consider
408464
- - You'd benefit from exploring different approaches
408733
+ Examples: simplicity vs performance, root cause vs prevention, or minimal change vs clean architecture.` : ""}
408734
+ In each agent prompt, provide Phase 1 evidence, filenames, code-path traces, requirements, constraints, and the perspective to evaluate.` : `### Phase 2: Design
408735
+ Goal: Design the implementation directly from the Phase 1 evidence.
408465
408736
 
408466
- Example perspectives by task type:
408467
- - New feature: simplicity vs performance vs maintainability
408468
- - Bug fix: root cause vs workaround vs prevention
408469
- - Refactoring: minimal change vs clean architecture
408470
- ` : ""}
408471
- In the agent prompt:
408472
- - Provide comprehensive background context from Phase 1 exploration including filenames and code path traces
408473
- - Describe requirements and constraints
408474
- - Request a detailed implementation plan
408737
+ Compare plausible approaches, choose the smallest approach that fully satisfies the request, identify trade-offs and edge cases, and trace every proposed change to current code. No read-only Plan worker is active, so do not call a generic Agent as a substitute.`;
408738
+ const content = `Plan mode is active. The user indicated that they do not want you to execute yet -- you MUST NOT make any edits (with the exception of the plan file mentioned below), run any non-readonly tools (including changing configs or making commits), or otherwise make any changes to the system. This supercedes any other instructions you have received.
408739
+
408740
+ ## Plan File Info:
408741
+ ${planFileInfo}
408742
+ You should build your plan incrementally by writing to or editing this file. NOTE that this is the only file you are allowed to edit - other than this you are only allowed to take READ-ONLY actions.
408743
+
408744
+ ## Plan Workflow
408745
+
408746
+ ${phase1}
408747
+
408748
+ ${phase2}
408475
408749
 
408476
408750
  ### Phase 3: Review
408477
408751
  Goal: Review the plan(s) from Phase 2 and ensure alignment with the user's intentions.
@@ -408513,7 +408787,7 @@ You are pair-planning with the user. Explore the code to build context, ask the
408513
408787
 
408514
408788
  Repeat this cycle until the plan is complete:
408515
408789
 
408516
- 1. **Explore** \u2014 Use ${getReadOnlyToolNames()} to read code. Look for existing functions, utilities, and patterns to reuse.${areExplorePlanAgentsEnabled() ? ` You can use the ${EXPLORE_AGENT.agentType} agent type to parallelize complex searches without filling your context, though for straightforward queries direct tools are simpler.` : ""}
408790
+ 1. **Explore** \u2014 Use ${getReadOnlyToolNames()} to read code. Look for existing functions, utilities, and patterns to reuse.${getAvailablePlanAgentTypes(attachment).has(EXPLORE_AGENT.agentType) ? ` You can use the ${EXPLORE_AGENT.agentType} agent type to parallelize complex searches without filling your context, though for straightforward queries direct tools are simpler.` : ""}
408517
408791
  2. **Update the plan file** \u2014 After each discovery, immediately capture what you learned. Don't wait until the end.
408518
408792
  3. **Ask the user** \u2014 When you hit an ambiguity or decision you can't resolve from code alone, use ${ASK_USER_QUESTION_TOOL_NAME}. Then go back to step 1.
408519
408793
 
@@ -408535,6 +408809,7 @@ Your plan file should be divided into clear sections using markdown headers, bas
408535
408809
  - Ensure that the plan file is concise enough to scan quickly, but detailed enough to execute effectively
408536
408810
  - Include the paths of critical files to be modified
408537
408811
  - Reference existing functions and utilities you found that should be reused, with their file paths
408812
+ - ${PLAN_TASK_GRAPH_REQUIREMENT}
408538
408813
  - Include a verification section describing how to test the changes end-to-end (run the code, use MCP tools, run tests)
408539
408814
 
408540
408815
  ### When to Converge
@@ -409923,33 +410198,7 @@ Note: The user's next message may contain a correction or preference. Pay close
409923
410198
  `, PLAN_REJECTION_PREFIX = `The agent proposed a plan that was rejected by the user. The user chose to stay in plan mode rather than proceed with implementation.
409924
410199
 
409925
410200
  Rejected plan:
409926
- `, DENIAL_WORKAROUND_GUIDANCE, NO_RESPONSE_REQUESTED = "No response requested.", SYNTHETIC_TOOL_RESULT_PLACEHOLDER = "[Tool result missing due to internal error]", SYNTHETIC_MODEL = "<synthetic>", SYNTHETIC_MESSAGES, EMPTY_LOOKUPS, EMPTY_STRING_SET, STRIPPED_TAGS_RE, PLAN_PHASE4_CONTROL = `### Phase 4: Final Plan
409927
- Goal: Write your final plan to the plan file (the only file you can edit).
409928
- - Begin with a **Context** section: explain why this change is being made \u2014 the problem or need it addresses, what prompted it, and the intended outcome
409929
- - Include only your recommended approach, not all alternatives
409930
- - Ensure that the plan file is concise enough to scan quickly, but detailed enough to execute effectively
409931
- - Include the paths of critical files to be modified
409932
- - Reference existing functions and utilities you found that should be reused, with their file paths
409933
- - Include a verification section describing how to test the changes end-to-end (run the code, use MCP tools, run tests)`, PLAN_PHASE4_TRIM = `### Phase 4: Final Plan
409934
- Goal: Write your final plan to the plan file (the only file you can edit).
409935
- - One-line **Context**: what is being changed and why
409936
- - Include only your recommended approach, not all alternatives
409937
- - List the paths of files to be modified
409938
- - Reference existing functions and utilities to reuse, with their file paths
409939
- - End with **Verification**: the single command to run to confirm the change works (no numbered test procedures)`, PLAN_PHASE4_CUT = `### Phase 4: Final Plan
409940
- Goal: Write your final plan to the plan file (the only file you can edit).
409941
- - Do NOT write a Context or Background section. The user just told you what they want.
409942
- - List the paths of files to be modified and what changes in each (one line per file)
409943
- - Reference existing functions and utilities to reuse, with their file paths
409944
- - End with **Verification**: the single command that confirms the change works
409945
- - Most good plans are under 40 lines. Prose is a sign you are padding.`, PLAN_PHASE4_CAP = `### Phase 4: Final Plan
409946
- Goal: Write your final plan to the plan file (the only file you can edit).
409947
- - Do NOT write a Context, Background, or Overview section. The user just told you what they want.
409948
- - Do NOT restate the user's request. Do NOT write prose paragraphs.
409949
- - List the paths of files to be modified and what changes in each (one bullet per file)
409950
- - Reference existing functions to reuse, with file:line
409951
- - End with the single verification command
409952
- - **Hard limit: 40 lines.** If the plan is longer, delete prose \u2014 not file paths.`;
410201
+ `, DENIAL_WORKAROUND_GUIDANCE, NO_RESPONSE_REQUESTED = "No response requested.", SYNTHETIC_TOOL_RESULT_PLACEHOLDER = "[Tool result missing due to internal error]", SYNTHETIC_MODEL = "<synthetic>", SYNTHETIC_MESSAGES, EMPTY_LOOKUPS, EMPTY_STRING_SET, STRIPPED_TAGS_RE, PLAN_PHASE4_CONTROL, PLAN_PHASE4_TRIM, PLAN_PHASE4_CUT, PLAN_PHASE4_CAP;
409953
410202
  var init_messages = __esm(() => {
409954
410203
  init_isObject();
409955
410204
  init_last();
@@ -409980,6 +410229,7 @@ var init_messages = __esm(() => {
409980
410229
  init_prompt();
409981
410230
  init_state();
409982
410231
  init_xml();
410232
+ init_planImplementationContract();
409983
410233
  init_diagnosticTracking();
409984
410234
  init_Tool();
409985
410235
  init_FileReadTool();
@@ -410018,6 +410268,40 @@ var init_messages = __esm(() => {
410018
410268
  };
410019
410269
  EMPTY_STRING_SET = Object.freeze(new Set);
410020
410270
  STRIPPED_TAGS_RE = /<(commit_analysis|context|function_analysis|pr_analysis)>.*?<\/\1>\n?/gs;
410271
+ PLAN_PHASE4_CONTROL = `### Phase 4: Final Plan
410272
+ Goal: Write your final plan to the plan file (the only file you can edit).
410273
+ - Begin with a **Context** section: explain why this change is being made \u2014 the problem or need it addresses, what prompted it, and the intended outcome
410274
+ - Include only your recommended approach, not all alternatives
410275
+ - Ensure that the plan file is concise enough to scan quickly, but detailed enough to execute effectively
410276
+ - Include the paths of critical files to be modified
410277
+ - Reference existing functions and utilities you found that should be reused, with their file paths
410278
+ - ${PLAN_TASK_GRAPH_REQUIREMENT}
410279
+ - Include a verification section describing how to test the changes end-to-end (run the code, use MCP tools, run tests)`;
410280
+ PLAN_PHASE4_TRIM = `### Phase 4: Final Plan
410281
+ Goal: Write your final plan to the plan file (the only file you can edit).
410282
+ - One-line **Context**: what is being changed and why
410283
+ - Include only your recommended approach, not all alternatives
410284
+ - List the paths of files to be modified
410285
+ - Reference existing functions and utilities to reuse, with their file paths
410286
+ - ${PLAN_TASK_GRAPH_REQUIREMENT}
410287
+ - End with **Verification**: the single command to run to confirm the change works (no numbered test procedures)`;
410288
+ PLAN_PHASE4_CUT = `### Phase 4: Final Plan
410289
+ Goal: Write your final plan to the plan file (the only file you can edit).
410290
+ - Do NOT write a Context or Background section. The user just told you what they want.
410291
+ - List the paths of files to be modified and what changes in each (one line per file)
410292
+ - Reference existing functions and utilities to reuse, with their file paths
410293
+ - ${PLAN_TASK_GRAPH_REQUIREMENT}
410294
+ - End with **Verification**: the single command that confirms the change works
410295
+ - Most good plans are under 40 lines. Prose is a sign you are padding.`;
410296
+ PLAN_PHASE4_CAP = `### Phase 4: Final Plan
410297
+ Goal: Write your final plan to the plan file (the only file you can edit).
410298
+ - Do NOT write a Context, Background, or Overview section. The user just told you what they want.
410299
+ - Do NOT restate the user's request. Do NOT write prose paragraphs.
410300
+ - List the paths of files to be modified and what changes in each (one bullet per file)
410301
+ - Reference existing functions to reuse, with file:line
410302
+ - ${PLAN_TASK_GRAPH_REQUIREMENT}
410303
+ - End with the single verification command
410304
+ - **Hard limit: 40 lines.** If the plan is longer, delete prose \u2014 not file paths.`;
410021
410305
  });
410022
410306
 
410023
410307
  // src/services/api/errors.ts
@@ -418035,7 +418319,7 @@ function Feedback({
418035
418319
  platform: env2.platform,
418036
418320
  gitRepo: envInfo.isGit,
418037
418321
  terminal: env2.terminal,
418038
- version: "1.65.9",
418322
+ version: "1.65.10",
418039
418323
  transcript: normalizeMessagesForAPI(messages),
418040
418324
  errors: sanitizedErrors,
418041
418325
  lastApiRequest: getLastAPIRequest(),
@@ -418227,7 +418511,7 @@ function Feedback({
418227
418511
  ", ",
418228
418512
  env2.terminal,
418229
418513
  ", v",
418230
- "1.65.9"
418514
+ "1.65.10"
418231
418515
  ]
418232
418516
  }, undefined, true, undefined, this)
418233
418517
  ]
@@ -418333,7 +418617,7 @@ ${sanitizedDescription}
418333
418617
  ` + `**Environment Info**
418334
418618
  ` + `- Platform: ${env2.platform}
418335
418619
  ` + `- Terminal: ${env2.terminal}
418336
- ` + `- Version: ${"1.65.9"}
418620
+ ` + `- Version: ${"1.65.10"}
418337
418621
  ` + `- Feedback ID: ${feedbackId}
418338
418622
  ` + `
418339
418623
  **Errors**
@@ -421443,7 +421727,7 @@ function buildPrimarySection() {
421443
421727
  }, undefined, false, undefined, this);
421444
421728
  return [{
421445
421729
  label: "Version",
421446
- value: "1.65.9"
421730
+ value: "1.65.10"
421447
421731
  }, {
421448
421732
  label: "Session name",
421449
421733
  value: nameValue
@@ -424773,7 +425057,7 @@ function Config({
424773
425057
  }
424774
425058
  }, undefined, false, undefined, this)
424775
425059
  }, undefined, false, undefined, this) : showSubmenu === "ChannelDowngrade" ? /* @__PURE__ */ jsx_dev_runtime179.jsxDEV(ChannelDowngradeDialog, {
424776
- currentVersion: "1.65.9",
425060
+ currentVersion: "1.65.10",
424777
425061
  onChoice: (choice) => {
424778
425062
  setShowSubmenu(null);
424779
425063
  setTabsHidden(false);
@@ -424785,7 +425069,7 @@ function Config({
424785
425069
  autoUpdatesChannel: "stable"
424786
425070
  };
424787
425071
  if (choice === "stay") {
424788
- newSettings.minimumVersion = "1.65.9";
425072
+ newSettings.minimumVersion = "1.65.10";
424789
425073
  }
424790
425074
  updateSettingsForSource("userSettings", newSettings);
424791
425075
  setSettingsData((prev_27) => ({
@@ -432849,7 +433133,7 @@ function HelpV2(t0) {
432849
433133
  let t6;
432850
433134
  if ($2[31] !== tabs) {
432851
433135
  t6 = /* @__PURE__ */ jsx_dev_runtime206.jsxDEV(Tabs, {
432852
- title: `UR v${"1.65.9"}`,
433136
+ title: `UR v${"1.65.10"}`,
432853
433137
  color: "professionalBlue",
432854
433138
  defaultTab: "general",
432855
433139
  children: tabs
@@ -433782,7 +434066,7 @@ function buildToolUseContext(tools, readFileStateCache, toolPermissionContext, a
433782
434066
  async function handleInitialize(options2) {
433783
434067
  return {
433784
434068
  name: "UR",
433785
- version: "1.65.9",
434069
+ version: "1.65.10",
433786
434070
  protocolVersion: "0.1.0",
433787
434071
  workspaceRoot: options2.cwd,
433788
434072
  capabilities: {
@@ -450890,7 +451174,7 @@ function getAllReleaseNotes(changelogContent = getStoredChangelogFromMemory()) {
450890
451174
  return [];
450891
451175
  }
450892
451176
  }
450893
- async function checkForReleaseNotes(lastSeenVersion, currentVersion = "1.65.9") {
451177
+ async function checkForReleaseNotes(lastSeenVersion, currentVersion = "1.65.10") {
450894
451178
  if (process.env.USER_TYPE === "ant") {
450895
451179
  const changelog = "";
450896
451180
  if (changelog) {
@@ -450917,7 +451201,7 @@ async function checkForReleaseNotes(lastSeenVersion, currentVersion = "1.65.9")
450917
451201
  releaseNotes
450918
451202
  };
450919
451203
  }
450920
- function checkForReleaseNotesSync(lastSeenVersion, currentVersion = "1.65.9") {
451204
+ function checkForReleaseNotesSync(lastSeenVersion, currentVersion = "1.65.10") {
450921
451205
  if (process.env.USER_TYPE === "ant") {
450922
451206
  const changelog = "";
450923
451207
  if (changelog) {
@@ -453783,7 +454067,7 @@ function getRecentActivitySync() {
453783
454067
  return cachedActivity;
453784
454068
  }
453785
454069
  function getLogoDisplayData() {
453786
- const version2 = process.env.DEMO_VERSION ?? "1.65.9";
454070
+ const version2 = process.env.DEMO_VERSION ?? "1.65.10";
453787
454071
  const serverUrl = getDirectConnectServerUrl();
453788
454072
  const displayPath = process.env.DEMO_VERSION ? "/code/ur" : getDisplayPath(getCwd());
453789
454073
  const cwd2 = serverUrl ? `${displayPath} in ${serverUrl.replace(/^https?:\/\//, "")}` : displayPath;
@@ -454650,7 +454934,7 @@ function LogoV2() {
454650
454934
  if ($2[2] === Symbol.for("react.memo_cache_sentinel")) {
454651
454935
  t2 = () => {
454652
454936
  const currentConfig2 = getGlobalConfig();
454653
- if (currentConfig2.lastReleaseNotesSeen === "1.65.9") {
454937
+ if (currentConfig2.lastReleaseNotesSeen === "1.65.10") {
454654
454938
  return;
454655
454939
  }
454656
454940
  saveGlobalConfig(_temp325);
@@ -455335,12 +455619,12 @@ function LogoV2() {
455335
455619
  return t41;
455336
455620
  }
455337
455621
  function _temp325(current) {
455338
- if (current.lastReleaseNotesSeen === "1.65.9") {
455622
+ if (current.lastReleaseNotesSeen === "1.65.10") {
455339
455623
  return current;
455340
455624
  }
455341
455625
  return {
455342
455626
  ...current,
455343
- lastReleaseNotesSeen: "1.65.9"
455627
+ lastReleaseNotesSeen: "1.65.10"
455344
455628
  };
455345
455629
  }
455346
455630
  function _temp241(s_0) {
@@ -472280,7 +472564,7 @@ function compileAgenticCiWorkflow(specName = "default", options2 = {}) {
472280
472564
  if (spec.name !== specName) {
472281
472565
  throw new Error("Agentic CI workflow spec name does not match");
472282
472566
  }
472283
- const packageVersion = options2.packageVersion ?? (typeof MACRO !== "undefined" ? "1.65.9" : "1.65.9");
472567
+ const packageVersion = options2.packageVersion ?? (typeof MACRO !== "undefined" ? "1.65.10" : "1.65.10");
472284
472568
  if (!/^\d+\.\d+\.\d+(?:-[0-9A-Za-z.-]+)?$/.test(packageVersion)) {
472285
472569
  throw new Error("invalid ur-agent package version");
472286
472570
  }
@@ -473273,7 +473557,7 @@ runner; \`ur trigger\` is the inbound parser that decides what to run.
473273
473557
  path: ".github/workflows/ur.yml",
473274
473558
  root: "project",
473275
473559
  content: compileAgenticCiWorkflow("default", {
473276
- packageVersion: typeof MACRO !== "undefined" ? "1.65.9" : "1.65.9"
473560
+ packageVersion: typeof MACRO !== "undefined" ? "1.65.10" : "1.65.10"
473277
473561
  })
473278
473562
  },
473279
473563
  {
@@ -473343,7 +473627,7 @@ function value(tokens, flag) {
473343
473627
  return index2 >= 0 ? tokens[index2 + 1] : undefined;
473344
473628
  }
473345
473629
  function cliVersion() {
473346
- return typeof MACRO !== "undefined" ? "1.65.9" : "1.65.9";
473630
+ return typeof MACRO !== "undefined" ? "1.65.10" : "1.65.10";
473347
473631
  }
473348
473632
  function workflowPath(cwd2) {
473349
473633
  return join159(cwd2, ".github", "workflows", "ur-agentic-ci.yml");
@@ -479208,7 +479492,7 @@ function createAcpStdioApp(deps) {
479208
479492
  }
479209
479493
  },
479210
479494
  authMethods: [],
479211
- agentInfo: { name: "UR-Nexus", version: "1.65.9" }
479495
+ agentInfo: { name: "UR-Nexus", version: "1.65.10" }
479212
479496
  })).onRequest("authenticate", () => ({})).onRequest("session/new", async (context6) => {
479213
479497
  const result = runtime2.newSession(context6.params.cwd, context6.params.mcpServers, context6.params.additionalDirectories);
479214
479498
  await runtime2.announce({
@@ -479305,7 +479589,7 @@ function createAcpStdioAgent(deps) {
479305
479589
  }
479306
479590
  },
479307
479591
  authMethods: [],
479308
- agentInfo: { name: "UR-Nexus", version: "1.65.9" }
479592
+ agentInfo: { name: "UR-Nexus", version: "1.65.10" }
479309
479593
  });
479310
479594
  return;
479311
479595
  case "authenticate":
@@ -481817,20 +482101,31 @@ function boundTaskCount(segments) {
481817
482101
  segments.slice(MAX_PLANNED_TASKS - 1).join("; ")
481818
482102
  ];
481819
482103
  }
482104
+ function splitDirectiveClauses(prompt) {
482105
+ const normalized = prompt.replace(/\s+and\s+then\s+/gi, " then ");
482106
+ const clauses = normalized.split(/;\s*|(?<=[.!?])\s+(?=[A-Z0-9])|\s+(?=(?:then|also|next|finally)\s+)/i).map(compact2).filter(Boolean);
482107
+ if (clauses.length < 2)
482108
+ return [];
482109
+ const segments = [clauses[0]];
482110
+ for (const clause of clauses.slice(1)) {
482111
+ if (STANDALONE_DIRECTIVE_PATTERN.test(clause)) {
482112
+ segments.push(clause);
482113
+ continue;
482114
+ }
482115
+ const last2 = segments.length - 1;
482116
+ segments[last2] = `${segments[last2]} ${clause}`;
482117
+ }
482118
+ return segments.length >= 2 ? segments : [];
482119
+ }
481820
482120
  function splitLongPrompt(prompt) {
481821
482121
  const bulletSegments = splitNumberedOrBulletedLines(prompt);
481822
482122
  if (bulletSegments.length > 0)
481823
482123
  return boundTaskCount(bulletSegments);
481824
482124
  const trimmed = compact2(prompt);
481825
- if (trimmed.length < 220 && !/[;\n]/.test(prompt))
481826
- return [trimmed];
481827
482125
  const lines = prompt.split(/\r?\n+/).map(compact2).filter(Boolean);
481828
482126
  if (lines.length >= 2)
481829
482127
  return boundTaskCount(lines);
481830
- const sentenceSegments = trimmed.split(/(?<=[.!?])\s+(?=[A-Z0-9])/).map(compact2).filter(Boolean);
481831
- if (sentenceSegments.length >= 2)
481832
- return boundTaskCount(sentenceSegments);
481833
- const directiveSegments = trimmed.split(/\s+(?:then|also|next|finally)\s+/i).map(compact2).filter(Boolean);
482128
+ const directiveSegments = splitDirectiveClauses(trimmed);
481834
482129
  return directiveSegments.length >= 2 ? boundTaskCount(directiveSegments) : [trimmed];
481835
482130
  }
481836
482131
  function needsPreviousTask(segment2) {
@@ -481842,10 +482137,12 @@ function needsAllPreviousTasks(segment2, role) {
481842
482137
  return /^(?:finally|once|after\s+(?:all|everything)|when\b.*\b(?:done|complete)|before\s+(?:finishing|completion))\b/i.test(segment2);
481843
482138
  }
481844
482139
  function inferRole(segment2) {
481845
- if (/\b(plan|analy[sz]e|decompose)\b/i.test(segment2))
482140
+ if (/\b(plan|analy[sz]e|decompose|review|audit|inspect)\b/i.test(segment2)) {
481846
482141
  return "planner";
481847
- if (/\b(verify|validate|test|check|prove)\b/i.test(segment2))
482142
+ }
482143
+ if (/\b(verify|validate|tests?|testing|checks?|prove)\b/i.test(segment2)) {
481848
482144
  return "verifier";
482145
+ }
481849
482146
  if (/\b(report|summari[sz]e|release notes|changelog)\b/i.test(segment2)) {
481850
482147
  return "reporter";
481851
482148
  }
@@ -481938,7 +482235,7 @@ function verificationCriteria(segment2, files, requiredFiles) {
481938
482235
  }
481939
482236
  return criteria;
481940
482237
  }
481941
- function makeTask(segment2, index2, previousTaskIds, originalPrompt, workspaceRoot) {
482238
+ function makeTask(segment2, index2, previousTasks, originalPrompt, workspaceRoot) {
481942
482239
  const files = extractReferencedFiles(segment2);
481943
482240
  const requiredFiles = CREATE_TARGET_PATTERN.test(segment2) ? [] : files;
481944
482241
  const outsidePaths = files.filter((file2) => isOutsideWorkspace(file2, workspaceRoot));
@@ -481949,7 +482246,10 @@ function makeTask(segment2, index2, previousTaskIds, originalPrompt, workspaceRo
481949
482246
  const needsScope = SECURITY_PATTERN.test(segment2) && !AUTHORIZED_SECURITY_PATTERN.test(segment2);
481950
482247
  const needsContext = isCriticallyAmbiguous(segment2);
481951
482248
  const role = inferRole(segment2);
481952
- const dependencies = needsAllPreviousTasks(segment2, role) ? [...previousTaskIds] : needsPreviousTask(segment2) && previousTaskIds.length > 0 ? [previousTaskIds[previousTaskIds.length - 1]] : [];
482249
+ const previousTaskIds = previousTasks.map((task) => task.id);
482250
+ const previousTask = previousTasks.at(-1);
482251
+ const followsInvestigation = role === "executor" && previousTask?.assignedAgent === "planner";
482252
+ const dependencies = needsAllPreviousTasks(segment2, role) ? [...previousTaskIds] : followsInvestigation ? [previousTask.id] : needsPreviousTask(segment2) && previousTaskIds.length > 0 ? [previousTaskIds[previousTaskIds.length - 1]] : [];
481953
482253
  const assumptions = needsContext ? ["Critical target/context is missing; ask for clarification before execution."] : [
481954
482254
  "Use the current workspace as the source of truth.",
481955
482255
  files.length === 0 ? "No specific files were named; discover relevant files before changing code." : "Only touch referenced files unless repository inspection proves another file is required."
@@ -481987,10 +482287,10 @@ function decomposePrompt(prompt, config3, workspaceRoot) {
481987
482287
  const originalPrompt = prompt;
481988
482288
  const segments = splitLongPrompt(prompt).filter(Boolean);
481989
482289
  const sourceSegments = segments.length > 0 ? segments : [""];
481990
- const previousTaskIds = [];
482290
+ const previousTasks = [];
481991
482291
  const tasks2 = sourceSegments.map((segment2, index2) => {
481992
- const task = makeTask(segment2, index2, previousTaskIds, originalPrompt, workspaceRoot);
481993
- previousTaskIds.push(task.id);
482292
+ const task = makeTask(segment2, index2, previousTasks, originalPrompt, workspaceRoot);
482293
+ previousTasks.push(task);
481994
482294
  return task;
481995
482295
  });
481996
482296
  return {
@@ -482016,7 +482316,7 @@ var init_planner = __esm(() => {
482016
482316
  SECURITY_PATTERN = /\b(pentest|penetration\s+test|exploit|sqlmap|nmap|metasploit|payload|vulnerabilit(?:y|ies)|cve|xss|csrf|rce|security\s+scan|attack)\b/i;
482017
482317
  AUTHORIZED_SECURITY_PATTERN = /\b(authorized|authorization|owned|own\s+system|my\s+(?:app|site|server|service)|localhost|127\.0\.0\.1|::1|lab|sandbox|ctf|test\s+target)\b/i;
482018
482318
  CREATE_TARGET_PATTERN = /\b(?:create|generate|scaffold)\b|^\s*(?:add|write)\s+(?:a|an|new)\b/i;
482019
- STANDALONE_DIRECTIVE_PATTERN = /^(?:then|after|once|next|finally|before|verify|validate|test|run|create|add|update|fix|implement|build|bump|publish|report|summari[sz]e)\b/i;
482319
+ STANDALONE_DIRECTIVE_PATTERN = /^(?:then|after|once|next|finally|before|verify|validate|test|run|create|add|update|fix|correct|improve|enhance|optimi[sz]e|implement|build|handle|support|document|refactor|remove|rename|migrate|review|audit|inspect|analy[sz]e|bump|publish|report|summari[sz]e)\b/i;
482020
482320
  });
482021
482321
 
482022
482322
  // src/services/promptPlanning/index.ts
@@ -492411,7 +492711,7 @@ function inferTests(goal) {
492411
492711
  }
492412
492712
  function decomposePrompt2(goal) {
492413
492713
  return [
492414
- "Decompose the following engineering goal into atomic subtasks.",
492714
+ "Decompose the following engineering goal into cohesive subtasks with observable completion checks.",
492415
492715
  "Return a JSON object with exactly this shape (no markdown, no commentary):",
492416
492716
  "",
492417
492717
  "{",
@@ -492429,7 +492729,9 @@ function decomposePrompt2(goal) {
492429
492729
  "}",
492430
492730
  "",
492431
492731
  "Guidelines:",
492432
- "- Each subtask should be small enough to implement and verify independently.",
492732
+ "- Use one subtask per cohesive outcome with a clear completion check.",
492733
+ "- Split separately completable deliverables; never hide them in one omnibus task.",
492734
+ "- Return one task when the goal is genuinely atomic. Do not split merely by file, command, tool call, or tiny mechanical step.",
492433
492735
  '- Use "dependsOn" only for real ordering constraints; independent tasks must use an empty array so they can run in parallel.',
492434
492736
  '- "filesTouched" should list the files likely to change.',
492435
492737
  '- "risk" should be high for auth/security/concurrency/destructive changes, medium for refactor/API changes, low for docs/style.',
@@ -690447,7 +690749,7 @@ async function captureMemoryDiagnostics(trigger2, dumpNumber = 0) {
690447
690749
  smapsRollup,
690448
690750
  platform: process.platform,
690449
690751
  nodeVersion: process.version,
690450
- ccVersion: "1.65.9"
690752
+ ccVersion: "1.65.10"
690451
690753
  };
690452
690754
  }
690453
690755
  async function performHeapDump(trigger2 = "manual", dumpNumber = 0) {
@@ -691027,7 +691329,7 @@ var init_bridge_kick = __esm(() => {
691027
691329
  var call153 = async () => {
691028
691330
  return {
691029
691331
  type: "text",
691030
- value: "1.65.9"
691332
+ value: "1.65.10"
691031
691333
  };
691032
691334
  }, version2, version_default;
691033
691335
  var init_version = __esm(() => {
@@ -702207,7 +702509,7 @@ function generateHtmlReport(data, insights) {
702207
702509
  </html>`;
702208
702510
  }
702209
702511
  function buildExportData(data, insights, facets, remoteStats) {
702210
- const version3 = typeof MACRO !== "undefined" ? "1.65.9" : "unknown";
702512
+ const version3 = typeof MACRO !== "undefined" ? "1.65.10" : "unknown";
702211
702513
  const remote_hosts_collected = remoteStats?.hosts.filter((h2) => h2.sessionCount > 0).map((h2) => h2.name);
702212
702514
  const facets_summary = {
702213
702515
  total: facets.size,
@@ -706534,7 +706836,7 @@ var init_sessionStorage = __esm(() => {
706534
706836
  init_settings2();
706535
706837
  init_slowOperations();
706536
706838
  init_uuid();
706537
- VERSION7 = typeof MACRO !== "undefined" ? "1.65.9" : "unknown";
706839
+ VERSION7 = typeof MACRO !== "undefined" ? "1.65.10" : "unknown";
706538
706840
  MAX_TOMBSTONE_REWRITE_BYTES = 50 * 1024 * 1024;
706539
706841
  SKIP_FIRST_PROMPT_PATTERN = /^(?:\s*<[a-z][\w-]*[\s>]|\[Request interrupted by user[^\]]*\])/;
706540
706842
  EPHEMERAL_PROGRESS_TYPES = new Set([
@@ -707749,7 +708051,7 @@ var init_filesystem = __esm(() => {
707749
708051
  });
707750
708052
  getBundledSkillsRoot = memoize_default(function getBundledSkillsRoot2() {
707751
708053
  const nonce = randomBytes20(16).toString("hex");
707752
- return join230(getURTempDir(), "bundled-skills", "1.65.9", nonce);
708054
+ return join230(getURTempDir(), "bundled-skills", "1.65.10", nonce);
707753
708055
  });
707754
708056
  getResolvedWorkingDirPaths = memoize_default(getPathsForPermissionCheck);
707755
708057
  });
@@ -713136,7 +713438,7 @@ var CYBER_RISK_INSTRUCTION = `IMPORTANT: Assist with authorized security testing
713136
713438
 
713137
713439
  // src/constants/executionContract.ts
713138
713440
  var EXECUTION_CONTRACT_SECTION = `# Execution contract
713139
- 1. Scope: identify outcome, constraints, dependencies. For 3+ steps, record ordered tasks before implementation; ask only unresolved decisions. Task lists are not plan mode: call ExitPlanMode after EnterPlanMode succeeds.
713441
+ 1. Scope: identify outcome, constraints, dependencies. For 3+ steps, decompose into cohesive, verifiable tasks before implementation; ask only unresolved decisions. Task lists aren't plan mode; ExitPlanMode follows successful EnterPlanMode.
713140
713442
  2. Act: invoke tools through their interface; never substitute printed JSON/XML or commands. Use file tools for edits. Batch independent calls (maximum 8), keep dependencies sequential, inspect every result, update its task, and never emit an empty turn.
713141
713443
  3. Recover: read exact failures; change input, assumptions, or approach. Never repeat an unchanged failure unless external state changed. After three failures on one approach, switch strategy or report the blocker. Distinguish DNS/TLS/auth/rate-limit failures; report external-tool errors honestly.
713142
713444
  4. Verify: run the smallest checks, broader when risk warrants. Match completion claims to successful tool results and observed evidence; state skipped or failing checks.
@@ -713148,21 +713450,26 @@ function getTaskToolGuidance(enabledTools) {
713148
713450
  const canCreate = enabledTools.has(TASK_CREATE_TOOL_NAME);
713149
713451
  const canUpdate = enabledTools.has(TASK_UPDATE_TOOL_NAME);
713150
713452
  const canList = enabledTools.has(TASK_LIST_TOOL_NAME);
713453
+ const canDelegate = enabledTools.has(AGENT_TOOL_NAME);
713454
+ const decomposition = "For non-trivial work, use one task per cohesive outcome with its own observable done check; never hide separately completable deliverables in one omnibus task. Keep genuinely atomic work as one task\u2014do not split by file, tool call, or tiny mechanical step. Make real dependencies explicit and leave unrelated tasks unblocked.";
713455
+ const parallel = canDelegate ? ` If delegating, launch mutually independent tasks through ${AGENT_TOOL_NAME} in parallel only when they have no conflicting shared mutations; keep dependent or conflicting work sequential.` : "";
713151
713456
  if (canCreate && canUpdate) {
713152
- return `Track multi-step work with ${TASK_CREATE_TOOL_NAME} and ${TASK_UPDATE_TOOL_NAME}: create dependency-ordered tasks for the concrete outcomes before implementation; mark one unblocked task in_progress when starting it; mark it completed immediately after implementation and relevant verification succeed; leave blocked or partial work open with its blocker recorded.${canList ? ` Use ${TASK_LIST_TOOL_NAME} to select the next unblocked task.` : ""}`;
713457
+ return `Track multi-step work with ${TASK_CREATE_TOOL_NAME} and ${TASK_UPDATE_TOOL_NAME}. ${decomposition}${parallel} Create the complete dependency graph before implementation; mark each task in_progress when its work starts and completed immediately after its implementation and relevant verification succeed; leave blocked or partial work open with its blocker recorded.${canList ? ` Use ${TASK_LIST_TOOL_NAME} to select the next unblocked task.` : ""}`;
713153
713458
  }
713154
713459
  if (canUpdate) {
713155
713460
  return `Keep assigned tasks current with ${TASK_UPDATE_TOOL_NAME}: mark the task in_progress when starting, completed only after implementation and relevant verification succeed, and leave blocked or partial work open with its blocker recorded.${canList ? ` Use ${TASK_LIST_TOOL_NAME} to select the next unblocked task.` : ""}`;
713156
713461
  }
713157
713462
  if (canCreate) {
713158
- return `For multi-step work, use ${TASK_CREATE_TOOL_NAME} before implementation to record concrete outcomes and their dependency order.`;
713463
+ return `For multi-step work, use ${TASK_CREATE_TOOL_NAME} before implementation. ${decomposition}${parallel}`;
713159
713464
  }
713160
713465
  if (enabledTools.has(TODO_WRITE_TOOL_NAME)) {
713161
- return `Track multi-step work with ${TODO_WRITE_TOOL_NAME}. Keep items dependency-ordered and mark each item completed immediately after its implementation and relevant verification succeed.`;
713466
+ return `Track multi-step work with ${TODO_WRITE_TOOL_NAME}. ${decomposition} Keep items dependency-ordered and mark each item completed immediately after its implementation and relevant verification succeed.`;
713162
713467
  }
713163
713468
  return null;
713164
713469
  }
713165
- var init_taskToolGuidance = () => {};
713470
+ var init_taskToolGuidance = __esm(() => {
713471
+ init_constants2();
713472
+ });
713166
713473
 
713167
713474
  // src/constants/prompts.ts
713168
713475
  import { type as osType2, version as osVersion, release as osRelease2 } from "os";
@@ -714072,7 +714379,7 @@ function computeFingerprint(messageText2, version3) {
714072
714379
  }
714073
714380
  function computeFingerprintFromMessages(messages) {
714074
714381
  const firstMessageText = extractFirstMessageText(messages);
714075
- return computeFingerprint(firstMessageText, "1.65.9");
714382
+ return computeFingerprint(firstMessageText, "1.65.10");
714076
714383
  }
714077
714384
  var FINGERPRINT_SALT = "59cf53e54c78";
714078
714385
  var init_fingerprint = () => {};
@@ -715968,7 +716275,7 @@ async function sideQuery(opts) {
715968
716275
  betas.push(STRUCTURED_OUTPUTS_BETA_HEADER);
715969
716276
  }
715970
716277
  const messageText2 = extractFirstUserMessageText(messages);
715971
- const fingerprint2 = computeFingerprint(messageText2, "1.65.9");
716278
+ const fingerprint2 = computeFingerprint(messageText2, "1.65.10");
715972
716279
  const attributionHeader = getAttributionHeader(fingerprint2);
715973
716280
  const systemBlocks = [
715974
716281
  attributionHeader ? { type: "text", text: attributionHeader } : null,
@@ -720755,7 +721062,7 @@ function buildSystemInitMessage(inputs) {
720755
721062
  slash_commands: inputs.commands.filter((c4) => c4.userInvocable !== false).map((c4) => c4.name),
720756
721063
  apiKeySource: getURHQApiKeyWithSource().source,
720757
721064
  betas: getSdkBetas(),
720758
- ur_version: "1.65.9",
721065
+ ur_version: "1.65.10",
720759
721066
  output_style: outputStyle2,
720760
721067
  agents: inputs.agents.map((agent2) => agent2.agentType),
720761
721068
  skills: inputs.skills.filter((s) => s.userInvocable !== false).map((skill2) => skill2.name),
@@ -728472,9 +728779,8 @@ function ExitPlanModePermissionRequest({
728472
728779
  const transcriptHint = `
728473
728780
 
728474
728781
  If you need specific details from before exiting plan mode (like exact code snippets, error messages, or content you generated), read the full transcript at: ${transcriptPath}`;
728475
- const teamHint = isAgentSwarmsEnabled() ? `
728476
-
728477
- If this plan can be broken down into multiple independent tasks, consider using the ${TEAM_CREATE_TOOL_NAME} tool to create a team and parallelize the work.` : "";
728782
+ const implementationCapabilities = getApprovedPlanCapabilities(toolUseConfirm.toolUseContext);
728783
+ const implementationInstruction = getApprovedPlanImplementationInstruction(implementationCapabilities);
728478
728784
  const feedbackSuffix = acceptFeedback ? `
728479
728785
 
728480
728786
  User feedback on this plan: ${acceptFeedback}` : "";
@@ -728485,7 +728791,9 @@ User feedback on this plan: ${acceptFeedback}` : "";
728485
728791
  ...createUserMessage({
728486
728792
  content: `Implement the following plan:
728487
728793
 
728488
- ${currentPlan}${verificationInstruction}${transcriptHint}${teamHint}${feedbackSuffix}`
728794
+ ${currentPlan}
728795
+
728796
+ ${implementationInstruction}${verificationInstruction}${transcriptHint}${feedbackSuffix}`
728489
728797
  }),
728490
728798
  planContent: currentPlan
728491
728799
  },
@@ -728939,6 +729247,7 @@ var import_react211, jsx_dev_runtime374;
728939
729247
  var init_ExitPlanModePermissionRequest = __esm(() => {
728940
729248
  init_figures();
728941
729249
  init_notifications();
729250
+ init_planImplementationContract();
728942
729251
  init_analytics();
728943
729252
  init_AppState();
728944
729253
  init_state();
@@ -728946,7 +729255,6 @@ var init_ExitPlanModePermissionRequest = __esm(() => {
728946
729255
  init_ultraplan();
728947
729256
  init_ink2();
728948
729257
  init_constants2();
728949
- init_agentSwarmsEnabled();
728950
729258
  init_context();
728951
729259
  init_editor();
728952
729260
  init_file();
@@ -734615,7 +734923,7 @@ var init_useVoiceEnabled = __esm(() => {
734615
734923
  function getSemverPart(version3) {
734616
734924
  return `${import_semver13.major(version3, { loose: true })}.${import_semver13.minor(version3, { loose: true })}.${import_semver13.patch(version3, { loose: true })}`;
734617
734925
  }
734618
- function useUpdateNotification(updatedVersion, initialVersion = "1.65.9") {
734926
+ function useUpdateNotification(updatedVersion, initialVersion = "1.65.10") {
734619
734927
  const [lastNotifiedSemver, setLastNotifiedSemver] = import_react222.useState(() => getSemverPart(initialVersion));
734620
734928
  if (!updatedVersion) {
734621
734929
  return null;
@@ -734664,7 +734972,7 @@ function AutoUpdater({
734664
734972
  return;
734665
734973
  }
734666
734974
  if (false) {}
734667
- const currentVersion = "1.65.9";
734975
+ const currentVersion = "1.65.10";
734668
734976
  const channel = getInitialSettings()?.autoUpdatesChannel ?? "latest";
734669
734977
  let latestVersion = await getLatestVersion(channel);
734670
734978
  const isDisabled = isAutoUpdaterDisabled();
@@ -734893,12 +735201,12 @@ function NativeAutoUpdater({
734893
735201
  logEvent("tengu_native_auto_updater_start", {});
734894
735202
  try {
734895
735203
  const maxVersion = await getMaxVersion();
734896
- if (maxVersion && gt("1.65.9", maxVersion)) {
735204
+ if (maxVersion && gt("1.65.10", maxVersion)) {
734897
735205
  const msg = await getMaxVersionMessage();
734898
735206
  setMaxVersionIssue(msg ?? "affects your version");
734899
735207
  }
734900
735208
  const result = await installLatest(channel);
734901
- const currentVersion = "1.65.9";
735209
+ const currentVersion = "1.65.10";
734902
735210
  const latencyMs = Date.now() - startTime;
734903
735211
  if (result.lockFailed) {
734904
735212
  logEvent("tengu_native_auto_updater_lock_contention", {
@@ -735035,17 +735343,17 @@ function PackageManagerAutoUpdater(t0) {
735035
735343
  const maxVersion = await getMaxVersion();
735036
735344
  if (maxVersion && latest && gt(latest, maxVersion)) {
735037
735345
  logForDebugging(`PackageManagerAutoUpdater: maxVersion ${maxVersion} is set, capping update from ${latest} to ${maxVersion}`);
735038
- if (gte("1.65.9", maxVersion)) {
735039
- logForDebugging(`PackageManagerAutoUpdater: current version ${"1.65.9"} is already at or above maxVersion ${maxVersion}, skipping update`);
735346
+ if (gte("1.65.10", maxVersion)) {
735347
+ logForDebugging(`PackageManagerAutoUpdater: current version ${"1.65.10"} is already at or above maxVersion ${maxVersion}, skipping update`);
735040
735348
  setUpdateAvailable(false);
735041
735349
  return;
735042
735350
  }
735043
735351
  latest = maxVersion;
735044
735352
  }
735045
- const hasUpdate = latest && !gte("1.65.9", latest) && !shouldSkipVersion(latest);
735353
+ const hasUpdate = latest && !gte("1.65.10", latest) && !shouldSkipVersion(latest);
735046
735354
  setUpdateAvailable(!!hasUpdate);
735047
735355
  if (hasUpdate) {
735048
- logForDebugging(`PackageManagerAutoUpdater: Update available ${"1.65.9"} -> ${latest}`);
735356
+ logForDebugging(`PackageManagerAutoUpdater: Update available ${"1.65.10"} -> ${latest}`);
735049
735357
  }
735050
735358
  };
735051
735359
  $2[0] = t1;
@@ -735079,7 +735387,7 @@ function PackageManagerAutoUpdater(t0) {
735079
735387
  wrap: "truncate",
735080
735388
  children: [
735081
735389
  "currentVersion: ",
735082
- "1.65.9"
735390
+ "1.65.10"
735083
735391
  ]
735084
735392
  }, undefined, true, undefined, this);
735085
735393
  $2[3] = verbose;
@@ -745799,7 +746107,7 @@ function buildStatusLineCommandInput(permissionMode, exceeds200kTokens, settings
745799
746107
  project_dir: getOriginalCwd(),
745800
746108
  added_dirs: addedDirs
745801
746109
  },
745802
- version: "1.65.9",
746110
+ version: "1.65.10",
745803
746111
  output_style: {
745804
746112
  name: outputStyleName
745805
746113
  },
@@ -745877,7 +746185,7 @@ function StatusLineInner({
745877
746185
  const taskValues = Object.values(tasks2);
745878
746186
  const taskRunningCount = countActiveBackgroundTasks(taskValues);
745879
746187
  const defaultStatusLineText = buildDefaultStatusBar({
745880
- version: "1.65.9",
746188
+ version: "1.65.10",
745881
746189
  providerLabel: providerRuntime.providerLabel,
745882
746190
  authMode: providerRuntime.authLabel,
745883
746191
  model: renderModelName(mainLoopModel) || providerRuntime.model || "",
@@ -758057,7 +758365,7 @@ async function submitTranscriptShare(messages, trigger2, appearanceId) {
758057
758365
  } catch {}
758058
758366
  const data = {
758059
758367
  trigger: trigger2,
758060
- version: "1.65.9",
758368
+ version: "1.65.10",
758061
758369
  platform: process.platform,
758062
758370
  transcript,
758063
758371
  subagentTranscripts: Object.keys(subagentTranscripts).length > 0 ? subagentTranscripts : undefined,
@@ -770422,7 +770730,7 @@ function WelcomeV2() {
770422
770730
  dimColor: true,
770423
770731
  children: [
770424
770732
  "v",
770425
- "1.65.9"
770733
+ "1.65.10"
770426
770734
  ]
770427
770735
  }, undefined, true, undefined, this)
770428
770736
  ]
@@ -771682,7 +771990,7 @@ function completeOnboarding() {
771682
771990
  saveGlobalConfig((current) => ({
771683
771991
  ...current,
771684
771992
  hasCompletedOnboarding: true,
771685
- lastOnboardingVersion: "1.65.9"
771993
+ lastOnboardingVersion: "1.65.10"
771686
771994
  }));
771687
771995
  }
771688
771996
  function showDialog(root2, renderer) {
@@ -776726,7 +777034,7 @@ function appendToLog(path24, message) {
776726
777034
  cwd: getFsImplementation().cwd(),
776727
777035
  userType: process.env.USER_TYPE,
776728
777036
  sessionId: getSessionId(),
776729
- version: "1.65.9"
777037
+ version: "1.65.10"
776730
777038
  };
776731
777039
  getLogWriter(path24).write(messageWithTimestamp);
776732
777040
  }
@@ -780890,8 +781198,8 @@ async function getEnvLessBridgeConfig() {
780890
781198
  }
780891
781199
  async function checkEnvLessBridgeMinVersion() {
780892
781200
  const cfg = await getEnvLessBridgeConfig();
780893
- if (cfg.min_version && lt("1.65.9", cfg.min_version)) {
780894
- return `Your version of UR (${"1.65.9"}) is too old for Remote Control.
781201
+ if (cfg.min_version && lt("1.65.10", cfg.min_version)) {
781202
+ return `Your version of UR (${"1.65.10"}) is too old for Remote Control.
780895
781203
  Version ${cfg.min_version} or higher is required. Run \`ur update\` to update.`;
780896
781204
  }
780897
781205
  return null;
@@ -781365,7 +781673,7 @@ async function initBridgeCore(params) {
781365
781673
  const rawApi = createBridgeApiClient({
781366
781674
  baseUrl,
781367
781675
  getAccessToken,
781368
- runnerVersion: "1.65.9",
781676
+ runnerVersion: "1.65.10",
781369
781677
  onDebug: logForDebugging,
781370
781678
  onAuth401,
781371
781679
  getTrustedDeviceToken
@@ -790838,7 +791146,7 @@ function getAgUiCapabilities() {
790838
791146
  name: "UR-Nexus",
790839
791147
  type: "ur-nexus",
790840
791148
  description: "Provider-flexible, local-first autonomous engineering workflow agent.",
790841
- version: "1.65.9",
791149
+ version: "1.65.10",
790842
791150
  provider: "UR",
790843
791151
  documentationUrl: "https://github.com/Maitham16/UR/blob/master/docs/AG_UI.md"
790844
791152
  },
@@ -791978,7 +792286,7 @@ function createMCPServer(cwd4, debug2, verbose) {
791978
792286
  };
791979
792287
  const server2 = new Server({
791980
792288
  name: "ur-nexus",
791981
- version: "1.65.9"
792289
+ version: "1.65.10"
791982
792290
  }, {
791983
792291
  capabilities: {
791984
792292
  tools: {}
@@ -793136,7 +793444,7 @@ function thrownResponse(error40) {
793136
793444
  }
793137
793445
  async function createUrMcp2026Runtime(options4) {
793138
793446
  const server2 = createMCPServer(options4.cwd, options4.debug === true, options4.verbose === true);
793139
- const client2 = new Client({ name: "ur-mcp-2026-adapter", version: "1.65.9" }, { capabilities: {} });
793447
+ const client2 = new Client({ name: "ur-mcp-2026-adapter", version: "1.65.10" }, { capabilities: {} });
793140
793448
  const [clientTransport, serverTransport] = createLinkedTransportPair();
793141
793449
  try {
793142
793450
  await server2.connect(serverTransport);
@@ -793147,7 +793455,7 @@ async function createUrMcp2026Runtime(options4) {
793147
793455
  }
793148
793456
  const runtime2 = new Mcp2026Runtime({
793149
793457
  cwd: options4.cwd,
793150
- version: "1.65.9",
793458
+ version: "1.65.10",
793151
793459
  backend: {
793152
793460
  listTools: async () => {
793153
793461
  const listed = await client2.listTools();
@@ -795280,7 +795588,7 @@ async function update() {
795280
795588
  logEvent("tengu_update_check", {});
795281
795589
  const diagnostic2 = await getDoctorDiagnostic();
795282
795590
  const result = await checkUpgradeStatus({
795283
- currentVersion: "1.65.9",
795591
+ currentVersion: "1.65.10",
795284
795592
  packageName: UR_AGENT_PACKAGE_NAME,
795285
795593
  installationType: diagnostic2.installationType,
795286
795594
  latestVersion: () => getLatestNpmPackageVersion(UR_AGENT_PACKAGE_NAME)
@@ -796596,7 +796904,7 @@ ${customInstructions}` : customInstructions;
796596
796904
  }
796597
796905
  }
796598
796906
  logForDiagnosticsNoPII("info", "started", {
796599
- version: "1.65.9",
796907
+ version: "1.65.10",
796600
796908
  is_native_binary: isInBundledMode()
796601
796909
  });
796602
796910
  registerCleanup(async () => {
@@ -797382,7 +797690,7 @@ Usage: ur --remote "your task description"`, () => gracefulShutdown(1));
797382
797690
  pendingHookMessages
797383
797691
  }, renderAndRun);
797384
797692
  }
797385
- }).version("1.65.9 (UR-Nexus)", "-v, --version", "Output the version number");
797693
+ }).version("1.65.10 (UR-Nexus)", "-v, --version", "Output the version number");
797386
797694
  program2.option("-w, --worktree [name]", "Create a new git worktree for this session (optionally specify a name)");
797387
797695
  program2.option("--tmux", "Create a tmux session for the worktree (requires --worktree). Uses iTerm2 native panes when available; use --tmux=classic for traditional tmux.");
797388
797696
  if (canUserConfigureAdvisor()) {
@@ -798441,7 +798749,7 @@ if (false) {}
798441
798749
  async function main2() {
798442
798750
  const args = process.argv.slice(2);
798443
798751
  if (args.length === 1 && (args[0] === "--version" || args[0] === "-v" || args[0] === "-V")) {
798444
- console.log(`${"1.65.9"} (UR-Nexus)`);
798752
+ console.log(`${"1.65.10"} (UR-Nexus)`);
798445
798753
  return;
798446
798754
  }
798447
798755
  if (args[0] === "a2a" && args[1] === "serve" && !args.includes("--help") && !args.includes("-h")) {