@wrongstack/core 0.68.0 → 0.73.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (55) hide show
  1. package/dist/{agent-bridge-D-j6OOBT.d.ts → agent-bridge-C0Ze7Ldm.d.ts} +1 -1
  2. package/dist/{agent-subagent-runner-DRZ9-NnR.d.ts → agent-subagent-runner-BmITbs1Q.d.ts} +13 -5
  3. package/dist/{config--86aHSln.d.ts → config-Dy0CK_o6.d.ts} +44 -1
  4. package/dist/coordination/index.d.ts +10 -10
  5. package/dist/coordination/index.js +10 -4
  6. package/dist/coordination/index.js.map +1 -1
  7. package/dist/defaults/index.d.ts +15 -15
  8. package/dist/defaults/index.js +53 -22
  9. package/dist/defaults/index.js.map +1 -1
  10. package/dist/{events-CIplI98R.d.ts → events-BBAlxBuw.d.ts} +8 -0
  11. package/dist/execution/index.d.ts +8 -8
  12. package/dist/execution/index.js +4 -4
  13. package/dist/execution/index.js.map +1 -1
  14. package/dist/extension/index.d.ts +5 -5
  15. package/dist/{index-DKUvyTvV.d.ts → index-BN6i2Nfg.d.ts} +4 -4
  16. package/dist/{index-b5uhfTSl.d.ts → index-yQbZ2NQx.d.ts} +6 -6
  17. package/dist/index.d.ts +29 -27
  18. package/dist/index.js +154 -33
  19. package/dist/index.js.map +1 -1
  20. package/dist/infrastructure/index.d.ts +4 -4
  21. package/dist/kernel/index.d.ts +7 -7
  22. package/dist/kernel/index.js.map +1 -1
  23. package/dist/{mcp-servers-DwoNBf6r.d.ts → mcp-servers-T0O6UN_w.d.ts} +1 -1
  24. package/dist/{mode-CV077NjV.d.ts → mode-BO4SEUIv.d.ts} +7 -0
  25. package/dist/models/index.d.ts +1 -1
  26. package/dist/models/index.js +18 -9
  27. package/dist/models/index.js.map +1 -1
  28. package/dist/{multi-agent-coordinator-CWnH-CiX.d.ts → multi-agent-coordinator-BSBbZt0e.d.ts} +1 -1
  29. package/dist/{null-fleet-bus-CuN0ObJr.d.ts → null-fleet-bus-BCIRT_nV.d.ts} +19 -9
  30. package/dist/observability/index.d.ts +1 -1
  31. package/dist/{parallel-eternal-engine-0UwotoSx.d.ts → parallel-eternal-engine-CjAYGaCw.d.ts} +3 -3
  32. package/dist/{path-resolver-DVkEcIw8.d.ts → path-resolver-BnqXa9Ze.d.ts} +1 -1
  33. package/dist/{permission-C1A5whY5.d.ts → permission-V5BLOrY6.d.ts} +0 -4
  34. package/dist/{permission-policy-B2dK-T5N.d.ts → permission-policy-CBVx-d-8.d.ts} +1 -5
  35. package/dist/{plan-templates-Bprrzhbu.d.ts → plan-templates-DBgrTGPu.d.ts} +2 -2
  36. package/dist/{provider-runner-mXvXGSIw.d.ts → provider-runner-n3KkHT_w.d.ts} +1 -1
  37. package/dist/sdd/index.d.ts +6 -6
  38. package/dist/sdd/index.js +3 -3
  39. package/dist/sdd/index.js.map +1 -1
  40. package/dist/security/index.d.ts +2 -2
  41. package/dist/security/index.js +0 -8
  42. package/dist/security/index.js.map +1 -1
  43. package/dist/skills/index.js +1 -0
  44. package/dist/skills/index.js.map +1 -1
  45. package/dist/storage/index.d.ts +3 -3
  46. package/dist/storage/index.js +26 -2
  47. package/dist/storage/index.js.map +1 -1
  48. package/dist/{system-prompt-b61lOd49.d.ts → system-prompt-CA11g6Jo.d.ts} +1 -1
  49. package/dist/types/index.d.ts +13 -13
  50. package/dist/types/index.js +19 -10
  51. package/dist/types/index.js.map +1 -1
  52. package/dist/utils/index.d.ts +1 -1
  53. package/dist/utils/index.js +2 -1
  54. package/dist/utils/index.js.map +1 -1
  55. package/package.json +1 -1
