@codedrifters/configulator 0.0.287 → 0.0.288
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/lib/index.d.mts +0 -5
- package/lib/index.d.ts +0 -5
- package/lib/index.js +34 -13
- package/lib/index.js.map +1 -1
- package/lib/index.mjs +34 -13
- package/lib/index.mjs.map +1 -1
- package/package.json +1 -1
package/lib/index.d.mts
CHANGED
|
@@ -364,11 +364,6 @@ interface AgentSubAgent {
|
|
|
364
364
|
* Rendered to the platform-specific sub-agent config.
|
|
365
365
|
*/
|
|
366
366
|
readonly mcpServers?: Readonly<Record<string, McpServerConfig>>;
|
|
367
|
-
/**
|
|
368
|
-
* Sub-agents this agent can invoke/delegate to.
|
|
369
|
-
* @example ['test-writer', 'code-reviewer']
|
|
370
|
-
*/
|
|
371
|
-
readonly canDelegateToAgents?: ReadonlyArray<string>;
|
|
372
367
|
/** Optional per-platform overrides for this sub-agent. */
|
|
373
368
|
readonly platforms?: AgentSubAgentPlatformOverrides;
|
|
374
369
|
}
|
package/lib/index.d.ts
CHANGED
|
@@ -413,11 +413,6 @@ interface AgentSubAgent {
|
|
|
413
413
|
* Rendered to the platform-specific sub-agent config.
|
|
414
414
|
*/
|
|
415
415
|
readonly mcpServers?: Readonly<Record<string, McpServerConfig>>;
|
|
416
|
-
/**
|
|
417
|
-
* Sub-agents this agent can invoke/delegate to.
|
|
418
|
-
* @example ['test-writer', 'code-reviewer']
|
|
419
|
-
*/
|
|
420
|
-
readonly canDelegateToAgents?: ReadonlyArray<string>;
|
|
421
416
|
/** Optional per-platform overrides for this sub-agent. */
|
|
422
417
|
readonly platforms?: AgentSubAgentPlatformOverrides;
|
|
423
418
|
}
|
package/lib/index.js
CHANGED
|
@@ -12111,10 +12111,33 @@ function renderPipelineSkillBody(task, lines) {
|
|
|
12111
12111
|
"filter issues by `type:*` or phase label. Each invocation runs the",
|
|
12112
12112
|
`target sub-agent's full end-to-end cycle exactly once.`,
|
|
12113
12113
|
"",
|
|
12114
|
-
|
|
12115
|
-
"
|
|
12116
|
-
"
|
|
12117
|
-
"
|
|
12114
|
+
"## Depth-0 execution contract",
|
|
12115
|
+
"",
|
|
12116
|
+
"**You \u2014 the scheduled-task session \u2014 are the pipeline manager.**",
|
|
12117
|
+
"Do **not** spawn the target sub-agent via the `Agent` tool. The",
|
|
12118
|
+
"Claude Code runtime forbids nested sub-agent spawning: a depth-1",
|
|
12119
|
+
"sub-agent cannot invoke `Agent` to reach depth-2, so a pipeline",
|
|
12120
|
+
"manager that delegates to other workers must run at depth-0 (this",
|
|
12121
|
+
"scheduled-task session). See",
|
|
12122
|
+
'<https://code.claude.com/docs/en/sub-agents> \u2014 *"Subagents cannot',
|
|
12123
|
+
"spawn other subagents. If your workflow requires nested delegation,",
|
|
12124
|
+
'use Skills or chain subagents from the main conversation."*',
|
|
12125
|
+
"",
|
|
12126
|
+
"Therefore:",
|
|
12127
|
+
"",
|
|
12128
|
+
`1. **Read \`.claude/agents/${task.agent}.md\` in this session** and`,
|
|
12129
|
+
" execute its phase pipeline directly. Treat the agent file as a",
|
|
12130
|
+
" workflow runbook the scheduled-task session follows step-by-step,",
|
|
12131
|
+
" not as a sub-agent to spawn.",
|
|
12132
|
+
"2. **Use the `Agent` tool (with the `subagent_type` parameter set",
|
|
12133
|
+
" to the target worker name) to delegate one tier down.** From",
|
|
12134
|
+
" depth-0, you can spawn a depth-1 sub-agent (e.g. `issue-worker`,",
|
|
12135
|
+
" `pr-reviewer`) for the implementation, review, or merge step the",
|
|
12136
|
+
" pipeline calls out.",
|
|
12137
|
+
"3. **Never spawn the pipeline manager itself as a sub-agent.** Do",
|
|
12138
|
+
` not call \`Agent(subagent_type: "${task.agent}", ...)\`. That`,
|
|
12139
|
+
" would put the pipeline manager at depth-1 and break every",
|
|
12140
|
+
" subsequent delegation step.",
|
|
12118
12141
|
"",
|
|
12119
12142
|
"## Recommended model",
|
|
12120
12143
|
"",
|
|
@@ -13536,7 +13559,6 @@ var orchestratorSubAgent = {
|
|
|
13536
13559
|
description: "End-to-end pipeline manager that runs one full cycle every invocation: pre-flight PR merge \u2192 triage \u2192 maintenance \u2192 queue scan \u2192 delegate the picked issue to the issue-worker \u2192 cleanup",
|
|
13537
13560
|
model: AGENT_MODEL.POWERFUL,
|
|
13538
13561
|
maxTurns: 100,
|
|
13539
|
-
canDelegateToAgents: ["issue-worker", "pr-reviewer"],
|
|
13540
13562
|
platforms: { cursor: { exclude: true } },
|
|
13541
13563
|
prompt: [
|
|
13542
13564
|
"# Orchestrator Agent",
|
|
@@ -13917,7 +13939,6 @@ var issueWorkerSubAgent = {
|
|
|
13917
13939
|
description: "Selects the next ready issue from the queue, claims it, and implements the change end-to-end following repository conventions",
|
|
13918
13940
|
model: AGENT_MODEL.POWERFUL,
|
|
13919
13941
|
maxTurns: 100,
|
|
13920
|
-
canDelegateToAgents: [],
|
|
13921
13942
|
platforms: { cursor: { exclude: true } },
|
|
13922
13943
|
prompt: [
|
|
13923
13944
|
"# Issue Worker",
|
|
@@ -14346,7 +14367,13 @@ var ORCHESTRATOR_CONVENTIONS_PREAMBLE = [
|
|
|
14346
14367
|
"- The queue scan reads only `priority:*` and `status:*` labels \u2014 type-routing (which typed agent handles a given `type:*` label) is the `issue-worker`'s concern, not the orchestrator's. The orchestrator's funnel-tier sort is a tie-breaker on `priority:*`, not a routing decision.",
|
|
14347
14368
|
"- Priority order: critical > high > medium > low > trivial, then **funnel tier asc** (lower tier wins ties), then FIFO by issue number",
|
|
14348
14369
|
"- Stale thresholds: 72h for in-progress, 168h for blocked",
|
|
14349
|
-
"- Flagged issues get `status:needs-attention` \u2014 they are not auto-reset"
|
|
14370
|
+
"- Flagged issues get `status:needs-attention` \u2014 they are not auto-reset",
|
|
14371
|
+
"",
|
|
14372
|
+
"## Depth-0 invocation requirement",
|
|
14373
|
+
"",
|
|
14374
|
+
'The orchestrator agent **must run as the top-level (depth-0) session** when its Phase G needs to delegate work to the `issue-worker` sub-agent. The Claude Code harness forbids nested sub-agent spawning \u2014 *"Subagents cannot spawn other subagents. If your workflow requires nested delegation, use Skills or chain subagents from the main conversation."* (see <https://code.claude.com/docs/en/sub-agents>). If the orchestrator itself were spawned as a depth-1 sub-agent (e.g. via `Agent(subagent_type: "orchestrator")` from another session), the `Agent` tool needed to reach the `issue-worker` at depth-2 would not be available and Phase G would silently abort.',
|
|
14375
|
+
"",
|
|
14376
|
+
'Practical implication for scheduled-task wiring: the `worker-orchestrator` scheduled task\'s `SKILL.md` instructs the **scheduled-task session itself** to read `.claude/agents/orchestrator.md` and execute its phase pipeline in-session, then use the `Agent` tool to delegate the picked work item to `issue-worker` (depth-1). The scheduled task does **not** call `Agent(subagent_type: "orchestrator")` \u2014 that would put the orchestrator at depth-1 and break the chain.'
|
|
14350
14377
|
].join("\n");
|
|
14351
14378
|
function buildOrchestratorConventionsContent(tiers, scopeGate = resolveScopeGate(), runRatio = resolveRunRatio(), preflight = resolvePreflightPr(), scheduledTasks = resolveScheduledTasks(), unblockDependents = resolveUnblockDependents()) {
|
|
14352
14379
|
return [
|
|
@@ -27518,12 +27545,6 @@ var ClaudeRenderer = class _ClaudeRenderer {
|
|
|
27518
27545
|
if (agent.platforms?.claude?.memory) {
|
|
27519
27546
|
lines.push(`memory: ${agent.platforms.claude.memory}`);
|
|
27520
27547
|
}
|
|
27521
|
-
if (agent.canDelegateToAgents && agent.canDelegateToAgents.length > 0) {
|
|
27522
|
-
lines.push(`canDelegateToAgents:`);
|
|
27523
|
-
for (const delegateName of agent.canDelegateToAgents) {
|
|
27524
|
-
lines.push(` - "${delegateName}"`);
|
|
27525
|
-
}
|
|
27526
|
-
}
|
|
27527
27548
|
lines.push("---");
|
|
27528
27549
|
lines.push("");
|
|
27529
27550
|
lines.push(...agent.prompt.split("\n"));
|