@adhdev/daemon-core 0.9.82-rc.320 → 0.9.82-rc.321

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/index.d.ts CHANGED
@@ -7,8 +7,8 @@ export type { ChatBubbleState, ChatMessage, ExtensionInfo, CommandResult as Core
7
7
  export type { SessionEntry, CompactSessionEntry, CompactDaemonEntry, CloudDaemonSummaryEntry, DashboardBootstrapDaemonEntry, VersionUpdateReason, CloudStatusReportPayload, DaemonStatusEventPayload, DashboardStatusEventPayload, SessionTransport, SessionKind, SessionCapability, AgentSessionStream, ReadChatCursor, ReadChatSyncResult, TransportTopic, SessionChatTailSubscriptionParams, SessionRuntimeOutputSubscriptionParams, MachineRuntimeSubscriptionParams, SessionHostDiagnosticsSubscriptionParams, SessionModalSubscriptionParams, DaemonMetadataSubscriptionParams, WorkspaceGitSubscriptionParams, SessionChatTailUpdate, MachineRuntimeUpdate, SessionHostDiagnosticsUpdate, SessionModalUpdate, DaemonMetadataUpdate, TopicUpdateEnvelope, SubscribeRequest, UnsubscribeRequest, StandaloneWsStatusPayload, AvailableProviderInfo, AcpConfigOption, AcpMode, ProviderControlSchema, StatusReportPayload, MachineInfo, SessionHostDiagnosticsSnapshot, SessionHostRecord, SessionHostWriteOwner, SessionHostAttachedClient, SessionHostLogEntry, SessionHostRequestTrace, SessionHostRuntimeTransition, DetectedIdeInfo, WorkspaceEntry, ProviderSummaryItem, ProviderSummaryMetadata, ProviderState, ProviderStatus, ProviderErrorReason, SessionActiveChatData, ActiveChatData, IdeProviderState, CliProviderState, AcpProviderState, ExtensionProviderState, MessageInputSupport, InputMediaStrategyDescriptor, InputAttachmentStrategy, InputMediaType, } from './shared-types.js';
8
8
  export type { InteractivePrompt, InteractiveQuestion, InteractiveOption, InteractivePromptResponse, InteractiveAnswer, } from './providers/types/interactive-prompt.js';
9
9
  export { normalizeInteractivePrompt, normalizeInteractivePromptResponse, buildClaudeInteractiveToolResult, interactivePromptFromClaudeAskUserQuestion, detectClaudeAskUserQuestionPromptFromJson, } from './providers/types/interactive-prompt.js';
10
- export type { RepoMesh, RepoMeshDaemonRole, RepoMeshHostMetadata, RepoMeshHostPairingMetadata, RepoMeshHostStatus, RepoMeshNode, RepoMeshNodeHealth, RepoMeshPolicy, RepoMeshNodePolicy, RepoMeshRelatedRepo, RepoMeshNodeCapabilities, DetectedCommand, ProjectContextSnapshot, ProjectContextSource, RepoMeshCoordinatorConfig, LocalMeshConfig, LocalMeshEntry, LocalMeshNodeEntry, RepoMeshStatus, RepoMeshNodeStatus, RepoMeshPeerConnectionStatus, RepoMeshPeerConnectionState, RepoMeshPeerConnectionTransport, RepoMeshSessionStatus, RepoMeshQueueTask, RepoMeshQueueTaskStatus, RepoMeshQueueSummary, RepoMeshQueueStatus, RepoMeshLedgerEntryStatus, RepoMeshLedgerSummaryStatus, RepoMeshLedgerStatus, MeshAsyncJobLifecycle, RepoMeshSchedulingStrategy, RepoMeshTaskAffinityPolicy, StandardMeshRole, } from './repo-mesh-types.js';
11
- export { DEFAULT_MESH_POLICY, resolveDelegatedWorkerAutoApprove, MESH_SCHEDULING_STRATEGIES, DEFAULT_MESH_SCHEDULING_STRATEGY, normalizeMeshSchedulingStrategy, resolveNodeSchedulingPriority, MESH_CONVERGE_REFINE_TAG, MESH_CONVERGE_FAST_FORWARD_TAG, resolveAutoConvergeCodeChange, STANDARD_MESH_ROLES, DEFAULT_TASKMODE_ROLE_MAP, resolveTaskAffinityRole, resolveMeshRoleOptions, } from './repo-mesh-types.js';
10
+ export type { RepoMesh, RepoMeshDaemonRole, RepoMeshHostMetadata, RepoMeshHostPairingMetadata, RepoMeshHostStatus, RepoMeshNode, RepoMeshNodeHealth, RepoMeshPolicy, RepoMeshNodePolicy, RepoMeshRelatedRepo, RepoMeshNodeCapabilities, DetectedCommand, ProjectContextSnapshot, ProjectContextSource, RepoMeshCoordinatorConfig, LocalMeshConfig, LocalMeshEntry, LocalMeshNodeEntry, RepoMeshStatus, RepoMeshNodeStatus, RepoMeshPeerConnectionStatus, RepoMeshPeerConnectionState, RepoMeshPeerConnectionTransport, RepoMeshSessionStatus, RepoMeshQueueTask, RepoMeshQueueTaskStatus, RepoMeshQueueSummary, RepoMeshQueueStatus, RepoMeshLedgerEntryStatus, RepoMeshLedgerSummaryStatus, RepoMeshLedgerStatus, MeshAsyncJobLifecycle, RepoMeshSchedulingStrategy, } from './repo-mesh-types.js';
11
+ export { DEFAULT_MESH_POLICY, resolveDelegatedWorkerAutoApprove, MESH_SCHEDULING_STRATEGIES, DEFAULT_MESH_SCHEDULING_STRATEGY, normalizeMeshSchedulingStrategy, resolveNodeSchedulingPriority, MESH_CONVERGE_REFINE_TAG, MESH_CONVERGE_FAST_FORWARD_TAG, resolveAutoConvergeCodeChange, } from './repo-mesh-types.js';
12
12
  export * from './git/index.js';
13
13
  import type { RuntimeWriteOwner as _RuntimeWriteOwner } from './shared-types-extra.js';
14
14
  import type { RuntimeAttachedClient as _RuntimeAttachedClient } from './shared-types-extra.js';
@@ -49,7 +49,7 @@ export { fastForwardMeshNode } from './mesh/mesh-fast-forward.js';
49
49
  export type { MeshFastForwardNodeArgs, MeshFastForwardPlannedStep, MeshFastForwardResult } from './mesh/mesh-fast-forward.js';
50
50
  export { buildMeshLedgerReconciliationEvidence, buildMeshLedgerReplicaEvidence } from './mesh/mesh-ledger-reconciliation.js';
51
51
  export type { AnyLedgerSlice, MeshLedgerReconciliationEvidence, MeshLedgerReplicaEvidence, MeshLedgerReplicaStatus } from './mesh/mesh-ledger-reconciliation.js';
52
- export { enqueueTask, recordDirectDispatchTask, getQueue, claimNextTask, updateTaskStatus, updateSessionTaskStatus, cancelTask, requeueTask, getMeshQueueStats, getMeshQueueRevision, normalizeMeshTaskMode, validateMeshTaskModeRequest, buildMeshNodeCapabilityTags, nodeSatisfiesRequiredTags, normalizeMeshCapabilityTags, resolveConvergeRequiredTags, resolveTaskAffinityRequiredTags, insertDirectDispatch, getActiveDirectDispatches, updateDirectDispatchStatus, cleanupTerminalDirectDispatches, markStaleDirectDispatches, deleteDirectDispatchesByTaskId, recordMeshToolCall, assertNoDependencyCycle, hasPendingDependents, describeTaskDependencyState } from './mesh/mesh-work-queue.js';
52
+ export { enqueueTask, recordDirectDispatchTask, getQueue, claimNextTask, updateTaskStatus, updateSessionTaskStatus, cancelTask, requeueTask, getMeshQueueStats, getMeshQueueRevision, normalizeMeshTaskMode, validateMeshTaskModeRequest, buildMeshNodeCapabilityTags, nodeSatisfiesRequiredTags, normalizeMeshCapabilityTags, resolveConvergeRequiredTags, insertDirectDispatch, getActiveDirectDispatches, updateDirectDispatchStatus, cleanupTerminalDirectDispatches, markStaleDirectDispatches, deleteDirectDispatchesByTaskId, recordMeshToolCall, assertNoDependencyCycle, hasPendingDependents, describeTaskDependencyState } from './mesh/mesh-work-queue.js';
53
53
  export type { MeshWorkQueueEntry, MeshTaskStatus, MeshTaskMode, MeshWorkQueueStats, MeshQueueMutationOptions, MeshTaskModeValidationResult, DirectDispatchRecord, MeshToolCallRateResult } from './mesh/mesh-work-queue.js';
54
54
  export { buildCompactStaleDirectWorkSummary, buildMeshActiveWork, buildMeshActiveWorkSummary, classifyStaleDirectForPrune, PRUNABLE_ORPHAN_STALE_REASONS } from './mesh/mesh-active-work.js';
55
55
  export type { StaleDirectPruneClassification } from './mesh/mesh-active-work.js';
package/dist/index.js CHANGED
@@ -40,35 +40,6 @@ function resolveNodeSchedulingPriority(nodePolicy) {
40
40
  const raw = Number(nodePolicy?.schedulingPriority);
41
41
  return Number.isFinite(raw) ? raw : 0;
42
42
  }
43
- function resolveTaskAffinityRole(taskMode, policy) {
44
- if (!taskMode) return null;
45
- if (policy?.enabled === false) return null;
46
- const override = policy?.byTaskMode && Object.prototype.hasOwnProperty.call(policy.byTaskMode, taskMode) ? policy.byTaskMode[taskMode] : void 0;
47
- if (typeof override === "string") {
48
- const trimmed = override.trim().toLowerCase();
49
- return trimmed ? trimmed : null;
50
- }
51
- const fallback = DEFAULT_TASKMODE_ROLE_MAP[taskMode];
52
- return fallback ?? null;
53
- }
54
- function resolveMeshRoleOptions(policy) {
55
- const out = [...STANDARD_MESH_ROLES];
56
- const seen = new Set(out);
57
- const add = (raw) => {
58
- if (typeof raw !== "string") return;
59
- const role = raw.trim().toLowerCase();
60
- if (!role || seen.has(role)) return;
61
- seen.add(role);
62
- out.push(role);
63
- };
64
- if (policy?.byTaskMode) {
65
- for (const value of Object.values(policy.byTaskMode)) add(value);
66
- }
67
- if (Array.isArray(policy?.customRoles)) {
68
- for (const value of policy.customRoles) add(value);
69
- }
70
- return out;
71
- }
72
43
  function resolveAutoConvergeCodeChange(policy) {
73
44
  return policy?.autoConvergeCodeChange === true;
74
45
  }
@@ -81,7 +52,7 @@ function resolveDelegatedWorkerAutoApprove(meshPolicy, nodePolicy) {
81
52
  }
82
53
  return true;
83
54
  }