@@ -1,44 +1,44 @@
1
1
  export { D as DefaultLogger, a as DefaultLoggerOptions } from '../logger-bOzkF5LL.js';
2
- export { A as AbandonedSession, a as AttachmentStoreOptions, C as ConfigLoaderOptions, b as ConfigMigration, c as ConfigMigrationError, d as ConfigSource, D as DEFAULT_CONFIG_MIGRATIONS, e as DefaultAttachmentStore, f as DefaultConfigLoader, g as DefaultConfigStore, h as DefaultMemoryStore, i as DefaultSessionStore, M as MemoryStoreOptions, j as MigrationContext, k as MigrationResult, P as PersistedQueueItem, l as PlanFile, m as PlanItem, n as PlanTemplate, Q as QueueStore, R as RecoveryLock, o as RecoveryLockOptions, S as SessionAnalyzer, p as SessionStoreOptions, T as TodosCheckpointFile, q as addPlanItem, r as attachPlanCheckpoint, s as attachTodosCheckpoint, t as clearPlan, u as deriveTodosFromPlanItem, v as emptyPlan, w as formatPlan, x as formatPlanTemplates, y as getPlanTemplate, z as listPlanTemplates, B as loadPlan, E as loadTodosCheckpoint, F as removePlanItem, G as runConfigMigrations, H as savePlan, I as saveTodosCheckpoint, J as setPlanItemStatus } from '../plan-templates-Bprrzhbu.js';
2
+ export { A as AbandonedSession, a as AttachmentStoreOptions, C as ConfigLoaderOptions, b as ConfigMigration, c as ConfigMigrationError, d as ConfigSource, D as DEFAULT_CONFIG_MIGRATIONS, e as DefaultAttachmentStore, f as DefaultConfigLoader, g as DefaultConfigStore, h as DefaultMemoryStore, i as DefaultSessionStore, M as MemoryStoreOptions, j as MigrationContext, k as MigrationResult, P as PersistedQueueItem, l as PlanFile, m as PlanItem, n as PlanTemplate, Q as QueueStore, R as RecoveryLock, o as RecoveryLockOptions, S as SessionAnalyzer, p as SessionStoreOptions, T as TodosCheckpointFile, q as addPlanItem, r as attachPlanCheckpoint, s as attachTodosCheckpoint, t as clearPlan, u as deriveTodosFromPlanItem, v as emptyPlan, w as formatPlan, x as formatPlanTemplates, y as getPlanTemplate, z as listPlanTemplates, B as loadPlan, E as loadTodosCheckpoint, F as removePlanItem, G as runConfigMigrations, H as savePlan, I as saveTodosCheckpoint, J as setPlanItemStatus } from '../plan-templates-DBgrTGPu.js';
3
3
  export { D as DefaultSessionReader } from '../session-reader-BIpwM60D.js';
4
4
  export { A as AuditLevel, a as SessionEventBridge, b as SessionEventBridgeOptions, c as SessionSamplingOptions, T as ToolProgressSamplingOptions, d as createSessionEventBridge, r as resolveAuditLevel, e as resolveSessionLoggingConfig } from '../session-event-bridge-CDHxcmQU.js';
5
5
  export { D as DirectorStateCheckpoint, a as DirectorStateSnapshot, b as DirectorSubagentState, c as DirectorTaskState, l as loadDirectorState } from '../director-state-BmYi3DGA.js';
6
6
  export { D as DefaultSecretScrubber, a as DefaultSecretVault, S as SecretVaultOptions, d as decryptConfigSecrets, e as encryptConfigSecrets, m as migratePlaintextSecrets, r as rewriteConfigEncrypted } from '../secret-scrubber-7rSC_emZ.js';
