synorch 0.2.0 → 0.3.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +32 -1
- package/README.md +314 -28
- package/dist/application/doctor-service.d.ts +16 -0
- package/dist/application/doctor-service.d.ts.map +1 -1
- package/dist/application/doctor-service.js +230 -32
- package/dist/application/doctor-service.js.map +1 -1
- package/dist/application/generated-skill-doctor.d.ts +9 -0
- package/dist/application/generated-skill-doctor.d.ts.map +1 -0
- package/dist/application/generated-skill-doctor.js +433 -0
- package/dist/application/generated-skill-doctor.js.map +1 -0
- package/dist/application/project-discovery.d.ts +12 -0
- package/dist/application/project-discovery.d.ts.map +1 -1
- package/dist/application/project-discovery.js +65 -2
- package/dist/application/project-discovery.js.map +1 -1
- package/dist/application/safe-path.d.ts +19 -0
- package/dist/application/safe-path.d.ts.map +1 -0
- package/dist/application/safe-path.js +35 -0
- package/dist/application/safe-path.js.map +1 -0
- package/dist/application/size-ceiling.d.ts +15 -0
- package/dist/application/size-ceiling.d.ts.map +1 -0
- package/dist/application/size-ceiling.js +32 -0
- package/dist/application/size-ceiling.js.map +1 -0
- package/dist/application/structure-service.d.ts.map +1 -1
- package/dist/application/structure-service.js +10 -1
- package/dist/application/structure-service.js.map +1 -1
- package/dist/cli.js +10 -1
- package/dist/cli.js.map +1 -1
- package/dist/domain/canonical-contracts.d.ts +69 -0
- package/dist/domain/canonical-contracts.d.ts.map +1 -0
- package/dist/domain/canonical-contracts.js +92 -0
- package/dist/domain/canonical-contracts.js.map +1 -0
- package/dist/domain/generated-skill.d.ts +55 -0
- package/dist/domain/generated-skill.d.ts.map +1 -0
- package/dist/domain/generated-skill.js +90 -0
- package/dist/domain/generated-skill.js.map +1 -0
- package/dist/domain/generation.d.ts +15 -2
- package/dist/domain/generation.d.ts.map +1 -1
- package/dist/domain/observation-ledger.d.ts +118 -0
- package/dist/domain/observation-ledger.d.ts.map +1 -0
- package/dist/domain/observation-ledger.js +183 -0
- package/dist/domain/observation-ledger.js.map +1 -0
- package/dist/domain/product.d.ts +1 -1
- package/dist/domain/product.js +1 -1
- package/dist/domain/relative-path.d.ts +21 -0
- package/dist/domain/relative-path.d.ts.map +1 -0
- package/dist/domain/relative-path.js +43 -0
- package/dist/domain/relative-path.js.map +1 -0
- package/dist/domain/skill-packs.d.ts.map +1 -1
- package/dist/domain/skill-packs.js +1 -0
- package/dist/domain/skill-packs.js.map +1 -1
- package/dist/domain/zod-issues.d.ts +21 -0
- package/dist/domain/zod-issues.d.ts.map +1 -0
- package/dist/domain/zod-issues.js +27 -0
- package/dist/domain/zod-issues.js.map +1 -0
- package/dist/infrastructure/frontmatter.d.ts +25 -0
- package/dist/infrastructure/frontmatter.d.ts.map +1 -0
- package/dist/infrastructure/frontmatter.js +75 -0
- package/dist/infrastructure/frontmatter.js.map +1 -0
- package/dist/templates/agent-manifests.d.ts +19 -0
- package/dist/templates/agent-manifests.d.ts.map +1 -0
- package/dist/templates/agent-manifests.js +302 -0
- package/dist/templates/agent-manifests.js.map +1 -0
- package/dist/templates/base-skills.d.ts +23 -0
- package/dist/templates/base-skills.d.ts.map +1 -0
- package/dist/templates/base-skills.js +477 -0
- package/dist/templates/base-skills.js.map +1 -0
- package/dist/templates/skill-creator-skill.d.ts +23 -0
- package/dist/templates/skill-creator-skill.d.ts.map +1 -0
- package/dist/templates/skill-creator-skill.js +235 -0
- package/dist/templates/skill-creator-skill.js.map +1 -0
- package/dist/templates/skill-references.d.ts +13 -0
- package/dist/templates/skill-references.d.ts.map +1 -0
- package/dist/templates/skill-references.js +280 -0
- package/dist/templates/skill-references.js.map +1 -0
- package/dist/templates/structure-templates.d.ts.map +1 -1
- package/dist/templates/structure-templates.js +15 -139
- package/dist/templates/structure-templates.js.map +1 -1
- package/dist/templates/task-conductor-skill.d.ts +1 -1
- package/dist/templates/task-conductor-skill.d.ts.map +1 -1
- package/dist/templates/task-conductor-skill.js +50 -22
- package/dist/templates/task-conductor-skill.js.map +1 -1
- package/package.json +1 -1
|
@@ -1,6 +1,8 @@
|
|
|
1
1
|
import { SYNORCH_GENERATOR_NAME, SYNORCH_VERSION } from "../domain/product.js";
|
|
2
2
|
import { stringifyYaml } from "../infrastructure/serialization.js";
|
|
3
|
-
import {
|
|
3
|
+
import { AGENT_DOCUMENTS } from "./agent-manifests.js";
|
|
4
|
+
import { BASE_SKILL_DOCUMENTS } from "./base-skills.js";
|
|
5
|
+
import { skillCreatorLedgerFiles } from "./skill-creator-skill.js";
|
|
4
6
|
export function createStructureFiles(scope) {
|
|
5
7
|
return [
|
|
6
8
|
file("AGENTS.md", codexEntrypoint, "entrypoint"),
|
|
@@ -30,19 +32,11 @@ export function createStructureFiles(scope) {
|
|
|
30
32
|
file(".ai/protocols/core/verification.md", verificationProtocol, "protocol"),
|
|
31
33
|
file(".ai/protocols/core/failure-recovery.md", failureRecoveryProtocol, "protocol"),
|
|
32
34
|
file(".ai/protocols/core/user-communication.md", userCommunicationProtocol, "protocol"),
|
|
33
|
-
file(
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
file(".ai/skills/planning/SKILL.md", planningSkill, "skill"),
|
|
39
|
-
file(".ai/skills/project-discovery/SKILL.md", projectDiscoverySkill, "skill"),
|
|
40
|
-
file(".ai/skills/codebase-exploration/SKILL.md", explorationSkill, "skill"),
|
|
41
|
-
file(".ai/skills/implementation/SKILL.md", implementationSkill, "skill"),
|
|
42
|
-
file(".ai/skills/verification/SKILL.md", verificationSkill, "skill"),
|
|
43
|
-
file(".ai/skills/debugging/SKILL.md", debuggingSkill, "skill"),
|
|
44
|
-
file(".ai/skills/code-review/SKILL.md", codeReviewSkill, "skill"),
|
|
45
|
-
file(".ai/skills/task-conductor/SKILL.md", taskConductorSkill, "skill"),
|
|
35
|
+
...AGENT_DOCUMENTS.map((agent) => file(`.ai/agents/${agent.id}/AGENT.md`, agent.manifest, "agent")),
|
|
36
|
+
...BASE_SKILL_DOCUMENTS.flatMap((skill) => [
|
|
37
|
+
file(`.ai/skills/${skill.id}/SKILL.md`, skill.skill, "skill"),
|
|
38
|
+
...skill.references.map((reference) => file(`.ai/skills/${skill.id}/references/${reference.fileName}`, reference.content, "reference")),
|
|
39
|
+
]),
|
|
46
40
|
file(".ai/model-profiles/openai.yaml", openAiProfile, "canonical"),
|
|
47
41
|
file(".ai/model-profiles/claude.yaml", claudeProfile, "canonical"),
|
|
48
42
|
file(".ai/schemas/context-packet.schema.json", contextPacketSchema, "schema"),
|
|
@@ -50,6 +44,7 @@ export function createStructureFiles(scope) {
|
|
|
50
44
|
file(".ai/providers/codex.md", codexAdapter, "provider"),
|
|
51
45
|
file(".ai/providers/claude-code.md", claudeAdapter, "provider"),
|
|
52
46
|
file(".ai/tasks/.gitkeep", "", "canonical"),
|
|
47
|
+
...skillCreatorLedgerFiles,
|
|
53
48
|
];
|
|
54
49
|
}
|
|
55
50
|
function file(relativePath, content, kind) {
|
|
@@ -73,8 +68,9 @@ Before the first task:
|
|
|
73
68
|
4. Do not begin discovery or planning until the user confirms.
|
|
74
69
|
5. For the active project, read its record from \`.ai/workspace.yaml\`, then read the referenced \`skill_registry\`.
|
|
75
70
|
6. Treat registry entries as active, catalog entries as merely available, and skill contents as unloaded until the current work requires them. Do not scan or load the whole catalog during bootstrap.
|
|
76
|
-
7.
|
|
77
|
-
8.
|
|
71
|
+
7. Outside the registry, discover \`.ai/skills/project/*/SKILL.md\` from frontmatter only. Route only \`status: active\`; never auto-load \`proposed\`, \`stale\` or \`retired\`, and keep bodies unloaded during discovery.
|
|
72
|
+
8. For a non-trivial brief, load \`.ai/skills/task-conductor/SKILL.md\` as the central decomposition and routing discipline. For a one-line or single-step fix, keep the workflow trivial and do not create an orchestra.
|
|
73
|
+
9. Load other skills just in time when their description matches the work. Load a generated skill body only when its active metadata matches.
|
|
78
74
|
|
|
79
75
|
## Non-negotiable behavior
|
|
80
76
|
|
|
@@ -103,8 +99,9 @@ Before the first task:
|
|
|
103
99
|
4. Do not begin discovery or planning until the user confirms.
|
|
104
100
|
5. For the active project, read its record from \`.ai/workspace.yaml\`, then read the referenced \`skill_registry\`.
|
|
105
101
|
6. Treat registry entries as active, catalog entries as merely available, and skill contents as unloaded until the current work requires them. Do not scan or load the whole catalog during bootstrap.
|
|
106
|
-
7.
|
|
107
|
-
8.
|
|
102
|
+
7. Outside the registry, discover \`.ai/skills/project/*/SKILL.md\` from frontmatter only. Route only \`status: active\`; never auto-load \`proposed\`, \`stale\` or \`retired\`, and keep bodies unloaded during discovery.
|
|
103
|
+
8. For a non-trivial brief, load \`.ai/skills/task-conductor/SKILL.md\` as the central decomposition and routing discipline. For a one-line or single-step fix, keep the workflow trivial and do not create an orchestra.
|
|
104
|
+
9. Load other skills just in time when their description matches the work. Load a generated skill body only when its active metadata matches.
|
|
108
105
|
|
|
109
106
|
## Non-negotiable behavior
|
|
110
107
|
|
|
@@ -293,127 +290,6 @@ mandatory: true
|
|
|
293
290
|
|
|
294
291
|
Only the orchestrator speaks to the user. Lead with outcomes and decisions. Ask only for choices that materially affect scope or result. Plans and final reports include model routing and verification evidence without exposing unnecessary internal chatter.
|
|
295
292
|
`;
|
|
296
|
-
const orchestratorAgent = `---
|
|
297
|
-
name: orchestrator
|
|
298
|
-
role: control-plane
|
|
299
|
-
writes_product_files: false
|
|
300
|
-
control_plane_write_scope: .ai/tasks/**
|
|
301
|
-
---
|
|
302
|
-
|
|
303
|
-
# Orchestrator
|
|
304
|
-
|
|
305
|
-
Own requirements, risk classification, decisions, plans, delegation, context packets, monitoring, review synthesis and user communication. Never implement. Use Task Conductor as the central routing discipline for non-trivial briefs, load other skills just in time and keep single-step work plain. Treat worker claims as untrusted until supported by proportionate evidence.
|
|
306
|
-
`;
|
|
307
|
-
const explorerAgent = `---
|
|
308
|
-
name: explorer
|
|
309
|
-
role: read-only-evidence
|
|
310
|
-
writes_product_files: false
|
|
311
|
-
---
|
|
312
|
-
|
|
313
|
-
# Explorer
|
|
314
|
-
|
|
315
|
-
Answer one bounded codebase question with paths, symbols and evidence. Do not modify files. Reuse existing project snapshots and task evidence before searching. Report unknowns and confidence explicitly.
|
|
316
|
-
`;
|
|
317
|
-
const implementerAgent = `---
|
|
318
|
-
name: implementer
|
|
319
|
-
role: product-change
|
|
320
|
-
writes_product_files: true
|
|
321
|
-
---
|
|
322
|
-
|
|
323
|
-
# Implementer
|
|
324
|
-
|
|
325
|
-
Implement only the assigned objective and owned paths. Read the task packet first, preserve concurrent work, run required checks and return a structured completion packet. Escalate scope changes instead of expanding the task.
|
|
326
|
-
`;
|
|
327
|
-
const debuggerAgent = `---
|
|
328
|
-
name: debugger
|
|
329
|
-
role: root-cause-and-fix
|
|
330
|
-
writes_product_files: true
|
|
331
|
-
---
|
|
332
|
-
|
|
333
|
-
# Debugger
|
|
334
|
-
|
|
335
|
-
Reproduce, narrow the search space, form falsifiable hypotheses, identify root cause, implement the smallest justified fix and prove it. Do not patch symptoms without evidence.
|
|
336
|
-
`;
|
|
337
|
-
const reviewerAgent = `---
|
|
338
|
-
name: reviewer
|
|
339
|
-
role: independent-review
|
|
340
|
-
writes_product_files: false
|
|
341
|
-
---
|
|
342
|
-
|
|
343
|
-
# Reviewer
|
|
344
|
-
|
|
345
|
-
Independently compare the approved plan, acceptance criteria, diff and verification evidence. Report actionable findings by severity. Do not approve based only on the implementer's summary and do not modify the implementation.
|
|
346
|
-
`;
|
|
347
|
-
const planningSkill = `---
|
|
348
|
-
name: planning
|
|
349
|
-
description: Use for every new user task before implementation begins.
|
|
350
|
-
---
|
|
351
|
-
|
|
352
|
-
# Planning
|
|
353
|
-
|
|
354
|
-
1. State the goal and non-goals.
|
|
355
|
-
2. Classify the task as trivial, standard or high-risk with evidence.
|
|
356
|
-
3. Separate verified facts, assumptions and decisions; identify material questions.
|
|
357
|
-
4. Build a dependency-aware task graph with ownership.
|
|
358
|
-
5. Select worker tiers and verification.
|
|
359
|
-
6. Present the plan and wait for user approval.
|
|
360
|
-
|
|
361
|
-
For trivial work, replace the task graph with one compact objective, one fast worker, exact ownership and claim-specific proof.
|
|
362
|
-
`;
|
|
363
|
-
const projectDiscoverySkill = `---
|
|
364
|
-
name: project-discovery
|
|
365
|
-
description: Use after manual sync or when a registered project's facts need bounded refresh.
|
|
366
|
-
---
|
|
367
|
-
|
|
368
|
-
# Project Discovery
|
|
369
|
-
|
|
370
|
-
Read existing AI instructions first. Inspect manifests, lockfiles, README, CI and configuration before source code. Record only evidence-backed languages, frameworks, commands and boundaries. Mark uncertain interpretations as hypotheses. Never invent architecture for an empty project.
|
|
371
|
-
`;
|
|
372
|
-
const explorationSkill = `---
|
|
373
|
-
name: codebase-exploration
|
|
374
|
-
description: Use to answer a specific codebase question before planning or delegation.
|
|
375
|
-
---
|
|
376
|
-
|
|
377
|
-
# Codebase Exploration
|
|
378
|
-
|
|
379
|
-
Start from the project snapshot and existing evidence. Search by symbol and path, not by reading the entire repository. Return relevant files, relationships, conventions, risks and unanswered questions with provenance.
|
|
380
|
-
`;
|
|
381
|
-
const implementationSkill = `---
|
|
382
|
-
name: implementation
|
|
383
|
-
description: Use by a worker after an approved plan and task packet exist.
|
|
384
|
-
---
|
|
385
|
-
|
|
386
|
-
# Implementation
|
|
387
|
-
|
|
388
|
-
Confirm objective, ownership and constraints. Inspect the latest target files, make the smallest coherent change, preserve unrelated work, verify incrementally and return a completion packet. Stop and escalate when scope or assumptions change.
|
|
389
|
-
`;
|
|
390
|
-
const verificationSkill = `---
|
|
391
|
-
name: verification
|
|
392
|
-
description: Use before any implementation is reported complete.
|
|
393
|
-
---
|
|
394
|
-
|
|
395
|
-
# Verification
|
|
396
|
-
|
|
397
|
-
Map each acceptance criterion to the cheapest sufficient evidence and stop when the claim is proven. Trivial work uses exact diff or targeted static proof without broad checks or review. Standard work uses focused tests and only the relevant lint/typecheck/build. High-risk work adds broad checks and independent review. A headed browser is opt-in and requires a user request or approval for a named unresolved criterion. Record passed, failed, skipped and not-run checks.
|
|
398
|
-
`;
|
|
399
|
-
const debuggingSkill = `---
|
|
400
|
-
name: debugging
|
|
401
|
-
description: Use for defects, flaky behavior and unexplained failures.
|
|
402
|
-
---
|
|
403
|
-
|
|
404
|
-
# Debugging
|
|
405
|
-
|
|
406
|
-
Reproduce first. Establish a minimal failing case, rank hypotheses, gather evidence that can disprove each one, locate root cause, add a regression test, implement the smallest fix and rerun relevant verification.
|
|
407
|
-
`;
|
|
408
|
-
const codeReviewSkill = `---
|
|
409
|
-
name: code-review
|
|
410
|
-
description: Use for independent review after implementation.
|
|
411
|
-
---
|
|
412
|
-
|
|
413
|
-
# Code Review
|
|
414
|
-
|
|
415
|
-
Review against the approved task, not personal preference. Inspect the actual diff and surrounding code. Prioritize correctness, regressions, security, concurrency and missing tests. Report precise locations and consequences; state explicitly when no actionable finding exists.
|
|
416
|
-
`;
|
|
417
293
|
const openAiProfile = `schema_version: 1
|
|
418
294
|
provider: openai
|
|
419
295
|
defaults:
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"structure-templates.js","sourceRoot":"","sources":["../../src/templates/structure-templates.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,sBAAsB,EAAE,eAAe,EAAE,MAAM,sBAAsB,CAAC;AAC/E,OAAO,EAAE,aAAa,EAAE,MAAM,oCAAoC,CAAC;AACnE,OAAO,EAAE,kBAAkB,EAAE,MAAM,
|
|
1
|
+
{"version":3,"file":"structure-templates.js","sourceRoot":"","sources":["../../src/templates/structure-templates.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,sBAAsB,EAAE,eAAe,EAAE,MAAM,sBAAsB,CAAC;AAC/E,OAAO,EAAE,aAAa,EAAE,MAAM,oCAAoC,CAAC;AACnE,OAAO,EAAE,eAAe,EAAE,MAAM,sBAAsB,CAAC;AACvD,OAAO,EAAE,oBAAoB,EAAE,MAAM,kBAAkB,CAAC;AACxD,OAAO,EAAE,uBAAuB,EAAE,MAAM,0BAA0B,CAAC;AAEnE,MAAM,UAAU,oBAAoB,CAAC,KAAqB;IACxD,OAAO;QACL,I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,SAAS,EAAE,CAAC,EAAE;QACzC,MAAM,EAAE,EAAE,IAAI,EAAE,CAAC,WAAW,EAAE,QAAQ,EAAE,eAAe,EAAE,SAAS,CAAC,EAAE;QACrE,OAAO,EAAE,EAAE,IAAI,EAAE,QAAQ,EAAE;QAC3B,UAAU,EAAE,EAAE,IAAI,EAAE,CAAC,QAAQ,EAAE,MAAM,CAAC,EAAE;QACxC,aAAa,EAAE,EAAE,IAAI,EAAE,OAAO,EAAE,KAAK,EAAE,EAAE,IAAI,EAAE,QAAQ,EAAE,EAAE;QAC3D,YAAY,EAAE,EAAE,IAAI,EAAE,OAAO,EAAE,KAAK,EAAE,EAAE,IAAI,EAAE,QAAQ,EAAE,EAAE;QAC1D,cAAc,EAAE,EAAE,IAAI,EAAE,OAAO,EAAE,KAAK,EAAE,EAAE,IAAI,EAAE,QAAQ,EAAE,EAAE;QAC5D,aAAa,EAAE,EAAE,IAAI,EAAE,OAAO,EAAE,KAAK,EAAE,EAAE,IAAI,EAAE,QAAQ,EAAE,SAAS,EAAE,CAAC,EAAE,EAAE;QACzE,cAAc,EAAE,EAAE,IAAI,EAAE,OAAO,EAAE,KAAK,EAAE,EAAE,IAAI,EAAE,QAAQ,EAAE,EAAE;QAC5D,gBAAgB,EAAE,EAAE,IAAI,EAAE,OAAO,EAAE,KAAK,EAAE,EAAE,IAAI,EAAE,QAAQ,EAAE,EAAE;QAC9D,2BAA2B,EAAE,EAAE,IAAI,EAAE,OAAO,EAAE,KAAK,EAAE,EAAE,IAAI,EAAE,QAAQ,EAAE,EAAE;KAC1E;CACF,EACD,IAAI,EACJ,CAAC,CACF,CAAC"}
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export declare const taskConductorSkill = "---\nname: task-conductor\ndescription: Use as the orchestrator's central routing discipline for multi-part work. Decompose by dependency, load skills just in time, scale ceremony to risk, and stop verification at the cheapest sufficient evidence. Do not use the
|
|
1
|
+
export declare const taskConductorSkill = "---\nname: task-conductor\ndescription: Use as the orchestrator's central routing discipline for multi-part work. Decompose by dependency, load skills just in time, scale ceremony to risk, and stop verification at the cheapest sufficient evidence.\nversion: 1.1.0\nnot_for: Do not use the conductor workflow for a one-line or single-step fix, for work already decomposed into an approved task graph, or inside a worker dispatch \u2014 a worker conducts nothing.\ninputs:\n - The complete brief, read in full before any process is chosen\n - The registered project snapshot, skill registry and active generated-skill metadata for the active project\n - The risk tier, or the facts needed to classify it\ntools:\n - File read, directory listing and symbol search\n - Frontmatter-only discovery of generated project skills and just-in-time skill loading\n - Control-plane writes under .ai/tasks/**\noutputs: approved-plan\n---\n\n# Task Conductor\n\nRead the complete brief before deciding how much process it needs. Optimize jointly for correctness, elapsed time and context cost. More ceremony is not more correctness when it does not reduce a concrete risk.\n\n## When this applies\n\n- A brief carries several deliverables, or spans more than one concern, module or owner.\n- Work must be ordered by dependency before anyone can be dispatched.\n- A workstream needs a specialist skill and it is unclear which one.\n\n## When it does not\n\n- A one-line or single-step fix. A typo or a literal replacement needs no orchestra.\n- An approved task graph already exists and nothing about it changed.\n- You are the worker. Conducting is the orchestrator's authority, not a worker's.\n\n## Required inputs\n\n- The brief in full, including constraints and acceptance criteria the user stated.\n- The project snapshot: modules, commands, boundaries and registered skills.\n- Existing task evidence, so no workstream rediscovers what is already verified.\n\n## Ceremony by tier\n\nClassify with `.ai/protocols/core/orchestration.md`, then spend accordingly.\n\n- **trivial**: one fast worker. Keep the approved plan to one compact paragraph. Do not create workstreams, run broad discovery, request independent review or open a browser. Verify the exact diff and the changed claim only.\n- **standard**: the smallest capable worker set, focused discovery and targeted automated checks. Add independent review only when the diff is material or crosses a boundary.\n- **high-risk**: complex workers, explicit decomposition, strong verification and independent review.\n\nEscalate the tier when scope expands, a check fails unexpectedly, verified facts contradict the plan, or the change crosses a risk boundary. Record the reason. Never lower a tier merely to save cost.\n\n## Procedure\n\n1. Extract deliverables, actions, constraints, acceptance criteria and affected surfaces.\n2. Trace existing code and contracts before designing. Do not invent layers the brief does not need.\n3. Split into dependency-ordered workstreams. Each has one goal, explicit ownership and one done-check.\n4. Load zero to two genuinely matching skills per workstream, just in time. Available skills are not active or loaded skills. Discover `.ai/skills/project/*/SKILL.md` through frontmatter metadata only; consider only `status: active`, and load a generated skill's body only when its metadata matches the workstream. Never auto-load `proposed`, `stale` or `retired` skills.\n5. Execute one dependency layer at a time. Parallelize only independent ownership.\n6. Verify each acceptance claim with the cheapest sufficient evidence, then stop.\n\n## Context economy\n\nStart from the registered project snapshot and reuse verified evidence. Give workers minimal task packets, never the full conversation or the complete skill library. Load project-registered technology skills only when relevant to the owned work. Treat generated project skills as a separate, frontmatter-discovered namespace rather than registry entries. Search the available catalog only when the current task has an unmet specialist need.\n\n## Tools\n\nRead, list and search across the product tree; frontmatter-only generated-skill discovery; just-in-time body loading from active matches, registry and then catalog; control-plane writes under `.ai/tasks/**`. The conductor never edits product files and never dispatches work the user has not approved.\n\n## Verification\n\nClimb only as far as `.ai/protocols/core/verification.md` requires for the tier, and stop at the first sufficient evidence. The decomposition itself is sound when every workstream has one owner, no two concurrent workstreams own the same path, every dependency points backwards, and every acceptance claim names the evidence that will settle it.\n\n## Stop and escalate\n\nReturn to the user when the brief admits two materially different approaches, when a workstream needs authority the plan did not grant, when two workstreams contend for the same files, or when a named acceptance criterion cannot be settled by static, automated or structural evidence \u2014 in that last case explain the gap and obtain approval before opening a browser. Never create a browser or screenshot harness as a side effect of another task.\n\n## Output contract\n\nA dependency-ordered task graph: workstreams with owner, model tier, owned paths, acceptance criteria, loaded skills and done-check, plus the risk tier and its justification. On completion, report what changed, which claims were verified, which checks were intentionally not run, loaded skills, defaults chosen and remaining uncertainty. An honestly bounded verification gap is better than an expensive unrelated check.\n";
|
|
2
2
|
//# sourceMappingURL=task-conductor-skill.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"task-conductor-skill.d.ts","sourceRoot":"","sources":["../../src/templates/task-conductor-skill.ts"],"names":[],"mappings":"AAAA,eAAO,MAAM,kBAAkB,
|
|
1
|
+
{"version":3,"file":"task-conductor-skill.d.ts","sourceRoot":"","sources":["../../src/templates/task-conductor-skill.ts"],"names":[],"mappings":"AAAA,eAAO,MAAM,kBAAkB,skLA4E9B,CAAC"}
|
|
@@ -1,50 +1,78 @@
|
|
|
1
1
|
export const taskConductorSkill = `---
|
|
2
2
|
name: task-conductor
|
|
3
|
-
description: Use as the orchestrator's central routing discipline for multi-part work. Decompose by dependency, load skills just in time, scale ceremony to risk, and stop verification at the cheapest sufficient evidence.
|
|
3
|
+
description: Use as the orchestrator's central routing discipline for multi-part work. Decompose by dependency, load skills just in time, scale ceremony to risk, and stop verification at the cheapest sufficient evidence.
|
|
4
|
+
version: 1.1.0
|
|
5
|
+
not_for: Do not use the conductor workflow for a one-line or single-step fix, for work already decomposed into an approved task graph, or inside a worker dispatch — a worker conducts nothing.
|
|
6
|
+
inputs:
|
|
7
|
+
- The complete brief, read in full before any process is chosen
|
|
8
|
+
- The registered project snapshot, skill registry and active generated-skill metadata for the active project
|
|
9
|
+
- The risk tier, or the facts needed to classify it
|
|
10
|
+
tools:
|
|
11
|
+
- File read, directory listing and symbol search
|
|
12
|
+
- Frontmatter-only discovery of generated project skills and just-in-time skill loading
|
|
13
|
+
- Control-plane writes under .ai/tasks/**
|
|
14
|
+
outputs: approved-plan
|
|
4
15
|
---
|
|
5
16
|
|
|
6
17
|
# Task Conductor
|
|
7
18
|
|
|
8
19
|
Read the complete brief before deciding how much process it needs. Optimize jointly for correctness, elapsed time and context cost. More ceremony is not more correctness when it does not reduce a concrete risk.
|
|
9
20
|
|
|
10
|
-
##
|
|
21
|
+
## When this applies
|
|
11
22
|
|
|
12
|
-
-
|
|
13
|
-
-
|
|
14
|
-
-
|
|
23
|
+
- A brief carries several deliverables, or spans more than one concern, module or owner.
|
|
24
|
+
- Work must be ordered by dependency before anyone can be dispatched.
|
|
25
|
+
- A workstream needs a specialist skill and it is unclear which one.
|
|
15
26
|
|
|
16
|
-
|
|
27
|
+
## When it does not
|
|
17
28
|
|
|
18
|
-
|
|
29
|
+
- A one-line or single-step fix. A typo or a literal replacement needs no orchestra.
|
|
30
|
+
- An approved task graph already exists and nothing about it changed.
|
|
31
|
+
- You are the worker. Conducting is the orchestrator's authority, not a worker's.
|
|
19
32
|
|
|
20
|
-
|
|
33
|
+
## Required inputs
|
|
34
|
+
|
|
35
|
+
- The brief in full, including constraints and acceptance criteria the user stated.
|
|
36
|
+
- The project snapshot: modules, commands, boundaries and registered skills.
|
|
37
|
+
- Existing task evidence, so no workstream rediscovers what is already verified.
|
|
38
|
+
|
|
39
|
+
## Ceremony by tier
|
|
40
|
+
|
|
41
|
+
Classify with \`.ai/protocols/core/orchestration.md\`, then spend accordingly.
|
|
42
|
+
|
|
43
|
+
- **trivial**: one fast worker. Keep the approved plan to one compact paragraph. Do not create workstreams, run broad discovery, request independent review or open a browser. Verify the exact diff and the changed claim only.
|
|
44
|
+
- **standard**: the smallest capable worker set, focused discovery and targeted automated checks. Add independent review only when the diff is material or crosses a boundary.
|
|
45
|
+
- **high-risk**: complex workers, explicit decomposition, strong verification and independent review.
|
|
46
|
+
|
|
47
|
+
Escalate the tier when scope expands, a check fails unexpectedly, verified facts contradict the plan, or the change crosses a risk boundary. Record the reason. Never lower a tier merely to save cost.
|
|
48
|
+
|
|
49
|
+
## Procedure
|
|
21
50
|
|
|
22
51
|
1. Extract deliverables, actions, constraints, acceptance criteria and affected surfaces.
|
|
23
52
|
2. Trace existing code and contracts before designing. Do not invent layers the brief does not need.
|
|
24
|
-
3. Split into dependency-ordered workstreams. Each
|
|
25
|
-
4. Load zero to two genuinely matching skills per workstream, just in time. Available skills are not active or loaded skills.
|
|
53
|
+
3. Split into dependency-ordered workstreams. Each has one goal, explicit ownership and one done-check.
|
|
54
|
+
4. Load zero to two genuinely matching skills per workstream, just in time. Available skills are not active or loaded skills. Discover \`.ai/skills/project/*/SKILL.md\` through frontmatter metadata only; consider only \`status: active\`, and load a generated skill's body only when its metadata matches the workstream. Never auto-load \`proposed\`, \`stale\` or \`retired\` skills.
|
|
26
55
|
5. Execute one dependency layer at a time. Parallelize only independent ownership.
|
|
27
56
|
6. Verify each acceptance claim with the cheapest sufficient evidence, then stop.
|
|
28
57
|
|
|
29
|
-
For a single-step fix, do the plain work plainly. A typo or literal text replacement needs no orchestra.
|
|
30
|
-
|
|
31
58
|
## Context economy
|
|
32
59
|
|
|
33
|
-
Start from the registered project snapshot and reuse verified evidence. Give workers minimal task packets, never the full conversation or the complete skill library. Load project-registered technology skills only when relevant to the owned work. Search the available catalog only when the current task has an unmet specialist need.
|
|
60
|
+
Start from the registered project snapshot and reuse verified evidence. Give workers minimal task packets, never the full conversation or the complete skill library. Load project-registered technology skills only when relevant to the owned work. Treat generated project skills as a separate, frontmatter-discovered namespace rather than registry entries. Search the available catalog only when the current task has an unmet specialist need.
|
|
61
|
+
|
|
62
|
+
## Tools
|
|
63
|
+
|
|
64
|
+
Read, list and search across the product tree; frontmatter-only generated-skill discovery; just-in-time body loading from active matches, registry and then catalog; control-plane writes under \`.ai/tasks/**\`. The conductor never edits product files and never dispatches work the user has not approved.
|
|
34
65
|
|
|
35
|
-
## Verification
|
|
66
|
+
## Verification
|
|
36
67
|
|
|
37
|
-
|
|
68
|
+
Climb only as far as \`.ai/protocols/core/verification.md\` requires for the tier, and stop at the first sufficient evidence. The decomposition itself is sound when every workstream has one owner, no two concurrent workstreams own the same path, every dependency points backwards, and every acceptance claim names the evidence that will settle it.
|
|
38
69
|
|
|
39
|
-
|
|
40
|
-
2. Narrow existing lint, typecheck, unit or component checks for the affected scope.
|
|
41
|
-
3. Broader build, integration or end-to-end checks when boundaries or behavior justify them.
|
|
42
|
-
4. Independent review for material standard work and all high-risk work.
|
|
70
|
+
## Stop and escalate
|
|
43
71
|
|
|
44
|
-
|
|
72
|
+
Return to the user when the brief admits two materially different approaches, when a workstream needs authority the plan did not grant, when two workstreams contend for the same files, or when a named acceptance criterion cannot be settled by static, automated or structural evidence — in that last case explain the gap and obtain approval before opening a browser. Never create a browser or screenshot harness as a side effect of another task.
|
|
45
73
|
|
|
46
|
-
##
|
|
74
|
+
## Output contract
|
|
47
75
|
|
|
48
|
-
|
|
76
|
+
A dependency-ordered task graph: workstreams with owner, model tier, owned paths, acceptance criteria, loaded skills and done-check, plus the risk tier and its justification. On completion, report what changed, which claims were verified, which checks were intentionally not run, loaded skills, defaults chosen and remaining uncertainty. An honestly bounded verification gap is better than an expensive unrelated check.
|
|
49
77
|
`;
|
|
50
78
|
//# sourceMappingURL=task-conductor-skill.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"task-conductor-skill.js","sourceRoot":"","sources":["../../src/templates/task-conductor-skill.ts"],"names":[],"mappings":"AAAA,MAAM,CAAC,MAAM,kBAAkB,GAAG
|
|
1
|
+
{"version":3,"file":"task-conductor-skill.js","sourceRoot":"","sources":["../../src/templates/task-conductor-skill.ts"],"names":[],"mappings":"AAAA,MAAM,CAAC,MAAM,kBAAkB,GAAG;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CA4EjC,CAAC"}
|