84
- function resolveProviderRole(nodePolicy, providerType) {
55
+ function resolveProviderMaxParallel(nodePolicy, providerType) {
85
56
  const wanted = typeof providerType === "string" ? providerType.trim().toLowerCase() : "";
86
57
  if (!wanted) return void 0;
87
58
  const roles = nodePolicy?.providerRoles;
@@ -89,17 +60,14 @@ function resolveProviderRole(nodePolicy, providerType) {
89
60
  for (const entry of roles) {
90
61
  if (!entry || typeof entry !== "object") continue;
91
62
  const type = typeof entry.providerType === "string" ? entry.providerType.trim().toLowerCase() : "";
92
- if (type && type === wanted) return entry;
63
+ if (!type || type !== wanted) continue;
64
+ const raw = Number(entry.maxParallel);
65
+ if (!Number.isFinite(raw) || raw < 0) return void 0;
66
+ return Math.floor(raw);
93
67
  }
94
68
  return void 0;
95
69
  }
96
- function resolveProviderMaxParallel(nodePolicy, providerType) {
97
- const role = resolveProviderRole(nodePolicy, providerType);
98
- const raw = Number(role?.maxParallel);
99
- if (!Number.isFinite(raw) || raw < 0) return void 0;
100
- return Math.floor(raw);
101
- }
102
- var MESH_SCHEDULING_STRATEGIES, DEFAULT_MESH_SCHEDULING_STRATEGY, MESH_CONVERGE_REFINE_TAG, MESH_CONVERGE_FAST_FORWARD_TAG, STANDARD_MESH_ROLES, DEFAULT_TASKMODE_ROLE_MAP, DEFAULT_MESH_POLICY;
70
+ var MESH_SCHEDULING_STRATEGIES, DEFAULT_MESH_SCHEDULING_STRATEGY, MESH_CONVERGE_REFINE_TAG, MESH_CONVERGE_FAST_FORWARD_TAG, DEFAULT_MESH_POLICY;
103
71
  var init_repo_mesh_types = __esm({
104
72
  "src/repo-mesh-types.ts"() {
105
73
  "use strict";
@@ -112,14 +80,6 @@ var init_repo_mesh_types = __esm({
112
80
  DEFAULT_MESH_SCHEDULING_STRATEGY = "first_eligible";
113
81
  MESH_CONVERGE_REFINE_TAG = "converge=refine";
114
82
  MESH_CONVERGE_FAST_FORWARD_TAG = "converge=fast_forward";
115
- STANDARD_MESH_ROLES = ["investigator", "coder", "validator", "converger"];
116
- DEFAULT_TASKMODE_ROLE_MAP = {
117
- live_debug_readonly: "investigator",
118
- code_change: "coder",
119
- launch_app: "coder",
120
- validation: "validator",
121
- convergence: "converger"
122
- };
123
83
  DEFAULT_MESH_POLICY = {
124
84
  requirePreTaskCheckpoint: false,
125
85
  requirePostTaskCheckpoint: true,
@@ -353,10 +313,10 @@ function readInjected(value) {
353
313
  }
354
314
  function getDaemonBuildInfo() {
355
315
  if (cached) return cached;
356
- const commit = readInjected(true ? "bbaf30f95c09531cec77fb48a8cf6d38b3b6d7f9" : void 0) ?? "unknown";
357
- const commitShort = readInjected(true ? "bbaf30f9" : void 0) ?? (commit !== "unknown" ? commit.slice(0, 7) : "unknown");
358
- const version = readInjected(true ? "0.9.82-rc.320" : void 0) ?? readInjected(typeof process !== "undefined" ? process.env?.ADHDEV_PKG_VERSION : void 0) ?? "unknown";
359
- const builtAt = readInjected(true ? "2026-06-19T01:16:38.511Z" : void 0);
316
+ const commit = readInjected(true ? "d41c5687bc8d6f8a7c7f7ffeb3faac5801f146f1" : void 0) ?? "unknown";
317
+ const commitShort = readInjected(true ? "d41c5687" : void 0) ?? (commit !== "unknown" ? commit.slice(0, 7) : "unknown");
318
+ const version = readInjected(true ? "0.9.82-rc.321" : void 0) ?? readInjected(typeof process !== "undefined" ? process.env?.ADHDEV_PKG_VERSION : void 0) ?? "unknown";
319
+ const builtAt = readInjected(true ? "2026-06-19T03:20:44.153Z" : void 0);
360
320
  cached = builtAt ? { commit, commitShort, version, builtAt } : { commit, commitShort, version };
361
321
  return cached;
362
322
  }
@@ -1657,61 +1617,8 @@ function mergeMeshPolicy(base, patch) {
1657
1617
  } else {
1658
1618
  delete policy.autoConvergeCodeChange;
1659
1619
  }
1660
- const normalizedAffinity = normalizeTaskAffinityPolicy(policy.taskAffinity);
1661
- if (normalizedAffinity) {
1662
- policy.taskAffinity = normalizedAffinity;
1663
- } else {
1664
- delete policy.taskAffinity;
1665
- }
1666
1620
  return policy;
1667
1621
  }
1668
- function normalizeTaskAffinityPolicy(value) {
1669
- if (!value || typeof value !== "object" || Array.isArray(value)) return void 0;
1670
- const record = value;
1671
- const out = {};
1672
- let hasContent = false;
1673
- if (typeof record.enabled === "boolean") {
1674
- out.enabled = record.enabled;
1675
- if (record.enabled === false) hasContent = true;
1676
- else delete out.enabled;
1677
- }
1678
- if (record.byTaskMode && typeof record.byTaskMode === "object" && !Array.isArray(record.byTaskMode)) {
1679
- const byTaskMode = {};
1680
- for (const [mode, raw] of Object.entries(record.byTaskMode)) {
1681
- const modeKey = mode.trim();
1682
- if (!modeKey) continue;
1683
- if (typeof raw !== "string") continue;
1684
- const role = raw.trim().toLowerCase();
1685
- byTaskMode[modeKey] = role;
1686
- if (role && !STANDARD_MESH_ROLES.includes(role)) {
1687
- try {
1688
- console.warn(`[mesh] task_affinity.byTaskMode.${modeKey}: custom role "${role}" is not a standard mesh role (${STANDARD_MESH_ROLES.join("/")}); routing still applies`);
1689
- } catch {
1690
- }
1691
- }
1692
- }
1693
- if (Object.keys(byTaskMode).length > 0) {
1694
- out.byTaskMode = byTaskMode;
1695
- hasContent = true;
1696
- }
1697
- }
1698
- if (Array.isArray(record.customRoles)) {
1699
- const seen = /* @__PURE__ */ new Set();
1700
- const customRoles = [];
1701
- for (const raw of record.customRoles) {
1702
- if (typeof raw !== "string") continue;
1703
- const role = raw.trim().toLowerCase();
1704
- if (!role || seen.has(role)) continue;
1705
- seen.add(role);
1706
- customRoles.push(role);
1707
- }
1708
- if (customRoles.length > 0) {
1709
- out.customRoles = customRoles;
1710
- hasContent = true;
1711
- }
1712
- }
1713
- return hasContent ? out : void 0;
1714
- }
1715
1622
  function normalizeAutoFastForwardPolicy(value) {
1716
1623
  const record = value && typeof value === "object" && !Array.isArray(value) ? value : {};
1717
1624
  const maxBehind = Number(record.maxBehind);
@@ -2168,11 +2075,10 @@ function buildNodeConfigSection(mesh) {
2168
2075
  const providerRoles = Array.isArray(n.policy?.providerRoles) ? n.policy.providerRoles.map((r) => {
2169
2076
  const type = typeof r?.providerType === "string" ? r.providerType.trim() : "";
2170
2077
  if (!type) return "";
2171
- const role = typeof r?.role === "string" && r.role.trim() ? `=${r.role.trim()}` : "";
2172
2078
  const cap = Number.isFinite(Number(r?.maxParallel)) ? ` (max ${Math.floor(Number(r.maxParallel))})` : "";
2173
- return `${type}${role}${cap}`;
2079
+ return `${type}${cap}`;
2174
2080
  }).filter(Boolean) : [];
2175
- const providerRolesSuffix = providerRoles.length ? ` | roles: ${providerRoles.join(", ")}` : "";
2081
+ const providerRolesSuffix = providerRoles.length ? ` | caps: ${providerRoles.join(", ")}` : "";
2176
2082
  lines.push(`- ${explicitLabel} nodeId: \`${n.id}\` | workspace: \`${n.workspace}\`${n.daemonId ? ` | daemon: \`${n.daemonId}\`` : ""}${providerPriority}${providerRolesSuffix}${suffix}`);
2177
2083
  const nodePrompt = typeof n.systemPrompt === "string" ? n.systemPrompt.trim() : "";
2178
2084
  if (nodePrompt) {
@@ -3005,7 +2911,6 @@ __export(mesh_work_queue_exports, {
3005
2911
  recordTaskAutoLaunch: () => recordTaskAutoLaunch,
3006
2912
  requeueTask: () => requeueTask,
3007
2913
  resolveConvergeRequiredTags: () => resolveConvergeRequiredTags,
3008
- resolveTaskAffinityRequiredTags: () => resolveTaskAffinityRequiredTags,
3009
2914
  updateDirectDispatchStatus: () => updateDirectDispatchStatus,
3010
2915
  updateSessionTaskStatus: () => updateSessionTaskStatus,
3011
2916
  updateTaskStatus: () => updateTaskStatus,
@@ -3079,21 +2984,6 @@ function firstProviderPriority(policy) {
3079
2984
  if (!Array.isArray(raw)) return void 0;
3080
2985
  return raw.find((type) => typeof type === "string" && type.trim())?.trim();
3081
2986
  }
3082
- function roleCapabilityTags(policy, providerType) {
3083
- const roles = policy && typeof policy === "object" && !Array.isArray(policy) ? policy.providerRoles : void 0;
3084
- if (!Array.isArray(roles)) return [];
3085
- const wantedProvider = typeof providerType === "string" && providerType.trim() ? providerType.trim().toLowerCase() : "";
3086
- const out = [];
3087
- for (const entry of roles) {
3088
- if (!entry || typeof entry !== "object") continue;
3089
- const type = typeof entry.providerType === "string" ? entry.providerType.trim().toLowerCase() : "";
3090
- const role = typeof entry.role === "string" ? entry.role.trim().toLowerCase() : "";
3091
- if (!role) continue;
3092
- if (wantedProvider && type && type !== wantedProvider) continue;
3093
- out.push(`role=${role}`);
3094
- }
3095
- return out;
3096
- }
3097
2987
  function buildMeshNodeCapabilityTags(node, providerType) {
3098
2988
  const provider = typeof providerType === "string" && providerType.trim() ? providerType.trim() : firstProviderPriority(node?.policy);
3099
2989
  const worktreeBranch = typeof node?.worktreeBranch === "string" && node.worktreeBranch.trim() ? node.worktreeBranch.trim() : null;
@@ -3116,14 +3006,7 @@ function buildMeshNodeCapabilityTags(node, providerType) {
3116
3006
  // receives the task instead). Reuses the ordinary required-tags filter —
3117
3007
  // the load-balancing scheduler auto-injects converge=refine for code_change
3118
3008
  // so such work is hard-filtered onto refine-capable nodes.
3119
- ...node?.isLocalWorktree === true ? ["converge=refine"] : ["converge=fast_forward"],
3120
- // Role-based routing: advertise role=<x> for each (node, provider) role
3121
- // declared in policy.providerRoles. Narrowed to the selected provider when
3122
- // one is given so the chosen provider must match a task's required role;
3123
- // when no provider is selected, all declared roles are advertised for the
3124
- // node-level eligibility scan. Reuses the ordinary required-tags filter —
3125
- // no separate role field/gate.
3126
- ...roleCapabilityTags(node?.policy, providerType)
3009
+ ...node?.isLocalWorktree === true ? ["converge=refine"] : ["converge=fast_forward"]
3127
3010
  ]);
3128
3011
  }
3129
3012
  function nodeSatisfiesRequiredTags(requiredTags, capabilityTags) {
@@ -3144,31 +3027,6 @@ function resolveConvergeRequiredTags(meshId, taskMode, explicitRequiredTags, opt
3144
3027
  if (!optedIn) return explicitRequiredTags;
3145
3028
  return normalizeMeshCapabilityTags([...explicitRequiredTags, MESH_CONVERGE_REFINE_TAG]);
3146
3029
  }
3147
- function meshHasNodeAdvertisingRole(nodes, role) {
3148
- if (!Array.isArray(nodes) || nodes.length === 0) return false;
3149
- const wanted = `role=${role}`;
3150
- return nodes.some((node) => buildMeshNodeCapabilityTags(node).includes(wanted));
3151
- }
3152
- function resolveTaskAffinityRequiredTags(meshId, taskMode, explicitRequiredTags, opts) {
3153
- if (typeof opts?.targetNodeId === "string" && opts.targetNodeId.trim()) return explicitRequiredTags;
3154
- if (opts?.callerSpecifiedRequiredTags === true) return explicitRequiredTags;
3155
- let mesh;
3156
- try {
3157
- mesh = getMesh(meshId);
3158
- } catch {
3159
- return explicitRequiredTags;
3160
- }
3161
- const role = resolveTaskAffinityRole(taskMode, mesh?.policy?.taskAffinity);
3162
- if (!role) return explicitRequiredTags;
3163
- if (!meshHasNodeAdvertisingRole(mesh?.nodes, role)) {
3164
- try {
3165
- console.warn(`[mesh] task_affinity: no node advertises role=${role} for taskMode=${taskMode} in mesh ${meshId}; skipping injection (least_loaded fallback)`);
3166
- } catch {
3167
- }
3168
- return explicitRequiredTags;
3169
- }
3170
- return normalizeMeshCapabilityTags([...explicitRequiredTags, `role=${role}`]);
3171
- }
3172
3030
  function withQueueLock(_meshId, fn) {
3173
3031
  return MeshRuntimeStore.getInstance().transaction(fn);
3174
3032
  }
@@ -3220,19 +3078,12 @@ function enqueueTask(meshId, message, opts) {
3220
3078
  }
3221
3079
  assertNoDependencyCycle(meshId, id, dependsOn);
3222
3080
  const callerTags = normalizeMeshCapabilityTags(opts?.requiredTags);
3223
- const callerSpecifiedRequiredTags = callerTags.length > 0;
3224
- let resolvedRequiredTags = resolveConvergeRequiredTags(
3081
+ const resolvedRequiredTags = resolveConvergeRequiredTags(
3225
3082
  meshId,
3226
3083
  modeValidation.taskMode,
3227
3084
  callerTags,
3228
3085
  { targetNodeId: opts?.targetNodeId }
3229
3086
  );
3230
- resolvedRequiredTags = resolveTaskAffinityRequiredTags(
3231
- meshId,
3232
- modeValidation.taskMode,
3233
- resolvedRequiredTags,
3234
- { targetNodeId: opts?.targetNodeId, callerSpecifiedRequiredTags }
3235
- );
3236
3087
  const entry = {
3237
3088
  id,
3238
3089
  meshId,
@@ -16059,7 +15910,6 @@ __export(index_exports, {
16059
15910
  DEFAULT_STATUS_INITIAL_REPORT_DELAY_MS: () => DEFAULT_STATUS_INITIAL_REPORT_DELAY_MS,
16060
15911
  DEFAULT_STATUS_P2P_REPORT_INTERVAL_MS: () => DEFAULT_STATUS_P2P_REPORT_INTERVAL_MS,
16061
15912
  DEFAULT_STATUS_SERVER_REPORT_INTERVAL_MS: () => DEFAULT_STATUS_SERVER_REPORT_INTERVAL_MS,
16062
- DEFAULT_TASKMODE_ROLE_MAP: () => DEFAULT_TASKMODE_ROLE_MAP,
16063
15913
  DEV_SERVER_PORT: () => DEV_SERVER_PORT,
16064
15914
  DaemonAgentStreamManager: () => DaemonAgentStreamManager,
16065
15915
  DaemonCdpInitializer: () => DaemonCdpInitializer,
@@ -16099,7 +15949,6 @@ __export(index_exports, {
16099
15949
  RawTerminalAttachment: () => RawTerminalAttachment,
16100
15950
  STALE_TERMINAL_REFINE_WINDOW_MS: () => STALE_TERMINAL_REFINE_WINDOW_MS,
16101
15951
  STANDALONE_CDP_SCAN_INTERVAL_MS: () => STANDALONE_CDP_SCAN_INTERVAL_MS,
16102
- STANDARD_MESH_ROLES: () => STANDARD_MESH_ROLES,
16103
15952
  SessionHostPtyTransportFactory: () => SessionHostPtyTransportFactory,
16104
15953
  TerminalAdapter: () => TerminalAdapter,
16105
15954
  TurnSnapshotTracker: () => TurnSnapshotTracker,
@@ -16333,12 +16182,9 @@ __export(index_exports, {
16333
16182
  resolveGitRepository: () => resolveGitRepository,
16334
16183
  resolveMeshHostStatus: () => resolveMeshHostStatus,
16335
16184
  resolveMeshRefineValidationPlan: () => resolveMeshRefineValidationPlan,
16336
- resolveMeshRoleOptions: () => resolveMeshRoleOptions,
16337
16185
  resolveNodeSchedulingPriority: () => resolveNodeSchedulingPriority,
16338
16186
  resolveSessionHostAppName: () => resolveSessionHostAppName,
16339
16187
  resolveSessionHostAppNameResolution: () => resolveSessionHostAppNameResolution,
16340
- resolveTaskAffinityRequiredTags: () => resolveTaskAffinityRequiredTags,
16341
- resolveTaskAffinityRole: () => resolveTaskAffinityRole,
16342
16188
  resolveWorktreePath: () => resolveWorktreePath,
16343
16189
  runAsyncBatch: () => runAsyncBatch,
16344
16190
  runGit: () => runGit,
@@ -42828,8 +42674,6 @@ function normalizeProviderRoles(value) {
42828
42674
  const providerType = typeof rec.providerType === "string" ? rec.providerType.trim() : "";
42829
42675
  if (!providerType) continue;
42830
42676
  const entry = { providerType };
42831
- const role = typeof rec.role === "string" ? rec.role.trim() : "";
42832
- if (role) entry.role = role;
42833
42677
  const maxParallel = Number(rec.maxParallel);
42834
42678
  if (Number.isFinite(maxParallel) && maxParallel >= 0) entry.maxParallel = Math.floor(maxParallel);
42835
42679
  byType.set(providerType.toLowerCase(), entry);
@@ -58614,7 +58458,6 @@ var V1_CONTRACT_VERSION = "1.0.0";
58614
58458
  DEFAULT_STATUS_INITIAL_REPORT_DELAY_MS,
58615
58459
  DEFAULT_STATUS_P2P_REPORT_INTERVAL_MS,
58616
58460
  DEFAULT_STATUS_SERVER_REPORT_INTERVAL_MS,
58617
- DEFAULT_TASKMODE_ROLE_MAP,
58618
58461
  DEV_SERVER_PORT,
58619
58462
  DaemonAgentStreamManager,
58620
58463
  DaemonCdpInitializer,
@@ -58654,7 +58497,6 @@ var V1_CONTRACT_VERSION = "1.0.0";
58654
58497
  RawTerminalAttachment,
58655
58498
  STALE_TERMINAL_REFINE_WINDOW_MS,
58656
58499
  STANDALONE_CDP_SCAN_INTERVAL_MS,
58657
- STANDARD_MESH_ROLES,
58658
58500
  SessionHostPtyTransportFactory,
58659
58501
  TerminalAdapter,
58660
58502
  TurnSnapshotTracker,
@@ -58888,12 +58730,9 @@ var V1_CONTRACT_VERSION = "1.0.0";
58888
58730
  resolveGitRepository,
58889
58731
  resolveMeshHostStatus,
58890
58732
  resolveMeshRefineValidationPlan,
58891
- resolveMeshRoleOptions,
58892
58733
  resolveNodeSchedulingPriority,
58893
58734
  resolveSessionHostAppName,
58894
58735
  resolveSessionHostAppNameResolution,
58895
- resolveTaskAffinityRequiredTags,
58896
- resolveTaskAffinityRole,
58897
58736
  resolveWorktreePath,
58898
58737
  runAsyncBatch,
58899
58738
  runGit,