7
- export { A as AutoApprovePermissionPolicy, D as DefaultPermissionPolicy, P as PermissionPolicyOptions } from '../permission-policy-B2dK-T5N.js';
8
- export { C as CompactorOptions, a as DefaultErrorHandler, b as DefaultRetryPolicy, E as EternalAutonomyEngine, c as EternalAutonomyOptions, d as EternalEngineState, H as HybridCompactor, I as IterationStage, P as ParallelEngineState, e as ParallelEternalEngine, f as ParallelEternalOptions, g as ParallelIterationStage, T as ToolExecutor } from '../parallel-eternal-engine-0UwotoSx.js';
7
+ export { A as AutoApprovePermissionPolicy, D as DefaultPermissionPolicy, P as PermissionPolicyOptions } from '../permission-policy-CBVx-d-8.js';
8
+ export { C as CompactorOptions, a as DefaultErrorHandler, b as DefaultRetryPolicy, E as EternalAutonomyEngine, c as EternalAutonomyOptions, d as EternalEngineState, H as HybridCompactor, I as IterationStage, P as ParallelEngineState, e as ParallelEternalEngine, f as ParallelEternalOptions, g as ParallelIterationStage, T as ToolExecutor } from '../parallel-eternal-engine-CjAYGaCw.js';
9
9
  export { AutoCompactionMiddleware, AutonomousRunner, AutonomousRunnerOptions, AutonomyPromptContributorOptions, DefaultSkillLoader, DoneCheckResult, DoneConditionChecker, IntelligentCompactor, IntelligentCompactorOptions, SelectiveCompactor, SelectiveCompactorOptions, SkillLoaderOptions, buildGoalPreamble, makeAutonomyPromptContributor } from '../execution/index.js';
10
- import { P as ProviderRunner, R as RunProviderOptions } from '../provider-runner-mXvXGSIw.js';
10
+ import { P as ProviderRunner, R as RunProviderOptions } from '../provider-runner-n3KkHT_w.js';
11
11
  import { q as Response } from '../context-y87Jc5ei.js';
12
- export { a as AGENTS_BY_PHASE, b as AGENT_CATALOG, c as ALL_AGENT_DEFINITIONS, d as ALL_FLEET_AGENTS, e as AUDIT_LOG_AGENT, f as AutoExtendCeiling, g as AutoExtendPolicy, B as BUG_HUNTER_AGENT, n as CreateDelegateToolOptions, D as DEFAULT_DIRECTOR_PREAMBLE, q as DEFAULT_SUBAGENT_BASELINE, r as DelegateHost, s as Director, w as DirectorPromptParts, x as DirectorSessionFactory, y as DirectorSessionFactoryOptions, F as FLEET_ROSTER, z as FLEET_ROSTER_BUDGETS, J as FleetRosterBudget, K as FleetSpawnBudgetError, L as ICoordinator, M as IFleetManager, O as NULL_FLEET_BUS, R as REFACTOR_PLANNER_AGENT, S as SECURITY_SCANNER_AGENT, V as SubagentPromptParts, W as applyRosterBudget, X as attachAutoExtend, Y as composeDirectorPrompt, Z as composeSubagentPrompt, _ as createDelegateTool, $ as getAgentDefinition, a1 as makeAskTool, a2 as makeAssignTool, a3 as makeAwaitTasksTool, a4 as makeCollabDebugTool, a5 as makeDirectorSessionFactory, a6 as makeFleetEmitTool, a7 as makeFleetHealthTool, a8 as makeFleetSessionTool, a9 as makeFleetStatusTool, aa as makeFleetUsageTool, ab as makeRollUpTool, ac as makeSpawnTool, ad as makeTerminateTool, af as rosterSummaryFromConfigs } from '../null-fleet-bus-CuN0ObJr.js';
13
- export { A as AgentBudgetTier, a as AgentCapability, b as AgentDefinition, c as AgentPhase, D as DEFAULT_DISPATCH_ROLE, d as DefaultMultiAgentCoordinator, e as DispatchCandidate, f as DispatchClassifier, g as DispatchMethod, h as DispatchOptions, i as DispatchResult, j as MultiAgentCoordinatorOptions, k as dispatchAgent, m as makeLLMClassifier, s as scoreAgents } from '../multi-agent-coordinator-CWnH-CiX.js';
14
- export { c as AgentFactory, d as AgentFactoryResult, e as AgentRunnerOptions, g as BudgetExceededError, h as BudgetKind, i as BudgetLimits, n as BudgetUsage, F as FleetBus, p as FleetEvent, q as FleetHandler, r as FleetUsage, s as FleetUsageAggregator, K as SubagentBudget, V as SubagentUsageSnapshot, _ as makeAgentSubagentRunner } from '../agent-subagent-runner-DRZ9-NnR.js';
15
- export { I as InMemoryAgentBridge, a as InMemoryBridgeTransport, c as createMessage } from '../agent-bridge-D-j6OOBT.js';
12
+ export { a as AGENTS_BY_PHASE, b as AGENT_CATALOG, c as ALL_AGENT_DEFINITIONS, d as ALL_FLEET_AGENTS, e as AUDIT_LOG_AGENT, f as AutoExtendCeiling, g as AutoExtendPolicy, B as BUG_HUNTER_AGENT, n as CreateDelegateToolOptions, D as DEFAULT_DIRECTOR_PREAMBLE, q as DEFAULT_SUBAGENT_BASELINE, r as DelegateHost, s as Director, w as DirectorPromptParts, x as DirectorSessionFactory, y as DirectorSessionFactoryOptions, F as FLEET_ROSTER, z as FLEET_ROSTER_BUDGETS, J as FleetRosterBudget, K as FleetSpawnBudgetError, L as ICoordinator, M as IFleetManager, O as NULL_FLEET_BUS, R as REFACTOR_PLANNER_AGENT, S as SECURITY_SCANNER_AGENT, V as SubagentPromptParts, W as applyRosterBudget, X as attachAutoExtend, Y as composeDirectorPrompt, Z as composeSubagentPrompt, _ as createDelegateTool, $ as getAgentDefinition, a1 as makeAskTool, a2 as makeAssignTool, a3 as makeAwaitTasksTool, a4 as makeCollabDebugTool, a5 as makeDirectorSessionFactory, a6 as makeFleetEmitTool, a7 as makeFleetHealthTool, a8 as makeFleetSessionTool, a9 as makeFleetStatusTool, aa as makeFleetUsageTool, ab as makeRollUpTool, ac as makeSpawnTool, ad as makeTerminateTool, af as rosterSummaryFromConfigs } from '../null-fleet-bus-BCIRT_nV.js';
13
+ export { A as AgentBudgetTier, a as AgentCapability, b as AgentDefinition, c as AgentPhase, D as DEFAULT_DISPATCH_ROLE, d as DefaultMultiAgentCoordinator, e as DispatchCandidate, f as DispatchClassifier, g as DispatchMethod, h as DispatchOptions, i as DispatchResult, j as MultiAgentCoordinatorOptions, k as dispatchAgent, m as makeLLMClassifier, s as scoreAgents } from '../multi-agent-coordinator-BSBbZt0e.js';
14
+ export { c as AgentFactory, d as AgentFactoryResult, e as AgentRunnerOptions, g as BudgetExceededError, h as BudgetKind, i as BudgetLimits, n as BudgetUsage, F as FleetBus, p as FleetEvent, q as FleetHandler, r as FleetUsage, s as FleetUsageAggregator, K as SubagentBudget, V as SubagentUsageSnapshot, _ as makeAgentSubagentRunner } from '../agent-subagent-runner-BmITbs1Q.js';
15
+ export { I as InMemoryAgentBridge, a as InMemoryBridgeTransport, c as createMessage } from '../agent-bridge-C0Ze7Ldm.js';
16
16
  export { D as DefaultModelsRegistry, a as DefaultModelsRegistryOptions, c as classifyFamily } from '../models-registry-Cuq1C8V9.js';
17
17
  export { DefaultModeStore, LLMSelector, LLMSelectorOptions, ModeLoaderOptions, loadProjectModes, loadUserModes } from '../models/index.js';
18
18
  export { AISpecBuilder, AISpecBuilderOptions, AISpecPhase, AISpecSession, AutoExecutor, AutoExecutorOptions, BottleneckTask, CollectedAnswer, CriticalPathAnalysis, DefaultTaskStore, ExecutionSummary, GeneratedTask, RunResult, SPEC_TEMPLATES, SddParallelRun, SddParallelRunOptions, SddProgress, SddTaskDecomposer, SddTaskDecomposerOptions, SpecDiff, SpecDrivenDev, SpecDrivenDevOptions, SpecIndexEntry, SpecParser, SpecStore, SpecStoreOptions, SpecVersion, SpecVersioning, TaskBatch, TaskExecutionContext, TaskExecutionResult, TaskFlow, TaskFlowEventMap, TaskFlowEventName, TaskFlowExecutionContext, TaskFlowOptions, TaskFlowPhase, TaskGenerator, TaskGeneratorOptions, TaskGraphIndexEntry, TaskGraphStore, TaskGraphStoreOptions, TaskStore, TaskTracker, TaskTrackerOptions, TaskTransition, WaveResult, analyzeCriticalPath, createAutoExecutor, getTemplate, listTemplates, renderProgress, renderSpecAnalysis, renderTaskGraph, renderTaskList, templateToMarkdown } from '../sdd/index.js';
19
19
  export { DefaultHealthRegistry, InMemoryMetricsSink, MetricsServerHandle, MetricsServerOptions, NoopMetricsSink, NoopTracer, OTelTracer, OtlpMetricsExporterHandle, OtlpMetricsExporterOptions, OtlpTraceExporterHandle, OtlpTraceExporterOptions, PROMETHEUS_CONTENT_TYPE, buildOtlpMetricsRequest, buildOtlpTracesRequest, renderPrometheus, startMetricsServer, startOtlpMetricsExporter, startOtlpTraceExporter, wireMetricsToEvents } from '../observability/index.js';
20
- export { C as ContextManagerAction, a as ContextManagerInput, b as ContextManagerResult, c as ContextManagerToolOptions, d as allServers, e as awsServer, f as blockServer, g as braveSearchServer, h as context7Server, i as contextManagerTool, j as createContextManagerTool, k as everArtServer, l as filesystemServer, m as githubServer, n as googleMapsServer, o as miniMaxVisionServer, s as sentinelServer, p as slackServer, z as zaiVisionServer } from '../mcp-servers-DwoNBf6r.js';
20
+ export { C as ContextManagerAction, a as ContextManagerInput, b as ContextManagerResult, c as ContextManagerToolOptions, d as allServers, e as awsServer, f as blockServer, g as braveSearchServer, h as context7Server, i as contextManagerTool, j as createContextManagerTool, k as everArtServer, l as filesystemServer, m as githubServer, n as googleMapsServer, o as miniMaxVisionServer, s as sentinelServer, p as slackServer, z as zaiVisionServer } from '../mcp-servers-T0O6UN_w.js';
21
21
  export { D as DEFAULT_AUTONOMY_CONFIG, a as DEFAULT_CONTEXT_CONFIG, c as DEFAULT_TOOLS_CONFIG } from '../default-config-DEXI4jsl.js';
22
22
  import '../logger-DDd5C--Z.js';
23
- import '../events-CIplI98R.js';
23
+ import '../events-BBAlxBuw.js';
24
24
  import '../secret-scrubber-3MHDDAtm.js';
25
25
  import '../memory-CEXuo7sz.js';
26
26
  import '../wstack-paths-eMXnY1_X.js';
27
- import '../config--86aHSln.js';
27
+ import '../config-Dy0CK_o6.js';
28
28
  import '../models-registry-BcYJDKLm.js';
29
29
  import '../secret-vault-DoISxaKO.js';
30
30
  import '../input-reader-E-ffP2ee.js';
31
- import '../permission-C1A5whY5.js';
31
+ import '../permission-V5BLOrY6.js';
32
32
  import '../compactor-D_ExJajC.js';
33
33
  import '../retry-policy-CG3qvH_e.js';
34
- import '../index-DKUvyTvV.js';
35
- import '../system-prompt-b61lOd49.js';
34
+ import '../index-BN6i2Nfg.js';
35
+ import '../system-prompt-CA11g6Jo.js';
36
36
  import '../observability-BhnVLBLS.js';
37
37
  import '../goal-store-C7jcumEh.js';
38
38
  import '../selector-RvBR_YRW.js';
39
39
  import '../skill-CxuWrsKK.js';
40
40
  import 'node:events';
41
- import '../mode-CV077NjV.js';
41
+ import '../mode-BO4SEUIv.js';
42
42
  import '../task-graph-D1YQbpxF.js';
43
43
 
44
44
  /**
@@ -1479,8 +1479,17 @@ var BEHAVIOR_DEFAULTS = {
1479
1479
  modelsRegistry: true,
1480
1480
  skills: true
1481
1481
  },
1482
+ indexing: {
1483
+ onSessionStart: true,
1484
+ onEdit: true,
1485
+ watchExternal: true,
1486
+ debounceMs: 400
1487
+ },
1482
1488
  session: { ...DEFAULT_SESSION_LOGGING_CONFIG }
1483
1489
  };
1490
+ function envBool(v) {
1491
+ return !/^(0|false|no|off)$/i.test(v.trim());
1492
+ }
1484
1493
  var ENV_MAP = {
1485
1494
  WRONGSTACK_PROVIDER: (c, v) => {
1486
1495
  c.provider = v;
@@ -1505,8 +1514,23 @@ var ENV_MAP = {
1505
1514
  WRONGSTACK_LOG_LEVEL: (c, v) => {
1506
1515
  if (!c.log) c.log = { level: "info" };
1507
1516
  c.log.level = v;
1517
+ },
1518
+ WRONGSTACK_INDEX_ON_START: (c, v) => {
1519
+ c.indexing = { ...defaultIndexing, ...c.indexing, onSessionStart: envBool(v) };
1520
+ },
1521
+ WRONGSTACK_INDEX_ON_EDIT: (c, v) => {
1522
+ c.indexing = { ...defaultIndexing, ...c.indexing, onEdit: envBool(v) };
1523
+ },
1524
+ WRONGSTACK_INDEX_WATCH: (c, v) => {
1525
+ c.indexing = { ...defaultIndexing, ...c.indexing, watchExternal: envBool(v) };
1508
1526
  }
1509
1527
  };
1528
+ var defaultIndexing = {
1529
+ onSessionStart: true,
1530
+ onEdit: true,
1531
+ watchExternal: true,
1532
+ debounceMs: 400
1533
+ };
1510
1534
  function isPrimitiveArray(a) {
1511
1535
  return a.every((v) => v === null || typeof v !== "object");
1512
1536
  }
@@ -3481,14 +3505,6 @@ var DefaultPermissionPolicy = class {
3481
3505
  getConfirmDestructive() {
3482
3506
  return this.confirmDestructive;
3483
3507
  }
3484
- /** @deprecated Use `setYoloDestructive`. */
3485
- setForceAllYolo(enabled) {
3486
- this.setYoloDestructive(enabled);
3487
- }
3488
- /** @deprecated Use `getYoloDestructive`. */
3489
- getForceAllYolo() {
3490
- return this.getYoloDestructive();
3491
- }
3492
3508
  async reload() {
3493
3509
  try {
3494
3510
  const raw = await fsp.readFile(this.trustFile, "utf8");
@@ -5832,7 +5848,7 @@ ${errorDetails}`,
5832
5848
  const decision = await this.opts.permissionPolicy.evaluate(tool, use.input, ctx);
5833
5849
  let effectivePermission = decision.permission;
5834
5850
  const policy = this.opts.permissionPolicy;
5835
- const yolo = policy.getYolo?.() === true || policy.getYoloDestructive?.() === true || policy.getForceAllYolo?.() === true;
5851
+ const yolo = policy.getYolo?.() === true || policy.getYoloDestructive?.() === true;
5836
5852
  if (toolDangerousCaps.length > 0 && effectivePermission === "auto" && !yolo) {
5837
5853
  effectivePermission = "confirm";
5838
5854
  }
@@ -10312,7 +10328,7 @@ var DefaultMultiAgentCoordinator = class _DefaultMultiAgentCoordinator extends E
10312
10328
  }
10313
10329
  async spawn(subagent) {
10314
10330
  const id = subagent.id || randomUUID();
10315
- subagent = this.withNickname(subagent, id);
10331
+ const cfg = this.withNickname(subagent, id);
10316
10332
  if (this.subagents.has(id)) {
10317
10333
  throw new Error(`Subagent id "${id}" already exists \u2014 refusing to overwrite`);
10318
10334
  }
@@ -10327,12 +10343,12 @@ var DefaultMultiAgentCoordinator = class _DefaultMultiAgentCoordinator extends E
10327
10343
  maxConcurrent: this.config.maxConcurrent ?? 16
10328
10344
  };
10329
10345
  this.subagents.set(id, {
10330
- config: { ...subagent, id },
10346
+ config: { ...cfg, id },
10331
10347
  context,
10332
10348
  status: "idle",
10333
10349
  abortController: new AbortController()
10334
10350
  });
10335
- this.emit("subagent.started", { subagent: { ...subagent, id } });
10351
+ this.emit("subagent.started", { subagent: { ...cfg, id } });
10336
10352
  this.fleetBus?.emit({
10337
10353
  subagentId: id,
10338
10354
  ts: Date.now(),
@@ -11562,7 +11578,8 @@ function isGlob(p) {
11562
11578
  return false;
11563
11579
  }
11564
11580
  function globToRegex(pat) {
11565
- let i = 0, re = "^";
11581
+ let i = 0;
11582
+ let re = "^";
11566
11583
  while (i < pat.length) {
11567
11584
  const c = pat[i];
11568
11585
  if (c === "*") {
@@ -12281,6 +12298,10 @@ A scratchpad shared with the rest of the fleet is mounted at \`${parts.sharedScr
12281
12298
  - Use stable filenames (one file per concern); overwrite instead of appending so the Director sees the latest state.`
12282
12299
  );
12283
12300
  }
12301
+ if (parts.skills && parts.skills.trim().length > 0) {
12302
+ sections.push(`Domain knowledge:
12303
+ ${parts.skills.trim()}`);
12304
+ }
12284
12305
  if (parts.override && parts.override.trim().length > 0) {
12285
12306
  sections.push(parts.override.trim());
12286
12307
  }
@@ -14113,6 +14134,7 @@ var Director = class _Director {
14113
14134
  role: config.prompt,
14114
14135
  task: taskBrief,
14115
14136
  sharedScratchpad: this.sharedScratchpadPath ?? void 0,
14137
+ skills: config.skillContent,
14116
14138
  override: config.systemPromptOverride
14117
14139
  });
14118
14140
  }
@@ -14989,7 +15011,8 @@ When reviewing code:
14989
15011
  - Verify test coverage for critical paths
14990
15012
  - Ensure naming conventions are followed`,
14991
15013
  tags: ["review", "quality", "security"],
14992
- toolPreferences: ["read", "grep", "git", "diff", "test"]
15014
+ toolPreferences: ["read", "grep", "git", "diff", "test"],
15015
+ suggestedSkills: ["bug-hunter", "security-scanner", "typescript-strict", "testing"]
14993
15016
  },
14994
15017
  {
14995
15018
  id: "code-auditor",
@@ -15006,7 +15029,8 @@ When auditing code for security:
15006
15029
  - Assess input validation and output encoding
15007
15030
  - Look for timing attacks and information leakage`,
15008
15031
  tags: ["security", "audit", "compliance"],
15009
- toolPreferences: ["grep", "read", "audit", "bash"]
15032
+ toolPreferences: ["grep", "read", "audit", "bash"],
15033
+ suggestedSkills: ["security-scanner", "bug-hunter", "audit-log"]
15010
15034
  },
15011
15035
  {
15012
15036
  id: "architect",
@@ -15024,7 +15048,8 @@ When designing or reviewing architecture:
15024
15048
  - Assess API design and contract stability
15025
15049
  - Consider operational aspects (monitoring, logging, deployment)`,
15026
15050
  tags: ["architecture", "design", "scalability"],
15027
- toolPreferences: ["read", "glob", "tree", "diff"]
15051
+ toolPreferences: ["read", "glob", "tree", "diff"],
15052
+ suggestedSkills: ["api-design", "refactor-planner", "node-modern", "docker-deploy"]
15028
15053
  },
15029
15054
  {
15030
15055
  id: "debugger",
@@ -15042,7 +15067,8 @@ When investigating bugs:
15042
15067
  - Use binary search to isolate the root cause
15043
15068
  - Verify fixes with tests before considering done`,
15044
15069
  tags: ["debug", "investigation", "error-resolution"],
15045
- toolPreferences: ["read", "grep", "bash", "logs", "test"]
15070
+ toolPreferences: ["read", "grep", "bash", "logs", "test"],
15071
+ suggestedSkills: ["bug-hunter", "audit-log", "observability"]
15046
15072
  },
15047
15073
  {
15048
15074
  id: "tester",
@@ -15060,7 +15086,8 @@ When testing or writing tests:
15060
15086
  - Check for integration test gaps
15061
15087
  - Verify test isolation and cleanup`,
15062
15088
  tags: ["testing", "qa", "quality"],
15063
- toolPreferences: ["read", "grep", "test", "bash"]
15089
+ toolPreferences: ["read", "grep", "test", "bash"],
15090
+ suggestedSkills: ["testing", "bug-hunter", "typescript-strict"]
15064
15091
  },
15065
15092
  {
15066
15093
  id: "devops",
@@ -15078,7 +15105,8 @@ When working on infrastructure:
15078
15105
  - Assess secrets management
15079
15106
  - Check for resource limits and quotas`,
15080
15107
  tags: ["devops", "infrastructure", "operations"],
15081
- toolPreferences: ["read", "bash", "grep", "logs", "git"]
15108
+ toolPreferences: ["read", "bash", "grep", "logs", "git"],
15109
+ suggestedSkills: ["docker-deploy", "observability", "security-scanner"]
15082
15110
  },
15083
15111
  {
15084
15112
  id: "refactorer",
@@ -15096,7 +15124,8 @@ When refactoring code:
15096
15124
  - Don't mix formatting changes with logic changes
15097
15125
  - Keep performance in mind \u2014 don't regress`,
15098
15126
  tags: ["refactor", "modernization", "improvement"],
15099
- toolPreferences: ["read", "edit", "test", "git", "grep"]
15127
+ toolPreferences: ["read", "edit", "test", "git", "grep"],
15128
+ suggestedSkills: ["refactor-planner", "typescript-strict", "node-modern", "testing"]
15100
15129
  },
15101
15130
  {
15102
15131
  id: "brief",
@@ -15126,7 +15155,8 @@ Get to the point \u2014 read files, run commands, make changes.
15126
15155
  - One-liner sufficient? One liner.
15127
15156
  - Max 3 sentences per paragraph.`,
15128
15157
  tags: ["fast", "concise", "direct"],
15129
- toolPreferences: ["read", "edit", "bash"]
15158
+ toolPreferences: ["read", "edit", "bash"],
15159
+ suggestedSkills: []
15130
15160
  },
15131
15161
  {
15132
15162
  id: "teach",
@@ -15191,7 +15221,8 @@ You follow these principles, but always with explanation:
15191
15221
 
15192
15222
  Remember: your job is to make the user a better developer, not just to complete tasks faster.`,
15193
15223
  tags: ["teaching", "mentor", "learning"],
15194
- toolPreferences: ["read", "edit", "explain"]
15224
+ toolPreferences: ["read", "edit", "explain"],
15225
+ suggestedSkills: ["prompt-engineering", "skill-creator", "node-modern", "typescript-strict"]
15195
15226
  }
15196
15227
  ];
15197
15228